Delete Work
Deletes a work item.
Required scopes:
Depends on the object type in the id field:
| type | required scope |
|---|---|
| incident | incident:all |
| issue | issue:all |
| opportunity | opportunity:all |
| task | task:all |
| ticket | ticket:all |
Authorization
auth-token All the DevRev APIs require a token to authenticate the user. Provide Authorization: Bearer <TOKEN> as a header to every API request.
How do I find my token?
In: header
Request Body
application/json
The work's ID.
idResponse Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://api.devrev.ai/works.delete" \ -H "Content-Type: application/json" \ -d '{ "id": "ISS-12345" }'{}{
"detail": "string",
"message": "string",
"type": "artifact_already_attached_to_a_parent",
"existing_parent": "string",
"is_same": true
}{
"detail": "string",
"message": "string",
"type": "dev_org_deactivated"
}{
"detail": "string",
"message": "string",
"type": "forbidden",
"object_ids": [
"string"
]
}{
"detail": "string",
"message": "string",
"type": "not_found"
}{
"detail": "string",
"message": "string",
"type": "request_entity_too_large",
"max_bytes": 0
}{
"detail": "string",
"message": "string",
"type": "too_many_requests",
"retry_after": 0
}{
"detail": "string",
"message": "string",
"type": "internal_error",
"reference_id": "string"
}{
"detail": "string",
"message": "string",
"type": "service_unavailable"
}Create Work POST
Creates new work ([issue](https://devrev.ai/docs/product/build), [ticket](https://devrev.ai/docs/product/support)) item. [task](https://devrev.ai/docs/product/tasks) and opportunity work types are supported in the beta version. **Required scopes:** Depends on the object type in the `type` field: | type | required scope | |---|---| | incident | `incident:write` OR `incident:all` | | issue | `issue:write` OR `issue:all` | | opportunity | `opportunity:write` OR `opportunity:all` | | task | `task:write` OR `task:all` | | ticket | `ticket:write` OR `ticket:all` |
Export Works (POST) POST
Exports a collection of work items. **Required scopes:** Depends on the object type in the `type` field: | type | required scope | |---|---| | incident | `incident:read` OR `incident:write` OR `incident:all` | | issue | `issue:read` OR `issue:write` OR `issue:all` | | opportunity | `opportunity:read` OR `opportunity:write` OR `opportunity:all` | | task | `task:read` OR `task:write` OR `task:all` | | ticket | `ticket:read` OR `ticket:write` OR `ticket:all` |