# Send a json file via email using workflows

**URL:** <https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446>\
**Category:** Open Q&A\
**Tags:** integrations, problem-notification, workflows\
**Created:** [July 14, 2026, 3:37pm UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446 "2026-07-14T15:37:19Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![elenaperez](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/elenaperez/32/38054_2.png) [@elenaperez](https://community.dynatrace.com/u/elenaperez)\
**Post date:** [July 14, 2026, 3:37pm UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/1 "2026-07-14T15:37:19Z")

</div>

Hi team&nbsp;😊

I have a workflow with a variable that contains a lot of information I want to send via email.

The information is too large to be sent via email directly so I need a json file to be sent. I don’t see a way to attach files though.

What is the best way to do this? I’ve tried with Power Automate and Microsoft Entra but don’t have enough permissions.

Maybe via FTP? But how?

Thanks in advance!

---

<div class="post-metadata">

**Author:** ![sujit\_k\_singh](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@sujit\_k\_singh](https://community.dynatrace.com/u/sujit_k_singh)\
**Post date:** [July 15, 2026, 3:28am UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/2 "2026-07-15T03:28:18Z")

</div>

Hi&nbsp;[@elenaperez](https://community.dynatrace.com/user/58054)

The built-in&nbsp;Send Email&nbsp;action in Dynatrace Workflows does&nbsp;not support file attachments&nbsp; it only supports sending text/Markdown content in the email body, this is a known limitation.

The most reliable workaround: use the built-in HTTP Request action to call an external email API that supports attachments , encoding your JSON variable into the payload. Store the API key in the Credential Vault. This sidesteps the Power Automate/Entra permissions issue since you’re not going through Microsoft at all.

Or 2nd approach could be, use HTTP Request to upload the JSON somewhere accessible (S3, Blob Storage or a file server.) then use the Send Email action to send a link to the file rather than the file itself.

Thanks,

Sujit

---

<div class="post-metadata">

**Author:** ![AntonPineiro](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/antonpineiro/32/49_2.png) [@AntonPineiro](https://community.dynatrace.com/u/AntonPineiro)\
**Post date:** [July 15, 2026, 1:23pm UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/3 "2026-07-15T13:23:20Z")

</div>

Hi,

Maybe this can be a product idea.

Best regards

---

<div class="post-metadata">

**Author:** ![sujit\_k\_singh](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@sujit\_k\_singh](https://community.dynatrace.com/u/sujit_k_singh)\
**Post date:** [July 15, 2026, 9:51pm UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/4 "2026-07-15T21:51:55Z")

</div>

Hello,

Yes, this is right use case for product idea.

Thanks,

Sujit

---

<div class="post-metadata">

**Author:** ![elenaperez](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/elenaperez/32/38054_2.png) [@elenaperez](https://community.dynatrace.com/u/elenaperez)\
**Post date:** [July 17, 2026, 1:48pm UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/5 "2026-07-17T13:48:04Z")

</div>

I don’t think I understand the solution. Where do I get the external email API from?  
Could you provide an example of how you would do this, please?

---

<div class="post-metadata">

**Author:** ![sujit\_k\_singh](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@sujit\_k\_singh](https://community.dynatrace.com/u/sujit_k_singh)\
**Post date:** [July 18, 2026, 1:35am UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/6 "2026-07-18T01:35:35Z")

</div>

Hi&nbsp;[@elenaperez](https://community.dynatrace.com/user/58054)

Sure,&nbsp;this is absolutely possible using Dynatrace Workflows. Here’s how I’ve done it:

I have used here HTTP Request action with SendGrid API

Step 1: Generate JSON data (JavaScript action) sample example

 ![sujit_k_singh_2-1784337913446.png](https://global.discourse-cdn.com/dynatrace/original/2X/3/393b85bcfddbf2eb1a991a3bdfa715499ee46b8f.png)

Step 2: Send email with attachment (HTTP Request action)  
Method: POST  
URL: [https://api.sendgrid.com/v3/mail/send](https://api.sendgrid.com/v3/mail/send)  
Authentication: Bearer token (store your SendGrid API key in Credential Vault)  
Payload:

 ![sujit_k_singh_4-1784338092761.png](https://global.discourse-cdn.com/dynatrace/original/2X/3/3a3b4e16dc2504e41b8146895ae38e9cb5530c53.png)

Store your API key in Dynatrace Credential Vault

 ![sujit_k_singh_5-1784338221035.png](https://global.discourse-cdn.com/dynatrace/original/3X/0/5/05a3eead8af0ff83bb211616465b62f1937f9d3c.png)

now run the flow

This approach works for any JSON data — problem notifications, metric exports, custom reports, etc.

 ![sujit_k_singh_6-1784338355852.png](https://global.discourse-cdn.com/dynatrace/original/1X/7ff7dd1f861d7989a226656551fa1b9ab287647a.png)

 ![sujit_k_singh_7-1784338427054.png](https://global.discourse-cdn.com/dynatrace/original/2X/1/12db04f18bfea8a8abce52edd7fffa5909faed24.png)

Now i got this email with attachment

 ![sujit_k_singh_0-1784337729539.png](https://global.discourse-cdn.com/dynatrace/original/2X/5/59ff03054b94cac89730fa86563872a6834d72a0.png)

Thanks,

Sujit

---

<div class="post-metadata">

**Author:** ![elenaperez](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/elenaperez/32/38054_2.png) [@elenaperez](https://community.dynatrace.com/u/elenaperez)\
**Post date:** [July 21, 2026, 9:47am UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/7 "2026-07-21T09:47:30Z")

</div>

This won’t be possible for them because their email blocks anything coming from SendGrid.  
Would it be possible to send the json to an Ubuntu machine somehow? Maybe with EdgeConnect?

---

<div class="post-metadata">

**Author:** ![sujit\_k\_singh](https://avatars.discourse-cdn.com/v4/letter/s/34f0e0/32.png) [@sujit\_k\_singh](https://community.dynatrace.com/u/sujit_k_singh)\
**Post date:** [July 21, 2026, 11:15am UTC](https://community.dynatrace.com/t/send-a-json-file-via-email-using-workflows/56446/8 "2026-07-21T11:15:30Z")

</div>

Hi&nbsp;[@elenaperez](https://community.dynatrace.com/user/58054)

Yes, its possible.

I tested this on my end — it works! Here’s what I did:

- Dynatrace tenant with EdgeConnect configured to reach my Ubuntu machine
- Simple Flask webhook listener on the Ubuntu box (port 5000)
- Dynatrace Workflow: On demand trigger → Run JavaScript (generate JSON) → HTTP Request (POST to webhook via EdgeConnect)

 ![sujit_k_singh_1-1784632311812.png](https://global.discourse-cdn.com/dynatrace/original/3X/b/f/bf90e95217cba3bb894d3f35e6fea2acdd1a69e7.png)

 ![sujit_k_singh_3-1784632400563.png](https://global.discourse-cdn.com/dynatrace/original/2X/e/e68c38d33f82f144ebd50f52ffad698713381db7.png)

 ![sujit_k_singh_2-1784632374326.png](https://global.discourse-cdn.com/dynatrace/original/3X/0/6/06c82a6553c222a9883137782fbb289d02186b3b.png)

Thanks,

Sujit
