For the complete documentation index, see llms.txt. Markdown versions of documentation pages are available by appending .md to page URLs.
Skip to content

Retrieve a Collection

Retrieve a Collection

get

This endpoint allows you to retrieve a Collection by providing their collection address.

Authorizations
AuthorizationstringRequired
Bearer authentication header of the form Bearer <token>.
Path parameters
collectionAddressstringRequired

Mint address for the NFT Collection

Query parameters
pagenumber · nullableOptional
limitnumber · max: 100 · nullableOptional
Responses
200

Returns a Collection with a paginated list of NFTs

application/json
namestringRequired

Name stored as on-chain metadata

Example: NFT #1
symbolstringOptional

Symbol stored as on-chain metadata

Example: NFT
descriptionstringOptional

Description stored in the metadata

Example: This is my first NFT
imagestringRequired

Image URL for your NFT

Example: https://example.com/image.png
animationUrlstringOptional

Animation URL for your NFT

Example: https://example.com/animation.mp4
idnumberRequired

Unique ID for an NFT in a Project

projectIdnumberOptional

The ID of the Project the NFT is part of

transferablebooleanOptional

Whether or not the NFT can be transferred based on the Project its a part of

mintAddressstringRequired

Address for the NFT's or token's mint account

Example: EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDpPattern: ^[A-HJ-NP-Za-km-z1-9]*$
ownerAddressstringOptional

Wallet addres for the NFT's owner

Example: EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDpPattern: ^[A-HJ-NP-Za-km-z1-9]*$
claimerAddressstringOptional

Wallet address allowed to claim the NFT

Example: EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDpPattern: ^[A-HJ-NP-Za-km-z1-9]*$
statusstringRequired
get/v1/collections/:collectionAddress
GET /v1/collections/:collectionAddress HTTP/1.1
Host: api.underdogprotocol.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
  "name": "NFT #1",
  "symbol": "NFT",
  "description": "This is my first NFT",
  "image": "https://example.com/image.png",
  "animationUrl": "https://example.com/animation.mp4",
  "attributes": {
    "Points": "40000",
    "Nickname": "LeGoat"
  },
  "id": 1,
  "projectId": 1,
  "transferable": true,
  "mintAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
  "ownerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
  "claimerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
  "status": "text",
  "nfts": {
    "results": [
      {
        "name": "NFT #1",
        "symbol": "NFT",
        "description": "This is my first NFT",
        "image": "https://example.com/image.png",
        "animationUrl": "https://example.com/animation.mp4",
        "attributes": {
          "Points": "40000",
          "Nickname": "LeGoat"
        },
        "id": 1,
        "projectId": 1,
        "transferable": true,
        "mintAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
        "ownerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
        "claimerAddress": "EBeLw5jEdrEgDe17BdKGW2MizzGxtxigEuAGvYC7VzDp",
        "status": "text"
      }
    ],
    "page": 1,
    "limit": 10,
    "totalPages": 1,
    "totalResults": 1
  }
}

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);
  }
}

Last updated