Writing a Web Service Client for Authentication and User Admin Services¶
This topic demonstrates how to use different web services API exposed by
Identity Server, to write a client application "
" to handle user management functionality (ex: create user, create
roles, assign roles) of WSO2 Identity Server remotely. The
AuthenticationAdmin, RemoteUserStoreManagerService and
RemoteAuthorizationManagerService admin services to perform different
operations. Go through the
sample implementation to see details.
- The code for the sample can be checked out from the GitHub repository. To do this, follow the instructions on the Downloading a Sample topic.
Once you have downloaded the samples, go to the
<Sample_Home>/user-mgt/remote-user-mgtdirectory to build the remote user management client.
<Samples_Home>is referred to the root directory of the WSO2 Identity Server's samples that you checkout by following the steps here
Make sure the URL of the remote server (
remote.server.url), credentials of the user who performs user management operations (
user.name, user.password) and truststore (
truststore.path, truststore.password) configured in
<Samples_Home>/ user-mgt/remote-user-mgt/client.propetiesare correct with respect to your environment. If you have changed the private key in the identity server, import the public certificate of the identity server to the truststore (
client-truststore.jks) of the sample client in
Build the client using
Once the client is built successfully, run the
remote-user-mgt-client.shfile in Unix or
remote-user-mgt-client.batin Windows. You can see that the actions performed is being printed by the client.
The service stubs are available at WSO2 Maven Repository and
can be added as dependencies to the project. Also, you can generate the
service stubs from the WSDL file available at
In order to enable access to the WSDL files, add the following configuration in
<IS_HOME>/repository/conf/deployment.toml file and restart the server.
[admin_service.wsdl] enable = false