curl --request GET \
--url https://api.trycomp.ai/v1/tasks/{taskId} \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.trycomp.ai/v1/tasks/{taskId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.trycomp.ai/v1/tasks/{taskId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "tsk_abc123def456",
"title": "Implement user authentication",
"description": "Add OAuth 2.0 authentication to the platform",
"status": "in_progress",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}{
"message": "Task with ID tsk_abc123def456 not found"
}Get task by ID | Comp AI API
Get task by ID in Comp AI. Manage compliance task lifecycle, assignments, review approvals, evidence uploads, policy links, and activity history.
curl --request GET \
--url https://api.trycomp.ai/v1/tasks/{taskId} \
--header 'X-API-Key: <api-key>'const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.trycomp.ai/v1/tasks/{taskId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.trycomp.ai/v1/tasks/{taskId}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "tsk_abc123def456",
"title": "Implement user authentication",
"description": "Add OAuth 2.0 authentication to the platform",
"status": "in_progress",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}{
"message": "Task with ID tsk_abc123def456 not found"
}Authorizations
API key for authentication
Path Parameters
Unique task identifier
"tsk_abc123def456"
Response
Task retrieved successfully
Unique identifier for the task
"tsk_abc123def456"
Task title
"Implement user authentication"
Task status
todo, in_progress, done, blocked "in_progress"
Task creation timestamp
"2024-01-15T10:30:00Z"
Task last update timestamp
"2024-01-15T10:30:00Z"
Cadence for running the integration check attached to this task
daily, weekly, monthly, quarterly, yearly "daily"
Task description
"Add OAuth 2.0 authentication to the platform"
Task template ID
"frk_tt_68406e353df3bc002994acef"
Last successful integration check run timestamp
What an auditor needs to see in the evidence for this task, approved by Comp AI. Returned by GET /v1/tasks/{taskId}; empty when the task has no approved checklist.
[ "Backup jobs for 10 consecutive days", "Success or failure of each job" ]
How many evidence files on this task no person has marked as reviewed yet. Returned by GET /v1/tasks?includeRelations=true.
2
Was this page helpful?

