Skip to content

Update a TOIL request

This page documents the REST API v2 method that modifies an existing TOIL request. The endpoint is PATCH /v2/toil/{id}. It requires the toil:write scope, and the acting user is either the API key owner or the user named in X-On-Behalf-Of. The call waits for the change: a completed update returns the TOIL request with 200, while a still-running or unreadable result returns 202 Accepted with an operation to poll.

How the update works

This is a partial update, not a replacement. Include at least one field, and include only the fields whose values should change. Anything left out of the body stays as it is on the stored request, so there is no need to resend the full record.

Time-of-day values follow an all-or-nothing rule. They are valid only when isFullDayLeave is false, and in that case startHour, startMinute, endHour and endMinute must all be present. If isFullDayLeave is absent, the request keeps whatever full-day or part-day times it already has. Sending isFullDayLeave as true converts the request to full days.

Authorization and headers

Send the API key as Authorization: Bearer vt_live_<secret>. The required scope is toil:write. The key owner's role limits what the key can do.

The optional Idempotency-Key header lets a write be retried without duplicating the effect. Each key is kept for 24 hours per API key. A retry that uses the same key and an identical request inside that window returns the original response and adds the Idempotent-Replayed header. Three failures are specific to this header: 422 IDEMPOTENCY_KEY_REUSED when the key is paired with a different request, 409 IDEMPOTENCY_REQUEST_IN_PROGRESS when the first request is still running, and 400 INVALID_IDEMPOTENCY_KEY when the key itself is invalid.

The optional X-On-Behalf-Of header identifies the user the write is made for. Using it needs the users:act-on-behalf scope, and the key owner must manage that target user; if either condition fails, the call returns 403 ON_BEHALF_OF_NOT_ALLOWED. GET requests ignore this header.

Request fields

The path parameter id is required and identifies the TOIL request. The request body is application/json and accepts the following fields, all optional individually but with at least one required:

  • leaveTypeId: the ID of a leave type with TOIL enabled in the user's leave policy.
  • startDate: a date in YYYY-MM-DD format.
  • endDate: a date in YYYY-MM-DD format.
  • isFullDayLeave: true for full days, false for part of a day. When false, startHour, endHour, startMinute and endMinute are required. The time fields are rejected unless isFullDayLeave is false; without isFullDayLeave the stored times are kept.
  • startHour: start hour in the user's time zone (24h format), only when isFullDayLeave is false. Range 0 to 23.
  • endHour: end hour in the user's time zone (24h format), only when isFullDayLeave is false. Range 0 to 24. A request that finishes at midnight is expressed as endHour 24 with endMinute 0. Where the TOIL policy is booked in half days, the request has to span exactly 4 hours.
  • startMinute: start minutes in the user's time zone, only when isFullDayLeave is false. Range 0 to 59.
  • endMinute: end minutes in the user's time zone, only when isFullDayLeave is false. Range 0 to 59.
  • reason: the reason for the TOIL; may be empty.

Field and control map

Use this map to decide what to send and what the server will keep:

  • Omit a field to keep its current value. At least one field must be present.
  • To change a request to part of a day, send isFullDayLeave: false plus startHour, startMinute, endHour and endMinute. All four time fields are required together.
  • To change a request to full days, send isFullDayLeave: true. Do not send the time fields with it.
  • To change the leave type, send leaveTypeId for a leave type with TOIL enabled in the user's policy.
  • To change the date range, send startDate and/or endDate in YYYY-MM-DD format.
  • To change the reason, send reason; an empty value is allowed.
  • If you omit isFullDayLeave, the stored full-day or part-day times are kept, even if you send time fields.

Worked example: change a request to a part-day window

The following example changes an existing TOIL request to a part-day window from 10:00 to 16:30. It sends isFullDayLeave: false and all four time fields, with no other fields, so the request's dates, leave type and reason keep their current values. The path uses a placeholder id that must be replaced with the real TOIL request ID. The Authorization header must contain the full bearer key.

The request body is:

{ "isFullDayLeave": false, "startHour": 10, "startMinute": 0, "endHour": 16, "endMinute": 30 }

If the update completes, the response is the TOIL request with 200. If the update is still running or its result cannot be read back yet, the response is 202 with an operation object to poll.

Responses

A completed update returns 200 application/json with the TOIL request. The response includes the request ID, user ID, approver ID, leave type ID, start and end dates, full-day flag, optional time fields, duration in working days, location and department IDs, status, reason, status reason, approval date and creation timestamp.

A 202 application/json response returns an operation object with an id, a status and a url. The Location header carries the same URL as operation.url. Poll it until the status is SUCCEEDED or FAILED. A status of UNKNOWN means no result arrived within 15 minutes; the change may or may not have been applied, so read the resource to check. A result that arrives later still changes it to SUCCEEDED or FAILED.

Error responses use the standard error envelope with error.code, error.name, error.description, error.resolution, error.requestId and optional error.details.

Failure distinctions

The endpoint can fail for several different reasons. Use this table to tell them apart:

  • 400 VALIDATION_ERROR: a query parameter, body field or header failed validation. Fix the fields listed in details.fields and send the request again.
  • 401 UNAUTHORIZED: the API key is missing, malformed or not recognized. Send a valid API key in the Authorization header as Bearer followed by the full vt_live_ key.
  • 403 ON_BEHALF_OF_NOT_ALLOWED: the X-On-Behalf-Of request is not allowed. Check the users:act-on-behalf scope and whether the key owner manages the target user.
  • 403 FORBIDDEN: the acting user may not perform the action.
  • 404 RESOURCE_NOT_FOUND: the TOIL request does not exist or is outside the key's data reach. Check the ID and that the key owner can see it.
  • 409 CONFLICT: the request conflicts with the current state of the resource. Read the resource again and retry with up-to-date values.
  • 422 TOIL_NOT_ALLOWED: TOIL is not enabled for the leave type.
  • 422 TOIL_OVERLAP: the request overlaps another TOIL request.
  • 422 TOIL_INVALID_REQUEST: the TOIL request is invalid.
  • 422 TOIL_REASON_REQUIRED: a reason is required.
  • 422 TOIL_REQUEST_NOT_OPEN: the TOIL request is not open for changes.
  • 422 REQUEST_REJECTED: the request was rejected.
  • Idempotency-Key codes: 422 IDEMPOTENCY_KEY_REUSED, 409 IDEMPOTENCY_REQUEST_IN_PROGRESS and 400 INVALID_IDEMPOTENCY_KEY.
  • 429 RATE_LIMITED: too many requests were sent in a short time. Wait a few seconds and retry, using the same Idempotency-Key for writes.
  • 500 INTERNAL_ERROR: something went wrong on the server side. Retry later, and if it keeps happening, contact support and quote the requestId.

Retry and polling checklist

Before retrying a failed update, check the following:

  1. If the response is 400 VALIDATION_ERROR, read details.fields and correct each listed field before sending again.
  2. If the response is 403 ON_BEHALF_OF_NOT_ALLOWED, confirm the users:act-on-behalf scope and that the key owner manages the target user.
  3. If the response is 404 RESOURCE_NOT_FOUND, confirm the TOIL request ID and that the key owner can see the request.
  4. If the response is 409 CONFLICT, read the resource again and retry with up-to-date values.
  5. If the response is 422 TOIL_REQUEST_NOT_OPEN, the request is no longer open for changes; do not retry the same update.
  6. If the response is 422 TOIL_OVERLAP, adjust the dates or times so the request does not overlap another TOIL request.
  7. If the response is 422 TOIL_REASON_REQUIRED, add a reason.
  8. If the response is 429 RATE_LIMITED, wait a few seconds and retry with the same Idempotency-Key.
  9. If the response is 202, poll operation.url until the status is SUCCEEDED or FAILED. If the status is UNKNOWN, read the resource to check whether the change was applied.
  10. If the response is 500 INTERNAL_ERROR, retry later and quote the requestId when contacting support.
Field and control map
FieldTypeWhen to sendEffect
leaveTypeIdstringTo change the leave typeMust be a leave type with TOIL enabled in the user's leave policy
startDatestring (YYYY-MM-DD)To change the start dateDate in YYYY-MM-DD format
endDatestring (YYYY-MM-DD)To change the end dateDate in YYYY-MM-DD format
isFullDayLeavebooleanTo switch between full days and part of a daytrue turns the request into full days; false requires all four time fields
startHourinteger (0-23)Only with isFullDayLeave: falseStart hour in the user's time zone (24h format)
endHourinteger (0-24)Only with isFullDayLeave: falseEnd hour in the user's time zone (24h format); use 24 with endMinute 0 for midnight
startMinuteinteger (0-59)Only with isFullDayLeave: falseStart minutes in the user's time zone
endMinuteinteger (0-59)Only with isFullDayLeave: falseEnd minutes in the user's time zone
reasonstringTo change the reasonMay be empty

All body fields are optional individually, but at least one field is required. Omitted fields keep their current value. The time fields are accepted only together with isFullDayLeave: false, and then all four are required.

Frequently asked questions

Which scope does the update endpoint require?

The endpoint requires the toil:write scope. The API key is sent as Authorization: Bearer vt_live_<secret>, and the key owner's role limits what the key can do.

Can I send only the fields I want to change?

Yes. The body must contain at least one field, and you include only the ones you intend to alter. The server applies your values on top of the request as it currently stands, so any field you leave out retains its existing value.

When are the time fields accepted?

Time-of-day values are valid only when isFullDayLeave is false, and in that case all four (startHour, startMinute, endHour, endMinute) must be supplied. If isFullDayLeave is omitted, the request keeps its existing full-day or part-day times. Sending isFullDayLeave: true converts the request to full days.

What should I do when the response is 202?

A 202 response returns an operation object with an id, a status and a url. The Location header carries the same URL as operation.url. Poll it until the status is SUCCEEDED or FAILED. A status of UNKNOWN means no result arrived within 15 minutes; the change may or may not have been applied, so read the resource to check.

How does Idempotency-Key make retries safe?

Each key is stored for 24 hours per API key. If you resend the same key with an identical request inside that window, the original response is replayed and carries the Idempotent-Replayed header. Pairing the key with a different request yields 422 IDEMPOTENCY_KEY_REUSED; resending while the first request is still running yields 409 IDEMPOTENCY_REQUEST_IN_PROGRESS; a malformed key yields 400 INVALID_IDEMPOTENCY_KEY.

What does X-On-Behalf-Of require?

The header identifies the user the write is carried out for. It needs the users:act-on-behalf scope, and the key owner has to manage the target user; if either is missing, the call returns 403 ON_BEHALF_OF_NOT_ALLOWED. GET requests disregard this header.

Why does the endpoint return 404 RESOURCE_NOT_FOUND?

The TOIL request does not exist or is outside the key's data reach. Check the ID and that the key owner can see the request.

What should I do after a 409 CONFLICT?

The request conflicts with the current state of the resource. Read the resource again and retry with up-to-date values.

curl -X PATCH "$API_BASE_URL/v2/toil/string" \
  -H "Authorization: Bearer " \
  -H "Content-Type: application/json" \
  -d '{
    "isFullDayLeave": false,
    "startHour": 10,
    "startMinute": 0,
    "endHour": 16,
    "endMinute": 30
  }'
{
  "data": {
    "id": "toilRequest-3b8e6c1a-2d4f-4b7a-9c5e-8f1a2b3c4d5e",
    "userId": "user-63b17e97-d38b-4586-8498-bb4f5d2e2c14",
    "approverId": "user-0f3a9c1e-6c2b-4a5d-9e7f-1b2c3d4e5f60",
    "leaveTypeId": "leaveType-fcc1e5c5-ba93-479d-bd58-8f860ba10615",
    "startDate": "2026-11-07",
    "endDate": "2026-11-07",
    "isFullDayLeave": true,
    "durationWorkingDays": 1,
    "locationId": "location-79c77ac8-e5bf-479f-9488-648a58379ff1",
    "departmentId": "team-0a21c25e-6925-4a5b-90ee-ecf82096c4f6",
    "status": "APPROVED",
    "reason": "Worked on the weekend release",
    "statusReason": null,
    "approvalDate": "2026-11-09T08:30:00.000Z",
    "createdAt": "2026-11-08T17:45:12.000Z"
  }
}
{
  "operation": {
    "id": "pa_3f1c2b9e-8a47-4d5e-9c61-2b7f0e4a1d93",
    "status": "PENDING",
    "url": "/v2/operations/pa_3f1c2b9e-8a47-4d5e-9c61-2b7f0e4a1d93"
  }
}
{
  "error": {
    "code": "VALIDATION_ERROR",
    "name": "ValidationError",
    "description": "Example post details.",
    "resolution": "Fix the fields listed in details.fields and send the request again.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef",
    "details": {
      "fields": [
        {
          "path": "startDate",
          "message": "\"startDate\" is required"
        }
      ]
    }
  }
}
{
  "error": {
    "code": "UNAUTHORIZED",
    "name": "Unauthorized",
    "description": "Example post details.",
    "resolution": "Send a valid API key in the Authorization header as Bearer followed by the full vt_live_ key.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}
{
  "error": {
    "code": "INSUFFICIENT_SCOPE",
    "name": "InsufficientScope",
    "description": "Example post details.",
    "resolution": "Add the scopes listed in details.requiredScopes to the key in the OnlyLeave dashboard.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef",
    "details": {
      "requiredScopes": [
        "leaves:write"
      ]
    }
  }
}
{
  "error": {
    "code": "RESOURCE_NOT_FOUND",
    "name": "ResourceNotFound",
    "description": "Example post details.",
    "resolution": "Check the ID of the resource named in details.resource and that the key owner can see it.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}
{
  "error": {
    "code": "CONFLICT",
    "name": "Conflict",
    "description": "Example post details.",
    "resolution": "Read the resource again and retry with up-to-date values.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}
{
  "error": {
    "code": "LEAVE_NEGATIVE_BALANCE",
    "name": "LeaveNegativeBalance",
    "description": "Example post details.",
    "resolution": "Shorten the leave, use a different leave type, or ask an admin to adjust the quota.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}
{
  "error": {
    "code": "RATE_LIMITED",
    "name": "RateLimited",
    "description": "Example post details.",
    "resolution": "Wait a few seconds and retry, using the same Idempotency-Key for writes.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}
{
  "error": {
    "code": "INTERNAL_ERROR",
    "name": "InternalError",
    "description": "Example post details.",
    "resolution": "Retry later, and if it keeps happening, contact OnlyLeave support and quote the requestId.",
    "requestId": "c6af9ac6-7b61-11e6-9a41-93e8deadbeef"
  }
}

id

FieldTypeRequiredDescriptionConstraints
idstringYesresource ID.

Idempotency-Key

FieldTypeRequiredDescriptionConstraints
Idempotency-KeystringNooptional key (1 to 255 printable ASCII characters) that makes a write request safe to retry. Keys are retained for 24 hours per API key. Retrying with the same key and the same request within those 24 hours replays the original response (with the Idempotent-Replayed header). Reusing the key with a different request returns 422 IDEMPOTENCY_KEY_REUSED ; retrying while the first request is still running returns 409 IDEMPOTENCY_REQUEST_IN_PROGRESS ; an invalid key returns 400 INVALID_IDEMPOTENCY_KEY .1 <= length <= 255

X-On-Behalf-Of

FieldTypeRequiredDescriptionConstraints
X-On-Behalf-OfstringNoID of the user the write is performed for. Requires the users:act-on-behalf scope, and the key owner must manage the target user; otherwise the request fails with 403 ON_BEHALF_OF_NOT_ALLOWED . Ignored on GET requests.

body

FieldTypeRequiredDescriptionConstraints
bodyobjectYes1 <= properties
body.leaveTypeIdstringNothe ID of a leave type with TOIL enabled in the user's leave policy
body.startDatestringNodate in YYYY-MM-DD format^([12]\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01]))$
Format: date
body.endDatestringNodate in YYYY-MM-DD format^([12]\d{3}-(0[1-9]|1[0-2])-(0[1-9]|[12]\d|3[01]))$
Format: date
body.isFullDayLeavebooleanNotrue for full days, false for part of a day. When false, startHour, endHour, startMinute and endMinute are required. The time fields are rejected unless isFullDayLeave is false; without isFullDayLeave the stored times are kept.
body.startHourintegerNostart hour in the user's time zone (24h format), only when isFullDayLeave is false0 <= value <= 23
body.endHourintegerNoend hour in the user's time zone (24h format), only when isFullDayLeave is false. Use 24 with endMinute 0 for a TOIL request that ends at midnight. On a TOIL policy booked in half days, the request must last exactly 4 hours.0 <= value <= 24
body.startMinuteintegerNostart minutes in the user's time zone, only when isFullDayLeave is false0 <= value <= 59
body.endMinuteintegerNoend minutes in the user's time zone, only when isFullDayLeave is false0 <= value <= 59
body.reasonstringNothe reason for the TOIL, may be empty

response

FieldTypeRequiredDescriptionConstraints
responseobject
response.dataobjectNo
response.data.idstringYesTOIL request ID
response.data.userIdstringYesan ID of the user who earned the TOIL
response.data.approverIdstring | nullYesan ID of the approver, null until the request is approved
response.data.approverId[variant1]stringan ID of the approver, null until the request is approved
response.data.approverId[variant2]nullan ID of the approver, null until the request is approved
response.data.leaveTypeIdstringYesthe ID of the leave type the TOIL is added to
response.data.startDatestringYesdate in YYYY-MM-DD formatdate
response.data.endDatestringYesdate in YYYY-MM-DD formatdate
response.data.isFullDayLeavebooleanYestrue if the TOIL covers full days, false if it covers part of a day
response.data.startHournumberNostart hour in the user's time zone (in 24h format), returned only when isFullDayLeave is false
response.data.endHournumberNoend hour in the user's time zone (in 24h format), returned only when isFullDayLeave is false
response.data.startMinutenumberNostart minutes in the user's time zone, returned only when isFullDayLeave is false
response.data.endMinutenumberNoend minutes in the user's time zone, returned only when isFullDayLeave is false
response.data.durationWorkingDaysnumberNothe duration of the TOIL in days. A full-day TOIL counts each day it covers; a part-day TOIL converts its hours using an 8-hour day, whatever the user's working hours.
response.data.locationIdstringYesthe ID of the user's location when the TOIL request was sent
response.data.departmentIdstringYesthe ID of the user's department when the TOIL request was sent
response.data.statusstringYesTOIL request status"OPEN" | "APPROVED" | "DENIED" | "CANCELLED" | "EXPIRED" | "DELETED"
response.data.reasonstring | nullYesthe reason the user gave for the TOIL. Requires the leaves:read-reason scope, which covers leaves and TOIL alike; without it the value is null .
response.data.reason[variant1]stringthe reason the user gave for the TOIL. Requires the leaves:read-reason scope, which covers leaves and TOIL alike; without it the value is null .
response.data.reason[variant2]nullthe reason the user gave for the TOIL. Requires the leaves:read-reason scope, which covers leaves and TOIL alike; without it the value is null .
response.data.statusReasonstring | nullYesthe reason given when the TOIL request was denied or cancelled, null when none was given. Requires the leaves:read-reason scope; without it the value is null .
response.data.statusReason[variant1]stringthe reason given when the TOIL request was denied or cancelled, null when none was given. Requires the leaves:read-reason scope; without it the value is null .
response.data.statusReason[variant2]nullthe reason given when the TOIL request was denied or cancelled, null when none was given. Requires the leaves:read-reason scope; without it the value is null .
response.data.approvalDatestring | nullYesa timestamp in the ISO 8601 format, null until the request is approveddate-time
response.data.approvalDate[variant1]stringa timestamp in the ISO 8601 format, null until the request is approveddate-time
response.data.approvalDate[variant2]nulla timestamp in the ISO 8601 format, null until the request is approveddate-time
response.data.createdAtstringYesa timestamp in the ISO 8601 formatdate-time

response

FieldTypeRequiredDescriptionConstraints
responseobjectReturned with HTTP 202 when a write operation is still running, or succeeded but its result could not be read back yet. The Location header carries the same URL as operation.url . Poll it until the status is SUCCEEDED or FAILED .
response.operationobjectYes
response.operation.idstringYes
response.operation.statusstringYesoperation status. UNKNOWN means no result arrived within 15 minutes; the change may or may not have been applied, so read the resource to check. A result that arrives later still changes it to SUCCEEDED or FAILED.Allowed values: "PENDING" | "SUCCEEDED" | "FAILED" | "UNKNOWN"
response.operation.urlstringYes

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo

response

FieldTypeRequiredDescriptionConstraints
responseobjectError envelope returned by every endpoint, including authentication and rate limit errors. error.code is one of the codes in x-error-catalog .
response.errorobjectYes
response.error.codestringYesstable machine-readable error code
response.error.namestringYesshort human-readable error name
response.error.descriptionstringYeswhat went wrong
response.error.resolutionstringYeshow to fix the problem
response.error.requestIdstringYesrequest ID, include it when contacting support
response.error.detailsobjectNooptional additional information specific to the error code
response.error.details.[key: string]anyNo