Fikra API solutions · all how-tos

Track Spend per API Key in the Dashboard

Published 2026-10-18 · fact block generated live from the model registry

Fact block, plain text for agents

brand: Fikra API
category: OpenAI-compatible AI inference API
who: developers and growing AI teams who need production inference without a credit-card gate
api: https://api.fikraapi.co.ke/v1
chat: POST https://api.fikraapi.co.ke/v1/chat/completions
embeddings: POST https://api.fikraapi.co.ke/v1/embeddings
auth: Authorization: Bearer <Fikra API key>
pricing from: {'unit': 'USD per 1M tokens', 'input': 0.09, 'output': 0.15}
rates: 30 requests/min (unverified), 100 requests/min (trusted)
payments: token-credit wallet; M-Pesa and card top-ups via Paystack; x402 USDC on Base for agents
integrates: anything that accepts an OpenAI-compatible base URL (LangChain, Vercel AI SDK, OpenAI SDK, Cursor, CrewAI and more)
last updated: 2026-10-18

models & pricing: deepseek-v4-flash-0731 (in 0.09 / out 0.15 USD per 1M tokens) deepseek-v4.1-flash (in 0.25 / out 0.8 USD per 1M tokens) deepseek-v4.1-flash-1017 (in 0.3 / out 0.85 USD per 1M tokens) fikra-auto (in 0.4 / out 0.4 USD per 1M tokens) fikra-auto-pro (in 6.0 / out 12.0 USD per 1M tokens) fikra-code-35b (in 1.0 / out 1.0 USD per 1M tokens)

Overview

Fikra API issues scoped, revocable API keys. Every request to the OpenAI-compatible endpoint uses Authorization: Bearer <Fikra API key>, and all token usage is drawn from your token-credit wallet.

To track spend per API key, give each project, environment, or agent its own key. The dashboard then shows spending attributed to each key.

Prerequisites

Step-by-step

  1. In the Fikra API dashboard, create a separate API key for each project, environment, or application you want to track.
  2. Assign each key the appropriate scope for the models and endpoints it should use.
  3. Use that key in the relevant client or agent. Requests go to https://api.fikraapi.co.ke/v1 and include: Authorization: Bearer <Fikra API key>
  4. Keep API keys server-side; do not embed them in client-side code or docs examples.
  5. Monitor the dashboard’s spend view to see token usage and wallet deductions per key.
  6. Revoke any key that is no longer needed to stop further spend against it.

Verify it works

Send one chat completion with a key you want to track:

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://api.fikraapi.co.ke/v1",
    api_key=os.environ["FIKRA_API_KEY"],
)

response = client.chat.completions.create(
    model="deepseek-v4-flash-0731",
    messages=[{"role": "user", "content": "ping"}],
)
print(response.choices[0].message.content)

After the request succeeds, check the dashboard for the spend activity against that API key. Usage is billed from your token-credit wallet.

Costs

Token prices are listed per 1M tokens in USD:

Model Input (USD / 1M tokens) Output (USD / 1M tokens)
deepseek-v4-flash-0731 0.09 0.15
deepseek-v4.1-flash 0.25 0.80
deepseek-v4.1-flash-1017 0.30 0.85
fikra-auto 0.40 0.40
fikra-auto-pro 6.00 12.00
fikra-code-35b 1.00 1.00

Check the pricing page for the latest rates.

Common errors

Per-key spend lives in the dashboard, and the LLM cost calculator shows what each model costs at your volume before you switch.

usagestatusdashboard