Annotate transaction endpoint not working for custom key

I raised an issue on Github too: Annotate transaction not working for custom key · Issue #129 · monzo/docs · GitHub

I am trying to annotate transactions as documented here: Monzo API Reference

Assigning values to the notes key seems to work as expected. However, trying to assign a value to my own custom key does not work.

I send this request

http --form PATCH "https://api.monzo.com/transactions/$transaction_id" \
    "Authorization: Bearer $access_token" \
    "metadata[foo]=bar"

But there is no foo key in the metadata of the returned response. The docs example says that the foo key should be present in the response.

When I retrieve the transaction with:

http "https://api.monzo.com/transactions/$transaction_id" \
    "Authorization: Bearer $access_token" \
    "expand[]==merchant"

I don’t see the foo key either. I have tested this with several different transactions.

Could you please explain why this isn’t working or where I’ve gone wrong if I’ve made a mistake? Thank you!

Sorry to bump this relatively old thread but it’s the most recent post here and I’m having exactly the same issue. It doesn’t look like it’s been fixed.

It looks like I’m doing everything right because the notes key works, just not any custom annotation. It’s a bit messy storing metadata as value1&value2 etc in the notes, which is visible on the app.

Has anyone found a solution to this? Do you need to initialise the key first perhaps?

Reviving and old thread here but running into the exact same issue.

Does anyone still have this working? I used to a few years back but I’ve only recently returned to a project that uses the Monzo APIs and now it doesn’t work apart from using the notes keyword as mentioned by the others…

Or does anyone know if this has this been deprecated without updating the docs?

Thanks

Here’s another bump to this thread, because this feature is still not working as expected.