{"id":18221831,"url":"https://github.com/karlicoss/monzoexport","last_synced_at":"2025-04-03T02:30:50.307Z","repository":{"id":141611479,"uuid":"230107205","full_name":"karlicoss/monzoexport","owner":"karlicoss","description":"Tool to export your Monzo transactions","archived":false,"fork":false,"pushed_at":"2024-03-04T20:16:45.000Z","size":51,"stargazers_count":4,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-02T20:05:08.811Z","etag":null,"topics":["backup","data-liberation","export","monzo"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/karlicoss.png","metadata":{"files":{"readme":"README.org","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2019-12-25T13:31:30.000Z","updated_at":"2022-09-12T21:14:01.000Z","dependencies_parsed_at":"2023-04-11T06:07:59.768Z","dependency_job_id":"6c3b4364-edb3-4c44-b376-4182e89e9322","html_url":"https://github.com/karlicoss/monzoexport","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/karlicoss%2Fmonzoexport","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/karlicoss%2Fmonzoexport/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/karlicoss%2Fmonzoexport/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/karlicoss%2Fmonzoexport/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/karlicoss","download_url":"https://codeload.github.com/karlicoss/monzoexport/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246925206,"owners_count":20855857,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backup","data-liberation","export","monzo"],"created_at":"2024-11-03T22:04:41.231Z","updated_at":"2025-04-03T02:30:49.999Z","avatar_url":"https://github.com/karlicoss.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"#+begin_src python :results drawer :exports results\nimport monzoexport.export as E; return E.make_parser().prog\n#+end_src\n\n#+RESULTS:\n:results:\nTool to export your Monzo transactions\n:end:\n\n* Setting up\n1. The easiest way is =pip3 install --user git+https://github.com/karlicoss/monzoexport=.\n\n   Alternatively, use =git clone --recursive=, or =git pull \u0026\u0026 git submodule update --init=. After that, you can use =pip3 install --editable=.\n2. Create a new oauth client on [[https://developers.monzo.com/apps/home][monzo website]].\n\n   - pick confidentiality to be \"confidential\"\n   - redirect uri should be =https://github.com= (it's currently hardcoded in the export script)\n\n   After creating the client, click on it in the oauth clients list.\n\n   - add your own user id to \"collaborators\", your User ID will be the same as app \"Owner ID\". You might need to refresh the page to see changes.\n   - take note of \"Client ID\" and \"Client secret\", you'll need them on the next step\n\n3. *Log in and do an initial export*\n\n   The =--first-time= parameter will walk you through the login procedure:\n\n   : python3 -m monzoexport.export --token-path token.json --first-time /path/to/first-export.json\n\n   After a successful export, move =token.json= somewhere safe, and pass it as =token-path= later.\n   You won't need to pass =--first-time= anymore.\n\n   Note that *after 5 minutes after login, api can only sync the last 90 days of transactions*\n   (see https://docs.monzo.com/#list-transactions for more information).\n   Because of that it's important to do at least one export immediately once you received the token.\n\n\n* Exporting\n\n#+begin_src python :results drawer :exports results\nimport monzoexport.export as E; return E.make_parser().epilog\n#+end_src\n\n#+RESULTS:\n:results:\n\nUsage:\n\n*Recommended*: create =secrets.py= keeping your api parameters, e.g.:\n\n\n: token-path = \"TOKEN-PATH\"\n\n\nAfter that, use:\n\n: python3 -m monzoexport.export --secrets /path/to/secrets.py\n\nThat way you type less and have control over where you keep your plaintext secrets.\n\n*Alternatively*, you can pass parameters directly, e.g.\n\n: python3 -m monzoexport.export --token-path \u003ctoken-path\u003e\n\nHowever, this is verbose and prone to leaking your keys/tokens/passwords in shell history.\n\n\nYou can also import ~export.py~ as a module and call ~get_json~ function directly to get raw JSON.\n\n\nI *highly* recommend checking exported files at least once just to make sure they contain everything you expect from your export. If not, please feel free to ask or raise an issue!\n\n:end:\n\n* Using data\n  \n#+begin_src python :results drawer :exports results \nimport monzoexport.exporthelpers.dal_helper as D; return D.make_parser().epilog\n#+end_src\n\n#+RESULTS:\n:results:\n\nYou can use =monzoexport.dal= (stands for \"Data Access/Abstraction Layer\") to access your exported data, even offline.\nI elaborate on motivation behind it [[https://beepb00p.xyz/exports.html#dal][here]].\n\n- main usecase is to be imported as python module to allow for *programmatic access* to your data.\n\n  You can find some inspiration in [[https://beepb00p.xyz/mypkg.html][=my.=]] package that I'm using as an API to all my personal data.\n\n- to test it against your export, simply run: ~python3 -m monzoexport.dal --source /path/to/export~\n\n- you can also try it interactively: ~python3 -m monzoexport.dal --source /path/to/export --interactive~\n\n:end:\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkarlicoss%2Fmonzoexport","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkarlicoss%2Fmonzoexport","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkarlicoss%2Fmonzoexport/lists"}