On the wire the request/response payloads still use
project-prefixed keys
(project, project_id) for backward compatibility. These name the ontology
container.Save an ontology
Create or update an ontology. Sending an existingid updates the ontology in
place; a new id (or a client-generated one) creates a new ontology.
Example
List ontologies
Return all ontologies visible to the authenticated user, deduplicated by ontology ID. No parameters required.data is an array of ontology objects (id, name, description, and associated
metadata).
Load an ontology
Fetch full details for a single ontology by ID.Copy an ontology
Duplicate an existing ontology. All concepts, data source binds, and the schema are copied; a new ontology ID is assigned.Templates
Templates are pre-built ontologies available to all users from a shared marketplace. Uselist-templates to browse them, then import-template to
instantiate one as a new ontology in your workspace.
List templates
Return all available templates from the marketplace. No parameters required.data is an array of template objects (id, name, description, and metadata).
Import a template
Create a new ontology from a marketplace template. Data source connections are validated after import; any that cannot be resolved are reported infailed_datasources.
Export an ontology
Serialize a single ontology — its concepts (structure only, not cached output rows), data source binds, schema, and metadata — into a JSON payload.To move an ontology to another account or workspace, export it as a file tree
with
export-tree instead. The app no longer imports this JSON
payload, and import-ontology is deprecated.Concept execution output (cached predicate rows) and embedding tables are
excluded from the export. All concepts are marked as not-populated so they
must be re-run after import.
Import an ontology
Restore an ontology from a payload previously produced byexport-ontology. A new
ontology ID is assigned; data source connections are validated after import and
any that fail are reported in failed_datasources.
Ontology as files
export-ontology and import-ontology above move an ontology as one opaque
payload. The three endpoints here move it as a file tree instead — a
manifest, one file per concept, the data source specs, the schema graph and the
apps — which is what you want when the ontology lives in version control.
This is the API behind the CLI’s px pull, px plan and px apply; if you are
working from a terminal, use the CLI
rather than these endpoints directly.
Export a tree
format=zip the response is the raw archive rather than the envelope.
A tree never carries credentials. Data sources are exported as specs — type,
host, database, table — so a tree is safe to commit, and applying one to an
account that lacks a named data source reports it rather than inventing it.
Plan a tree
Diffs a tree against what is live and writes nothing. Run this before applying, and show a user the result: it is the only point at which the consequences of an apply are visible in advance.{"files": [{"path": "...", "content": "..."}, …]} — or a
multipart/form-data upload with a file field holding the tree as a zip.
data classifies every concept as create,
update, delete or unchanged, lists the data source, app and schema
changes, and — importantly — names the downstream concepts a changed
definition forces to re-run. A one-line edit near the top of a chain can mean
rebuilding most of the project, and this is where you find that out.
Apply a tree
Reconciles live state to the tree. Concepts are written dependencies-first, and an ontology the tree names but your account does not have is created./plan-tree, plus:
Export workspace
Export every ontology in the workspace — and all workspace-level tables — in a single payload. Equivalent to callingexport-ontology for each ontology plus the
workspace-level tables in one request. No parameters required.
Import workspace
Restore a full workspace from a payload produced byexport-workspace. Each
ontology is imported in turn; partial failures are tracked per-ontology in the
summary.
Create from context
Create a brand-new ontology from free-text context and/or file attachments. The platform analyzes the input with the LLM to extract entities and relationships, generates an ontology name and description, and uses Vadalingo to translate the domain knowledge into Vadalog concepts. This endpoint is sent asmultipart/form-data (form fields, not JSON) because it
accepts file uploads.
Provide at least one of
context or files; supplying neither returns a 400.
Snapshots
Snapshots are point-in-time captures of an ontology’s full state — concepts, data source binds, and schema. They enable lightweight versioning without a full export/import cycle.Create a snapshot
List snapshots
Return snapshot metadata for an ontology. The heavy snapshot payload is omitted — userestore with a snapshot_id to apply one.
data is an array of snapshot metadata objects (snapshot_id, description,
created_at).
Restore a snapshot
Delete a snapshot
Read a snapshot’s concepts
Return the concept definitions held by one snapshot, or by the live ontology. This is what a diff view reads on both sides — pass a snapshot ID for one side andcurrent for the other.

