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

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Status

Specification

DONE

Apiary

DONE

JSON Schema request

ABSENT

JSON Schema response
SPECS

Purpose

This WS is designed to return Program_medications list by filters.

APIary

Get Program medications list                                               

Input parameters (filters)

  • id (optional)
  • medical_program_id (optional)
  • medical_program_name (optional, as `LIKE *`)
  • innm_id (optional)
  • innm_name (optional, as `LIKE *`)
  • medication_id (optional)
  • medication_name (optional, as `LIKE *`)

Logic WS

  1. Verify the validity of access token
  2. Check user scopes in order to perform this action (scope = 'program_medications:read')
  3. Search Program_medications by filters and show:

    id (program_medications_id)

    medical_program_name

    medication_name
    form
    manufacturer 
    reimbursement_amount
    innm_name

    When filter by innm we show only medication where this innm in medication.dosage has is_active_substance=true.

Prepare & return response data structure

  1. Fill response WS data structure 
  2. Validate response using JSON schemas (!!! TBD)
    1. Return 422 with list of validation errors in case validation fails (422 EView) 
  • No labels