Developers

API reference

The e-ZeeInternet API is a small, JSON-over-HTTPS surface. All authenticated endpoints use Bearer tokens issued from your dashboard.

Authentication

Every authenticated request must include an Authorization header containing a Bearer token:

Authorization: Bearer ezi_sk_<your-token>
  • Token format: tokens start with the ezi_sk_ prefix followed by 64 hexadecimal characters.
  • Storage: tokens are hashed (SHA-256) at rest. We can never recover the plain-text value — if you lose a token, regenerate it.
  • Transport: always send tokens over HTTPS. Never embed tokens in client-side JavaScript or public repositories.
  • Scope: tokens act on behalf of the user who created them and respect the same row-level security as the dashboard.

Creating & regenerating tokens

Tokens are managed from the dashboard under the Tokens tab.

  1. 1
    Open the Tokens tab
    Sign in, go to Dashboard → Tokens. You'll see every active token, when it was created, and when it was last used.
  2. 2
    Click 'New token'
    Give the token a memorable name (e.g. CI pipeline or Local laptop). Names are for your reference only and can be reused.
  3. 3
    Copy the token immediately
    The full token is shown once, in a modal. Copy it into your secret manager — after closing the modal you'll only see the first 16 characters as a prefix.
  4. 4
    Use the token in the Authorization header
    See the examples below for curl, JavaScript and Python snippets you can copy verbatim.

Regenerate

Issues a brand-new token under the same name and instantly revokes the old one. Use this if a token leaks or on a regular rotation schedule.

Revoke

Permanently disables the token. Any client still using it will receive 401 Unauthorized on the next request. Revocation cannot be undone.

Examples

All examples list the trackers in your account. Replace ezi_sk_… with the token you copied from the dashboard.

curl
curl https://e-zeeinternet.com/api/v1/trackers \
  -H "Authorization: Bearer ezi_sk_REPLACE_ME" \
  -H "Accept: application/json"
JavaScript (fetch)
const res = await fetch("https://e-zeeinternet.com/api/v1/trackers", {
  headers: {
    Authorization: `Bearer ${process.env.EZI_TOKEN}`,
    Accept: "application/json",
  },
});

if (!res.ok) {
  throw new Error(`API error: ${res.status} ${res.statusText}`);
}

const { data: trackers } = await res.json();
console.log(trackers);
Python (requests)
import os, requests

resp = requests.get(
    "https://e-zeeinternet.com/api/v1/trackers",
    headers={
        "Authorization": f"Bearer {os.environ['EZI_TOKEN']}",
        "Accept": "application/json",
    },
    timeout=10,
)
resp.raise_for_status()

trackers = resp.json()["data"]
for t in trackers:
    print(t["domain"], t["site_id"])
Successful response (200)
{
  "data": [
    {
      "id": "8b1c…",
      "name": "My blog",
      "domain": "example.com",
      "site_id": "ezi_91bb8a0f41ea",
      "created_at": "2025-10-12T08:14:22.000Z"
    }
  ]
}

Endpoints

GET/api/v1/trackersBearerList trackers in your account.
POST/api/public/collectPublicSend a pageview or custom event from any source.
GET/api/public/statsPublic (site_id)Read aggregated stats for a tracker by site_id.

Errors

Errors are returned as JSON with an error code and HTTP status:

{
  "error": "unauthorized",
  "message": "Missing or invalid Bearer token. Create one in your dashboard under the Tokens tab."
}
  • 401 unauthorized — token missing, malformed, or revoked.
  • 404 not_found — the requested resource doesn't exist or isn't accessible to your token.
  • 429 rate_limited — back off and retry after the Retry-After header.
  • 500 server_error — transient on our end. Retry with exponential backoff.

Rate limits

Free plan: 60 requests/minute per token. Pro plan: 600 requests/minute per token. Burst credits replenish every second. 429 responses include a Retry-After header (in seconds).