Skycloak Realm Users API
The Realm Users API from Skycloak — 2 operation(s) for realm users.
The Realm Users API from Skycloak — 2 operation(s) for realm users.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
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.curl "https://apis.io/api/v1/apis/skycloak-io:skycloak-io-realm-users-api"
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.
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: 3.2.0
info:
title: Skycloak Public Realm Users 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: Realm Users
paths:
/clusters/{cluster_id}/realms/{realm_name}/users:
get:
operationId: listRealmUsers
summary: List realm users
description: 'Returns users in the specified realm.
Required scope: `realm-users:read`'
parameters:
- name: cluster_id
in: path
required: true
schema:
$ref: '#/components/schemas/ClusterId'
- name: realm_name
in: path
required: true
schema:
$ref: '#/components/schemas/RealmName'
- name: search
in: query
required: false
schema:
type: string
minLength: 1
maxLength: 256
explode: false
- name: status
in: query
required: false
schema:
allOf:
- $ref: '#/components/schemas/RealmUserStatus'
default: all
explode: false
- name: limit
in: query
required: false
schema:
allOf:
- $ref: '#/components/schemas/PageLimit'
default: 25
explode: false
- name: offset
in: query
required: false
schema:
allOf:
- $ref: '#/components/schemas/PageOffset'
default: 0
explode: false
- name: order
in: query
required: false
schema:
allOf:
- $ref: '#/components/schemas/SortOrder'
default: asc
explode: false
- $ref: '#/components/parameters/CommonParameters'
responses:
'200':
description: The request has succeeded.
headers:
Total-Count:
required: true
description: Total number of results across all pages, before pagination is applied.
schema:
type: integer
Link:
required: false
description: RFC 8288 Link header containing `next`, `prev`, `first`, and `last` relations.
schema:
type: string
content:
application/json:
schema:
type: array
items:
$ref: '#/components/schemas/RealmUser'
'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'
'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:
- Realm Users
security:
- ApiKeyAuth: []
x-scopes:
- realm-users:read
post:
operationId: createRealmUser
summary: Create a realm user
description: 'Creates a user in the specified realm.
Required scope: `realm-users:write`'
parameters:
- name: cluster_id
in: path
required: true
schema:
$ref: '#/components/schemas/ClusterId'
- name: realm_name
in: path
required: true
schema:
$ref: '#/components/schemas/RealmName'
- $ref: '#/components/parameters/CommonParameters'
responses:
'201':
description: The request has succeeded and a new resource has been created as a result.
content:
application/json:
schema:
$ref: '#/components/schemas/RealmUser'
'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'
'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:
- Realm Users
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/CreateRealmUserRequest'
security:
- ApiKeyAuth: []
x-scopes:
- realm-users:write
/clusters/{cluster_id}/realms/{realm_name}/users/{user_id}:
get:
operationId: getRealmUser
summary: Get a realm user
description: 'Returns a single user from the specified realm.
Required scope: `realm-users:read`'
parameters:
- name: cluster_id
in: path
required: true
schema:
$ref: '#/components/schemas/ClusterId'
- name: realm_name
in: path
required: true
schema:
$ref: '#/components/schemas/RealmName'
- name: user_id
in: path
required: true
schema:
$ref: '#/components/schemas/RealmUserId'
- $ref: '#/components/parameters/CommonParameters'
responses:
'200':
description: The request has succeeded.
content:
application/json:
schema:
$ref: '#/components/schemas/RealmUser'
'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:
- Realm Users
security:
- ApiKeyAuth: []
x-scopes:
- realm-users:read
patch:
operationId: updateRealmUser
summary: Update a realm user
description: 'Partially updates a realm user.
Required scope: `realm-users:write`'
parameters:
- name: cluster_id
in: path
required: true
schema:
$ref: '#/components/schemas/ClusterId'
- name: realm_name
in: path
required: true
schema:
$ref: '#/components/schemas/RealmName'
- name: user_id
in: path
required: true
schema:
$ref: '#/components/schemas/RealmUserId'
- $ref: '#/components/parameters/CommonParameters'
responses:
'200':
description: The request has succeeded.
content:
application/json:
schema:
$ref: '#/components/schemas/RealmUser'
'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'
'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:
- Realm Users
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/UpdateRealmUserRequest'
security:
- ApiKeyAuth: []
x-scopes:
- realm-users:write
delete:
operationId: deleteRealmUser
summary: Delete a realm user
description: 'Deletes the specified user from the realm.
Required scope: `realm-users:write`'
parameters:
- name: cluster_id
in: path
required: true
schema:
$ref: '#/components/schemas/ClusterId'
- name: realm_name
in: path
required: true
schema:
$ref: '#/components/schemas/RealmName'
- name: user_id
in: path
required: true
schema:
$ref: '#/components/schemas/RealmUserId'
- $ref: '#/components/parameters/CommonParameters'
responses:
'204':
description: There is no content to send for this request, but the headers may be useful.
'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:
- Realm Users
security:
- ApiKeyAuth: []
x-scopes:
- realm-users:write
components:
schemas:
Versions:
type: string
enum:
- 2026-06-01.beta
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
RealmUser:
type: object
required:
- id
- username
- email
- enabled
properties:
id:
allOf:
- $ref: '#/components/schemas/RealmUserId'
example: 9f3f2e5c-9e3d-4b1d-9f53-2a8af5a5d9a1
username:
allOf:
- $ref: '#/components/schemas/RealmUsername'
example: john.doe
email:
allOf:
- $ref: '#/components/schemas/EmailAddress'
example: john@example.com
first_name:
type: string
example: John
last_name:
type: string
example: Doe
enabled:
type: boolean
description: Whether the user can sign in.
example: true
email_verified:
type: boolean
description: Whether the email address has been verified.
example: true
organization:
type: string
description: Organization associated with the user, when available.
example: Acme Corp
last_login_at:
type: string
format: date-time
description: Most recent successful sign-in time, when available.
created_at:
type: string
format: date-time
description: Time when the user was created, when available.
description: Public representation of a realm user.
example:
id: 9f3f2e5c-9e3d-4b1d-9f53-2a8af5a5d9a1
username: john.doe
email: john@example.com
first_name: John
last_name: Doe
enabled: true
email_verified: true
organization: Acme Corp
RealmUserStatus:
type: string
enum:
- all
- enabled
- disabled
RealmUsername:
type: string
minLength: 3
maxLength: 255
pattern: ^[A-Za-z0-9._@-]+$
description: Realm username. Allows letters, digits, dots, hyphens, underscores, and `@`.
example: john.doe
FieldError:
type: object
required:
- field
- detail
properties:
field:
type: string
detail:
type: string
code:
type: string
value: {}
SortOrder:
type: string
enum:
- asc
- desc
description: Sort direction.
ClusterId:
type: string
format: uuid
PageOffset:
type: integer
minimum: 0
RealmUserId:
type: string
minLength: 1
maxLength: 255
example: 9f3f2e5c-9e3d-4b1d-9f53-2a8af5a5d9a1
UpdateRealmUserRequest:
type: object
properties:
email:
allOf:
- $ref: '#/components/schemas/EmailAddress'
example: jane@example.com
first_name:
type: string
maxLength: 255
example: Jane
last_name:
type: string
maxLength: 255
example: Doe
enabled:
type: boolean
description: Whether the user can sign in.
example: true
email_verified:
type: boolean
description: Whether the email address has been verified.
example: true
description: Patch request for updating a realm user. At least one field should be provided.
example:
first_name: Jane
last_name: Doe
enabled: true
email_verified: true
RealmRoleName:
type: string
minLength: 1
maxLength: 255
pattern: ^[A-Za-z0-9._:@-]+$
description: Role name.
example: admin
PageLimit:
type: integer
minimum: 1
maximum: 100
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.
RealmName:
type: string
minLength: 1
maxLength: 63
pattern: ^[a-zA-Z][a-zA-Z0-9-]*$
description: Keycloak realm name (not ID). Must start with a letter; allows letters, digits, and hyphens.
example: customer-portal
CreateRealmUserRequest:
type: object
required:
- username
- email
- temporary_password
properties:
username:
allOf:
- $ref: '#/components/schemas/RealmUsername'
example: john.doe
email:
allOf:
- $ref: '#/components/schemas/EmailAddress'
example: john@example.com
first_name:
type: string
maxLength: 255
example: John
last_name:
type: string
maxLength: 255
example: Doe
temporary_password:
type: string
minLength: 8
format: password
description: 'Initial password set for the user. Must be at least 8 characters.
Additional constraints are enforced by the realm''s Keycloak password policy at the time
of creation (e.g. minimum uppercase/lowercase/digit/special-character counts, disallow
reuse, disallow username/email as password). Password policy violations return `422`
with a message describing the specific rule that was not met.'
example: ChangeMe123
enabled:
type: boolean
description: Whether the user can sign in immediately after creation.
example: true
default: true
roles:
type: array
items:
$ref: '#/components/schemas/RealmRoleName'
description: Realm roles to assign after the user is created.
example:
- admin
description: Request body for creating a realm user.
example:
username: john.doe
email: john@example.com
first_name: John
last_name: Doe
temporary_password: ChangeMe123
enabled: true
roles:
- admin
EmailAddress:
type: string
format: email
example: john@example.com
parameters:
CommonParameters:
name: API-Version
in: header
required: true
schema:
$ref: '#/components/schemas/Versions'
securitySchemes:
ApiKeyAuth:
type: apiKey
in: header
name: API-Key