HTTP Request value passing through Parameters

How to pass the value in HTTP Request instead of using body , we need to pass the value through Parameter in"post" Method…?

1 Like

Hi @Anikalai

Welcome to our UiPath Forum! :slight_smile:

You can use the Parameters parameter of the HTTP Request activity:
image

It is quite straightforward:
image

hi @loginerror,

How to pass variables in it it is not working for me

You should simply replace the "yourString" with your String variable.

Some examples of the errors you are getting could help us dive deeper into your issue :slight_smile:

Hi @loginerror,

As you mentioned here by am sharing the error which am facing, Please find the details in the image

{
“timestamp”: “2020-08-18T13:31:13.444+05:30”,
“status”: 415,
“error”: “Unsupported Media Type”,
“message”: “Content type ‘application/x-www-form-urlencoded;charset=UTF-8’ not supported”,
“path”: “/xxxxx/xxx/xxx/xxxxxx”
}

parameter_error_message parameters

Could you also show how your HTTP Request is configured in both Studio and a working example using some other tool (i.e. Postman)?

This would help a lot.

Hi @loginerror ,

Please find the details that u have asked.

1 Like

Could you try passing the JSON in the Body field of the HTTP Request activity?
image

It accepts input as string, so you will have to escape all double quotes, like so:

"{""key"":""value""}"

There are other ways to pass this JSON input to this field, such as:

  1. Load it from a text file as is (no need to escape quotes) using the Read Text File activity
  2. Create it from scratch, more on that here.
1 Like

@loginerror ,

I also have a similar doubt.How to pass a file path to a API call in HTTP request.
I have the URL and key that works fine. The API will convert that file and return me a ID(in numbers) but if i pass file as a parameter in string throws empty error

Hi @Stealth_Coder

I am not sure I understand your reqest.

Could you maybe post a screenshot how you would achieve the same in let’s say Postman (or any other tool of your choice)?

hi i am able to only hardcode a value and unable to pass a variable in there

Hi, I am having a similar issue, but my Post Body request needs a variable type of DateTime, but I can pass only the String value, Let me know how I can change the datatype of my parameter.

2 posts were split to a new topic: HTTP Request configure button purges given variable parameters

Is this solved now? i am also facing similar issue