Attention Items

Draft a reply to an attention item

Draft the user's reply to the item's thread in their saved drafting style. Nothing is sent or saved. Optional body: `instruction` (≤300 characters, e.g. "shorter") and `draft: { subject, body }` to re

POST /v2/attention-items/{attentionItemId}/draft

Parameters

Path parameters

attentionItemId
string (uuid) required

Header parameters

Idempotency-Key
string
Optional. Accepted to dedupe retries on this endpoint. See apps/rest-api/src/shared/idempotency.ts.

Request body

Content-Type: application/json

instruction
string
draft
object
draft.subject
string
draft.body
string

Example

{
  "instruction": "string",
  "draft": {
    "subject": "string",
    "body": "string"
  }
}

Responses

200 — Successful response

Content-Type: application/json

data
object required
data.attentionItemReplyDraft
object required
data.attentionItemReplyDraft.subject
string required
data.attentionItemReplyDraft.body
string required
data.attentionItemReplyDraft.to
string | null required

Example

{
  "data": {
    "attentionItemReplyDraft": {
      "subject": "string",
      "body": "string",
      "to": "string"
    }
  }
}

400 — Request body failed validation.

Content-Type: application/json

(body)
any

401 — Missing or invalid API key.

Content-Type: application/json

(body)
any

403 — Valid key, insufficient permission.

Content-Type: application/json

(body)
any

404 — Resource does not exist.

Content-Type: application/json

(body)
any

409 — Request conflicts with the current state of the resource.

Content-Type: application/json

(body)
any

429 — Rate limit exceeded.

Content-Type: application/json

(body)
any

500 — Unexpected server error.

Content-Type: application/json

(body)
any

Code samples

curl https://api.prod.getdex.com/v2/attention-items/00000000-0000-0000-0000-000000000000/draft \
  --request POST \
  --header 'Authorization: Bearer YOUR_API_KEY' \
  --header 'Content-Type: application/json' \
  --data '{
  "instruction": "string",
  "draft": {
    "subject": "string",
    "body": "string"
  }
}'
Copyright © 2026