Skip to main content
PUT
/
api
/
v1
/
forms
/
{token}
Update a form
curl --request PUT \
  --url https://formhug.ai/api/v1/forms/{token} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "locale": "<string>",
  "timezone": "<string>",
  "fields": [
    {
      "label": "<string>",
      "type": "short_text",
      "api_code": "<string>",
      "notes": "<string>",
      "private": true,
      "required": true,
      "customized_validation_message": "<string>",
      "predefined_value": "<string>",
      "placeholder": "<string>",
      "answers": [
        {
          "score": 123,
          "answer": [
            "<string>"
          ]
        }
      ],
      "answer_explanation": "<string>"
    }
  ],
  "theme": {
    "header_image_url": "<string>",
    "header_image_keywords": "<string>"
  },
  "folder_token": "<string>",
  "original_folder_token": "<string>"
}
'
{
  "data": {
    "name": "Customer feedback",
    "description": "Please share your feedback",
    "token": "Wabc12",
    "scene": "survey",
    "locale": "en",
    "timezone": "UTC",
    "created_at": "2026-05-12T08:00:00Z",
    "updated_at": "2026-05-12T09:00:00Z",
    "last_entry_created_at": "2026-05-13T10:00:00Z",
    "entries_count": 42,
    "folder": {
      "token": "KaB2c1",
      "name": "Work"
    },
    "fields": [
      {
        "type": "short_text",
        "label": "Name",
        "api_code": "field_1",
        "notes": "Please use your real name",
        "private": false,
        "required": true,
        "customized_validation_message": "<string>",
        "predefined_value": "<string>",
        "placeholder": "<string>",
        "answers": [
          {
            "score": 123,
            "answer": [
              "<string>"
            ]
          }
        ],
        "answer_explanation": "<string>"
      }
    ]
  }
}

Documentation Index

Fetch the complete documentation index at: https://formhug.ai/docs/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Personal Access Token prefixed with fh_. Sent as Authorization: Bearer fh_xxx. The scope required by each endpoint is listed in that endpoint's description.

Path Parameters

token
string
required

Form token

Body

application/json

All attributes are optional; only the provided ones are updated.

name
string

New form name.

description
string | null

New form description.

locale
string

Form locale, e.g. en, zh-CN, it.

timezone
string

IANA timezone name used by the form when interpreting times.

fields
(Short Text · object | Long Text · object | Radio · object | Checkbox · object | Dropdown · object | Number · object | Email · object | Phone · object | Date · object | Name · object | URL · object | Address · object | Rating · object | NPS · object | Upload · object | Cascade · object | Ranking · object | Matrix Input · object | Likert Scale · object | Time · object | Location · object | Signature · object | Grid Rating · object | Table · object | Product · object | Booking · object | Linked Form · object)[]

Replaces the form's field list. See the "How the fields array is reconciled" section above for the add / update / delete semantics, and the Form Field schema for the parameters accepted per field type.

A field definition supplied on form create / update. Every field accepts the shared keys (label, api_code, notes, private, required, ...) plus a set of type-specific keys determined by its type — see the per-type sections below.

theme
object

Auto-generate a header image and matching palette. Provide either header_image_url or header_image_keywords.

folder_token
string

Target folder token; empty string moves the form to the desktop (root).

original_folder_token
string

Original folder token; used for cross-folder move authorization.

Response

Updated

data
object
required
Last modified on May 21, 2026