api.pinaivu.com is the developer-facing surface: each customer holds
their own API key, and the gateway is intentionally stateless — no
memory layer, no enclave, just a thin proxy in front of the coordinator.
For the end-user chat product with built-in memory, see
chat-relayer API.
Authentication
/v1/chat/completions. Issued per developer via
the gateway’s key-management endpoints.
POST /v1/chat/completions
Request:
node_url, no second call. The
coordinator ran the auction, dispatched the job to the winning node over
libp2p, and waited for the reply before responding.
This single-round-trip shape differs from earlier internal docs that
described a 307-redirect /
node_url flow — the gateway and chat-relayer
both now do the node round trip server-side, so callers never see a
node’s address or a dispatch token.Encrypted mode (optional)
For prompt privacy from the operator, sendclient_x25519_pubkey_hex +
messages_encrypted + messages_nonce instead of plaintext messages,
using an ECDH scheme. Fetch the coordinator’s X25519 key from
GET /enclave_health first. The gateway passes these fields through
untouched.
Other routes (no auth required)
| Route | Purpose |
|---|---|
GET /health | Liveness |
GET /enclave_health | Coordinator pubkey + uptime, proxied |
GET /get_attestation | Raw NSM attestation document |
GET /v1/models | Available models |
GET /v1/nodes | Current peer registry |
What a gateway client must persist
| Value | |
|---|---|
| Identity | own API key (sk-pnv-...) |
| Per-session | session_id, session_key |
On-chain verification
How the response you get back is independently verifiable on Sui, even
though you never see the raw receipt directly