You are viewing limited content. For full access, please sign in.

Question

Question

How to configure a multipart/form-data web request in On-Prem Workflow Designer

asked on August 1, 2024

I have the following multipart/form-data web request rule configured in Cloud, but we have an On-Prem customer trying to do the same thing and we don't see the multipart/form-data option in the web request rule list. If we manually type it, it does not give us an option to add custom boundaries or to choose an electronic document from the token picker.

Here is an example of the working method in Cloud

Here are my options in On-Prem Web Requests

Even when manually entering the content type there is no where to specify your boundaries and the electronic document token does not give you access to the actual document to add to the body

 

0 0

Replies

replied on August 1, 2024 Show version history

For self-hosted, you would use HTTP Form Post instead of HTTP Web Request

Here's an example; the settings/gear icon allows you to do more customization like switching between automated/manual headers and/or adding multiline content to a field.

2 0
replied on August 1, 2024

Ah, just posted our solution using this, but still a little confused about where to put the JSON that is also included in our HTML Body after switching to this type of rule.

0 0
replied on August 1, 2024

Got it working and will post the answer here in case someone else needs this or when I need this in future, the interface is just so different then Clouds rule interface and you don't need to do any boundary work.

You can use the Form Post instead which does not have content type options but you can add it as a header and it works

From there you can configure a Form data field with the name of your name= field from the HTML body line Content-Disposition: form-data; name="X". In our case it was "Files" and it allows you to access the Electronic Document token here.

You have to click the gear and select use the following headers, File. Here you can set the content-type and Filename from your original HTML body.

The only unknown part here is where to put the JSON part of the body. In our case we dropped the JSON all together which likely used defaults instead and it still worked. But if you had to use JSON within your body while also sending a file, I am not sure where to put it, since the Form Post Activity does not include anywhere to freely enter your HTML body.

2 0
You are not allowed to follow up in this post.

Sign in to reply to this post.