You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: pages/benchmarks/index.mdx
+3-3
Original file line number
Diff line number
Diff line change
@@ -18,10 +18,10 @@ Technically, each displayed price corresponds to the Pyth price update published
18
18
19
19
## On-Chain Contracts
20
20
21
-
On-chain contracts can consume benchmark prices using the same pull model as [Pythnet Price Feeds](pythnet-price-feeds.md).
21
+
On-chain contracts can consume benchmark prices using the same pull model as [Pythnet Price Feeds](../price-feeds/price-feed-ids.mdx).
22
22
Integrators can follow these three steps:
23
23
24
-
1. Use the [Hermes](pythnet-price-feeds/hermes) endpoint `/api/get_vaa` to retrieve a signed price update for the desired price feed and time.
24
+
1. Use the [Hermes](pythnet-price-feeds/hermes) endpoint `/v2/updates/price/{price_time}` to retrieve a signed price update for the desired price feed and time.
25
25
This endpoint will return a signed price update, specifically the price update immediately after the queried time.
26
26
This step can be done in either a web frontend or a backend process, depending on who is expected to initiate the transaction.
27
27
2. Pass this price update to your on-chain contract as part of the transaction that needs the benchmark data.
@@ -30,7 +30,7 @@ Integrators can follow these three steps:
30
30
The price update will only be valid if the signatures are correct and the update falls within a user-configured time interval; integrators should set this time interval such that it matches their desired time.
31
31
32
32
Note that this process is similar to the standard process for consuming pull updates.
33
-
The main differences are that users call the `get_vaa` endpoint instead of `latest_vaas`, and the on-chain contract calls `parsePriceFeedUpdates` instead of `updatePriceFeeds`.
33
+
The main differences are that users call the `/v2/updates/price/{price_time}` endpoint instead of `/v2/updates/price/latest`, and the on-chain contract calls `parsePriceFeedUpdates` instead of `updatePriceFeeds`.
34
34
The pyth-crosschain repo has [example code](https://github.com/pyth-network/pyth-crosschain/blob/main/target_chains/ethereum/sdk/js/src/examples/EvmBenchmark.ts) for an integration along the lines above for EVM chains.
0 commit comments