🚀Native Response Transformation in HTTP Request Action

The Goal: Reduce 3 actions (HTTP Request → JSON to Object → Query Collection) into 1 single action.

The Problem

Currently, when working with Google APIs (and many others), the response is often returned as a collection, even if it contains only a single item (e.g., {"organizations": [...]}). (And in most of the cases the response only has 1 item)

To get to the data we actually need, we are forced into a "3-Action Chain":

  1. HTTP Request: To get the raw data.

  2. Query Collection: To isolate the first (and only) element.

  3. Convert JSON to Object: To apply a schema and get usable tokens.

This adds unnecessary complexity, clutters the Flow Designer, and makes the token picker harder to navigate.

The Proposal

Enhance the HTTP Request action to include two new configuration fields:

  1. Response Path (JSON Path support): Allow us to specify a path like $.organizations[0] or $.folders[0] directly in the action settings.

  2. Native Output Schema: Allow us to define the JSON Schema for the result of that path directly within the HTTP Request action.

Why this is a Game Changer:

  • Cleaner Flows: We eliminate two redundant steps for every API call.

  • Better Performance: Fewer actions per flow execution.

  • Intuitive Token Mapping: Instead of seeing a "Collection" icon, we immediately see the attributes (like ID, Name, State) in our token picker.

  • Standardized Experience: This aligns the HTTP Request action with how modern iPaaS tools handle complex JSON responses.

Example Use Case

When searching for a specific Organization ID, instead of managing a collection, we simply set the Response Path to $.organizations[0]. Zenphi then treats the output as a single Organization Object, giving us direct access to all properties immediately.