Transaction methods
GET
transaction/categorizedtask (send)
This method is to send transaction email.
Request url
https://euapi.sendigo.com/transaction/categorizedtask
Simple transaction:
Request body
appId: xxxxxxxxxxxxxxxxxxxxxxxxxx

data:
{
"categories": ["example"],
"baseData": {
"bodyHtml": "Example",
"bodyPlain": null,
"templateSlug": null,
"templateData": [],
"from": "[email protected]",
"fromTitle": null,
"subject": "example",
"replyTo": null,
"replyToTitle": null,
"utmSource": null,
"utmCampaign": null
}
,
"attachments": null,
"recipients": [{
"to": "[email protected]",
"replacements": {},
"attachments": null
}]
,
"metadata": "value"
}
Template:
Request body
appId: xxxxxxxxxxxxxxxxxxxxxxxxxx

data:
{
"categories": ["example"],
"baseData": {
"bodyHtml": null,
"bodyPlain": null,
"templateSlug": "template-xxxxxxxxxxx",
"templateData": [],
"from": "[email protected]",
"fromTitle": null,
"subject": "example",
"replyTo": null,
"replyToTitle": null,
"utmSource": null,
"utmCampaign": null
}
,
"attachments": null,
"recipients": [{
"to": "[email protected]",
"replacements": {},
"attachments": null
}]

}
With replacements:
Request body
appId: xxxxxxxxxxxxxxxxxxxxxxxxxx

data:
{
"categories": ["example"],
"baseData": {
"bodyHtml": "Example replacement %R#replacement#R%",
"bodyPlain": null,
"templateSlug": null,
"templateData": [],
"from": "[email protected]",
"fromTitle": null,
"subject": "example",
"replyTo": null,
"replyToTitle": null,
"utmSource": null,
"utmCampaign": null
}
,
"attachments": null,
"recipients": [{
"to": "[email protected]",
"replacements":
{ "replacement": "example"
}
,
"attachments": null
}]

}
With attachments:
Request body
appId: xxxxxxxxxxxxxxxxxxxxxxxxxx

data:
{
"categories": ["example"],
"baseData": {
"bodyHtml": "Example",
"bodyPlain": null,
"templateSlug": null,
"templateData": [],
"from": "[email protected]",
"fromTitle": null,
"subject": "example",
"replyTo": null,
"replyToTitle": null,
"utmSource": null,
"utmCampaign": null
}
,
"attachments": [{
"name": "myfile.txt",
"data": "ZXhhbXBsZSBmaWxl",
"mime": "text\/plain"
}],
,
"recipients": [{
"to": "[email protected]",
"replacements": {},
"attachments": null
}]

}
Method Description
setBodyHtml Required Html text of transaction email
setFrom Required Email address from which is sent
setSubject Required Subject of marketing email
addRecipients Required Recipient model that contains parameters setTo(email) , addReplacement($field, $data)($field is replacement name, $data is a replacement value) and addMetadata ($field, $data)($field is key value, $data metadata value)
setCategories Required Array of strings with task categories
setBodyPlain Optional Plain text of marketing email
setFromTitle Optional Name of email address from which is sent
setReplyTo Optional Email address where to replay
setReplyToTitle Optional Name of email address where to replay
attachments Optional Attachment of marketing email
setTemplateSlug() Optional Identificator of template
metadata Optional String that contains metadata