REST API
For pushing attendance into payroll, pulling tracked hours into an invoice, or provisioning employees from your HR system.
Authentication
Generate a token in the admin area and send it as a bearer token. Tokens are scoped and revocable, and every call is written to the audit log against the token that made it.
curl https://hr.yourcompany.com/api/v1/employees \
-H "Authorization: Bearer edc_live_xxxxxxxxxxxx" \
-H "Accept: application/json"
Endpoints
| Method | Path | Does |
|---|---|---|
| GET | /api/v1/employees | List employees, filterable by department and status |
| POST | /api/v1/employees | Create an employee and send the invitation |
| PATCH | /api/v1/employees/:id | Update an employee; archive by setting status |
| GET | /api/v1/attendance | Attendance records for a date range |
| POST | /api/v1/attendance | Post a check-in or check-out, for biometric integration |
| GET | /api/v1/attendance/summary | The payroll summary, same shape as the CSV export |
| GET | /api/v1/leaves | Leave requests, filterable by status |
| POST | /api/v1/leaves/:id/approve | Approve or reject a request |
| GET | /api/v1/leave-balances | Current balances per employee and leave type |
| GET | /api/v1/time-entries | Tracked time, filterable by employee, project and date |
| GET | /api/v1/projects | Projects and their members |
| GET | /api/v1/reports/time-by-project | Aggregated hours per project for a date range |
A worked example: month-end payroll
curl -G https://hr.yourcompany.com/api/v1/attendance/summary \
-H "Authorization: Bearer $EDC_TOKEN" \
-d from=2026-08-01 \
-d to=2026-08-31
{
"period": { "from": "2026-08-01", "to": "2026-08-31" },
"data": [
{
"employee_code": "EDC-014",
"name": "A. Sharma",
"present_days": 21,
"absent_days": 1,
"late_marks": 2,
"half_days": 0,
"leave_days": 2,
"worked_hours": 168.5
}
],
"meta": { "page": 1, "per_page": 100, "total": 47 }
}
Pagination
List endpoints return 100 records per page. Pass page and per_page, and read meta.total to size the loop. Sorting is stable, so paging through a large range does not skip or repeat records.
Webhooks
Register an endpoint and receive a signed POST when something happens, rather than polling for it.
| Event | Fires when |
|---|---|
attendance.checked_in | An employee checks in |
attendance.checked_out | An employee checks out |
leave.requested | A leave request is submitted |
leave.approved / leave.rejected | A request is decided |
employee.created / employee.archived | Headcount changes |
timer.session_completed | A tracked session ends and uploads |
Each delivery carries an HMAC signature header computed with your webhook secret. Verify it before acting on the payload. Failed deliveries retry with exponential backoff for 24 hours.
Errors
| Code | Meaning | What to do |
|---|---|---|
| 400 | Validation failed | Read the errors object; it names the fields |
| 401 | Missing or invalid token | Check the header and whether the token was revoked |
| 403 | Token scope insufficient | Regenerate with write scope |
| 404 | Not found, or not visible to this token | Confirm the id and the token scope |
| 422 | Business rule rejected it | For example leave overlapping an existing approved request |
| 429 | Rate limited | Back off; Retry-After tells you how long |
Related
Frequently asked
Which plans include the API?
The Pro cloud plan and every self-hosted installation. It is not available on Starter or Growth.
How is it authenticated?
A bearer token generated in the admin area, scoped to read or read-write, and revocable. Every call is recorded in the audit log against the token.
Is there a rate limit?
600 requests per minute per token on cloud. Self-hosted installations set their own limit, because it is your server.
Something missing from the docs?
Tell us what you were looking for at support@employeedeskcrm.com and we will add it here.
- 7-day trial
- No credit card
- Cancel anytime