5

I'm trying to send mail using mandrill from node js API.

I was successful in sending the following as long as I keep my 'downloadLink' free from 'dangerous' characters such as : '/' and '?'

the following get send but the 'link' is following to nowhere:

    var downloadLink =(encodeURIComponent('itms-services://c')
    var text  = [
        "We are excited to send you a version of our app",
        "You can download it here: <a href=\""+downloadLink+"\">link</a> thats it.",

    ].join('<br>')
    console.log(text)
    var message = {
        "html": text,
        "subject": "New App!",


        "from_email": "Hello@d.com",
        "from_name": "D Guys",
        "to": [{
                "email": mail,
                //"name": "Recipient Name",
                "type": "to"
            }],
        "headers": {
            "Reply-To": "message.reply@example.com"
        },
        "important": false,
        "track_opens": true,
        "track_clicks": true,
        "auto_text": null,
        "auto_html": false,
        "inline_css": null,
        "url_strip_qs": null,
        "preserve_recipients": null,
        "view_content_link": null,
        "tracking_domain": null,
        "signing_domain": null,
        "return_path_domain": null,
        "merge": true,
}

removeing '/' characters from the 'downloadLink' does work.

skme
  • 731
  • 6
  • 24

0 Answers0