User Data Capture

Create a data capture form

POST/data-capture-forms

Creates a data capture form and returns it with a Location. name is required. It starts disabled, so no user is asked for its fields until status is enabled or internal_only. Send pages and fields to author it in one call; each field needs a type, and its reference is the key its answer is stored under. Put requiredness in validator, such as required|string. dry_run shows the result without saving it. Emits data_capture_form.created and sends no email. DELETE /data-capture-forms/{id} undoes it.

Query parameters

  • dry_runboolean#

    Validate and run the call without committing it, returning what the real call would return with meta.dry_run set.

Headers

  • Idempotency-Keystring#

    Makes a retry safe. Send a new UUID for each new request and reuse it only to retry that request; the first response is replayed for 24 hours.

Request body

application/json, required · DataCaptureFormCreate

  • namestringRequired#

    The form's display name.

  • statusstring#

    The status to start in. enabled asks every user for the form's fields, internal_only asks internal users only, and disabled asks nobody. A new form is disabled unless this says otherwise.

    One of: enabled, disabled, internal_only
  • pagesarray | null#

    The form's pages.

  • fieldsarray | null#

    The form's fields.

{
  "name": "UK Investor Profile",
  "status": "enabled",
  "fields": [
    {
      "type": "DATE",
      "label": "Date of birth",
      "reference": "date_of_birth",
      "validator": "required|date",
      "order": 1
    },
    {
      "type": "TEXT",
      "label": "Nationality",
      "reference": "nationality",
      "placeholder": "e.g. British",
      "validator": "required|string",
      "order": 2
    },
    {
      "type": "DROPDOWN",
      "label": "Country of tax residency",
      "reference": "tax_residency",
      "options": [
        "United Kingdom",
        "Ireland",
        "Other"
      ],
      "order": 3
    }
  ]
}

Responses

201

The data capture form was created.

DataCaptureForm
{
  "data": {
    "id": "9a9d1c5e-4f2b-4c8e-9a7d-2f1e6b3c4d5a",
    "name": "string",
    "status": "enabled",
    "field_count": 1,
    "pages": [
      {
        "id": "9a9d1c5e-4f2b-4c8e-9a7d-2f1e6b3c4d5a",
        "name": "string",
        "description": "string",
        "order": 1
      }
    ],
    "fields": [
      {
        "id": "9a9d1c5e-4f2b-4c8e-9a7d-2f1e6b3c4d5a",
        "label": "string",
        "name": "string",
        "description": "string",
        "type": "string",
        "reference": "string",
        "validator": "string",
        "placeholder": "string",
        "pre_population_key": "string",
        "backfill": true,
        "order": 1,
        "page_id": "9a9d1c5e-4f2b-4c8e-9a7d-2f1e6b3c4d5a",
        "option_preset_id": "9a9d1c5e-4f2b-4c8e-9a7d-2f1e6b3c4d5a",
        "options": [],
        "required": true,
        "conditions": [],
        "condition_logic": "AND"
      }
    ],
    "created_at": "2026-06-12T10:00:00+00:00",
    "updated_at": "2026-06-12T10:00:00+00:00"
  }
}
401

Authentication failed. error.code is one of invalid_token, expired, revoked.

Error
403

Authorization failed. error.code is one of org_disabled, ip_blocked, missing_scope, scope_disabled, user_disabled.

Error
422

The request can't be processed (HTTP 422): validation_failed with one ErrorDetail per problem, or a code documented on the operation.

Error
429

Rate limit exceeded (error.code = rate_limited).

Error

Examples

curl -X POST https://your-org-domain/kong/core/api/v2/data-capture-forms\
  -H "Authorization: Bearer $HELM_API_KEY"\
  -H "Content-Type: application/json"\
  -d '{
  "name": "UK Investor Profile",
  "status": "enabled",
  "fields": [
    {
      "type": "DATE",
      "label": "Date of birth",
      "reference": "date_of_birth",
      "validator": "required|date",
      "order": 1
    },
    {
      "type": "TEXT",
      "label": "Nationality",
      "reference": "nationality",
      "placeholder": "e.g. British",
      "validator": "required|string",
      "order": 2
    },
    {
      "type": "DROPDOWN",
      "label": "Country of tax residency",
      "reference": "tax_residency",
      "options": [
        "United Kingdom",
        "Ireland",
        "Other"
      ],
      "order": 3
    }
  ]
}'