Get Project
const options = {
method: 'GET',
headers: {'x-api-key': '<x-api-key>', 'x-organization-id': '<x-organization-id>'}
};
fetch('https://api.dcycle.io/v1/projects/{project_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.dcycle.io/v1/projects/{project_id}"
headers = {
"x-api-key": "<x-api-key>",
"x-organization-id": "<x-organization-id>"
}
response = requests.get(url, headers=headers)
print(response.text)curl --request GET \
--url https://api.dcycle.io/v1/projects/{project_id} \
--header 'x-api-key: <x-api-key>' \
--header 'x-organization-id: <x-organization-id>'{
"id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"description": {},
"start_date": {},
"end_date": {},
"due_date": {},
"project_type": {},
"methodology": {},
"responsible_user_id": "<string>",
"responsible_user": {
"id": "<string>",
"email": "<string>",
"first_name": {},
"last_name": {},
"profile_img_url": {}
},
"parent": {
"id": "<string>",
"name": "<string>"
},
"created_at": {},
"updated_at": {}
}Get Project
Retrieve a specific project by its ID
GET
/
v1
/
projects
/
{project_id}
Get Project
const options = {
method: 'GET',
headers: {'x-api-key': '<x-api-key>', 'x-organization-id': '<x-organization-id>'}
};
fetch('https://api.dcycle.io/v1/projects/{project_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.dcycle.io/v1/projects/{project_id}"
headers = {
"x-api-key": "<x-api-key>",
"x-organization-id": "<x-organization-id>"
}
response = requests.get(url, headers=headers)
print(response.text)curl --request GET \
--url https://api.dcycle.io/v1/projects/{project_id} \
--header 'x-api-key: <x-api-key>' \
--header 'x-organization-id: <x-organization-id>'{
"id": "<string>",
"organization_id": "<string>",
"name": "<string>",
"description": {},
"start_date": {},
"end_date": {},
"due_date": {},
"project_type": {},
"methodology": {},
"responsible_user_id": "<string>",
"responsible_user": {
"id": "<string>",
"email": "<string>",
"first_name": {},
"last_name": {},
"profile_img_url": {}
},
"parent": {
"id": "<string>",
"name": "<string>"
},
"created_at": {},
"updated_at": {}
}Get Project
Retrieve detailed information about a specific project using its unique identifier.Request
Headers
string
required
Your API key for authenticationExample:
sk_live_1234567890abcdefstring
required
Your organization UUIDExample:
a8315ef3-dd50-43f8-b7ce-d839e68d51faPath Parameters
string
required
The unique identifier (UUID) of the project to retrieveExample:
550e8400-e29b-41d4-a716-446655440000Response
string
Unique identifier (UUID)
string
Organization UUID
string
Project name
string | null
Project description
date | null
Project start date (YYYY-MM-DD)
date | null
Project end date (YYYY-MM-DD)
date | null
Project due date (YYYY-MM-DD)
string | null
Project type classificationPossible values:
carbon_footprint, custom, einf, iso_14064, iso_14001, iso_9001, acv, visualization, suppliers, logisticsstring | null
Reporting methodologyPossible values:
esrs, gri, glecstring
UUID of the user responsible for the project
object
object | null
datetime
Timestamp when the project was created
datetime | null
Timestamp when the project was last updated
Example
curl -X GET "https://api.dcycle.io/v1/projects/550e8400-e29b-41d4-a716-446655440000" \
-H "x-api-key: ${DCYCLE_API_KEY}" \
-H "x-organization-id: ${DCYCLE_ORG_ID}"
import requests
import os
api_key = os.getenv("DCYCLE_API_KEY")
org_id = os.getenv("DCYCLE_ORG_ID")
headers = {
"x-api-key": api_key,
"x-organization-id": org_id
}
project_id = "550e8400-e29b-41d4-a716-446655440000"
response = requests.get(
f"https://api.dcycle.io/v1/projects/{project_id}",
headers=headers
)
project = response.json()
print(f"Project: {project['name']}")
print(f"Type: {project['project_type']}")
print(f"Responsible: {project['responsible_user']['email']}")
const axios = require('axios');
const apiKey = process.env.DCYCLE_API_KEY;
const orgId = process.env.DCYCLE_ORG_ID;
const headers = {
'x-api-key': apiKey,
'x-organization-id': orgId
};
const projectId = '550e8400-e29b-41d4-a716-446655440000';
axios.get(
`https://api.dcycle.io/v1/projects/${projectId}`,
{ headers }
)
.then(response => {
const project = response.data;
console.log(`Project: ${project.name}`);
console.log(`Type: ${project.project_type}`);
console.log(`Responsible: ${project.responsible_user.email}`);
})
.catch(error => console.error(error));
Successful Response
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"organization_id": "a8315ef3-dd50-43f8-b7ce-d839e68d51fa",
"name": "Carbon Footprint 2024",
"description": "Annual carbon footprint calculation for FY2024",
"start_date": "2024-01-01",
"end_date": "2024-12-31",
"due_date": "2025-03-31",
"project_type": "carbon_footprint",
"methodology": "gri",
"responsible_user_id": "user-uuid-001",
"responsible_user": {
"id": "user-uuid-001",
"email": "maria@company.com",
"first_name": "Maria",
"last_name": "Garcia",
"profile_img_url": null
},
"parent": null,
"created_at": "2024-01-15T10:30:00Z",
"updated_at": "2024-06-20T14:45:00Z"
}
Common Errors
401 Unauthorized
Cause: Missing or invalid API key{
"detail": "Invalid API key",
"code": "INVALID_API_KEY"
}
404 Not Found
Cause: Project not found or doesn’t belong to your organization{
"detail": "Project not found"
}
422 Validation Error
Cause: Invalid project ID format{
"detail": [
{
"loc": ["path", "project_id"],
"msg": "value is not a valid uuid",
"type": "type_error.uuid"
}
]
}
Related Endpoints
List Projects
Retrieve all projects
Update Project
Modify project details
Delete Project
Remove a project
Link Entities
Link entities to a project
Was this page helpful?