Advanced
Bring your own AI key
FairThen’s AI features can run through an AI account of your own. The request goes straight from your phone to the provider you picked, so unless the app says otherwise where you use it, nothing about that request passes through our servers.
Receipt scan is the feature that uses AI today: it reads a photo of a bill into an itemized split. Anything we add later will use the same key, and the app will always say when a feature is about to send something off.
Checked 22 August 2026. The limits and data policies below are other companies’ and they change them whenever they like, so treat everything here as a starting point and follow the links to confirm.
Before you start
- It’s your account and your bill. You sign up with the provider directly. The two named providers below both have a free tier that doesn’t ask for a credit card up front, but that’s their decision to change, not ours, and anything you spend there is between the two of you.
- We’re not in the middle of the AI part. The request goes device to provider, so the reading happens there. The flip side is that we can’t see what went wrong when something does. Outages, rate limits and billing are all on their side.
- The app asks first. Before the first scan with each provider, FairThen tells you which provider and which web address the receipt is going to, and sends nothing until you tap Allow. Changed your mind? Switch it off in Settings → Advanced, under Data sharing, and it asks again before the next scan.
- It changes the AI step, not the app. Your key swaps out who does the reading. The items and amounts you keep are saved like any other bill, under the usual Privacy Policy, and the receipt photo itself isn’t saved or sent to our server.
- Look at what you’re sending. A receipt carries more than groceries sometimes, so crop or skip anything you’d rather not send. Along with the photo, the app sends the bill’s currency and how many people are on it, and nothing else from your groups. What each provider then does with what it receives differs, which is the main thing the comparison below is for.
- Your key stays on the phone. It’s held in the iOS Keychain or the Android Keystore, only ever sent to the provider it belongs to, only over an encrypted connection, and erased when you log out. It never touches our servers. Treat it like a password: most providers let you cap spending, and you can revoke a key from their dashboard at any time.
- Keep the screen open while it runs. There’s no job on our server to pick it up if you leave, so a request that outlives the screen is lost.
- Check what comes back. AI output is good rather than perfect. That means glancing over the items and the total before you split.
- Phones only. Your key lives in the phone’s secure storage, which a browser has no equivalent of, and some of these providers refuse browser requests outright. So this needs the iOS or Android app.
Why these ones
A provider had to clear three bars: a free tier you can use without a credit card, the same OpenAI-compatible API FairThen already speaks, and a model that can read an image, which is what Receipt scan needs. Two providers cleared it. The third option, Custom, is the escape hatch for everything else.
Google AI Studio
Easiest to set up- Free tier
- Free, no card. Your limits are shown in AI Studio rather than published.
- What they do with it
- Free tier may be used to improve Google’s products, and reviewed by people.
- You’ll need
- A Google account.
Cloudflare Workers AI
Flat daily allowance- Free tier
- 10,000 Neurons a day on the free Workers plan, reset at midnight UTC.
- What they do with it
- Says it doesn’t use what you send to train models or improve services.
- You’ll need
- A Cloudflare account, an API token, and your Account ID.
Custom
Anything else- Free tier
- Whatever your endpoint costs, possibly nothing if you run it yourself.
- What they do with it
- Whatever their policy says. On your own machine, nothing leaves your network.
- You’ll need
- An https OpenAI-compatible endpoint, the model id, and a key.
Google AI Studio
The shortest route if you already have a Google account, because Google sets up the project and the first key for you.
- Open aistudio.google.com/apikey and sign in.
- Accept the terms if you’re asked. A Google Cloud project and a first API key are created for you, so there’s nothing to configure on that side.
- Select Create API key (the section is called Get API key), then copy the key.
- In FairThen, go to Settings → Advanced, tap Google AI Studio, paste the key, then Test connection and Save.
Worth knowing
- Make a fresh key rather than reusing an old one. Google has been retiring its older Standard keys through 2026, unrestricted ones first, and issues a different kind now. FairThen doesn’t care what a key looks like, but an old one may already be refused by Google.
- The free tier is the one that learns from you. Google may use what you send on it to improve its products, and reviewers can see it. It doesn’t apply if you’re in the UK, the EEA or Switzerland, and moving to a paid tier stops it. Their API terms spell out both.
-
It has to be a key you can copy out of AI Studio. A service-account
JSON file or a
gcloudcredential isn’t something you can paste into the key field.
Official pages
Cloudflare Workers AI
Two values to copy instead of one, because a Workers AI token can’t tell the app which account it belongs to. Both are on the same screen.
- Sign in at dash.cloudflare.com. The free Workers plan is enough and no card is needed.
- Open Workers AI, then select Use REST API.
- Select Create a Workers AI API Token, then Create API Token, then Copy API Token. It’s shown once.
-
On the same screen, copy your Account ID. It’s 32 hex characters, so
0to9andatof. - In FairThen, go to Settings → Advanced, tap Cloudflare Workers AI, paste the token and the Account ID, then Test connection and Save.
Worth knowing
- Tapping Get a key in the app opens Cloudflare’s general API Tokens page rather than the Workers AI screen above, so those three buttons won’t be there. That page works too: Create Token, give the token both Workers AI · Read and Workers AI · Edit, and pick the Account ID up separately.
- To find the Account ID on its own, press Ctrl+K in the dashboard (Cmd+K on a Mac) and search for “Copy account ID”, or look under Workers & Pages → Account Details.
- The Account ID is not the Zone ID sitting next to it on a domain’s page, and it isn’t the token’s own id either. Those are the two things people paste by mistake.
Official pages
Custom: anything else
Custom points FairThen at any endpoint that speaks the OpenAI chat/completions API. That covers OpenAI itself, a gateway like OpenRouter, a proxy your workplace runs, or a model you host yourself.
What you fill in
- Endpoint URL. The base, usually ending in
/v1/. FairThen addschat/completionsitself, and adds the trailing slash if you forget. - Default model. The exact model id your endpoint expects. It’s the fallback: a tool that has its own model picked uses that one instead.
- API key. Whatever that endpoint authenticates with.
What FairThen sends
One POST to {your endpoint}chat/completions with your key as
a bearer token, carrying a system message with the instructions and a user message with
the text plus, where the feature needs one, an image as an inline base64
data: URI. It asks for a JSON schema first, and if the endpoint answers 400
to say it doesn’t understand that, it retries in plain JSON mode.
What the endpoint has to do
- https, no exceptions. An
http://endpoint is refused outright, because your key would cross the network in the clear. - No query string, no fragment, and no username or password in the URL. Any of the three is rejected before a request goes out.
- Answer on that exact URL. Redirects aren’t followed, on purpose, so your key can’t be bounced somewhere you didn’t agree to. An endpoint that 301s or 302s elsewhere will never work.
- For Receipt scan, accept an image inline as base64. Some endpoints only take a public image URL, and those won’t work here.
- Answer inside the budget. Receipt scan allows roughly a minute per attempt and three tries, and stops at about two and a half minutes overall. Very slow local hardware may not make it.
We can’t test or support an endpoint we’ve never seen, so this option really is at your own risk. Test connection sends a tiny text prompt, which proves the key and the URL work. Whether a model can actually read an image is checked separately, when you pick a model for Receipt scan.
Switching it on in the app
Two lists, in this order: Providers is where a key lives, and AI tools is where Receipt scan picks which provider and model to run on.
- Open Settings → Advanced.
- Under Providers, tap the one you want and fill in its fields. Google needs a key, Cloudflare also wants your Account ID, and Custom wants an endpoint URL and a default model.
- Test connection. A tiny text prompt goes to that provider using your key, so passing means the key and the endpoint work. Whether a model can read an image is a separate question, answered in step 5.
- Save. It stays locked until a test passes on exactly the values on screen, which is deliberate: a saved key that has never worked would fail at the worst possible moment. The row then reads Working.
- Under AI tools, open Receipt scan and give it a provider and a model. Test this model is worth using here: on a scan it runs a real test receipt and tells you how many items it read back, which is the only thing that proves the model can actually see. Unlike the key sheet, this one won’t stop you saving an untested choice.
- Turn on Use my own AI key. It sits at the top of the screen, above both lists, but it stays greyed out until at least one provider tests as working, which is why it is the last thing you do rather than the first.
A provider row tells you where it stands: Not set, Untested, Working or Failed, and once it works, which tools are pointed at it. A tool row shows its provider and model underneath, or Not set up if it has neither yet.
If something goes wrong
- The test fails and mentions 401 or 403. The key is wrong, expired, or restricted to something else. Make a new one and paste it again. Google AI Studio is the odd one out and answers a bad key with a 400, which the app spells out for you.
- A brand new Google key is refused straight away. Google changed the kind of key AI Studio issues during 2026, and the changeover has been bumpy. Check Google’s AI Developer Forum before assuming you did something wrong, and try one of the other providers meanwhile.
- 429, or anything about rate limits. You’ve reached the free allowance. Wait it out, or go back to Settings → Advanced, open Receipt scan, and point it at another provider you’ve set up. Nothing switches provider on its own.
- Cloudflare says the Account ID looks wrong. It’s 32 hex characters,
0to9andatof. The Zone ID and the token’s own id are different values. - A custom endpoint keeps returning 400. If the endpoint says the problem is the response format, FairThen retries in plain JSON mode by itself. Any other 400 is final, so the model most likely can’t return structured JSON, or, on Receipt scan, can’t read images at all.
- It worked yesterday and doesn’t today. Providers retire models. When that happens the provider is marked Failed and stops being used, rather than quietly falling back to something that can’t work. Worth knowing: if the provider that broke is the one behind Receipt scan, then Use my own AI key switches itself off. Sort the key out or point Receipt scan at another provider, then switch it back on. We can point the app at a replacement model without an app update, though it only looks for one about once a week, so reopen the tool, choose a model again and Test this model, or use Custom with a model id you choose yourself.
- Still stuck. Email support@fairthen.com. We can’t see anything that happened on the provider’s side, but we can usually tell you whether the app is doing its part.
Your key, your provider, your call
What happens to something that runs through us is in the Privacy Policy. The terms for bringing your own are in the Terms. Anything this page didn’t answer, just ask.
Provider details on this page were last checked on 22 August 2026.