Response Drafts

Use the response drafts endpoint to create or update the pending response for an existing conversation.

Create or update a response draft

POST /api/v2/organizations/{organization_id}/conversations/{conversation_id}/response-drafts

This endpoint creates or updates the pending response draft for a specific conversation.

Response drafts use body_html for the reply body. For email conversations, this field may contain HTML content.

autosend_draft and add_notification are mutually exclusive. If autosend_draft=true, set add_notification=false.

When autosend_draft=true, the draft is queued immediately by setting scheduled_send_at. Otherwise, it is saved for review.

This endpoint maintains one response draft row per conversation.

Create response draft request

curl -X POST https://api.hyperrep.ai/api/v2/organizations/HR_id_example_organization_id/conversations/HR_id_example_conversation_id/response-drafts \
  -H "X-API-KEY: your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "body_html": "<p>Hi Diana, thanks for the follow-up. We can do Tuesday at 2pm.</p>",
    "cc_emails": [],
    "bcc_emails": [],
    "autosend_draft": false,
    "add_notification": true
  }'

Example response (saved response draft)

{
  "response_id": "HR_id_example_response_draft_id",
  "conversation_id": "HR_id_example_conversation_id",
  "scheduled_to_send": false,
  "scheduled_send_at": null
}

Example response (queued response draft)

{
  "response_id": "HR_id_example_response_draft_id",
  "conversation_id": "HR_id_example_conversation_id",
  "scheduled_to_send": true,
  "scheduled_send_at": "2026-05-22T20:45:03.221009Z"
}

List response drafts

GET /api/v2/organizations/{organization_id}/conversations/{conversation_id}/response-drafts

Returns a paginated collection of response drafts for one conversation.

Supports optional limit, cursor, start_date, and end_date query parameters.

List response drafts request

curl -G https://api.hyperrep.ai/api/v2/organizations/HR_id_example_organization_id/conversations/HR_id_example_conversation_id/response-drafts \
  -H "X-API-KEY: your-api-key" \
  --data-urlencode "limit=25"

Example response

{
  "data": [
    {
      "response_id": "HR_id_example_response_draft_id",
      "conversation_id": "HR_id_example_conversation_id",
      "body_html": "<p>Hi Diana, thanks for the follow-up. We can do Tuesday at 2pm.</p>",
      "recipient_name": "Diana Prince",
      "recipient_email": "[email protected]",
      "recipient_phone_number": "513-867-5309",
      "cc_emails": [],
      "bcc_emails": [],
      "scheduled_send_at": null,
      "created_at": "2026-05-21T14:35:00Z"
    }
  ],
  "pagination": {
    "limit": 25,
    "cursor": null,
    "next_cursor": null,
    "has_more": false
  }
}

Get a response draft

GET /api/v2/organizations/{organization_id}/conversations/{conversation_id}/response-drafts/{response_id}

Returns one response draft by ID for the specified conversation.

If the draft has already been promoted into a message, this endpoint returns 404 with guidance to use the message route.

If the ID belongs to a message draft instead of a response draft, this endpoint also returns 404 with guidance to use the message drafts route.

Get response draft request

curl https://api.hyperrep.ai/api/v2/organizations/HR_id_example_organization_id/conversations/HR_id_example_conversation_id/response-drafts/HR_id_example_response_draft_id \
  -H "X-API-KEY: your-api-key"

Example response

{
  "response_id": "HR_id_example_response_draft_id",
  "conversation_id": "HR_id_example_conversation_id",
  "body_html": "<p>Hi Diana, thanks for the follow-up. We can do Tuesday at 2pm.</p>",
  "recipient_name": "Diana Prince",
  "recipient_email": "[email protected]",
  "recipient_phone_number": "513-867-5309",
  "cc_emails": [],
  "bcc_emails": [],
  "scheduled_send_at": null,
  "created_at": "2026-05-21T14:35:00Z"
}

Delete a response draft

DELETE /api/v2/organizations/{organization_id}/conversations/{conversation_id}/response-drafts/{response_id}

Deletes one response draft by ID for the specified conversation.

On success, the API returns 204 No Content.

If the draft has already been promoted into a message, this endpoint returns 404 with guidance to use the messages route.

If the draft is currently sending, this endpoint returns 400.

Delete response draft request

curl -X DELETE https://api.hyperrep.ai/api/v2/organizations/HR_id_example_organization_id/conversations/HR_id_example_conversation_id/response-drafts/HR_id_example_response_draft_id \
  -H "X-API-KEY: your-api-key"

Draft lifecycle lookups

  • Name
    Promotion (response draft -> message)
    Description

    After a response draft is sent and promoted into a conversation message, the draft is no longer returned by response-draft detail lookups. You receive 404 plus a route hint to the message endpoint.

  • Name
    Cross-route ID lookup
    Description

    If you call response-draft detail with an ID that actually belongs to a message draft, you receive 404 plus a route hint to the message-drafts detail endpoint.

  • Name
    Conversation-scoped behavior
    Description

    Response drafts are scoped to a specific conversation route, so lookup checks always validate both the organization and conversation context.

Request body fields

  • Name
    body_html
    Description

    Required response draft HTML body content.

  • Name
    cc_emails
    Description

    Optional list of CC email addresses.

  • Name
    bcc_emails
    Description

    Optional list of BCC email addresses.

  • Name
    autosend_draft
    Description

    When true, the response draft is queued for asynchronous delivery immediately.

  • Name
    add_notification
    Description

    Applies only when autosend_draft=false. If autosend_draft=true, this must be false.

Response fields

  • Name
    response_id
    Description

    Encoded response draft identifier.

  • Name
    conversation_id
    Description

    Encoded conversation identifier for the draft’s session.

  • Name
    scheduled_to_send
    Description

    true when the response draft has been queued for delivery.

  • Name
    scheduled_send_at
    Description

    Timestamp when the response draft was queued. null when saved for later review.

Was this page helpful?