Skip to content

Save a draft

Request

Save a draft someone wrote, such as an email: its subject and body. It is recorded as their own text. Send an Idempotency-Key so a retry saves one draft. Use this when someone asks to keep a draft in HRC Ledger. The subject is saved as the draft's title and the body as its one section. It is recorded as the key holder's own text with the key, never as written by the assistant. Answers 201 with the draft; the same Idempotency-Key and body again answers 200 with the same id.

Security
bearerKey
Headers
Idempotency-Keystring, [ 1 .. 128 ] characters

1 to 128 characters. A retry with the same key and body returns the first result; the same key with another body is 409.

Bodyapplication/jsonrequired
subjectstring, [ 1 .. 200 ] charactersrequired
purposestringrequired
Enum:"email""ad""note""call_opener""brief""assessment""proposal""thesis""general"
audiencestring, [ 1 .. 300 ] characters
bodystring, [ 1 .. 20000 ] charactersrequired
curl -i -X POST \
  https://docs.hrcledger.com/_mock/docs/openapi/api/v1/drafts \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "subject": "Imaging at Inova",
    "purpose": "email",
    "audience": "Inova'\''s CIO",
    "body": "We help imaging teams cut wait times."
  }'

Responses

A retry: the same Idempotency-Key and body as a 201 before it; the same id.

Bodyapplication/json
okanyrequired
Value:true
dataobject(PublicDraft)required
Response
{ "ok": true, "data": { "id": "Drf5tH8jKw2qR6mX9vBz", "url": "https://hrcledger.com/drafts/items/Drf5tH8jKw2qR6mX9vBz", "title": "Imaging at Inova", "purpose": "email", "audience": "Inova's CIO", "sections": [ … ], "subject": "Imaging at Inova", "body": "We help imaging teams cut wait times.", "evidence": [], "approval": null, "archived": false, "revisionNo": 1, "updatedAt": "2026-10-16T14:02:11.000Z" } }