ЕСОЗ - публічна документація
RС_[NEW] (GraphQl) Search Device registry Jobs_EN
Purpose
This WS allows to find Device registry Jobs in Admin panel using search params.
Key points
This is a graphQl query method used in Administration panel only
Only authenticated and authorized NHS employee with appropriate scope can search Device registry Jobs
Query returns a list of Device registry Jobs filtered by search params
Specification
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 scopes in order to perform this action (scope = 'device_registry_job:read')
return 403 (“Your scope does not allow to access this resource. Missing allowances: device_registry_job:read”) in case of invalid scope(s)
Validate legal entity
Extract client_id from token.
Check legal entity status (status = ACTIVE)
In case of error - return 409 ('client_id refers to legal entity that is not active')
Check client type (type = NHS)
In case of error - return 403 ('You don't have permission to access this resource')
Service logic
Get list of all Device registry Jobs from jobs table in JABBA DB, filtered by:
device registry job types (jabba.jobs.type):
upload_device_definitions_registry
submitted additional search params
status. Search by jobs.status
Apply optional ordering
by default order records by inserted_at field in descending order
Render a response according to specification
ЕСОЗ - публічна документація