Campaigns

Update Lead Schema

Registers the fields a lead can carry. Add Leads ignores any key that isn't in the schema, so call this first when pushing leads with custom fields.

Additive — a field you don't mention is kept, so a partial write never wipes the rest. A new name creates a field; re-sending an existing one is a no-op. A field's type is locked once created (a different type is ignored rather than rewriting stored values), and email and name are fixed fields that cannot be renamed, retyped or removed.

The schema is written to the draft, so fields registered here survive the next publish, and to the live sequence when one already exists. Registering fields never publishes a sequence on its own. Returns the full merged schema.

patch/api/v1/campaigns/{campaign_id}/lead-schema

Request

  • Base URL
    http://localhost:3009
  • Auth
    HTTP bearer

Path parameters

campaign_idstring required

Campaign ID

Request body

Example request

{
  "fields": [
    {
      "name": "company",
      "type": "string"
    }
  ]
}

Response

Default Response

statusinteger
messagestring

Example response

{
  "data": {
    "fields": [
      {
        "name": "company",
        "type": "string"
      }
    ]
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.