Monzo API - My PHP database

Hi all,

I run a self-hosted finance database on my Ubuntu-based Raspberry Pi.

I have it tied to an app that I’ve written in Flutter, and I’ve been using it for quite a few years now. I’m looking at using the Monzo API to pull my account details and pot balances.

I’ve never really experimented with API’s before, but I’ve read the documentation. With assistance of Claude code, I’m hoping to pull the balance’s into myPHP database.

Having read all the documentation, and from what I can see there is no way to send funds outside my account. The last thing I want to do is log in and realise I’ve sent all my money to some unknown person.

Usually I’d always test in sandbox, but I don’t think there is the option here to do this

Would love to know if anyone has done similar, and also how often do I need to re-authenticate the token

Thanks,

James.

I would suggest using the export to google sheets feature from monzo and getting your server to read from that or arranging for google sheets to write to your database. It would prevent the risk of exposing your API key, in case of breach.

Thanks for the comments, but I’d rather experiment with the API.

My app updates prior to me leaving the house, or pulls and updates whenever you come back onto my WIFI. I never felt comfortable exposing it to the outside world fully, hence I stayed away from Tailscale and other methods.

I was hoping to create another container on docker solely for the purpose of pulling the balance data from Monzo. Not all the transaction data, then I’ll pull from that container again only when connected to my WIFI.

I was more curious if the API allowed you to send money outside your account? I can’t see from the docs that you can which would make me feel a bit safer with experimenting.

I have it tied to Google docs at the moment but cant say I find it a good experience.

Doesn’t look like I can get access to the API anyhow.

Just keeps saying Developers.monzo.com

says Error: authentication state mismatch.

Tried on my computer and the phone I have logged into my Monzo, using their magic link you get emailed.