Portal Forms

Replaces a custom form with the supplied fields and settings.

To remove a field, leave it out of the fields array; to rename a field, change its label (a field's name can't change once set).

The form's type can't be changed. Its name is fixed for developer_registration forms but can be changed for api_registration forms.

developer_registration forms must include the built-in full_name and email fields.

put/v3/portals/{portalId}/forms/{formId}

Request

  • Base URL
    https://global.api.konghq.com
  • Auth
    • HTTP bearer
    • or HTTP bearer
    • or HTTP bearer
    • or HTTP bearer

Path parameters

portalId, string uuid required
Example:f32d905a-ed33-46a3-a093-d8f536af9a8a

ID of the portal.

formId, string uuid required
Example:5f9fd312-a987-4628-b4c5-bb4f4fddd5f7

ID of the portal form.

Request body

union required

Request body for updating a form.

The type must match the form's existing type — it can't be changed.

To remove a field, leave it out of fields; to rename a field, edit its label.

intersection required
OR
intersection required

Example request

{
  "type": "developer_registration",
  "status": "published",
  "fields": [
    {
      "name": "full-name",
      "type": "content",
      "value": "## Tell us about your project"
    }
  ]
}

Response

A custom form belonging to a portal.

CustomFormResponse required

A custom form configured for a developer portal, including its fields.

id, string uuid required

Contains a unique identifier used for this resource.

name, string required

A unique, URL-friendly identifier for the form (lowercase letters, digits, and hyphens). For developer_registration forms, this is always developer-registration. For api_registration forms, you choose the name when creating the form and can change it later.

type, 'developer_registration' | 'api_registration' required

The kind of form. Determines which fields are required and where developers see the form on the portal.

status, 'published' | 'unpublished' required

Whether the form is visible to developers on the portal. unpublished forms aren't shown to developers; for the developer_registration form, a default form is shown instead.

fields, CustomFormField[] required

The form's fields, in the order they're displayed. Must include exactly one submit field. developer_registration forms must also include the built-in full_name and email fields.

created_at, string date-time required

An ISO-8601 timestamp representation of entity creation date.

updated_at, string date-time required

An ISO-8601 timestamp representation of entity update date.

Example response

{
  "id": "5f9fd312-a987-4628-b4c5-bb4f4fddd5f7",
  "name": "flights-api-registration",
  "type": "developer_registration",
  "status": "unpublished",
  "fields": [
    {
      "name": "full-name",
      "type": "content",
      "value": "## Tell us about your project",
      "built_in": true
    }
  ],
  "created_at": "2022-11-04T20:10:06.927Z",
  "updated_at": "2022-11-04T20:10:06.927Z"
}

Changes

    • info

      the response property fields/items/oneOf[#/components/schemas/CustomFormCheckboxField]/required became required for the status

    • info

      the response property fields/items/oneOf[#/components/schemas/CustomFormEmailField]/required became required for the status

    • info

      the response property fields/items/oneOf[#/components/schemas/CustomFormNumberField]/required became required for the status

    6 more changes in this revision