The scopes
safety:readreads an end user’s safety records and reveals the contacts a record masks.safety:updateraises a record, changes it, records each step, and closes it.
Neither is ever part of choosing every scope on a key: an Owner or Admin has to tick each one. Give them only to a system that handles a disclosure the way your own family violence policy says, and to no one who doesn’t need them.
What you must do with the data
- Keep it from anyone it could endanger. A safety record exists because someone’s contact details could be used to find them. Don’t copy the revealed contacts, the safe contact or the notes into places other staff, other systems or the other person on the account can see.
- Use only the agreed way to communicate. When the record names a method, time, safe number or safe email, contact the person only that way.
- Post bills only to the safe postal address. Under
safe_post, a bill goes tosafePostalAddress, never to the end user’s own address. The bill PDF printssafePostalAddressin its address block, or no address when there is none, and no internet service’s street address or location ID. - Follow the steps in order. Record that the person confirmed it is safe to talk before recording that support was explained, or whether they want more. The API refuses them out of order with 409, as the portal does.
- Close, never delete. A closed record is kept until its retention date,
retentionExpiresAt. There is no delete call.
Every read and reveal is audited
Every call, including each read, is made with your key, and every change and
every reveal is in your audit log naming the key. A step taken by API names
no person on the record: identifiedBy, supportAdvisedBy and closedBy
are null. The audit log names the key instead.
Masked contacts
While an active record suppresses contact disclosure, every end-user call
withholds the end user’s email, phone and addresses, and contactsMasked is
true. POST /end-users/{endUser}/contacts/reveal, on safety:read, returns
them and is audited as a reveal each time. Ask for them only when you need
them for the call in front of you.
A record’s own safe contacts are the safe number, safe email and safe postal
address. They are stored encrypted and masked on every read of the record:
safeContactNumber, safeContactEmail and safePostalAddress are always
null there, and safeContactsMasked says whether any is recorded.
POST /end-users/{endUser}/safety-records/{recordId}/safe-contacts/reveal,
on safety:read, returns them, and is audited as a reveal naming the record
each time. To change one, send it on PATCH. Leave it out to keep it, or
send null to clear it.
The workflow
-
POST /end-users/{endUser}/safety-recordsraises a record with:- the reason
- the agreed way and time to communicate
- whether to suppress contact details, which is on by default
- the safe number and email
- the safe postal address,
safePostalAddress - how they want their bills,
billDelivery:safe_email,safe_post,portal_onlyornone. Their bills and billing notices follow it. AbillDeliveryNotegoes with it. - notes.
safe_postneeds a safe postal address. Without one the call is refused with422, onsafePostalAddress. -
POST .../safety-records/{recordId}/confirm-saferecords that the person confirmed it is safe to talk. -
POST .../support-advisedrecords that support was explained, andPOST .../further-supportwithwantedrecords whether they want more. -
PATCH .../safety-records/{recordId}changes the record while it is active. -
POST .../closecloses it and sets its retention date.