HTTP Request
Sends an HTTP request to a URL and outputs the status and the response body.
- Category
- Action
- Topics
- Scheduler ยท HTTP
Ports
- triggercontrol
- URLstring
- Request bodystring
- Content-Typestring
- onCompletecontrol
- onFailedcontrol
- HTTP statusnumber
- Response bodystring
Data types
string
number
bool
Strings accept any data input.
Numbers accept boolean input.
Fields
| Field | What it does | Default | Limits |
|---|---|---|---|
| Method | The HTTP method of the request. | POST |
|
| URL | The address to request. | None | Cannot be empty; http or https only. |
| Request body | The text sent as the request body. | None | None |
| Content-Type | The Content-Type header sent with the body. |
application/json |
None |
What a run does
Sends one request with a 30 s timeout and follows up to 10 redirects.
A wired
URL, Request body or Content-Type replaces its field.
An empty Request body
sends no body and no Content-Type header.
An empty Content-Type
sends application/json.
The block does not filter addresses, so a
URL on the local network works.
It leaves by onComplete when the status is below 400.
It leaves by
onFailed on a status of 400 or above, and on a connection error.
HTTP status carries the status code whenever a response arrived, failed or
not.
Response body carries the body as text once the whole body has been
read.
A body over 1 MiB fails the block and sets no Response body.
Errors
| Message says | Do |
|---|---|
| url is empty | Fill in URL or wire one in. |
| HTTP status: response body | The service answered 400 or above; check the request and what the service expects. |
| HTTP status: response body exceeds 1048576 bytes | Request something smaller; the block keeps 1 MiB at most. |
| HTTP status: read response: reason | The connection broke while the body was read; check the service and the network. |
| Method "url": reason | Check the address, that the service is reachable and that it answers within 30 s. |