Get Tournament Projects
Retrieve projects associated with a specific tournament.
Endpoint
GET /api/v2/tournament/{id}/projects/
Authentication
This endpoint is public and does not require authentication.
Description
This endpoint returns all projects associated with a specific tournament. These projects represent NFT collections, contracts, or other blockchain assets linked to the tournament.
Path Parameters
Parameter | Type | Required | Description |
---|---|---|---|
id | string | Yes | Unique identifier for the tournament |
Request Example
GET /api/v2/tournament/tournament-123/projects/
Response
Success Response (200)
{
"data": [
{
"id": "project-123",
"name": "Epic NFT Collection",
"imageUrl": "https://example.com/project-image.jpg",
"organizationId": "org-456",
"chainId": "1",
"contractAddress": "0x1234567890123456789012345678901234567890",
"createdAt": 1703548800000,
"updatedAt": 1703548800000
},
{
"id": "project-456",
"name": "Tournament Token",
"imageUrl": "https://example.com/token-image.jpg",
"organizationId": "org-456",
"chainId": "137",
"contractAddress": "0x9876543210987654321098765432109876543210",
"createdAt": 1703635200000,
"updatedAt": 1703635200000
},
{
"id": "project-789",
"name": "Gaming Assets",
"imageUrl": "https://example.com/gaming-assets.jpg",
"organizationId": null,
"chainId": null,
"contractAddress": null,
"createdAt": 1703721600000,
"updatedAt": 1703721600000
}
]
}
Error Response (404)
{
"message": "Tournament not found",
"status": 404
}
Response Fields
Field | Type | Description |
---|---|---|
data | array | Array of project objects |
data[].id | string | Unique project identifier |
data[].name | string | Project name |
data[].imageUrl | string | Project image URL |
data[].organizationId | string | Organization identifier (optional) |
data[].chainId | string | Blockchain chain ID (optional) |
data[].contractAddress | string | Smart contract address (optional) |
data[].createdAt | number | Creation date (Unix timestamp in milliseconds) |
data[].updatedAt | number | Last update date (Unix timestamp in ms) |
Usage Example
const response = await fetch("https://api-stage.intraverse.io/api/v2/tournament/tournament-123/projects/");
const result = await response.json();
console.log(`Found ${result.data.length} projects for tournament`);
result.data.forEach((project) => {
console.log(`\n${project.name}`);
console.log(`- ID: ${project.id}`);
console.log(`- Image: ${project.imageUrl}`);
console.log(`- Organization: ${project.organizationId || "None"}`);
console.log(`- Chain ID: ${project.chainId || "None"}`);
console.log(`- Contract: ${project.contractAddress || "None"}`);
console.log(`- Created: ${new Date(project.createdAt).toISOString()}`);
console.log(`- Updated: ${new Date(project.updatedAt).toISOString()}`);
});
Error Handling
Error | Description | Solution |
---|---|---|
Tournament not found | Tournament ID doesn't exist | Check tournament ID |