candidates
Sends candidate data to the module, creates a candidate record in the system, and
creates a survey. You can send an individual candidate, or an array of candidates. Input is
JSON format.
Single Candidate
Creates a single candidate record.
POST: /api/v1/candidates
Field | Type | Required | Description |
---|---|---|---|
candidateSource | string | Yes | |
clientKey | string | Yes | Single word value, case sensitive. For example, 'FRW_01_TGTE'. |
countryCode | string | Yes | Two character country code. For example, 'US'. |
sourceCandidateId | string | Yes | Alpha numeric value, case sensitive. |
firstName | string | Yes | |
lastName | string | Yes | |
string | Yes | ||
phone | string | No | |
supplierName | string | No | |
directSourcePro | boolean | No. Default value is false. | If set to 'true', uses DSPRO settings for email and survey page. |
returnSurveyLink | boolean | No. Default value is false. | Returns link to survey before notification is sent to the candidate. |
Multiple Candidates
Creates multiple candidate records from array of data.
PUT: /api/v1/candidates
Field | Type | Required | Description |
---|---|---|---|
candidateSource | string | Yes | |
clientKey | string | Yes | Single word value, case sensitive. For example, 'FRW_01_TGTE'. |
countryCode | string | Yes | Two character country code. For example, 'US'. |
sourceCandidateId | string | Yes | Alpha numeric value, case sensitive. |
firstName | string | Yes | |
lastName | string | Yes | |
string | Yes | ||
phone | string | No | |
supplierName | string | No | |
directSourcePro | boolean | No. Default value is false. | If set to 'true', uses DSPRO settings for email and survey page. |
returnSurveyLink | boolean | No. Default value is false. | Returns link to survey before notification is sent to the candidate. |
Examples
Single Candidate POST
curl --location --request POST 'http://<url>/diversity/api/v1/candidates' \
--header 'Authorization: ApiKey <api_key>' \
--header 'Content-Type: application/json' \
--data-raw '{
"candidateSource": "WFQ",
"clientKey": "WFQ_CLIENT_KEY_01",
"countryCode": "US",
"sourceCandidateId": "10001",
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]",
"sourceCandidateId": "10001",
"supplierName": "Abc Management",
"returnSurveyLink": "true"
}'
RESPONSE:
{
"sourceCandidateId": "10001",
"shortUrl": "https://bit.ly/3bU2iiG",
"statusText": "Candidate#2810102 has been created for the Source
Candidate#10001",
"status": "Success"
}
Multiple Candiate PUT
curl --location --request PUT 'http://<url>/diversity/api/v1/candidates' \
--header 'Authorization: ApiKey <api_key>' \
--header 'Content-Type: application/json' \
--data-raw '[
{
"candidateSource": "WFQ",
"clientKey": "WFQ_CLIENT_KEY_01",
"countryCode": "US",
"sourceCandidateId": "10011",
"firstName": "John1",
"lastName": "Doe",
"email": "[email protected]",
"supplierName": "Abc Management"
}, {
"sourceCandidateId": "10001",
"shortUrl": "https://bit.ly/3bU2iiG",
"candidateSource": "WFQ",
"clientKey": "WFQ_CLIENT_KEY_01",
"countryCode": "US",
"sourceCandidateId": "10012",
"firstName": "John2",
"lastName": "Doe",
"email": "[email protected]",
"supplierName": "Abc Management"
} ]'
Response
[
{
"sourceCandidateId": "10011",
"statusText": "Candidate#2810105 has been created for the Source Candidate#10011",
"status": "Success"
},
{
'sourceCandiateId": "10012",
"statusText": "Candidate#2810108 has been created for the SourceCandidate#10012",
"status": "Success"
}
]