monzo / monzo/docs

Annotate transaction not working for custom key

Open
#129 0 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
SCSS
Stars
116
Forks
51
Avg merge
1h 25m
Merged PRs (30d)
1

Description

I am trying to annotate transactions as documented here: https://docs.monzo.com/#annotate-transaction

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!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the annotate-transaction section at https://docs.monzo.com/#annotate-transaction and compare its documented response with the PATCH and GET transaction requests shown here. Reproduce the metadata update with a test transaction, then determine whether the API behavior or the documentation conflicts with the example. Done means the expected behavior is explained and the documentation or issue guidance is corrected.

Written by the indexing model from the issue text.

Assessment

Domain
api, documentation
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.