API & contracts
Build on invokr
One key, every model, same balance as the app. The API is OpenAI-compatible: change the base URL and keep your code.
Base URL
https://invokrai.com/api/v1Auth
Authorization: Bearer ivk_…. Keys are shown once and stored hashed. Revoke them any time from your account.
Endpoints
- POST
/chat/completionsOpenAI-compatible chat. Streaming, tools, JSON mode, images (modalities).
- GET
/modelsEvery model with live input / output prices.
- GET
/balanceYour balance, drop credits and today's holder band.
Errors & limits
402 insufficient_credits when the balance can't cover a response. 429 rate_limited above 60 req/min (120 for Priority tier and above). Responses include x-ratelimit-* headers.
curl https://invokrai.com/api/v1/chat/completions \
-H "Authorization: Bearer $INVOKR_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai/gpt-6-sol",
"messages": [{ "role": "user", "content": "Summarise EIP-7702 in 3 bullets" }],
"stream": true
}'import OpenAI from "openai";
const client = new OpenAI({ baseURL: "https://invokrai.com/api/v1", apiKey: process.env.INVOKR_KEY });
const stream = await client.chat.completions.create({
model: "anthropic/claude-opus-5.5",
messages: [{ role: "user", content: "Refactor this function…" }],
stream: true,
});
for await (const chunk of stream) process.stdout.write(chunk.choices[0]?.delta?.content ?? "");from openai import OpenAI
import os
client = OpenAI(base_url="https://invokrai.com/api/v1", api_key=os.environ["INVOKR_KEY"])
res = client.chat.completions.create(
model="google/gemini-3.8-flash",
messages=[{"role": "user", "content": "Write a haiku about block times"}],
)
print(res.choices[0].message.content)Smart contracts
Deployed on Robinhood Chain (chain id 4663). Verified source on Blockscout. Solidity 0.8.28, OpenZeppelin 5.
| INVK token | 1B fixed-supply ERC-20, launched on Pons | at launch |
| Pons curve | Official Pons bonding curve for INVK; graduates into a locked Uniswap v4 pool | at launch |
| CreditVault | Deposits (ETH / ERC-20, gifting by ref) and EIP-712 cash-out vouchers | at launch |
| HolderPerks | On-chain daily allowance and tiers | at launch |
| VestingLock | Company allocation: cliff + monthly unlocks, non-revocable | at launch |
Fund an account from a contract
// Top up any Invokr account by its deposit reference (Account → Top up → Gift credits)
ICreditVault(vault).depositETH{value: 0.05 ether}(accountRef);
// Read a wallet's live holder allowance
HolderPerks.Profile memory p = HolderPerks(perks).aggregate(wallets);
p.dailyCredits; p.tier; p.resetsAt;