Skip to main content
Cloud has the newest features. Some may not be in a release yet; the newest release is Identity & Access Management 7.3.0.

User store management API

Download OpenAPI (YAML)Version v1

Base URL: https://api.asgardeo.io/t/<ROOT_ORGANIZATION_NAME>/o/api/server/v1

The WSO2 Identity Platform - UserStore Management Rest API (version v1).

Download the OpenAPI definition (YAML)

Security schemes​

OAuth2: oauth2

authorizationCode flow, token URL https://api.asgardeo.io/t/{root-organization-name}/oauth/token, authorization URL https://api.asgardeo.io/t/{root-organization-name}/oauth/authorize

User Store​

Retrieve the list of secondary user stores​

GET /userstores

This API provides the capability to list the configured secondary user stores.

Scope(Permission) required: internal_org_userstore_view

Parameters

NameInTypeRequiredDescription
limitqueryinteger (int32)

maximum number of records to return

offsetqueryinteger (int32)

number of records to skip for pagination

filterquerystring

Condition to filter the retrieval of records.

sortquerystring

Define the order of how the retrieved records should be sorted.

requiredAttributesquerystring

Define set of user store attributes (as comma separated) to be returned.

Responses

CodeDescriptionSchema
200

Successful response.

array of UserStoreListResponse
401

Unauthorized.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error
501

Not Implemented.

Error

Add a secondary user store.​

POST /userstores

This API provides the capability to add a secondary user store.

NOTE:

To retrieve the available user store classes/types, use the /o/api/server/v1/userstores/meta/types API.

When creating a user store, it will be disabled by default. To enable the user store, include the disabled property set to false in the properties of the payload.

Scope(Permission) required: internal_org_userstore_create

Request body: application/json

Secondary user store to add.

Schema: UserStoreReq

5 properties
NameTypeRequiredDescription
typeIdstringYes

The id of the user store manager class type.

descriptionstringYes

Description of the user store.

namestringYes

This is a unique name that identifies the user store.

propertiesarray of PropertyYes

Various properties related to the user store such as connection URL, connection password etc.

claimAttributeMappingsarray of ClaimAttributeMapping

Claim attribute mappings.

Responses

CodeDescriptionSchema
201

Successful response

UserStoreResponse
400

Invalid input request.

Error
401

Unauthorized.

403

Resource Forbidden.

409

Element Already Exists.

Error
500

Internal Server Error.

Error

Retrieve the configurations of secondary user store based on its domain id​

GET /userstores/{userstore-domain-id}

This API provides the capability to retrieve the configurations of a secondary user store based on its domain id.

Scope(Permission) required: internal_org_userstore_view

Parameters

NameInTypeRequiredDescription
userstore-domain-idpathstringYes

The unique name of the user store domain

Responses

CodeDescriptionSchema
200

Successful response.

UserStoreConfigurationsRes
401

Unauthorized.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error

Update a user store by its domain id​

PUT /userstores/{userstore-domain-id}

This API provides the capability to edit a user store based on its domain id

Scope(Permission) required: internal_org_userstore_update

Parameters

NameInTypeRequiredDescription
userstore-domain-idpathstringYes

Current domain id of the user store

Request body: application/json

The secondary user store values which are needed to be edited for a given domain id.

Schema: UserStoreReq

5 properties
NameTypeRequiredDescription
typeIdstringYes

The id of the user store manager class type.

descriptionstringYes

Description of the user store.

namestringYes

This is a unique name that identifies the user store.

propertiesarray of PropertyYes

Various properties related to the user store such as connection URL, connection password etc.

claimAttributeMappingsarray of ClaimAttributeMapping

Claim attribute mappings.

Responses

CodeDescriptionSchema
200

Successful response.

UserStoreResponse
400

Invalid input request.

Error
401

Unauthorized.

403

Resource Forbidden.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error

Delete a secondary user store​

DEL /userstores/{userstore-domain-id}

This API provides the capability to delete a secondary user store based on matching to the given user store domain id.

Scope(Permission) required: internal_org_userstore_delete

Parameters

NameInTypeRequiredDescription
userstore-domain-idpathstringYes

The unique name of the user store domain

Responses

CodeDescriptionSchema
204

No Content.

401

Unauthorized.

403

Resource Forbidden.

500

Internal Server Error.

Error

Patch the secondary user store by it's domain id​

PATCH /userstores/{userstore-domain-id}

This API provides the capability to update the secondary user store's property using patch request by using its domain id.

Scope(Permission) required: internal_org_userstore_update

Parameters

NameInTypeRequiredDescription
userstore-domain-idpathstringYes

The unique name of the user store domain

Request body (required): application/json

Schema: PatchRequest

Responses

CodeDescriptionSchema
200

Successful response.

UserStoreResponse
400

Invalid input request.

Error
401

Unauthorized.

403

Resource Forbidden.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error

Update the secondary user store attribute mappings by it's domain id.​

PATCH /userstores/{userstore-domain-id}/attribute-mappings

This API provides the capability to update the secondary user store's attribute mappings using patch request by using its domain id.

Scope(Permission) required: internal_org_userstore_update

Parameters

NameInTypeRequiredDescription
userstore-domain-idpathstringYes

The unique name of the user store domain

Request body (required): application/json

Schema: AttributeMappingsReq

Responses

CodeDescriptionSchema
200

OK.

400

Invalid input request.

Error
401

Unauthorized.

403

Resource Forbidden.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error

Meta​

Retrieve the available user store classes/types​

GET /userstores/meta/types

This API provides the capability to retrieve the available user store types

Scope(Permission) required: internal_org_userstore_view

Responses

CodeDescriptionSchema
200

Successful Response.

array of AvailableUserStoreClassesRes
401

Unauthorized.

500

Internal Server Error.

Error

Retrieve the properties of secondary user store of a given user store type​

GET /userstores/meta/types/{type-id}

This API provides the capability to retrieve the properties of secondary user store of a given class name.

Scope(Permission) required: internal_org_userstore_view

Parameters

NameInTypeRequiredDescription
type-idpathstringYes

Id of the user store type

Responses

CodeDescriptionSchema
200

Successful response.

MetaUserStoreType
400

Invalid input request.

Error
401

Unauthorized.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error
501

Not Implemented.

Error

Retrieve the meta attributes of a user store of a given user store type.​

GET /userstores/meta/types/{type-id}/attributes

This API provides the capability to retrieve the attribute mappings of a given user store type.

Scope(Permission) required: internal_org_userstore_view

Parameters

NameInTypeRequiredDescription
type-idpathstringYes

Id of the user store type

includeIdentityClaimMappingsqueryboolean

Whether to include the identity claim mappings with user store attributes.

Responses

CodeDescriptionSchema
200

Successful Response.

UserStoreAttributeMappingResponse
400

Invalid input request.

Error
401

Unauthorized.

403

Resource Forbidden.

404

The specified resource is not found.

Error
500

Internal Server Error.

Error

Schemas​

UserStoreReq​

Type: object

Secondary user store request.

5 properties
NameTypeRequiredDescription
typeIdstringYes

The id of the user store manager class type.

descriptionstringYes

Description of the user store.

namestringYes

This is a unique name that identifies the user store.

propertiesarray of PropertyYes

Various properties related to the user store such as connection URL, connection password etc.

claimAttributeMappingsarray of ClaimAttributeMapping

Claim attribute mappings.

PatchRequest​

Type: array of PatchDocument

PatchDocument​

Type: object

A JSONPatch document as defined by RFC 6902

3 properties
NameTypeRequiredDescription
operationstringYes

The operation to be performed

Allowed values: ADD, REMOVE, REPLACE

pathstringYes

A JSON-Pointer

valuestring

The value to be used within the operations

ClaimAttributeMapping​

Type: object

2 properties
NameTypeRequiredDescription
claimURIstringYes

A unique URI specific to the claim.

mappedAttributestringYes

Userstore attribute to be mapped to.

AttributeMappingsReq​

Type: array of ClaimAttributeMapping

Array of ClaimURI attribute mappings.

Error​

Type: object

3 properties
NameTypeRequiredDescription
codestringYes
messagestringYes
descriptionstring

Property​

Type: object

2 properties
NameTypeRequiredDescription
namestringYes
valuestringYes

UserStoreListResponse​

Type: object

8 properties
NameTypeRequiredDescription
idstring

base64 url encoded value of domain name

namestring

Domain name of the secondary user store.

enabledboolean

Enabled status of the userstore.

descriptionstring
isLocalboolean

Whether the user store is local or not.

selfstring

Location of the created/updated resource.

typeNamestring

User store type name.

propertiesarray of AddUserStorePropertiesRes

Requested configured user store property for the set

MetaUserStoreType​

Type: object

4 properties
NameTypeRequiredDescription
typeNamestring
typeIdstring
isLocalboolean

Whether the user store is local or not.

propertiesUserStorePropertiesRes

UserStoreResponse​

Type: object

7 properties
NameTypeRequiredDescription
idstring

base64 url encoded value of domain name

namestring

domain name of the secondary user store

typeNamestring
typeIdstring
descriptionstring
propertiesarray of AddUserStorePropertiesRes

Configured user store proper for the set.

claimAttributeMappingsarray of ClaimAttributeMapping

Configured user store claim attribute mappings

AvailableUserStoreClassesRes​

Type: object

Available User Store Classes Response.

4 properties
NameTypeRequiredDescription
typeIdstring
typeNamestring
isLocalboolean

Whether the user store is local or not.

selfstring

UserStoreConfigurationsRes​

Type: object

Available User Store Configurations Response.

7 properties
NameTypeRequiredDescription
typeNamestring
typeIdstring
namestring
descriptionstring
isLocalboolean

Whether the user store is local or not.

propertiesarray of AddUserStorePropertiesRes

Configured user store property for the set

claimAttributeMappingsarray of ClaimAttributeMapping

Requested configured user store claim attribute mappings.

AddUserStorePropertiesRes​

Type: object

Available User Store Properties.

2 properties
NameTypeRequiredDescription
namestringYes
valuestringYes

UserStorePropertiesRes​

Type: object

3 properties
NameTypeRequiredDescription
Mandatoryarray of PropertiesRes
Optionalarray of PropertiesRes
Advancedarray of PropertiesRes

PropertiesRes​

Type: object

4 properties
NameTypeRequiredDescription
namestring
defaultValuestring
descriptionstring
attributesarray of Attribute

Attribute​

Type: object

2 properties
NameTypeRequiredDescription
namestring
valuestring

UserStoreAttributeMappingResponse​

Type: object

4 properties
NameTypeRequiredDescription
typeNamestring

Type name of the user store.

typeIdstring

Type id of the user store.

isLocalboolean

Whether the user store is local or not.

attributeMappingsarray of UserStoreAttributeResponse

User store attribute mappings.

UserStoreAttributeResponse​

Type: object

4 properties
NameTypeRequiredDescription
claimIdstring

Claim id of the attribute.

claimURIstring

Claim URI of the attribute.

mappedAttributestring

Mapped attribute name.

displayNamestring

Display name of the attribute.

Was this page helpful?