Actifit Bot Development Updates - November 9 2018
Repository
https://github.com/mcfarhat/actifit-bot
Introduction
Actifit bot hosts the integral core part of the Actifit project and its reward process. As the project grows, we continuously work on improving this core functionality.
For this round, we have implemented several new features, modifications and fixes to enhance Actifit, including new API endpoints, beneficiary payment auto-rewards claim, hourly constraints on reports eligible for rewards, as well as few other fixes.
Below you will find more details about this update.
Technology Stack
The bot is scripted using Node.js, and connects to a MongoDB instance for storing and retrieving values.
Work Done
Create new API endpoints: Commit
- Create new endpoint for retrieving a post's full AFIT Pay reward. This allows filtering based on user and post url.
- Create new endpoint for gathering total number of AFIT tokens paid out based on charity-based activity
- Create new endpoint for retrieving number of AFIT tokens rewarded in return for STEEM/SBD based on Full AFIT Pay option
- Refactor post reward functionality to allow code reuse across new end points.
Implement Auto-rewards claims full AFIT Pay: Commit
- Implemented a new functionality to automated beneficiary rewards claims for the full AFIT beneficiary account so that every hour a check is made if beneficiary rewards are available, and hence to claim them.
Add hourly constraint between reports: Commit
- Implemented new constraint to prevent two reports from being voted if they have less than 6 hours difference. This is mostly to prevent issues with Steem BC timing out and sending incorrect response that post was not created, but also to circumvent potential abuse.
Implement Minor Fixes: Commit
- Implement a fix to tackle number of retries issues upon voting
- Implement a fix to skip end date target for fetching beneficiary rewards for full afit pay option
Roadmap
Further continuous improvements are planned for Actifit core functionality, particularly as the project grows, starting with the development of new endpoints to improve the website, app, and stats/info gathering processes.
How to contribute?
You can chat to us on the official actifit discord, or to me in discord private @mcfarhat#6013.
Contributions are accepted as pull requests to the official github repo.
We are having continuous tasks assigned to different contributors to our project. More official tasks are continuously announced :)
Thanks for the contribution, @mcfarhat! Cool to see you adding new endpoints and the automatic claiming of rewards especially. I've been working on my own JavaScript project for the last couple of days and have been using async / await as well. Coming from Python it took me a while to wrap my head around, so it's good to see examples of others using it.
I see you have an
eslintrc.js
in your repository and ESLint in your dev dependencies, but you don't seem to be using it. My configuration (I use airbnb, I don't know what standard is like in comparison) is showing quite a lot of things that should be changed (likevar
toconst
etc.). I'd also recommend installing Prettier, as that will also help with formatting everything correctly.Your contribution has been evaluated according to Utopian policies and guidelines, as well as a predefined set of questions pertaining to the category.
To view those questions and the relevant answers related to your post, click here.
Need help? Write a ticket on https://support.utopian.io/.
Chat with us on Discord.
[utopian-moderator]
Thanks @amosbastian
JS is fun, no? :)
I hear you about await and async, promises too, they're amazing stuff. It took me a while to wrap my head around them too, being an old Javascript guy who hasn't seen this stuff before lol
Yea we do have ESLint, I'm still to explore how to properly use it. I'm still coding with NP++ :D .. tried to move to Atom, still favored NP++.
Ill check out Prettier!
Haha it's not really that fun to me yet, but I'm getting more used to it. It's just frustrating when I know exactly how to do something in Python, but it takes me hours to do it in JavaScript because of my inexperience.
I am using Visual Studio Code with the ESLint plugin, with ESLint and Prettier also installed with npm. Just followed this video to get everything to work, and it's really great in my opinion.
Thank you for your review, @amosbastian! Keep up the good work!
I still think having a feature that allows two or more @actifit members to have a daily/weekly or monthly challenge with the opportunity to make a wager would be a great feature.
(Or you could bet that days tokens that are going to be distributed when the competition ends and the rewards are paid by actifit kind of how you have the rewards set up for donations.. or however you would want to go about it, the details don't really matter right now).
I think that would really push a lot of people to be way more active. Having an additional challenge or bet with a friend, that actually pays you a reward if you win... That would encourage me a hell of a lot more than just bragging rights. just sayin..
And isn't that what @actifit is really all about? Getting people more excited about fitness and health by monetarily rewarding them.
yes i remember our chat from before. We do have ideas for increasing competitiveness too, the queue is just too lengthy, we will get to it ;)
Good stuff! I just wanted to give u a reminder 😉 I'm sure people have given u lots of great ideas..
thank for Actifit efforts ! :)
Actifit ♥ LOVE !
Posted using Partiko Android
곰돌이가 @bluengel님의 소중한 댓글에 $0.006을 보팅해서 $0.017을 살려드리고 가요. 곰돌이가 지금까지 총 1410번 $19.620을 보팅해서 $17.500을 구했습니다. @gomdory 곰도뤼~
곰도뤼 늘 항상 댓글 구출 고마워용~♥
행복한 불금 보내셔용~^^
Posted using Partiko Android
Hey - this is an excellent idea as this incentivises physical effort. I am testing on iOS and will share feedback
Thank you, sure happy to hear that!
And you're welcome to join us on discord as well :)
always improving ... thanks
Just dropping by to say thank you for writing the account claim/create script that I've been using! Works like a charm, you rule!
Happy to hear man ! :)
Btw not sure if you've heard about our @actifit project? We've got an amazing project going on to incentivize people towards a more active / healthier lifestyle while earning tokens/STEEM upvotes.
If you'd like to support (and earn tokens) would be great! Maybe vote for our witness too? :)
Thank you !
@mcfarhat - @Actifit Founder
Vote for Actifit as a Witness
Delegate to Actifit 10SP| 20SP| 50SP| 100SP| 250SP| 500SP|
1000SP| 5000SP| 10000SP| 20000SP| Custom Amount
Chat with us on discord | Visit our website
Download on playstore | Download on app store
FAQs | Text Tutorial | Video Tutorial
Hi @mcfarhat!
Your post was upvoted by @steem-ua, new Steem dApp, using UserAuthority for algorithmic post curation!
Your post is eligible for our upvote, thanks to our collaboration with @utopian-io!
Feel free to join our @steem-ua Discord server
Hi, @mcfarhat!
You just got a 0.22% upvote from SteemPlus!
To get higher upvotes, earn more SteemPlus Points (SPP). On your Steemit wallet, check your SPP balance and click on "How to earn SPP?" to find out all the ways to earn.
If you're not using SteemPlus yet, please check our last posts in here to see the many ways in which SteemPlus can improve your Steem experience on Steemit and Busy.
Congratulations @mcfarhat! You have completed the following achievement on the Steem blockchain and have been rewarded with new badge(s) :
Click here to view your Board of Honor
If you no longer want to receive notifications, reply to this comment with the word
STOP
Do not miss the last post from @steemitboard:
Congratulations @mcfarhat! You have completed the following achievement on the Steem blockchain and have been rewarded with new badge(s) :
Click here to view your Board of Honor
If you no longer want to receive notifications, reply to this comment with the word
STOP
Do not miss the last post from @steemitboard: