API recipes
Worked examples: syncing staff, starting and ending employment, compliance, teams, care.
Worked examples for the integrations people build most. Each uses only the calls in the reference.
Keep a rota or payroll system in step with your staff
Scopes: people.read, staff.read (and events.read if you want to react to changes). Without care.read the key can never see people who only receive support.
- First load: page through
GET /employments?status=current(andstatus=upcomingfor people who start soon). Each employment has the person’s id,employee_ref, job title, contract, hours, line manager, start and end dates. Fetch names and emails withGET /people?kind=staff. - Stay in step: either
- poll
GET /events?types=employment.*&after=LAST_CURSORevery minute and apply each event in order (employment.started,employment.changed,employment.ended), saving the lastcursoryou processed; or - create a webhook for the same events and let Care Core call you.
- poll
- Safety net: once a night, reconcile with
GET /people?updated_since=YESTERDAYand a fresh list of current employments. Events can be missed if your receiver was down; this catches them. - Leavers: an
employment.endedevent carries the last day (end_date). Disable the person in your system after that day. Care Core ends their access the same way.
Start someone from a recruitment system
Scopes: staff.write (plus teams.write only if you add team places separately).
POST /employments
Idempotency-Key: candidate-4821
{ "first_name": "Ada", "last_name": "Lovelace", "email": "ada@example.org",
"job_title": "Support Worker", "start_date": "2026-12-01", "hours_per_week": 37.5,
"employee_ref": "E4821", "team_id": "…", "line_manager_id": "…" }
- This is the joiner process: the person, the employment, the team place, and the new starter checklist, all at once. The response includes
tasks_created. - The idempotency key means a retry after a timeout cannot start the same person twice. (An existing email is refused anyway.)
- A returner: pass
person_idinstead of the name fields. The response saysrehire: true. - Then add what you know:
PATCH /people/{id}/profile(address, emergency contact; National Insurance and bank needstaff.sensitive),POST /people/{id}/registrations,PATCH /employments/{id}/details/wtd. - No login is created. Access is arranged by an administrator or by Entra provisioning.
End someone’s employment from HR
GET /employments/{id}/leave-preview?last_day=2026-12-18 (changes nothing)
POST /employments/{id}/end { "last_day": "2026-12-18", "reason": "Resigned" }
The preview says how many team places will end, how many people lose this key worker or line manager, how many logins will stop and how many offboarding tasks will be created. The end call does it all in one transaction and returns the same counts. The API cannot half-end someone.
A compliance dashboard
Scopes: compliance.read, people.read.
GET /compliance/due?days=60returns everything overdue or due in the next 60 days for current staff, with the person’s id, what it is, and the date. Look the people up withGET /people/{id}.- For one person:
GET /people/{id}/registrations,/supervisions,/appraisals,/learning. - Training from a learning system:
POST /people/{id}/learningwithtitle,record_type,completion_date,expiry_date,statusandis_mandatory. Use the learning system’s record id as theIdempotency-Key.
Who is in this team, now or on any date?
GET /teams the structure
GET /teams/{id}/members today
GET /teams/{id}/members?on=2026-03-14 on a past date
Each place has a role, primary, start_date and end_date. GET /people/{id}/teams gives one person’s whole history. To move someone, use the mover endpoint (POST /employments/{id}/changes with team_id), which ends the old primary team the day before and starts the new one, rather than editing places by hand.
A care system that needs key workers and teams
Scopes: care.read, teams.read (and care.write to change).
GET /people?kind=supported: everyone currently receiving support.GET /people/{id}/key-workers: current key workers first. Called on a member of staff it lists the people they are key worker for.POST /key-workersto assign (the rules about current staff and people currently supported apply). When a key worker leaves, Care Core ends their links and creates a task for each person; read those withGET /tasks?kind=reassign.- Listen for
keyworker.startedandkeyworker.endedevents.
Close the loop on tasks
Another system (a service desk, a rota) may do the work a task describes. GET /tasks?status=open&kind=leaver lists what is waiting; PATCH /tasks/{id} with {"status":"done"} marks it complete and raises task.completed.
Audit what an integration did
Everything a key does is attributed to it. Read it back with GET /audit?action=employment (or filter by subject_id); entries show the actor system:api:KEYNAME. Sensitive values are never in the log.
Manage webhooks as part of your own deployment
POST /webhooks { "url": "https://hooks.example.org/care", "event_types": ["employment.*", "team_assignment.*"] }
→ { "data": { "id": "…", "secret": "d4f6…" } } (the secret is shown once)
GET /webhooks/{id}/deliveries?status=failed see what is not getting through
See Events and webhooks for how to verify the signature.
Feed events or poll?
| Compared | Webhooks | Event feed (GET /events) |
|---|---|---|
| Latency | About a minute | As often as you poll |
| Needs a public address | Yes (https) | No: you call us |
| If you are down | Retried for about 15 hours, then given up | Nothing is lost: resume from your last cursor |
| Best for | Reacting quickly | Systems behind a firewall; guaranteed catch-up |
Many integrations use both: webhooks for speed and the feed to catch up.