> ## Documentation Index
> Fetch the complete documentation index at: https://docs.geniusforms.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Form

> Update form metadata and webhook configuration. At least one field must be provided.



## OpenAPI

````yaml openapi.json patch /forms/{id}
openapi: 3.1.0
info:
  title: GeniusForms API
  description: >-
    AI-powered form builder API. Create forms manually or generate them from
    natural language prompts.
  version: 1.0.0
  contact:
    name: GeniusForms Support
    email: support@geniusforms.ai
    url: https://geniusforms.ai
servers:
  - url: https://geniusforms.ai/api/v1
    description: Production
  - url: http://localhost:8000/api/v1
    description: Local Development
security:
  - ApiKeyAuth: []
paths:
  /forms/{id}:
    patch:
      tags:
        - Forms
      summary: Update Form
      description: >-
        Update form metadata and webhook configuration. At least one field must
        be provided.
      operationId: updateForm
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: integer
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateFormRequest'
      responses:
        '200':
          description: Form updated
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Form'
components:
  schemas:
    UpdateFormRequest:
      type: object
      properties:
        title:
          type: string
        description:
          type: string
        displayMode:
          type: string
          enum:
            - single-page
            - multi-step
        webhookUrl:
          type: string
          nullable: true
          maxLength: 2000
          description: >-
            Webhook URL to receive form submissions. Set to null or empty string
            to clear.
        webhookEnabled:
          type: boolean
          description: Enable or disable webhook delivery. Requires a webhookUrl to be set.
    Form:
      type: object
      properties:
        id:
          type: integer
          example: 208
        title:
          type: string
          example: Customer Feedback
        description:
          type: string
          example: Help us improve our service
        isPublished:
          type: boolean
          example: false
        shareUrl:
          type: string
          example: abc123xyz
        url:
          type: string
          example: https://geniusforms.ai/f/abc123xyz
        displayMode:
          type: string
          enum:
            - single-page
            - multi-step
          example: single-page
        createdAt:
          type: string
          format: date-time
        publishedAt:
          type: string
          format: date-time
          nullable: true
        webhook:
          $ref: '#/components/schemas/WebhookConfig'
    WebhookConfig:
      type: object
      description: Webhook configuration for the form
      properties:
        enabled:
          type: boolean
          example: false
        url:
          type: string
          nullable: true
          example: https://example.com/webhook
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key
      description: API key obtained from your GeniusForms dashboard

````