AdHub App icon

AdHub App

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

Lead Custom Field → Create

AI-generated

Summary

Create a new custom field for leads in the AdHub system, specifying its label, name, type, options, required status, and default value either via form inputs or by providing a raw JSON body.

Inputs

  • Body Type (required) — Choose how to provide the custom field data: as form parameters ('form') or as raw JSON ('json'). Defaults to 'form'.
  • Label (required) — The display label for the custom field. Used only when 'Body Type' is 'form'.
  • Name (required) — The internal name (identifier) of the custom field. Used only when 'Body Type' is 'form'.
  • Type (required) — The type of the custom field, e.g., checkbox, date, email, input, multiselect, phone, radio, select, or textarea. Used only when 'Body Type' is 'form'.
  • Options — For field types that support multiple choices (select, multiselect, checkbox, radio), specify the option values. Used only when 'Body Type' is 'form'.
  • Required — Boolean flag indicating if the custom field is mandatory. Used only when 'Body Type' is 'form'.
  • Default Value — Default value to assign to the custom field. Used only when 'Body Type' is 'form'.
  • Body (JSON) (required) — Raw JSON string representing the custom field definition, including all relevant properties. Used only when 'Body Type' is 'json'.

Output shape

a single created custom field object

The operation returns the newly created lead custom field as an object. Input validation depends on the chosen 'Body Type'. For 'form' inputs, fields are strictly typed and validated accordingly. For 'json' input, the entire field object must be composed correctly in JSON format.

Examples

Example 1: Create a simple lead custom field using form inputs

Set 'Body Type' to 'form', provide 'Label' as 'Industry', 'Name' as 'industry', select 'Type' as 'multiselect', add option values such as 'saas' and 'ecommerce', set 'Required' to true, and optionally a default value.

Example 2: Create a complex custom field with detailed rules and defaults using raw JSON

Set 'Body Type' to 'json' and provide a JSON string defining all necessary properties including label, name, type, options, rules, and default values.

Links

Discussion