2026-02-16 14:20:52 +07:00
|
|
|
openapi: 3.1.0
|
2026-01-28 17:31:00 +07:00
|
|
|
info:
|
|
|
|
|
title: CLQMS - Clinical Laboratory Quality Management System API
|
|
|
|
|
description: |
|
|
|
|
|
API for Clinical Laboratory Quality Management System supporting patient management,
|
|
|
|
|
specimen tracking, test ordering, instrument integration, and laboratory operations.
|
2026-02-16 14:20:52 +07:00
|
|
|
|
|
|
|
|
**IMPORTANT:** For OpenAPI tools (Swagger UI, Redoc, Postman, etc.), use the bundled file:
|
|
|
|
|
`api-docs.bundled.yaml` which contains all paths and schemas merged into one file.
|
|
|
|
|
|
|
|
|
|
This file (api-docs.yaml) contains schema references and is meant for development.
|
|
|
|
|
The paths are defined in separate files in the `paths/` directory.
|
2026-01-28 17:31:00 +07:00
|
|
|
version: 1.0.0
|
|
|
|
|
contact:
|
|
|
|
|
name: CLQMS API Support
|
|
|
|
|
license:
|
|
|
|
|
name: Proprietary
|
|
|
|
|
|
|
|
|
|
servers:
|
|
|
|
|
- url: http://localhost/clqms01/
|
|
|
|
|
description: Local development server
|
|
|
|
|
- url: https://clqms01-api.services-summit.my.id/
|
|
|
|
|
description: Production server
|
|
|
|
|
|
|
|
|
|
tags:
|
|
|
|
|
- name: Authentication
|
|
|
|
|
description: User authentication and session management
|
|
|
|
|
- name: Patients
|
|
|
|
|
description: Patient registration and management
|
|
|
|
|
- name: Patient Visits
|
|
|
|
|
description: Patient visit/encounter management
|
|
|
|
|
- name: Organization
|
|
|
|
|
description: Organization structure (accounts, sites, disciplines, departments, workstations)
|
|
|
|
|
- name: Specimen
|
|
|
|
|
description: Specimen and container management
|
|
|
|
|
- name: Tests
|
|
|
|
|
description: Test definitions and test catalog
|
|
|
|
|
- name: Orders
|
|
|
|
|
description: Laboratory order management
|
|
|
|
|
- name: Results
|
|
|
|
|
description: Patient results reporting
|
|
|
|
|
- name: Edge API
|
|
|
|
|
description: Instrument integration endpoints
|
refactor(api-docs): Split Master Data into Contacts and Locations modules
- Split monolithic master-data.yaml into separate contact.yaml and locations.yaml files
- Replace 'Master Data' tag with dedicated 'Contacts' and 'Locations' tags for better API organization
- Add complete CRUD operations for Contacts (GET, POST, PATCH, DELETE, GET by ID)
- Add complete CRUD operations for Locations (GET, POST, PATCH, DELETE, GET by ID)
- Enhance Contact schema with comprehensive fields: NameFirst, NameLast, Title, Initial,
Birthdate, EmailAddress1/2, Phone, MobilePhone1/2, Specialty, SubSpecialty
- Enhance Location schema with additional fields: Description, LocType, improved Parent
field documentation for hierarchical locations
- Update bundled API documentation to reflect new endpoint structure
- Remove deprecated Occupation, MedicalSpecialty, and Counter schemas from bundled docs
2026-02-18 08:45:54 +07:00
|
|
|
- name: Contacts
|
|
|
|
|
description: Contact management (doctors, practitioners, etc.)
|
|
|
|
|
- name: Locations
|
|
|
|
|
description: Location management (rooms, wards, buildings)
|
2026-01-28 17:31:00 +07:00
|
|
|
- name: ValueSets
|
|
|
|
|
description: Value set definitions and items
|
|
|
|
|
- name: Demo
|
|
|
|
|
description: Demo/test endpoints (no authentication)
|
2026-02-24 16:53:36 +07:00
|
|
|
- name: EquipmentList
|
|
|
|
|
description: Laboratory equipment and instrument management
|
2026-01-28 17:31:00 +07:00
|
|
|
|
|
|
|
|
components:
|
|
|
|
|
securitySchemes:
|
|
|
|
|
bearerAuth:
|
|
|
|
|
type: http
|
|
|
|
|
scheme: bearer
|
|
|
|
|
bearerFormat: JWT
|
|
|
|
|
description: JWT token from login endpoint
|
|
|
|
|
cookieAuth:
|
|
|
|
|
type: apiKey
|
|
|
|
|
in: cookie
|
|
|
|
|
name: token
|
|
|
|
|
description: JWT token stored in HTTP-only cookie
|
|
|
|
|
|
|
|
|
|
schemas:
|
2026-02-16 14:20:52 +07:00
|
|
|
# Common schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
SuccessResponse:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/common.yaml#/SuccessResponse'
|
2026-01-28 17:31:00 +07:00
|
|
|
ErrorResponse:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/common.yaml#/ErrorResponse'
|
|
|
|
|
DashboardSummary:
|
|
|
|
|
$ref: './components/schemas/common.yaml#/DashboardSummary'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Authentication schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
LoginRequest:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/authentication.yaml#/LoginRequest'
|
2026-01-28 17:31:00 +07:00
|
|
|
LoginResponse:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/authentication.yaml#/LoginResponse'
|
2026-01-28 17:31:00 +07:00
|
|
|
RegisterRequest:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/authentication.yaml#/RegisterRequest'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Patient schemas
|
|
|
|
|
Patient:
|
|
|
|
|
$ref: './components/schemas/patient.yaml#/Patient'
|
2026-01-28 17:31:00 +07:00
|
|
|
PatientIdentifier:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient.yaml#/PatientIdentifier'
|
feat(patient): handle array format for Custodian and LinkTo fields
- PatientModel: Convert Custodian from array to integer InternalPID when received as object
- PatientModel: Convert LinkTo from array of objects to comma-separated InternalPID string
- API docs: Add LinkedPatient, Custodian, and PatAttEntry schema definitions
- API docs: Extend Patient schema with DeathIndicator, TimeOfDeath, PatCom,
PatAtt, Province, City, Country, Race, MaritalStatus, Religion, Ethnic fields
- Add AGENTS.md to .gitignore
2026-01-29 11:21:34 +07:00
|
|
|
LinkedPatient:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient.yaml#/LinkedPatient'
|
feat(patient): handle array format for Custodian and LinkTo fields
- PatientModel: Convert Custodian from array to integer InternalPID when received as object
- PatientModel: Convert LinkTo from array of objects to comma-separated InternalPID string
- API docs: Add LinkedPatient, Custodian, and PatAttEntry schema definitions
- API docs: Extend Patient schema with DeathIndicator, TimeOfDeath, PatCom,
PatAtt, Province, City, Country, Race, MaritalStatus, Religion, Ethnic fields
- Add AGENTS.md to .gitignore
2026-01-29 11:21:34 +07:00
|
|
|
Custodian:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient.yaml#/Custodian'
|
feat(patient): handle array format for Custodian and LinkTo fields
- PatientModel: Convert Custodian from array to integer InternalPID when received as object
- PatientModel: Convert LinkTo from array of objects to comma-separated InternalPID string
- API docs: Add LinkedPatient, Custodian, and PatAttEntry schema definitions
- API docs: Extend Patient schema with DeathIndicator, TimeOfDeath, PatCom,
PatAtt, Province, City, Country, Race, MaritalStatus, Religion, Ethnic fields
- Add AGENTS.md to .gitignore
2026-01-29 11:21:34 +07:00
|
|
|
PatAttEntry:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient.yaml#/PatAttEntry'
|
2026-01-28 17:31:00 +07:00
|
|
|
PatientListResponse:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient.yaml#/PatientListResponse'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Patient Visit schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
PatientVisit:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient-visit.yaml#/PatientVisit'
|
2026-02-10 15:37:12 +07:00
|
|
|
PatVisitADT:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/patient-visit.yaml#/PatVisitADT'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Organization schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
Account:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/organization.yaml#/Account'
|
2026-01-28 17:31:00 +07:00
|
|
|
Site:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/organization.yaml#/Site'
|
2026-01-28 17:31:00 +07:00
|
|
|
Discipline:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/organization.yaml#/Discipline'
|
2026-01-28 17:31:00 +07:00
|
|
|
Department:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/organization.yaml#/Department'
|
2026-01-28 17:31:00 +07:00
|
|
|
Workstation:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/organization.yaml#/Workstation'
|
2026-02-27 16:31:55 +07:00
|
|
|
HostApp:
|
|
|
|
|
$ref: './components/schemas/organization.yaml#/HostApp'
|
|
|
|
|
HostComPara:
|
|
|
|
|
$ref: './components/schemas/organization.yaml#/HostComPara'
|
|
|
|
|
CodingSys:
|
|
|
|
|
$ref: './components/schemas/organization.yaml#/CodingSys'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Specimen schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
Specimen:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/specimen.yaml#/Specimen'
|
2026-01-28 17:31:00 +07:00
|
|
|
ContainerDef:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/specimen.yaml#/ContainerDef'
|
2026-01-28 17:31:00 +07:00
|
|
|
SpecimenPrep:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/specimen.yaml#/SpecimenPrep'
|
2026-01-28 17:31:00 +07:00
|
|
|
SpecimenStatus:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/specimen.yaml#/SpecimenStatus'
|
2026-01-28 17:31:00 +07:00
|
|
|
SpecimenCollection:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/specimen.yaml#/SpecimenCollection'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Tests schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
TestDefinition:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/tests.yaml#/TestDefinition'
|
2026-01-28 17:31:00 +07:00
|
|
|
TestMap:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/tests.yaml#/TestMap'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Orders schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
OrderTest:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/orders.yaml#/OrderTest'
|
2026-01-28 17:31:00 +07:00
|
|
|
OrderItem:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/orders.yaml#/OrderItem'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Edge API schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
EdgeResultRequest:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/edge-api.yaml#/EdgeResultRequest'
|
2026-01-28 17:31:00 +07:00
|
|
|
EdgeResultResponse:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/edge-api.yaml#/EdgeResultResponse'
|
2026-01-28 17:31:00 +07:00
|
|
|
EdgeOrder:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/edge-api.yaml#/EdgeOrder'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# ValueSets schemas
|
2026-02-13 06:35:05 +07:00
|
|
|
ValueSetLibItem:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/valuesets.yaml#/ValueSetLibItem'
|
2026-01-28 17:31:00 +07:00
|
|
|
ValueSetDef:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/valuesets.yaml#/ValueSetDef'
|
2026-01-28 17:31:00 +07:00
|
|
|
ValueSetItem:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/valuesets.yaml#/ValueSetItem'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
refactor(api-docs): Split Master Data into Contacts and Locations modules
- Split monolithic master-data.yaml into separate contact.yaml and locations.yaml files
- Replace 'Master Data' tag with dedicated 'Contacts' and 'Locations' tags for better API organization
- Add complete CRUD operations for Contacts (GET, POST, PATCH, DELETE, GET by ID)
- Add complete CRUD operations for Locations (GET, POST, PATCH, DELETE, GET by ID)
- Enhance Contact schema with comprehensive fields: NameFirst, NameLast, Title, Initial,
Birthdate, EmailAddress1/2, Phone, MobilePhone1/2, Specialty, SubSpecialty
- Enhance Location schema with additional fields: Description, LocType, improved Parent
field documentation for hierarchical locations
- Update bundled API documentation to reflect new endpoint structure
- Remove deprecated Occupation, MedicalSpecialty, and Counter schemas from bundled docs
2026-02-18 08:45:54 +07:00
|
|
|
# Locations schemas
|
2026-01-28 17:31:00 +07:00
|
|
|
Location:
|
2026-02-16 14:20:52 +07:00
|
|
|
$ref: './components/schemas/master-data.yaml#/Location'
|
2026-01-28 17:31:00 +07:00
|
|
|
|
2026-02-24 16:53:36 +07:00
|
|
|
# EquipmentList schemas
|
|
|
|
|
EquipmentList:
|
|
|
|
|
$ref: './components/schemas/equipmentlist.yaml#/EquipmentList'
|
|
|
|
|
|
2026-02-16 14:20:52 +07:00
|
|
|
# Paths are in separate files in the paths/ directory
|
|
|
|
|
# To view the complete API with all paths, use: api-docs.bundled.yaml
|
|
|
|
|
# To rebuild the bundle after changes: python bundle-api-docs.py
|
|
|
|
|
paths: {}
|