From cf4ce9778e7203f4f7ff2082da4ea24a7749de0e Mon Sep 17 00:00:00 2001 From: Ali Behjati Date: Thu, 27 Feb 2025 13:57:58 +0100 Subject: [PATCH 1/3] chore: add iota network --- pages/price-feeds/contract-addresses/sui.mdx | 9 ++++++ pages/price-feeds/use-real-time-data/sui.mdx | 33 ++++++++++++++------ 2 files changed, 33 insertions(+), 9 deletions(-) diff --git a/pages/price-feeds/contract-addresses/sui.mdx b/pages/price-feeds/contract-addresses/sui.mdx index 39a80d5b..d0f9c90c 100644 --- a/pages/price-feeds/contract-addresses/sui.mdx +++ b/pages/price-feeds/contract-addresses/sui.mdx @@ -13,6 +13,15 @@ Pyth is currently available on the following sui-based chains: | Wormhole State ID | [`0xaeab97f96cf9877fee2883315d459552b2b921edc16d7ceac6eab944dd88919c`](https://explorer.sui.io/object/0xaeab97f96cf9877fee2883315d459552b2b921edc16d7ceac6eab944dd88919c) | | Wormhole Package ID | [`0x5306f64e312b581766351c07af79c72fcb1cd25147157fdc2f8ad76de9a3fb6a`](https://explorer.sui.io/object/0x5306f64e312b581766351c07af79c72fcb1cd25147157fdc2f8ad76de9a3fb6a) | +#### IOTA testnet + +| Name | Address | +| ------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| Pyth State ID | [`0x68dda579251917b3db28e35c4df495c6e664ccc085ede867a9b773c8ebedc2c1`](https://explorer.rebased.iota.org/object/0x68dda579251917b3db28e35c4df495c6e664ccc085ede867a9b773c8ebedc2c1?network=testnet) | +| Pyth Package ID | [`0x23994dd119480ea614f7623520337058dca913cb1bb6e5d8d51c7b067d3ca3bb`](https://explorer.rebased.iota.org/object/0x23994dd119480ea614f7623520337058dca913cb1bb6e5d8d51c7b067d3ca3bb?network=testnet) | +| Wormhole State ID | [`0x8bc490f69520a97ca1b3de864c96aa2265a0cf5d90f5f3f016b2eddf0cf2af2b`](https://explorer.rebased.iota.org/object/0x8bc490f69520a97ca1b3de864c96aa2265a0cf5d90f5f3f016b2eddf0cf2af2b?network=testnet) | +| Wormhole Package ID | [`0xfca58c557f09cddb7930588c4e2a4edbe3cdded1ac1ed2270aa2dfa8d2b9ae0d`](https://explorer.rebased.iota.org/object/0xfca58c557f09cddb7930588c4e2a4edbe3cdded1ac1ed2270aa2dfa8d2b9ae0d?network=testnet) | + ### Beta channel #### Sui Testnet diff --git a/pages/price-feeds/use-real-time-data/sui.mdx b/pages/price-feeds/use-real-time-data/sui.mdx index 1638c00b..562fd7cc 100644 --- a/pages/price-feeds/use-real-time-data/sui.mdx +++ b/pages/price-feeds/use-real-time-data/sui.mdx @@ -8,7 +8,7 @@ This guide explains how to use real-time Pyth data in Sui applications. Use the following dependency in your `Move.toml` file to use the latest Pyth Sui package and its dependencies: - + ```sh copy [dependencies.Pyth] @@ -50,21 +50,36 @@ rev = "041c5f2bae2fe52079e44b70514333532d69f4e6" ```` + +[dependencies.Pyth] +git = "https://github.com/pyth-network/pyth-crosschain.git" +subdir = "target_chains/sui/contracts" +rev = "sui-contract-iota-testnet" + +[dependencies.Wormhole] +git = "https://github.com/pyth-network/pyth-crosschain.git" +subdir = "target_chains/sui/contracts/vendor/wormhole_iota_testnet/wormhole" +rev = "sui-contract-iota-testnet" + +[dependencies.Iota] +git = "https://github.com/iotaledger/iota.git" +subdir = "crates/iota-framework/packages/iota-framework" +rev = "751c23caf24efd071463b9ffd07eabcb15f44f31" + + + Pyth also provides a javascript SDK to construct transaction blocks that update price feeds: - + - ```sh copy - npm install --save @pythnetwork/pyth-sui-js - ``` + ```sh copy # NPM npm install --save @pythnetwork/pyth-sui-js # Yarn yarn add + @pythnetwork/pyth-sui-js ``` - ```sh copy - yarn add @pythnetwork/pyth-sui-js -```` - + ```sh copy # NPM npm install --save @pythnetwork/pyth-iota-js # Yarn yarn + add @pythnetwork/pyth-iota-js ```` From ab9bc114e1ed3ed272c43332e088560f08f9c9d6 Mon Sep 17 00:00:00 2001 From: Ali Behjati Date: Thu, 27 Feb 2025 14:03:35 +0100 Subject: [PATCH 2/3] fix: add code block --- pages/price-feeds/use-real-time-data/sui.mdx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pages/price-feeds/use-real-time-data/sui.mdx b/pages/price-feeds/use-real-time-data/sui.mdx index 562fd7cc..85f0c315 100644 --- a/pages/price-feeds/use-real-time-data/sui.mdx +++ b/pages/price-feeds/use-real-time-data/sui.mdx @@ -51,6 +51,8 @@ rev = "041c5f2bae2fe52079e44b70514333532d69f4e6" + +```sh copy [dependencies.Pyth] git = "https://github.com/pyth-network/pyth-crosschain.git" subdir = "target_chains/sui/contracts" @@ -65,6 +67,7 @@ rev = "sui-contract-iota-testnet" git = "https://github.com/iotaledger/iota.git" subdir = "crates/iota-framework/packages/iota-framework" rev = "751c23caf24efd071463b9ffd07eabcb15f44f31" +``` From 1f7d97024dcee7aa5baa031dda1c11d1437cc8fc Mon Sep 17 00:00:00 2001 From: Ali Behjati Date: Thu, 27 Feb 2025 14:15:15 +0100 Subject: [PATCH 3/3] fix: fix --- pages/price-feeds/use-real-time-data/sui.mdx | 21 +++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/pages/price-feeds/use-real-time-data/sui.mdx b/pages/price-feeds/use-real-time-data/sui.mdx index 85f0c315..ae18f58c 100644 --- a/pages/price-feeds/use-real-time-data/sui.mdx +++ b/pages/price-feeds/use-real-time-data/sui.mdx @@ -70,19 +70,30 @@ rev = "751c23caf24efd071463b9ffd07eabcb15f44f31" ``` - Pyth also provides a javascript SDK to construct transaction blocks that update price feeds: - ```sh copy # NPM npm install --save @pythnetwork/pyth-sui-js # Yarn yarn add - @pythnetwork/pyth-sui-js ``` + ```sh + # NPM + npm install --save @pythnetwork/pyth-sui-js + + # Yarn + yarn add @pythnetwork/pyth-sui-js + ``` + - ```sh copy # NPM npm install --save @pythnetwork/pyth-iota-js # Yarn yarn - add @pythnetwork/pyth-iota-js ```` + ```sh + # NPM + npm install --save @pythnetwork/pyth-iota-js + + # Yarn + yarn add @pythnetwork/pyth-iota-js + ``` +