Skip to main content

Requests API

Create, read, update, and manage support requests via the API.

Endpoints Overview

MethodEndpointDescription
GET/v1/requestsList requests
GET/v1/requests/:idGet single request
POST/v1/requestsCreate request
PATCH/v1/requests/:idUpdate request
DELETE/v1/requests/:idDelete request

List Requests

Request

GET /v1/requests

Query Parameters

ParameterTypeDescription
statusstringFilter by status
prioritystringFilter by priority
assignedTostringFilter by assignee
groupIdstringFilter by group
createdAfterdatetimeCreated after date
createdBeforedatetimeCreated before date
pagenumberPage number (default: 1)
limitnumberItems per page (default: 20, max: 100)

Example

curl -X GET "https://api.dzdesk.com/v1/requests?status=open&priority=high&limit=10" \
-H "Authorization: Bearer YOUR_TOKEN"

Response

{
"success": true,
"data": {
"requests": [
{
"id": "req_abc123",
"title": "Cannot access email",
"description": "Outlook shows connection error",
"status": "open",
"priority": "high",
"category": "software",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T10:30:00Z",
"assignedTo": null,
"assignedGroup": "grp_software",
"requester": {
"id": "usr_123",
"email": "john@company.com",
"name": "John Doe"
}
}
],
"pagination": {
"page": 1,
"limit": 10,
"total": 45,
"pages": 5
}
}
}

Get Single Request

Request

GET /v1/requests/:id

Example

curl -X GET "https://api.dzdesk.com/v1/requests/req_abc123" \
-H "Authorization: Bearer YOUR_TOKEN"

Response

{
"success": true,
"data": {
"id": "req_abc123",
"title": "Cannot access email",
"description": "Outlook shows connection error since this morning",
"status": "in_progress",
"priority": "high",
"category": "software",
"tags": ["email", "outlook"],
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-15T14:22:00Z",
"assignedTo": {
"id": "usr_456",
"email": "jane@company.com",
"name": "Jane Smith"
},
"assignedGroup": {
"id": "grp_software",
"name": "Software Support"
},
"requester": {
"id": "usr_123",
"email": "john@company.com",
"name": "John Doe",
"isVip": false
},
"sla": {
"tier": "Tier 2",
"responseTarget": "2024-01-15T14:30:00Z",
"resolutionTarget": "2024-01-15T18:30:00Z",
"responseStatus": "met",
"resolutionStatus": "on_track"
},
"comments": [
{
"id": "cmt_789",
"content": "I'll look into this right away",
"author": {
"id": "usr_456",
"name": "Jane Smith"
},
"isInternal": false,
"createdAt": "2024-01-15T11:00:00Z"
}
],
"attachments": [
{
"id": "att_111",
"filename": "error_screenshot.png",
"size": 245000,
"uploadedAt": "2024-01-15T10:30:00Z"
}
]
}
}

Create Request

Request

POST /v1/requests

Body Parameters

FieldTypeRequiredDescription
titlestringYesRequest title
descriptionstringYesDetailed description
prioritystringYescritical, high, medium, low
categorystringNoCategory name
assignedTostringNoUser ID to assign
assignedGroupstringNoGroup ID to assign
tagsarrayNoList of tags

Example

curl -X POST "https://api.dzdesk.com/v1/requests" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"title": "New laptop setup required",
"description": "New employee starting Monday needs laptop configured",
"priority": "medium",
"category": "hardware",
"assignedGroup": "grp_hardware",
"tags": ["new-hire", "laptop"]
}'

Response

{
"success": true,
"data": {
"id": "req_def456",
"title": "New laptop setup required",
"status": "open",
"createdAt": "2024-01-15T15:00:00Z"
}
}

Update Request

Request

PATCH /v1/requests/:id

Body Parameters

FieldTypeDescription
titlestringUpdated title
descriptionstringUpdated description
statusstringNew status
prioritystringNew priority
assignedTostringNew assignee
assignedGroupstringNew group
tagsarrayUpdated tags

Example

curl -X PATCH "https://api.dzdesk.com/v1/requests/req_abc123" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"status": "resolved",
"resolution": "Recreated Outlook profile, issue resolved"
}'

Response

{
"success": true,
"data": {
"id": "req_abc123",
"status": "resolved",
"updatedAt": "2024-01-15T16:30:00Z"
}
}

Delete Request

Request

DELETE /v1/requests/:id

Example

curl -X DELETE "https://api.dzdesk.com/v1/requests/req_abc123" \
-H "Authorization: Bearer YOUR_TOKEN"

Response

{
"success": true,
"data": {
"deleted": true
}
}

Note: Requires admin permissions.

Add Comment

Request

POST /v1/requests/:id/comments

Body Parameters

FieldTypeRequiredDescription
contentstringYesComment text
isInternalbooleanNoInternal note (default: false)

Example

curl -X POST "https://api.dzdesk.com/v1/requests/req_abc123/comments" \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"content": "Issue resolved by recreating user profile",
"isInternal": false
}'

Upload Attachment

Request

POST /v1/requests/:id/attachments

Example

curl -X POST "https://api.dzdesk.com/v1/requests/req_abc123/attachments" \
-H "Authorization: Bearer YOUR_TOKEN" \
-F "file=@screenshot.png"

Response

{
"success": true,
"data": {
"id": "att_222",
"filename": "screenshot.png",
"size": 150000,
"url": "https://api.dzdesk.com/v1/attachments/att_222"
}
}

Status Values

StatusDescription
openNew request
assignedAssigned to agent
in_progressBeing worked on
pendingWaiting for response
resolvedSolution provided
closedCompleted

Priority Values

PriorityDescription
criticalSystem down, urgent
highMajor impact
mediumStandard issue
lowMinor/question