Mandrill- Attachments not sending attachment -
I am trying to send a small RTF attachment through Mandril. I made the following Jason and the API test page Have tried to use. The attachment base 64 is encoded API does not tell an error and comes via email, but with no attachment. What am I doing wrong
{ "attachments": [{ "type": "application / rtf", "name": "test.rtf", "content": "e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZGVmZjBcZGVmbGFuZzIwNTd7XGZvbnR0Ymx7XGYwXGZuaWxcZmNoYXJzZXQwIENhbGlicmk7fX0NCntcKlxnZW5lcmF0b3IgTXNmdGVkaXQgNS40MS4yMS4yNTEwO31cdmlld2tpbmQ0XHVjMVxwYXJkXHNhMjAwXHNsMjc2XHNsbXVsdDFcbGFuZzlcZjBcZnMyMiB0aGlzIGlzIGEgdGVzdCBzZW5kaW5nIGZpbGVccGFyDQp9DQoA" } "," Message ": {" html ":" & lt; Html & gt; \ R \ n & lt; Body & gt; Exam data & lt; / Body & gt; \ R \ n & lt; / Html & gt; "", "" "," "", "" "," "" "," "," Name ":" "," "", "", "", "from_email": " Jklovanc@hotmail.com "," preserve_recipients ": true," text "e-mail": "jklovanc@hotmail.com"}], "to_name": "", "header": {"to answer": "Jklovanc@hotmail.com"}}, "key": # mykey #, "Async": false }
The message object is part of the attachment, so the attachment parameter should be nested instead of the message at the same level instead, should look like this:
< Code> {"message": {"attachments": [{"type": "application / rtf", "name": "test.rtf", "content": "e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZGV mZjBcZGVmbGFuZzIwNTd7XGZvbnR0Ymx7XGYwXGZuaWxcZmNoYXJzZXQwIENhbGlicmk7fX0NCntcKlxnZW5lcmF0b3IgTXNmdGVkaXQgNS40MS4yMS4yNTEwO31cdmlld2tpbmQ0XHVjMVxwYXJkXHNhMjAwXHNsMjc2XHNsbXVsdDFcbGFuZzlcZjBcZnMyMiB0aGlzIGlzIGEgdGVzdCBzZW5kaW5nIGZpbGVccGFyDQp9DQoA "}]," html ":" & LT; html & gt; \ r \ n & LT; Body & gt; test data & lt; / body & gt; \ R \ n & lt; / Html & gt; \ R \ n ", ....
Comments
Post a Comment