Skip to main content
POST
/
live-updates
Create Live Update
curl --request POST \
  --url https://playground.answeringagent.com/api/v1/live-updates \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "Temporary System Maintenance",
  "message": "We are currently performing system maintenance. Expected completion time is 2 PM.",
  "type": "announcement",
  "starts_at": "2025-07-25T14:00:00Z",
  "expires_at": "2025-07-25T16:00:00Z",
  "phone_number_ids": [
    1,
    2,
    3
  ]
}
'
{
  "data": {
    "id": 1,
    "title": "Temporary System Maintenance",
    "message": "We are currently performing system maintenance. Expected completion time is 2 PM.",
    "type": "announcement",
    "starts_at": "2025-07-25T14:00:00Z",
    "expires_at": "2025-07-25T16:00:00Z",
    "is_cancelled": false,
    "created_at": "2025-07-25T10:30:00Z",
    "updated_at": "2025-07-25T11:45:00Z",
    "phone_numbers": [
      {
        "id": 1,
        "name": "Main Office",
        "phone_number": "+1234567890"
      }
    ],
    "created_by": {
      "id": 1,
      "name": "John Doe",
      "email": "[email protected]"
    }
  },
  "message": "Live update created successfully."
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
title
string
required

Title of the live update

Required string length: 3 - 255
Example:

"Temporary System Maintenance"

message
string
required

Detailed message for the live update

Required string length: 10 - 2000
Example:

"We are currently performing system maintenance. Expected completion time is 2 PM."

type
enum<string>
required

Type of live update

Available options:
announcement,
wait_time,
flash_sale,
closure,
schedule_change
Example:

"announcement"

starts_at
string<date-time>
required

When the live update becomes active (ISO 8601 format)

Example:

"2025-07-25T14:00:00Z"

expires_at
string<date-time> | null

When the live update expires (null for no expiration, must be after starts_at)

Example:

"2025-07-25T16:00:00Z"

phone_number_ids
integer[] | null

Array of phone number IDs to apply this update to (empty array or null means all locations)

Maximum array length: 50
Example:
[1, 2, 3]

Response

Live update created successfully

data
object
message
string
Example:

"Live update created successfully."