Create compliance task
POST
/v1/tasks
const url = 'https://api.varman.io/v1/tasks';const options = { method: 'POST', headers: {'X-API-Key': '<X-API-Key>', 'Content-Type': 'application/json'}, body: '{"title":"Implement access controls","description":"Set up role-based access controls for the platform","assigneeId":"mem_abc123","frequency":"daily","department":"it","controlIds":["ctrl_abc123"],"taskTemplateId":"tmpl_abc123","vendorId":"vnd_abc123"}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.varman.io/v1/tasks \ --header 'Content-Type: application/json' \ --header 'X-API-Key: <X-API-Key>' \ --data '{ "title": "Implement access controls", "description": "Set up role-based access controls for the platform", "assigneeId": "mem_abc123", "frequency": "daily", "department": "it", "controlIds": [ "ctrl_abc123" ], "taskTemplateId": "tmpl_abc123", "vendorId": "vnd_abc123" }'Create a compliance task for evidence collection, remediation, review, or recurring control work inside an organization.
Authorizations
Section titled “Authorizations”Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
title
required
string
Example
Implement access controlsdescription
required
string
Example
Set up role-based access controls for the platformassigneeId
string
Example
mem_abc123frequency
string
Example
monthlydepartment
Built-in values: none, admin, gov, hr, it, itsm, qms. Custom department names are also accepted.
string
Example
itcontrolIds
Array<string>
Example
[ "ctrl_abc123"]taskTemplateId
string
Example
tmpl_abc123vendorId
Vendor ID to connect this task to
string
Example
vnd_abc123Responses
Section titled “Responses”Task created successfully
Media typeapplication/json
object
id
required
Unique identifier for the task
string
title
required
Task title
string
description
Task description
string
status
required
Task status
string
createdAt
required
Task creation timestamp
string format: date-time
updatedAt
required
Task last update timestamp
string format: date-time
taskTemplateId
Task template ID
object
integrationScheduleFrequency
required
Cadence for running the integration check attached to this task
string
integrationLastRunAt
Last successful integration check run timestamp
object
Example
{ "id": "tsk_abc123def456", "title": "Implement user authentication", "description": "Add OAuth 2.0 authentication to the platform", "status": "todo", "createdAt": "2024-01-15T10:30:00Z", "updatedAt": "2024-01-15T10:30:00Z", "taskTemplateId": "frk_tt_68406e353df3bc002994acef", "integrationScheduleFrequency": "daily"}Invalid request body