Skip to content
Log inStart free

API reference

Admin API

Run the platform around your stores: sign-in and sessions, the stores you own and their members, billing, subscriptions and custom domains. 292 operations in 35 groups, generated from the OpenAPI document the service publishes.

Admin APIOpenAPI 3.0.0 · v1.0.0api.tanqory.com
Operations
292
Groups
35
Schemas
73

Largest groups

  1. Domains40 operations
  2. Subscriptions33 operations
  3. Billing24 operations
  4. Taxes22 operations
  5. Authentication18 operations
  6. Stores18 operations

Client libraries

Call it from the stack you know

Every operation is an HTTPS request with a JSON body, so any language can call the Admin API. In TypeScript, the SDK wraps the same OpenAPI documents.

  • TypeScript SDK@tanqory/sdk, generated from the OpenAPI documents this reference is built from, for browsers and Node.js.
  • React and React NativeThe @tanqory/sdk/react and @tanqory/sdk/react-native entry points add hooks for web and mobile apps.
  • Any HTTP clientcURL, fetch or Python requests: send the Bearer header and a JSON body, read JSON back.
  • Python and GoLibraries are on the roadmap. Until they ship, call the API over HTTPS as shown below.
install.sh
npm install @tanqory/sdk# Entry points#   @tanqory/sdk               browsers and Node.js#   @tanqory/sdk/react         React hooks#   @tanqory/sdk/react-native  React Native

Authentication

One Bearer token per request

Every Admin API call carries an Authorization header with a JSON Web Token. The same token opens the Admin, Store and AI APIs, so one key serves your whole app.

  • Bearer tokenThe spec declares one security scheme: HTTP bearer, format JWT, on every operation that needs sign-in.
  • Keep keys on the serverAnyone holding a key acts as you. Never commit it, log it or ship it in a browser bundle.
  • API License and TermsHow keys may be used and rotated.
  • When a token failsA missing, wrong or expired token answers 401 with the code auth_token_invalid. Sign in again; never retry the same token.
request.http
GET /api/v1/stores HTTP/1.1Host: api.tanqory.comAuthorization: Bearer $TANQORY_API_KEYContent-Type: application/json
401.json401 Unauthorized
{  "error": {    "type": "authentication_error",    "code": "auth_token_invalid",    "status": 401  }}

Base URL

Where the Admin API answers

The Admin API shares one host with the Store API, for live traffic and for development; each operation is sent to the service that owns it.

  • Productionhttps://api.tanqory.com serves every live call, for every store and region.
  • Developmenthttps://api.tanqory.dev is the development host.
  • No host to look upA store's calls go to the same host with its ID in the path; the platform routes them to the store's region.
  • Productionhttps://api.tanqory.com
  • Developmenthttps://api.tanqory.dev

First call

Make a call

The same request in three languages. Export your key as TANQORY_API_KEY, then run it.

  • GET /api/v1/storesList all stores for authenticated user. Find the operation in the Stores group, with its parameters and responses.
  • ResponsesIt answers 200 OK; a failure returns the one error object every call shares.
  • WorkbenchFill the fields and send the same request from the browser.
list-stores.sh200 OK
HOST=https://api.tanqory.comcurl -H "Authorization: Bearer $TANQORY_API_KEY" \  "$HOST/api/v1/stores"
GET/api/v1/stores

List all stores for authenticated user

Responses

  • 200OKReturns paginated list of stores

Limits, errors and versions

Rules every call shares

Retry what is safe to retry, read the one error envelope, and pin the version in the path.

  • Rate limitsTreat 429 and 503 as a signal to wait: honor Retry-After, otherwise back off with jitter, at most 4 attempts.
  • ErrorsEvery error is one error object with a type, a code, the status and a request id; a validation error lists each field.
  • VersioningVersions live in the URL path, not in a header. The Admin API is on /api/v1, document version 1.0.0.
  • PaginationList operations that page declare limit with offset or page; each operation's parameters say which.
with-retry.js
// Retry 429 and 503: honor Retry-After, else back off with jitter.async function withRetry(fn, max = 4) {  for (let attempt = 0; ; attempt++) {    const res = await fn();    if (res.status !== 429 && res.status !== 503) return res;    if (attempt >= max) return res;    const retryAfter = Number(res.headers.get('Retry-After'));    const base = Number.isFinite(retryAfter)      ? retryAfter * 1000      : Math.min(1000 * 2 ** attempt, 30_000); // 1s, 2s, 4s, capped    await new Promise((r) => setTimeout(r, base + Math.random() * 250));  }}

Make your first call today

Open a store, create a key and list your stores in one request. AI is part of every plan.

  • One Bearer token for every API
  • Generated from the OpenAPI spec
  • SDK, CLI and MCP server