Go to file
gallynaut d049b53fe7
chore: pull monorepo changes (#173)
* Project import generated by Copybara.

GitOrigin-RevId: 5aae5e514cbb815872967735716823f422a6316a

* chore: Update pnpm lockfile

---------

Co-authored-by: Copybara <copybara@example.com>
Co-authored-by: gallynaut <gallynaut@users.noreply.github.com>
2023-11-28 17:15:32 -07:00
.changeset wip 2023-06-13 15:00:48 -06:00
.docs chore: removed deprecated javascript packages 2023-05-30 12:49:56 -06:00
.github ci 2023-08-07 11:12:43 -06:00
.vscode fix: removed oracle import from solana.js for browser compatibility 2023-03-23 09:28:41 -06:00
examples chore: pull monorepo changes (#173) 2023-11-28 17:15:32 -07:00
javascript chore: pull monorepo changes (#170) 2023-11-28 10:43:30 -07:00
rust chore: pull monorepo changes (#173) 2023-11-28 17:15:32 -07:00
scripts add new examples 2023-06-19 11:26:21 -06:00
.gitignore added turborepo 2023-06-13 11:58:29 -06:00
.npmrc chore: lockfile 2023-06-01 12:13:14 -06:00
LICENSE cleaned up package.json, tsconfig.json, and misc build configs 2022-05-25 12:38:29 -06:00
README.md update lockfile 2023-05-25 13:21:25 -06:00
package.json chore: package.json metadata 2023-08-11 10:07:24 -06:00
pnpm-lock.yaml chore: pull monorepo changes (#173) 2023-11-28 17:15:32 -07:00
pnpm-workspace.yaml add new examples 2023-06-19 11:26:21 -06:00
tsconfig.json add new examples 2023-06-19 11:26:21 -06:00
turbo.json add new examples 2023-06-19 11:26:21 -06:00

README.md

Switchboard Logo

Switchboard x Solana

A collection of libraries and examples for interacting with Switchboard V2 on Solana.

Test Status Anchor Test Status

Crates.io NPM Badge

Getting Started

To get started, clone the sbv2-solana repository.

git clone https://github.com/switchboard-xyz/sbv2-solana

Then install the dependencies

cd sbv2-solana
pnpm install
pnpm build

Addresses

The following addresses can be used with the Switchboard deployment on Solana

Mainnet

Account Address
Program ID SW1TCH7qEPTdLsDHRgPuMQjbQxKdH2aBStViMFnt64f
Program Authority 2NvGRFswVx3GXxURNSfjbsWY4iP1ufj8LvAKJWGXSm4D
IdlAddress Fi8vncGpNKbq62gPo56G4toCehWNy77GgqGkTaAF5Lkk
Permissioned Queue 3HBb2DQqDfuMdzWxNk1Eo9RTMkFYmuEAd32RiLKn9pAn
Permissionless Queue 5JYwqvKkqp35w8Nq3ba4z1WYUeJQ1rB36V8XvaGp6zn1

Devnet

Account Address
Program ID SW1TCH7qEPTdLsDHRgPuMQjbQxKdH2aBStViMFnt64f
Program Authority 2KgowxogBrGqRcgXQEmqFvC3PGtCu66qERNJevYW8Ajh
IdlAddress Fi8vncGpNKbq62gPo56G4toCehWNy77GgqGkTaAF5Lkk
Permissioned Queue PeRMnAqNqHQYHUuCBEjhm1XPeVTh4BxjY4t4TPan1pG
Permissionless Queue uPeRMdfPmrPqgRWSrjAnAkH78RqAhe5kXoW6vBYRqFX

Clients

Lang Name Description
Rust switchboard-v2 A Rust library to interact with Switchboard V2 accounts on Solana.
Javascript @switchboard-xyz/solana.js A Typescript client to interact with Switchboard on Solana.

Examples

Lang Name Description
Rust native-feed-parser Read a Switchboard feed using Solana's native program library
Anchor anchor-feed-parser Read a Switchboard feed using Anchor
Anchor anchor-history-parser Read a data feeds history buffer and get the closest historical sample to a given timestamp
Anchor anchor-vrf-parser Read a Switchboard VRF account and make a Cross Program Invocation (CPI) to request a new randomness value
Anchor anchor-vrf-lite-parser Read a Switchboard VRF Lite account and make a Cross Program Invocation (CPI) to request a new randomness value
Anchor anchor-buffer-parser Read a Switchboard buffer relayer using Anchor
Javascript javascript-feed-walkthrough Create a private Switchboard queue and oracle and fulfill your own oracle updates

Troubleshooting

  1. File a GitHub Issue
  2. Ask a question in Discord #dev-support