17
Views
5
Comments
Pretty up JSON for email
Question

Is there any way to pretty up a bunch of JSON I am throwing into an email (as a text input parameter) that has the appropriate line breaks/tabs/spaces?

Dave,

If you're open to using a second module, I would create the email in a tradweb module, and then access it with a shared action.


This will give you access to the email with a prep, where you can use the JSONDeserialize action do make whatever changes to the data you want, or even display it in a table or list.


Best,
RAD Manage

Champion

Hi Dave,

You can use "Pretty Json Format" forge component.

Here is the link of component

https://www.outsystems.com/forge/component-overview/969/json-pretty-format

Best

Arun

JSON Pretty Format seems interesting but I don't see how I can use the provided Web Block (that the JSON is rendered into) in an OutSystems email.  Can you even use webblocks in emails?

Champion

Firstly take dependency of that web block to your module where you have email functionality then drag and drop same web block inside the email template

Do let me know if face any issue.

Best

Arun

You cannot drag and drop a web block in a reactive email as far as i can tell.  It's very limited.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.