Feed updates
Commodities.HNG7/USDwent liveEquity.US.VXF7went liveEquity.US.VXV6removedCommodities.RSN7/UScwent liveCommodities.CLLX6/USDremovedCrypto.PRL/USDwent liveCommodities.LIZ6/CNYaddedCommodities.LIX6/CNYaddedCommodities.WTIZ7/USDaddedCommodities.WTIX7/USDaddedCommodities.WTIV7/USDaddedCommodities.WTIU7/USDaddedCommodities.WTIQ7/USDaddedCommodities.WTIN7/USDadded
View all
Developer Hub

REST API

On-demand price queries via REST

Base URL

https://pyth-lazer.dourolabs.app

Endpoints

MethodPathAuthDescription
POST/v1/latest_priceYesFetch the latest price for one or more price feeds
POST/v1/priceYesFetch price data at a specific historical timestamp

POST /v1/latest_price

Returns the most recent price data for the requested feeds. The request body follows the same schema as the WebSocket subscribe message — see the Payload Reference for full details.

Request Body

FieldTypeRequiredDescription
channelstringYesSubscription channel. One of: real_time, fixed_rate@50ms, fixed_rate@200ms, fixed_rate@1000ms

Each feed has a minimum supported channel (min_channel), discoverable via /v1/symbols. You must use a channel at or above the feed's min_channel. See Symbology & Reference Data for every field the symbols endpoint returns.

POST /v1/price

Returns price data at a specific historical timestamp.

Request Body

All fields from /v1/latest_price, plus:

FieldTypeRequiredDescription
timestampu64YesUnix timestamp in microseconds. Must be a raw integer — do not quote it.

For the full response schema — including price feed fields, signed payloads, and available properties — see the Payload Reference.

Authentication

POST /v1/latest_price and POST /v1/price require API-key authentication. Pass your Pro API key as a bearer token:

curl -X POST -H "Authorization: Bearer $PRO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"priceFeedIds":[1,2],"properties":["price"],"formats":["solana"],"channel":"fixed_rate@200ms","timestamp":1704067200000000}' \
  "https://pyth-lazer.dourolabs.app/v1/price"

Do not embed your Pro API key in frontend or browser applications. The key must stay server-side. Route requests through your own backend, which injects the Authorization header before forwarding to this API. For browser/frontend apps that cannot hold a secret, see Frontend Authentication.

See Acquire an API Key to obtain a key.

OpenAPI Schema

The REST API is part of the Pyth Pro Router API. The full OpenAPI specification is available at:

Price Updates for the Pyth Core Contracts

To verify prices on a blockchain with the Pyth Core contracts, fetch price updates from Hermes. Choose a Contract explains when to use the Pyth Core contracts.

Hermes takes the same API key and the 32-byte hexadecimal IDs from Price Feed IDs. GET /v2/updates/price/latest returns the latest update for one or more feeds, here BTC/USD and ETH/USD:

curl -H "Authorization: Bearer $PYTH_API_KEY" \
  'https://pyth.dourolabs.app/hermes/v2/updates/price/latest?ids[]=0xe62df6c8b4a85fe1a67db44dc12de5db330f7ac66b72dc658afedf0f4a415b43&ids[]=0xff61491a931112ddf1bd8147cd1b641375f79f5825126d665480874634fd0ace'

binary.data holds the update to submit to a Pyth Core contract, and parsed holds the decoded prices. From TypeScript, getLatestPriceUpdates in HermesClient makes the same request. The Hermes API reference lists every endpoint. To stream updates instead, see Subscribe to Prices.

On this page