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

Approve declaration

n/n
description
inputs
expected result GraphQlactual result GraphQl
TD1Approve declaration without scopes
  • token
missing allowance declaration:approvedeclaration:approve
TD2Approve declaration  by doctor 
  • doctor token
403401
TD3Approve declaration  by ID doesn't exist
  • token
  • invalid id 
not_found"code": "BAD_REQUEST",
"exception": "%{\"error\" => %{\"type\" => \"not_found\"}, \"meta\" => %{\"code\" => 404, \"request_id\" => \"86aceff7-7039-41d5-b6b4-161fdb77f360#15236\", \"type\" => \"object\", \"url\" => \"http://graphql-svc.il/declarations/0e4f17e9-182f-4594-9a83-3a5e6f54a086\"}}"
TD4Approve active declaration
  • token
CONFLICT invalid status

Incorrect status transition.

TD5Approve inactive declaration 
  • token
  • status - inactive
CONFLICT invalid statusIncorrect status transition.
TD6Approve pending verification declaration 
  • token
  • valid person id
200, status = `REJECTED`, reason = `manual_person`

200, ok

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