Call Tabbify from a script
Everything an agent can do over MCP a script can do over plain HTTP:
POST /api/v1/<tool> with a JSON body, an API key as the bearer token, a JSON
answer. Use it from a shell, a CI job or a cron entry, where an MCP client would
be in the way. It runs the same tool, with the same permission checks, as the
same call over MCP.
The address is https://api.tabbify.io. The tool API is switched on per site;
where it is off, /api/v1 answers 404.
1. Make a key
In the console open Settings, API keys and make a key:
- Access. Read only sees apps, their status and logs, and environments. Deploy adds deploy, restart, scale and stop. Full access is everything you may do, secrets and access included. Give a script the least it needs.
- Environments. All of them (including ones you make later) or the ones you tick. A key made for one environment cannot touch another.
- Expires. 30, 90 (the default) or 365 days, or never (until you revoke it).
The key (tbf_pat_...) is shown once, when it is made; copy it then. Keep it in
your CI's secret store and send it as Authorization: Bearer <key>. The key
page lists keys without their values and revokes any of them: a revoked key stops
working within 15 seconds.
From a terminal the same thing is tcli keys create --name "ci deploy" --preset deploy,
and tcli keys list and tcli keys revoke <id> (see CLI workflows).
2. Call a tool
export TABBIFY_TOKEN=tbf_pat_...
curl -X POST https://api.tabbify.io/api/v1/list_apps \
-H "Authorization: Bearer $TABBIFY_TOKEN" \
-H 'Content-Type: application/json' \
-d '{}'
The body is a JSON object holding the tool's arguments (empty, or {}, for a tool
that takes none), up to 1 MiB. The answer is the tool's JSON. The words the tools
write for a model (say_to_user, next_step, hint) are left out.
A few tools you will reach for first:
| Tool | Body | What you get |
|---|---|---|
list_apps | {} | Your apps and their state. |
deploy | {"repo_url": "...", "ref": "main", "tenant": "t_...", "app_name": "..."} | Starts a deploy from a repository and answers at once with a deploy_id. tenant is your account's tenant id. |
deploy_status | {"deploy_id": "..."} | Whether that deploy is serving, and the real build error if it is not. Poll it. |
An error answer is JSON too, with an error code:
tool.refusedwith amessage(and sometimesdata): 400 when the tool refused the arguments, 404 when the thing it names is not in your environments, 502 when it failed upstream;tool.failed, 400: the tool ran and reported an error; its answer is underanswer;tool.unknown, 404: there is no tool by that name;request.invalid, 400: the body is not a JSON object;request.too_large, 413: the body is over 1 MiB.
A missing or invalid key is 401. The X-Tabbify-Trace-Id response header names the call: give it
to support, or to the agent_trace tool, to see where it stopped.
A key made with less than full access is refused a tool outside what it may do.
3. The OpenAPI document
GET https://api.tabbify.io/api/v1/openapi.json describes every tool from the
argument schemas the tools themselves declare. It needs no key. Feed it to a client
generator, or read it to find a tool.
What a tool answers was written for a model and can change between releases. Only
the fields the document lists under x-stable-fields for a tool are stable: they are
not removed or renamed within a major version. Build on those and ignore the rest.
4. From the command line
tcli api is the same call without writing the HTTP:
tcli api --tools # list the tools
tcli api list_apps # no arguments
tcli api deploy_status deploy_id=... # key=value is a string
tcli api deploy --json @args.json # the whole body from a file, or - for stdin
key:=json passes a number, a boolean, an array or an object, for example
limit:=5. tcli api reads the key from TABBIFY_TOKEN (or --token), and
--dry-run prints the request instead of sending it.
Limits
- Rate. A site can hold each key to a number of requests a minute, counted
across
/api/v1and/mcptogether. A call over it is answered429with aRetry-Afterheader in seconds: wait that long and try again. A script that loops should honourRetry-Afterand not retry at once. - Scope. A key sees only the environments and permissions it was made with. Make one key per job, so revoking one does not stop the others.