Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This WS allows to get a list of Service Requests referenced on or referenced by the Specimen resource directly when the diagnostic investigation is requested.

Specification

Link

 Apiary

Resource

api/specimens/specimen_id/service_requests

Scope

service_request:read_impersonal

_read

Components

 service request

Microservices

 

Protocol type

 REST

Request type

 Get

Sync/Async

 Sync

Public/Private/Internal

 Public

Key points

  1. Only authenticated and authorized employee with appropriate scope can get a list of Specimen.

  2. Method returns a list of Service Requests referenced on or referenced by the specified Specimen

  3. Service requests can be additionally filtered by status.

  4. ABAC rules and forbidden group filtration are not used here.

  5. Service Request entities does not contain any information about a Patient, only its age and gender.

...

  • Get all Service Requests from service_requests collection (MongoDB) that includes the Specimen. Get even those containing forbidden elements.

  • Get all Service Requests from service_requests collection (MongoDB) that included in the Specimen. Get even those containing forbidden elements.

  • Additionally, filter the list of Service requests by submitted search params

  • Render a response according to specification with a list of found Service Request entities. Do not show info about the Patient identity, except age and gender.

Filters

Filter

Values

Type

Description

Example

specimen_id

String

Unique Specimen identifier

7075e0e2-6b57-47fd-aff7-324806efa7e5

status

 https://e-health-ua.atlassian.net/wiki/spaces/EH/pages/17629118869/RC.+Specimen+status+model#Statuses-of-Specimen

String

status of the Specimen

available

Dictionaries

https://e-health-ua.atlassian.net/wiki/spaces/EH/pages/17629119370/RC.+Specimen+dictionaries+and+configurable+parameters#Dictionaries

Request structure

See on Apiary

Authorization

  • Verify the validity of access token

    • in case of error - return 401 “Invalid access token” in case of validation fails

  • Verify that token is not expired

    • in case of error - return 401 “Invalid access token”

  • Check user and client scopes in order to perform this action (scope = 'service_request:read_impersonal')

    • return 403 “Your scope does not allow to access this resource. Missing allowances: service_request:read_impersonal” in case of invalid scope(s)

...

  • status

    • filter list by specimen.status

Response structure

See on Apiary

 

HTTP status codes

HTTP status code

Message

What caused the error

200

 

 

401

 Invalid access token

 

403

  • Your scope does not allow to access this resource. Missing allowances: service_request:read_impersonal