You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The docs for update transactions say that the PATCH will update multiple transactions with changes by transaction id or import id.
However, the API doesn't accept id as a field in the transaction change. I get a 400 back when I try to, say, change the flag color on a group of transactions.
Thanks for this issue - I am almost certain you are receiving a 400 response because you are not providing complete transaction resources in the transactions array (only sending up { id: t.id, flag_color: "red" }). The PATCH is on the collection, not the resources themselves. So, you are PATCHing, or modifying the collection of transactions but the data for the individual transaction resources must be complete (i.e. have all necessary data).
On Jan 21, 2019, at 7:12 PM, Brady Holt ***@***.***> wrote:
Hello @ntdef 👋!
Thanks for this issue - I am almost certain you are receiving a 400 response because you are not providing complete transaction resources in the transactions array (only sending up { id: t.id, flag_color: "red" }). The PATCH is on the collection, not the resources themselves. So, you are PATCHing, or modifying the collection of transactions but the data for the individual transaction resources must be complete (i.e. have all necessary data).
In #40, I've added an example for update_transactions usage to hopefully make this clearer: https://github.com/ynab/ynab-sdk-ruby/blob/master/examples/update-multiple-transactions.rb
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
The docs for update transactions say that the PATCH will update multiple transactions with changes by transaction id or import id.
However, the API doesn't accept
id
as a field in the transaction change. I get a 400 back when I try to, say, change the flag color on a group of transactions.For example, the following doesn't work.
The text was updated successfully, but these errors were encountered: