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

# Update Mapping

> Update a custom field mapping. Only `json_path` is mutable — to change the scope of a mapping, delete it and create a new one.



## OpenAPI

````yaml patch /api/v1/custom-fields/mapping/{custom_field_mapping_id}
openapi: 3.1.0
info:
  title: Bindbee APIs
  version: 0.1.0
servers:
  - url: https://api.bindbee.dev
  - url: https://api-eu.bindbee.dev
security: []
paths:
  /api/v1/custom-fields/mapping/{custom_field_mapping_id}:
    patch:
      tags:
        - Custom Fields
      summary: Update Custom Field Mapping
      description: Update a custom field mapping (json_path only).
      operationId: >-
        update_custom_field_mapping_api_v1_custom_fields_mapping__custom_field_mapping_id__patch
      parameters:
        - name: custom_field_mapping_id
          in: path
          required: true
          schema:
            type: string
            format: uuid
            title: Custom Field Mapping Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CustomFieldMappingUpdateExternal'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CustomFieldMappingExternal'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    CustomFieldMappingUpdateExternal:
      properties:
        json_path:
          type: string
          maxLength: 1024
          pattern: \S.*\S
          title: Json Path
          description: JMESPath expression to extract the value from the upstream payload.
      type: object
      required:
        - json_path
      title: CustomFieldMappingUpdateExternal
    CustomFieldMappingExternal:
      properties:
        id:
          type: string
          format: uuid
          title: Id
          description: Unique identifier of the mapping.
          examples:
            - 018e586b-7d0b-7bc9-be65-a8fdbc82d734
        custom_field_id:
          type: string
          format: uuid
          title: Custom Field Id
          description: ID of the custom field this mapping belongs to.
          examples:
            - 018e586b-7d0b-7bc9-be65-a8fdbc82d734
        integration_slug:
          anyOf:
            - type: string
            - type: 'null'
          title: Integration Slug
          description: >-
            Integration slug. Set when the mapping is organization-scoped; null
            otherwise.
          examples:
            - workday
        connector_token:
          anyOf:
            - type: string
            - type: 'null'
          title: Connector Token
          description: >-
            Connector token. Set when the mapping is connector-scoped; null
            otherwise.
          examples:
            - i5kqe8bSedEdPLX9pHhFojKdo7Uzvue0f7I4NVhaDfV0GTxF0uAgwa_COb3zZU3T
        json_path:
          type: string
          title: Json Path
          description: >-
            JMESPath expression used to extract the value from the upstream
            payload.
          examples:
            - data.employee.guardian_mobile
        created_at:
          type: string
          format: date-time
          title: Created At
        updated_at:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Updated At
      type: object
      required:
        - id
        - custom_field_id
        - json_path
        - created_at
      title: CustomFieldMappingExternal
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer

````