Request

All your candidates can be retrieved by GET request to 

https://<your_traffit_subdomain>.traffit.com/public/an/list/

By default, this request is public, which means it does not require an authorization.

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/'
 
However, we can change it at the request of customer to require the authorization.
After that you will need to have a grant access token with public_advert_list scope.

The client name connected to the recruitment is added to response when the endpoint is secured by authorization.

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/' \
-H 'Authorization: Bearer <your_token>' 

Parameters:

You can use parameters in query to limit, offset , filter and sort publications:

limit
Defines how many records will be returned at most

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/?limit=10' 

offset
Offset is the position in the dataset of a particular record. By specifying offset, you retrieve a subset of records starting with the offset.

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/?offset=10' 

language
Filter records by language value. (two-letter ISO code)

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/?language=en'

awarded
Filter publications by highlighted / not highlighted.  Accepts values 1 and 0.

Example cURL request:
curl -X GET 'https://<your_traffit_subdomain>.traffit.com/public/an/list/?awarded=1' 

Response 

Example response: (additionally we returns all recruitment custom fields)
(In this response we use "x_work_time" as example custom field")

{

    "count": 1,

    "items": [

        {

            "advertPublishId": 8155,

            "nrRef": "/1/11/2018/MC",

            "recruitmentId": 201373,

            "advertId": 52783,

            "url": "https://<your_traffit_domain>.traffit.com/public/an/QjcxRU0yUT0=",

            "awarded": null,

            "validStart": 1582533000,

            "title": "Advert",

            "applicationForm": "https://<your_traffit_domain>.traffit.com/public/form/a/52783",

            "region": "Poland",

            "sector": "Research and development",

            "jobType": null,

            "contactPerson": "Mark Smith",

            "confidential": 0,

            "language": "en",

            "advertTemplate": null,

            "name": "Test",

            "headerPhoto": null,

            "companyId": 1509,

            "recruitmentImage": null,

            "status": "New",

            "contactPerson.desc": "Contact Person description",

            "branches": "Research and development",

            "regions": "Poland",

            "description": "<p>Advert description</p>",

            "geolocation": "{\"latitude\":\"52.235840\",\"longitude\":\"21.011959\",\"iso\":\"pl\",\"locality\":\"Warszawa\",\"region1\":\"Mazowieckie\",\"region2\":\"Warszawa\",\"region3\":\"Warszawa\",\"postcode\":\"00-002\",\"country\":\"Polska\"}",

            "location": null,

            "client": "Client name",
            "x_work_time":"custom_field_system_value",
            "x_work_time.desc":"custom_field_name",
            "x_work_time.translate":"custom_field_value"
        }

    ]

}


Description of response parameters:

{

    "count": "Number of records returned",

    "items": [

        {

            "advertPublishId": "Publication ID",

            "nrRef": "Reference number of the recruitment",

            "recruitmentId": "Recruitment ID",

            "advertId": "Advert ID",

            "url": "Advert URL",

            "awarded": "Is publication highlighted",

            "validStart": "Publication date ",

            "title": "Recruitment title",

            "applicationForm": "Application form URL",

            "region": "Recruitment region field",

            "sector": "Recruitment sector field",

            "jobType": "Recruitment type field",

            "contactPerson": "Contact person assigned to the recruitment",

            "confidential": "Information is recruitment confidential",

            "language": "Language iso two-letter code",

            "advertTemplate": "Advert template ID",

            "name": "Advert title",

            "headerPhoto": "Advert image",

            "companyId": "Client ID ,

            "recruitmentImage": "URL to recruitment image",

            "status": "Recruitment status",

            "contactPerson.desc": "Contact person description",

            "branches": "Recruitment sector field",

            "regions": "Recruitment region field",

            "description": "Advert description",

            "geolocation": "Geolocation object - job location",

            "location": "Location string - job location (used for older publications)",

            "client": "Client name. Added only if endpoint needs an authorization",
            "x_work_time":"custom_field_system_value",
            "x_work_time.desc":"custom_field_name",
            "x_work_time.translate":"custom_field_value"
        }

    ]
}

Did this answer your question?