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

# Atualizar campo de inscrição



## OpenAPI

````yaml /openapi.json patch /events/{event}/registration-fields/{field}
openapi: 3.1.0
info:
  title: Eventor Management API v1
  version: 1.0.0
  description: >-
    Management API do Eventor (Fase 9) — configuração de evento ponta a ponta
    por agente/CLI. Autenticação: `Authorization: Bearer <api_key>` com escopo
    `manage`.


    Envelope de sucesso: `{data}` (item) e `{data,meta,links}` (coleção
    paginada).

    Envelope de erro: `{error,message,details}`.
servers:
  - url: http://localhost/api/v1
security:
  - bearerAuth: []
paths:
  /events/{event}/registration-fields/{field}:
    patch:
      tags:
        - RegistrationFields
      summary: Atualizar campo de inscrição
      operationId: registrationFields.update
      parameters:
        - name: event
          in: path
          required: true
          schema:
            type: string
        - name: field
          in: path
          required: true
          schema:
            anyOf:
              - type: string
              - type: integer
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/UpdateRegistrationFieldRequest'
      responses:
        '200':
          description: '`JsonResource`'
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    $ref: '#/components/schemas/RegistrationFieldResource'
                required:
                  - data
        '401':
          description: API key ausente ou inválida.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
        '403':
          description: A API key não tem o escopo `manage`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
        '404':
          description: Recurso não encontrado neste hub.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
        '409':
          description: 'Conflito (ex.: dependência que impede a operação).'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
        '422':
          description: Falha de validação dos dados enviados.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiError'
components:
  schemas:
    UpdateRegistrationFieldRequest:
      type: object
      description: >-
        PATCH /api/v1/events/{event}/registration-fields/{field} — atualização
        parcial.
      properties:
        label:
          type: string
          maxLength: 120
        key:
          type: string
          maxLength: 60
        type:
          $ref: '#/components/schemas/RegistrationFieldType'
        validation_rules:
          type:
            - array
            - 'null'
          items:
            type: string
        help_text:
          type:
            - string
            - 'null'
          maxLength: 500
        is_required:
          type: boolean
        show_only_with_kit:
          type: boolean
        is_active:
          type: boolean
        sort_order:
          type: integer
          minimum: 0
        options:
          type:
            - array
            - 'null'
          items:
            type: object
            properties:
              value:
                type: string
                maxLength: 120
              label:
                type: string
                maxLength: 120
      title: UpdateRegistrationFieldRequest
    RegistrationFieldResource:
      type: object
      properties:
        id:
          type: integer
        event_id:
          type: integer
        key:
          type: string
        label:
          type: string
        type:
          type: string
        options:
          type: array
          items: {}
        validation_rules:
          type:
            - array
            - 'null'
          items: {}
        help_text:
          type:
            - string
            - 'null'
        is_required:
          type: boolean
        show_only_with_kit:
          type: boolean
        is_active:
          type: boolean
        sort_order:
          type: integer
        created_at:
          type: string
        updated_at:
          type: string
      required:
        - id
        - event_id
        - key
        - label
        - type
        - options
        - validation_rules
        - help_text
        - is_required
        - show_only_with_kit
        - is_active
        - sort_order
        - created_at
        - updated_at
      title: RegistrationFieldResource
    ApiError:
      type: object
      properties:
        error:
          type: string
          description: >-
            Código machine-parseable (ex.: validation_failed, forbidden_scope,
            not_found).
        message:
          type: string
          description: Mensagem legível (português).
        details:
          type:
            - object
            - 'null'
          description: 'Detalhes opcionais (ex.: erros de validação por campo).'
          additionalProperties: {}
      required:
        - error
        - message
      title: ApiError
    RegistrationFieldType:
      type: string
      enum:
        - text
        - textarea
        - select
        - multiselect
        - checkbox
        - file
      title: RegistrationFieldType
  securitySchemes:
    bearerAuth:
      type: http
      description: >-
        API key do hub com escopo `manage`. Header: `Authorization: Bearer
        <api_key>`.
      scheme: bearer

````