Get All
GET
/:tenantId/patientsQuery Parameters
| Name | Type | Required | Description |
|---|---|---|---|
filter[birth_date][from] | datetime | no | Filters results by birth dates starting from this date (format: YYYY-MM-DD). |
filter[birth_date][to] | datetime | no | Filters results by birth dates up to this date (format: YYYY-MM-DD). |
filter[group_id] | integer | no | Filters results by group IDs. Accepts a comma-separated list of IDs (e.g., 1,2). |
search | string | no | Searches by name, mobile |
Response
HTTP 200 OK
json
{
"data": [
{
"id": 1,
"name": "John Doe",
"mobile": "+1234567890",
"email": "johndoe@example.com",
"birth_date": "1980-01-01T00:00:00.000000Z",
"identity_number": "123456789",
"protocol_no": "JD123",
"photo": null,
"groups": [],
"sms_consent": 1
},
{
"id": 2,
"name": "Jane Doe",
"mobile": "+9876543210",
"email": "janedoe@example.com",
"birth_date": "1990-02-02T00:00:00.000000Z",
"identity_number": "987654321",
"protocol_no": "JD456",
"photo": null,
"groups": [],
"sms_consent": 0
},
{
"id": 3,
"name": "Alice Smith",
"mobile": "+1122334455",
"email": "alice.smith@example.com",
"birth_date": "1995-03-03T00:00:00.000000Z",
"identity_number": "555666777",
"protocol_no": "AS789",
"photo": null,
"groups": [],
"sms_consent": 1
},
{
"id": 4,
"name": "Bob Johnson",
"mobile": "+9988776655",
"email": "bob.johnson@example.com",
"birth_date": "1985-04-04T00:00:00.000000Z",
"identity_number": "333444555",
"protocol_no": "BJ101",
"photo": null,
"groups": [],
"sms_consent": 2
},
{
"id": 5,
"name": "Charlie Brown",
"mobile": "+4455667788",
"email": "charlie.brown@example.com",
"birth_date": "2000-05-05T00:00:00.000000Z",
"identity_number": "111222333",
"protocol_no": "CB202",
"photo": null,
"groups": [],
"sms_consent": 1
}
],
"links": {
"first": "https://<Base URL>/api/v1/:tenantId/patients?page=1",
"last": "https://<Base URL>/api/v1/:tenantId/patients?page=1",
"prev": null,
"next": null
},
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"links": [
{
"url": null,
"label": "pagination.previous",
"active": false
},
{
"url": "https://<Base URL>/api/v1/:tenantId/patients?page=1",
"label": "1",
"active": true
},
{
"url": null,
"label": "pagination.next",
"active": false
}
],
"path": "https://<Base URL>/api/v1/:tenantId/patients",
"per_page": 5,
"to": 5,
"total": 5
}
}