HTTP Request Block

Description of the HTTP Request Block work

This block makes an HTTP request. Five request methods are supported:

  • GET - Used to request the contents of a specified resource

  • POST - Used to transfer user data to a specified resource

  • PUT - Used to load the contents of the request to the URI specified in the request

  • PATCH - Similar to PUT, but applies only to a fragment of the resource

  • DELETE - Deletes the specified resource

The screenshot below shows the block settings with a detailed description.

  1. Request method.

  2. UrI specifies the path to the requested document.

  3. Content type in queries (such as POST or PUT), the client tells the server the type of data to send.

  4. The request header can be added using the Add header button

  5. Setting up a response from the server in the block:

  • Response type. The response format can be in three options: json, text, base64. For json, the Data path setting is available

  • The response data can be written to a variable or workflow table

Data path

If you want to receive part of the json response data, you can use the Data path setting.For example, when the response returns this data:

{

"status": 200,

"data": {

"name": "Prices",

"values": [

{ "id": 1, "value": 4000 },

{ "id": 2, "value": 24000 }

]

}

}

To obtain values array, write data.values as a path. And to get the first value of the array values, write data.values.0.

\

Last updated