CARESIGN INTEGRATION API

Your agreements.
Connected.

A practical guide to connecting your application to CareSign—from your first API request to the final signed document.

API v1REST · JSON · HTTPS
ONE CONNECTED WORKFLOW

Discover a published template

Send an agreement

Follow every step

Retrieve the signed PDF

Server-to-server · API key authentication
01

A connected signing workflow

Your application starts the agreement. CareSign takes care of the signing journey.

Your applicationCRM, HR system or backend
CareSign APIPrepare, send and track
Your recipientsReview and sign in a browser

Use a published template to create agreements, fill in business data, invite people by email or SMS, and retrieve the completed PDF. Recipients use their private invitation link; they do not need a CareSign staff account.

Start with a template. Prepare and publish it in the CareSign workspace. The API uses that saved publication, so every agreement starts from the version you selected.

Template

The reusable document and its recipient roles, such as “Customer”.

Publication

A frozen version of a template. Its slot IDs and field rules stay consistent.

Agreement

A specific document sent to real recipients. Its sent ID is called an envelopeId.

02

Get connected

You will need an API key, your CareSign address and a published template.

  1. Ask your System Admin for an API key.

    They select an active organization, a sender account and permissions in the System Admin portal. The sender must have completed their initial password change. The full secret is shown once.

  2. Choose the permissions you need.

    For the complete workflow, request templates:read, agreements:send, agreements:read and documents:read. Add agreements:create for separate draft creation or application-template import.

  3. Store the key in your backend.

    Use server-side configuration or a secret manager. Send it in the Authorization: Bearer YOUR_API_KEY header. Real keys begin with cs_live_. Never place the secret in frontend code, a URL or logs.

Your API base URL

Base URL
https://YOUR_CARESIGN_HOST/api/v1/integrations

Replace YOUR_CARESIGN_HOST with the web application address your administrator gives you. The default local address is http://127.0.0.1:3000/api/v1/integrations; remote applications need a reachable host.

Make a read-only connection check

Connection check · cURL
curl --fail-with-body "https://YOUR_CARESIGN_HOST/api/v1/integrations/connection" \
  -H "Authorization: Bearer $CARESIGN_API_KEY" \
  -H 'Accept: application/json'

A 200 response confirms access. The handshake reports configured capabilities without sending anything. Provider delivery still needs to be verified separately. This example expects your secret in the server environment variable CARESIGN_API_KEY.

Deployment & key lifecycle

Use staff authentication and apply the migrations shipped with your deployment. Sending, agreement status and completed downloads require signing to be enabled. Email recipients need configured email delivery; SMS recipients need an enabled SMS provider. SMS-only invitations do not require email readiness. Keys can expire after 1–365 days or have no automatic expiry. Revocation, organization/sender suspension and required password changes still block access. Rotate a key by testing its replacement for the same sender before revoking the old one.

03

Send your first agreement

Follow these steps in order. Keep the IDs returned at each step in your application.

1

Find a template

Call GET /templates?view=summary. Choose a non-archived template with a publication, then read GET /templates/{templateId} for its full published-version list.

2

Read the chosen publication

Call GET /templates/{templateId}/publications/{publishedVersion}. Use its slots and field definitions, resolving any roleKey and fieldKey lookup keys to their IDs. The template’s editable version is different from its published version.

3

Prepare the request

Generate and save a UUID idempotency key for this business agreement. Assign every published role slot, including copies. Save the example below as agreement-request.json and replace all sample values.

agreement-request.json
{
  "publishedVersion": 1,
  "title": "Service agreement",
  "idempotencyKey": "00000000-0000-4000-8000-000000000006",
  "assignments": [
    {
      "slotId": "00000000-0000-4000-8000-000000000002",
      "name": "Alex Morgan",
      "email": "[email protected]"
    }
  ]
}

Illustrative values only. Version 1 is not a discovery result. Use your publication’s slot IDs and provide any required exposed field values.

4

Send the agreement

Set CARESIGN_BASE_URL to the base URL above and TEMPLATE_ID to the chosen template ID. This request queues real invitations to the destinations in your JSON.

Send agreement · cURL
curl --fail-with-body \
  -X POST "$CARESIGN_BASE_URL/templates/$TEMPLATE_ID/send" \
  -H "Authorization: Bearer $CARESIGN_API_KEY" \
  -H 'Content-Type: application/json' \
  --data-binary @agreement-request.json

Save the returned draftId, envelopeId, version and actual recipient IDs. Continue with tracking and download.

Want to prepare before sending? Use POST /templates/{templateId}/agreements to create a draft. Promote it through the template send endpoint with the same key and request values.

04

Build your request

Draft creation and sending use the same strict JSON request structure.

publishedVersionRequired · integer

A positive published version of the chosen template.

titleRequired · text

A nonempty single-line title, up to 120 characters.

idempotencyKeyRequired · UUID

One saved key per intended agreement. Reuse it and the same body on retries.

assignmentsRequired · array

1–50 recipients, exactly one for every published slotId. Each needs a name (up to 120 characters) and the selected channel’s contact.

fieldValuesOptional · object

Map published integrationKey values to text, booleans or finite numbers (up to 200 keys). Required exposed fields must be supplied, even when a template default exists. Use publication validation rules and option IDs.

fieldRequirementsOptional · array

Up to 200 unique { fieldId, required } entries for opted-in requirementFields. Applied before prefill validation; every signer must keep a required signature.

editableMissingPrefillOptional · boolean

Defaults to false. Allows eligible missing optional prefill answers to be filled by the recipient when the published field is not read-only. Missing required values still fail validation.

messageOptional · object

Both subject (up to 200 characters) and body (up to 4000 characters). Omit to use the published message.

expiresInDaysOptional · integer

Signing deadline of 1–120 days; defaults to 30. This is separate from API-key expiry.

reminderDaysOptional · integer

Reminder interval of 1–30 days. Omit to use existing sending behavior.

Choose how each recipient is invited

Set deliveryMethod on each assignment to EMAIL (default), SMS or BOTH. Include email for EMAIL/BOTH and phone for SMS/BOTH. Adding another contact does not select another channel.

Core agreement phones use an international +country code and 8–15 digits; formatting separators are stripped. Email addresses are stored in lowercase. Destinations must be unique for the same recipient action and selected channel.

Optional smsMessage allows up to 1000 characters; CareSign appends the signing link. Optional emailPreferences requires a supported language code (for example, en, en-GB or bn) and accepts subject/body overrides up to 200/4000 characters.

Supported recipient email languages

ar, bg, cs, zh-CN, zh-TW, hr, da, nl, en, en-GB, et, fa, fi, fr, fr-CA, de, el, he, hi, hu, hy, id, it, ja, ko, lv, lt, ms, no, pl, pt, pt-BR, ro, ru, sr, sk, sl, es, es-419, sv, th, tr, uk, vi, bn

Core POST body limit: 32,768 bytes, including JSON formatting. Unknown properties are rejected. Omit send; the selected endpoint determines the action. Signatures, initials and generated signing dates cannot be supplied as prefill values.

05

The endpoint reference

All 15 routes, explained. Paths below are relative to your API base URL. Expand an endpoint for permissions and usage details.

Core workflow9 endpoints

GET/connectionCheck your connection

Confirm that your API key works without sending an invitation.

Permission
templates:read
Success
200 · JSON

Returns service, contractVersion, authenticated, signingEnabled, feature flags and deliveryConfiguration. Configuration flags describe enabled features; they do not contact a provider or prove that an email or SMS can be delivered.

GET/templatesFind your templates

List templates owned by the sender attached to your key.

Permission
templates:read
Success
200 · JSON

Use view=summary for a compact list. page defaults to 1 (maximum 10000); pageSize accepts 10, 25 or 50. Optional q searches up to 120 characters; filter accepts all, favorites or archived; sort accepts updated_desc or name_asc. scope is always restricted to the sender. Unknown query parameters are rejected. Check archived and publishedVersions before use; summary includes at most one publication version.

GET/templates/{templateId}Read a template

Read the template configuration and its available published versions.

Permission
templates:read
Success
200 · JSON

The top-level version is the editable revision. It is different from publishedVersion. Fetch the chosen publication to discover the exact recipient slots and API fields before sending.

GET/templates/{templateId}/publications/{publishedVersion}Discover a published version

Get the immutable recipient slots and automation fields for one publication.

Permission
templates:read
Success
200 · JSON

Returns templateId, publishedVersion, createdAt, slots, fields and requirementFields. Assign every slots[].slotId, including copy recipients. fields contains only opted-in prefill fields with integrationKey and validation rules. requirementFields lists fields that permit requirement overrides. slots[].roleKey (taken from the role name) and fields/requirementFields[].fieldKey (taken from the API field label), both locked once published, are stable keys, null when unset. Resolve them to slotId/fieldId, reject missing or ambiguous matches, and keep submitting values by integrationKey. A key grants no permission. Editing a template does not change an earlier publication.

POST/templates/{templateId}/agreementsCreate a prepared draft

Prepare an agreement without sending recipient invitations.

Permission
agreements:create
Success
201 · JSON

Send publishedVersion, title, idempotencyKey and complete assignments, with optional request fields described above. Returns draftId and source. To send this same draft, call the template send endpoint with the same key and request values. Do not include send: true. There is no public draft-ID send endpoint.

POST/templates/{templateId}/sendSend an agreement

Create or reuse a prepared draft and queue recipient invitations.

Permission
agreements:send
Success
200 · JSON

Uses the same body as draft creation. Returns draftId, source, envelopeId, current version and recipients with delivery details. The agreements:create scope is not also required. A successful response means invitations were queued, not delivered. Requires signing enabled, usable documents, complete assignments and readiness for each selected channel. No recipient signing URL is returned.

GET/agreements/{envelopeId}Read agreement progress

Follow the agreement, its recipients and its events.

Permission
agreements:read
Success
200 · JSON

Returns id, draftId, title, status, version, waitingFor, progress, updatedAt, expiresAt, senderName, activeStep, recipients, events and documents. progress counts non-copy recipients, including approvals. Document sha256 values refer to source documents, not the completed signed PDF. Use the sent envelopeId, not the draftId.

POST/agreements/{envelopeId}/resendResend an invitation

Send a fresh invitation to an existing recipient using the stored destination.

Permission
agreements:send
Success
200 · JSON

Body: recipientId, latest agreement version and a new UUID idempotencyKey. Retain the same key and original version for retries. Requires an unexpired SENT agreement and a recipient still in SENT; VIEWED and other states are rejected. Fresh resend/correction operations are limited to one per recipient per 60 seconds. A successful operation can be replayed without sending again. Returns envelopeId, version and recipients.

GET/agreements/{envelopeId}/completedDownload the signed PDF

Download the completed combined agreement as a binary PDF.

Permission
documents:read
Success
200 · PDF

Wait for COMPLETED, then request with Accept: application/pdf. Returns attachment Content-Disposition and Cache-Control: no-store. A not-ready or inaccessible agreement returns 404, not 202. Check the status and Content-Type before saving. Certificate, ZIP and separate signed-document endpoints are not exposed.

CareFlow applications6 endpoints

POST/application-templatesImport an application template

Import a mapped application PDF and publish a template with one caregiver signer.

Permission
agreements:create
Success
200 · JSON

Strict body: UUID idempotencyKey, trimmed name (1–120 characters), pdfBase64 (up to 28,000,000 characters), lowercase sha256 and 1–400 complete fieldSchema objects. Decoded PDF limit: 20,000,000 bytes; JSON limit: 30,000,000 bytes. Include a required SIGNATURE and valid field geometry. The service replaces document and recipient references. Normal processing and publication validation applies. Returns templateId and publishedVersion without sending. Preserve the exact body on retry; changed published mappings conflict. This is a specialized import, not a general template editing API.

GET/application-sms/readinessCheck application SMS setup

Read whether application SMS is configured.

Permission
agreements:send
Success
200 · JSON

Returns ready, origin, languages and hrReviewNotifications when the service is available. ready checks SMS enablement and CAREFLOW_APPLICATION_ORIGIN; it does not prove delivery. When absent, returns ready: false and origin: null.

POST/application-smsQueue an application SMS

Send a restricted CareFlow application or HR review notification.

Permission
agreements:send
Success
200 · JSON

Body limit: 4096 bytes. Required: UUID idempotencyKey, normalized US phone (+1 with valid area-code/exchange starting digits), canonical url (maximum 700 characters) and expiresAt (UTC, future, at most eight days ahead). Optional kind: caregiver (default) or hr-review; language: en (default), es, bn, ht or ru. URL origin must match configured CareFlow. Caregiver links use /apply/#invite= with a 40–100 character URL-safe token and no query. HR links use /ats/?applicationReview= with exactly one parameter (1–120 letters, digits, underscores, colons, dots or hyphens), no fragment, and require HR sign-in. Uses fixed copy; HR text is English. Returns messageId, phone, status, attempts and updatedAt. Keep the same body on retries; expired requests must use receipt lookup. This endpoint does not create the private link or accept custom SMS text.

GET/application-sms/requests/{idempotencyKey}Find an SMS by request key

Recover an application SMS receipt after an uncertain send response.

Permission
agreements:read
Success
200 · JSON

Use the original application SMS request UUID. Returns messageId, phone, status, attempts and updatedAt. Only messages for the same organization and sender are accessible; otherwise returns 404. This does not send another message.

GET/application-sms/{messageId}Read an application SMS receipt

Poll a queued application SMS using its message UUID.

Permission
agreements:read
Success
200 · JSON

Returns messageId, phone, status, attempts and updatedAt, restricted to the same organization and sender. Message IDs are different from agreement IDs. Poll within the shared per-key request budget.

GET/agreements/{envelopeId}/application-submissionExport application answers

Read mapped field answers after the application has completed signing.

Permission
agreements:read
Success
200 · JSON

Returns envelopeId and fields: [{ integrationKey, value }]. Includes prefill integrationKey and converted apiInputKey fields. Uses saved answers, then frozen defaults, then an empty string. Unmapped fields and signatures are omitted. Requires COMPLETED; unfinished agreements return 409, inaccessible agreements return 404. Download the signed PDF separately.

06

Track progress. Keep the signed copy.

Agreement progress and invitation delivery are separate signals.

Read agreement status · cURL
curl --fail-with-body "$CARESIGN_BASE_URL/agreements/$ENVELOPE_ID" \
  -H "Authorization: Bearer $CARESIGN_API_KEY"

Set ENVELOPE_ID to the sent agreement ID. Poll about every 15 seconds initially, then less often as appropriate. Stagger requests across agreements.

Receive progress in your own system.

Use signed webhooks for agreement, recipient and email/SMS delivery events. Follow the full receiver setup guide, signature examples and replay instructions.

Open Webhook Manual →
SENT
Signing is active. Check recipient delivery separately.
FINALIZING
All recipient actions are done; the PDF is being finalized. Keep polling.
COMPLETED
The signed output is ready. Download the combined PDF.
FINALIZATION_FAILED
Notify the operator for recovery. Do not automatically send a replacement.
DECLINED / VOIDED / EXPIRED
The workflow has ended. Stop ordinary polling.
Understand recipient delivery

SMS ACCEPTED and email SENT mean provider submission, not confirmed delivery. DELIVERED requires provider evidence. CareSign does not silently switch channels after failure. SMS states: QUEUED, SENDING, ACCEPTED, DELIVERED, FAILED, UNCERTAIN. Email states: QUEUED, SENDING, SENT, DELIVERED, FAILED, BOUNCED.

deliveryAttempts holds the latest invitation message for each used channel, including reminders/corrections, with provider submission counts. It is not a complete attempt history. Raw provider errors and signing URLs are excluded.

Recipient workflow states are BLOCKED, SENT, VIEWED, SIGNED, FILLED, APPROVED, DECLINED, CANCELLED, EXPIRED and COPY. Keep them separate from the agreement status. An actual recipient ID is different from a template slot ID.

Download completed PDF · cURL
curl --fail --silent --show-error \
  "$CARESIGN_BASE_URL/agreements/$ENVELOPE_ID/completed" \
  -H "Authorization: Bearer $CARESIGN_API_KEY" \
  -H 'Accept: application/pdf' \
  --output completed-agreement.pdf

Wait for COMPLETED before downloading. The response is PDF bytes with an attachment header, not a JSON URL. In automated downloads, verify HTTP status and content type, then rename a temporary file after success.

07

Make retries predictable

A timeout does not mean that nothing happened. Keep the request identity stable.

120

requests per minute, per API key

Shared across all integration operations and API processes.

  • One agreement, one UUID. Save the key and exact body before sending. Retry with both unchanged after a network failure or timeout. The key belongs in JSON, not an Idempotency-Key header.
  • Respect conflicts. Changing the publication, recipients, prefill, requirement overrides, editable-missing setting or send options can conflict with the same key. Reconcile partial success before replacing an agreement.
  • Wait when asked. A 429 includes Retry-After: 60. Wait at least that long. For transient service failures, use bounded retries with backoff.
  • Plan for the gateway deadline. The upstream deadline is 60 seconds. An uncertain mutation should reuse its key. Key rotation for the same organization and sender does not require a new agreement key.

Resending is its own operation. Use a fresh operation UUID for each intentional resend. Retries keep that UUID and the original version. Fresh resend/correction operations share a one-per-recipient, 60-second limit.

08

Know what to do next

Use the HTTP status and error details to choose your next action.

400

Check your request

Correct invalid UUIDs, unknown fields, missing assignments, invalid field values or an oversized body before retrying.

401

Check the API key

Use the complete secret with the exact Bearer prefix. Confirm that it has not expired or been revoked. Staff cookies cannot replace a key.

403

Check access

Confirm the key’s permission, an active organization and an active sender who has completed the initial password change. Call from your backend.

404

Check the resource

Verify the ID and route. Resources belonging to another sender are hidden. A completed PDF also returns 404 until ready.

409

Resolve the conflict

Check the publication, readiness and request identity. Reconcile an existing draft before changing the payload or creating a replacement.

429

Wait before retrying

Respect Retry-After: 60. Reduce polling and share the request budget across all operations using the key.

500 / 503

Retry with care

Use bounded retries with backoff for transient failures. Keep mutation keys and request bodies unchanged. Contact your operator if failures persist.

Typical JSON error response
{
  "error": {
    "code": "FORBIDDEN",
    "message": "API key does not allow this operation.",
    "requestId": "00000000-0000-4000-8000-000000000010"
  }
}

Record the HTTP status, error code, message, request ID and x-request-id header when available. Infrastructure can return non-JSON errors; handle them as failures. Keep API keys, private links and confidential documents out of logs and support messages.

What is outside the integration API?

Use the workspace for general template editing and administration. Apart from the specialized CareFlow template import, the API does not offer arbitrary uploads/preparation, an agreement list, signing URL retrieval, embedded signing, bulk send, agreement cancellation, recipient correction, certificate/ZIP download or user/key administration. Subscribe to signed webhooks or poll individual agreements for updates. Staff and System Admin routes use separate authentication.

Ready to connect your workflow?

Get a key from your administrator, then start with a read-only check.

Back to setup

API v1 · Documentation reviewed 17 November 2026 · Examples use placeholders. Feature availability depends on your deployment.