API Reference Guides

Creating requests, incidents and problems

There are two endpoints for creating tickets with an API key. Which one you use depends on the type of ticket you want to create.

Ticket typeEndpointrequest_type
General requestPOST /api/v1/requestsREQUEST (or omit the field)
General requestPOST /api/v1/requests/createREQUEST
IncidentPOST /api/v1/requests/createINCIDENT
Service requestPOST /api/v1/requests/createSERVICE_REQUEST
ProblemPOST /api/v1/requests/createPROBLEM

POST /api/v1/requests creates general requests only. Sending "request_type": "INCIDENT", "SERVICE_REQUEST" or "PROBLEM" to it returns 400 Bad Request with a message such as Could not resolve type id 'INCIDENT' as a subtype of CreateGeneralRequestDto. Use POST /api/v1/requests/create for every other ticket type.

POST /api/v1/requests/create

Creates a ticket of any type. The request_type field in the body selects the ticket type and decides which additional fields are accepted (for example impact and urgency on incidents).

Create an incident

curl -X POST "https://{tenant}.atomicwork.com/api/v1/requests/create" \
     -H "X-Api-Key: <your-api-key>" \
     -H "Content-Type: application/json" \
     -d '{
           "request_type": "INCIDENT",
           "request_source": "API",
           "workspace_id": 48,
           "subject": "VPN is down for the London office",
           "description": "Users in London cannot connect to the VPN since 09:00 UTC."
         }'

Create a problem

curl -X POST "https://{tenant}.atomicwork.com/api/v1/requests/create" \
     -H "X-Api-Key: <your-api-key>" \
     -H "Content-Type: application/json" \
     -d '{
           "request_type": "PROBLEM",
           "request_source": "API",
           "workspace_id": 48,
           "subject": "Recurring VPN outages",
           "description": "Third VPN outage this month; root cause unknown."
         }'

Create a service request

curl -X POST "https://{tenant}.atomicwork.com/api/v1/requests/create" \
     -H "X-Api-Key: <your-api-key>" \
     -H "Content-Type: application/json" \
     -d '{
           "request_type": "SERVICE_REQUEST",
           "request_source": "API",
           "workspace_id": 48,
           "subject": "New laptop for a starter",
           "description": "Please provision a laptop for the new hire starting Monday."
         }'

Response

A successful call returns 200 OK (not 201 Created) with the created ticket, including its display_id (for example IOINC-169) and the resolved request_type.

Field reference

FieldTypeRequiredNotes
request_typestringYes on /requests/createOne of REQUEST, INCIDENT, SERVICE_REQUEST, PROBLEM. Must be the string enum name — the integer values used internally (for example 2 for incidents) are rejected. On POST /api/v1/requests it must be REQUEST or omitted.
workspace_idintegerRecommendedBody field. There is no X-Workspace-Id header. If omitted, the ticket is created in the tenant's default workspace — if that workspace has incidents or problems disabled, the call fails even though the workspace you intended has them enabled. Always set it explicitly.
request_sourcestringNoUse API for tickets created through the public API.
subjectstringRecommendedTicket title.
descriptionstringNoTicket body.
statusstringNoDefaults to the workspace's initial status.
prioritystringNoDefaults from the workspace configuration.
impact, urgencystringNoIncident-only. Default from the workspace configuration.
requesterintegerNoUser ID. Defaults to the owner of the API key.
assigneeintegerNoUser ID to assign the ticket to.
agent_groupintegerNoAgent group ID.
category, subcategory, cti_itemstringNoClassification hierarchy.
tagsinteger[]NoTag IDs.
custom_fieldsobjectNoCustom field values keyed by field key.

POST /api/v1/requests

Creates a general request. It accepts the same body as above, but request_type must be REQUEST or omitted. Prefer POST /api/v1/requests/create for new integrations so the same code path can create every ticket type.

curl -X POST "https://{tenant}.atomicwork.com/api/v1/requests" \
     -H "X-Api-Key: <your-api-key>" \
     -H "Content-Type: application/json" \
     -d '{
           "request_source": "API",
           "workspace_id": 48,
           "subject": "Question about expense policy",
           "description": "Where can I find the current expense limits?"
         }'

POST /api/v1/incidents is not available with API-key authentication and returns 400 with "URL Not Allowed". Use POST /api/v1/requests/create with "request_type": "INCIDENT" instead.