Understanding Fikra API Billing: Token Credits and Payment Methods
Fikra API Billing Overview
Fikra API operates on a token-credit wallet system. When you use the API, your requests consume tokens from this wallet. The platform integrates with Paystack for billing, and the public website states that M-Pesa and card payments are accepted.
What is a Token-Credit Wallet?
A token-credit wallet is a prepaid balance system. You top up your account with credits, and each API request deducts the corresponding token cost from this balance. This model allows for predictable cost management and immediate access to API services once funds are added.
Account and Top-Up Flow
- Access Dashboard: Log in to the Fikra dashboard to manage your account.
- Top Up: Use the billing section to add credits. The platform supports M-Pesa and card payments via Paystack.
- Verify Balance: Ensure your token-credit balance is sufficient before making API calls.
Monitoring Balance and Handling HTTP 402
Developers should monitor their token-credit balance to avoid service interruptions. If your balance is insufficient, the API will return an HTTP 402 (Payment Required) status code.
- Prevention: Implement balance checks in your application logic before making high-volume requests.
- Handling: If you receive a 402 error, pause API calls and prompt the user to top up their wallet via the Fikra dashboard.
Security Advice
- Never expose API keys in browser code: Fikra API keys (e.g.,
fk_live_...) should only be used in server-side environments. Exposing them in client-side code (JavaScript, HTML) can lead to unauthorized usage and depletion of your token credits. - Use Environment Variables: Store your
FIKRA_API_KEYin environment variables on your server to keep it secure.
Note on Payment Methods
While M-Pesa and card payments are publicly stated as accepted methods, specific payment options such as direct USD-to-KES conversion APIs or other international payment methods are not explicitly listed as supported features. If you require a specific payment method not mentioned in the public documentation, please confirm its availability with Fikra support before attempting to use it.
James Miano
CTO & ML Engineer at Lacesse Ventures. James specializes in low-overhead LLM quantization processes, custom ternary weights architectures, and localized server optimization.
Stop paying for overpriced round-trip latency
Why route queries over Western servers when you can use low-overhead hardware located in Nairobi? Save 87% on your monthly inference spend. No minimum credit limits. M-Pesa ready.