What is relayfor.si?

Statements

A month's credits and AI spend, per account and in total.

A statement adds up a month: each account's opening and closing credit, what came in (payouts, purchases, adjustments) and what calls spent. The dashboard's Statements page shows it and downloads it as CSV.

Get a statement

GET

Send the project's secret key as Authorization: Bearer rf_sk_..., from a server.

Request
curl https://relayfor.si/api/project/v1/statements/2026-09 \  -H "Authorization: Bearer $RELAYFOR_SECRET_KEY"

Path

  • monthstringRequired

    YYYY-MM, in UTC; the current month reads to date.

Answer

Answers 200 with Statement.

Example answer
{  "month": "2026-09",  "from": "2026-09-01T00:00:00.000Z",  "to": "2026-10-01T00:00:00.000Z",  "complete": true,  "accounts": [    {      "account": "acc_arqp1qhbpvjhzifE",      "token": {        "mint": "MASi45ub7Qe4ZE36UT5G6cU4ud8Fhhe4deS4F3cw9KTA",        "symbol": "NOVA",        "name": "Nova"      },      "opening_usd": "0",      "credited_usd": {        "fee_credit": "58.4105",        "purchase": "50",        "adjustment": "0"      },      "spent_usd": "67.181766",      "closing_usd": "41.228734",      "payouts": 9,      "calls": 4812    }  ],  "totals": {    "opening_usd": "0",    "credited_usd": "108.4105",    "spent_usd": "67.181766",    "closing_usd": "41.228734"  },  "lines": [    {      "at": "2026-09-14T13:40:01.000Z",      "account": "acc_arqp1qhbpvjhzifE",      "token": "MASi45ub7Qe4ZE36UT5G6cU4ud8Fhhe4deS4F3cw9KTA",      "kind": "fee_credit",      "amount_usd": "7.6104",      "ref": "payout:dYmM6J4tmCUz5J2h6tH6fwF5Hx8W1NcTJg93anG8BH4CDLhLaqEKVZkCJPt2H312oZcDZXGV7juiUjYbvySZLmEF:0"    }  ]}
Its fields
  • monthstringRequired

    YYYY-MM, in UTC.

  • fromstringRequired

    The month's first instant, in UTC.

  • tostringRequired

    The next month's first instant: not included.

  • completebooleanRequired

    False for the current month: its figures are to date.

  • accountsobject[]Required

    One row per credit account.

    • accountstringRequired

      The credit account: acc_...

    • tokenobject | nullRequired

      The token whose AI share lands there.

      • mintstringRequired

        The token's mint address.

      • namestringRequired

        The token's name.

      • symbolstringRequired

        The token's ticker.

    • opening_usdstringRequired

      Its balance as the month began.

    • credited_usdobjectRequired

      Credit that came in, by kind.

      • fee_creditstringRequired

        From the token's payouts.

      • purchasestringRequired

        Bought in USDC.

      • adjustmentstringRequired

        By hand.

    • spent_usdstringRequired

      What its AI calls were charged.

    • closing_usdstringRequired

      Its balance as the month ended, or now.

    • payoutsintegerRequired

      Payouts credited.

    • callsintegerRequired

      Calls charged.

  • totalsobjectRequired

    The accounts together.

    • opening_usdstringRequired

      Dollars, as an exact decimal.

    • credited_usdstringRequired

      Dollars, as an exact decimal.

    • spent_usdstringRequired

      Dollars, as an exact decimal.

    • closing_usdstringRequired

      Dollars, as an exact decimal.

  • linesobject[]Required

    Each credit on its own, and each account's AI spend once a day, oldest first.

    • atstringRequired

      When it happened, in UTC.

    • accountstringRequired

      The credit account: acc_...

    • tokenstring | nullRequired

      The token's symbol.

    • kindstringRequired

      fee_credit, purchase, adjustment or call_charge.

    • amount_usdstringRequired

      Positive for a credit, negative for spend.

    • refstringRequired

      The ledger's reference (payout:<signature>:<event>, purchase:...), or calls:<n> for a day's AI spend.

Errors

A 429 or 503 answer carries Retry-After: wait that many seconds, then send the same request again.

On this page