Skip to Content
TMBillOpen API

Getting a key

Keys are created by the restaurant owner in TMBill Backoffice, never by TMBill staff. This is what the owner does.

Create a key (owner)

Open Backoffice as the owner

Log in with the company owner account and go to Settings › API keys. Staff and sub-user logins do not see this screen.

Fill in the form

  • Name: who it is for, e.g. "Acme ERP" (letters, digits and . , & ( ) ' _ -, up to 100 characters).
  • Environment: live for real stores or test for the sandbox.
  • What it may read: Sales, Stores (both ticked by default).
  • Stores: all stores (including stores opened later), or chosen brands, markets, clusters or single stores.
  • Allowed IP addresses (optional, up to 20, IPv4/IPv6 or CIDR): the key works only from these.
  • Expiry (optional): default is never.

Confirm with the one-time code

TMBill emails a 6-digit code to the owner's verified address. It is valid for 5 minutes, works once, and only approves exactly the form that was sent. TMBill staff and developers will never ask for it.

Copy the key

The key is shown once. The owner passes it to you through a safe channel (a password manager share, not chat or email).

Roll a key (no downtime)

Rolling issues a new key and keeps the old one working for a chosen time: now, 1 hour, 24 hours or 7 days. It also needs the owner's one-time code. Deploy the new key, check /v1/me with it, then let the old one stop.

Revoke a key

The owner clicks Revoke. The key stops working on the very next call (401 key_revoked). No code is needed, because revoking only removes access. Do this at once if a key may have leaked.

Rules worth knowing

RuleWhy
Keys never expire unless the owner sets an expiryIntegrations should not break on a date nobody remembers
At most 2 active keys per app and environmentEnough for a roll; more means something is wrong
If the owner's email or phone changed in the last 14 days, new keys waitStops someone who took over a login from minting keys
A revoked or already stopped key can't be rolledRetired keys stay retired

On this page