Modify OpenAPI spec POST /admin/realms

Closes #25565

Signed-off-by: Yoshiyuki Tabata <yoshiyuki.tabata.jy@hitachi.com>
This commit is contained in:
Yoshiyuki Tabata 2023-12-18 16:41:23 +09:00 committed by GitHub
parent b371deddb0
commit 5bdadaacbc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -19,6 +19,7 @@ package org.keycloak.services.resources.admin;
import org.eclipse.microprofile.openapi.annotations.Operation;
import org.eclipse.microprofile.openapi.annotations.extensions.Extension;
import org.eclipse.microprofile.openapi.annotations.parameters.Parameter;
import org.eclipse.microprofile.openapi.annotations.responses.APIResponse;
import org.eclipse.microprofile.openapi.annotations.tags.Tag;
import org.jboss.logging.Logger;
import org.jboss.resteasy.annotations.cache.NoCache;
@ -134,6 +135,7 @@ public class RealmsAdminResource {
@Consumes(MediaType.APPLICATION_JSON)
@Tag(name = KeycloakOpenAPI.Admin.Tags.REALMS_ADMIN)
@Operation(summary = "Import a realm. Imports a realm from a full representation of that realm.", description = "Realm name must be unique.")
@APIResponse(responseCode = "201", description = "Created")
public Response importRealm(InputStream requestBody) {
AdminPermissions.realms(session, auth).requireCreateRealm();