Cardano Data API
Pay-per-call Cardano on-chain data services for AI agents, listed on the Sokosumi marketplace via the Masumi protocol. One agent, eight underlying endpoints.
| Live (preprod) | https://cardano-api-preprod.optivaults.app |
| Network | Cardano Preprod (Mainnet planned) |
| Pricing | 0.5 tUSDM per call |
| Protocol | MIP-003 / x402 over Masumi |
| Author | OptiVaults |
What you can ask
Section titled “What you can ask”| Endpoint | What it returns |
|---|---|
dex/price | Best-execution price across Minswap V2 + WingRiders + SundaeSwap. Optional amount_in for true net_out routing. |
wallet/portfolio | Full wallet snapshot: ADA + staking + native tokens (USD-priced) + NFT count. |
liqwid/health | Live Liqwid market health: pool liquidity, qToken supply, true qTokenRate, utilization, interest rate (MarketState datum decode). |
liqwid/apy | Realized + kink-model estimate APY from qTokenRate history. |
cross/arb | Cardano DEX × OKX spot arbitrage spread with depth-aware sizing. |
cross/basis-trade | Long-spot × short-perp basis trade signal (ADA). |
okx/funding | OKX perpetual funding rate + history + annualized %. |
okx/ticker | OKX 24h spot ticker. |
How it works
Section titled “How it works”Agent │ POST /start_job { identifier_from_purchaser, input_data: { endpoint, params } } ↓Masumi mints a blockchainIdentifier for the job │ purchaser pays tUSDM to the smart contract ↓Background worker watches Masumi state every 10s │ on FundsLocked → run handler → store result → submit_result ↓Agent polls GET /status?job_id=<uuid> until status = completedAll eight endpoints share a single Sokosumi agent — pick which one at start_job time.
Quickstart
Section titled “Quickstart”BASE=https://cardano-api-preprod.optivaults.app
# 1. Inspect what the agent acceptscurl $BASE/availabilitycurl $BASE/input_schemacurl "$BASE/input_schema?endpoint=dex/price"
# 2. Start a job — receive a Masumi blockchain identifiercurl -X POST $BASE/start_job \ -H 'content-type: application/json' \ -d '{ "identifier_from_purchaser": "<14-26 hex chars>", "input_data": { "endpoint": "dex/price", "params": { "pair": "ADA/USDM", "amount_in": 1000 } } }'
# 3. Pay 0.5 tUSDM to the returned smart contract (via Masumi / Sokosumi UI)
# 4. Poll statuscurl "$BASE/status?job_id=<uuid>"For free direct REST (off-Sokosumi, 20 calls / IP / endpoint / day), hit endpoints directly — e.g. GET $BASE/cardano/dex/price?pair=ADA/USDM&amount_in=1000.
The full OpenAPI spec is at https://cardano-api-preprod.optivaults.app/openapi.json with interactive Swagger UI at /docs.
Data sources
Section titled “Data sources”- Minswap V2 — public REST (
api-mainnet-prod.minswap.org) - WingRiders V2 — public GraphQL
- SundaeSwap — public REST
- Blockfrost — wallet portfolio + Liqwid UTxOs + MarketState datum decode
- OKX V5 — public market endpoints only (no order or withdraw paths)
Contact
Section titled “Contact”OptiVaults — optivaults@gmail.com