Add Delivery Status

Add Delivery Status

Required scope: public-api:write

Description

This endpoint allows an external system to send updates about a delivery build to Livingdocs.

Delivery builds are initiated by users within the Livingdocs editor and can be configured to notify an external system. Through this endpoint, external systems can report back to Livingdocs regarding the status of a triggered task or request further clarification by providing user choices. For more information on how to set up and use delivery builds, please refer to our guide.

Curl Example
ACCESS_TOKEN=ey1234
curl -k -X POST "https://server.livingdocs.io/api/v1/documents/:documentId/addDeliveryStatus" \
  -H "Authorization: Bearer $ACCESS_TOKEN" \
  -H "Content-Type: application/json; charset=utf-8" \
  --data-binary @- << EOF
  {
    "reportId": "2SG2MAA9RwPn",
    "publicationId": 524,
    "deliveryHandle": "web",
    "status": "success",
    "message": "Message with <strong>html</strong>"
  }
EOF

Endpoint

POST api/v1/documents/:documentId/addDeliveryStatus

Parameters

NameTypeRequiredNotes
:documentIdintegerx
reportIdstringIf provided, this will update the matching delivery build; otherwise, it will create a new one.
publicationIdinteger(x)Required for delivery builds of type publication
deliveryHandlestringx
statusstringxOne of: “success”, “failed”, “aborted” (Added in: release-2024-07), “in-progress”
messagestringString or sanitized HTML (supports <em>, <strong>, <a> and <br> tags)
userChoicesArray<{label: string, value: string}>An array of options given to the user to choose from. This parameter is only allowed when status is set to “in-progress”. (Added in: release-2024-07)

Response

200
OK
api/v1/documents/222/addDeliveryStatus
{reportId: '0TAW2ORdNjuM'}