Skip to content

HTTP API / Discovery

Discovery API ​

13 operations. Paths are relative to the API host (http://localhost:5080 in local development). Every operation accepts an OIDC bearer token (Authorization: Bearer …) or a workspace API key (X-Api-Key: keel_live_…); errors are RFC 9457 Problem Details with a code (error codes). Permissions: matrix.

MethodPathSummary
GET/api/v1/workspaces/{workspaceId}/discovery-runsDiscovery runs of a workspace (or one source), newest first.
GET/api/v1/workspaces/{workspaceId}/discovery-runs/{runId}A discovery run with its stages and metrics.
POST/api/v1/workspaces/{workspaceId}/discovery-runs/{runId}:cancelCancel a run; its source queries stop within seconds.
POST/api/v1/workspaces/{workspaceId}/discovery-runs/{runId}:retryResume a failed or cancelled run from its first unfinished stage.
GET/api/v1/workspaces/{workspaceId}/drift-eventsSchema drift events of a workspace (or one source), newest first.
GET/api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}One schema drift event with its impact and the change request proposing the fix.
POST/api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}:acknowledgeAcknowledge a drift event (it stays listed until resolved).
POST/api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}:resolveResolve a drift event (fix merged, source reverted or change accepted).
GET/api/v1/workspaces/{workspaceId}/snapshots/{snapshotId}/tables/{tableId}A table with columns, profiles, keys, indexes and declared relationships.
GET/api/v1/workspaces/{workspaceId}/snapshots/{snapshotId}/treeSchemas and tables of a snapshot.
POST/api/v1/workspaces/{workspaceId}/sources/{sourceId}:check-driftStart a metadata-only drift scan compared with the last snapshot (F16). Progress: /jobs/{jobId}/events.
POST/api/v1/workspaces/{workspaceId}/sources/{sourceId}:scanStart a discovery run (harvest + profile). Progress: /jobs/{jobId}/events.
GET/api/v1/workspaces/{workspaceId}/sources/{sourceId}/snapshotsSchema snapshots of a source, newest first.

ListDiscoveryRuns ​

http
GET /api/v1/workspaces/{workspaceId}/discovery-runs

Discovery runs of a workspace (or one source), newest first.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
sourceIdqueryuuidno
limitqueryint32no
StatusDescriptionBody
200OKDiscoveryRunDto[]

GetDiscoveryRun ​

http
GET /api/v1/workspaces/{workspaceId}/discovery-runs/{runId}

A discovery run with its stages and metrics.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
runIdpathuuidyes
StatusDescriptionBody
200OKDiscoveryRunDto

Response 200: DiscoveryRunDto

FieldTypeNotes
completedAtdate-time?
dataSourceIduuid
dataSourceNamestring
iduuid
jobIduuid?
requestedAtdate-time
snapshotIduuid?
stagesStageDto[]
startedAtdate-time?
statusRunStatusOne of Queued, Running, Succeeded, Failed, Cancelling, Cancelled
triggerRunTriggerOne of Manual, Scheduled, Drift
workspaceIduuid

CancelDiscoveryRun ​

http
POST /api/v1/workspaces/{workspaceId}/discovery-runs/{runId}:cancel

Cancel a run; its source queries stop within seconds.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
runIdpathuuidyes
StatusDescriptionBody
204No Content—

RetryDiscoveryRun ​

http
POST /api/v1/workspaces/{workspaceId}/discovery-runs/{runId}:retry

Resume a failed or cancelled run from its first unfinished stage.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
runIdpathuuidyes
StatusDescriptionBody
202AcceptedRunAccepted

Response 202: RunAccepted

FieldTypeNotes
jobIduuid
runIduuid

ListDriftEvents ​

http
GET /api/v1/workspaces/{workspaceId}/drift-events

Schema drift events of a workspace (or one source), newest first.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
sourceIdqueryuuidno
statusqueryDriftStatusno
breakingOnlyquerybooleanno
limitqueryint32no
StatusDescriptionBody
200OKDriftEventDto[]

GetDriftEvent ​

http
GET /api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}

One schema drift event with its impact and the change request proposing the fix.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
driftEventIdpathuuidyes
StatusDescriptionBody
200OKDriftEventDto

Response 200: DriftEventDto

FieldTypeNotes
acknowledgedAtdate-time?
acknowledgedBystring?
affectedObjectsstring[]
affectsReleaseboolean
afterstring?
beforestring?
breakingboolean
changeRequestModelIduuid?
changeRequestNumberint32?
columnstring?
dataSourceIduuid
dataSourceNamestring
detectedAtdate-time
evidencestring?
iduuid
kindDriftKindOne of TableAdded, TableRemoved, TableRenamed, ColumnAdded, ColumnRemoved, ColumnRenamed, ColumnTypeChanged, KeyChanged, ViewDefinitionChanged
newColumnstring?
newSchemastring?
newTablestring?
proposedFixstring?
resolutionNotestring?
resolvedAtdate-time?
resolvedBystring?
runIduuid
schemastring
statusDriftStatusOne of Open, Acknowledged, Resolved
summarystring
tablestring

AcknowledgeDriftEvent ​

http
POST /api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}:acknowledge

Acknowledge a drift event (it stays listed until resolved).

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
driftEventIdpathuuidyes
StatusDescriptionBody
204No Content—

ResolveDriftEvent ​

http
POST /api/v1/workspaces/{workspaceId}/drift-events/{driftEventId}:resolve

Resolve a drift event (fix merged, source reverted or change accepted).

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
driftEventIdpathuuidyes

Request body (application/json): ResolveDriftEventRequest

FieldTypeNotes
notestring?Why the drift is resolved (optional, at most 500 characters).
StatusDescriptionBody
204No Content—

GetTableDetail ​

http
GET /api/v1/workspaces/{workspaceId}/snapshots/{snapshotId}/tables/{tableId}

A table with columns, profiles, keys, indexes and declared relationships.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
snapshotIdpathuuidyes
tableIdpathuuidyes
StatusDescriptionBody
200OKTableDetailDto

Response 200: TableDetailDto

FieldTypeNotes
classificationTableClassificationDto?
columnsColumnDto[]
commentstring?
foreignKeysForeignKeyDto[]
hashstring
iduuid
indexesIndexDto[]
kindstring
namestring
primaryKeyKeyDto?
profileNotestring?
profileStatusstring
referencedByForeignKeyDto[]
rowCountint64?
rowCountEstimateint64?
rowCountExactboolean
sampleSizeint64?
schemastring
snapshotIduuid
uniqueKeysKeyDto[]
viewDefinitionstring?

GetSchemaTree ​

http
GET /api/v1/workspaces/{workspaceId}/snapshots/{snapshotId}/tree

Schemas and tables of a snapshot.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
snapshotIdpathuuidyes
StatusDescriptionBody
200OKSchemaTreeDto

Response 200: SchemaTreeDto

FieldTypeNotes
dataSourceIduuid
dataSourceNamestring
schemasTreeSchemaDto[]
snapshotIduuid
takenAtdate-time

CheckDataSourceDrift ​

http
POST /api/v1/workspaces/{workspaceId}/sources/{sourceId}:check-drift

Start a metadata-only drift scan compared with the last snapshot (F16). Progress: /jobs/{jobId}/events.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
sourceIdpathuuidyes
StatusDescriptionBody
202AcceptedRunAccepted

Response 202: RunAccepted

FieldTypeNotes
jobIduuid
runIduuid

ScanDataSource ​

http
POST /api/v1/workspaces/{workspaceId}/sources/{sourceId}:scan

Start a discovery run (harvest + profile). Progress: /jobs/{jobId}/events.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
sourceIdpathuuidyes
StatusDescriptionBody
202AcceptedRunAccepted

Response 202: RunAccepted

FieldTypeNotes
jobIduuid
runIduuid

ListSnapshots ​

http
GET /api/v1/workspaces/{workspaceId}/sources/{sourceId}/snapshots

Schema snapshots of a source, newest first.

ParameterInTypeRequiredNotes
workspaceIdpathuuidyes
sourceIdpathuuidyes
StatusDescriptionBody
200OKSnapshotDto[]

Anchor Keel is a working product name: one platform, a shared core and licensed modules (Keel Semantic, Keel Migrate). Documentation built from the repository — facts are derived from code, ADRs and the decisions log.