Interface AdminResource
-
Method Summary
Modifier and TypeMethodDescriptioncreateGitOpsValidateTask(@NotNull GitOpsValidateRequest data) Experimental. Creates a dry-run validation task that fetches a git ref and validates the data without affecting the live registry.voidcreateGlobalRule(@NotNull CreateRule data) Adds a rule to the list of globally configured rules.voidcreateRoleMapping(@NotNull RoleMapping data) Creates a new mapping between a user/principal and a role.voidDeletes all globally configured rules.voiddeleteGitOpsValidateTask(String taskId) Experimental. Deletes a validation task and cleans up its checkout directory.voidDeletes the global contract ruleset.voiddeleteGlobalRule(RuleType ruleType) Deletes a single global rule.voiddeleteRoleMapping(String principalId) Deletes a single role mapping, effectively denying access to a user/principal.jakarta.ws.rs.core.ResponseexportData(Boolean forBrowser, String groupId) Exports registry data as a ZIP archive.getArtifactUsageMetrics(String groupId, String artifactId) getConfigProperty(String propertyName) Returns the value of a single configuration property.getConsumerVersionHeatmap(String groupId, String artifactId) getDeprecationReadiness(String groupId, String artifactId, String version) Experimental. Returns the current synchronization status of the GitOps storage, including the current commit SHA, sync state, load statistics, and any errors from the last sync attempt.getGitOpsValidateTask(String taskId) Experimental. Returns the status and results of a specific dry-run validation task.Returns the global contract ruleset that applies to all artifacts.getGlobalRuleConfig(RuleType ruleType) Returns information about the named globally configured rule.getRoleMapping(String principalId) Gets the details of a single role mapping (byprincipalId).voidimportData(Boolean xRegistryPreserveGlobalId, Boolean xRegistryPreserveContentId, Boolean requireEmptyRegistry, @NotNull InputStream data) Imports registry data that was previously exported using the/admin/exportoperation.Gets a list of all the configured artifact types.Returns a list of all configuration properties that have been set.Experimental. Returns a list of all active dry-run validation tasks.Gets a list of all the currently configured global rules (if any).listRoleMappings(BigInteger limit, BigInteger offset) Gets a list of all role mappings configured in the registry (if any).voidresetConfigProperty(String propertyName) Resets the value of a single configuration property.setGlobalContractRuleset(@NotNull ContractRuleSet data) Sets the global contract ruleset that applies to all artifacts.voidExperimental. Requests an immediate synchronization of the GitOps storage.Triggers the creation of a snapshot of the internal database for compatible storages.voidupdateConfigProperty(String propertyName, @NotNull UpdateConfigurationProperty data) Updates the value of a single configuration property.updateGlobalRuleConfig(RuleType ruleType, @NotNull Rule data) Updates the configuration for a globally configured rule.voidupdateRoleMapping(String principalId, @NotNull UpdateRole data) Updates a single role mapping for one user/principal.
-
Method Details
-
listGlobalRules
Gets a list of all the currently configured global rules (if any).
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
createGlobalRule
@Path("/rules") @POST @Consumes("application/json") void createGlobalRule(@NotNull @NotNull CreateRule data) Adds a rule to the list of globally configured rules.
This operation can fail for the following reasons:
- The rule type is unknown (HTTP error
400) - The rule already exists (HTTP error
409) - A server error occurred (HTTP error
500)
- The rule type is unknown (HTTP error
-
deleteAllGlobalRules
@Path("/rules") @DELETE void deleteAllGlobalRules()Deletes all globally configured rules.
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
getGlobalRuleConfig
@Path("/rules/{ruleType}") @GET @Produces("application/json") Rule getGlobalRuleConfig(@PathParam("ruleType") RuleType ruleType) Returns information about the named globally configured rule.
This operation can fail for the following reasons:
- Invalid rule name/type (HTTP error
400) - No rule with name/type
ruleexists (HTTP error404) - A server error occurred (HTTP error
500)
- Invalid rule name/type (HTTP error
-
updateGlobalRuleConfig
@Path("/rules/{ruleType}") @PUT @Produces("application/json") @Consumes("application/json") Rule updateGlobalRuleConfig(@PathParam("ruleType") RuleType ruleType, @NotNull @NotNull Rule data) Updates the configuration for a globally configured rule.
This operation can fail for the following reasons:
- Invalid rule name/type (HTTP error
400) - No rule with name/type
ruleexists (HTTP error404) - A server error occurred (HTTP error
500)
- Invalid rule name/type (HTTP error
-
deleteGlobalRule
Deletes a single global rule. If this is the only rule configured, this is the same as deleting all rules.
This operation can fail for the following reasons:
- Invalid rule name/type (HTTP error
400) - No rule with name/type
ruleexists (HTTP error404) - Rule cannot be deleted (HTTP error
409) - A server error occurred (HTTP error
500)
- Invalid rule name/type (HTTP error
-
exportData
@Path("/export") @GET @Produces({"application/json","application/zip"}) jakarta.ws.rs.core.Response exportData(@QueryParam("forBrowser") Boolean forBrowser, @QueryParam("groupId") String groupId) Exports registry data as a ZIP archive. If a
groupIdquery parameter is provided, only data belonging to the specified group will be exported and global rules will be excluded. -
importData
@Path("/import") @POST @Consumes("application/zip") void importData(@HeaderParam("X-Registry-Preserve-GlobalId") Boolean xRegistryPreserveGlobalId, @HeaderParam("X-Registry-Preserve-ContentId") Boolean xRegistryPreserveContentId, @QueryParam("requireEmptyRegistry") Boolean requireEmptyRegistry, @NotNull @NotNull InputStream data) Imports registry data that was previously exported using the
/admin/exportoperation. -
getRoleMapping
@Path("/roleMappings/{principalId}") @GET @Produces("application/json") RoleMapping getRoleMapping(@PathParam("principalId") String principalId) Gets the details of a single role mapping (by
principalId).This operation can fail for the following reasons:
- No role mapping for the
principalIdexists (HTTP error404) - A server error occurred (HTTP error
500)
- No role mapping for the
-
updateRoleMapping
@Path("/roleMappings/{principalId}") @PUT @Consumes("application/json") void updateRoleMapping(@PathParam("principalId") String principalId, @NotNull @NotNull UpdateRole data) Updates a single role mapping for one user/principal.
This operation can fail for the following reasons:
- No role mapping for the principalId exists (HTTP error
404) - A server error occurred (HTTP error
500)
- No role mapping for the principalId exists (HTTP error
-
deleteRoleMapping
@Path("/roleMappings/{principalId}") @DELETE void deleteRoleMapping(@PathParam("principalId") String principalId) Deletes a single role mapping, effectively denying access to a user/principal.
This operation can fail for the following reasons:
- No role mapping for the principalId exists (HTTP error
404) - A server error occurred (HTTP error
500)
- No role mapping for the principalId exists (HTTP error
-
listConfigProperties
@Path("/config/properties") @GET @Produces("application/json") List<ConfigurationProperty> listConfigProperties()Returns a list of all configuration properties that have been set. The list is not paged.
This operation may fail for one of the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
getConfigProperty
@Path("/config/properties/{propertyName}") @GET @Produces("application/json") ConfigurationProperty getConfigProperty(@PathParam("propertyName") String propertyName) Returns the value of a single configuration property.
This operation may fail for one of the following reasons:
- Property not found or not configured (HTTP error
404) - A server error occurred (HTTP error
500)
- Property not found or not configured (HTTP error
-
updateConfigProperty
@Path("/config/properties/{propertyName}") @PUT @Consumes("application/json") void updateConfigProperty(@PathParam("propertyName") String propertyName, @NotNull @NotNull UpdateConfigurationProperty data) Updates the value of a single configuration property.
This operation may fail for one of the following reasons:
- Property not found or not configured (HTTP error
404) - A server error occurred (HTTP error
500)
- Property not found or not configured (HTTP error
-
resetConfigProperty
@Path("/config/properties/{propertyName}") @DELETE void resetConfigProperty(@PathParam("propertyName") String propertyName) Resets the value of a single configuration property. This will return the property to its default value (see external documentation for supported properties and their default values).
This operation may fail for one of the following reasons:
- Property not found or not configured (HTTP error
404) - A server error occurred (HTTP error
500)
- Property not found or not configured (HTTP error
-
listRoleMappings
@Path("/roleMappings") @GET @Produces("application/json") RoleMappingSearchResults listRoleMappings(@QueryParam("limit") BigInteger limit, @QueryParam("offset") BigInteger offset) Gets a list of all role mappings configured in the registry (if any).
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
createRoleMapping
@Path("/roleMappings") @POST @Consumes("application/json") void createRoleMapping(@NotNull @NotNull RoleMapping data) Creates a new mapping between a user/principal and a role.
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
listArtifactTypes
@Path("/config/artifactTypes") @GET @Produces("application/json") List<ArtifactTypeInfo> listArtifactTypes()Gets a list of all the configured artifact types.
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
getGlobalContractRuleset
@Path("/contracts/ruleset") @GET @Produces("application/json") ContractRuleSet getGlobalContractRuleset()Returns the global contract ruleset that applies to all artifacts.
-
setGlobalContractRuleset
@Path("/contracts/ruleset") @PUT @Produces("application/json") @Consumes("application/json") ContractRuleSet setGlobalContractRuleset(@NotNull @NotNull ContractRuleSet data) Sets the global contract ruleset that applies to all artifacts.
-
deleteGlobalContractRuleset
@Path("/contracts/ruleset") @DELETE void deleteGlobalContractRuleset()Deletes the global contract ruleset.
-
triggerSnapshot
Triggers the creation of a snapshot of the internal database for compatible storages.
This operation can fail for the following reasons:
- A server error occurred (HTTP error
500)
- A server error occurred (HTTP error
-
getGitOpsStatus
Experimental. Returns the current synchronization status of the GitOps storage, including the current commit SHA, sync state, load statistics, and any errors from the last sync attempt.
This endpoint is only available when GitOps storage is enabled (
apicurio.storage.kind=gitops). Returns HTTP 409 (Conflict) if a different storage backend is active.This operation can fail for the following reasons:
- GitOps storage is not enabled (HTTP error
409) - A server error occurred (HTTP error
500)
- GitOps storage is not enabled (HTTP error
-
triggerGitOpsSync
@Path("/gitops/sync") @POST void triggerGitOpsSync()Experimental. Requests an immediate synchronization of the GitOps storage. This resets the poll timer so the next scheduler cycle will poll the Git repository without waiting for the configured poll period.
The synchronization happens asynchronously — this endpoint returns immediately and the actual sync occurs on the next scheduler cycle.
This endpoint is only available when GitOps storage is enabled (
apicurio.storage.kind=gitops). Returns HTTP 409 (Conflict) if a different storage backend is active.This operation can fail for the following reasons:
- GitOps storage is not enabled (HTTP error
409) - A server error occurred (HTTP error
500)
- GitOps storage is not enabled (HTTP error
-
listGitOpsValidateTasks
@Path("/gitops/validate") @GET @Produces("application/json") List<GitOpsValidateTask> listGitOpsValidateTasks()Experimental. Returns a list of all active dry-run validation tasks.
-
createGitOpsValidateTask
@Path("/gitops/validate") @POST @Produces("application/json") @Consumes("application/json") GitOpsValidateTask createGitOpsValidateTask(@NotNull @NotNull GitOpsValidateRequest data) Experimental. Creates a dry-run validation task that fetches a git ref and validates the data without affecting the live registry. The sidecar fetches the ref, and the registry loads and validates the data in the inactive storage (no swap).
Returns a task object with a
taskIdthat can be used to poll for results.This endpoint is only available when GitOps storage is enabled.
This operation can fail for the following reasons:
- GitOps storage is not enabled (HTTP error
409) - Dry-run validation is disabled (HTTP error
503) - A server error occurred (HTTP error
500)
- GitOps storage is not enabled (HTTP error
-
getGitOpsValidateTask
@Path("/gitops/validate/{taskId}") @GET @Produces("application/json") GitOpsValidateTask getGitOpsValidateTask(@PathParam("taskId") String taskId) Experimental. Returns the status and results of a specific dry-run validation task.
-
deleteGitOpsValidateTask
@Path("/gitops/validate/{taskId}") @DELETE void deleteGitOpsValidateTask(@PathParam("taskId") String taskId) Experimental. Deletes a validation task and cleans up its checkout directory.
-
getUsageSummary
-
getArtifactUsageMetrics
@Path("/usage/artifacts/{groupId}/{artifactId}") @GET @Produces("application/json") ArtifactUsageMetrics getArtifactUsageMetrics(@PathParam("groupId") String groupId, @PathParam("artifactId") String artifactId) -
getConsumerVersionHeatmap
@Path("/usage/artifacts/{groupId}/{artifactId}/heatmap") @GET @Produces("application/json") ConsumerVersionHeatmap getConsumerVersionHeatmap(@PathParam("groupId") String groupId, @PathParam("artifactId") String artifactId) -
getDeprecationReadiness
@Path("/usage/artifacts/{groupId}/{artifactId}/versions/{version}/deprecation-readiness") @GET @Produces("application/json") DeprecationReadiness getDeprecationReadiness(@PathParam("groupId") String groupId, @PathParam("artifactId") String artifactId, @PathParam("version") String version)
-