Query peos
| /peo/peos/query Get lost of PEO tids by allowed criteria. |
Allows to get peos tids by:
-
By modification date (from/until)
-
By project tid
-
By peos names
| When project tid is set the peos linked to child projects are exported as well by default. withChildren boolean parameter is responsible for this functionality. By default, this parameters value is true. |
Tip: Request can be performed by one parameter or by many at once. Criteria combined with AND operator.
Resource path |
/api/core/v1/peo/peos/query |
HTTP method |
POST |
Request content type |
application/json; |
Response content type |
application/json; |
Body parameters
Accepts PeoQuery
Return Type
Filled with peos tids PeoRequest
Responses
| Code | Message | Datatype |
|---|---|---|
200 |
Found products tids |
|
400 |
Invalid input provided |
|
401 |
Not authorized |
|
404 |
Not found |
|
500 |
An unknown internal error occurred |
Samples
Query by product tid, modified date interval, peo names and project tid with child projects peos
curl
curl --location 'http://<OMN_SERVER>/api/core/v1/peo/peos/query' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data '{
"tidProduct": "ec98dde6-4064-465d-a1fb-237e2f10a336",
"modifiedFrom": "2018-02-25T01:00:00.000",
"modifiedUntil": "2023-02-24T01:00:00.000",
"names": ["PEO name", "PEO other name"],
"tidProject": "t0t8de6-9874-46a1-f11t-ec98dde6"
}'
Request body
{
"tidProduct": "ec98dde6-4064-465d-a1fb-237e2f10a336",
"modifiedFrom": "2018-02-25T01:00:00.000",
"modifiedUntil": "2023-02-24T01:00:00.000",
"names": ["PEO name", "PEO other name"],
"tidProject": "t0t8de6-9874-46a1-f11t-ec98dde6"
}
Response body
{
"tids": [
"55beafb6-a80b-48ab-8a7b-9e1a98d67b24",
"38b42b94-ffca-445c-b395-fa6ee612cbb3",
"8d4e6770-67d2-49db-874c-bf4d5dfa315b"
]
}
Query by product tid, modified date interval, peo names and project tid without child projects peos
curl
curl --location 'http://<OMN_SERVER>/api/core/v1/peo/peos/query' \
--header 'Authorization: Bearer <TOKEN>' \
--header 'Content-Type: application/json' \
--data '{
"tidProduct": "ec98dde6-4064-465d-a1fb-237e2f10a336",
"modifiedFrom": "2018-02-25T01:00:00.000",
"modifiedUntil": "2023-02-24T01:00:00.000",
"names": ["PEO name", "PEO other name"],
"tidProject": "t0t8de6-9874-46a1-f11t-ec98dde6",
"withChildren": false
}'
Request body
{
"tidProduct": "ec98dde6-4064-465d-a1fb-237e2f10a336",
"modifiedFrom": "2018-02-25T01:00:00.000",
"modifiedUntil": "2023-02-24T01:00:00.000",
"names": ["PEO name", "PEO other name"],
"tidProject": "t0t8de6-9874-46a1-f11t-ec98dde6",
"withChildren": false
}
Response body
{
"tids": [
"55beafb6-a80b-48ab-8a7b-9e1a98d67b24",
"38b42b94-ffca-445c-b395-fa6ee612cbb3"
]
}