ЕСОЗ - публічна документація

Create declaration (Internal method)

Purpose

Method to register new declaration record.

Specification

Link

https://uaehealthapi.docs.apiary.io/#reference/internal.-ops-db/declarations/create-declaration

Resource

 

Scope

 

Components

Declarations

Using Microservices

 

Protocol type

 

Request type

POST

Sync/Async

 

Public/Private/Internal

Internal

Logic

Input parameters

 

Input parameter

Values

Type

Description

Example

Input parameter

Values

Type

Description

Example

id

 

string

id of the signed document stored on the Media content storage

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

person_id

 

string

 

d290f1ee-6c54-4b01-90e6-d701748f0851

employee_id

 

string

 

d290f1ee-6c54-4b01-90e6-d701748f0851

division_id

 

string

 

`d290f1ee-6c54-4b01-90e6-d701748f0851`m

legal_entity_id

 

string

 

`d290f1ee-6c54-4b01-90e6-d701748f0851`m

scope

 

enum

 

 

start_date

 

string

 

2017-03-02

end_date

 

string

 

2017-03-02

signed_at

 

string

 

2017-03-02T10:45:16.000Z

Filters

Global and configuration parameters

Preconditions

Request structure

Example:

{ "person_id": "4d0d790c-cbf1-44f5-ab21-ba8db67da161", "employee_id": "1a8b10ea-ba09-40f2-8f9e-55608e9208c6", "division_id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "authorize_with": "cc949559-5dfe-420f-ac05-065e443b2cc6", "parent_declaration_id": "8c7753fc-a647-435f-8e43-4ff4546431f6" }

Authorize

 

Headers

  • Content-Type:application/json

Validate request

{ "id": "b075f148-7f93-4fc2-b2ec-2d81b19a9b7b", "person_id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "employee_id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "division_id": "`d290f1ee-6c54-4b01-90e6-d701748f0851`m", "legal_entity_id": "`d290f1ee-6c54-4b01-90e6-d701748f0851`m", "scope": "family_doctor", "start_date": "2017-03-02", "end_date": "2017-03-02", "signed_at": "2017-03-02T10:45:16.000Z" }

 

Request data validation

Processing

 

Response structure

 

{ "meta": { "code": 201, "url": "https://example.com/resource", "type": "object", "request_id": "6617aeec-15e2-4d6f-b9bd-53559c358f97#17810" }, "data": { "id": "b075f148-7f93-4fc2-b2ec-2d81b19a9b7b", "person_id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "employee_id": "d290f1ee-6c54-4b01-90e6-d701748f0851", "division_id": "`d290f1ee-6c54-4b01-90e6-d701748f0851`m", "legal_entity_id": "`d290f1ee-6c54-4b01-90e6-d701748f0851`m", "scope": "family_doctor", "start_date": "2017-03-02", "end_date": "2017-03-02", "signed_at": "2017-03-02T10:45:16.000Z", "inserted_at": "1991-08-19T00:00:00.000Z", "inserted_by": "userid", "updated_at": "1991-08-19T00:00:00.000Z", "updated_by": "userid" } }

 

Post-processing processes

HTTP status codes

HTTP status code

Message

What caused the error

HTTP status code

Message

What caused the error

201

 Response

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Backward compatibility

ЕСОЗ - публічна документація