API for HMS integration flows that do not use callback URLs. Use these endpoints for GET/polling style integration and CSV maintenance flows.
Complete Integration Guide: HMS Integration without Callback url (GET CALL)
Creates a doctor record and associates it with an organization.
Doctor creation payload
| first_name required | string |
| last_name required | string |
| speciality_id required | integer |
| salutation | string |
| hospital_id required | integer |
| license_no | string |
| phone_number | string |
string | |
| practitioner_id required | string |
{- "first_name": "John",
- "last_name": "Doe",
- "speciality_id": 5,
- "salutation": "Dr.",
- "hospital_id": 101,
- "license_no": "ABC12345",
- "phone_number": "+91-9876543210",
- "email": "johndoe@example.com",
- "practitioner_id": "PRAC-001"
}{- "message": "Doctor created successfully",
- "doctor": {
- "doctor_id": 1,
- "first_name": "John",
- "last_name": "Doe",
- "speciality_id": 5,
- "salutation": "Dr.",
- "organization_id": 101,
- "active_organization_id": 101,
- "license_no": "ABC12345",
- "phone_number": "+91-9876543210",
- "email": "johndoeABC1015@gmail.com",
- "practitioner_id": "PRAC-001",
- "opdassessment": {
- "chief_complaints": true,
- "history_of_presenting_illness": true,
- "patient_history": true,
- "personal_history": true,
- "examination_findings": true,
- "investigations": true,
- "recommendations": true,
- "medications": true,
- "follow_up": true,
- "plan": true
}, - "opdsheet": {
- "sign": true,
- "vital": true,
- "summary": false,
- "medicine": true,
- "diagnosis": true,
- "drawImage": true,
- "assessment": true,
- "investigation": true,
- "datasheetimage": true
}, - "stream": true,
- "debug_mode": false,
- "advanced_settings": {
- "brand": true,
- "generic": true,
- "TNMCRegNo": true,
- "genericFront": true,
- "FrequencyEvng": false,
- "preferredLang": "English",
- "prioritize_accuracy": true
}
}
}Accepts patient, doctor, hospital, and vitals data for integration.
| hospital_id required | string |
required | object |
required | object |
required | object |
{- "hospital_id": "HOS789",
- "doctor": {
- "practitioner_id": "PRACT789"
}, - "patient": {
- "patient_id": "PAT123",
- "name": "John Doe",
- "age": 30,
- "gender": "Male",
- "language": "English",
- "past_history": [
- {
- "condition": "Hypertension",
- "diagnosed_on": "2023-01-15",
- "status": "Active"
}
], - "family_history": [
- {
- "relation": "Father",
- "condition": "Diabetes"
}
]
}, - "vitals": {
- "height_cm": 170,
- "weight_kg": 70,
- "bmi": 24.2,
- "chest_circumference": null,
- "head_circumference": null,
- "blood_pressure": "120/80",
- "pulse_rate": 72,
- "respiratory_rate": 16,
- "temperature_celsius": 36.6,
- "oxygen_saturation": 98,
- "glucose_mg_dl": 90,
- "spo2": 98,
- "ecg_status": "Normal",
- "abnormal_conditions": [
- {
- "condition": "Arrhythmia",
- "severity": "Mild",
- "note": "Observed during routine checkup"
}
]
}
}{- "message": "New patient created successfully. Vitals uploaded.",
}Retrieves the latest patient interactions for a given hospital and hospital_patient_id.
The API fetches interaction details (Edited OPD or Audio URL), reads the associated file from Google Cloud Storage (if available), and returns parsed interaction notes.
If data is not yet generated, the API returns a retry message.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier (maps to organization) |
| patient_id required | string Example: patient_id=GEN9-202602-00133 Hospital patient identifier (hospital_patient_id) |
| limit | integer Example: limit=3 Number of latest interactions to return (min 1, max 3) |
{- "count": 1,
- "data": [
- {
- "interaction_id": 108055,
- "patient_id": "QAT70-202603-00157",
- "doctor_id": 318,
- "patient": {
- "patient_id": "QAT70-202603-00157",
- "first_name": "zuu",
- "last_name": "",
- "hospital_patient_id": "QAT70-202603-00157",
- "date_of_birth": null,
- "gender": null,
- "age": null
}, - "interaction_date": "2026-03-04T16:34:52.000Z",
- "interaction_detail_type": "Audio url",
- "created_at": "2026-03-04T16:35:06.068Z",
- "data": {
- "vitals": [ ],
- "dashboard_notes": { },
- "dermatology_notes": { },
- "assessment": [ ],
- "past_medications_templates": [ ],
- "phonetic_uri": "gs://medscribe-dev/70/GENERAL AND LAPAROSCOPIC SURGERY/318/medication_autocorrect.csv",
- "vaccines": [ ],
- "medication_templates": [
- {
- "medication_name": "PARACETAMOL 500MG (CALPOL 500MG TAB)",
- "brand_name": "CALPOL 500MG TAB",
- "brand_id": "9141",
- "generic_name": "PARACETAMOL 500MG",
- "strength": "500 mg",
- "uom": "mg",
- "frequency_morning": "1",
- "frequency_afternoon": "1",
- "frequency_evening": "1",
- "frequency_night": "0",
- "days": null,
- "quantity": null,
- "dosage_value": "500",
- "prn": "",
- "route": "Oral",
- "drug_type": "tablet",
- "vaccine": false,
- "duration": "",
- "instructions": "Take on alternative days, three times a day.",
- "frequency_code": "ATHTMAE",
- "frequency_description": "Alternate Days Thrice Time (Morn,Noon,Eve)(1-1-1-0)",
- "route_code": "24",
- "route_description": "Oral",
- "uom_code": "NUMBR",
- "uom_description": "No(s)"
}
], - "Diagnosis": "**Fever**",
- "chief_complaints": "**Fever**.",
- "history_of_presenting_illness": "Patient presents with complaints of **fever**.",
- "follow_up": "Follow up after **one week**."
}
}
]
}Creates or updates a Master Health Checkup (MHC) patient, assigns doctor, and optionally uploads vitals.
MHC integration payload
| hospital_id required | string |
| package_name required | string |
required | object |
required | object |
Array of objects |
{- "hospital_id": "9",
- "package_name": "Executive Health Checkup",
- "doctor": {
- "practitioner_id": "123"
}, - "patient": {
- "patient_id": "HPID1001",
- "name": "Ravi Kumar",
- "age": 42,
- "gender": "Male",
- "language": "English",
- "date_of_birth": "1984-01-15",
- "phone_number": "9876543210",
- "email": "ravi.kumar@example.com",
- "address1": "12 MG Road, Bengaluru",
- "marital_status": "Married",
- "occupation": "Engineer",
- "past_history": "Diabetes,Hypertension"
}, - "vitals": [
- {
- "height": 172,
- "weight": 78,
- "bmi": 26.4,
- "systolic_bp": 130,
- "diastolic_bp": 85,
- "pulse_rate": 78,
- "temperature": 98.6,
- "spo2": 98
}
]
}{- "message": "MHC patient updated successfully.",
- "patient_id": "GEN9-202605-00010",
- "hospital_patient_id": "HPID1001",
- "mhc_id": "MHC-GEN9-202605-00011",
- "package_name": "Executive Health Checkup",
- "doctor_list": [
- 403
], - "vitals_uploaded": true
}Retrieves generated Master Health Checkup (MHC) form data for a patient by calling the OPD chatbot upstream service.
Use this GET endpoint after creating or updating an MHC patient via POST /patient/softwareintegrationmhc.
The API resolves the patient (by internal patient_id or hospital_patient_id), locates the active MHC record,
and returns the generated form payload for the requested form_name.
Response form_name uses internal keys (eye_checkup, dental_checkup, gynaec_checkup,
history_physical_examination, ent_checkup). The matching question_text field echoes the requested label.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier (maps to organization) |
| patient_id required | string Example: patient_id=ragulID1002 Patient identifier (internal patient_id or hospital_patient_id) |
| form_name required | string Enum: "Generate Eye Checkup" "Generate Dental Checkup" "Generate Gynecology checkup Report" "Generate History and Physical Examination" "Generate ENT Checkup" Example: form_name=Generate ENT Checkup MHC form to generate. |
| mhc_id | string Example: mhc_id=MHC-GEN9-202606-00002 Optional MHC record identifier. When omitted, the most recently updated active MHC record is used. |
{- "status": true,
- "hospital_id": "9",
- "patient_id": "ragulID1002",
- "internal_patient_id": "GEN9-202606-00221",
- "hospital_patient_id": "ragulID1002",
- "mhc_id": "MHC-GEN9-202606-00002",
- "form_name": "eye_checkup",
- "question_text": "Generate Eye Checkup",
- "interaction_id": 119880,
- "force_regenerate": 119880,
- "data": {
- "response": { }
}
}Uploads medication master data for a hospital in JSON format and stores it as a CSV file.
Requirements:
hospital_id and a non-empty medications array are required.BRAND NAME and GENERIC NAME.BRAND ID is optional, but if provided in any item, it must be present in all items.Optional Fields:
UOM CODEUOM DESCRIPTION (if provided, UOM CODE is required).ACTIVE FROM (DD/MM/YYYY)ACTIVE TO (DD/MM/YYYY)MEDICATION TYPEValidation:
BRAND ID values in the request are marked invalid.BRAND NAME and GENERIC NAME combinations are marked invalid.The API stores the valid data as a CSV file and returns the processed file URL along with any invalid rows.
| hospital_id required | string Hospital/organization identifier. |
required | Array of objects non-empty Array of medication objects. Supported fields (case-sensitive as shown in examples):
|
{- "hospital_id": "9",
- "medications": [
- {
- "BRAND ID": "13752",
- "BRAND NAME": "OLVANCE 40MG TAB",
- "GENERIC NAME": "OLMESARTAN MEDOXOMIL 40MG",
- "UOM CODE": "mg",
- "UOM DESCRIPTION": "Milligram",
- "ACTIVE FROM": "01/01/2026",
- "ACTIVE TO": "31/12/2026",
- "MEDICATION TYPE": "Tablet"
}
]
}{- "message": "Medication data uploaded successfully",
- "invalid": [
- {
- "BRAND ID": "13752",
- "BRAND NAME": "MERSILK 5062",
- "GENERIC NAME": "MERSILK",
- "UOM CODE": "",
- "UOM DESCRIPTION": "Milligram",
- "error": "BRAND NAME and GENERIC NAME combination already exists"
}
]
}Updates the medication master data for a hospital by merging the given JSON medications with the existing stored CSV.
hospital_id and non-empty medications are required.BRAND NAME and GENERIC NAME.BRAND ID is optional, but if used in any item, it must be present in all items.UOM CODE and UOM DESCRIPTION are optional (if UOM DESCRIPTION is provided, UOM CODE is required).ACTIVE FROM, ACTIVE TO, and MEDICATION TYPE are optional; dates use DD/MM/YYYY.medications, rows, data, or items; hospital_id may be supplied in query or body.| hospital_id required | string Hospital/organization identifier. |
required | Array of objects non-empty Array of medication objects to merge into existing data. |
{- "hospital_id": "9",
- "medications": [
- {
- "BRAND ID": "13752",
- "BRAND NAME": "OLVANCE 40MG TAB",
- "GENERIC NAME": "OLMESARTAN MEDOXOMIL 40MG",
- "UOM CODE": "mg",
- "UOM DESCRIPTION": "Milligram",
- "ACTIVE FROM": "01/01/2026",
- "ACTIVE TO": "31/12/2026",
- "MEDICATION TYPE": "Tablet"
}
]
}{- "message": "Medication data updated successfully (merged, duplicates removed)",
- "url": "gs://bucket/csv_uploads/organization_20260916120000.csv",
- "invalid": [ ]
}Uploads a medication master CSV for a hospital and replaces the existing stored file (if any). The API validates the CSV, stores only valid rows, and returns the processed file URL.
Supported CSV headers (normalized case-insensitively and kept in this order):
BRAND NAME, GENERIC NAMEBRAND ID, BRAND NAME, GENERIC NAMEBRAND NAME, GENERIC NAME, UOM CODE, UOM DESCRIPTIONBRAND ID, BRAND NAME, GENERIC NAME, UOM CODE, UOM DESCRIPTIONACTIVE FROM, ACTIVE TO, and MEDICATION TYPE columns in that order.Validation rules:
BRAND NAME and GENERIC NAME are required.BRAND ID is required only if the header contains BRAND ID.UOM CODE and UOM DESCRIPTION are optional.UOM DESCRIPTION is provided, UOM CODE must also be provided.ACTIVE FROM and ACTIVE TO, when present, must use DD/MM/YYYY.BRAND ID values are rejected.BRAND NAME + GENERIC NAME combinations are rejected., or . are rejected.Invalid rows are returned in the invalid field of the response.
| hospital_id required | string Hospital/organization identifier. |
| csvFile required | string <binary> Medication CSV file to upload. |
{- "message": "CSV uploaded and saved",
- "invalid": [ ]
}Uploads a medication CSV for the given hospital_id and merges it with the existing medication CSV stored in Google Cloud Storage (GCS).
CSV headers (normalized case-insensitively and kept in this order):
BRAND NAME, GENERIC NAMEBRAND ID, BRAND NAME, GENERIC NAMEBRAND NAME, GENERIC NAME, UOM CODE, UOM DESCRIPTIONBRAND ID, BRAND NAME, GENERIC NAME, UOM CODE, UOM DESCRIPTIONACTIVE FROM, ACTIVE TO, and MEDICATION TYPE columns in that order.Validation rules (applies to both existing CSV and uploaded CSV):
BRAND NAME and GENERIC NAME are required in every row., or . are rejected.BRAND ID values (when BRAND ID exists) are rejected.BRAND NAME + GENERIC NAME combinations are rejected.UOM DESCRIPTION is provided, UOM CODE is required.ACTIVE FROM and ACTIVE TO, when present, must use DD/MM/YYYY.Header mismatch between existing and new CSV.Merge behavior:
BRAND ID, the merge key is BRAND ID.BRAND NAME + GENERIC NAME.| hospital_id required | string Hospital identifier for the organization. |
| csvFile required | string <binary> Medication CSV file to upload (must end with |
{- "message": "Medication data updated successfully (merged, duplicates removed)",
- "invalid": [ ]
}Uploads and replaces the organization's investigation CSV. Required headers are Service ID and Standard Lab Test Name. Optional headers are Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO. Headers are matched case-insensitively. Dates, when supplied, must use DD/MM/YYYY. Invalid rows are returned while valid rows are stored; an empty Alias Name is populated from Standard Lab Test Name.
| hospital_id required | string The ID of the hospital associated with the organization. |
| csvFile required | string <binary> CSV with required columns Service ID and Standard Lab Test Name, and optional Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO. |
{- "message": "CSV updated and saved",
- "invalid": [
- {
- "Service ID": "INV001",
- "Standard Lab Test Name": "Complete Blood Count",
- "Alias Name": "CBC",
- "error": "Service ID is required"
}
]
}Merges the uploaded CSV with stored investigation data using the case-insensitive Service ID and Service Type pair as the key. The same Service ID may therefore be stored in multiple rows when Service Type differs, while duplicate Service ID and Service Type pairs are rejected. Required headers are Service ID and Standard Lab Test Name; optional headers are Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO. Dates must use DD/MM/YYYY.
| hospital_id required | string The ID of the hospital associated with the organization. |
| csvFile required | string <binary> Investigation CSV to merge. Service ID and Standard Lab Test Name are required; Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO are optional. |
{- "message": "CSV uploaded and saved",
- "invalid": [
- {
- "Service ID": "INV001",
- "Standard Lab Test Name": "Complete Blood Count",
- "Alias Name": "CBC",
- "error": "Service ID is required"
}
]
}Replaces stored investigation data using either a direct JSON array or { data: [...] }. Service ID and Standard Lab Test Name are required. Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO are optional. Field names are normalized case-insensitively and dates must use DD/MM/YYYY.
| hospital_id required | string The ID of the hospital associated with the organization. |
Investigation rows wrapped in data; the controller also accepts a direct array.
required | Array of objects |
{- "data": [
- {
- "Service ID": "INV001",
- "Standard Lab Test Name": "Complete Blood Count",
- "Alias Name": "CBC",
- "Service Type": "Laboratory",
- "Hospital ID": "HOSP123",
- "ACTIVE FROM": "01/01/2026",
- "ACTIVE TO": "31/12/2026"
}
]
}{- "message": "Investigation data uploaded successfully",
- "invalid": [
- {
- "Service ID": "INV001",
- "error": "Service ID is required"
}
]
}Merges a direct JSON array or { data: [...] } into stored investigation data using the case-insensitive Service ID and Service Type pair as the key. The same Service ID may be used for different Service Types. Service ID and Standard Lab Test Name are required; all other supported columns are optional. Dates must use DD/MM/YYYY.
| hospital_id required | string The ID of the hospital associated with the organization. |
Array of investigation objects to merge with existing data
required | Array of objects |
{- "data": [
- {
- "Service ID": "INV001",
- "Standard Lab Test Name": "Complete Blood Count",
- "Alias Name": "CBC",
- "Service Type": "Laboratory",
- "Hospital ID": "HOSP123",
- "ACTIVE FROM": "01/01/2026",
- "ACTIVE TO": "31/12/2026"
}
]
}{- "message": "Investigation data updated successfully",
- "invalid": [
- {
- "Service ID": "INV001",
- "error": "Service ID is required"
}
]
}Retrieves route master data for the given hospital_id.
This API:
If the organization is not found, or route data is unavailable, the API returns an error.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier used to find the organization |
[- {
- "ROUTE CODE": "IV",
- "ROUTE DESCRIPTION": "Intravenous"
}
]Uploads a Route master CSV for the specified hospital_id (query parameter). The CSV requires ROUTE CODE and ROUTE DESCRIPTION. ACTIVE FROM and ACTIVE TO are optional and must use DD/MM/YYYY. Header matching is case-insensitive; unknown or duplicate headers are rejected. Use the uploadRouteCsv API only for the initial upload of Route master data. If this API is called again for appending data, the existing Route list will be completely deleted and replaced with the newly uploaded CSV data. For any modifications, additions, or updates to the existing Route list, please use the updateRouteCsvs API.
| hospital_id required | string Hospital ID used to resolve organization |
| csvFile required | string <binary> CSV file containing route data (ROUTE CODE, ROUTE DESCRIPTION) |
{- "message": "CSV uploaded and saved",
- "invalid": [
- {
- "ROUTE CODE": "",
- "ROUTE DESCRIPTION": "Oral",
- "error": "ROUTE CODE is empty"
}
]
}Uploads a Route CSV file for the specified hospital_id and merges it with the existing Route data (if available) stored for the organization.
Requirements: - ROUTE CODE and ROUTE DESCRIPTION are required headers. - ACTIVE FROM and ACTIVE TO are optional headers using DD/MM/YYYY. - Header matching is case-insensitive; unknown or duplicate headers are rejected.
Validation: - If duplicate ROUTE CODE values are found in the uploaded CSV, those rows will be
reported in the invalid field of the response.
Merge Behavior: - ROUTE CODE is used as the unique key. - If a ROUTE CODE already exists in the stored Route data, the uploaded value overwrites the existing one.
| hospital_id required | string Hospital ID used to resolve organization |
| csvFile required | string <binary> CSV file containing route data (ROUTE CODE, ROUTE DESCRIPTION) |
{- "message": "Route data updated successfully (merged, duplicates removed)",
- "invalid": [
- {
- "ROUTE CODE": "24",
- "ROUTE DESCRIPTION": "Oral",
- "error": "ROUTE CODE already exists"
}
]
}Uploads Route master data from a direct array or an object containing routes, rows, data, or items, then stores it as CSV. ROUTE CODE and ROUTE DESCRIPTION are required; ACTIVE FROM and ACTIVE TO are optional dates in DD/MM/YYYY format. This API should be used only for the initial upload of Route data. If this API is called again, the existing Route list will be completely deleted and replaced with the newly uploaded data. For any modifications or additions to the existing Route list, please use the updateRouteJson API.
| hospital_id required | string The ID of the hospital/organization |
Array of objects Array of route objects |
{- "data": [
- {
- "ROUTE CODE": "string",
- "ROUTE DESCRIPTION": "string"
}
]
}{- "message": "JSON uploaded and saved as CSV",
- "invalid": [
- {
- "index": 1,
- "error": "ROUTE DESCRIPTION is empty"
}
], - "totalItems": 2,
- "invalidItemsCount": 0
}Merges a direct JSON array, or an object containing routes, rows, data, or items, into stored route data using ROUTE CODE as the key. ACTIVE FROM and ACTIVE TO are optional dates in DD/MM/YYYY format.
The uploaded Route json will be merged with the existing route data (if available) stored for the organization and saved as a CSV file.
| hospital_id required | string Hospital ID used to identify the organization |
Array of objects |
{- "data": [
- {
- "ROUTE CODE": "string",
- "ROUTE DESCRIPTION": "string"
}
]
}{- "status": "success",
- "message": "Route data updated successfully (merged, stored as CSV)",
- "invalid": [
- {
- "ROUTE CODE": "24",
- "ROUTE DESCRIPTION": "Oral",
- "error": "ROUTE CODE already exists"
}
]
}Deletes the route CSV file associated with the given hospital_id.
This API:
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier used to find the organization |
{- "message": "Route CSV removed successfully"
}Retrieves frequency master data for the given hospital_id.
This API:
If the organization is not found, or frequency data is unavailable, the API returns an error.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier used to find the organization |
[- {
- "FREQUENCY CODE": "OD",
- "FREQUENCY DESCRIPTION": "Once Daily"
}
]Uploads a Frequency master CSV for the given hospital_id (query param) and stores it for the organization. The CSV requires FREQUENCY CODE and FREQUENCY DESCRIPTION. ACTIVE FROM and ACTIVE TO are optional and must use DD/MM/YYYY. Header matching is case-insensitive; unknown or duplicate headers are rejected.
Validation:
invalid.invalid.| hospital_id required | string Hospital ID used to resolve organization |
| csvFile required | string <binary> CSV file with headers FREQUENCY CODE and FREQUENCY DESCRIPTION |
{- "message": "CSV uploaded and saved",
- "invalid": [
- {
- "FREQUENCY CODE": "",
- "FREQUENCY DESCRIPTION": "Once daily",
- "error": "FREQUENCY CODE is empty"
}
]
}This API uploads or updates Frequency master data for a hospital using JSON input and stores it as a CSV file.
For the initial setup, this API can be used to upload the complete Frequency master list for the organization. If this API is called again, the existing Frequency list will be completely deleted and replaced with the newly uploaded data.
For any modifications or incremental updates to the existing Frequency list, please use the updateFrequencyJson API.
Requirements:
Validation:
invalid.invalid field. A 400 is returned when no valid rows remain.Behavior:
The final dataset is stored as a CSV file and linked to the organization.
| hospital_id required | string The ID of the hospital/organization |
Array of objects Array of frequency objects |
{- "data": [
- {
- "FREQUENCY CODE": "string",
- "FREQUENCY DESCRIPTION": "string"
}
]
}{- "message": "JSON uploaded and saved as CSV",
- "invalid": [
- {
- "index": 1,
- "error": "FREQUENCY DESCRIPTION is empty"
}
], - "totalItems": 2,
- "invalidItemsCount": 0
}This API updates frequency master data for a hospital using JSON input.
The provided Frequency list will be merged with the existing frequency data (if available) stored for the organization and saved as a CSV file.
Requirements:
Validation:
invalid.invalid. A 400 is returned when no valid rows remain.Merge Behavior:
The final merged dataset is stored as a CSV file and linked to the organization.
| hospital_id required | string Hospital ID used to resolve organization |
Array of objects Array of frequency objects. Can be sent directly as an array or wrapped as an object with a data property. |
{- "data": [
- {
- "FREQUENCY CODE": "string",
- "FREQUENCY DESCRIPTION": "string"
}
]
}{- "status": "success",
- "message": "Frequency data updated successfully (merged, stored as CSV)",
- "invalid": [
- {
- "FREQUENCY CODE": "OD",
- "FREQUENCY DESCRIPTION": "Once daily",
- "error": "FREQUENCY CODE already exists"
}
]
}This API updates frequency data for a hospital.
The uploaded Frequency CSV will be merged with the existing frequency data (if available) stored for the organization and saved as a CSV file.
Requirements:
Validation:
invalid field of the response.invalid.invalid.Merge Behavior:
The final merged dataset will be stored as a CSV file and linked to the organization.
| hospital_id required | string Hospital ID used to resolve organization |
| csvFile required | string <binary> CSV file containing frequency data (FREQUENCY CODE, FREQUENCY DESCRIPTION) |
{- "message": "Frequency data updated successfully (merged, duplicates removed)",
- "invalid": [
- {
- "FREQUENCY CODE": "OD",
- "FREQUENCY DESCRIPTION": "Once daily",
- "error": "FREQUENCY CODE already exists"
}
]
}Deletes the frequency CSV file associated with the given hospital_id.
This API:
Returns success message after deletion.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier used to find the organization |
{- "message": "Frequency CSV removed successfully"
}Updates medication records in the CSV file using BRAND ID as the identifier. Required Query Parameters: - hospital_id Request Body: - medications (array of medication objects with BRAND ID and fields to update) Notes: - Validates hospital_id and organization existence. - Ensures medication CSV exists and contains BRAND ID column. - Updates rows matching BRAND ID. - Prevents duplicate BRAND NAME and GENERIC NAME combinations. - Returns invalid and not found entries if any issues occur.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier. |
required | Array of objects List of medication records to update. |
{- "medications": [
- {
- "BRAND ID": "L917",
- "BRAND NAME": "LUBIC JELLY {50GM}",
- "GENERIC NAME": "Lubricant Jelly",
- "UOM DESCRIPTION": "No(s)",
- "UOM CODE": "NUMBR"
}
]
}{- "message": "Medication rows updated successfully",
- "updated": [
- { }
], - "url": "gs://bucket/medication/updated_file.csv"
}Deletes medication records from the CSV file using BRAND ID as the identifier. Required Query Parameters: - hospital_id Request Body: - medications (array containing BRAND ID values to delete) Notes: - Validates hospital_id and organization existence. - Ensures medication CSV exists and contains BRAND ID column. - Deletes rows matching provided BRAND IDs. - Returns deleted rows and not_found entries if any IDs do not exist. - If all rows are deleted, the CSV file is removed from storage.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier. |
required | Array of objects List of medication entries to delete. |
{- "medications": [
- {
- "BRAND ID": "L917"
}
]
}{- "message": "Medication rows deleted successfully",
- "deleted": [
- { }
], - "url": "gs://bucket/medication/updated_file.csv",
- "data": [
- { }
]
}Fetches all Drug Allergy CSV records stored for a hospital. Required Query Parameters: - hospital_id Notes: - Returns all drug allergy rows from the stored CSV - If no CSV exists for the hospital, API returns 404
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
[- {
- "DRUGALLERGY CODE": "A001",
- "DRUGALLERGY NAME": "Penicillin Allergy",
- "DRUGALLERGY DESCRIPTION": "Rash and swelling reaction"
}
]Uploads a CSV file containing drug allergy data for a hospital.
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
.csv files are accepted - Duplicate DRUGALLERGY CODE values are not allowed - Invalid rows will be returned in the response| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing drug allergy data |
{- "message": "Drug Allergy CSV uploaded and saved",
- "invalid": [
- { }
]
}Updates existing Drug Allergy CSV data for a hospital.
The uploaded CSV will be merged with the existing stored CSV data using DRUGALLERGY CODE as the unique identifier.
Behavior: - Existing rows with matching DRUGALLERGY CODE will be updated - New DRUGALLERGY CODE rows will be added - Duplicate DRUGALLERGY CODE values inside the uploaded CSV are not allowed
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
.csv files are accepted - Duplicate DRUGALLERGY CODE values are not allowed within upload file - Invalid rows will be returned in the response - Existing CSV data will be preserved and merged| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing updated drug allergy data |
{- "message": "Drug Allergy CSV updated successfully",
- "invalid": [
- { }
]
}Uploads Drug Allergy master data in JSON format for a hospital.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing an allergies array
Accepted alternatives: - Direct array, or drugAllergies, drug_allergies, rows, data, or items
Validation Rules: - Each allergy object requires DRUGALLERGY CODE and DRUGALLERGY NAME - DRUGALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO are optional - DRUGALLERGY CODE values must be unique within the request - Required values cannot be empty - Duplicate DRUGALLERGY CODE entries will result in validation errors Notes: - hospital_id can be passed either in query params or request body - Invalid rows will be returned separately in the response - Data is stored and converted internally into CSV format
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "allergies": [
- {
- "DRUGALLERGY CODE": "A001",
- "DRUGALLERGY NAME": "Penicillin Allergy",
- "DRUGALLERGY DESCRIPTION": "Rash and swelling reaction"
}
]
}{- "message": "Drug Allergy JSON uploaded and saved",
- "invalid": [
- { }
]
}Updates existing Drug Allergy master data using JSON payload.
The uploaded allergy records are merged with existing stored data using DRUGALLERGY CODE as the unique identifier.
Behavior: - Existing allergy rows with matching DRUGALLERGY CODE will be updated - New DRUGALLERGY CODE rows will be added - Duplicate DRUGALLERGY CODE values inside request payload are not allowed
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing an allergies array
Accepted alternatives: - Direct array, or drugAllergies, drug_allergies, rows, data, or items
Validation Rules: - Each allergy object requires DRUGALLERGY CODE and DRUGALLERGY NAME - DRUGALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO are optional - Required values cannot be empty - Duplicate DRUGALLERGY CODE values are not allowed within request payload
Notes: - hospital_id can be passed either in query params or request body - Existing allergy data will be preserved and merged - Invalid rows will be returned separately in the response
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "allergies": [
- {
- "DRUGALLERGY CODE": "A001",
- "DRUGALLERGY NAME": "Updated Penicillin Allergy",
- "DRUGALLERGY DESCRIPTION": "Severe rash and swelling reaction"
}
]
}{- "message": "Drug Allergy JSON updated successfully",
- "invalid": [
- { }
]
}Updates specific Drug Allergy rows in the existing CSV data using DRUGALLERGY CODE as the unique identifier.
Behavior: - Only rows with matching DRUGALLERGY CODE values will be updated - DRUGALLERGY CODE itself cannot be modified - Partial updates are supported for other fields - Duplicate DRUGALLERGY CODE values within request payload are not allowed
Required Query Parameters: - hospital_id
Validation Rules: - Each allergy object must contain:
code in query/body or DRUGALLERGY CODE in the body| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "allergies": [
- {
- "DRUGALLERGY CODE": "A0023569",
- "DRUGALLERGY NAME": "Updated Peanut Allergy",
- "DRUGALLERGY DESCRIPTION": "Updated allergy description"
}
]
}{- "message": "Drug Allergy rows updated successfully",
- "updated": [
- { }
],
}Deletes specific drug allergy rows from the existing Drug Allergy CSV using DRUGALLERGY CODE values.
Required Query Parameters: - hospital_id
Request Body: - allergies array containing DRUGALLERGY CODE values
The body may contain one code or use drugAllergies, drug_allergies, allergies, rows, data, or items. A single code may also be supplied with the code query parameter.
Notes: - Matching is case-insensitive - DRUGALLERGY CODE is mandatory - If any code is not found, API returns 404 - If all rows are deleted, the CSV file will be removed from storage
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of allergy rows to delete |
{- "hospital_id": "9",
- "allergies": [
- {
- "DRUGALLERGY CODE": "A0023569"
}
]
}{- "message": "Drug Allergy rows deleted successfully",
- "deleted": [
- {
- "DRUGALLERGY CODE": "A0023569",
- "DRUGALLERGY NAME": "Peanut Allergy",
- "DRUGALLERGY DESCRIPTION": "Severe allergic reaction to peanuts"
}
],
}Fetches all Food Allergy CSV records stored for a hospital. Required Query Parameters: - hospital_id Notes: - Returns all food allergy rows from the stored CSV - If no CSV exists for the hospital, API returns 404
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
[- {
- "FOODALLERGY CODE": "F001",
- "FOODALLERGY NAME": "Peanut Allergy",
- "FOODALLERGY DESCRIPTION": "Severe allergic reaction to peanuts"
}
]Uploads a CSV file containing food allergy data for a hospital.
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing food allergy data |
{- "message": "Food Allergy CSV uploaded and saved",
- "invalid": [
- { }
]
}Updates the existing Food Allergy CSV data for a hospital by merging uploaded CSV rows with existing records using FOODALLERGY CODE.
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
.csv files are accepted - Existing rows are updated using FOODALLERGY CODE - New FOODALLERGY CODE rows are added - Duplicate FOODALLERGY CODE values are not allowed - Invalid rows will be returned in the response| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing updated food allergy data |
{- "message": "Food Allergy CSV updated successfully",
- "invalid": [
- { }
]
}Uploads Food Allergy data in JSON format for a hospital.
Required Query Parameters: - hospital_id
Request Body: - JSON object containing a data array of food allergy records
Accepted body: - A direct array or foodAllergies, food_allergies, allergies, rows, data, or items - Each row requires:
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of food allergy records |
{- "hospital_id": "9",
- "data": [
- {
- "FOODALLERGY CODE": "ORDCN0277",
- "FOODALLERGY NAME": "Curd Allergy",
- "FOODALLERGY DESCRIPTION": "Curd Allergy"
}
]
}{- "message": "Food Allergy JSON uploaded and saved",
- "invalid": [
- { }
]
}Updates existing Food Allergy records using JSON payload for a hospital. New records are added and existing ones are updated.
Required Query Parameters: - hospital_id
Request Body: - JSON object containing a data array of food allergy records
Accepted body: - A direct array or foodAllergies, food_allergies, allergies, rows, data, or items - Each row requires:
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of food allergy records to update |
{- "hospital_id": "9",
- "data": [
- {
- "FOODALLERGY CODE": "ORDCN0277",
- "FOODALLERGY NAME": "Curdedd Allergy",
- "FOODALLERGY DESCRIPTION": "Curd Allergy"
}
]
}{- "message": "Food Allergy JSON updated successfully",
- "invalid": [
- { }
]
}Updates existing food allergy rows in the Food Allergy CSV using FOODALLERGY CODE as the unique identifier.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
Notes: - FOODALLERGY CODE must already exist in the CSV - Duplicate FOODALLERGY CODE values in request are not allowed - Only provided fields will be updated - FOODALLERGY CODE cannot be modified - Invalid or missing rows will be returned in the response
Required JSON Fields: - FOODALLERGY CODE
The body may be a direct array or use foodAllergies, food_allergies, allergies, rows, data, or items. A single row may instead use the code query/body field.
Updatable fields include FOODALLERGY NAME, FOODALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO. A single row may instead use the code query/body field.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "FOODALLERGY CODE": "ORDCN0277",
- "FOODALLERGY NAME": "Updated Curd Allergy",
- "FOODALLERGY DESCRIPTION": "Updated curd allergy description"
}
]
}{- "message": "Food Allergy rows updated successfully",
- "updated": [
- {
- "FOODALLERGY CODE": "ORDCN0277",
- "FOODALLERGY NAME": "Updated Curd Allergy",
- "FOODALLERGY DESCRIPTION": "Updated curd allergy description"
}
],
}Deletes food allergy rows from the Food Allergy CSV using FOODALLERGY CODE as the unique identifier.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
Notes: - FOODALLERGY CODE must already exist in the CSV - Duplicate FOODALLERGY CODE values are ignored internally - If all rows are deleted, the CSV file will be removed - Missing or invalid codes will be returned in not_found
Required JSON Fields: - FOODALLERGY CODE
The body may be a direct array or use foodAllergies, food_allergies, allergies, rows, data, or items. A single row may instead use the code query/body field.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "FOODALLERGY CODE": "ORDCN0279"
}
]
}{- "message": "Food Allergy rows deleted successfully",
- "deleted": [
- {
- "FOODALLERGY CODE": "ORDCN0279",
- "FOODALLERGY NAME": "Sunflower Seeds Allergy",
- "FOODALLERGY DESCRIPTION": "Sunflower Seed Allergy"
}
],
}Fetches all Other Allergy CSV records configured for a hospital. Required Query Parameters: - hospital_id Notes: - Returns all rows from the stored Other Allergy CSV - If no CSV data exists for the hospital, a 404 response is returned
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
[- {
- "OTHERALLERGY CODE": "OTH001",
- "OTHERALLERGY NAME": "Dust Allergy",
- "OTHERALLERGY DESCRIPTION": "Sneezing and breathing irritation due to dust"
}
]Uploads a CSV file containing Other Allergy data for a hospital.
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
Notes: - Only .csv files are accepted - Duplicate OTHERALLERGY CODE values are not allowed - Invalid rows will be returned in the response
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing Other Allergy data |
{- "message": "Other Allergy CSV uploaded and saved",
- "invalid": [
- { }
]
}Updates the existing Other Allergy CSV data for a hospital by merging records from the uploaded CSV file using OTHERALLERGY CODE as the unique identifier.
Required Query Parameters: - hospital_id
Request: - Multipart form-data with a CSV file field named csvFile
CSV headers: - The CSV must contain the following required column names:
Notes: - Only .csv files are accepted - Existing rows with matching OTHERALLERGY CODE will be updated - New OTHERALLERGY CODE values will be added - Duplicate OTHERALLERGY CODE values in request are not allowed - Invalid rows will be returned in the response
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| csvFile required | string <binary> CSV file containing Other Allergy data |
{- "message": "Other Allergy CSV updated successfully",
- "invalid": [
- { }
]
}Uploads Other Allergy data in JSON format for a hospital.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
JSON fields: - OTHERALLERGY CODE - OTHERALLERGY NAME - OTHERALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO are optional
The body may be a direct array or use otherAllergies, other_allergies, allergies, rows, data, or items. Field names are normalized case-insensitively.
Notes: - Duplicate OTHERALLERGY CODE values are not allowed - Invalid rows will be returned in the response - If all rows are invalid, the API returns 400
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "OTHERALLERGY CODE": "ORDCN0290",
- "OTHERALLERGY NAME": "Grass Pollen Allergy",
- "OTHERALLERGY DESCRIPTION": "Grass Pollen Allergy"
}
]
}{- "message": "Other Allergy JSON uploaded and saved",
- "invalid": [
- { }
]
}Updates existing Other Allergy records using JSON payload data. Existing rows are matched and updated using OTHERALLERGY CODE as the unique identifier. New codes will be added if they do not already exist.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
JSON fields: - OTHERALLERGY CODE - OTHERALLERGY NAME - OTHERALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO are optional
The body may be a direct array or use otherAllergies, other_allergies, allergies, rows, data, or items. Field names are normalized case-insensitively.
Notes: - Duplicate OTHERALLERGY CODE values in request are not allowed - Invalid rows will be returned in the response
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "OTHERALLERGY CODE": "ORDCN0290",
- "OTHERALLERGY NAME": "Updated Grass Pollen Allergy",
- "OTHERALLERGY DESCRIPTION": "Updated Grass Pollen Allergy"
}
]
}{- "message": "Other Allergy JSON updated successfully",
- "invalid": [
- { }
]
}Updates existing Other Allergy rows in the Other Allergy CSV using OTHERALLERGY CODE as the unique identifier.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
Notes: - OTHERALLERGY CODE must already exist in the CSV - Duplicate OTHERALLERGY CODE values in request are not allowed - Only provided fields will be updated - OTHERALLERGY CODE cannot be modified - Invalid or missing rows will be returned in the response
Required JSON Fields: - OTHERALLERGY CODE
Updatable fields include OTHERALLERGY NAME, OTHERALLERGY DESCRIPTION, ACTIVE FROM, and ACTIVE TO. A single row may instead use the code query/body field.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "OTHERALLERGY CODE": "ORDCN0290",
- "OTHERALLERGY NAME": "Updated Grass Pollen Allergy",
- "OTHERALLERGY DESCRIPTION": "Updated allergy description"
}
]
}{- "message": "Other Allergy rows updated successfully",
- "updated": [
- {
- "OTHERALLERGY CODE": "ORDCN0290",
- "OTHERALLERGY NAME": "Updated Grass Pollen Allergy",
- "OTHERALLERGY DESCRIPTION": "Updated allergy description"
}
],
}Deletes Other Allergy rows from the Other Allergy CSV using OTHERALLERGY CODE as the unique identifier.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing a data array
Notes: - OTHERALLERGY CODE must already exist in the CSV - Missing or invalid codes will be returned in not_found - If all rows are deleted, the CSV file will be removed
Required JSON Fields: - OTHERALLERGY CODE
The body may be a direct array or use otherAllergies, other_allergies, allergies, rows, data, or items. A single row may instead use the code query/body field.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects |
{- "hospital_id": "9",
- "data": [
- {
- "OTHERALLERGY CODE": "ORDCN0290"
}
]
}{- "message": "Other Allergy rows deleted successfully",
- "deleted": [
- {
- "OTHERALLERGY CODE": "ORDCN0290",
- "OTHERALLERGY NAME": "Grass Pollen Allergy",
- "OTHERALLERGY DESCRIPTION": "Grass Pollen Allergy"
}
],
}Updates existing Investigation CSV rows using Service ID and, when supplied, Service Type as a case-insensitive composite identifier.
Required Query Parameters: - hospital_id
Request Body: - JSON payload containing an investigations, rows, data, or items array; one row may instead use service_id in query/body or Service ID in the body
Notes: - Service ID must already exist in the CSV - Duplicate Service ID and Service Type pairs in the request are not allowed - Service Type is required when multiple stored rows share the Service ID - Only provided fields will be updated - Service ID cannot be modified - Invalid or missing rows will be returned in the response
Required JSON Fields: - Service ID
Supported optional fields are Standard Lab Test Name, Alias Name, Service Type, Hospital ID, ACTIVE FROM, and ACTIVE TO. Dates use DD/MM/YYYY.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| service_id | string Service ID for a single-row update. |
| service_type | string Service Type used with service_id to select one row when the Service ID is shared. |
| hospital_id | string |
| service_id | string |
| service_type | string |
Array of objects |
{- "hospital_id": "9",
- "service_id": "ITC9492",
- "service_type": "Laboratory",
- "investigations": [
- {
- "Service ID": "ITC9492",
- "Service Type": "Laboratory",
- "STANDARD LAB TEST NAME": "ASCITIC FLUID - AMYLASE UPDATED",
- "ALIAS NAME": "ASCITIC FLUID - AMYLASE UPDATED",
- "Hospital ID": "HOSP123",
- "ACTIVE FROM": "01/01/2026",
- "ACTIVE TO": "31/12/2026"
}
]
}{- "message": "Investigation rows updated successfully",
- "updated": [
- {
- "Service ID": "ITC9492",
- "STANDARD LAB TEST NAME": "ASCITIC FLUID - AMYLASE UPDATED",
- "ALIAS NAME": "ASCITIC FLUID - AMYLASE UPDATED"
}
],
}Deletes investigation rows using Service ID and, when supplied, Service Type as a case-insensitive composite identifier.
Required Query Parameters: - hospital_id
Request Body: - investigations, rows, data, or items array containing Service ID values; one row may instead use service_id in query/body or Service ID in the body
Notes: - SERVICE ID is mandatory for deletion - Service Type is required when multiple stored rows share the Service ID - Matching is case-insensitive - If all rows are deleted, the CSV file will be removed - If any SERVICE ID is not found, the API returns 404 - Multiple investigation rows can be deleted in a single request
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| service_id | string Service ID for a single-row deletion. |
| service_type | string Service Type used with service_id to select one row when the Service ID is shared. |
| hospital_id | string |
| service_id | string |
| service_type | string |
Array of objects List of investigation rows to delete |
{- "hospital_id": "9",
- "service_id": "ITC9492",
- "service_type": "Laboratory",
- "investigations": [
- {
- "Service ID": "ITC9492",
- "Service Type": "Laboratory"
}
]
}{- "message": "Investigation rows deleted successfully",
- "deleted": [
- { }
], - "data": [
- { }
]
}Updates existing route rows in the Route CSV using ROUTE CODE.
Required Query Parameters: - hospital_id
Request Body: - routes array containing ROUTE CODE and fields to update
Notes: - ROUTE CODE is mandatory - Matching is case-insensitive - Only provided fields will be updated - Multiple route rows can be updated in a single request - Duplicate ROUTE CODE values in the request are not allowed
Header Restrictions: - ROUTE CODE - ROUTE DESCRIPTION - ACTIVE FROM (optional; DD/MM/YYYY) - ACTIVE TO (optional; DD/MM/YYYY)
A single row may alternatively be selected with code in the query/body or ROUTE CODE in the body.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of route rows to update |
{- "hospital_id": "9",
- "routes": [
- {
- "ROUTE CODE": "17",
- "ROUTE DESCRIPTION": "Intrathecal"
}
]
}{- "message": "Route rows updated successfully",
- "updated": [
- { }
],
}Deletes route rows from the Route CSV using ROUTE CODE.
Required Query Parameters: - hospital_id
Request Body: - routes array containing ROUTE CODE values, or one code/ROUTE CODE
Notes: - ROUTE CODE is mandatory for deletion - Matching is case-insensitive - Multiple route rows can be deleted in a single request - If all rows are deleted, the CSV file will be removed - If any ROUTE CODE is not found, the API returns 404
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of route rows to delete |
{- "hospital_id": "9",
- "routes": [
- {
- "ROUTE CODE": "17"
}
]
}{- "message": "Route rows deleted successfully",
- "deleted": [
- { }
], - "data": [
- { }
]
}Updates existing frequency rows in the Frequency CSV using FREQUENCY CODE.
Required Query Parameters: - hospital_id
Request Body: - frequencies array containing FREQUENCY CODE and fields to update
Notes: - FREQUENCY CODE is mandatory - Matching is case-insensitive - Only provided fields will be updated - Multiple frequency rows can be updated in a single request - Duplicate FREQUENCY CODE values in the request are not allowed
Header Restrictions: - FREQUENCY CODE - FREQUENCY DESCRIPTION - ACTIVE FROM (optional; DD/MM/YYYY) - ACTIVE TO (optional; DD/MM/YYYY)
A single row may alternatively be selected with code in the query/body or FREQUENCY CODE in the body.
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of frequency rows to update |
{- "hospital_id": "9",
- "frequencies": [
- {
- "FREQUENCY CODE": "AOTA",
- "FREQUENCY DESCRIPTION": "Alternate Days One Times (Noon)(0-1-0-0)"
}
]
}{- "message": "Frequency rows updated successfully",
- "updated": [
- { }
],
}Deletes frequency rows from the Frequency CSV using FREQUENCY CODE.
Required Query Parameters: - hospital_id
Request Body: - frequencies array containing FREQUENCY CODE values, or one code/FREQUENCY CODE
Notes: - FREQUENCY CODE is mandatory for deletion - Matching is case-insensitive - Multiple frequency rows can be deleted in a single request - If all rows are deleted, the CSV file will be removed - If any FREQUENCY CODE is not found, the API returns 404
Header Restrictions: - FREQUENCY CODE - FREQUENCY DESCRIPTION
| hospital_id required | string Example: hospital_id=9 Unique hospital identifier |
| hospital_id | string |
required | Array of objects List of frequency rows to delete |
{- "hospital_id": "9",
- "frequencies": [
- {
- "FREQUENCY CODE": "AOTA"
}
]
}{- "message": "Frequency rows deleted successfully",
- "deleted": [
- { }
], - "data": [
- { }
]
}Retrieves the investigation CSV data for a given hospital. Returns a JSON array of investigations with "SERVICE ID", "STANDARD LAB TEST NAME", and "ALIAS NAME".
| hospital_id required | string The unique hospital ID to fetch investigation CSV for |
[- {
- "SERVICE ID": "INV001",
- "STANDARD LAB TEST NAME": "Complete Blood Count",
- "ALIAS NAME": "CBC"
}
]Upload a patient document file and patient details using multipart/form-data.
| hospital_id required | string Example: hospital_id=9 Hospital ID used to resolve the organization. |
| patient_id required | string Patient identifier. |
| name required | string Patient name. |
| age required | integer Patient age. |
| gender required | string Patient gender. |
| language required | string Patient preferred language. |
| practitioner_id required | string Practitioner identifier. |
| caregiver_id required | string Caregiver identifier. |
| patient_type required | string Enum: "opd" "ipd" Patient type for the upload flow. |
| hospital_inpatient_id required | string Inpatient identifier from the HMS. |
| file required | string File(s) to upload. Send up to 10 document files using the file field. The total upload size must not exceed 30MB. Supported file types include PDF, DOC, DOCX, TXT, JPG, JPEG, PNG, GIF, AVIF, and HEIC. |
{- "message": "Document uploaded successfully."
}