Invoke a Google Cloud function using an HTTP request. Refer to the Google Cloud Functions API documentation.

Options

  • Region (drop-down): assigned region for your project; the following regions are available:
    • asia-east2
    • asia-northeast1
    • europe-west1
    • europe-west2
    • europe-west3
    • us-central1
    • us-east1
    • us-east4

The names of the cloud functions in each region are unique, but you can have the same named function in two different regions. us-central1 is the default.

  • Function Name (drop-down): the name of the function
  • Request Type (drop-down): one of five 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. If successful, GET will receive a 200 OK response message with the requested content. Refer to additional documentation here.
    • POST sends data to a web server based on your parameters. POST requests include actions like uploading a file. Multiple POSTs may result in a different outcome than a single POST, so you should be cautious about unintentionally sending multiple POSTs. If a POST is successful, you will receive a 200 OK response message. Refer to 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). Refer to additional documentation here.
    • PATCH applies partial modifications to a resource on a web server based on your parameters. PATCH is not idempotent, meaning that multiple PATCHs could have unintended consequences. If a PUT is successful, you will receive a 200 response message (usually 204). Refer to 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. Refer to additional documentation here.

Input

  • Query (object or text): JSON object that determines the action taken at the URL

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

    Example: {"Content-type":"application/json"}
  • Body (object): JSON object that is passed in the content of the request. This will usually be a replica of the example below.

    Example: {"id":10}

Output

  • Status Code (number): Success or failure of your HTTP request. Here is a list of all status codes.
  • Headers (object): A detailed context for the status code, unrelated to the output body. Response headers are dependent on your selected HTTP request option. Note that not all headers are response headers.
  • Body (object): data returned from your selected HTTP request (for example, the data from a GET request)