invokr

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/v1

Auth

Authorization: Bearer ivk_…. Keys are shown once and stored hashed. Revoke them any time from your account.

Endpoints

  • POST/chat/completions

    OpenAI-compatible chat. Streaming, tools, JSON mode, images (modalities).

  • GET/models

    Every model with live input / output prices.

  • GET/balance

    Your 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
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
  }'
node / typescript
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 ?? "");
python
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 token1B fixed-supply ERC-20, launched on Ponsat launch
Pons curveOfficial Pons bonding curve for INVK; graduates into a locked Uniswap v4 poolat launch
CreditVaultDeposits (ETH / ERC-20, gifting by ref) and EIP-712 cash-out vouchersat launch
HolderPerksOn-chain daily allowance and tiersat launch
VestingLockCompany allocation: cliff + monthly unlocks, non-revocableat 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;