Create subtransactions in YNAB for Venmo deposits
golf1052 opened this issue · 0 comments
After (with categories filled in)
YNAB API documentation and endpoints.
- Users must be able to authenticate with YNAB similar to how they authenticate with Venmo
- Users must set a default budget in YNAB
- Users must be able to set a default account in Slack
- Upon authentication prompt users to select a default account
- The server must query YNAB every hour to check for new Venmo deposits in the user's default budget under their selected account
- The server must find all payments to the Venmo user between their last two deposits and create subtransactions for each Venmo payment in ascending order.
- Ascending order is used because money sent to the user closer to the deposit is more likely to be in the Venmo account.
- If multiple Venmo deposits are found one after another in YNAB a new transaction in YNAB must be made with the combined amount of those deposits and the subtransactions must go under that new transaction.
- The old transactions should have their memo updated to say something like "<DELETE ME: Combined into $X Transfer from Venmo>"
- If the amount of money for a deposit is greater than the amount of Venmo payments between deposits the remaining amount must have a memo of "UNKNOWN"
- If the amount of money for a deposit is less than the amount of Venmo payments between deposits the remaining Venmo payments are ignored.
- In Slack, users should be able to create a mapping between a Venmo note and a YNAB category name so that the server can automatically categorize subtransactions.
Commands
/venmo ynab
- Prompt the user for authorization if they are not authorized. Show Venmo YNAB commands if they are authorized
/venmo ynab code [code]
- Completes YNAB authorization
/venmo ynab help
- Show Venmo YNAB commands
/venmo ynab list account[s]
- List YNAB accounts under the default budget
/venmo ynab set account [number]
- Set the default YNAB account to use
/venmo ynab list categories
- List all YNAB categories
/venmo ynab list mapping
- List all Venmo to YNAB mappings
/venmo ynab set mapping "[note]" to "[YNAB category]"
- Create/update a mapping from a Venmo note to a YNAB category
/venmo ynab delete mapping [number]
- Delete a mapping