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

# Update the schema for an object type

> Update the schema for an existing object type

> **Supported products**


## OpenAPI

````yaml specs/legacy/v1/cms-media-bridge-v1.json PATCH /media-bridge/v1/{appId}/schemas/{objectType}
openapi: 3.0.1
info:
  title: CMS Media Bridge
  description: Basepom for all HubSpot Projects
  version: v1
  x-hubspot-product-tier-requirements:
    marketing: FREE
    sales: FREE
    service: FREE
    cms: FREE
    commerce: FREE
    crmHub: FREE
    dataHub: FREE
  x-hubspot-related-documentation:
    - name: Media Bridge Guide
      url: https://developers.hubspot.com/docs/guides/api/cms/media-bridge
servers:
  - url: https://api.hubapi.com
security: []
tags:
  - name: Advanced
  - name: Basic
  - name: Batch
paths:
  /media-bridge/v1/{appId}/schemas/{objectType}:
    patch:
      tags:
        - Basic
      summary: Update the schema for an object type
      description: Update the schema for an existing object type
      operationId: patch-/media-bridge/v1/{appId}/schemas/{objectType}
      parameters:
        - name: appId
          in: path
          description: ''
          required: true
          style: simple
          explode: false
          schema:
            type: integer
            format: int32
        - name: objectType
          in: path
          description: ''
          required: true
          style: simple
          explode: false
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ObjectTypeDefinitionPatch'
        required: true
      responses:
        '200':
          description: successful operation
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ObjectTypeDefinition'
        default:
          $ref: '#/components/responses/Error'
          description: ''
      security:
        - developer_hapikey: []
components:
  schemas:
    ObjectTypeDefinitionPatch:
      required:
        - clearDescription
      type: object
      properties:
        allowsSensitiveProperties:
          type: boolean
        clearDescription:
          type: boolean
        description:
          type: string
        labels:
          $ref: '#/components/schemas/ObjectTypeDefinitionLabels'
        primaryDisplayProperty:
          type: string
        requiredProperties:
          type: array
          items:
            type: string
        restorable:
          type: boolean
        searchableProperties:
          type: array
          items:
            type: string
        secondaryDisplayProperties:
          type: array
          items:
            type: string
    ObjectTypeDefinition:
      required:
        - allowsSensitiveProperties
        - archived
        - fullyQualifiedName
        - id
        - labels
        - name
        - objectTypeId
        - requiredProperties
        - searchableProperties
        - secondaryDisplayProperties
      type: object
      properties:
        allowsSensitiveProperties:
          type: boolean
        archived:
          type: boolean
        createdAt:
          type: string
          format: date-time
        description:
          type: string
        fullyQualifiedName:
          type: string
        id:
          type: string
        labels:
          $ref: '#/components/schemas/ObjectTypeDefinitionLabels'
        name:
          type: string
        objectTypeId:
          type: string
        portalId:
          type: integer
          format: int32
        primaryDisplayProperty:
          type: string
        requiredProperties:
          type: array
          items:
            type: string
        searchableProperties:
          type: array
          items:
            type: string
        secondaryDisplayProperties:
          type: array
          items:
            type: string
        updatedAt:
          type: string
          format: date-time
    ObjectTypeDefinitionLabels:
      type: object
      properties:
        plural:
          type: string
        singular:
          type: string
    Error:
      required:
        - category
        - correlationId
        - message
      type: object
      properties:
        category:
          type: string
          description: The error category
        context:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: Context about the error condition
          example: >-
            {invalidPropertyName=[propertyValue], missingScopes=[scope1,
            scope2]}
        correlationId:
          type: string
          description: >-
            A unique identifier for the request. Include this value with any
            error reports or support tickets
          format: uuid
          example: aeb5f871-7f07-4993-9211-075dc63e7cbf
        errors:
          type: array
          description: further information about the error
          items:
            $ref: '#/components/schemas/ErrorDetail'
        links:
          type: object
          additionalProperties:
            type: string
          description: >-
            A map of link names to associated URIs containing documentation
            about the error or recommended remediation steps
        message:
          type: string
          description: >-
            A human readable message describing the error along with remediation
            steps where appropriate
          example: An error occurred
        subCategory:
          type: string
          description: >-
            A specific category that contains more specific detail about the
            error
      description: >-
        Represents an error response returned by the API when an operation
        fails. This component is used in various endpoints to provide detailed
        information about the error encountered.
      example:
        message: Invalid input (details will vary based on the error)
        correlationId: aeb5f871-7f07-4993-9211-075dc63e7cbf
        category: VALIDATION_ERROR
        links:
          knowledge-base: https://www.hubspot.com/products/service/knowledge-base
    ErrorDetail:
      required:
        - message
      type: object
      properties:
        code:
          type: string
          description: The status code associated with the error detail
        context:
          type: object
          additionalProperties:
            type: array
            items:
              type: string
          description: Context about the error condition
          example: '{missingScopes=[scope1, scope2]}'
        in:
          type: string
          description: The name of the field or parameter in which the error was found.
        message:
          type: string
          description: >-
            A human readable message describing the error along with remediation
            steps where appropriate
        subCategory:
          type: string
          description: >-
            A specific category that contains more specific detail about the
            error
      description: >-
        Represents detailed information about an error that occurred in the API.
        This component is used to provide additional context and specifics about
        errors, typically as part of an error response.
  responses:
    Error:
      description: An error occurred.
      content:
        '*/*':
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    developer_hapikey:
      type: apiKey
      name: hapikey
      in: query

````