-
Notifications
You must be signed in to change notification settings - Fork 0
Cannot send json object #26
Comments
The mail enpdoint accepts any data, as long as it contains node-templater-mailer-microservice/api.js Line 148 in a71a240
Can you show me your templates and the data you send?
|
Thanks for your very quick response 👍 Initially I was trying to submit a JSON object like
and output it in the template with Thanks for your hint with |
What's your template? |
By now I'm just trying to output the json into the template, but what I want in the end is to create a HTML structure out of the ( JSON.parse 'ed data).
|
Hi…I decided to put the direct sending of the JSON data aside and tried to implement the atob way as it fit's my needs. Still I cannot get the server/templating engine to accept I tried the following things:
Still in my template the field is processed with Inside the .js files I'm able to process a atob() command - it log's out perfectly to the console! Can you please give me a hint where I need to define |
Thanks for your great work, I like to use the microservice alot for different projects that do not require a backend but recent notifications.
To use the microservice for data-driven applications it would be benefitial if the user could payload some json data into the mail, as the underlying lodash library supports this.
I could not find out a way to transport e.g. a json object into the mailer (also html structure and "pure" data objects (just displayed as
[object]
) fail with unexpected token responses). Further attempts in base64 encoding the object failed, as i getatob is undefined
response from the server after i saved<%= atob(value) %>
to the template.I would appreciate any help and would be willing in contributing.
The text was updated successfully, but these errors were encountered: