Created
May 7, 2021 01:30
-
-
Save ponty96/1ab50c868f5c08af5385f54e0d4bbe8c to your computer and use it in GitHub Desktop.
Convert multipart mixed to finch command
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -v --location --request POST "https://route.example.com/route/v2/send" --header 'Content-Type: multipart/mixed; boundary=mimeboundary' --header 'Authorization: Basic AUTH_TOKEN' --data-binary "@body_data.txt" | |
body_data.txt is: | |
--mimeboundary | |
Content-Type: application/json | |
Content-Id: main | |
{ | |
"type": "DUDE", | |
"source": "jane@doe.com", | |
"destination": "john@doe.com", | |
"config": "configvalue", | |
"subject": "Example Email", | |
"operatordId": 200 } | |
--mimeboundary | |
Content-Type: application/vnd.example.remoteContent | |
Content-Id: EMAIL-Demo.mp4 | |
https://example.com/resources/EMAIL-DEMO.mp4 | |
--mimeboundary | |
Content-Type: text/plain; charset=utf-8 | |
Content-Id: example.txt | |
This is my text. | |
--mimeboundary-- |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment