Skip to content

Authentication

Every call needs a key. Sign in at japanfold.aiand.com/account/token and the page shows one. A new account starts with $100.00, once.

If JAPANFOLD_API_KEY is already set where you run (check with [ -n "$JAPANFOLD_API_KEY" ], never by printing it), that is your key: use it and skip the sign-in.

The catalog is the one exception, because a client has to read it before it can ask for anything:

curl -s https://api.japanfold.aiand.com/v1/models

Your API key

  1. Sign in at japanfold.aiand.com/account/token with your email address. A six-digit code arrives by mail, and the page makes a key the moment you are in.
  2. Copy it. It is shown once, because only its hash is kept; if you lose it, revoke it on the same page and make another. Make one per machine or agent and name it after where it lives, so you know which one to revoke.
  3. Send it on every call as Authorization: Bearer (or X-API-Key). The examples in these docs read it from $JAPANFOLD_API_KEY:
export JAPANFOLD_API_KEY=jf_live_your_key_here
curl -s https://api.japanfold.aiand.com/v1/jobs \
  -H "Authorization: Bearer $JAPANFOLD_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{"model":"boltz2","input":"MKTAYIAKQRQISFVKSHFSRQLEERLGLIEVQ"}'

A job belongs to the account that submitted it. Poll, download and delete it with any key on that account; another account's id returns 404, and so does an id that does not exist. A key that is present but invalid or revoked is rejected with 401.

Colleagues

One account can have several people. Add a colleague's address under People on your account page. They get a mail with a link, and they join the account when they open it. From then on they sign in with their own address like you do. Until they accept they are listed as invited and are not on the account. The link works once, for 7 days; add them again to send a new one. Everyone on the account shares the same balance, jobs, API keys and invoice, so a lab pays one bill instead of one per scientist.

  • Anyone on the account can add or remove a colleague. There are no roles.
  • Removing someone signs them out at once and switches off the API keys they made. Their jobs stay with the account.
  • The account's own address, where invoices go, cannot be removed by a colleague. Only its holder can move it to another address or close the account.
  • An address that already has its own JapanFold account cannot be added. Its holder closes that account, or moves it to another address, on their account page first.

Over HTTP, GET /v1/account lists members; one who has not accepted yet carries invited: true. Adding and removing (POST /v1/account/members, DELETE /v1/account/members/{email}) needs a signed-in browser: an API key can read who is on the account but cannot change it.

Billing

Work is priced in US dollars for the time a chip actually holds your job: $0.26 per processor-hour. Nothing is quoted or reserved before a run, so what you are charged is what the meter measured, and a job that fails costs nothing.

When the balance reaches zero the API answers 402 with out_of_credit: true and a link to top up. A job already queued still runs. How billing works in full: https://api.japanfold.aiand.com/billing. Your balance, keys and usage are on your account.

An organisation that needs one invoice a month instead of paying by card can ask for monthly invoicing: runs draw on an agreed spending limit, and GET /v1/billing shows this month's usage, what is left and each invoice with its pay link.

What you spent is GET /v1/usage. Its summary covers the whole period you ask for (from/to as dates, or since/until), not just the page of rows: amount is the total in dollars, currency is usd, and by_model splits it per model. Every *_micros field in the API is the same money in millionths of a dollar, exact and safe to add up; amount beside it is ready to read.

curl -s "https://api.japanfold.aiand.com/v1/usage?from=2026-10-01&to=2026-10-07&limit=1" \
  -H "Authorization: Bearer $JAPANFOLD_API_KEY" | jq .summary
# {"amount": 1.84, "currency": "usd", "jobs": 37, "billable_s": 25476.9,
#  "by_model": {"boltz2": {"jobs": 30, "billable_s": 21012.3, "amount": 1.52, ...}, ...}, ...}

The CLI prints the same: japanfold usage --days 7.

Ownership and limits

Your balance is the limit. There is no cap on how many jobs you may queue, how many designs you may ask for or how much you may download, because every one of those costs money and the balance already bounds it.

What is still refused is what the hardware cannot fold: the per-model residue ceilings on Models & limits, live at GET /v1/models. Over one of those you get 400 (see Errors).