Skycloak Imports API

The Imports API from Skycloak — 3 operation(s) for imports.

GitHub OpenAPI

Operations 3

POST /clusters/{cluster_id}/realms/import Start a realm import #
POST /clusters/{cluster_id}/realms/import/upload-url Get a presigned URL to upload a realm artifact #
GET /realm-imports/{import_id} Get a realm import #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/skycloak-io:skycloak-io-imports-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

skycloak-io-imports-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Skycloak Public Imports API
  version: '2026-03-01'
  contact:
    name: Skycloak Support
    url: https://support.skycloak.io
  license:
    name: Proprietary
  description: Programmatic management of Keycloak infrastructure on the Skycloak platform.
servers:
- url: http://localhost:8000
  description: Local development
  variables: {}
tags:
- name: Imports
paths:
  /clusters/{cluster_id}/realms/import:
    post:
      operationId: createRealmImport
      summary: Start a realm import
      description: 'Imports a realm (configuration, users, and credentials) into the cluster via the Keycloak Admin

        API. Preflight validates the target Keycloak version, refuses a name collision, and blocks on

        missing password-hash providers. Poll `GET /realm-imports/{import_id}` until `status` is

        `completed` or `failed`.


        Required scope: `clusters:imports:write`'
      parameters:
      - name: cluster_id
        in: path
        required: true
        schema:
          $ref: '#/components/schemas/ClusterId'
      - $ref: '#/components/parameters/CommonParameters'
      responses:
        '202':
          description: Returned when a realm import has been accepted for processing. Poll the resource until `status` is `completed` or `failed`.
          headers:
            Location:
              required: true
              description: URL of the resource being created or modified. Poll this endpoint to track completion.
              schema:
                type: string
                format: uri
            Retry-After:
              required: false
              schema:
                type: integer
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RealmImport'
        '400':
          description: The server could not understand the request due to invalid syntax.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '401':
          description: Access is unauthorized.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '402':
          description: Client error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/PlanLimitErrorBody'
        '403':
          description: Access is forbidden.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '404':
          description: The server cannot find the requested resource.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '409':
          description: The request conflicts with the current state of the server.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '422':
          description: Client error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ValidationErrorBody'
        '429':
          description: Client error
          headers:
            Retry-After:
              required: false
              schema:
                type: integer
            RateLimit-Limit:
              required: false
              schema:
                type: integer
            RateLimit-Remaining:
              required: false
              schema:
                type: integer
            RateLimit-Reset:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Day:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Day:
              required: false
              schema:
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '500':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '501':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
      tags:
      - Imports
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateRealmImportRequest'
      security:
      - ApiKeyAuth: []
      x-scopes:
      - clusters:imports:write
  /clusters/{cluster_id}/realms/import/upload-url:
    post:
      operationId: presignRealmImportUpload
      summary: Get a presigned URL to upload a realm artifact
      description: 'Returns a short-lived presigned PUT URL to upload the realm artifact to, and the object key to

        pass to `createRealmImport` as `upload_s3_key`.


        Required scope: `clusters:imports:write`'
      parameters:
      - name: cluster_id
        in: path
        required: true
        schema:
          $ref: '#/components/schemas/ClusterId'
      - $ref: '#/components/parameters/CommonParameters'
      responses:
        '200':
          description: Presigned URL to upload an import artifact to, plus the object key to pass back to createRealmImport.
          content:
            application/json:
              schema:
                type: object
                properties:
                  upload_url:
                    type: string
                    x-oapi-codegen-extra-tags:
                      validate: omitnil,max=500
                    format: uri
                  s3_key:
                    type: string
                    x-oapi-codegen-extra-tags:
                      validate: omitnil,max=500
                required:
                - upload_url
                - s3_key
        '401':
          description: Access is unauthorized.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '403':
          description: Access is forbidden.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '404':
          description: The server cannot find the requested resource.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '429':
          description: Client error
          headers:
            Retry-After:
              required: false
              schema:
                type: integer
            RateLimit-Limit:
              required: false
              schema:
                type: integer
            RateLimit-Remaining:
              required: false
              schema:
                type: integer
            RateLimit-Reset:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Day:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Day:
              required: false
              schema:
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '500':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '501':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
      tags:
      - Imports
      security:
      - ApiKeyAuth: []
      x-scopes:
      - clusters:imports:write
  /realm-imports/{import_id}:
    get:
      operationId: getRealmImport
      summary: Get a realm import
      description: 'Returns a single realm import. Poll to observe `status` and `progress` until `completed` or `failed`.


        Required scope: `clusters:imports:read`'
      parameters:
      - name: import_id
        in: path
        required: true
        schema:
          $ref: '#/components/schemas/RealmImportId'
      - $ref: '#/components/parameters/CommonParameters'
      responses:
        '200':
          description: The request has succeeded.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RealmImport'
        '401':
          description: Access is unauthorized.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '403':
          description: Access is forbidden.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '404':
          description: The server cannot find the requested resource.
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '429':
          description: Client error
          headers:
            Retry-After:
              required: false
              schema:
                type: integer
            RateLimit-Limit:
              required: false
              schema:
                type: integer
            RateLimit-Remaining:
              required: false
              schema:
                type: integer
            RateLimit-Reset:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Second:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Minute:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Hour:
              required: false
              schema:
                type: integer
            X-RateLimit-Limit-Day:
              required: false
              schema:
                type: integer
            X-RateLimit-Remaining-Day:
              required: false
              schema:
                type: integer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '500':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
        '501':
          description: Server error
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ErrorBody'
      tags:
      - Imports
      security:
      - ApiKeyAuth: []
      x-scopes:
      - clusters:imports:read
components:
  schemas:
    CreateRealmImportRequest:
      type: object
      properties:
        source_kind:
          allOf:
          - $ref: '#/components/schemas/RealmImportSourceKind'
          description: Where the artifact comes from. `upload` (default) or `stored`.
          default: upload
        upload_s3_key:
          type: string
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: Object key of a previously-uploaded artifact (from the upload-url endpoint). Required when `source_kind` is `upload`.
        source_export_id:
          type: string
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: A stored realm export id. Required when `source_kind` is `stored`.
        password:
          type: string
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: Password to decrypt an encrypted artifact. Omit for a bare foreign JSON.
      example:
        source_kind: upload
        upload_s3_key: realm-imports/uploads/ws/abc.zip.enc
        password: a-strong-passphrase
    ValidationErrorBody:
      type: object
      required:
      - type
      - title
      - status
      - detail
      - errors
      properties:
        type:
          type: string
          format: uri
        title:
          type: string
        status:
          type: integer
        detail:
          type: string
        instance:
          type: string
          format: uri
        errors:
          type: array
          items:
            $ref: '#/components/schemas/FieldError'
          minItems: 1
    FieldError:
      type: object
      required:
      - field
      - detail
      properties:
        field:
          type: string
        detail:
          type: string
        code:
          type: string
        value: {}
    ExportStatus:
      type: string
      enum:
      - pending
      - processing
      - completed
      - failed
    ClusterId:
      type: string
      format: uuid
    RealmImportId:
      type: string
      format: uuid
    RealmImport:
      type: object
      required:
      - id
      - cluster_id
      - realm
      - source_kind
      - status
      - progress
      - created_at
      properties:
        id:
          $ref: '#/components/schemas/RealmImportId'
        cluster_id:
          $ref: '#/components/schemas/ClusterId'
        realm:
          type: string
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: The imported realm's name, derived from the artifact.
        source_kind:
          $ref: '#/components/schemas/RealmImportSourceKind'
        status:
          $ref: '#/components/schemas/ExportStatus'
        progress:
          type: integer
          description: Percent complete, 0-100.
        source_version:
          type:
          - string
          - 'null'
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: Keycloak version that produced the artifact.
        target_version:
          type:
          - string
          - 'null'
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: Target cluster's Keycloak version at import time.
        error_message:
          type:
          - string
          - 'null'
          x-oapi-codegen-extra-tags:
            validate: omitnil,max=500
          description: Failure description. Only set when `status` is `failed`.
        created_at:
          type: string
          format: date-time
        completed_at:
          type:
          - string
          - 'null'
          format: date-time
      example:
        id: 7b1c2d3e-4f5a-6b7c-8d9e-0f1a2b3c4d5e
        cluster_id: a1b2c3d4-e5f6-7890-abcd-ef1234567890
        realm: cust-brasilia
        source_kind: upload
        status: completed
        progress: 100
        source_version: 26.6.1
        target_version: 26.6.2
        error_message: null
        created_at: '2026-07-19T15:00:00Z'
        completed_at: '2026-07-19T15:03:00Z'
    RealmImportSourceKind:
      type: string
      enum:
      - upload
      - stored
    Versions:
      type: string
      enum:
      - 2026-06-01.beta
    ErrorBody:
      type: object
      required:
      - type
      - title
      - status
      - detail
      properties:
        type:
          type: string
          format: uri
        title:
          type: string
        status:
          type: integer
        detail:
          type: string
        instance:
          type: string
          format: uri
      description: RFC 9457 Problem Details object.
    PlanLimitErrorBody:
      type: object
      required:
      - type
      - title
      - status
      - detail
      - current_plan
      - required_plan
      properties:
        type:
          type: string
          format: uri
        title:
          type: string
        status:
          type: integer
        detail:
          type: string
        instance:
          type: string
          format: uri
        current_plan:
          type: string
        required_plan:
          type: string
        code:
          type: string
          description: 'Machine-readable identifier of the quota that was hit, so a client can tell

            quotas apart without parsing `detail`. Known values include `cluster_limit`

            (the workspace''s total cluster allowance), `cluster_size_quota` (the

            allowance for the requested cluster size) and `cluster_size` (the requested

            size is not offered on the plan at all). New values may be added.'
        current_usage:
          type: integer
          description: How many of the resource the workspace currently has.
        current_limit:
          type: integer
          description: Maximum allowed by the current plan. `0` means the plan does not include the resource at all.
      description: Returned when a workspace plan quota would be exceeded. `required_plan` indicates the minimum plan needed to complete the request.
  parameters:
    CommonParameters:
      name: API-Version
      in: header
      required: true
      schema:
        $ref: '#/components/schemas/Versions'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: API-Key