Receives a list of workers vinculated with the Client. (client_id will be obtained through the authentication token) matching criteria.
This endpoint can be filtered by worker status. If no query param is sent, it will return all workers by default.
The query param to filter between status is called “statusId”, and it goes in integers from 0 to 3, being the next relation:

Status IDEquivalent value
0ACTIVE
1INVITATION_SENT
2VERIFICATION_PENDING
3ENDED
curl --location 'https://api.demo.getontop.com/contract/workers/list' \
--header 'Authorization: Bearer ' \
--header 'Cookie: JSESSIONID='
{
    "content": [
        {
            "agreementId": 15,
            "firstName": null,
            "lastName": null,
            "legalName": null,
            "email": "[email protected]",
            "jobTitle": "Software Engineer",
            "country": null,
            "externalId": null,
            "workerCreationDate": "2023-09-29T22:33:34.377+00:00",
            "status": "INVITATION_SENT"
        },
        {
            "agreementId": 16,
            "firstName": "Juan",
            "lastName": "Perez",
            "legalName": null,
            "email": "[email protected]",
            "jobTitle": "Ingeniero de Software",
            "country": "Argentina",
            "externalId": "SFK005",
            "workerCreationDate": "2023-09-21T14:42:38.793+00:00",
            "status": "ACTIVE"
        }
    ],
    "pageable": {
        "sort": {
            "empty": true,
            "sorted": false,
            "unsorted": true
        },
        "offset": 0,
        "pageNumber": 0,
        "pageSize": 20,
        "paged": true,
        "unpaged": false
    },
    "last": true,
    "totalPages": 1,
    "totalElements": 2,
    "number": 0,
    "sort": {
        "empty": true,
        "sorted": false,
        "unsorted": true
    },
    "size": 20,
    "first": true,
    "numberOfElements": 2,
    "empty": false
}

Example cURL Filtered by ACTIVE status:

curl --location 'https://api.demo.getontop.com/contract/workers/list?statusId=0' \
--header 'Authorization: Bearer'\
  --header 'Cookie: JSESSIONID='
{
    "content": [
        {
            "agreementId": 16,
            "firstName": "Juan",
            "lastName": "Perez",
            "legalName": null,
            "email": "[email protected]",
            "jobTitle": "Ingeniero de Software",
            "country": "Argentina",
            "externalId": "SFK005",
            "workerCreationDate": "2023-09-21T14:42:38.793+00:00",
            "status": "ACTIVE"
        }
    ],
    "pageable": {
        "sort": {
            "empty": true,
            "sorted": false,
            "unsorted": true
        },
        "offset": 0,
        "pageNumber": 0,
        "pageSize": 20,
        "paged": true,
        "unpaged": false
    },
    "last": true,
    "totalPages": 1,
    "totalElements": 1,
    "number": 0,
    "sort": {
        "empty": true,
        "sorted": false,
        "unsorted": true
    },
    "size": 20,
    "first": true,
    "numberOfElements": 2,
    "empty": false
}
Language
Credentials
Bearer
Click Try It! to start a request and see the response here!