Retrieve a Collection
Example
curl "https://api.underdogprotocol.com/v1/collections/6TpvoRVJfJe6VdqfML4yjvp9Qc49LuVNb7uzWtPRZzVV" \
-H "Authorization: Bearer {token}"
import axios from 'axios';
const collectionAddress = '6TpvoRVJfJe6VdqfML4yjvp9Qc49LuVNb7uzWtPRZzVV';
const getCollection = async () => {
try {
const response = await axios.get(`https://api.underdogprotocol.com/v1/collections/${collectionAddress}`, {
headers: {
'Authorization': `Bearer ${token}`
}
});
console.log(response.data);
} catch (error) {
console.error(error);
}
}
Response
{
"mintAddress": "6TpvoRVJfJe6VdqfML4yjvp9Qc49LuVNb7uzWtPRZzVV",
"name": "Underdog Protocol",
"description": "Underdog Protocol Collection",
"image": "https://arweave.net/-RawfoOduz6O18yTuz4zOGbCokzoACaDjoogsSwMaBY",
"collectionDetails": {},
"status": "confirmed",
"ownerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
"nfts": {
"results": [
{
"mintAddress": "DBqMFAaE8rxJ5emotUywQLWJStGMgGRo3vH52dcKApe6",
"ownerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
"name": "Degenerate Ape",
"image": "https://arweave.net/8FZ8SmhuLDUH-vN0psJuq7GKpCncqGP-03UU_tjmHW8",
"description": null,
"status": "confirmed",
"tokenManager": {}
}
],
"page": 1,
"limit": 10,
"totalPages": 1,
"totalResults": 1
}
}
Last updated