Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No Account Info for deleted Transactions #124

Open
Jackman3005 opened this issue Apr 24, 2023 · 6 comments
Open

No Account Info for deleted Transactions #124

Jackman3005 opened this issue Apr 24, 2023 · 6 comments

Comments

@Jackman3005
Copy link

Hello, I am using the Up API to forward data to YNAB. I want to be able to keep track of pending transactions there as well so I can always have the same live balance in YNAB as I do in Up. I noticed today that if I receive a webhook event for TRANSACTION_DELETED, although I receive a transaction ID, I am unable to query for more information about that transaction from the GET /transactions/{id} endpoint as I receive a 404. Intuitively, this does make some sense... however, I am missing information on which account this transaction came from, which is necessary for me to identify the corresponding YNAB transaction and then delete it.

How can I know which account a transaction that has been deleted is/was associated with?

Thanks in advance! I'm really enjoying that you have totally changed the game in banking with this API ❤️

@d11wtq
Copy link
Contributor

d11wtq commented Apr 24, 2023

👍 Good call. I believe we have enough info available to include a relationship to the account in the event payload. Happy to have a look at this one!

@Jackman3005
Copy link
Author

Awesome, thanks for that!

@Jackman3005
Copy link
Author

Jackman3005 commented Apr 24, 2023

I am not 100% sure... But I think I may have received a DELETED event before the CREATED event... It's hard for me to confirm, b/c it looks like the transaction ID is different, but there was no other transaction that occurred during the timespan. i.e. I only received one DELETED event, then after received one CREATED event. The transaction that was created was created in a HELD status and in the app shows as "Pending charge from 24 Apr Expired." Although it too lists it as two transactions... (I did get a rogue DELETED that I can't match, but I don't think it's related to the paypal transactions shown below...) So I'm Still a bit confused now...

Can you confirm that DELETED events must be received after CREATED events, or is it possible the order can get mixed?

Cheers!

Here's what it looks like in my app btw.

Screenshot_20230424_141905_Up

@Jackman3005
Copy link
Author

When I tap on either one of the PayPal entries in the list shown in the screenshot the same detail view pops up from the bottom. Here is that...

Screenshot_20230424_142607_Up

(Sorry, I realize this may deserve to be documented under a separate issue, happy to make one if you want me to).

@d11wtq
Copy link
Contributor

d11wtq commented Apr 27, 2023

Can you confirm that DELETED events must be received after CREATED events, or is it possible the order can get mixed?

You might get events out of sequence if the event delivery failed on the first attempt and needs to be retried.

TRANSACTION_CREATED event is attempted, fails.
TRANSACTION_DELETED event is attempted, succeeds.
TRANSACTION_CREATED event is retried, succeeds.

We don't currently have a way of holding the queue of subsequent events if any single event needs to be retried.

But aside from retries, you are correct that deletes should always follow create events.

@Jackman3005
Copy link
Author

Okay, great thanks! It's possible that I was restarting the service when a TRANSACTION_CREATED was attempted and failed. Thanks :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants