apiome import
Global options such as --base-url, --tenant and --json go before the command — see CLI reference. Exit codes are listed in Exit codes.
apiome import
Import OpenAPI, Swagger, Arazzo, JSON Schema, and JSON Schema type documents into Apiome. Any other registered format (see import --list) is importable as import <format> <input>.
apiome import [OPTIONS] COMMAND [ARGS]...
Subcommands: arazzo, auto, git, json-schema, json-schema-type, openapi, preflight, swagger.
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--list | flag | List the registered import sources (formats) and exit. |
apiome import arazzo
Import an Arazzo 1.0 workflow document from a file, URL, or stdin.
apiome import arazzo [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | Arazzo document path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--dry-run | flag | Validate and plan the import without persisting changes. | ||
--project-name | text | Override project name derived from the configured project-name field. | ||
--project-name-field | text | Dot path or JSON Pointer for the field used as the project name (for example info.summary or #/info/summary). Stored as info.x-apiome-project-name-field when omitted from the document. | ||
--version | text | Override version string derived from info.version. | ||
--project-id | uuid | Update an existing project instead of creating from info. | ||
--project-slug | text | Override project slug derived from info.title (DB slug rules). | ||
--version-id | uuid | Attach workflows to this existing project version. | ||
--version-slug | text | Override version slug derived from info.version (DB slug rules). | ||
--publish | text | Publish the imported project version immediately as public or private (tenant-protected). Omit to leave the version as draft. | ||
--visibility | text | Alias for --publish (accepts public or private). | ||
--wait / --no-wait | flag | --wait | Poll async imports until complete (default: wait). | |
--poll-interval | float range | 1.0 | Seconds between GET /imports/{job_id} polls when waiting. |
apiome import auto
Detect document format from headers and run the matching import.
apiome import auto [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | Document path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--dry-run | flag | Validate and plan the import without persisting changes. | ||
--project-name | text | Override project name derived from the configured project-name field (OpenAPI/Arazzo). | ||
--project-name-field | text | Dot path or JSON Pointer for the field used as the project name (for example info.summary or #/info/summary). Stored as info.x-apiome-project-name-field when omitted from the document. (OpenAPI/Arazzo). | ||
--version | text | Override version string derived from info.version (OpenAPI/Arazzo). | ||
--project-id | uuid | Target or link project for the import. | ||
--project-slug | text | Override project slug derived from info.title (OpenAPI/Arazzo). | ||
--version-slug | text | Override version slug derived from info.version (OpenAPI/Arazzo). | ||
--version-id | uuid | Attach Arazzo workflows or JSON Schema to this project version. | ||
--publish | text | Publish the imported project version immediately as public or private (tenant-protected). Omit to leave the version as draft. (OpenAPI/Arazzo). | ||
--visibility | text | Alias for --publish (accepts public or private). (OpenAPI/Arazzo). | ||
--as | property | properties | schema | JSON Schema import target: property, properties, or schema (default: auto-detect). | ||
--name | text | Property, schema, or type name override. | ||
--description | text | Description stored on the imported JSON Schema artifact. | ||
--link-project-property | flag | Create a project_properties row when --project-id is set. | ||
--wait / --no-wait | flag | --wait | Poll async OpenAPI/Arazzo imports until complete (default: wait). | |
--poll-interval | float range | 1.0 | Seconds between GET /imports/{job_id} polls when waiting. | |
--force | flag | With --publish, bypass publish gates (e.g. classes missing required descriptions, breaking changes) so the version still publishes. (OpenAPI/Arazzo). | ||
--import-timeout | float range | Max seconds to wait for an async import job to finish, and the per-request HTTP timeout used while waiting (default 120). Increase for large specs that take longer than the default to import. Overrides the global --timeout for this import. | ||
--min-grade | text | Fail when the lint grade is worse than this (A best, F worst). Exits 4 when the threshold is missed. | ||
--fail-on | text | Fail when the lint report has any finding at or above this severity (error, warning, info). Exits 4 when the threshold is missed. | ||
--bulk | flag | Import every independent spec in an archive or directory (MFI-29.5): auto-detect each one, group the files that compile together, and start one import per spec. PATH must be a .zip/.tar.gz archive or a directory. | ||
--override | text (repeatable) | Override where one item goes, as KEY=SPEC (repeatable). SPEC is 'new' (create a project), 'existing' (append to the item's matched project), 'existing:PROJECT_ID' (append to that project), and may end in '@VERSION' to name the version created. '@VERSION' alone keeps the plan's choice and only sets the label. Items with no override apply the plan as reviewed. (--bulk only) |
apiome import git
Import a repository path or glob at a ref (MFI-29.3).
The server reads the selection at an immutable commit and packs it as the same multi-file payload an archive upload produces, so the import runs the normal pipeline — pre-flight gate included — and the created revision records which repository, ref, and commit it came from.
apiome import git [OPTIONS] REPO_URL
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
REPO_URL | text | yes | Repository URL, for example https://github.com/owner/repo. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--ref | text | Branch, tag, or commit sha (default: the repository's default branch). | ||
--path | text | Path or glob selecting what to import — a directory (protos/), an exact file, or a glob (**/*.proto). Default: the whole tree. | ||
--root | text | Root document inside the selection, when auto-detection is ambiguous. | ||
--format | text | Importer format key (default: the format detected for the root document). | ||
--repository-id | text | Registered repository whose stored credential authorizes a private read. | ||
--linked-account-id | text | Your linked account whose stored credential authorizes a private read. | ||
--dry-run | flag | Validate and preview the import without persisting changes. | ||
--import-timeout | float range | Max seconds to wait for an async import job to finish, and the per-request HTTP timeout used while waiting (default 120). Increase for large specs that take longer than the default to import. Overrides the global --timeout for this import. | ||
--wait / --no-wait | flag | --wait | Poll the import until complete (default: wait). | |
--poll-interval | float range | 1.0 | Seconds between import job-status polls when waiting. | |
--min-grade | text | Fail when the lint grade is worse than this (A best, F worst). Exits 4 when the threshold is missed. | ||
--fail-on | text | Fail when the lint report has any finding at or above this severity (error, warning, info). Exits 4 when the threshold is missed. |
apiome import json-schema
Import a JSON Schema 2020-12 document from a file, URL, or stdin.
apiome import json-schema [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | JSON Schema path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--as | property | properties | schema | Import as property, properties (all $defs entries), or schema (default: auto-detect). | ||
--name | text | Property or schema name when not inferred from the file. | ||
--description | text | Description stored on the property or schema. | ||
--project-id | uuid | Link the import to this project (project_properties when requested). | ||
--version-id | uuid | Link a schema import to this project version. | ||
--link-project-property | flag | Create a project_properties row when --project-id is set. | ||
--dry-run | flag | Validate and plan the import without persisting changes. |
apiome import json-schema-type
Import system-wide JSON Schema type definitions from a file, URL, or stdin.
apiome import json-schema-type [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | JSON Schema type library path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--dry-run | flag | Validate and plan the import without persisting changes. | ||
--name | text | Override inferred type name (single-type imports only). | ||
--description | text | Override description stored on the type (single-type imports only). | ||
--publish | text | Publish imported types to the system-wide library as public, or import private to the caller's tenant only. Omit to default to tenant scope. | ||
--visibility | text | Alias for --publish (accepts public or private). |
apiome import openapi
Import an OpenAPI document from a file, URL, or stdin.
apiome import openapi [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | OpenAPI document path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--dry-run | flag | Validate and plan the import without persisting changes. | ||
--project-name | text | Override project name derived from the configured project-name field. | ||
--project-name-field | text | Dot path or JSON Pointer for the field used as the project name (for example info.summary or #/info/summary). Stored as info.x-apiome-project-name-field when omitted from the document. | ||
--version | text | Override version string derived from info.version. | ||
--project-id | uuid | Update an existing project instead of creating from info. | ||
--project-slug | text | Override project slug derived from info.title (DB slug rules). | ||
--version-slug | text | Override version slug derived from info.version (DB slug rules). | ||
--publish | text | Publish the imported project version immediately as public or private (tenant-protected). Omit to leave the version as draft. | ||
--visibility | text | Alias for --publish (accepts public or private). | ||
--wait / --no-wait | flag | --wait | Poll async imports until complete (default: wait). | |
--poll-interval | float range | 1.0 | Seconds between GET /imports/{job_id} polls when waiting. | |
--force | flag | With --publish, bypass publish gates (e.g. classes missing required descriptions, breaking changes) so the version still publishes. | ||
--import-timeout | float range | Max seconds to wait for an async import job to finish, and the per-request HTTP timeout used while waiting (default 120). Increase for large specs that take longer than the default to import. Overrides the global --timeout for this import. | ||
--min-grade | text | Fail when the lint grade is worse than this (A best, F worst). Exits 4 when the threshold is missed. | ||
--fail-on | text | Fail when the lint report has any finding at or above this severity (error, warning, info). Exits 4 when the threshold is missed. |
apiome import preflight
Score a candidate document before importing it — lint grade, ranked findings, and the tenant quality-policy verdict. Nothing is persisted and no import job is created. Gate exit codes: 3 = tenant quality policy blocked, 4 = --min-grade/--fail-on threshold missed, 5 = nothing gradable (candidate unimportable / no usable target). These are distinct from transport (1) and usage/auth (2) failures.
apiome import preflight [OPTIONS] [INPUT]
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
SOURCE | text | Document path, http/https URL, or '-' for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--file | text | Local document path to import (alternative to the INPUT argument). | ||
--url | text | http/https document URL to import (alternative to the INPUT argument). | ||
--format | text | Registry key of the adapter to score against (source_kind). Omit to auto-detect; the detection verdict is reported either way. | ||
--root | text | Root document path inside a .zip/.tar.gz archive (MFI-29.1). | ||
--target | text | Destination a commit would request: catalog, types, or project. Consulted only for JSON Schema, exactly as on the import job. | ||
--min-grade | text | Fail when the lint grade is worse than this (A best, F worst). Exits 4 when the threshold is missed. | ||
--fail-on | text | Fail when the lint report has any finding at or above this severity (error, warning, info). Exits 4 when the threshold is missed. |
apiome import swagger
Import a Swagger 2.0 document from a file, URL, or stdin.
apiome import swagger [OPTIONS] PATH
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
PATH | text | yes | Swagger 2.0 document path (.json, .yaml, .yml), http/https URL, or - for stdin. |
Options
| Option | Type | Default | Required | Description |
|---|---|---|---|---|
--dry-run | flag | Validate and plan the import without persisting changes. | ||
--project-name | text | Override project name derived from the configured project-name field. | ||
--project-name-field | text | Dot path or JSON Pointer for the field used as the project name (for example info.summary or #/info/summary). Stored as info.x-apiome-project-name-field when omitted from the document. | ||
--version | text | Override version string derived from info.version. | ||
--project-id | uuid | Update an existing project instead of creating from info. | ||
--project-slug | text | Override project slug derived from info.title (DB slug rules). | ||
--version-slug | text | Override version slug derived from info.version (DB slug rules). | ||
--publish | text | Publish the imported project version immediately as public or private (tenant-protected). Omit to leave the version as draft. | ||
--visibility | text | Alias for --publish (accepts public or private). | ||
--wait / --no-wait | flag | --wait | Poll async imports until complete (default: wait). | |
--poll-interval | float range | 1.0 | Seconds between GET /imports/{job_id} polls when waiting. | |
--force | flag | With --publish, bypass publish gates (e.g. classes missing required descriptions, breaking changes) so the version still publishes. | ||
--import-timeout | float range | Max seconds to wait for an async import job to finish, and the per-request HTTP timeout used while waiting (default 120). Increase for large specs that take longer than the default to import. Overrides the global --timeout for this import. | ||
--min-grade | text | Fail when the lint grade is worse than this (A best, F worst). Exits 4 when the threshold is missed. | ||
--fail-on | text | Fail when the lint report has any finding at or above this severity (error, warning, info). Exits 4 when the threshold is missed. |