Skip to main content
The gateway accepts an execution request for a feed, dispatches a signing round to the deterministically selected node set for the current registry version, and returns a completed DataUpdateResult — a payload ready to submit to any chain’s verifier. The recommended access path is the SDK gateway client (sdk.gateway), which handles auth, optional context reuse, and struct assembly. For raw HTTP integration, use the Gateway HTTP API (OpenAPI reference with interactive playground).

Base URLs

Also exported as DEFAULT_GATEWAY_ENDPOINT from @molpha/sdk.

requestSignedData

Runs a live round against the current on-chain registry version and resolves with a DataUpdateResult. The SDK may take feedId for local context, but the HTTP gateway derives feed identity from (consumerAuthority|payer, apiConfig, signaturesRequired) and never trusts a client-supplied feed id. Live gateway rounds return fresh: true. Under the hood this calls POST /v1/round/execute for subscription-backed access, or POST /v1/agent/execute for x402 agent access. Execution is authenticated with an authSig produced by the wallet’s signAuthMessage (or derived from a keypair-backed Wallet.payer). The gateway requires a valid 64-byte Ed25519 authSig — all-zero signatures are rejected.

Private APIs

MolphaSDK wires verifyNodeKeys to solana.verifyNodeKeysForPrivateApi, which checks gateway node encryption keys against on-chain Node accounts before secrets are encrypted.

prepareContext

Fetches registry version, redundancy buffer, and the node set (via GET /v1/nodes), and returns a RoundContext. Pass it back via context to skip those prelude fetches on subsequent rounds. There is no automatic client-side cache — reuse is explicit.

Response shape

The flat DataUpdateResult maps 1:1 onto every chain’s verifier structs via buildEvmVerifierArgs / buildStarknetVerifierArgs, or directly into Solana’s SubmitDataUpdateArgs:

HTTP gateway notes

  • Authentication: subscription rounds use authSig over RequestAuth; agent rounds use agent_request_auth_sig over AgentRequestAuth. See the Gateways guide for hash definitions.
  • Freshness: live execute responses set fresh: true. To read a previously submitted Solana value without a new round, read the Feed account.
  • Registry: pass prepareContext(feedId) result as context to reuse registry version, redundancy buffer, and nodes across rounds.
  • Agent status: GET /v1/agent/{payer}/status returns advisory escrow state for x402 flows.