---
title: "Test schema compatibility against all schemas under a subject"
method: POST
path: "/compatibility/subjects/{subject}/versions"
tags: ["Compatibility (v1)"]
---

# Test schema compatibility against all schemas under a subject

`POST /compatibility/subjects/{subject}/versions`

Test input schema against a subject's schemas for compatibility, based on the configured compatibility level of the subject. In other words, it will perform the same compatibility check as register for that subject. The compatibility level applied for the check is the configured compatibility level for the subject (http:get:: /config/(string: subject)). If this subject's compatibility level was never changed, then the global compatibility level applies (http:get:: /config).

## Path parameters

- `subject` string, required

## Query parameters

- `verbose` boolean

## Request body

- RegisterSchemaRequest — Schema register request
  - `version` integer — Version number
  - `id` integer — Globally unique identifier of the schema
  - `schemaType` string — Schema type
  - `references` SchemaReference[] — References to other schemas
    - `name` string — Reference name
    - `subject` string — Name of the referenced subject
    - `version` integer — Version number of the referenced subject
  - `schema` string — Schema definition string
  - `metadata` Metadata, nullable — User-defined metadata
    - `tags` object
    - `properties` object
    - `sensitive` string[]
  - `ruleSet` RuleSet, nullable — Schema rule set
    - `migrationRules` Rule[]
      - `name` string — Rule name
      - `doc` string — Rule doc
      - `kind` 'TRANSFORM' | 'CONDITION' — Rule kind
      - `mode` 'UPGRADE' | 'DOWNGRADE' | 'UPDOWN' | 'WRITE' | 'READ' | 'WRITEREAD' — Rule mode
      - `type` string — Rule type
      - `tags` string[] — The tags to which this rule applies
      - `params` object — Optional params for the rule
      - `expr` string — Rule expression
      - `onSuccess` string — Rule action on success
      - `onFailure` string — Rule action on failure
      - `disabled` boolean — Whether the rule is disabled
    - `domainRules` Rule[]
      - `name` string — Rule name
      - `doc` string — Rule doc
      - `kind` 'TRANSFORM' | 'CONDITION' — Rule kind
      - `mode` 'UPGRADE' | 'DOWNGRADE' | 'UPDOWN' | 'WRITE' | 'READ' | 'WRITEREAD' — Rule mode
      - `type` string — Rule type
      - `tags` string[] — The tags to which this rule applies
      - `params` object — Optional params for the rule
      - `expr` string — Rule expression
      - `onSuccess` string — Rule action on success
      - `onFailure` string — Rule action on failure
      - `disabled` boolean — Whether the rule is disabled
  - `schemaTagsToAdd` SchemaTags[]
    - `schemaEntity` SchemaEntity
      - `entityPath` string
      - `entityType` 'sr_record' | 'sr_field'
    - `tags` string[]
  - `schemaTagsToRemove` SchemaTags[]
    - `schemaEntity` SchemaEntity
      - `entityPath` string
      - `entityType` 'sr_record' | 'sr_field'
    - `tags` string[]
  - `propagateSchemaTags` boolean

## Response `200`

Compatibility check result.

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden
- `422` — Unprocessable Entity. Error code 42201 indicates an invalid schema or schema type. Error code 42202 indicates an invalid version.
- `429` — Rate Limit Exceeded
- `500` — Internal Server Error. Error code 50001 indicates a failure in the backend data store.

---

[API](https://skmtc.dev/confluent/apis/confluent-cloud-apis.md) · [All operations](https://skmtc.dev/confluent/apis/confluent-cloud-apis/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/confluent/confluent-cloud-apis/revisions/a6a73f98a698/schema)
