# Update a file's schema field definitions
Source: https://docs.file.ai/api-reference/schemas-file-types/update-a-files-schema-field-definitions

> This endpoint is used to patch the schema fields that are associated with the file types in the workspace.

patch /prod/v1/files/schema

This endpoint is used to patch the schema fields that are associated with the file types in the workspace.

The response will contain a list of schemas that are associated with the file types in the workspace.

The `fileId` field is used to specify the file that should be changed to the new schema version.

The `schemaId` field is used to specify the schema that should be updated.

The `shouldCreateCustomIfNotExists` field is used to specify whether a custom schema should be created if it does not exist.

The `schemaVersionType` field is used to specify the type of schema version to be create. The allowed values are `MAJOR`, `MINOR`, and `PATCH`.

The `shouldChangeDocumentToNewSchemaVersion` field is used to specify whether the document should be changed to the new schema version.

The `fieldPaths` field is used to specify the fields that should be updated.
