Skip to main content

Ontology API Reference

Ontologies are managed through ordinary OpenMetadata REST APIs. The visual authoring workspace, Ontology Studio, is available only in Collate; these endpoints are part of OpenMetadata. The relational model is authoritative, so creating, editing, publishing, importing, and exporting an ontology don’t need the RDF triple store. Where an endpoint needs RDF or an LLM provider, the table says so.
Paths in the Ontologies table are relative to /api. Paths in the other tables are relative to the base path shown above each table. Every entity group below also supports the standard entity operations, so each table lists them once.

Ontologies

/api/v1/ontologies

Notable Fields

The ontology and release entities carry the review state of a release. These fields are read-only outputs of the release flow.

Concepts

/api/v1/ontologyConcepts Concept bindings are catalog links. They apply right away and aren’t part of a release.

Properties

/api/v1/ontologyProperties Same operations as concepts, without the bindings and query routes: list, fetch by {id} or /name/{fqn}, create, PUT, PATCH, delete, /restore, and version history. GET takes ontology to list the properties of one ontology.

Constraints

Constraints are stored as axioms. /api/v1/ontologyAxioms Axiom types: SUBCLASS_OF, EQUIVALENT_CLASS, DISJOINT_WITH, CLASS_ASSERTION, OBJECT_PROPERTY_ASSERTION, DATA_PROPERTY_ASSERTION.

Releases

A release is an immutable snapshot of an ontology. /api/v1/ontologyReleases

Capture a Release

POST /api/v1/ontologies/{id}/releases takes this body: PUT /api/v1/ontologies/{id}/activation takes releaseId and expectedActivationRevision, both required.

Export a Release

GET /api/v1/ontologyReleases/{id}/export exports the captured definitions, independent of working edits and of RDF availability.

Preview an Import

POST /api/v1/ontologies/{id}/imports/preview, POST /api/v1/ontologies/imports/preview, and POST /api/v1/ontologies/imports/detect take a JSON body: The preview with an ontology id compares the file with that ontology’s working revision. It returns the detected format, counts of what the file would add, update, or repeat, and the change set request that applies it. The preview without an id parses the file against an empty ontology, and needs permission to create ontologies. imports/detect reads at most the first 65,536 characters. None of them save anything.

Delete a Glossary Term With an Impact Preview

Deleting a glossary term can reassign or remove its child terms, typed relationships, and concept mappings. A two-step call shows you the effect first, then deletes only if you confirm it.
  1. GET /api/v1/ontology/impacts/glossaryTerms/{id}/delete returns a preview. It lists the immediate children, the relationships and concept mappings removed with the term, and a sample of the bound assets with their total count. It also returns an impactToken and its expiresAt time.
  2. POST /api/v1/ontology/impacts/glossaryTerms/{id}/delete deletes the term.
The token expires 2 minutes after the preview. The delete is also refused if the token was issued to a different user, or if the term or its impact changed since the preview. In each case, run a new preview and use the new token. If the term has children, set either cascadeConfirmed to true or reassignChildrenTo, but not both. The response returns the deleted resource, the number of reassignedChildren, and the cascaded and hardDeleted flags. These flags show whether the delete cascaded to child terms and whether it was permanent. The following example deletes a term and reassigns its children to a glossary.

Permissions

Administrators skip the checks on child terms. Everyone else needs the following permissions. The server checks them before it changes anything, so a refused request leaves the glossary as it was.
  • Delete on the term itself.
  • EditAll on the glossary or glossary term that receives the reassigned children, and on every term the reassignment affects.
  • Delete on every term a cascade removes, including soft-deleted descendants.

Change Sets

Durable authoring sessions with typed operations. A change set is created and applied for you when you import a file. /api/v1/ontologyChangeSets

Library Packs

/api/v1/ontologyPacks To install a pack into an existing ontology, review it with POST /v1/ontologies/{id}/library/{packId}/review, start it with POST /v1/ontologies/{id}/library/{packId}/install, and read the job with GET /v1/ontologies/{id}/library/jobs/{jobId}.

Relationship Types

Governed OWL object properties. /api/v1/relationshipTypes Related: GET /api/v1/glossaryTerms/relationTypes/usage returns usage counts per type.

Reasoning and AI

The following endpoints explain inferences and propose changes with AI. The /api/v1/ontology/ai routes need RDF_AI_ENABLED=true and a configured LLM provider.

Create a Custom Relationship Type

This request creates a custom relationship type.

Read the Unpublished Changes of an Ontology

This request reads the unpublished changes of an ontology.