Writing data
A key with the enrollments:write scope can update enrollment records, add notes, and create and complete follow-ups. Each change has the same effects as the same edit made in EnrollPilot: the activity timeline, the audit log, notifications to assignees and revalidation tasks all update.
What a write key can change
| Operation | operationId | What it does |
|---|---|---|
PATCH /enrollments/{id} | updateEnrollment | Change status, status reason, due date, revalidation date, effective date, TIN status or case number, and add a note |
GET /enrollments/{id}/follow-ups | listEnrollmentFollowUps | List the follow-ups and tasks on an enrollment. Needs enrollments:read only |
POST /enrollments/{id}/follow-ups | createEnrollmentFollowUp | Create a follow-up or task on an enrollment |
POST /follow-ups/{id}/complete | completeFollowUp | Complete a follow-up or task, optionally with a closing note and the next follow-up |
Nothing else can be written. Providers, provider groups, group enrollments, documents, requirement checklists and assignees are read only, and enrollments cannot be created or deleted through the API.
Getting a write key
An organization admin creates the key on the API keys page and selects enrollments:write. That scope requires enrollments:read, so the key can read back what it wrote. When write access is selected, the dialog shows a warning and the admin must tick a confirmation before the key can be created. The key list then shows the key with a "Can write" badge.
Existing keys never gain write access. To give an integration write access, create a new key. To take it away, revoke the key.
Who a change is recorded under
- Every change is recorded under the admin who created the key. In the activity timeline it reads as that admin's name followed by "(via API)".
- In the audit log the event shows the admin's name with a "via API" badge. Hovering the badge shows the key's 12-character prefix, which matches the key on the API keys page. The audit log can be filtered to show only API changes.
- When a status changes, every assignee on the enrollment is notified, including the admin who created the key.
- Before each write, EnrollPilot checks that the admin who created the key is still an active member of the organization with the Staff, Manager or Admin role. If not, the write returns
403 key_owner_inactiveand nothing is written. The key can still read. Create a new key from an active admin account.
Read before you write
Fetch the enrollment first and send back what you read. Both fields are optional, but they stop a change from landing on a record that someone else has edited in the meantime.
expectedStatus: the status you saw. If the enrollment's status is now different, the request returns 409. Always send it when you change status.expectedUpdatedAt: theupdatedAtvalue from your read. If the enrollment has changed since, the request returns 409.
A 409 conflict writes nothing at all, including any note sent in the same request. Read the enrollment again, check the change still applies, and retry with the new values.
curl -sS "https://app.enrollpilot.com/api/v1/enrollments/clv2h9c1k0007abcd1234efgh" \
-H "Authorization: Bearer epk_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"{
"error": {
"code": "conflict",
"message": "This enrollment's status is now APPROVED, not SUBMITTED."
}
}Repeated requests
Identical notes or follow-ups sent within 2 minutes of each other on the same enrollment are saved once. Change the text, or wait, to record a second one.
A repeated follow-up returns 200 with the follow-up that already exists instead of 201. Any difference in a field, such as the contact or the reference id, creates a separate follow-up. Completing a follow-up that is already complete returns 409 already_complete.
Request format and limits
- Send bodies as JSON with
Content-Type: application/json. Anything else returns415 unsupported_media_type. - Bodies are limited to 32 KB. A larger body returns
413 payload_too_large. - Unknown fields are rejected with 400 and the field is named in the message, so a misspelled field never looks like it worked.
- Writes are limited to 30 per minute per key and 60 per minute across all of an organization's keys, on top of the normal request limits. Over the limit, a write returns 429 with
Retry-After: 60. - If EnrollPilot cannot enforce the write limits, writes return
503 api_temporarily_unavailablewithRetry-After: 30and nothing is written. Reads are not affected. Retry after the interval.
The full list of codes is on Errors and rate limits.
Update an enrollment
Send at least one field or a note. Leave a field out to keep its current value, or send null to clear it. The response is the updated enrollment. A request whose values all match the current record returns 200 and writes nothing.
| Field | Type | Rules |
|---|---|---|
status | Enrollment status | One of the enrollment status values listed in the API reference |
statusReason | String or null | Up to 500 characters |
dueDate | YYYY-MM-DD or null | Must be a real calendar day |
revalidationDate | YYYY-MM-DD or null | Setting it creates or moves the revalidation task; null completes that task |
effectiveDate | YYYY-MM-DD or null | Must be a real calendar day |
tinStatus | String or null | One of Linked, Not Linked or Unknown |
caseNumber | String or null | Up to 100 characters |
note | String | 1 to 5,000 characters. Added to the enrollment's notes |
expectedStatus | Enrollment status | Precondition. See below |
expectedUpdatedAt | ISO 8601 date-time | Precondition. See below |
Moving to SUBMITTED or PAR fills in an empty submitted date or effective date the same way the enrollment page does.
curl -sS -X PATCH "https://app.enrollpilot.com/api/v1/enrollments/clv2h9c1k0007abcd1234efgh" \
-H "Authorization: Bearer epk_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" \
-H "Content-Type: application/json" \
-d '{
"status": "PENDED_AI",
"statusReason": "Payer asked for a copy of the DEA certificate",
"note": "Called provider services, spoke with the enrollment desk.",
"expectedStatus": "SUBMITTED",
"expectedUpdatedAt": "2026-10-29T15:04:11.482Z"
}'List follow-ups
status is open (default), completed or all. limit is 1 to 200, default 50, and nextCursor pages through the rest. Each item has its id, type, title, format, contact, reference id, due date, completion state and created date. Follow-up notes are never returned.
curl -sS "https://app.enrollpilot.com/api/v1/enrollments/clv2h9c1k0007abcd1234efgh/follow-ups?status=open&limit=50" \
-H "Authorization: Bearer epk_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"Create a follow-up
| Field | Type | Rules |
|---|---|---|
type | FOLLOW_UP or TASK | Required |
dueDate | YYYY-MM-DD | Required. Read as a date in your organization's time zone |
format | PHONE, EMAIL, FAX, MAIL or WEBSITE | Required for a follow-up |
title | String | Up to 255 characters. Required for a task. A follow-up defaults to "Follow up via" and its format |
contact | String | Up to 500 characters. Follow-ups only |
referenceId | String | Up to 100 characters |
notes | String | Up to 2,000 characters. Saved on the follow-up but never returned by the API |
The follow-up is assigned to the enrollment's active assignees, who are notified. The response is 201 with the new follow-up.
curl -sS -X POST "https://app.enrollpilot.com/api/v1/enrollments/clv2h9c1k0007abcd1234efgh/follow-ups" \
-H "Authorization: Bearer epk_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" \
-H "Content-Type: application/json" \
-d '{
"type": "FOLLOW_UP",
"format": "PHONE",
"dueDate": "2026-11-04",
"contact": "Provider services line",
"referenceId": "REF-20441"
}'Complete a follow-up
| Field | Type | Rules |
|---|---|---|
note | String | Optional, up to 2,000 characters. Saved as the item's final note |
next | Object | Optional. Schedules the next follow-up in the same call. Follow-ups only; a task with next returns 400 |
next.dueDate | YYYY-MM-DD | Required inside next |
next.notes | String | Up to 2,000 characters |
next.format, next.contact, next.referenceId | As for creating a follow-up | Optional. Copied from the completed follow-up when left out. Null or empty values return 400 |
The response contains the completed item and the next follow-up, or null when none was scheduled. Only follow-ups and tasks on an enrollment can be completed through the API; any other id returns 404.
curl -sS -X POST "https://app.enrollpilot.com/api/v1/follow-ups/clv2h9c1k0009abcd1234wxyz/complete" \
-H "Authorization: Bearer epk_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" \
-H "Content-Type: application/json" \
-d '{
"note": "Rep confirmed the application is in review.",
"next": { "dueDate": "2026-11-14", "notes": "Call back for the decision." }
}'Connecting a custom GPT
A ChatGPT custom GPT can call the API through an Action. You need a ChatGPT plan that lets you build GPTs and a key created as described above.
- In ChatGPT, create a GPT and open Configure, then Actions, then Create new action.
- Choose Import from URL and enter
https://app.enrollpilot.com/openapi.json. - Under Authentication choose API Key, set Auth Type to Bearer, and paste the key.
- In the GPT's instructions, tell it to read an enrollment before changing it and to always send
expectedStatuswhen it changes a status. - Save the GPT. Keep it private unless everyone who can use it should be able to change your data.
Instructions that come from the data
A GPT follows text it reads, and that includes text inside the records and emails it works with. If a GPT with a write key reads content from outside your organization, such as a payer email, that content can steer it into making changes. Give a write key only to a GPT whose inputs you trust, watch the "via API" entries in the audit log, and revoke the key if anything looks wrong. Revocation takes effect on the next request.
Data sent to AI services