All URIs are relative to https://api.blockchainapi.com/v1
Method | HTTP request | Description |
---|---|---|
solanaGetAccount | GET /solana/account/{network}/{public_key} | Get the details of an account on Solana |
solanaGetAccountIsCandyMachine | GET /solana/account/{network}/{public_key}/is_candy_machine | Get if account is candy machine |
solanaGetAccountIsNFT | GET /solana/account/{network}/{public_key}/is_nft | Get if account is NFT |
Account solanaGetAccount(network, publicKey)
Get the details of an account on Solana
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-account/get-account\" target="_blank">See examples (Python, JavaScript)</a>. Get the details of an account on Solana. Learn more about accounts <a href="https://docs.solana.com/developing/programming-model/accounts\" target="_blank">here</a>. `Cost: 0.25 Credit` (<a href="#section/Pricing">See Pricing</a>)
import theblockchainapi from 'theblockchainapi';
let defaultClient = theblockchainapi.ApiClient.instance;
// Configure API key authorization: APIKeyID
let APIKeyID = defaultClient.authentications['APIKeyID'];
APIKeyID.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APIKeyID.apiKeyPrefix = 'Token';
// Configure API key authorization: APISecretKey
let APISecretKey = defaultClient.authentications['APISecretKey'];
APISecretKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APISecretKey.apiKeyPrefix = 'Token';
let apiInstance = new theblockchainapi.SolanaAccountApi();
let network = mainnet-beta; // String | The network ID (devnet, mainnet-beta)
let publicKey = EEr5yQpNXf7Bru6Rt5podx56HGW9CEehXqgRGh2wa71w; // String | The public key of the account
apiInstance.solanaGetAccount(network, publicKey).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
network | String | The network ID (devnet, mainnet-beta) | |
publicKey | String | The public key of the account |
- Content-Type: Not defined
- Accept: application/json
AccountIsCandyMachine solanaGetAccountIsCandyMachine(network, publicKey)
Get if account is candy machine
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-account/get-is-candy-machine\" target="_blank">See examples (Python, JavaScript)</a>. Determine whether or not a public key address corresponds to a candy machine ID or candy machine configuration. `Cost: 1 Credit` (<a href="#section/Pricing">See Pricing</a>)
import theblockchainapi from 'theblockchainapi';
let defaultClient = theblockchainapi.ApiClient.instance;
// Configure API key authorization: APIKeyID
let APIKeyID = defaultClient.authentications['APIKeyID'];
APIKeyID.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APIKeyID.apiKeyPrefix = 'Token';
// Configure API key authorization: APISecretKey
let APISecretKey = defaultClient.authentications['APISecretKey'];
APISecretKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APISecretKey.apiKeyPrefix = 'Token';
let apiInstance = new theblockchainapi.SolanaAccountApi();
let network = mainnet-beta; // String | The network ID (devnet, mainnet-beta)
let publicKey = EEr5yQpNXf7Bru6Rt5podx56HGW9CEehXqgRGh2wa71w; // String | The public key of the account
apiInstance.solanaGetAccountIsCandyMachine(network, publicKey).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
network | String | The network ID (devnet, mainnet-beta) | |
publicKey | String | The public key of the account |
- Content-Type: Not defined
- Accept: application/json
AccountIsNFT solanaGetAccountIsNFT(network, publicKey)
Get if account is NFT
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-account/get-is-nft\" target="_blank">See examples (Python, JavaScript)</a>. Determine whether or not a public key is an NFT `mint address` `Cost: 0.5 Credit` (<a href="#section/Pricing">See Pricing</a>)
import theblockchainapi from 'theblockchainapi';
let defaultClient = theblockchainapi.ApiClient.instance;
// Configure API key authorization: APIKeyID
let APIKeyID = defaultClient.authentications['APIKeyID'];
APIKeyID.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APIKeyID.apiKeyPrefix = 'Token';
// Configure API key authorization: APISecretKey
let APISecretKey = defaultClient.authentications['APISecretKey'];
APISecretKey.apiKey = 'YOUR API KEY';
// Uncomment the following line to set a prefix for the API key, e.g. "Token" (defaults to null)
//APISecretKey.apiKeyPrefix = 'Token';
let apiInstance = new theblockchainapi.SolanaAccountApi();
let network = mainnet-beta; // String | The network ID (devnet, mainnet-beta)
let publicKey = EEr5yQpNXf7Bru6Rt5podx56HGW9CEehXqgRGh2wa71w; // String | The public key of the account
apiInstance.solanaGetAccountIsNFT(network, publicKey).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
network | String | The network ID (devnet, mainnet-beta) | |
publicKey | String | The public key of the account |
- Content-Type: Not defined
- Accept: application/json