Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion examples/blocksize-bidask/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Deployments:
- [Testnet](https://testnet.explorer.seda.xyz/oracle-programs/0befce19a31a9bb01ba0c3ed04d134498b0e55f356590103e8bd7f20a02ac582)
<!-- - [Mainnet](https://explorer.seda.xyz/oracle-programs/) -->
- [Mainnet](https://explorer.seda.xyz/oracle-programs/d5dff6a1ec7880fbf3267d8ffd5d787822d9f53e1e4989f3da88520bce43d370)


## Overview
Expand Down
11 changes: 3 additions & 8 deletions examples/blocksize-bidask/src/execution_phase.rs
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
use anyhow::{Result, anyhow};
#[cfg(any(feature = "testnet", feature = "mainnet"))]
use seda_sdk_rs::{Process, elog, log, proxy_http_fetch};
use seda_sdk_rs::{HttpFetchOptions, Process, elog, log, proxy_http_fetch};

#[cfg(feature = "testnet")]
const API_URL: &str = "https://seda-proxy.blocksize.dev/proxy/bidask/";
#[cfg(feature = "testnet")]
const PROXY_PUBLIC_KEY: &str = "029a10be2771c4933b1a0f4d5efa9d6cdfbd05b0b1749587fc1b1771394490d29b";

#[cfg(feature = "mainnet")]
const API_URL: &str = "";
const API_URL: &str = "https://seda-proxy.blocksize.capital/proxy/bidask/";
#[cfg(feature = "mainnet")]
const PROXY_PUBLIC_KEY: &str = "";
const PROXY_PUBLIC_KEY: &str = "03748c38f98a18b0ca8da9a33ede357f6502b2f5ea3c42c540cca54458a1ed340e";

#[cfg(not(any(feature = "testnet", feature = "mainnet")))]
pub fn execution_phase() -> Result<()> {
Expand Down Expand Up @@ -41,11 +41,6 @@ const VALID_FIELDS: &[&str] = &[
// return a uint256[] abi encoded in tally
#[cfg(any(feature = "testnet", feature = "mainnet"))]
pub fn execution_phase() -> Result<()> {
use seda_sdk_rs::HttpFetchOptions;

#[cfg(feature = "mainnet")]
unimplemented!("Mainnet not yet supported");

// Expected to be in the format "symbol" (e.g., "ETHUSD" or "BTCUSD").
// Optionally followed by the field names (e.g., "agg_ask_price,agg_mid_price") separated by a hyphen(-).
let dr_inputs_raw = String::from_utf8(Process::get_inputs())?;
Expand Down
2 changes: 1 addition & 1 deletion examples/blocksize-vwap/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Deployments:
- [Testnet](https://testnet.explorer.seda.xyz/oracle-programs/5f4b8b833396c5aa2c705f2f67029f820cad81fe786b68f59aa43577a3323526)
<!-- - [Mainnet](https://explorer.seda.xyz/oracle-programs/) -->
- [Mainnet](https://explorer.seda.xyz/oracle-programs/727f1dd64209ceb66db3dd80ac5ac7cd7c767b13ecbdfab91c4a8bd30743bed7)


## Overview
Expand Down
7 changes: 2 additions & 5 deletions examples/blocksize-vwap/src/execution_phase.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ const API_URL: &str = "https://seda-proxy.blocksize.dev/proxy/vwap/";
const PROXY_PUBLIC_KEY: &str = "029a10be2771c4933b1a0f4d5efa9d6cdfbd05b0b1749587fc1b1771394490d29b";

#[cfg(feature = "mainnet")]
const API_URL: &str = "";
const API_URL: &str = "https://seda-proxy.blocksize.capital/proxy/vwap/";
#[cfg(feature = "mainnet")]
const PROXY_PUBLIC_KEY: &str = "";
const PROXY_PUBLIC_KEY: &str = "03748c38f98a18b0ca8da9a33ede357f6502b2f5ea3c42c540cca54458a1ed340e";

#[cfg(not(any(feature = "testnet", feature = "mainnet")))]
pub fn execution_phase() -> Result<()> {
Expand All @@ -30,9 +30,6 @@ const VALID_FIELDS: &[&str] = &["price", "size", "volume", "ts"];

#[cfg(any(feature = "testnet", feature = "mainnet"))]
pub fn execution_phase() -> Result<()> {
#[cfg(feature = "mainnet")]
unimplemented!("Mainnet not yet supported");

// Expected to be in the format "symbol" (e.g., "ETHUSD" or "BTCUSD").
// Optionally followed by the field names (e.g., "price,size") separated by a hyphen(-).
let dr_inputs_raw = String::from_utf8(Process::get_inputs())?;
Expand Down
Loading