Update an NFT
Partial Update an NFT
This endpoint allows you to perform a partial update on an NFT.
Authorizations
Path parameters
transferablestringRequired
Value must be either 't' for transferable or 'n' for non-transferable
projectIdintegerRequired
nftIdintegerRequired
NFT ID
Body
descriptionstringOptionalExample:
Description stored in the metadata
This is my first NFT
imagestringOptionalExample:
Image URL for your NFT
https://example.com/image.png
animationUrlstringOptionalExample:
Animation URL for your NFT
https://example.com/animation.mp4
Responses
200
Returns an Updated NFT
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
404
Not Found
application/json
patch
PATCH /v2/projects/:transferable/:projectId/nfts/:nftId HTTP/1.1
Host: api.underdogprotocol.com
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 181
{
"description": "This is my first NFT",
"image": "https://example.com/image.png",
"attributes": {
"Points": "40000",
"Nickname": "LeGoat"
},
"animationUrl": "https://example.com/animation.mp4"
}
{
"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"
}
Example
curl --location --request PATCH 'https://dev.underdogprotocol.com/v2/projects/n/4/nfts/1' \
--header 'Authorization: Bearer {token}' \
--header 'Content-Type: application/json' \
--data-raw '{
"attributes": {
"points": "40000"
}
}'
{
"id": 1,
"status": "confirmed",
"mintAddress": "Dic1tC9yBhaDerQpV8ZBAsruBUKQsRWtCWysG965ADWi",
"name": "LeGoat",
"image": "https://underdog-test-bucket-dev.s3.amazonaws.com/Dic1tC9yBhaDerQpV8ZBAsruBUKQsRWtCWysG965ADWi/image.png",
"attributes": {
"points": "40000"
}
}
Update an NFT
This endpoint allows you to perform an update on an NFT.
Authorizations
Path parameters
transferablestringRequired
Value must be either 't' for transferable or 'n' for non-transferable
projectIdintegerRequired
nftIdintegerRequired
NFT ID
Body
descriptionstringOptionalExample:
Description stored in the metadata
This is my first NFT
imagestringRequiredExample:
Image URL for your NFT
https://example.com/image.png
animationUrlstringOptionalExample:
Animation URL for your NFT
https://example.com/animation.mp4
Responses
200
Returns an Updated NFT
application/json
401
Unauthorized
application/json
403
Forbidden
application/json
404
Not Found
application/json
put
PUT /v2/projects/:transferable/:projectId/nfts/:nftId HTTP/1.1
Host: api.underdogprotocol.com
Authorization: Bearer JWT
Content-Type: application/json
Accept: */*
Content-Length: 181
{
"description": "This is my first NFT",
"image": "https://example.com/image.png",
"attributes": {
"Points": "40000",
"Nickname": "LeGoat"
},
"animationUrl": "https://example.com/animation.mp4"
}
{
"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"
}
Example
curl --location --request PUT 'https://dev.underdogprotocol.com/v2/projects/n/4/nfts/1' \
--header 'Authorization: Bearer {token}' \
--header 'Content-Type: application/json' \
--data-raw '{
"name": "LeKareem",
"image": "https://upload.wikimedia.org/wikipedia/commons/a/a0/Kareem_Abdul-Jabbar_May_2014.jpg",
"attributes": {
"points": "40000"
}
}'
{
"id": 1,
"status": "confirmed",
"mintAddress": "Dic1tC9yBhaDerQpV8ZBAsruBUKQsRWtCWysG965ADWi",
"name": "LeGoat",
"image": "https://underdog-test-bucket-dev.s3.amazonaws.com/Dic1tC9yBhaDerQpV8ZBAsruBUKQsRWtCWysG965ADWi/image.png",
"attributes": {
"points": "40000"
}
}
Last updated