Filter for active tokens only (default: true). Non-admin users always get active tokens only.
PERS-api docs (2.0.2)
https://docs.pers.ninja/_mock/swagger/
https://api.pers.ninja/v2/
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens
https://api.pers.ninja/v2/tokens
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.pers.ninja/_mock/swagger/tokens?active=string' \
-H 'x-project-key: YOUR_API_KEY_HERE'Tokens retrieved successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
This is the underlying web3 native type of the token contract
[ { "id": "string", "contractAddress": "string", "metadata": [ … ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" } ]
The ABI URL is the URL to the contract ABI. This is an optional field. If not provided, the contract ABI will be fetched from PERS instance depending on selected token type.
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens
https://api.pers.ninja/v2/tokens
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://docs.pers.ninja/_mock/swagger/tokens \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"contractAddress": "string",
"abiUrl": "string",
"type": "ERC20",
"decimals": 0
}'Token created successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/address/{contractAddress}
https://api.pers.ninja/v2/tokens/address/{contractAddress}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.pers.ninja/_mock/swagger/tokens/address/{contractAddress}?contractTokenId=string' \
-H 'x-project-key: YOUR_API_KEY_HERE'Token retrieved successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/points
https://api.pers.ninja/v2/tokens/points
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
https://docs.pers.ninja/_mock/swagger/tokens/points \
-H 'x-project-key: YOUR_API_KEY_HERE'Point token retrieved successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/rewards
https://api.pers.ninja/v2/tokens/rewards
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.pers.ninja/_mock/swagger/tokens/rewards?active=string' \
-H 'x-project-key: YOUR_API_KEY_HERE'Reward tokens retrieved successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
This is the underlying web3 native type of the token contract
[ { "id": "string", "contractAddress": "string", "metadata": [ … ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" } ]
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/stamps
https://api.pers.ninja/v2/tokens/stamps
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
'https://docs.pers.ninja/_mock/swagger/tokens/stamps?active=string' \
-H 'x-project-key: YOUR_API_KEY_HERE'Stamp tokens retrieved successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
This is the underlying web3 native type of the token contract
[ { "id": "string", "contractAddress": "string", "metadata": [ … ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" } ]
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/types
https://api.pers.ninja/v2/tokens/types
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X GET \
https://docs.pers.ninja/_mock/swagger/tokens/types \
-H 'x-project-key: YOUR_API_KEY_HERE'[ { "nativeTokenType": "ERC20", "name": "string", "imageUrl": "string", "description": "string" } ]
Token native Types: - ERC20: used for credits - ERC721: used for stamps and NFTs - ERC1155: used for rewards
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/types
https://api.pers.ninja/v2/tokens/types
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
https://docs.pers.ninja/_mock/swagger/tokens/types \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"nativeTokenType": "ERC20",
"name": "string",
"imageUrl": "string",
"description": "string"
}'{ "nativeTokenType": "ERC20", "name": "string", "imageUrl": "string", "description": "string" }
This indicates if token should be included as a gallery. This is useful for ERC721 or ERC1155 tokens.
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/{id}
https://api.pers.ninja/v2/tokens/{id}
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
'https://docs.pers.ninja/_mock/swagger/tokens/{id}' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"isGallery": true,
"name": "string",
"symbol": "string"
}'Token updated successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/{id}/status
https://api.pers.ninja/v2/tokens/{id}/status
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
'https://docs.pers.ninja/_mock/swagger/tokens/{id}/status' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Token status updated successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/{id}/mainnet
https://api.pers.ninja/v2/tokens/{id}/mainnet
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
'https://docs.pers.ninja/_mock/swagger/tokens/{id}/mainnet' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"contractAddress": "string",
"chainId": 0
}'Mainnet contract address set successfully
Metadata of the token, this is optional and can be null in case of Point token
this is the abi of the contract, this is the interface of the contract to interact with it
this is the url of the abi of the contract, to be used to fetch the abi of the contract
this is the decimals of the token. This is optional and only used for ERC20 tokens (Points)
{ "id": "string", "contractAddress": "string", "metadata": [ { … } ], "abi": {}, "chainId": 0, "abiUrl": {}, "name": "string", "symbol": "string", "decimals": 0, "isActive": true, "isGallery": true, "type": "ERC20" }
This is the URL to the image of the item. Can be just about any type of image (including SVGs, which will be cached into PNGs by OpenSea), IPFS or Arweave URLs or paths. We recommend using a minimum 3000 x 3000 image.
A URL to a multi-media attachment for the item. The file extensions GLTF, GLB, WEBM, MP4, M4V, OGV, and OGG are supported, along with the audio-only extensions MP3, WAV, and OGA. Animation_url also supports HTML pages, allowing you to build rich experiences and interactive NFTs using JavaScript canvas, WebGL, and more. Scripts and relative paths within the HTML page are now supported. However, access to browser extensions is not supported.
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/{id}/metadata
https://api.pers.ninja/v2/tokens/{id}/metadata
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X POST \
'https://docs.pers.ninja/_mock/swagger/tokens/{id}/metadata' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'Content-Type: application/json' \
-d '{
"imageUrl": "string",
"externalUrl": "string",
"description": "string",
"name": "string",
"expiryDate": "2019-08-24T14:15:22Z",
"animationUrl": "string",
"youtubeUrl": "string",
"creatorAccountAddress": "string",
"previewUrl": "string"
}'Token metadata created successfully
This is the URL to the image of the item. Can be just about any type of image (including SVGs, which will be cached into PNGs by OpenSea), IPFS or Arweave URLs or paths. We recommend using a minimum 3000 x 3000 image.
A URL to a multi-media attachment for the item. The file extensions GLTF, GLB, WEBM, MP4, M4V, OGV, and OGG are supported, along with the audio-only extensions MP3, WAV, and OGA. Animation_url also supports HTML pages, allowing you to build rich experiences and interactive NFTs using JavaScript canvas, WebGL, and more. Scripts and relative paths within the HTML page are now supported. However, access to browser extensions is not supported.
{ "imageUrl": "string", "externalUrl": "string", "description": "string", "name": "string", "expiryDate": "2019-08-24T14:15:22Z", "animationUrl": "string", "youtubeUrl": "string", "creatorAccountAddress": "string", "previewUrl": "string", "id": "string", "animationWeb3StorageUrl": "string", "imageWeb3StorageUrl": "string", "web3StorageUrl": "string", "tokenMetadataIncrementalId": 0, "isActive": true }
- Mock server
https://docs.pers.ninja/_mock/swagger/tokens/metadata/{id}/status
https://api.pers.ninja/v2/tokens/metadata/{id}/status
- curl
- JavaScript
- Node.js
- Python
- Java
- C#
- PHP
- Go
- Ruby
- R
- Payload
curl -i -X PUT \
'https://docs.pers.ninja/_mock/swagger/tokens/metadata/{id}/status' \
-H 'Authorization: Bearer <YOUR_JWT_HERE>'Token metadata status updated successfully
This is the URL to the image of the item. Can be just about any type of image (including SVGs, which will be cached into PNGs by OpenSea), IPFS or Arweave URLs or paths. We recommend using a minimum 3000 x 3000 image.
A URL to a multi-media attachment for the item. The file extensions GLTF, GLB, WEBM, MP4, M4V, OGV, and OGG are supported, along with the audio-only extensions MP3, WAV, and OGA. Animation_url also supports HTML pages, allowing you to build rich experiences and interactive NFTs using JavaScript canvas, WebGL, and more. Scripts and relative paths within the HTML page are now supported. However, access to browser extensions is not supported.
{ "imageUrl": "string", "externalUrl": "string", "description": "string", "name": "string", "expiryDate": "2019-08-24T14:15:22Z", "animationUrl": "string", "youtubeUrl": "string", "creatorAccountAddress": "string", "previewUrl": "string", "id": "string", "animationWeb3StorageUrl": "string", "imageWeb3StorageUrl": "string", "web3StorageUrl": "string", "tokenMetadataIncrementalId": 0, "isActive": true }