All URIs are relative to https://api.blockchainapi.com/v1
Method | HTTP request | Description |
---|---|---|
solanaGetAllNFTsFromCandyMachine | GET /solana/nft/candy_machine/{network}/{candy_machine_id}/nfts | Get CM's NFTs |
solanaGetCandyMachineMetadata | POST /solana/nft/candy_machine/metadata | Get a CM's metadata |
solanaListAllCandyMachines | GET /solana/nft/candy_machine/list | List all CMs |
solanaSearchCandyMachines | POST /solana/nft/candy_machine/search | Search CMs |
GetAllNFTsResponse solanaGetAllNFTsFromCandyMachine(network, candyMachineId)
Get CM's NFTs
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-candy-machine/get-candy-machine-all-nfts\" target="_blank"> See examples (Python, JavaScript)</a>. Use this endpoint to get the list of all NFTs (minted and unminted) from a Solana Candy Machine. This works for `v1` and `v2` candy machines. However, for `v2` only the value for `all_nfts` is provided. To determine which are minted and unminted follow this example. You do not need to specify `v1` or `v2` for this endpoint as it will automatically determine it from the candy machine ID. See example for how to get the list of NFT hashes <a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-candy-machine/get-candy-machine-hash-table\" target="_blank">here</a>. `Cost: 2 Credits` (<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.SolanaCandyMachineApi();
let network = mainnet-beta; // String | The network ID
let candyMachineId = FmkrvXRenCGtwBHw3VtBcExp8eTdnau97upaewF4GUEX; // String | The ID of the candy machine
apiInstance.solanaGetAllNFTsFromCandyMachine(network, candyMachineId).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
network | String | The network ID | |
candyMachineId | String | The ID of the candy machine |
- Content-Type: Not defined
- Accept: application/json
GetCandyMetadataResponse solanaGetCandyMachineMetadata(opts)
Get a CM's metadata
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-candy-machine/get-candy-machine-metadata\" target="_blank">See examples (Python, JavaScript)</a>. Use this endpoint to get metadata about a Metaplex candy machine. This includes the goLiveDate, itemsAvailable, and itemsRedeemed. To see what is included, expand the green successful response below. NOTE: Supply exactly one of `candy_machine_id`, `config_address`, or `uuid`. If you provide more than one, you will receive a `400` error. `Cost: 2 Credits` (<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.SolanaCandyMachineApi();
let opts = {
'getCandyMetadataRequest': new theblockchainapi.GetCandyMetadataRequest() // GetCandyMetadataRequest |
};
apiInstance.solanaGetCandyMachineMetadata(opts).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
getCandyMetadataRequest | GetCandyMetadataRequest | [optional] |
- Content-Type: application/json
- Accept: application/json
Object solanaListAllCandyMachines()
List all CMs
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-candy-machine/list-all-candy-machines\" target="_blank">See examples (Python, JavaScript)</a>. With this endpoint, you can list all candy machines published to Solana mainnet. We update this data every 15 minutes. The output is a list of config addresses, currently about 17000 in length. `Cost: 2 Credits` (<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.SolanaCandyMachineApi();
apiInstance.solanaListAllCandyMachines().then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
This endpoint does not need any parameter.
Object
- Content-Type: Not defined
- Accept: application/json
[String] solanaSearchCandyMachines(opts)
Search CMs
<a href="https://github.com/BL0CK-X/the-blockchain-api/tree/main/examples/solana-candy-machine/search-candy-machines\" target="_blank">See examples (Python, JavaScript)</a>. With this endpoint, you can search candy machines by their symbol, name of NFTs, uuid, configuration address, and update authority. The output is a list of config addresses. You can also provide multiple search clauses, such as the update authority (`update_authority="G17UmNGnMJ851x3M1JXocgpft1afcYedjPuFpo1ohhCk"`) and symbol begins with "Sol" (`symbol="Sol", symbol_search_method='begins_with'`). `Cost: 2 Credits` (<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.SolanaCandyMachineApi();
let opts = {
'candyMachineSearchRequest': new theblockchainapi.CandyMachineSearchRequest() // CandyMachineSearchRequest |
};
apiInstance.solanaSearchCandyMachines(opts).then((data) => {
console.log('API called successfully. Returned data: ' + data);
}, (error) => {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
candyMachineSearchRequest | CandyMachineSearchRequest | [optional] |
[String]
- Content-Type: application/json
- Accept: application/json