Versions Compared

Key

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

Table of Contents

...

  1. Verify the validity of access token
  2. Check user scopes declaration:terminate in order to perform this action
    1. In case error - generate 401 response

Validate request

One parameter of employee_id and person_id must be set. Also can be added the description field: reason_description.

Validate person

  1. Search person by $.id
    1. in case error return 404
  2. Search declaration by $.person_id
    1. in case error return 404
  3. Check declaration status = active
    1. in case error return 422. Message:"declaration status is not active"

...