POST api/Candidates/Email
Used to send an email to one or more candidates
Request Information
URI Parameters
None.
Body Parameters
This is email request data
CandidateEmailMessageDTOName | Description | Type | Additional information |
---|---|---|---|
EmailTemplateID |
This is custom templateid id selected |
integer |
None. |
Subject |
This is custom subject line to use if not custom template was used |
string |
None. |
MessageBody |
This is custom email message to use if not custom template was used |
string |
None. |
CandidateIDs |
This is the list of candidateids to send the email to |
Collection of integer |
None. |
Attachments |
This is the list of attachments to include |
Collection of EmailAttachment |
None. |
Request Formats
application/json, text/json
Sample:
{ "EmailTemplateID": 1, "Subject": "sample string 2", "MessageBody": "sample string 3", "CandidateIDs": [ 1, 2 ], "Attachments": [ { "DocumentName": "sample string 1", "DocumentContent": "QEA=" }, { "DocumentName": "sample string 1", "DocumentContent": "QEA=" } ] }
text/xml
Sample:
<CandidateEmailMessageDTO xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO"> <Attachments> <EmailAttachment> <DocumentContent>QEA=</DocumentContent> <DocumentName>sample string 1</DocumentName> </EmailAttachment> <EmailAttachment> <DocumentContent>QEA=</DocumentContent> <DocumentName>sample string 1</DocumentName> </EmailAttachment> </Attachments> <CandidateIDs xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:int>1</d2p1:int> <d2p1:int>2</d2p1:int> </CandidateIDs> <EmailTemplateID>1</EmailTemplateID> <MessageBody>sample string 3</MessageBody> <Subject>sample string 2</Subject> </CandidateEmailMessageDTO>
multipart/form-data
Sample:
<CandidateEmailMessageDTO xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/RandstadWebAPI.Models.DTO"><Attachments><EmailAttachment><DocumentContent>QEA=</DocumentContent><DocumentName>sample string 1</DocumentName></EmailAttachment><EmailAttachment><DocumentContent>QEA=</DocumentContent><DocumentName>sample string 1</DocumentName></EmailAttachment></Attachments><CandidateIDs xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"><d2p1:int>1</d2p1:int><d2p1:int>2</d2p1:int></CandidateIDs><EmailTemplateID>1</EmailTemplateID><MessageBody>sample string 3</MessageBody><Subject>sample string 2</Subject></CandidateEmailMessageDTO>
application/x-www-form-urlencoded
Sample:
Sample not available.
Response Information
Resource Description
booleanResponse Formats
application/json, text/json
Sample:
true
text/xml, multipart/form-data
Sample:
<boolean xmlns="http://schemas.microsoft.com/2003/10/Serialization/">true</boolean>