This action allows you to make a custom, authenticated HTTP call to the Percolate API.

NOTE: If you have no experience working with API calls this may be a challenge, however this card is highly customizable. Good luck, and it may help if you refer to the documentation!

Options

  • Request Type (dropdown): your available HTTP request methods. There are 5 supported HTTP request methods (sometimes called verbs) in custom API calls:

    • GET: retrieves data from a web server based on your parameters. GET requests a representation of the specified resource, and if successful will receive a 200 OK response message with the requested content. Additional documentation here.

    • POST: sends data to a web server based on your parameters. POST requests include actions like uploading a file. Multiple POST’s may result in a different outcome than a single POST, so you should be cautious about unintentionally sending multiple POST’s. If a POST is successful, you will receive a 200 OK response message. Additional documentation here.

    • PUT: sends data to a location in the web server based on your parameters. PUT requests include actions like uploading a file. The difference between a PUT and POST is that PUT is idempotent, meaning that the result of a single successful PUT is the same as many identical PUT’s. If a PUT is successful, you will receive a 200 response message (usually 201 or 204). Additional documentation here.

    • PATCH: applies partial modifications to a resource on a web server based on your parameters. PATCH is not idempotent, meaning that the result of multiple PATCH’s could have unintended consequences. If a PUT is successful, you will receive a 200 response message (usually 204). Additional documentation here.

    • DELETE: deletes the specified resource from the web server based on your parameters (if the resource exists). If a DELETE is successful, you will receive a 200 OK response message. Additional documentation here.

Input Data

  • Relative URL (text): the address on the web server you are attempting to interact with. Relative URL means that you don’t have to explicitly specify the protocol at the beginning of the URL (such as “http://“). This suggests to the web server that the interaction is occurring on the server (in this instance). With this Custom API Action the user needs to specify the API version being accessed and add following ‘/’ characters when required.

    Example: /api/v5/campaign/
  • Query (object or text): JSON object that determines the action taken at the URL.

    Example: {"name":"something-urgent"}
  • Headers (object): JSON that determines the content type of the request. This will usually be a replica of the example below.

    Example: {"Content-type":"application/json"}

Output Data

  • Status Code (Number): the success or failure of your HTTP request. Here is a list of all status codes.

  • Headers (object): a more detailed context for the response/status code that doesn’t relate to the output body. Not all headers that appear in a response header are response headers, meaning that some are unlikely to be useful to you.

The response headers are dependent on the HTTP request you choose in options.

  • Body (object): depending on the HTTP request you chose in Options, you may receive some data back. That data, such as the data from a GET request, will be contained in this Body object.