Quickstart

QannasAPI is one API key for B2B data: unified person, company, contact, website, ads, maps and social data behind a single credit-based API. You are billed for results only — if no result is returned, the call is free.

  1. Get your API key

    Create a key in the portal under Settings → API keys. Two kinds exist:

    PrefixModeCost
    qk_test_…Free test mode - deterministic sample dataFree, workspace quota-bound
    qk_live_…Live — production dataCredits, results only

    Build the whole integration on a qk_test_ key, then switch the prefix to go live. See Test mode.

  2. Make your first call

    Every request authenticates with a bearer token against https://api.qannasapi.com. This call hits the UAE calendar — data served from our own store, so it costs zero credits and answers in milliseconds:

    curl https://api.qannasapi.com/v1/calendar/uae/next-holiday \
      -H "Authorization: Bearer qk_test_replace_me"

    Every response uses the same envelope:

    Response
    {
      "status": "OK",
      "request_id": "01K3Z9...",
      "data": {
        "after": "2026-08-27",
        "sector": "private",
        "days_until": 34,
        "holiday": {
          "date": "2026-09-30",
          "name_en": "Prophet Muhammad's Birthday",
          "sector": "private",
          "status": "expected"
        }
      }
    }

    data is the payload, request_id is your support handle — quote it when anything looks wrong.

  3. Read the credit headers

    Every /v1/data/* call returns three headers that make billing self-auditing:

    A metered call
    curl -i -X POST https://api.qannasapi.com/v1/data/companies/enrich \
      -H "Authorization: Bearer qk_live_replace_me" \
      -H "Content-Type: application/json" \
      -d '{"query": "acme.com"}'
    Response headers
    HTTP/1.1 200 OK
    X-Credits-Charged: 1
    X-Credits-Balance: 482
    X-Price-Book: 01JZQ0...
    HeaderMeaning
    X-Credits-ChargedCredits this call cost. 0 when nothing was found.
    X-Credits-BalanceYour remaining balance after the call.
    X-Price-BookID of the price book that priced the call.

No result, no charge. If no result is returned you get HTTP 200 with data: null and X-Credits-Charged: 0. Temporary service failures (502) are never charged either.

Estimate before you spend

Quote any action before running it: POST /v1/data/{action}:estimate (and POST /v1/data/workflows/{name}:estimate for workflows). The catalog at GET /v1/meta/actions lists every action with its price in credits and availability.

Where next