# HTTP Request

Executes a HTTP Request to a HTTP Server.

Action available for the following operating systems:

![](https://3821468174-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LrTlA1suFa5N48x_83N%2F-MAlPVpH3WRwBy16c7JY%2F-MAlQBZuuTnc6hyzKSVQ%2Fimage.png?alt=media\&token=5c9534b7-ca05-4ac4-b408-2207cd5a5295)

### Parameters

*General*

* **Run From** - This parameter allows user to choose between executing a HTTP Request locally (option "locally") or executing a HTTP Request remotely (option "Remotely"). If the user chooses option "Remotely", its necessary to define the following parameters:
  * **Communication Profile** - Name of the communication profile used to execute the remote HTTP Server.
  * **Hidden** - This parameter allows user to define if he wants to run the remote HTTP Request in hidden mode or not.
  * **Timeout** - The timeout defined for connection. The value 0 is System Default. The timeout value is in milliseconds.
* **Target Answer Body** <*string*> - The control or variable to save the result of the HTTP Request.
* **Target Answer Header** <*string*> - The control or variable to save the result of the HTTP Request Header.
* **Target Status Code** <*string*> - The control or variable to save the result of the status code.
* **Target Status Text** <*string*> - The control or variable to save the result of the status text.
* **Fail if status code isn't 2xx** - Defines whether fails if status code isn't 2xx.

*Details*

* **Server** <*string*> - The name of the server to execute the HTTP Request.
* **Object** <*string*> - The name of the object to execute the HTTP Request.
* **Port** <*numeric*> - The port to communicate with the HTTP server.
* **Encoding** <*string*> - The encoding schema used for the communication. The possible options for this parameter are:
  * utf-8
  * utf-7
  * ansi
  * unicode
* Mode numeric - The mode of the HTTP Request. The possible values for this parameter are:
  * 1 - GET
  * 2 - POST
  * 3 - PUT
  * 4 - DELETE
  * 5 - PATCH
  * 6 - HEAD
  * 7 - CONNECT
  * 8 - OPTIONS
  * 9 - TRACE
  * -2 - Reset Session

{% hint style="warning" %}
Note: -2 is only for Win32 clients. It ends the browser session, so that the next HTTP request is equivalent to being executed as if the applications just started. In Android and Win10 clients, it does nothing.
{% endhint %}

*Request*

* **Additional Header** <*string*> - Defines a additional request header for the HTTP Request.
* **Data** <*string*> - The string that represents the request to HTTP Server.

*Security*

* **User** <*string*> - The name of the user for the HTTP Request. If there is no defined user for the web service call, just put "" on this parameter.
* **Password** <*string*> - The password of the user of the HTTP Request. If there is no user and password, just put "" on this parameter.
* **Certificate File** <*string*> - Path of the client certificate file.
* **Certificate File Password** <*string*> - Client certificate File Password.

{% hint style="warning" %}
These last two parameters are not supported on Windows 10 Clients.
{% endhint %}

* **Ignore Invalid Certificates** - Defines whether ignores or not Invalid Certificates.
* **Certificate Fingerprint List** <*string*> - List of Public Key SHA256 Hash for certificate pinning, separated by CR.
* **Public Key Fingerprint List** <*string*> - List of Public Key SHA256 Hash for certificate pinning, separated by CR.

{% hint style="warning" %}
These last two parameters are not supported on Windows Mobile/CE.
{% endhint %}

{% hint style="info" %}
If the **Object** parameter is not empty, then in the **Server** parameter there should be only the server address, without any "/" and the remainder should go in the request Object parameter.

For example when you have a request address like <http://www.myserver.com/Name1/Name2> you can call:\
**Server**= "<http://www.myserver.com>" **Object**="Name1/Name2"\
or:\
**Server**= "<http://www.myserver.com/Name1/Name2>" **Object**=""
{% endhint %}

{% hint style="info" %}
If in the **Server** parameter the port is specified using a ":" then the **Port** parameter is ignored. For example:\
<http://www.myserver.com:8080>
{% endhint %}

{% hint style="info" %}
When using Self-signed Certificates, you should set the parameter Ignore Invalid Certificates to Yes, and add the certificate fingerprint in the Certificate Fingerprint List or the Public Key Fingerprint to the Public Key Fingerprint List.
{% endhint %}

{% hint style="info" %}
Client certificates and certificate fingerprint validation are not used when executing remotely by using MISCommunicator
{% endhint %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.sysdevmobile.com/kalipso5/developing/form/actions/actions-description/group-communications/http-request.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
