Skip to content

Create OCI registry

POST
/api/v1/registries/oci
curl --request POST \
--url http://localhost:3000/api/v1/registries/oci \
--header 'Content-Type: application/json' \
--header 'X-API-Key: <X-API-Key>' \
--data '{ "name": "my-container-registry", "description": "Production container images", "url": "https://registry.example.com", "registryType": "GENERIC", "authType": "NONE", "credential": "username:password", "verifyTls": true, "enabled": true, "repositories": [ "library/nginx", "team/app" ] }'

Creates a new OCI registry for the current organization.

Media type application/json
object
name
required

Unique name for the registry within the organization

string
>= 2 characters <= 100 characters
Example
my-container-registry
description

Description of the registry

string
<= 500 characters
Example
Production container images
url
required

OCI registry URL

string
Example
https://registry.example.com
registryType

Registry type

string
default: GENERIC
Allowed values: GENERIC
Example
GENERIC
authType

Authentication type

string
default: NONE
Allowed values: NONE BASIC TOKEN
Example
NONE
credential

Credential for authentication. Will be encrypted at rest. For BASIC auth this MUST be “username:password”. For TOKEN auth it is the raw token.

string
Example
username:password
verifyTls

Whether to verify TLS certificates

boolean
default: true
Example
true
enabled

Whether the registry is enabled

boolean
default: true
Example
true
repositories

Explicit repository list. When provided, sync uses these repositories directly and skips /v2/_catalog discovery (useful when _catalog requires authentication that is not configured).

Array<string>
Example
[
"library/nginx",
"team/app"
]

OCI registry created successfully

Media type application/json
object
id
required

Unique identifier

string
organizationId
required

Organization ID that owns this registry

string
name
required

Registry name

string
description

Registry description

string
nullable
url
required

OCI registry URL

string
registryType
required

Registry type

string
Allowed values: GENERIC
authType
required

Authentication type

string
Allowed values: NONE BASIC TOKEN
hasCredentials
required

Whether credentials are configured

boolean
verifyTls
required

Whether TLS verification is enabled

boolean
lastHealthCheck

Last health check timestamp

string format: date-time
nullable
healthStatus

Health status (healthy, unhealthy, unknown)

string
nullable
lastSyncAt

Last sync timestamp

string format: date-time
nullable
lastSyncError

Last sync error message

string
nullable
syncIntervalMinutes
required

Sync interval in minutes

number
enabled
required

Whether the registry is enabled

boolean
repositories
required

Explicit repository list used for sync. When non-empty, /v2/_catalog discovery is skipped.

Array<string>
createdAt
required

Creation timestamp

string format: date-time
updatedAt
required

Last update timestamp

string format: date-time
Example
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"organizationId": "550e8400-e29b-41d4-a716-446655440001",
"name": "my-container-registry",
"description": "Production container images",
"url": "https://registry.example.com",
"registryType": "GENERIC",
"authType": "NONE",
"hasCredentials": false,
"verifyTls": true,
"lastHealthCheck": "2024-01-15T10:30:00Z",
"healthStatus": "healthy",
"lastSyncAt": "2024-01-15T10:30:00Z",
"syncIntervalMinutes": 60,
"enabled": true,
"repositories": [],
"createdAt": "2024-01-01T00:00:00Z",
"updatedAt": "2024-01-15T10:30:00Z"
}

Invalid input data

Unauthorized

Forbidden

Registry with this name already exists