Retrieves information about non-visit activities (tasks) performed during a specified time range. The API supports optional filtering by task IDs and user ID.
Request
Endpoint
POST https://yourdomain.pharmahrm.com/crm-api/db-function/run
Authentication
Bearer Token required
Request Structure
Headers
| Key | Value |
|---|---|
| Authorization | Bearer <token>
|
| Content-Type | application/json |
Request Body
{
"function": "api_get_actions",
"format": "csv",
"arguments": {
"date_from": "2025-08-04",
"date_till": "2025-08-04",
"ids": "1,2,3,4",
"user_id": 1
}
}| Name | Type | Required | Description |
|---|---|---|---|
| format | string | Yes | The response format - csv |
| arguments | object | Yes | Parameters block. |
| date_from | string | Yes | Start date of the reporting period (visit start date). Format: YYYY-MM-DD
|
| date_till | string | Yes | End date of the reporting period (visit end date). Format: YYYY-MM-DD
|
| ids | string | Optional | Comma-separated list of non-visit activity (task) IDs from Proxima CRM. |
| user_id | integer | Optional | Proxima CRM user ID. Returns non-visit activities for a specific user. |
Successful Response
200 OK
Format
Plain text CSV
Content-Type
text/plain
Example Response
action_id,action_name,action_datefrom,action_datetill,action_tasktype,action_user_id,action_state
1001,Internal Meeting,2025-08-04T10:00:00Z,2025-08-04T11:00:00Z,Meeting,12,Completed
| Field | Description |
|---|---|
| action_id | Task ID in the Proxima CRM database |
| action_name | Task name or title |
| action_datefrom | Scheduled task start date and time (UTC). Format: YYYY-MM-DD HH:MM:SS |
| action_datetill | Scheduled task end date and time (UTC). Format: YYYY-MM-DD HH:MM:SS |
| action_tasktype | Type of task (e.g., Meeting, Training, Admin work) |
| action_user_id | ID of the user assigned to the task in Proxima CRM |
| action_state | Task status (e.g., Planned, Completed, Cancelled) |
Error Responses
40x/50x
{
"message": "string"
}| Code | Meaning |
|---|---|
| 400 | Bad request (e.g., missing required parameters) |
| 401 | Unauthorized (invalid or missing token) |
| 500 | Internal server error |