Specification
Apiary | |
JSON Schema response | SPECS |
Purpose
This WS is designed to return Substances list by filters.
Input parameters (filters)
- id (optional)
- sctid (optional)
- name (optional, as `LIKE *`)
- name_original (optional, as `LIKE *`)
Logic WS
- Verify the validity of access token
- Check user scopes in order to perform this action (scope = 'substance:read')
Search substances by filters in payload
SELECT * FROM substances S WHERE (S.id == $.id OR $.id IS NULL) AND (S.sctid == $.sctid OR $.sctid IS NULL) AND (S.name LIKE `%$.name%` OR $.name IS NULL) AND (S.name_original LIKE `%$.name_original%` OR $.name_original IS NULL)