Mailing links custom tracker
This extension allows for replacing links in Outreach outbound emails with links provided by your service. Links you provide is expected to eventually redirect to the original link. Outreach will call the registered URL of your service and provide a list of links from the email in the payload expecting to collect the list of equivalent links to be inserted back into the email.
Expect traffic!
Note that on busy customers the traffic rate may become high, thus you should ensure your service can handle that type of load. If your service becomes unavailable or fails to respond to the request the email will be sent with the set of original links and the operation will not be retried.
Only http://
and https://
links are offered for replacement (other links e.g. mailto://
are filtered out).
Request format
Before sending out the mailing Outreach will make a call to your service with the following payload:
{
"data": [
"https://bit.ly/33zYFqH",
"https://yhoo.it/35tPtX6"
],
"meta": {
"mailing": {
"id": "123"
},
"prospect": {
"email": "abc@prospect.com",
"id": "456"
},
"user": {
"email": "def@user.com",
"id": "789"
},
"urls": {
"https://www.google.com/": "https://bit.ly/33zYFqH",
"https://www.yahoo.com/": "https://yhoo.it/35tPtX6"
}
}
}
The urls
object in the example above contains URLs from the message that your extension may want to replace.
The keys of the urls
(google and yahoo) are the original links that the user has put into their email. The values (bit.ly)
are the result of a transformation by other extensions.
Every mailing links request will contain the Outreach-Webhook-Signature
header. Use this header to validate that the
request came from Outreach. The signature generation process is described in application lifecycle webhooks.
Also the shared secret used for mailing links extension is the same as for webhook requests.
Response format
Your extension is expected to respond with the following JSON:
{
"data" : {
"https://bit.ly/33zYFqH" : "https://example.com/aX2",
"https://yhoo.it/35tPtX6" : "https://example.com/fsr"
}
}
Note that you have to use the values from the urls
object as keys for your data
object. Outreach will only replace URLs that are mapped to valid HTTP(S) URLs; missing or invalid
URLs will be left untouched. Also note that it is not possible to determine the order that the extensions run in.