Migrate from v2 to v3
This is a general guidance for migrating from NFT-API v2 to NFT-API v3.
Intro
This guide outlines the seamless migration from NFT API v2 to NFT API v3, unlocking new features for creators and collectors alike. Migrate now by following the detailed guide which takes you through everything you need to change or update. Unlock new endpoints and features by migrating to NFT v3!
If you have any difficulties migrating, please contact the support team.
Migrating to NFT API v3
1. Base URL Change
The base URL for NFT v3 will become:
https://token-api.venly.io
https://token-api-sandbox.venly.io
2. Path Change for company wallet and media endpoints
For the following endpoints, replace /v2/
with /v3/
in the path:
Endpoints | v2/v3 comparison |
---|---|
Get all company wallets | v2: GET /api/v2/wallets |
v3: GET /api/v3/wallets | |
Get all company wallets by chain | v2: GET /api/v2/wallets/{chain} |
v3: GET /api/v3/wallets/{chain} | |
Delete company wallet | v2: DELETE /api/v2/wallets/{chain}/{address} |
v3: DELETE /api/v3/wallets/{chain}/{address} | |
Upload media file | v2: POST /api/v2/media |
v3: POST /api/v3/media | |
Upload image | v2: POST /api/v2/images |
v3: POST /api/v3/images |
3. Path change for all other endpoints
In the path of every other endpoint, replace /v2/
with /v3/erc1155/
For example, the endpoint to create a contract:
Before (v2):
POST /api/v2/contracts/deployments
Now (v3):
POST /api/v3/erc1155/contracts/deployments
Apply this path change for all the remaining endpoints.
4. Replace secretType
with chain
secretType
with chain
Replace secretType
with chain
everywhere, specifically in the path variable and request bodies.
4.1 Request Bodies
Replace secretType
with chain
in the request bodies for:
- Mint tokens endpoint (
POST /api/v3/erc1155/tokens/mints
) - Create token-type endpoint (
POST /api/v3/erc1155/token-types/creations
)
4.2 Path Params
Replace {secretType}
with {chain}
in the path of all the endpoints where applicable.
For example, the path to get a contract by blockchain and contract address:
Before (v2):
GET /api/v2/contracts/{secretType}/{contractAddress}
Now (v3):
GET /api/v3/erc1155/contracts/{chain}/{contractAddress}
4.3 Response Bodies
In the response bodies, secretType
will be replaced by the chain
parameter.
5. Removed Endpoints
The following endpoints from v2 have been removed in v3:
Endpoint Name | Endpoint URL |
---|---|
Create company/minter wallets | POST /api/v2/wallets |
We decided to remove the endpoint mentioned above because of mass minting. Mass minting allows you to mint a huge number of NFTs simultaneously. You don't need to wait for the entire minting process to be completed before getting your response.
Mass minting takes care of the token-type creation request or an NFT mint request, thus eliminating the need to create company/minter wallets.
6. New Endpoints
Endpoints | Description |
---|---|
Update contract owner | This endpoint updates the owner of an NFT contract. The owner has admin rights to the contract. |
Update contract royalty | This endpoint adds or updates the royalty information for an NFT contract. You can specify the royalty recipient's wallet address and the royalty percentage. (This endpoint can only be used on NFT contracts created with NFT v3) |
Endpoints: v2 → v3 mapping
The following table lists endpoint mappings from v2 to v3 in full, along with the differences.
Deprecated Endpoints | What to use instead? | Differences |
---|---|---|
Get All Contract v2 | Get All Contracts v3 | - Path param changed |
Create Contract v2 | Create Contract v3 | - Path param changed |
Get Contract Status v2 | Get Contract Status v3 | - Path param changed |
Get Contract by chain and contract address v2 | Get Contract by chain and contract address v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Delete Contract v2 | Delete Contract v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get Contract Metadata v2 | Get Contract Metadata v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Update Contract Metadata v2 | Update Contract Metadata v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get All Token-types v2 | Get All Token-types v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Create Token-type v2 | Create Token-type v3 | - Path param changed - Replace secretType with chain in the request body |
Get token-type status v2 | Get token-type status v3 | - Path param changed |
Get Specific Token-type v2 | Get Specific Token-type v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Delete Token-type v2 | Delete Token-type v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get Token-type Metadata v2 | Get Token-type Metadata v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Update Token-type Metadata v2 | Update Token-type Metadata v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get all tokens v2 | Get all tokens v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get All Token Mints v2 | Get All Token Mints v3 | - Path param changed |
Mint Tokens v2 | Mint Tokens v3 | - Path param changed - Replace secretType with chain in the request body |
Get Mint Status v2 | Get mint status v3 | - Path param changed |
Get Specific Token Details v2 | Get Specific Token Details v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get Token Metadata v2 | Get Token Metadata v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Update Property v2 | Update Property v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Delete Property v2 | Delete Property v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Add Attribute v2 | Add Attribute v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Update Attribute v2 | Update Attribute v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Delete Attribute v2 | Delete Attribute v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Update Animation URLs v2 | Update Animation URLs v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Delete Animation URLs v2 | Delete Animation URLs v3 | - Path param changed - Replace {secretType} with {chain} in the path |
Get all Company Wallets v2 | Get all Company Wallets v3 | - Path param changed |
Get Company Wallets by chain v2 | Get Company Wallet by chain v3 | - Path param changed |
Create Company Wallet v2 | Removed | - Endpoint removed in v3 |
Delete Company Wallet v2 | Delete Company Wallet v3 | - Path param changed |
Upload Media File v2 | Upload Media File v3 | - Path param changed |
Upload Image v2 | Upload Image v3 | - Path param changed |
Token API Endpoints (v3)
Endpoints | Description |
---|---|
Create token contract | This endpoint is used to create an ERC20 contract. |
Check token contract status | This endpoint is used to check the token contract creation request status. |
Get all token contracts | This endpoint fetches all of your token contracts. |
Get specific token contract | This endpoint is used to get a specific token contract using blockchain and contract address. |
Delete token contract | This endpoint is used to delete a token contract. |
Mint ERC20 tokens | This endpoint is used to mint and send ERC20 tokens. |
Check token mint status | This endpoint is used to check the status of a token mint request. |
Testing
Thoroughly test your integration with NFT API v3 in a sandbox environment to identify and address potential issues before deploying to production.
Updated 11 days ago