Concise example scripts showcasing the usage of Tensor's new JS SDKs.
This repository is temporary until all audits are concluded and programs are open-sourced.
To get started, clone or download this repository, navigate to the program folder you want to try out and install the necessary dependencies:
git clone https://github.com/tensor-foundation/SDK-examples.git
cd SDK-examples
cd marketplace
npm install
Afterwards, open common.ts
and fill in:
- your wallet's private key (please use a dedicated burner wallet) to
keypairBytes
- replace
helius_url
with a valid Helius RPC link - if you don't already have one, you can create one for free on Helius' website - this is used for their DAS API to retrieve indexed details for compressed NFTs - (optional) replace
helius_url
for therpc
variable to use a custom RPC connection used for all RPC calls
Now you can run whatever script you like by filling in the arguments of the function you want to execute at the bottom of each corresponding script file and executing the following command afterwards, e.g.:
npx tsx make_collection_bid.ts
If you have any questions or feedback, join our Discord and talk to us in #api-sdk-questions !