AdHub App icon

AdHub App

Manage AdHub leads, activities, sources, statuses, tags, and custom fields

Lead Segment → Create

AI-generated

Summary

Create a new lead segment in AdHub App by defining filter conditions either via form inputs or by providing a JSON payload.

Inputs

  • Body Type (required) — Choose between 'Form' to specify the segment details using form fields or 'JSON' to provide the segment as a raw JSON object.
  • Name (required) — Unique display name for the segment (up to 255 characters). Displayed only if Body Type is 'Form'.
  • Match Type (required) — Specify how the segment conditions are combined: 'ALL' requires all conditions to match; 'ANY' requires at least one condition to match. Displayed only if Body Type is 'Form'.
  • Conditions (required) — One or more filter conditions that define the segment criteria. Conditions include selecting a category, field, operator, and value. Displayed only if Body Type is 'Form'.
  • Body (JSON) (required) — Raw JSON object representing the segment properties, including name, match_type, and conditions. Displayed only if Body Type is 'JSON'.

Output shape

a single record representing the created lead segment

The returned data contains the properties of the newly created lead segment as received from the AdHub API. At least one condition is required when using the form input method. Using the JSON body requires supplying a valid JSON structure matching the API expectations.

Examples

Example 1: Create lead segment using form inputs

Set Body Type to 'Form', provide a unique Name, select a Match Type ('ALL' or 'ANY'), and add one or more Conditions specifying category, field, operator, and value.

Example 2: Create lead segment using JSON body

Set Body Type to 'JSON' and supply a JSON string defining the segment including fields like 'name', 'match_type', and 'conditions'.

Links

Discussion