Browse Source

Merge pull request #3195 from pyth-network/fix-links

chore(developer-hub): price feeds core fix
Nidhi Singh 1 week ago
parent
commit
8cc8430a3d

+ 2 - 2
apps/developer-hub/content/docs/price-feeds/core/api-instances-and-providers/hermes.mdx

@@ -9,7 +9,7 @@ import { Callout } from "fumadocs-ui/components/callout";
 Hermes is an open-source service that listens to the Pythnet and the Wormhole Network for Pyth price updates, and
 serves them via a convenient web API.
 
-Hermes allows users to easily [fetch price updates](../fetch-price-updates.mdx) via a REST API, or subscribe to server-side streaming
+Hermes allows users to easily [fetch price updates](../fetch-price-updates) via a REST API, or subscribe to server-side streaming
 updates.
 
 ## Public Endpoints
@@ -49,4 +49,4 @@ The following node providers offer Hermes:
 The Pyth Data Association provides a Helm chart for running Hermes in
 [charts](https://github.com/pyth-network/charts/tree/main/charts/hermes) repository. Please refer to the chart's readme
 for the configuration values.
-You will need a Pythnet RPC to run Hermes; see the [guide for accessing a Pythnet RPC](pythnet-rpc.mdx).
+You will need a Pythnet RPC to run Hermes; see the [guide for accessing a Pythnet RPC](./pythnet-rpc).

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/best-practices.mdx

@@ -92,7 +92,7 @@ To expand upon the first option, it is recommended to use the confidence interva
 
 The same principle would apply if you wrote a derivative contract. If someone wants to open a derivative contract with you, you would value their collateral at the lower price. However, if you were deciding whether someone's margin limits were violated, you could value their outstanding leveraged position at the higher price. If a contract needs to be settled at a price, you could take approaches such as the following:
 
-1. Using Pyth's exponential moving average price, which represents estimates of the average price of the asset over a specified time period (e.g., over the past 1 hour). The exponential moving average price is computed such that it lessens the influence of prices with wide confidence intervals. You may find more details in [EMA Price Aggregation](./how-pyth-works/ema-price-aggregation.mdx).
+1. Using Pyth's exponential moving average price, which represents estimates of the average price of the asset over a specified time period (e.g., over the past 1 hour). The exponential moving average price is computed such that it lessens the influence of prices with wide confidence intervals. You may find more details in [EMA Price Aggregation](./how-pyth-works/ema-price-aggregation).
 2. Using the aggregate price, which is Pyth's best estimate of the price at a single point in time. The quality of this estimate depends on the width of the confidence interval at settlement time and on occasion, it may be imprecise. However, it is the best you can do with Pyth data if you need a single price at that exact point in time.
 3. Defining the contract to depend on confidence. For example, you could create an option that refunds the option premium to the buyer (so both sides of the transaction are even) if the strike price is within the confidence interval at settlement time. You could also create a contract that delayed settlement until the confidence interval was sufficiently small. If you choose this second option, you should ensure that your contract is guaranteed to eventually settle even if the confidence interval never narrows.
 

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/contract-addresses/evm.mdx

@@ -203,4 +203,4 @@ Pyth is available on the following network using Pyth Beta price sources:
 
 ## Price Feed IDs
 
-The price feed IDs for EVM chains are available [here](../price-feeds.mdx)
+The price feed IDs for EVM chains are available [here](../price-feeds)

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/contract-addresses/pythnet.mdx

@@ -11,7 +11,7 @@ import { Callout } from "fumadocs-ui/components/callout";
   which is used to construct and deliver Pyth prices to other blockchains. If
   you are building an application on EVM, Solana, SVM, or another chain, you
   should use the Pyth program deployed on your target chain instead. Please
-  refer to the [Contract Addresses](/price-feeds/contract-addresses) page and
+  refer to the [Contract Addresses](/price-feeds/core/contract-addresses) page and
   select your specific blockchain environment.
 </Callout>
 

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/create-your-first-pyth-app/evm/part-1.mdx

@@ -565,4 +565,4 @@ contract MyFirstPythContractTest is Test {
 
 </Steps>
 
-Check out [Part 2](./part-2.mdx) to learn how to deploy our contract to OP-sepolia testnet and fetch prices using hermes-client.
+Check out [Part 2](./part-2) to learn how to deploy our contract to OP-sepolia testnet and fetch prices using hermes-client.

+ 2 - 2
apps/developer-hub/content/docs/price-feeds/core/derive-cross-rate.mdx

@@ -93,11 +93,11 @@ You may find these additional resources helpful.
 
 #### How to use real-time data in EVM contracts
 
-The [How to use real-time data in EVM contracts](./use-real-time-data/evm.mdx) guide provides a step-by-step guide on how to use real-time data in EVM contracts.
+The [How to use real-time data in EVM contracts](./use-real-time-data/pull-integration/evm) guide provides a step-by-step guide on how to use real-time data in EVM contracts.
 
 #### Price Feed IDs
 
-The [Price Feed IDs](./price-feeds.mdx) page lists the price feed IDs for each asset supported by Pyth.
+The [Price Feed IDs](./price-feeds) page lists the price feed IDs for each asset supported by Pyth.
 
   </Tab>
 

+ 2 - 2
apps/developer-hub/content/docs/price-feeds/core/fetch-price-updates.mdx

@@ -8,9 +8,9 @@ import { Callout } from "fumadocs-ui/components/callout";
 
 The following guide explains how to fetch price updates.
 Price updates can be submitted to the Pyth Price Feeds contract to update the on-chain price.
-Please see [What is a Pull Oracle?](/price-feeds/pull-updates) to learn more.
+Please see [What is a Pull Oracle?](/price-feeds/core/pull-updates) to learn more.
 
-Price updates are served from [Hermes](/price-feeds/how-pyth-works/hermes), which
+Price updates are served from [Hermes](/price-feeds/core/how-pyth-works/hermes), which
 provides three different ways to fetch price updates:
 
 1. [REST API](#rest-api)

+ 2 - 2
apps/developer-hub/content/docs/price-feeds/core/index.mdx

@@ -35,7 +35,7 @@ Pyth Core provides **two ways** to integrate and consume real-time price data on
   <Card
     icon={<ClockCountdown size={12.5} />}
     title="Integrate Push Updates"
-    href="/price-feeds/core/use-real-time-data/push-updates"
+    href="/price-feeds/core/use-real-time-data/push-integration"
   >
     {" "}
     Consume Pyth real-time prices without pulling them explicitly.
@@ -94,6 +94,6 @@ settlement and backtesting:
   <Card
     icon={<CloudArrowUp size={12.5} />}
     title="Push Feeds"
-    href="/price-feeds/core/push-updates"
+    href="/price-feeds/core/push-feeds"
   />
 </Cards>

+ 2 - 2
apps/developer-hub/content/docs/price-feeds/core/migrate-an-app-to-pyth/chainlink.mdx

@@ -100,7 +100,7 @@ Please see the [Chainlink Migration Example](https://github.com/pyth-network/pyt
 
 Chainlink-compatible applications typically expect on-chain price feeds to update on a schedule.
 When migrating to Pyth, apps may need to schedule these price updates themselves.
-This step is required because Pyth is a pull oracle; see [What is a pull oracle?](/price-feeds/core/pull-updates.mdx) to learn more about this topic.
+This step is required because Pyth is a pull oracle; see [What is a pull oracle?](/price-feeds/core/pull-updates) to learn more about this topic.
 
-The [Push Feeds](/price-feeds/core/push-feeds.mdx) page shows a list of feeds that have scheduled on-chain updates.
+The [Push Feeds](/price-feeds/core/push-feeds) page shows a list of feeds that have scheduled on-chain updates.
 If the feeds your application needs are not on this list, see [Schedule Price Updates](/price-feeds/core/schedule-price-updates) for several options to solve this problem.

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/price-feeds/index.mdx

@@ -36,4 +36,4 @@ Refer to the [Price Feed IDs](/price-feeds/core/price-feeds/price-feed-ids) page
 
 On Solana, each feed additionally has a collection of **price feed accounts** containing the feed's data.
 The addresses of these accounts are programmatically derived from the feed id and a shard id, which is simply a 16-bit number.
-See [How to Use Real-Time Data on Solana](./use-real-time-data/solana#price-feed-accounts) for more information on price feed accounts.
+See [How to Use Real-Time Data on Solana](../use-real-time-data/pull-integration/solana#price-feed-accounts) for more information on price feed accounts.

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/publish-data/index.mdx

@@ -65,7 +65,7 @@ Data providers can publish data to the network using the [pyth-agent](https://gi
 This package abstracts away all of the communication with the underlying blockchain and exposes a simple JSON RPC interface for submitting price data.
 Please see the [README](https://github.com/pyth-network/pyth-agent) of that package for instructions on using it.
 This software requires you to configure both the keypair and validators from the previous steps in order to run.
-Please also see the [JSON RPC API documentation](publish-data/pyth-client-websocket-api.md).
+Please also see the [JSON RPC API documentation](./pyth-client-websocket-api).
 Finally, the [example publisher](https://github.com/pyth-network/example-publisher) is a fully-worked example of how to integrate with the pyth-agent API.
 
 </Step>

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/pull-updates.mdx

@@ -55,4 +55,4 @@ Push oracles and pull oracles require applications to integrate in different way
 With a push oracle, applications typically read the current price out of a smart contract.
 Since the push oracle periodically updates the price, the application can assume the data in the smart contract is (reasonably) fresh.
 With a pull oracle, applications need to update the on-chain price before reading it.
-Developers using Pyth can refer to [How to Use Real-Time Price Data](/price-feeds/use-real-time-data) to learn how to perform these steps.
+Developers using Pyth can refer to [How to Use Real-Time Price Data](/price-feeds/core/use-real-time-data) to learn how to perform these steps.

+ 1 - 1
apps/developer-hub/content/docs/price-feeds/core/troubleshoot/evm.mdx

@@ -28,7 +28,7 @@ To resolve this issue:
 
 - Update the prices by calling [`updatePriceFeeds()`](https://api-reference.pyth.network/price-feeds/evm/updatePriceFeeds)
   by passing the latest updateData from [Hermes](https://hermes.pyth.network/docs/#/rest/latest_vaas).
-- Check the entered [price feed id](../price-feeds.mdx) and [pyth-contract address](https://docs.pyth.network/price-feeds/contract-addresses/evm) to make sure they are correct.
+- Check the entered [price feed id](../price-feeds) and [pyth-contract address](https://docs.pyth.network/price-feeds/contract-addresses/evm) to make sure they are correct.
 
 #### updatePriceFeeds() reverts with `InsufficientFee()` or `0x025dbdd4` error
 

+ 5 - 5
apps/developer-hub/content/docs/price-feeds/core/use-pyth-for-morpho.mdx

@@ -26,9 +26,9 @@ Please see [What is a Pull Oracle?](/price-feeds/core/pull-updates) to learn mor
 Consult [Schedule Price Updates](/price-feeds/core/schedule-price-updates) guide for more information.
 
 The Pyth Data Association sponsors regular on-chain updates for some price feeds.
-See [Push Feeds](./push-feeds.mdx) for the current list of feeds and their update parameters.
+See [Push Feeds](./push-feeds) for the current list of feeds and their update parameters.
 
-If you don't find relevant price IDs in the [Push Feeds](./push-feeds.mdx) list, please contact the Pyth team [here](https://tally.so/r/nGz2jj) to run the Price Pusher for the price feed you need.
+If you don't find relevant price IDs in the [Push Feeds](./push-feeds) list, please contact the Pyth team [here](https://tally.so/r/nGz2jj) to run the Price Pusher for the price feed you need.
 
 </Step>
 <Step>
@@ -43,14 +43,14 @@ If you are deploying, please make sure to update the README.md file with the new
 
 To do so, run the [`MorphoPythOracleDeploy.s.sol`](https://github.com/pyth-network/pyth-morpho-wrapper/blob/main/scripts/MorphoPythOracleDeploy.s.sol) script with the following environment variables set:
 
-- `PYTH_ADDRESS`: The Pyth contract address. This is the address of the Pyth contract deployed on the chain. You can find the address of the Pyth contract for each chain [here](./contract-addresses/evm.md).
+- `PYTH_ADDRESS`: The Pyth contract address. This is the address of the Pyth contract deployed on the chain. You can find the address of the Pyth contract for each chain [here](./contract-addresses/evm).
 - `BASE_VAULT`: The ERC4626 token vault for the base asset.
 - `BASE_VAULT_CONVERSION_SAMPLE`: A sample amount for converting base vault units.
-- `BASE_FEED1`, `BASE_FEED2`: Pyth price feed ids for the base asset. You can find the price feed ids for each asset in our [price feeds directory](./price-feeds.mdx).
+- `BASE_FEED1`, `BASE_FEED2`: Pyth price feed ids for the base asset. You can find the price feed ids for each asset in our [price feeds directory](./price-feeds).
 - `BASE_TOKEN_DECIMALS`: Decimal precision of the base asset.
 - `QUOTE_VAULT`: The ERC4626 token vault for the quote asset.
 - `QUOTE_VAULT_CONVERSION_SAMPLE`: A sample amount for converting quote vault units.
-- `QUOTE_FEED1`, `QUOTE_FEED2`: Pyth price feed ids for the quote asset. You can find the price feed ids for each asset in our [price feeds directory](./price-feeds.mdx).
+- `QUOTE_FEED1`, `QUOTE_FEED2`: Pyth price feed ids for the quote asset. You can find the price feed ids for each asset in our [price feeds directory](./price-feeds).
 - `QUOTE_TOKEN_DECIMALS`: Decimal precision of the quote asset.
 - `PRICE_FEED_MAX_AGE`: The maximum age of the price feed in seconds. Note: This adds an extra safety net to avoid using stale prices.
 - `SALT`: A unique identifier to create deterministic addresses for deployed oracles.