Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Table of Contents

Purpose

This WS is designed to return Group of Diagnoses details.

...

  1. This is a REST method used by MIS.

  2. Authorization is not needed to get Group of Diagnoses details.

Specification

Page Properties

Link

https://ehealthmisapi1.docs.apiary.io/#reference/public.-groups-of-diagnoses/get-group-of-diagnoses-details/get-group-of-diagnoses-details

Посилання на Apiary або Swagger

Resource

/api/diagnoses_groups/{{id}}

Посилання на ресурс, наприклад: /api/persons/create

Scope

API paragraph not found

Scope для доступу

Components

Medical events

Зазначається перелік бізнес компонентів, які використовують цей метод, наприклад: ePrescription

Microservices

API paragraph not found

Перелік мікросервісів, які використовує метод API, наприклад: Auth, ABAC

Protocol type

REST

Тип протоколу, який використовується запитом, наприклад: SOAP | REST

Request type

GET

Тип запиту API, наприклад: GET, POST, PATCH…

Sync/Async

Async

Метод є синхронним чи асинхронним?

Public/Private/Internal

Public

Потрібно зазначити тип методу за ступенем доступності

Logic

  1. Get data from prm DB:

    1. diagnoses_groups by id

    2. diagnoses_group_codes by diagnoses_group_id

  2. Render a response according to specification.

Input parameters

Input parameter

Values

Type

Description

Example

Id

String

Group of Diagnoses identifier.

Required

b075f148-7f93-4fc2-b2ec-2d81b19a9b7b

Authorize

Is not needed

Headers

Content-Type:application/json

Request data validation

Validate Group of Diagnoses

  1. Check that Group of Diagnoses with such ID exists in the system (is_active = true)

    1. In case of error - return 404 "Group of Diagnoses not found"

Search params

  • Group of Diagnoses id

Service logic

  1. Get data from prm DB:

    1. diagnoses_groups by id

    2. diagnoses_group_codes by diagnoses_group_id

  2. Render a response according to specification.

Response structure

Example:

Expand
titleResponse example
Code Block
{
  "meta": {
    "code": 200,
    "url": "https://example.com/resource",
    "type": "object",
    "request_id": "6617aeec-15e2-4d6f-b9bd-53559c358f97#17810"
  },
  "data": [
    {
      "id": "f7f817b2-3134-4625-b87d-e2d7fc8e9b90",
      "name": "Some name",
      "code": "H00",
      "description": "Some description"
    }
  ],
  "paging": {
    "page_number": 2,
    "page_size": 50,
    "total_entries": 1000,
    "total_pages": 23
  }
}

HTTP status codes

Page Properties

HTTP status code

Message

What caused the error

 200

 Response

 

 404

 Group of Diagnoses not found