### Receptionist List Response Sample Source: https://api.edm.mydr.pl/api-docs/index Example JSON response for the get /receptionists/ endpoint, detailing receptionist information. ```JSON { "current_page": 0, "last_page": 0, "count": 0, "next": "http://example.com", "previous": "http://example.com", "results": [ { "id": 0, "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "is_active": true } ] } ``` -------------------------------- ### Payment Response Sample Source: https://api.edm.mydr.pl/api-docs/index Example JSON response for the get /payments/ endpoint, showing pagination details and a list of payments. ```JSON { "current_page": 0, "last_page": 0, "count": 0, "next": "http://example.com", "previous": "http://example.com", "results": [ { "id": 0, "amount": "string", "method": "Gotówka", "visit_id": 0, "date": "string" } ] } ``` -------------------------------- ### Get Patient Visits API Request Example Source: https://api.edm.mydr.pl/api-docs/index This snippet demonstrates how to make a GET request to the /patients/{patient_pk}/visits/ endpoint to retrieve a list of patient visits. It includes common query parameters for filtering and pagination, such as visit status, date range, and page size. The response schema details the structure of the returned visit data. ```http GET https://api.edm.mydr.pl/secure/ext_api/patients/{patient_pk}/visits/ # Query Parameters: # visit_kind: string Enum: "NFZ" "Prywatna" (Filter by visit type) # state: string Enum: "Rezerwacja" "Zaplanowana" "Zakończona" "Anulowana" "Archiwalna" "W trakcie" "Pacjent czeka" "Do rozliczenia" "Do przełożenia" "Oczekuje na płatność" "Zaplanowana i opłacona" (Filter by visit state) # created_by_patient: boolean (Filter for visits created by patient) # evisit: boolean (Filter for e-visits) # date_from: string (Filter by start date) # date_to: string (Filter by end date) # time_from: string (Filter by start time) # time_to: string (Filter by end time) # prescription_visit: boolean (Filter for prescription visits) # ordering: string (Field to sort results by) # page: integer (Page number for pagination) # page_size: integer (Number of results per page) ``` -------------------------------- ### List Payments GET Response 200 Example Source: https://api.edm.mydr.pl/api-docs/index This JSON response details a successful retrieval of a list of payments (HTTP 200 OK). It includes pagination information (current page, last page, count, next/previous links) and an array of payment results, each with ID, amount, method, visit ID, and date. ```json { "current_page": 0, "last_page": 0, "count": 0, "next": "http://example.com", "previous": "http://example.com", "results": [ { "id": 0, "amount": "string", "method": "Gotówka", "visit_id": 0, "date": "string" } ] } ``` -------------------------------- ### Get Visits Endpoint Response Sample Source: https://api.edm.mydr.pl/api-docs/index This snippet shows a sample JSON response for the GET /visits/ endpoint. It includes pagination details and a list of visit objects, each with various attributes like IDs, dates, times, state, and descriptions. ```json { "current_page": 0, "last_page": 0, "count": 0, "next": "http://example.com", "previous": "http://example.com", "results": [ { "id": 0, "patient": 0, "doctor": 0, "office": 0, "date": "string", "timeFrom": "string", "timeTo": "string", "state": "Rezerwacja", "visit_type": [ 0 ], "interview": "string", "recommendation": "string", "examination": "string", "visit_kind": "NFZ", "note": "string", "recognition_description": "string", "confirmed": true, "latest_modification": "string", "prescription_visit": true, "evisit": true, "doctor_name": "string", "doctor_surname": "string" } ] } ``` -------------------------------- ### Create Receptionist Response Sample Source: https://api.edm.mydr.pl/api-docs/index Example JSON response for the POST /receptionists/ endpoint upon successful creation. ```JSON { "id": 0, "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "is_active": true } ``` -------------------------------- ### Create Office Request Sample (JSON) Source: https://api.edm.mydr.pl/api-docs/index This snippet shows the JSON payload for creating a new office. It requires the 'name' of the office, which must be between 1 and 100 characters. ```json { "name": "string" } ``` -------------------------------- ### Response Samples Source: https://api.edm.mydr.pl/api-docs/index Provides examples of successful responses from the API, including the structure and data types of returned fields. ```APIDOC ## Response Samples ### Description This section details the structure of successful API responses, specifically for a 201 status code. ### Method N/A (This describes a response format, not a specific request method) ### Endpoint N/A (This describes a response format, not a specific endpoint) ### Parameters N/A ### Request Example N/A ### Response #### Success Response (201) - **first_name** (string) - The first name of the entity. - **last_name** (string) - The last name of the entity. - **s** (string) - A string field, purpose not specified. - **recipe_symbol** (string) - A symbol or identifier related to a recipe. - **expiration_date** (string) - The expiration date. - **insurance_status** (string) - The current insurance status. - **additional_info** (array of strings) - Additional relevant information. - **note** (string) - Any accompanying notes. #### Response Example ```json { "first_name": "string", "last_name": "string", "s": "string", "recipe_symbol": "string", "expiration_date": "string", "insurance_status": "string", "additional_info": [ "string" ], "note": "string" } ``` ``` -------------------------------- ### Response Sample for Get Patient Permanent Drugs Source: https://api.edm.mydr.pl/api-docs/index Example JSON response structure when retrieving a list of permanent drugs for a patient. ```JSON [ { "id": 0, "patient": 0, "drug": 0, "payment": "100%", "recommendation": "string", "dosation": "string", "comment": "string" } ] ``` -------------------------------- ### POST /nurses/ Source: https://api.edm.mydr.pl/api-docs/index Creates a new nurse for the facility the user is currently logged into. ```APIDOC ## POST /nurses/ ### Description Creates a new nurse for the current facility. ### Method POST ### Endpoint `https://api.edm.mydr.pl/secure/ext_api/nurses/` ### Parameters #### Request Body - **email** (string) - Required - The email address of the nurse (<= 254 characters). - **first_name** (string) - Required - The first name of the nurse (<= 30 characters). - **last_name** (string) - Required - The last name of the nurse (<= 30 characters). - **pesel** (string) - Optional - The PESEL number of the nurse (<= 11 characters). - **telephone** (string) - Optional - The telephone number of the nurse (<= 25 characters). - **username** (string) - Optional - The username of the nurse (<= 150 characters, format: ^[\w.@+-]+$). If empty, it will be auto-generated. - **profession_code** (string) - The professional code of the nurse (Enum values: "1" to "50", "-1"). - **pwz** (string) - Optional - The PWZ number of the nurse (<= 20 characters). ### Response #### Success Response (201) (No specific response schema provided in the input for 201, typically returns the created nurse object or its ID.) ``` -------------------------------- ### Facility Request Payload Example Source: https://api.edm.mydr.pl/api-docs/index This JSON object represents a sample payload for creating or updating facility information. It includes various fields for facility details, contact information, and certificate data. Ensure all required fields are populated according to the specified constraints. ```json { "name": "string", "regon": "string", "nip": "string", "telephone": "string", "postal_code": "string", "street": "string", "house_number": "string", "flat_number": "string", "city": "string", "province": "Dolnośląskie", "www_address": "string", "tls_certificate": { "file_base64": "string", "password": "string" }, "wss_certificate": { "file_base64": "string", "password": "string" }, "oid_root": "string", "email": "user@example.com", "account_number": "string", "work_from": "string", "work_to": "string" } ``` -------------------------------- ### Response Sample for Get Specific Patient Permanent Drug Source: https://api.edm.mydr.pl/api-docs/index Example JSON response structure when retrieving details of a specific permanent drug. ```JSON { "id": 0, "patient": 0, "drug": 0, "payment": "100%", "recommendation": "string", "dosation": "string", "comment": "string" } ``` -------------------------------- ### Get Laboratory Results File API Request Example Source: https://api.edm.mydr.pl/api-docs/index This snippet shows how to make a GET request to the /laboratory-results-files/{id}/ endpoint to download a patient's laboratory results file. The file content is returned in Base64 format. The 'id' path parameter is required to specify which file to retrieve. The response includes file metadata such as size and type (currently only 'pdf' is supported). ```http GET https://api.edm.mydr.pl/secure/ext_api/laboratory-results-files/{id}/ # Path Parameters: # id: integer (Required) - The ID of the laboratory results file. ``` -------------------------------- ### Response Sample for Add Nurse Schedule (201) Source: https://api.edm.mydr.pl/api-docs/index Sample JSON response for successfully adding a nurse schedule. Includes the created schedule's details and associated private services. ```json { "id": 0, "weekday": 0, "start": "string", "end": "string", "valid_from": "string", "valid_to": "string", "office": 0, "visit_kind": "NFZ", "visit_performance": "0", "visit_time": 15, "specialties": [ 0 ], "private_services": [ { "id": 0, "name": "string", "price": "string", "active": true, "vat": 23 } ] } ``` -------------------------------- ### Free Slots Response Example (JSON) Source: https://api.edm.mydr.pl/api-docs/index Example JSON response structure for the GET /visits/free_slots/ endpoint. It details the 'next' cursor for pagination and the 'results' array, where each object represents a free slot with information like date, start/end times, office, department, private services, doctor ID, e-visit status, stationary status, and visit kind. It also includes 'doctors' and 'departments' arrays with their respective details. ```JSON { "next": "string", "results": [ { "date": "string", "start": "string", "end": "string", "office": 0, "department": 0, "private_services": [ 0 ], "private_services_custom_indexes": [ "string" ], "doctor": 0, "evisit": true, "stationary": true, "visit_kind": "NFZ" } ], "doctors": [ { "id": 0, "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "is_active": true } ], "departments": [ { "id": 0, "name": "string", "regon": "string", "department_code": "string", "departmental_code_7": "stri", "departmental_code_8": "stri", "code_5": "str", "nip": "string", "telephone": "string", "street": "string", "house_number": "string", "flat_number": "string", "postal_code": "string", "city": "string", "province": "Dolnośląskie", "country": "string", "work_from": "string", "work_to": "string", "mus_code": "str", "kids_allowed": false } ] } ``` -------------------------------- ### POST /secure/ext_api/nurses/ Source: https://api.edm.mydr.pl/api-docs/index Creates a new nurse entry in the system. Requires a JSON payload with nurse details. ```APIDOC ## POST /secure/ext_api/nurses/ ### Description Creates a new nurse entry in the system. Requires a JSON payload with nurse details. ### Method POST ### Endpoint https://api.edm.mydr.pl/secure/ext_api/nurses/ ### Parameters #### Request Body - **email** (string) - Required - Email address (<= 254 characters) - **first_name** (string) - Required - First name (<= 30 characters) - **last_name** (string) - Required - Last name (<= 30 characters) - **pesel** (string) - Optional - Pesel number (<= 11 characters) - **telephone** (string) - Optional - Telephone number (<= 25 characters) - **username** (string) - Optional - Username (<= 150 characters, regex: ^[\w.@+-]+$). If left empty, a username will be generated automatically. - **profession_code** (string) - Required - Profession code. Enum: "1", "2", "3", "4", "5", "6", "7", "8", "9", "33", "34", "11", "12", "13", "14", "15", "32", "16", "17", "37", "18", "19", "20", "21", "38", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", "50", "35", "36", "39", "-1" - **pwz** (string) - Optional - PWZ number (<= 20 characters) ### Request Example ```json { "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "profession_code": "1", "pwz": "string" } ``` ### Response #### Success Response (201) - **id** (integer) - Unique identifier for the nurse. - **email** (string) - Email address. - **first_name** (string) - First name. - **last_name** (string) - Last name. - **pesel** (string) - Pesel number. - **telephone** (string) - Telephone number. - **username** (string) - Username. - **is_active** (boolean) - Indicates if the user is active. - **profession_code** (string) - Profession code. - **pwz** (string) - PWZ number. #### Response Example ```json { "id": 0, "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "is_active": true, "profession_code": "1", "pwz": "string" } ``` ``` -------------------------------- ### GET /secure/ext_api/doctors/ Source: https://context7.com/context7/api_edm_mydr_pl_api-docs/llms.txt Get list of doctors in the facility with filtering by active status, specialty, and custom sorting. ```APIDOC ## GET /secure/ext_api/doctors/ ### Description Get list of doctors in the facility with filtering by active status, specialty, and custom sorting. ### Method GET ### Endpoint /secure/ext_api/doctors/ ### Parameters #### Query Parameters - **is_active** (boolean) - Optional - Filter by active status (true/false). - **specialty** (integer) - Optional - Filter by specialty ID. - **ordering** (string) - Optional - Field to sort by (e.g., "last_name"). ### Request Example ```bash curl -X GET "https://edm.mydr.pl/secure/ext_api/doctors/" -H "Authorization: Bearer 8Ay8DFJGN6erdTMgvDqCmhYspjDNb7" -G \ --data-urlencode "is_active=true" \ --data-urlencode "specialty=1" \ --data-urlencode "ordering=last_name" ``` ### Response #### Success Response (200 OK) - **current_page** (integer) - The current page number of results. - **last_page** (integer) - The total number of pages. - **count** (integer) - The total number of doctors found. - **results** (array) - A list of doctor objects. - **id** (integer) - Unique identifier for the doctor. - **email** (string) - Doctor's email address. - **first_name** (string) - Doctor's first name. - **last_name** (string) - Doctor's last name. - **pesel** (string) - Doctor's PESEL number. - **telephone** (string) - Doctor's phone number. - **username** (string) - Doctor's username. - **is_active** (boolean) - Indicates if the doctor is active. - **is_facility_owner** (boolean) - Indicates if the doctor is a facility owner. - **profession_code** (string) - Doctor's profession code. - **pwz** (string) - Doctor's PWZ number. - **is_therapist** (boolean) - Indicates if the doctor is a therapist. - **visit_time** (integer) - Default visit time in minutes. - **academic_degree** (string) - Doctor's academic degree. - **specialty** (array of integers) - List of specialty IDs the doctor has. #### Response Example ```json { "current_page": 1, "last_page": 5, "count": 50, "results": [ { "id": 10, "email": "doctor@example.com", "first_name": "Anna", "last_name": "Nowak", "pesel": "85010112345", "telephone": "+48987654321", "username": "dr_nowak", "is_active": true, "is_facility_owner": false, "profession_code": "1", "pwz": "1234567", "is_therapist": false, "visit_time": 30, "academic_degree": "lek. med.", "specialty": [1, 5] } ] } ``` ``` -------------------------------- ### Get Free Visit Slots Response Source: https://api.edm.mydr.pl/api-docs/index This snippet illustrates the JSON response structure for the GET /visits/slots/ endpoint, which provides paginated results of available appointment slots. ```json { "current_page": 0, "last_page": 0, "count": 0, "previous": "http://example.com", "next": "http://example.com", "results": [ { "date": "string", "start": "string", "end": "string", "office": 0, "department": 0, "private_services": [ 0 ], "private_services_custom_indexes": [ "string" ], "doctor": 0, "evisit": true, "stationary": true, "visit_kind": "NFZ" } ] } ``` -------------------------------- ### POST /secure/ext_api/prescriptions/new_draft_straight/ Source: https://context7.com/context7/api_edm_mydr_pl_api-docs/llms.txt Creates a prescription with automatic patient and visit creation, suitable for fast prescription workflows. ```APIDOC ## Create Draft E-Prescription with New Patient - Fast Prescription Workflow ### Description Creates a prescription with automatic patient and visit creation in a single request. Useful for prescription consultations. ### Method POST ### Endpoint `/secure/ext_api/prescriptions/new_draft_straight/` ### Parameters #### Query Parameters None specified. #### Request Body - **recipe_drugs** (array) - Required - A list of drugs for the prescription. - **dosation** (string) - Required - Dosage information. - **recommendation** (string) - Required - Usage recommendation. - **payment** (string) - Required - Payment details. - **remote_drug_id** (integer) - Required - The ID of the drug in the remote database. - **rights** (string) - Optional - Prescription rights identifier. - **nfz** (string) - Optional - NFZ identifier. - **expiration_365** (boolean) - Optional - Whether the prescription is valid for 365 days. - **patient** (object) - Required - Patient information. - **name** (string) - Required - Patient's first name. - **surname** (string) - Required - Patient's last name. - **pesel** (string) - Required - Patient's PESEL number. - **telephone** (string) - Required - Patient's phone number. - **sex** (string) - Required - Patient's sex. - **date_of_birth** (string) - Required - Patient's date of birth (YYYY-MM-DD). - **residence_address** (object) - Required - Patient's residence address. - **country** (string) - Required - Country code. - **street** (string) - Required - Street name. - **street_number** (string) - Required - Street number. - **postal_code** (string) - Required - Postal code. - **city** (string) - Required - City name. ### Request Example ```json { "recipe_drugs": [ { "dosation": "1 op.", "recommendation": "2x dziennie", "payment": "100%", "remote_drug_id": 12345 } ], "rights": "X", "nfz": "07", "expiration_365": true, "patient": { "name": "Jan", "surname": "Kowalski", "pesel": "90010112345", "telephone": "+48123456789", "sex": "Mężczyzna", "date_of_birth": "1990-01-01", "residence_address": { "country": "PL", "street": "Przykładowa", "street_number": "10", "postal_code": "00-001", "city": "Warszawa" } } } ``` ### Response #### Success Response (201 Created) - **id** (integer) - The ID of the created prescription. - **state** (integer) - The state of the created prescription (typically draft, e.g., 2). - **visit** (integer) - The ID of the automatically created visit. - **patient_id** (integer) - The ID of the automatically created patient. - Other fields may be present as in the standard prescription creation response. #### Response Example ```json { "id": 790, "state": 2, "visit": 502, "patient_id": 125, ... } ``` ``` -------------------------------- ### Response Sample (JSON) Source: https://api.edm.mydr.pl/api-docs/index This snippet shows a sample JSON payload for a successful (200) response. It mirrors the request structure, containing fields for quantity, base price, and discount. ```json { "quantity": -32768, "base_price": "string", "discount": "string" } ``` -------------------------------- ### GET /medicines/search/ Source: https://api.edm.mydr.pl/api-docs/index Search for medicines. ```APIDOC ## GET /medicines/search/ ### Description Search for medicines. ### Method GET ### Endpoint `/secure/ext_api/medicines/search/` ### Parameters #### Query Parameters - **query** (string) - Required - The search query for medicines. ``` -------------------------------- ### Recepcjoniści API Source: https://api.edm.mydr.pl/api-docs/index Endpoints for managing receptionists, including listing, creating, searching, retrieving, updating, and token acquisition. ```APIDOC ## GET /recepcjoniści ### Description Retrieves a list of all receptionists. ### Method GET ### Endpoint `/recepcjoniści` ### Parameters None ### Request Example None ### Response #### Success Response (200) * **receptionists** (array) - A list of receptionist objects. * **id** (string) - Receptionist ID. * **name** (string) - Receptionist name. #### Response Example ```json { "receptionists": [ { "id": "rec-101", "name": "Alice Smith" } ] } ``` ## POST /recepcjoniści ### Description Creates a new receptionist. ### Method POST ### Endpoint `/recepcjoniści` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body * **name** (string) - Required - The name of the receptionist. * **email** (string) - Required - The email of the receptionist. ### Request Example ```json { "name": "Bob Johnson", "email": "bob.j@example.com" } ``` ### Response #### Success Response (200) * **id** (string) - The ID of the newly created receptionist. * **message** (string) - A success message. #### Response Example ```json { "id": "rec-102", "message": "Receptionist created successfully." } ``` ## GET /recepcjoniści/wyszukaj ### Description Searches for receptionists based on given criteria. ### Method GET ### Endpoint `/recepcjoniści/wyszukaj` ### Parameters #### Path Parameters None #### Query Parameters * **name** (string) - Optional - Name to search for. * **email** (string) - Optional - Email to search for. #### Request Body None ### Request Example `GET /recepcjoniści/wyszukaj?name=Alice` ### Response #### Success Response (200) * **receptionists** (array) - A list of receptionist objects matching the search criteria. #### Response Example ```json { "receptionists": [ { "id": "rec-101", "name": "Alice Smith", "email": "alice.s@example.com" } ] } ``` ## GET /recepcjoniści/{id} ### Description Retrieves details of a specific receptionist. ### Method GET ### Endpoint `/recepcjoniści/{id}` ### Parameters #### Path Parameters * **id** (string) - Required - The ID of the receptionist to retrieve. #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) * **receptionist** (object) - Details of the receptionist. #### Response Example ```json { "receptionist": { "id": "rec-101", "name": "Alice Smith", "email": "alice.s@example.com" } } ``` ## PUT /recepcjoniści/{id} ### Description Updates all details of a specific receptionist. ### Method PUT ### Endpoint `/recepcjoniści/{id}` ### Parameters #### Path Parameters * **id** (string) - Required - The ID of the receptionist to update. #### Query Parameters None #### Request Body * **name** (string) - Required - The updated name of the receptionist. * **email** (string) - Required - The updated email of the receptionist. ### Request Example ```json { "name": "Alice Wonderland", "email": "alice.w@example.com" } ``` ### Response #### Success Response (200) * **message** (string) - A success message indicating the receptionist was updated. #### Response Example ```json { "message": "Receptionist updated successfully." } ``` ## PATCH /recepcjoniści/{id} ### Description Partially updates details of a specific receptionist. ### Method PATCH ### Endpoint `/recepcjoniści/{id}` ### Parameters #### Path Parameters * **id** (string) - Required - The ID of the receptionist to update. #### Query Parameters None #### Request Body * **name** (string) - Optional - The updated name of the receptionist. * **email** (string) - Optional - The updated email of the receptionist. ### Request Example ```json { "email": "alice.wonderland.updated@example.com" } ``` ### Response #### Success Response (200) * **message** (string) - A success message indicating the receptionist was partially updated. #### Response Example ```json { "message": "Receptionist partially updated successfully." } ``` ## POST /recepcjoniści/{id}/access_token ### Description Acquires an access token for a receptionist. ### Method POST ### Endpoint `/recepcjoniści/{id}/access_token` ### Parameters #### Path Parameters * **id** (string) - Required - The ID of the receptionist. #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) * **access_token** (string) - The access token for the receptionist. #### Response Example ```json { "access_token": "eyexampletoken" } ``` ``` -------------------------------- ### POST /secure/ext_api/prescriptions/ Source: https://context7.com/context7/api_edm_mydr_pl_api-docs/llms.txt Creates an electronic prescription for a visit, integrating with the Polish P1 system. ```APIDOC ## Create E-Prescription - Issue Electronic Prescription ### Description Creates an electronic prescription for a visit with medications from the drug database. Integrates with Polish P1 system. ### Method POST ### Endpoint `/secure/ext_api/prescriptions/` ### Parameters #### Query Parameters None specified. #### Request Body - **visit** (integer) - Required - The ID of the visit for which the prescription is created. - **straight** (boolean) - Optional - Indicates if this is a straight prescription. - **rights** (string) - Optional - Prescription rights identifier (e.g., 'X'). - **nfz** (string) - Optional - NFZ identifier. - **expiration_365** (boolean) - Optional - Whether the prescription is valid for 365 days. - **delivery_date** (string) - Optional - The date and time for delivery in ISO 8601 format (e.g., "2025-10-15T10:00:00"). - **has_senior_right** (boolean) - Optional - Indicates if the patient has senior rights. - **has_pregnant_right** (boolean) - Optional - Indicates if the patient has pregnant rights. - **recipe_drugs** (array) - Required - A list of drugs included in the prescription. - **dosation** (string) - Required - Dosage information (e.g., "1 op."). - **recommendation** (string) - Required - Usage recommendation (e.g., "2 razy dziennie po posiłku"). - **payment** (string) - Required - Payment details (e.g., "100%"). - **remote_drug_id** (integer) - Required - The ID of the drug in the remote database. - **is_part_of_box** (boolean) - Optional - Whether the drug is part of a package. - **composition** (string) - Optional - The composition of the drug. - **nurse_recipe_type** (any) - Optional - Type of nurse recipe. ### Request Example ```json { "visit": 500, "straight": false, "rights": "X", "nfz": "07", "expiration_365": true, "delivery_date": "2025-10-15T10:00:00", "has_senior_right": false, "has_pregnant_right": false, "recipe_drugs": [ { "dosation": "1 op.", "recommendation": "2 razy dziennie po posiłku", "payment": "100%", "remote_drug_id": 12345, "is_part_of_box": false, "composition": "Paracetamol 500mg" }, { "dosation": "2 op.", "recommendation": "1 tabletka rano", "payment": "50%", "remote_drug_id": 67890, "is_part_of_box": false } ], "nurse_recipe_type": null } ``` ### Response #### Success Response (200 OK) - **id** (integer) - The unique identifier of the created prescription. - **state** (integer) - The current state of the prescription. - **visit** (integer) - The ID of the associated visit. - **erecipe_package** (any) - E-recipe package information. - **rights** (string) - Prescription rights identifier. - **nfz** (string) - NFZ identifier. - **expiration_365** (boolean) - Indicates if the prescription is valid for 365 days. - **delivery_date** (string) - The delivery date of the prescription. - **recipe_drugs** (array) - A list of drugs included in the prescription. - **id** (integer) - The unique identifier of the drug in the prescription. - **dosation** (string) - Dosage information. - **recommendation** (string) - Usage recommendation. - **payment** (string) - Payment details. - **name** (string) - The name of the drug. - **ean13** (string) - The EAN13 code of the drug. - **composition** (string) - The composition of the drug. #### Response Example ```json { "id": 789, "state": 2, "visit": 500, "erecipe_package": null, "rights": "X", "nfz": "07", "expiration_365": true, "delivery_date": "2025-10-15T10:00:00", "recipe_drugs": [ { "id": 1001, "dosation": "1 op.", "recommendation": "2 razy dziennie po posiłku", "payment": "100%", "name": "Paracetamol", "ean13": "5901234567890", "composition": "Paracetamol 500mg" } ] } ``` ``` -------------------------------- ### Get Free Visit Slots v2 Response Source: https://api.edm.mydr.pl/api-docs/index This snippet shows the JSON response structure for the GET /visits/free_slots_v2/ endpoint, detailing available appointment slots, doctor information, and department details. ```json { "next": "string", "results": [ { "date": "string", "start": "string", "end": "string", "office": 0, "department": 0, "private_services": [ 0 ], "private_services_custom_indexes": [ "string" ], "doctor": 0, "evisit": true, "stationary": true, "visit_kind": "NFZ" } ], "doctors": [ { "id": 0, "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string", "is_active": true } ], "departments": [ { "id": 0, "name": "string", "regon": "string", "department_code": "string", "departmental_code_7": "stri", "departmental_code_8": "stri", "code_5": "str", "nip": "string", "telephone": "string", "street": "string", "house_number": "string", "flat_number": "string", "postal_code": "string", "city": "string", "province": "Dolnośląskie", "country": "string", "work_from": "string", "work_to": "string", "mus_code": "str", "kids_allowed": false } ] } ``` -------------------------------- ### Create Receptionist Request Payload Sample Source: https://api.edm.mydr.pl/api-docs/index Sample JSON payload for creating a new receptionist via the POST /receptionists/ endpoint. ```JSON { "email": "user@example.com", "first_name": "string", "last_name": "string", "pesel": "string", "telephone": "string", "username": "string" } ``` -------------------------------- ### Get Free Time Slots - Find Available Appointments (Bash) Source: https://context7.com/context7/api_edm_mydr_pl_api-docs/llms.txt Searches for available appointment slots based on date range, doctor, specialty, or service type. Returns a list of available slots with office and timing details. Uses a GET request with URL-encoded query parameters. ```bash curl -X GET "https://edm.mydr.pl/secure/ext_api/visits/free_slots/" \ -H "Authorization: Bearer 8Ay8DFJGN6erdTMgvDqCmhYspjDNb7" \ -G \ --data-urlencode "date_from=2025-10-15" \ --data-urlencode "date_to=2025-10-20" \ --data-urlencode "doctor=10" \ --data-urlencode "visit_kind=Prywatna" \ --data-urlencode "visit_duration=30" \ --data-urlencode "e-visit=true" ``` -------------------------------- ### POST /api/recipe Source: https://api.edm.mydr.pl/api-docs/index This endpoint allows for the creation of a new electronic prescription. It requires detailed information about the patient's rights, the prescription itself, and the drugs to be included. ```APIDOC ## POST /api/recipe ### Description Creates a new electronic prescription. ### Method POST ### Endpoint /api/recipe ### Parameters #### Request Body - **rights_required** (string) - Required - Specifies the patient's rights for prescription fulfillment. Enum: "WE", "IB", "AZ", "IN", "WP", "X", "ZK", "PO", "IW". - **nfz** (string) - Optional - Specifies the National Health Fund (NFZ) branch. Default: "X". Enum: "X", "01", "02", "03", "04", "05", "06", "07", "08", "09", "10", "11", "12", "13", "14", "15", "16". - **nurse_recipe_type** (string) - Optional - Type of prescription issued by a nurse. Enum: "5", "6". - **expiration_365** (boolean) - Optional - Indicates if the prescription expires within 365 days. Default: false. - **delivery_date** (string) - Optional - The date from which the prescription is valid (YYYY-MM-DDThh:mm[:ss]). - **has_senior_right** (boolean) - Optional - Indicates if the patient has senior rights. Default: false. - **has_pregnant_right** (boolean) - Optional - Indicates if the patient has pregnant rights. Default: false. - **recipe_drugs** (array of objects) - Required - An array of objects, where each object represents a drug to be included in the prescription. ### Request Example ```json { "rights_required": "WE", "nfz": "01", "expiration_365": true, "delivery_date": "2024-12-31T23:59:59", "has_senior_right": false, "has_pregnant_right": false, "recipe_drugs": [ { "drug_code": "12345", "drug_name": "Example Drug", "dose": "10mg", "form": "Tablet", "quantity": 1, "unit": "PCS", "manufacturer": "Pharma Inc." } ] } ``` ### Response #### Success Response (200) - **prescription_id** (string) - The unique identifier for the created prescription. - **status** (string) - The status of the prescription creation (e.g., "success"). #### Response Example ```json { "prescription_id": "PRES123456789", "status": "success" } ``` ``` -------------------------------- ### GET /visits/{visit_pk}/services/ Source: https://api.edm.mydr.pl/api-docs/index Lists all private services associated with a visit. ```APIDOC ## List Visit Private Services ### Description Retrieves a list of private services associated with a specific visit. ### Method GET ### Endpoint `/visits/{visit_pk}/services/` ### Parameters #### Path Parameters - **visit_pk** (string) - Required - The primary key of the visit. ### Response #### Success Response (200) - **id** (integer) - The unique identifier of the service. - **name** (string) - The name of the service. - **insurer_service_code** (string) - The insurer's service code. - **quantity** (integer) - The quantity of the service (Range: -32768 to 32767). - **base_price** (string) - The base price of the service. - **discount** (string) - The discount applied to the service. - **value** (string) - The final value of the service. ### Response Example ```json [ { "id": 0, "name": "string", "insurer_service_code": "string", "quantity": -32768, "base_price": "string", "discount": "string", "value": "string" } ] ``` ``` -------------------------------- ### Request Sample (JSON) Source: https://api.edm.mydr.pl/api-docs/index This snippet shows a sample JSON payload for a request, including fields for quantity, base price, and discount. The quantity field is an integer, while base price and discount are strings. ```json { "quantity": -32768, "base_price": "string", "discount": "string" } ``` -------------------------------- ### GET /visits/{visit_pk}/diagnoses/ Source: https://api.edm.mydr.pl/api-docs/index Retrieves a list of all diagnoses for a given visit. ```APIDOC ## GET /visits/{visit_pk}/diagnoses/ ### Description Retrieves a list of all diagnoses for a given visit. ### Method GET ### Endpoint https://api.edm.mydr.pl/secure/ext_api/visits/{visit_pk}/diagnoses/ ### Parameters #### Path Parameters - **visit_pk** (string) - Required - The primary key of the visit. ### Response #### Success Response (200) [Response schema not fully defined in the provided text] #### Response Example [No response example provided in the source text] ```