Query collections on Bitcoin by user address

Description

  • Method: HTTPS GET

  • Encoding: UTF-8

  • Path: https: https://api.blockin.ai/v2/user/nft/btc/wallet_collection_list

  • Description: Query collections on Bitcoin by user address

Request Header

Parameter
Required
Type
Description

Content-Type

Y

String

application/json

AccessKey

Y

String

1bdb01c947c54919b64d1fc6794atest

Request Parameters

Parameter
Required
Type
Description

address

Y

String

User's address

page

Y

Integer

Page number

page_size

Y

Integer

Page size(minimum:1 ,maximum:100)

Response

Public Response

Parameter
Required
Type
Description

success

Y

Boolean

Success Boolean

data

N

Object

Response object

error_code

N

String

Error code

error_msg

N

String

Error message

Response Content

Parameter
Required
Type
Description

list

Y

List

Detail info list

pagination

Y

Integer

Page info

Pagination Content

Parameter
Required
Type
Description

current

Y

Integer

Current page number

page_size

Y

Integer

Current page size

total

Y

Integer

Total number

count_page

Y

Integer

Total page number

HolderCollection Content

Parameter
Required
Type
Description

inscription_collection

Y

String

Collection's symbol

collection_name

Y

String

Collection's name

logo_url

Y

String

Collection's logo url

amount

Y

Long

Number of NFT items held by an address

Request Sample

curl -H "Content-Type:application/json" -H "AccessKey:1bdb01c947c54919b64d1fc6794atest" -X GET "https://api.blockin.ai/v2/user/nft/btc/wallet_collection_list?address=bc1pdkdhdftp9slhxx20pcpzp537pmaky2dl6ar6mxyx3t5qm6wpeu3qm2q4pz&page=1&page_size=10"

Successful Response Sample

{
    "success": true,
    "data": {
        "list": [
            {
                "logo_url": "https://bafkreicrlxiko36sxugnfbhuapyougyjw55iwk7n2acusptnc5q7kasfd4.ipfs.nftstorage.link/",
                "amount": 2,
                "collection_name": "BTC Survival Gear",
                "inscription_collection": "btc-survival-gear"
            },
            {
                "logo_url": null,
                "amount": 2,
                "collection_name": "OTHER",
                "inscription_collection": "OTHER"
            },
            {
                "logo_url": "https://bafkreifc6t46445jzrlyprmztnzcfc6qna32js3audmhnnesoml4gpmoty.ipfs.nftstorage.link/",
                "amount": "1",
                "collection_name": "BTC Artifacts",
                "inscription_collection": "btc-artifacts"
            },
            {
                "logo_url": "https://bafkreig5vhlgqyhq5ikmrfu5j26v3mjdpeeqds3elvnevwkx7rd7qahtli.ipfs.nftstorage.link/",
                "amount": 1,
                "collection_name": "0n1y 0ne pi×e1 ri0t",
                "inscription_collection": "0n1y_0ne_pixe1_ri0t"
            }
        ],
        "pagination": {
            "current": 1,
            "page_size": 100,
            "total": 4,
            "count_page": 1
        }
    },
    "error_code": null,
    "error_msg": null
}

Failed Response Sample

{
    "success": false,
    "data": null,
    "error_code": "INVALID_PARAM",
    "error_msg": "page_size minimum:1 ,maximum:100"
}

Last updated