Okay, so you spun up a Stellar node. Good plan. Here’s some valuable info on what do next, specifically how to employ SDKs.
First things First
Stellar is broken down into multiple parts. There are stellar-core and horizon, which allow you to interact with the testnet or mainnet. Using Horizon can be a bit complicated when doing certain calls like operations, that is why there are some Stellar SDKs that make it easy to use stellar-core. All you will need to use the SDK is the IP of the Blockdaemon Stellar Node.
How to find your Horizon node IP
- Login to your Blockdaemon account.
- In the dashboard click on the desired Horizon node.
- In order to generate an IP for the Horizon node it will first need to reach the Ready status in the network page.
- Click the Connect tab.
- Your Horizon IP and port will be listed in the IP section.
Available SDKs
- Java SDK
-
Server server = new Server("https://horizon-testnet.stellar.org");
-
- Ruby SDK
- You will need to provide your Blockdaemon node endpoint URL and auth token (from your dashboard) when creating your StellarSdk.Server object.
-
('https://stellar-test.bdnodes.net/?auth=<CUSTOMER TOKEN>')
- Python SDK
- You will need to provide your Blockdaemon node endpoint URL and auth token (from your dashboard) when creating your StellarSdk.Server object.
-
https://stellar-test.bdnodes.net/?auth=<CUSTOMER TOKEN>
- JS SDK
- You will need to provide your Blockdaemon node endpoint URL and auth token (from your dashboard) when creating your StellarSdk.Server object. For example:
-
var StellarSdk = require('stellar-sdk'); var server = new StellarSdk.Server('https://stellar-test.bdnodes.net/?auth=<CUSTOMER TOKEN>');// get a list of transactions that occurred in ledger 714678, you can change the value in the function server.transactions() .forLedger(714678) .call().then(function(r){ console.log(r); }).catch(function () {console.log("Promise Rejected")});
Note: the example above is using the testnet node. So you should use //stellar-main.bdnodes.net
endpoint URLs and auth in your dashboard