Staff
GET /v1/staff lists the people who work at one location, with their roles there. Use it to keep a payroll or scheduling system’s employee list in step with Selflane. With the pay scope, each role also carries its pay rate.
Needs the staff:read scope (Staff in Back Office). Pay rates and salary also need staff.pay:read (Staff pay). Both return personal information, so the owner confirms each one separately when creating the key. See Scopes.
A PIN, password, date of birth, photo, manager notes, or the reason someone left is never returned, with or without either scope.
Request
curl "https://developer.selflane.com/v1/staff?location=64b0c1e2f3a4b5c6d7e8f901" \
-H "Authorization: Bearer $SELFLANE_API_KEY"| Parameter | Required | Notes |
|---|---|---|
limit | No | Staff per page, 1 to 200. Default 50. |
cursor | No | The next_cursor from the previous page. Works only with the same location. |
location | When the key covers several locations | One of the key’s locations |
Staff come in id order. Keep requesting with cursor until next_cursor is null.
Response
{
"data": [
{
"id": "65a1c2d3e4f5a6b7c8d9e0f1",
"location": "64b0c1e2f3a4b5c6d7e8f901",
"home_location": "64b0c1e2f3a4b5c6d7e8f901",
"employee_id": "1042",
"first_name": "Sam",
"last_name": "Lee",
"display_name": "Sam L",
"email": "sam@example.com",
"phone": "7205550100",
"active": true,
"terminated_on": null,
"created": "2025-01-02T17:00:00.000Z",
"roles": [
{
"id": "6552a1b2c3d4e5f6a7b8c9d0",
"name": "Cashier",
"department": { "id": "6553a1b2c3d4e5f6a7b8c9d0", "name": "Front of house" },
"pay": { "type": "hourly", "rate": 1550, "currency": "usd" }
}
],
"salary": { "amount": 120000, "currency": "usd", "period": "week", "effective": "2026-06-01", "share": 60 }
}
],
"next_cursor": null
}Who is listed
- Everyone whose home location is this one.
- Staff of a multi-location business who are set up to work at this location.
- Inactive staff, with
activefalse. Selflane doesn’t delete staff, so deactivate your own copy whenactiveturnsfalse.
Fields
All money is integer cents in currency.
| Field | Meaning |
|---|---|
id | The person’s ID. It’s the staff_id on timecards. |
home_location | The location the person was created at. A person at a multi-location business can work at several. |
employee_id | The business’s own employee number, or null |
first_name, last_name | The person’s name. Empty when not given. |
display_name | The name shown on the POS |
email, phone | Contact details, each null when not given |
active | false once a manager deactivates the person |
terminated_on | Last day of work, YYYY-MM-DD, or null |
created | When the person was added, or null if it wasn’t recorded |
roles | The person’s roles at this location only. A role at another location comes back when you read that location. id is the role’s ID, the same as a timecard’s role.id. department is the role’s department (id and name), or null. |
roles[].pay | Only with staff.pay:read. type is hourly or weekly, and rate is cents per hour or per week. Without the scope, the field is missing. |
salary | Only with staff.pay:read. The fixed salary in effect today at this location, or null. amount is the whole salary per period (week, month, or year), effective is the date it started, and share is the whole percent of it allocated to this location. A salary allocated only to other locations is null here. Without the scope, the field is missing. |
Keep your copy current
The list is small. On every sync, read it all and replace each stored person with the same id.
Errors
| Status | code | When |
|---|---|---|
400 | invalid_parameter | limit isn’t a whole number from 1 to 200. param names it. |
400 | invalid_cursor | The cursor isn’t valid, or wasn’t issued for this location |
400 | location_required | The key covers several locations and none was named |
403 | insufficient_scope | The key lacks staff:read. staff.pay:read alone isn’t enough. |
403 | location_not_permitted | The key doesn’t cover the named location |
403 | plan_required | The location isn’t live or is below the POS plan |
503 | replica_unavailable | Staff are briefly unavailable. Retry after Retry-After. |
503 | staff_timeout | The request took too long. Retry after Retry-After, or ask for a smaller page. |
See Errors for the codes every endpoint shares.