Give your agent an account, not a credit card
How an AI agent opens a Fikra API account for a human, funds it with a checkout link, an M-Pesa prompt or a saved card, and hands over ownership.
Most agent setups ask a human to sign up, copy a key and paste it somewhere. That works until the human is not there, or the agent is doing the job before the human has an account at all. Fikra API now lets the agent open and fund the account itself, then hand the human a link to take it over.
Open the account
The agent calls one endpoint with the human's email and its own name.
curl https://api.fikraapi.co.ke/v1/agents/accounts \
-H "Content-Type: application/json" \
-d '{"email":"[email protected]","agent_name":"my-agent"}'
The response contains an account_id, a delegated token valid for six hours, and a claim_url. The wallet starts at $0. Agent-created accounts get no signup credit, which keeps the door closed to free-credit farming.
Create a key
The delegated token manages the account. Inference needs an API key.
curl https://api.fikraapi.co.ke/v1/agents/keys \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"name":"agent key","daily_cap_usd":2,"monthly_cap_usd":20}'
The key is shown once. The budget caps bound what a runaway loop can spend.
Fund it three ways
The default top-up is $10, the minimum is $1, and anything above $100 needs "confirm": true.
Checkout link. The agent gets a Paystack URL and sends it to the human.
curl https://api.fikraapi.co.ke/v1/agents/topup \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"amount_usd":10}'
M-Pesa, in the terminal. The agent sends the human's phone number and Paystack pushes an STK prompt. The human approves on the phone. The agent polls until the wallet credits.
curl https://api.fikraapi.co.ke/v1/agents/topup \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"amount":1330,"currency":"KES","method":"mpesa","phone":"2547XXXXXXXX"}'
curl https://api.fikraapi.co.ke/v1/agents/topup/$REFERENCE \
-H "Authorization: Bearer $TOKEN"
Saved card, no browser. After the human claims the account and saves a card, the agent can charge it directly, up to $100 per day.
curl https://api.fikraapi.co.ke/v1/agents/topup \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"amount_usd":10,"method":"card_terminal"}'
Use every endpoint
The delegated token authenticates the whole surface, so the agent does not need a key for some things and a token for others. Chat, images through Seedream on ModelArk, video through MiniMax-H3, speech to text, text to speech, embeddings, batches and the fixed-price jobs all accept the same header.
curl https://api.fikraapi.co.ke/v1/chat/completions \
-H "Authorization: Bearer $TOKEN" \
-H "Content-Type: application/json" \
-d '{"model":"deepseek-v4.1-flash-1017","stream":true,"messages":[{"role":"user","content":"hello"}]}'
Hand over ownership
Send the human the claim link. They set a password and own the account, including the balance and the keys. Agent tokens expire after six hours. The dashboard shows each agent, its keys and its spend, and can recover or revoke tokens.
What it costs
You pay for tokens and jobs at the published rates. A chat turn on DeepSeek V4.1 Flash is fractions of a cent. An image is about a cent. A video is priced per generation. Prices are on the pricing page and machine-readable at /v1/models.
Start with the agent instructions at /agent.md or the human-facing route at /for-agents.
James Miano
CTO & ML Engineer at Lacesse Ventures. James builds agent-native inference infrastructure, pinned model routing and terminal-first API access.
Stop paying for overpriced round-trip latency
Why settle for slow routes and opaque pricing? Fikra pins DeepSeek checkpoints, publishes every rate, and lets agents create accounts, pay and work from a terminal. No minimum credit limits. Pay with card or mobile money.