Retrieves the information about brands and drugs uploaded to the system.
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_preparation_json",
"format": "json",
"arguments": {
"ids": "1,2,3,4"
}
}| Field | Type | Required | Description |
|---|---|---|---|
| function | string | Yes | API method name. Use "api_get_preparation_json". |
| format | string | Yes | Response format - json |
| arguments | object | Yes | Parameters block |
| ids | string | No | Accepts record identifiers from the Proxima CRM database. Comma separator. |
Successful Response
Example Response
[
{
"brend_id": 1,
"direction": [
"Rx"
],
"brend_name": "Дексофен",
"preparation_id": 13,
"preparation_name": "ДЕКСОФЕН розчин для ін’єкцій, 50 мг/2 мл по 2 мл в ампулі; по 5 ампул у пласт конт уп в карт кор"
}
]| Field | Description |
|---|---|
| preparation_id | Drug identifier in Proxima CRM |
| preparation_name | Drug name |
| brend_id | Brand identifier in Proxima CRM |
| brend_name | Brand name |
| direction | The product category to which the drug belongs |
Error Response
40x/50x
{
"message": "string"
}| Code | Meaning |
|---|---|
| 400 | Bad request (e.g., missing required parameters) |
| 401 | Unauthorized access (invalid or missing token) |
| 500 | Internal server error |