Skip to content

OutPatient

Syarif Ubaidillah edited this page Jul 12, 2022 · 2 revisions

OutPatient

Setiap fitur yang memiliki header Authorization berarti harus login untuk mendapatkan access_token dan refresh_token.

Setiap fitur yang memiliki Query Param dapat digunakan seperti ini /api/example?paramA=12&paramB=331.

Create

Fitur terbatas pada role Administrator

Method Path
POST /api/outpatient
Header Value
Content-Type application/json
Authorization Bearer <access_token>
Request Body
{
	"patient_code": "RM00001",
	"complaint": "sakit perut",
	"date_check": "2022-06-24",
	"facility_id": 1,
	"session_id": 1
	"doctor_code": "DR00002",
}
Response Body
{
	"message": "Medic Record Created",
}

FindAll

Method Path
GET /api/outpatient
Header Value
Authorization Bearer <access_token>
Query Param Data Type Format
date_start String yyyy-mm-dd
date_end String yyyy-mm-dd
Response Body
{
	"data": [
		{
			"id": 1,
			"serial_number": "RM/748/2022/001",
			"patient_code": "RM0001",
			"full_name": "Faizur Ramadhan",
			"complaint": "sakit perut",
			"date_check": "2022-06-22",
			"doctor": "Alsyad Ahmad",
			"nurse": "Priscilla Halim",
			"session": "08:00",
			"queue": 1
		}
	],
	"message": "Medic Record Fetched"
}

FindByID

Method Path
GET /api/outpatient/{id}
Header Value
Authorization Bearer <access_token>
Response Body
{
	"data": {
		"id": 1,
		"serial_number": "RM/748/2022/001",
		"patient_code": "RM0001",
		"full_name": "Faizur Ramadhan",
		"complaint": "sakit perut",
		"date_check": "2022-06-22",
		"doctor": "Alsyad Ahmad",
		"session": "08:00",
		"queue": 1,
		"medic_check": {
			"blood_tension": 120,
			"height": 50,
			"weight": 150,
			"body_temp": 35,
			"nurse": "Priscilla Halim"
		}
	},
	"message": "Medic Record Fetched"
}

Process

Fitur terbatas pada role Dokter dan Perawat

Method Path
POST /api/outpatient/{id}/process
Header Value
Content-Type application/json
Authorization Bearer <access_token>
Request Body
  • Dokter
     {
     	"diagnose": "Migrain",
     	"prescription": "Mixagrip Migrain",
     }
  • Perawat
     {
     	"body_temp": 36,
     	"weight": 55,
     	"height": 165,
     	"blood_tension": 122,
     }
Response Body
{
	"message": "Medic Record Processed"
}

Report Log

Fitur terbatas pada role Dokter dan Perawat

Method Path
GET /api/outpatient/log
Header Value
Authorization Bearer <access_token>
Response Body
{
	"message": "Log Fetched"
	"data": [
		{
			"serial_number": "RM/754/22/0001"
		}
	]
}

Report Log

Fitur terbatas pada role Administrator

Method Path
GET /api/outpatient/report
Header Value
Authorization Bearer <access_token>
Response Body
{
	"data": [
		{
			"id": 1,
			"serial_number": "RM/748/2022/001",
			"code": "RM0001",
			"full_name": "Faizur Ramadhan",
			"complaint": "sakit perut",
			"date_check": "2022-06-22",
			"doctor": "Alsyad Ahmad",
			"session": "08:00",
			"queue": 1
		}
	],
	"message": "Report Fetched"
}

Clone this wiki locally