Unable to send [] in form-data of my multipart API method
Application Type
Mobile, Reactive
Service Studio Version
11.54.34 (Build 62959)
Platform Version
11.24.0 (Build 41209)

I am unable to parse the [ character or the ] character in my API call, here's an example
I tried to add the double quotes to ensure that it is passed a string, but without the double quotes it just gets hung and doesnt proceed further in testing even.To give a background I already tried to convert the parameter into text make it manually and then parse it as a string, example:
I have a very tight deadline need help ASAP

Hi Faizan,

Did you test your request using Postman, i.e.? And see if you get the same error?

The API specification tells you that you need to send the [] in each field to filer?



Postman brings the proper results :

Can you please attach you OML, just to check if something can be wrong, please?


Unfortunately due to policy I can't share the OML

hi faizan,

what is the exact error that you are getting in outsystems?

If I test it it says "Testing..." and just hangs,
If I click finish to complete it without testing it it doesnt create the API

Are you providing a proper structure in the response body?

try copying the response from postman and pasting it in the outsystems.


I've copied what was in payload when monitoring network of postman to use as structure in outsystems, basically I think it is what you meant.


Without a proper use case and/or example it is difficult to analyse which can be the issue.

However, did you try create the consume REST API manually instead of using the test approach?

Additionally, why do you need that your request format must be multipart? 

When creating manually it works but retrives all data, meaning it overlooked the query that had [] and just gave all the data in the system as response. 
The test approach as you said is the one that fails.

But when you test in Postam with the filter logic, are you getting the right data?

In that case, can you check in the OnBeforeRequest (RequestText) how the body is being sent to the external API.

Let me know which is the value that you are getting in the RequestText field.

This is what I got, one thing I noticed was the name of the field was supposed to be field[0] and not "=?utf-8?B?4oCcZmlsdGVyTG9naWPigJ0=?="::

Although it seems fine in request part, is this something that is causing the problem ?

Can you debug your OutSystems code, please?

At OnAfterResponse, can you add a breakpoint at the "start" and check which is the value of ResponseText or StatusLine.

Additionally, at OnBeforeRequest, can you check the RequestParts when debugging it.


Have you tried to replace the brackets by  their code:

replace [   by       %5B    

replace ]   by      %5D

Just an idea


Yep, done that also tried EncodeUrl() and EncodeSql() just in case if I missed something, when I manually created the API it works but I am unable to query it since [] is not passing in outsystems.


Which is the error message presented in Service Center?

Did you try to see which error you are getting in OnAfterResponse, in the StatusLine and/or ResponseText?

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