Using the Management API¶ The Management API of the WSO2 Integrator: MI is an internal REST API, which was introduced to substitute the admin services that were available in WSO2 EI 6.x.x. The Integration Control Plane communicates with this service to obtain administrative information of the server instance and to perform various administration tasks. If you are not using the ICP, you can directly access the resources of the management API by following the instructions given below. Securely invoking the API¶ The management API is secured using JWT authentication by default. Therefore, when you directly access the management API, you must first acquire a JWT token with your valid username and password. Tip See Securing the Management API for information on configuring users, JWT authentication, and other security options for the management API. Getting a JWT token¶ Follow the steps given below to acquire the JWT token. First, encode your username:password in Basic Auth format (encoded in base64). For example, use the default admin:admin credentials. Invoke the /login resource of the API with your encoded credentials as shown below. curl -X GET "https://localhost:9164/management/login" -H "accept: application/json" -H "Authorization: Basic YWRtaW46YWRtaW4=" -k -i The API will validate the authorization header and provide a response with the JWT token as follows: { "AccessToken":"%AccessToken%" } Invoking an API resource¶ You can now use this token when you invoke a resource. Info When the default JWT security handler is engaged, all the management API resources except /login are protected by JWT auth. Therefore, it is necessary to send the token as a bearer token when invoking the API resources. curl -X GET "https://localhost:9164/management/inbound-endpoints" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%” Log out from management API¶ Invoke the /logout resource to revoke the JWT token you used for invoking the API resource. curl -X GET "https://localhost:9164/management/logout" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i Accessing API resources¶ The management API has multiple resources to provide information regarding the deployed artifacts as well as the server itself. GET USERS¶ Resource: /users Description: Retrieves a list of all users stored in an external user store. Example: RequestResponse curl -X GET "https://localhost:9164/management/users?pattern=*us*&role=role" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { count:2 list: [ userId: user1, userId: user2, userId: user3, ] } Search for a user by nameYou can also search for a user by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/users?searchKey=read-only" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "userId": "read-only-user" }] } Resource: /users/{user_id} Description: Retrieves information related to a specified user stored in the external user store. Example: RequestResponse curl -X GET "https://localhost:9164/management/users/user1?domain=wso2.com" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { userid: "WSO2.COM/user1", isAdmin: true/false, roles : [ "WSO2.COM/role1", "role2", ] } Note When fetching users from the primary user store, the domain query parameter can be ignored or set as primary. Resource: /users?pattern=*&role=admin Description: Retrieves information related to user names (stored in an external user store that match a specific pattern and user role. Example: RequestResponse curl -X GET "https://localhost:9164/management/users?pattern=*us*&role=role" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { count:2 list: [ userId: user1, userId: user2, userId: user3, ] } ADD USERS¶ Resource: /users Description: Adds a user to the external user store. Note that only admin users can create other users with admin access. Example: First create the following JSON file with user details as shown below. Note that this new user is granted the admin role. { "userId":"user4", "password":"pwd1", "isAdmin":"false", "domain":"wso2.com" } Note When adding users to the primary user store, the domain can be ignored or set as primary. We cannot add admin users to the secondary user stores. Execute the following request and receive the response: RequestResponse curl -X POST -d @user "https://localhost:9164/management/users" -H "accept: application/json" -H "Content-Type: application/json" -H "Authorization: Bearer %AccessToken% " -k -i { "userId":"user4", "status":"Added" } REMOVE USERS¶ Resource: /users Description: Removes a user from the external user store. Note Only super admin user can remove other users with admin access. Example: The following request deletes the user1 from the user store: RequestResponse curl -X DELETE "https://localhost:9164/management/users/user1" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { "userId":"user1", "status":"Deleted" } Example: The following request deletes user1 from the secondary user store: RequestResponse curl -X DELETE "https://localhost:9164/management/users/user1?domain=wso2.com" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { "userId":"user1", "status":"Deleted" } UPDATE USERS¶ Resource: /users Description: Update the password of a user from the external user store. Any user with admin access can update the own password and the passwords of non-admin users. Example: First create the following JSON file with user details as shown below. Here we are changing the password of user1. { "newPassword": "user111", "confirmPassword": "user111", "oldPassword": "user1" } The following request update the password of the user1 from the user store: RequestResponse curl -X PATCH -d @user "https://localhost:9164/management/users/user1" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k { "userId":"user1", "status":"Password updated" } GET Roles¶ Resource: /roles Description: Retrieves a list of all roles stored in an external user store. Example: RequestResponse curl -X GET "https://localhost:9164/management/roles" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { count:3 list: [ {"role": "admin"}, {"role": "Internal/everyone"}, {"role": "WSO2.COM/wso2Role"} ] } Search for a role by nameYou can also search for a role by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/roles?searchKey=admin" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 2, "list": [{ "role": "admin" }, { "role": "super-admin" }] } Resource: /roles/{role_name} Description: Retrieves information related to a specified role stored in the external user store. Example: RequestResponse curl -X GET "https://localhost:9164/management/roles/wso2role?domain=wso2.com" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { role: "WSO2.COM/wso2role", users : [ "WSO2.COM/wso2User1", "user2", ] } Note When fetching roles from the primary user store, the domain query parameter can be ignored or set as primary. When fetching hybrid roles, the domain query parameter should be set as Internal or Application accordingly. ADD ROLES¶ Resource: /roles Description: Adds a role to the external user store. Example: First create the following JSON file with role details as shown below. { "role" : "wso2role", "domain" : "wso2.com" } Note When adding roles to the primary user store, the domain can be ignored or set as primary. When adding a hybrid role, respective hybrid domain (Internal/Application) should be added to the role name Ex: Internal/internalRole Execute the following request and receive the response: RequestResponse curl -X POST -d @role "https://localhost:9164/management/roles" -H "accept: application/json" -H "Content-Type: application/json" -H "Authorization: Bearer %AccessToken% " -k -i { "role": "wso2role", "status": "Added" } REMOVE Roles¶ Resource: /users Description: Removes a role from the external user store. Example: The following request deletes the wso2role from the user store: RequestResponse curl -X DELETE "https://localhost:9164/management/roles/wso2role?domain=wso2.com" -H "accept: application/json" -H "Authorization: Bearer %AccessToken%" -k -i { "role": "wso2role", "status": "Deleted" } Note When deleting roles from the primary user store, the domain can be ignored or set as primary. ASSIGN / REVOKE Roles¶ Resource: /roles Description: Assign/remove set of roles to/from a given user in the external user store. Example: First create the following JSON file with role details as shown below. { "userId" : "wso2user", "addedRoles" :["Internal/internalRole", "Application/applicationRole"], "removedRoles":["wso2role"], "domain" : "wso2.com" } Note When the user belongs to the primary user store, domain can be ignored or set as primary. Users in secondary user stores can have roles from that user store and hybrid roles only. Users in secondary user stores cannot have the admin role. Execute the following request and receive the response: RequestResponse curl -X PUT -d @user "https://localhost:9164/management/roles" -H "accept: application/json" -H "Content-Type: application/json" -H "Authorization: Bearer %AccessToken% " -k -i { "userId": "wso2user", "status": "Added/removed the roles" } GET PROXY SERVICES¶ Resource: /proxy-services Description: Retrieves a list of all deployed proxy services. Example: RequestResponse curl -X GET "https://localhost:9164/management/proxy-services" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 1, "list": [ { "name": "TestProxy", "wsdl1_1": "http://ThinkPad-X1-Carbon-3rd:8290/services/TestProxy?wsdl", "wsdl2_0": "http://ThinkPad-X1-Carbon-3rd:8290/services/TestProxy?wsdl2" } ] } Search for a proxy by nameYou can also search for a proxy by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/proxy-services?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "HelloProxyService", "wsdl1_1": "http://localhost:8285/services/HelloProxyService?wsdl", "wsdl2_0": "http://localhost:8285/services/HelloProxyService?wsdl2" }] } Resource: /proxy-services?proxyServiceName={proxyName} Description: Retrieves information related to a specified proxy. Example: curl -X GET "https://localhost:9164/management/proxy-services?proxyServiceName=helloProxy" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i ACTIVATE/DEACTIVATE PROXY SERVICES¶ Resource: /proxy-services Description: Activate and Deactivate a specified proxy service. Example: RequestResponse curl -X POST \ https://localhost:9164/management/proxy-services \ -H 'authorization: Bearer TOKEN -H 'content-type: application/json' \ -d '{ "name": "HelloWorld", "status": "inactive" }' -k -i {"Message":"Proxy service HelloWorld stopped successfully"} ENABLE/DISABLE MESSAGE TRACING for PROXY SERVICES¶ Resource: /proxy-services Description: Enable or disable message tracing for a specified proxy service. Example: RequestResponse curl -X POST \ https://localhost:9164/management/proxy-services \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HelloWorld", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('HelloWorld')"} ENABLE/DISABLE MESSAGE STATISTICS for PROXY SERVICES¶ Resource: /proxy-services Description: Enable or disable message statistics for a specified proxy service. Example: RequestResponse curl -X POST \ https://localhost:9164/management/proxy-services \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HelloWorld", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('HelloWorld')"} GET CARBON APPLICATIONS¶ Resource: /applications Description: This operation provides you a list of available active and faulty Applications. Example: RequestResponse curl -X GET "https://localhost:9164/management/applications" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "totalCount": 2, "activeCount": 1, "faultyCount": 1, "activeList": [ { "name": "SampleServicesCompositeApplication", "version": "1.0.0", "artifacts": [ { "name": "HelloWorldAPI", "type": "api" }, { "name": "EmployeeDataService", "type": "dataservice" } ] } ], "faultyList": [ { "name": "FaultyCAppCompositeExporter", "errorMessage": "API deployment from the file : /wso2mi/tmp/carbonapps/-1234/FaultyCAppCompositeExporter_1.0.0.car/FaultyAPI_1.0.0/FaultyAPI-1.0.0.xml : Failed.", "version": "1.0.0", "artifacts": [ { "name": "FaultyAPI", "type": "api" } ] } ] } Search for a Carbon Application by nameYou can also search for a Carbon Application by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/applications?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "helloartifactsPackComposite", "version": "1.0.0-SNAPSHOT", "artifacts": [{ "name": "HelloLocalEntry", "type": "local-entry" }, { "name": "HelloLocalEntry", "type": "local-entry" }, { "name": "CSV-connector", "type": "lib" }, { "name": "HelloMessageStore", "type": "message-store" }, { "name": "HelloMessageStore", "type": "message-store" }, { "name": "AbcRestApi", "type": "api" }, { "name": "HelloRestApi", "type": "api" }, { "name": "AbcEndPoint", "type": "endpoint" }, { "name": "HelloEndPoint", "type": "endpoint" }, { "name": "AbcSequence", "type": "sequence" }, { "name": "AbcMessageProcessor", "type": "message-processors" }, { "name": "HelloMessageProcessor", "type": "message-processors" }, { "name": "AbcTemplate", "type": "template" }, { "name": "AbcDataService", "type": "dataservice" }, { "name": "HelloDataService", "type": "dataservice" }, { "name": "AbcProxyService", "type": "proxy-service" }, { "name": "HelloProxyService", "type": "proxy-service" }, { "name": "HttpListenerEP1", "type": "inbound-endpoint" }, { "name": "AbcScheduledTask", "type": "task" }] }] } Resource: /applications?carbonAppName={appname} Description: Retrieves information related to a specified carbon application. Example: curl -X GET "https://localhost:9164/management/applications?carbonAppName=HelloCApp" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i Resource: /applications/{name}/fault Description: Retrieves the fault details including the stack trace of a faulty carbon application. Example: RequestResponse curl --location 'https://localhost:9164/management/applications/FaultyCAppCompositeExporter/fault' \ --header 'Accept: application/json' \ --header 'Authorization: Bearer TOKEN' { "name": "FaultyCAppCompositeExporter", "errorMessage": "API deployment from the file : /wso2mi/tmp/carbonapps/-1234/FaultyCAppCompositeExporter_1.0.0.car/FaultyAPI_1.0.0/FaultyAPI-1.0.0.xml : Failed.", "version": "1.0.0", "faultStackTrace": "<STACK_TRACE>" } ADD CARBON APPLICATIONS¶ Resource: /applications Description: Adds a carbon application to the deployment folder. Once added it will be hot deployed to the server. Example: RequestResponse curl -X POST "https://localhost:9164/management/applications" --form "file=@path_to_car_file" -H "Authorization: Bearer TOKEN" -k -i {"Message":"Successfully added Carbon Application HelloWorldCompositeExporter_1.0.0.car"} DELETE CARBON APPLICATIONS¶ Resource: /applications Description: Delete a carbon application from the deployment folder. Once deleted it will be undeployed from the server. Example: RequestResponse curl -X DELETE "https://localhost:9164/management/applications/HelloWorldCompositeExporter_1.0.0" -H "Authorization: Bearer TOKEN" -k -i {"Message":"Successfully removed Carbon Application named HelloWorldCompositeExporter_1.0.0"} DOWNLOAD CARBON APPLICATION¶ Resource: /applications Description: Download a carbon application. Example: wget \ https://localhost:9164/management/applications?carbonAppName=myHttpServiceCompositeExporter_1.0.0.car \ -O myHttpServiceCompositeExporter_1.0.0.car \ --header 'Authorization: Bearer TOKEN' \ --header 'accept: application/octet-stream' \ --no-check-certificate -i GET ENDPOINTS¶ Resource: /endpoints Description: Retrieves a list of available endpoints. Example: RequestResponse curl -X GET "https://localhost:9164/management/endpoints" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "name": "FailOver_EP", "type": "failover" }, { "name": "WSDL_EP", "type": "wsdl" } ] } Search for an endpoint by nameYou can also search for an endpoint by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/endpoints?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "HelloEndPoint", "type": "http", "isActive": true }] } Resource: /endpoints?endpointName={endpointname} Description: Retrieves information related to a specified endpoint. ACTIVATE/DEACTIVATE ENDPOINTS¶ Resource: /endpoints Description: Activate or deactivate a specified endpoint. Example: RequestResponse curl -X POST \https://localhost:9164/management/endpoints \ -H 'authorization: Bearer TOKEN -H 'content-type: application/json' \ -d '{"name": "HTTPEP", "status": "inactive"} -k -i {"Message":"HTTPEP : is switched Off"} ENABLE/DISABLE MESSAGE TRACING for ENDPOINTS¶ Resource: /endpoints Description: Enable or disable message tracing for a specified endpoint. Example: RequestResponse curl -X POST \ https://localhost:9164/management/endpoints \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HTTPEP", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('HTTPEP')"} ENABLE/DISABLE MESSAGE STATISTICS for ENDPOINTS¶ Resource: /endpoints Description: Enable or disable message statistics for a specified endpoint. Example: RequestResponse curl -X POST \ https://localhost:9164/management/endpoints \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HTTPEP", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('HTTPEP')"} GET APIs¶ Resource: /apis Description: Retrieves a list of available APIs. Example: RequestResponse curl -X GET "https://localhost:9164/management/apis" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "name": "api", "url": "http://localhost:8290/test" }, { "name": "helloApi", "url": "http://localhost:8290/api" } ] } Search for an API by nameYou can also search for an API by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/apis?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "tracing": "disabled", "name": "HelloRestApi", "url": "http://localhost:8285/hellorest" }] } Resource: /apis?apiName={api} Description: Retrieves information related to a specified API. ENABLE/DISABLE MESSAGING TRACING for APIs¶ Resource: /apis Description: Enable or disable message tracing for a specified API. Example: RequestResponse curl -X POST \ https://localhost:9164/management/apis \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "helloApi", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('helloApi')"} ENABLE/DISABLE MESSAGE STATISTICS for APIs¶ Resource: /apis Description: Enable or disable message statistics for a specified API. Example: RequestResponse curl -X POST \ https://localhost:9164/management/apis \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "helloApi", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('helloApi')"} GET SEQUENCES¶ Resource: /sequences Description: Retrieves a list of available sequences. Example: RequestResponse curl -X GET "https://localhost:9164/management/sequences" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 3, "list": [ { "tracing": "disabled", "stats": "disabled", "name": "fault" }, { "container": "[ Deployed From Artifact Container: helloCompositeApplication ] ", "tracing": "disabled", "stats": "disabled", "name": "sequenceForSampler" }, { "tracing": "disabled", "stats": "disabled", "name": "main" } ] } Search for a Sequence by nameYou can also search for a Sequence by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/sequences?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 2, "list": [{ "tracing": "disabled", "stats": "disabled", "name": "Hello" }, { "tracing": "disabled", "stats": "disabled", "name": "helloworld" }] } Resource: /sequences?sequenceName={sequence} Description: Retrieves information related to a specified sequence. ENABLE/DISABLE MESSAGE TRACING for SEQUENCES¶ Resource: /sequences Description: Enable or disable message tracing for a specified sequence. Example: RequestResponse curl -X POST \ https://localhost:9164/management/sequences \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "helloSequence", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('helloSequence')"} ENABLE/DISABLE MESSAGE STATISTICS for SEQUENCES¶ Resource: /sequences Description: Enable or disable message statistics for a specified sequence. Example: RequestResponse curl -X POST \ https://localhost:9164/management/sequences \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "helloSequence", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('helloSequence')"} GET LOCAL ENTRIES¶ Resource: /local-entries Description: Retrieves a list of available local entries. Example: RequestResponse curl -X GET "https://localhost:9164/management/local-entries" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "name": "testEntry1", "type": "Inline Text" }, { "name": "testentry2", "type": "Inline XML" } ] } Search for a Local Entry by nameYou can also search for a Local Entry by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/local-entries?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 2, "list": [{ "name": "HelloLocalEntry", "type": "Inline Text", "value": "0.1" }, { "name": "helloSERVER" "type": "Inline Text", "value": "0.5" }] } Resource: /local-entries?name={entryName} Description: Retrieves information related to a specified entry. GET TASKS¶ Resource: /tasks Description: Retrieves a list of available tasks. Example: RequestResponse curl -X GET "https://localhost:9164/management/tasks" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 1, "list": [ { "name": "testTask" } ] } Search for a Task by nameYou can also search for a Task by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/tasks?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "HelloScheduledTask" }] } Resource: /tasks?taskName={taskName} Description: Retrieves information related to a specified task. ACTIVATE/DEACTIVATE/TRIGGER TASKS¶ Resource: /tasks Description: Activate, deactivate, or trigger a specific task. The status can be set to active, inactive, or trigger to activate, deactivate, or trigger the task, respectively. When a task is triggered, it is executed immediately as a one-time execution. Example: RequestResponse curl -X POST \ https://localhost:9164/management/tasks \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HelloScheduledTask", "status": "inactive" }' -k -i {"message":"HelloScheduledTask : is deactivated"} GET TASK STATUS¶ Resource: /task-status Description: Retrieves which node of the cluster each coordinated task is currently running on. This resource is available when coordinated task monitoring is enabled — while the feature is disabled, every view responds with "taskMonitoringEnabled": false. All views except ?scope=local read the shared coordination database, so querying any one node returns the cluster-wide answer. Example: RequestResponse curl -X GET "https://localhost:9164/management/task-status" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "nodes": [ { "nodeId": "node", "tasks": [ "SampleScheduledTask", "MSMP_sampleMessageProcessor_0" ] }, { "nodeId": "node1", "tasks": [ "AnotherScheduledTask" ] } ], "coordinationDbAvailable": true } Resource: /task-status?node={nodeId},{nodeId} Description: The same view, filtered to the specified node(s). A requested node that is running no coordinated tasks is listed with an empty tasks array. Resource: /task-status?name={taskName} Description: Retrieves where the specified task is running, together with a duplicate flag and the last-observed time (ISO-8601, UTC). Example: RequestResponse curl -X GET "https://localhost:9164/management/task-status?name=SampleScheduledTask" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "observedAt": "2026-06-27T20:16:43.801Z", "taskName": "SampleScheduledTask", "duplicate": false, "coordinationDbAvailable": true, "runningOn": [ "node" ] } Resource: /task-status?view=duplicates Description: Live duplicate check — lists the coordinated tasks currently running on two or more nodes. "healthy": true means no task is duplicated right now. Example: RequestResponse curl -X GET "https://localhost:9164/management/task-status?view=duplicates" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "duplicates": [ { "nodes": [ "node", "node1" ], "taskName": "SampleScheduledTask" } ], "healthy": false, "coordinationDbAvailable": true } Resource: /task-status?view=history Description: Forensic duplication history — every recorded duplication episode, including short-lived ones. The severity is OPEN (still happening), TRANSIENT (recovered quickly), or SUSTAINED (persisted beyond roughly twice the heartbeat-retry interval). Add &name={taskName} to filter to one task. Example: RequestResponse curl -X GET "https://localhost:9164/management/task-status?view=history" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "coordinationDbAvailable": true, "episodes": [ { "severity": "SUSTAINED", "nodes": "node,node1", "kind": "UNEXPECTED", "clearedAt": "2026-06-27T20:25:17.211Z", "taskName": "SampleScheduledTask", "detectedAt": "2026-06-27T20:24:24.160Z", "durationMs": 53051, "open": false, "destinedNode": "node" } ] } Resource: /task-status?scope=local Description: The queried node's own in-memory set of running coordinated tasks. This view reads no database, so it keeps answering during a coordination database outage — query each node separately and compare. Example: RequestResponse curl -X GET "https://localhost:9164/management/task-status?scope=local" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "coordinationEnabled": true, "scope": "local", "source": "in-memory", "nodeId": "node", "tasks": [ "SampleScheduledTask", "MSMP_sampleMessageProcessor_0" ] } Coordination database outageIf the coordination database is unavailable, the database-backed views degrade explicitly with "coordinationDbAvailable": false and a message — they never return a false "healthy": true. The ?scope=local view is unaffected and keeps answering in this state. GET COORDINATION READINESS¶ Resource: /coordination-readiness Description: Reports whether this node is ready to run coordinated tasks under coordination hardening. The answer is node-local: query every node. "green": true with an empty conditions list means the node is armed and healthy. Each condition carries its name, its clazz (GATE blocks coordinated work until the cause is removed, CONTINUOUS is a state that may clear by itself), a human readable detail and the time it was raised. On a node that runs with the feature off, the single condition hardening-disabled is reported. The resource always responds with HTTP 200, so parse the body. Example: RequestResponseResponse (not armed) curl -X GET "https://localhost:9164/management/coordination-readiness" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "node": "node", "green": true, "conditions": [] } { "node": "node", "green": false, "conditions": [ { "sinceEpochMillis": 1788430437416, "name": "hardening-disabled", "detail": "coordination hardening disabled, stock task handling", "clazz": "GATE" } ] } Resource: /coordination-readiness?view=liveness Description: The liveness probe view. leaseState is the node's boot lease state (PROVEN when it may schedule), live tells whether coordinated scheduling is actually running on this node, schedulerCycle reports the age of the last completed scheduler cycle against its grace period, and terminalLeaseState.terminal is true when the node has stopped coordinated work permanently and needs a restart. A node can be green and still report "live": false during a coordination database stall; live turns false only after one advertised heartbeat window of grace. The resource returns HTTP 200 whatever the outcome, so a native Kubernetes httpGet liveness probe cannot use it: use an exec probe that parses the body, or treat the view as a monitoring signal. An exec probe that restarts the container only when a restart is the documented remedy, that is when terminalLeaseState.terminal is true, can be as small as: TOKEN=$(curl -sk -m 5 -u "$MI_ADMIN_USER:$MI_ADMIN_PASSWORD" https://localhost:9164/management/login | sed -n 's/.*"AccessToken"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p') [ -z "$TOKEN" ] && exit 0 curl -sk -m 5 -H "Authorization: Bearer $TOKEN" "https://localhost:9164/management/coordination-readiness?view=liveness" | grep -Eq '"terminal"[[:space:]]*:[[:space:]]*true' && exit 1 exit 0 MI_ADMIN_USER and MI_ADMIN_PASSWORD are environment variables populated from a Kubernetes Secret. Do not write the credentials into the probe itself. Example: RequestResponse curl -X GET "https://localhost:9164/management/coordination-readiness?view=liveness" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "node": "node", "renewalAgeMillis": 3437, "schedulerCycle": { "lastCompletedAgeMillis": 1470, "gracePeriodMillis": 15000, "schedulerRunning": true, "graceExpired": false }, "leaseState": "PROVEN", "advertisedWindowMillis": 15000, "live": true, "terminalLeaseState": { "gracePeriodMillis": 15000, "sinceEpochMillis": null, "terminal": false, "graceExpired": false } } Resource: /coordination-readiness?view=counters Description: The refused-fire counters of this node: one entry per task and reason (LOST_RACE, EPOCH_MISMATCH, LAPSED or EXCEPTION) with the count, the time of the first refusal and whether the episode is still open. Refusals around restarts and failovers are the claim check working; a counter that stays open for one task for longer than 4 x W is worth investigating. Example: RequestResponse curl -X GET "https://localhost:9164/management/coordination-readiness?view=counters" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "node": "node", "counters": [ { "reason": "LOST_RACE", "count": 1, "taskName": "SampleScheduledTask", "firstAtEpochMillis": 1788432023993, "open": false } ] } RECONFIGURE TASK¶ Resource: /task-reconfigure?task={taskName}&expectedIncarnation={n}&expectedFp={fingerprint} Description: Applies a changed schedule of a coordinated task to the state recorded under coordination hardening, for the case where the task's artifact was replaced offline or the task is parked on a fingerprint-conflict readiness condition. The caller passes the incarnation and the bound schedule fingerprint it expects, which are the INCARNATION and SCHEDULE_FP columns of the task's COORDINATED_TASK_CLAIM row and are also printed in the detail of the parked condition. The handling node computes the new fingerprint from its own deployed artifact; an optional targetFp parameter, when supplied, must equal that computed value or the request is refused. This resource requires admin credentials and responds with HTTP 503 while the feature is disabled. The response status is RECONFIGURED (a new incarnation was recorded), ALREADY_APPLIED (the recorded state already matches) or REOPENED (a completed one-shot task was reopened under a new incarnation). A mismatch between the expected and the recorded values, an attempt to change the trigger family, or a retire in progress for the task is refused with HTTP 409 and an error code (state-conflict, no-change, trigger-family-immutable, retire-in-progress, guard-orphan). Example: RequestResponse curl -X POST "https://localhost:9164/management/task-reconfigure?task=SampleScheduledTask&expectedIncarnation=1&expectedFp=v1:sha256:3f2a...9c1e" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "task": "SampleScheduledTask", "status": "RECONFIGURED", "incarnation": 2, "oldFp": "v1:sha256:3f2a...9c1e", "newFp": "v1:sha256:8b71...d402" } RETIRE TASK¶ Resource: /task-retire?task={taskName}&expectedIncarnation={n}&operationId={uuid} Description: Starts an operator-initiated delete wave that removes the recorded claim state of a coordinated task, for the case where a task has been undeployed from every node but its row remains (the orphan-task-row readiness condition) or where a task has to be retired before it is redeployed under a new name after a trigger-family-conflict. operationId is a lowercase UUID chosen by the caller and reused on every retry of the same operation: it becomes the durable identity of the wave, so a repeated call reports the progress of the same wave instead of starting another. This resource requires admin credentials and responds with HTTP 503 while the feature is disabled. The response status is RETIRING while live nodes are still acknowledging the wave, RETIRED once every live node has acknowledged and the row is gone, or RETIRE_REFUSED with the dissenter node when a live node still has the artifact deployed. A call while some cluster member has not armed the feature is refused with HTTP 409 and the error code unadvertised-members. Example: RequestResponse curl -X POST "https://localhost:9164/management/task-retire?task=SampleScheduledTask&expectedIncarnation=2&operationId=6d1d8f0e-4b0c-4b1a-9a6e-2f7d1c3e5a90" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k { "task": "SampleScheduledTask", "status": "RETIRING", "operationId": "6d1d8f0e-4b0c-4b1a-9a6e-2f7d1c3e5a90" } GET MESSAGE STORES¶ Resource: /message-stores Description: Retrieves a list of available message stores. Example: RequestResponse curl -X GET "https://localhost:9164/management/message-stores" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "size": 0, "name": "testMessageStore", "type": "in-memory-message-store" }, { "size": 0, "name": "jdbc_sample_store", "type": "jdbc-message-store" } ] } Search for a Message Store by nameYou can also search for a Message Store by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/message-stores?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "size": 0, "name": "HelloMessageStore", "type": "in-memory-message-store" }] } Resource: /message-stores?name={messageStore} Description: Retrieves information related to a specified message store. GET MESSAGE PROCESSORS¶ Resource: /message-processors Description: Retrieves a list of available message processors. Example: RequestResponse curl -X GET "https://localhost:9164/management/message-processors" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "name": "testMessageProcessor", "type": "Scheduled-message-forwarding-processor", "status": "active" }, { "name": "TestSamplingProcessor", "type": "Sampling-processor", "status": "active" } ] } Search for a Message Processor by nameYou can also search for a Message Processor by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/message-processors?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "HelloMessageProcessor", "type": "Scheduled-message-forwarding-processor", "status": "active" }] } Resource: /message-processors?name={messageProcessors} Description: Retrieves information related to a specified message processor. ACTIVATE/DEACTIVATE MESSAGE PROCESSORS¶ Resource: /message-processors Description: Used to activate or deactivate a specific message processor. Example: curl -X POST \ https://localhost:9164/management/message-processors \ -H 'authorization: Bearer Token -H 'content-type: application/json' \ -d '{ "name": "testMessageProcessor", "status": "inactive" }' GET INBOUND ENDPOINTS¶ Resource: /inbound-endpoints Description: Retrieves a list of available inbound endpoints. Example: RequestResponse curl -X GET "https://localhost:9164/management/inbound-endpoints" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 1, "list": [ { "protocol": "http", "name": "HTTPIEP" } ] } Search for an Inbound Endpoint by nameYou can also search for an Inbound Endpoint by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/inbound-endpoints?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [ { "protocol": "http", "name": "HelloHTTPIEP", "status": "active" } ] } Resource: /inbound-endpoints?inboundEndpointName={inboundEndpoint} Description: Retrieves information related to a specified inbound endpoint. ACTIVATE/DEACTIVATE INBOUND ENDPOINTS¶ Resource: /inbound-endpoints Description: Activate or deactivate a specific inbound endpoint. The status can be set to active or inactive to activate or deactivate the inbound endpoint, respectively. Example: curl -X POST \ "https://localhost:9164/management/inbound-endpoints" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer TOKEN" \ -d '{"name": "sampleFileInboundEndpoint", "status": "inactive"}' ENABLE/DISABLE MESSAGE TRACING for INBOUND ENDPOINTS¶ Resource: /inbound-endpoints Description: Enable or disable message tracing for a specified inbound-endpoint. Example: RequestResponse curl -X POST \ https://localhost:9164/management/inbound-endpoints \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HTTPIEP", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('HTTPIEP')"} ENABLE/DISABLE MESSAGE STATISTICS for INBOUND ENDPOINTS¶ Resource: /inbound-endpoints Description: Enable or disable message statistics for a specified inbound-endpoint. Example: RequestResponse curl -X POST \ https://localhost:9164/management/inbound-endpoints \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "HTTPIEP", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('HTTPIEP')"} GET CONNECTORS¶ Resource: /connectors Description: Retrieves a list of available connectors. Example: RequestResponse curl -X GET "https://localhost:9164/management/connectors" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 2, "list": [ { "package": "org.wso2.carbon.connector", "name": "fileconnector", "description": "wso2 file connector", "status": "enabled" }, { "package": "org.wso2.carbon.connector", "name": "gmail", "description": "WSO2 Gmail connector library", "status": "enabled" } ] } Search for a Connector by nameYou can also search for a Connector by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/connectors?searchKey=csv" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "package": "org.wso2.carbon.module.csv", "name": "CSV", "description": "WSO2 CSV Module", "status": "enabled" }] } GET TEMPLATES¶ Resource: /templates Description: Retrieves a list of available templates. Example: RequestResponse curl -X GET "https://localhost:9164/management/templates" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "sequenceTemplateList": [ { "name": "testSequenceTemplate" } ], "endpointTemplateList": [ { "name": "endpointTemplate" } ] } Search for a Template by nameYou can also search for a Template by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/templates?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "Parameters": [{ "defaultValue": "", "name": "message", "mandatory": false }], "configuration": "<template xmlns=\"http://ws.apache.org/ns/synapse\" name=\"HelloTemplate\"><parameter name=\"message\" isMandatory=\"false\" defaultValue=\"\"/><sequence><log level=\"custom\"><property name=\"GREETING_MESSAGE\" expression=\"$func:message\"/><\/log><\/sequence><\/template>", "name": "HelloTemplate", "type": "sequence" }] } Resource: /templates?type=TYPE Description: Retrieves a list of available templates of a given type. Supported template types are as follows. 1. endpoint 2. sequence Example: RequestResponse curl -X GET "https://localhost:9164/management/templates?type=sequence" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 1, "list": [ { "name": "testSequenceTemplate" } ] } Resource: /templates?type={type}&name={template} Description: Retrieves information related to a specific template. However this requires the template type to be included in the request as a query parameter in addition to the template name. Example: RequestResponse curl -X GET "https://localhost:9164/management/templates?type=sequence&name=testSequenceTemplate" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "Parameters": [], "configuration": "<template xmlns=\"http://ws.apache.org/ns/synapse\" name=\"testSequenceTemplate\"><sequence/></template>", "name": "testSequenceTemplate" } ENABLE/DISABLE MESSAGE TRACING for SEQUENCE TEMPLATES¶ Resource: /templates Description: Enable or disable message tracing for a specified sequence template. Example: RequestResponse curl -X POST \ https://localhost:9164/management/templates \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "testSequenceTemplate", "type": "sequence", "trace": "enable" }' -k -i {"message":"Enabled tracing for ('testSequenceTemplate')"} ENABLE/DISABLE MESSAGE STATISTICS for SEQUENCE TEMPLATES¶ Resource: /templates Description: Enable or disable message statistics for a specified sequence template. Example: RequestResponse curl -X POST \ https://localhost:9164/management/templates \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "name": "testSequenceTemplate", "type": "sequence", "statistics": "enable" }' -k -i {"message":"Enabled statistics for ('testSequenceTemplate')"} GET SERVER INFORMATION¶ Resource: /server Description: Retrieves information related to the WSO2 Integrator: MI server instance. Example: RequestResponse curl -X GET "https://localhost:9164/management/server" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "productVersion": "1.1.0", "repositoryLocation": "/Users/Sachith/IdeaProjects/micro-integrator-public/distribution/target/wso2mi-1.1.0-SNAPSHOT/repository/deployment/client/", "osVersion": "10.14", "javaVersion": "1.8.0_171", "workDirectory": "/Users/Sachith/IdeaProjects/micro-integrator-public/distribution/target/wso2mi-1.1.0-SNAPSHOT/tmp/work", "carbonHome": "/Users/Sachith/IdeaProjects/micro-integrator-public/distribution/target/wso2mi-1.1.0-SNAPSHOT", "javaVendor": "Oracle Corporation", "osName": "Mac OS X", "productName": "WSO2 Integrator: MI", "javaHome": "/Library/Java/JavaVirtualMachines/jdk1.8.0_171.jdk/Contents/Home/jre" } SHUTDOWN SERVER¶ Resource: /server Description: Shutdown the WSO2 Integrator: MI server instance forcefully. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/server \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "status": "shutdown" }' -k -i { "Message":"The server will start to shutdown." } SHUTDOWN SERVER GRACEFULLY¶ Resource: /server Description: Shutdown the WSO2 Integrator: MI server instance gracefully. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/server \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "status": "shutdownGracefully" }' -k -i { "Message":"The server will start to shutdown gracefully." } RESTART SERVER¶ Resource: /server Description: Restart the WSO2 Integrator: MI server instance forcefully. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/server \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "status": "restart" }' -k -i { "Message":"The server will start to restart." } RESTART SERVER GRACEFULLY¶ Resource: /server Description: Restart the WSO2 Integrator: MI server instance gracefully. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/server \ -H 'authorization: Bearer TOKEN' \ -H 'content-type: application/json' \ -d '{ "status": "restartGracefully" }' -k -i { "Message":"The server will start to restart gracefully." } GET DATA SERVICES¶ Resource: /data-services Description: Retrieves a list of all successfully deployed data services. If any standalone .dbs data services have failed to deploy, they are included in the faultyList of the response. Example: RequestResponse curl -X GET "https://localhost:9164/management/data-services" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "count": 1, "list": [ { "name": "StudentDataService", "wsdl1_1": "http://Sachiths-MacBook-Pro.local:8290/services/StudentDataService?wsdl", "wsdl2_0": "http://Sachiths-MacBook-Pro.local:8290/services/StudentDataService?wsdl2" } ], "faultyCount": 1, "faultyList": [ { "name": "FaultyDataService", "errorMessage": "DS Fault Message: Access denied for user 'root'@'localhost' (using password: YES)\nDS Code: CONNECTION_UNAVAILABLE_ERROR\n" } ] } Search for a Data Service by nameYou can also search for a Data Service by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/data-services?searchKey=hello" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 2, "list": [{ "name": "HelloDataService", "wsdl1_1": "http://localhost:8285/services/HelloDataService?wsdl", "wsdl2_0": "http://localhost:8285/services/HelloDataService?wsdl2" }] } Resource: /data-services?dataServiceName={dataservice} Description: Retrieves information related to a specific data service. Example: curl -X GET "https://localhost:9164/management/data-services?dataServiceName=StudentDataService" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i Resource: /data-services/{name}/fault Description: Retrieves the fault details including the stack trace of a faulty data service. Example: RequestResponse curl -X GET "https://localhost:9164/management/data-services/FaultyDataService/fault" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "serviceName": "FaultyDataService", "errorMessage": "DS Fault Message: Access denied for user 'root'@'localhost' (using password: YES)\nDS Code: CONNECTION_UNAVAILABLE_ERROR\n", "faultStackTrace": "<STACK_TRACE>" } GET DATA SOURCES¶ Resource: /data-sources Description: Retrieves a list of all data sources deployed. Example: RequestResponse curl -X GET "https://localhost:9164/management/data-sources" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i {"count":1,"list":[{"name":"MySQLConnection","type":"RDBMS"}]} Search for a Data Source by nameYou can also search for a Data Source by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/data-sources?searchKey=carbon" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "name": "WSO2CarbonDB", "type": "RDBMS" }] } Resource: /data-sources?name={datasource} Description: Retrieves information related to a specific data source. Example: RequestResponse curl -X GET "https://localhost:9164/management/data-sources?name=MySQLConnection" -H "accept: application/json" -H "Authorization: Bearer TOKEN" -k -i { "configuration":"<configuration><driverClassName>com.mysql.jdbc.Driver</driverClassName><url>jdbc:mysql://localhost:3307/AccountDetails</url><username>root</username><password>root</password></configuration>", "driverClass":"com.mysql.jdbc.Driver", "name":"MySQLConnection", "description":"MySQL Connection", "type":"RDBMS", "url":"jdbc:mysql://localhost:3307/AccountDetails", "status":"ACTIVE" } GET LOG LEVEL¶ Resource: /logging?loggerName={logger} Description: Retrieves information related to a specific logger. Example: RequestResponse curl -X GET "https://localhost:9164/management/logging?loggerName=org-apache-coyote" -H "accept: application/json" -H "Authorization: Bearer Token" -k { "loggerName": "org-apache-coyote", "level":"WARN", "componentName":"org.apache.coyote" } Search for a Logger by nameYou can also search for a Logger by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/logging?searchKey=carbon" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 1, "list": [{ "level": "WARN", "componentName": "org.wso2.carbon.apacheds", "loggerName": "org-wso2-carbon-apacheds" }] } UPDATE ROOT LOG LEVEL¶ Resource: /logging Description: Updates the log level of root logger. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/logging \ -H 'authorization: Bearer Token' \ -H 'content-type: application/json' \ -d '{ "loggerName": "rootLogger", "loggingLevel": "WARN" }' -k { "message": "Successfully updated rootLogger.level to WARN" } UPDATE LOG LEVEL¶ Resource: /logging Description: Updates the log level of a specific logger. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/logging \ -H 'authorization: Bearer Token' \ -H 'content-type: application/json' \ -d '{ "loggerName": "org-apache-hadoop-hive", "loggingLevel": "DEBUG" }' -k { "message": "Successfully updated logger.org-apache-hadoop-hive.level to DEBUG" } ADD NEW LOGGER¶ Resource: /logging Description: Add a new logger. Example: RequestResponse curl -X PATCH \ https://localhost:9164/management/logging \ -H 'authorization: Bearer Token' \ -H 'content-type: application/json' \ -d '{ "loggerName": "synapse-api", "loggingLevel": "DEBUG", "loggerClass":"org.apache.synapse.rest.API" }' -k { "message":"Successfully added logger for ('synapse-api') with level DEBUG for class org.apache.synapse.rest.API" } GET CORRELATION LOGGING CONFIGURATION STATUS¶ Resource: /configs?configName=correlation Description: Retrieves correlation log configuration status. Example: RequestResponse curl -X GET "https://localhost:9164/management/configs?configName=correlation" -H "accept: application/json" -H "Authorization: Bearer Token" -k { "configName": "correlation", "configs": { “enabled” : “false” } } Search for a log files by nameYou can also search for a log file by name. To do that, use the following example cURL command. RequestResponse curl -X GET "https://localhost:9164/management/logs?searchKey=carbon" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "count": 3, "list": [{ "Size": "36.1 KB", "FileName": "wso2carbon.log" }, { "Size": "12.7 KB", "FileName": "wso2carbon-09-08-2022.log" }, { "Size": "0 B", "FileName": "wso2carbon-trace-messages.log" }] } ENABLE/DISABLE CORRELATION LOGGING DURING RUNTIME¶ Resource: /configs Description: Enable or disable correlation logging in a running server. Example: RequestResponse curl -X PUT \ "https://localhost:9164/management/configs/" \ -H "accept: application/json" -H "authorization: Bearer Token" -H 'content-type: application/json' \ -d '{ "configName": "correlation", "configs": {"enabled" : "true"} }' -k -i { "message": "Successfully Updated Correlation Logs Status" } GET REGISTRY DIRECTORY DATA¶ Resource: /registry-resources?path={registry path} Description: Retrieves files and folders under the given parent folder with their media type and properties. Example: RequestResponse curl -X GET \ "https://localhost:9164/management/registry-resources?path=registry/config/testFolder" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "count":2, "list": [ { "name":"name1", "mediaType":"type1", "properties":[] }, { "name":"name2", "mediaType":"type2", "properties": [ { "name":"prop1", "value":"val1" } ] } ] } Resource: /registry-resources?path={registry path}&expand={true} Description: Retrieves a nested JSON containing all the files and folders under the given parent folder. Example: RequestResponse curl -X GET \ "https://localhost:9164/management/registry-resources?path=registry/config/testFolder&expand=true" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "name":"testFolder", "files": [ { "name":"test-text.txt", "files":[], "type":"text/plain" }, { "name":"testSubFolder", "files": [ { "name":"test-xml.xml", "files":[], "type":"text/xml" } ], "type":"directory" } ], "type":"directory" } GET REGISTRY CONTENT¶ Resource: /registry-resources/content?path={registry path} Description: Retrieves content of a registry as text. Example: RequestResponse curl -X GET \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-xml.xml" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i <?xml version="1.0" encoding="UTF-8"?> <endpoint name="sampleEP" xmlns="http://ws.apache.org/ns/synapse"> <address uri="http://localhost:9000/updatedServices"> <suspendOnFailure> <initialDuration>-1</initialDuration> <progressionFactor>1</progressionFactor> </suspendOnFailure> <markForSuspension> <retriesBeforeSuspension>5</retriesBeforeSuspension> </markForSuspension> </address> </endpoint> Search for a Registry Resource by nameYou can also search for a Registry Resource by name. To do that, use the following example cURL command. A nested search is possible here to find files inside directories. RequestResponse curl -X GET "https://localhost:9164/management/registry-resources?path=registry/config&searchKey=test-text" -H "accept: application/json" -H "Authorization: Bearer $AccessToken" -k -i { "list": { "name": "config", "files": [{ "name": "testFolder", "files": [{ "name": "test-text.txt", "files": [], "type": "testMediaType" }], "type": "directory" }], "type": "directory" } } ADD A REGISTRY RESOURCE¶ Resource: /registry-resources/content?path={registry path}&mediaType={media type} Description: Adds a new registry resource. Note Only admin users can add new registry resources. Use multipart/form-data as in Request 2 to add binary files as registry resources. Change Content-Type header according to the payload. Example: Request 1Request 2Response curl -X POST \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-xml.xml&mediaType=application/xml" \ -H "accept: application/json" \ -H "Content-Type: application/xml" \ -H "Authorization: Bearer TOKEN" \ -d '<?xml version="1.0" encoding="UTF-8"?> <endpoint name="initialEP" xmlns="http://ws.apache.org/ns/synapse"> <address uri="http://localhost:9000/services"> <suspendOnFailure> <initialDuration>-1</initialDuration> <progressionFactor>1</progressionFactor> </suspendOnFailure> <markForSuspension> <retriesBeforeSuspension>5</retriesBeforeSuspension> </markForSuspension> </address> </endpoint>' -k -i curl -X POST \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-pdf.pdf&mediaType=application/pdf" \ -H "accept: application/json" \ -H "Content-Type: multipart/form-data" \ -H "Authorization: Bearer TOKEN" \ -F '[email protected]' -k -i { "message": "Successfully added the registry resource" } MODIFY REGISTRY RESOURCE¶ Resource: /registry-resources/content?path={registry path} Description: Modifies the content of an existing registry resource. Note Only admin users can modify registry resources. Change Content-Type header according to the payload. Changes done to the registry resources will be updated to the cache after the predefined cachableDuration time period. Example: Request 1Request 2Response curl -X PUT \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-xml.xml" \ -H "accept: application/json" \ -H "Content-Type: application/xml" \ -H "Authorization: Bearer TOKEN" \ -d '<?xml version="1.0" encoding="UTF-8"?> <endpoint name="updatedEP" xmlns="http://ws.apache.org/ns/synapse"> <address uri="http://localhost:9000/updatedServices"> <suspendOnFailure> <initialDuration>-1</initialDuration> <progressionFactor>1</progressionFactor> </suspendOnFailure> <markForSuspension> <retriesBeforeSuspension>5</retriesBeforeSuspension> </markForSuspension> </address> </endpoint>' -k -i curl -X PUT \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-pdf.pdf" \ -H "accept: application/json" \ -H "Content-Type: multipart/form-data" \ -H "Authorization: Bearer TOKEN" \ -F 'file=updatedPdf.pdf' -k -i { "message": "Successfully modified the registry resource" } DELETE A REGISTRY RESOURCE¶ Resource: /registry-resources/content?path={registry path} Description: Deletes a registry resource. Note Only admin users can delete registry resources. Example: RequestResponse curl -X DELETE \ "https://localhost:9164/management/registry-resources/content?path=registry/config/testFolder/test-xml.xml" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "message": "Successfully deleted the registry resource" } GET PROPERTIES OF A REGISTRY RESOURCE¶ Resource: /registry-resources/properties?path={registry path} Description: Retrieves all the properties of a registry resource. Example: RequestResponse curl -X GET \ "https://localhost:9164/management/registry-resources/properties?path=registry/config/testFolder/test-text.txt" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "count":2, "list": [ { "name":"prop1" ,"value":"val1" }, { "name":"prop2", "value":"val2" } ] } Resource: /registry-resources/properties?path={registry path}&name={property name} Description: Retrieves the value of a property. Example: RequestResponse curl -X GET \ "https://localhost:9164/management/registry-resources/properties?path=registry/config/testFolder/test-text.txt&name=prop1" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "prop1":"val1" } ADD PROPERTIES TO A REGISTRY RESOURCE¶ Resource: /registry-resources/properties?path={registry path} Description: Adds properties to a registry resource. If the input payload consists an existing property name, property value will be modified. Note Only admin users can add properties to a registry resource. New properties should be in a JSON array with JSON objects for each property. Example: RequestResponse curl -X POST \ "https://localhost:9164/management/registry-resources/properties?path=registry/config/testFolder/test-text.txt" \ -H "accept: application/json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer TOKEN" \ -d '[ { "name":"prop1", "value":"val1" }, { "name":"prop2", "value":"val2" } ]' -k -i { "message": "Successfully added the registry property" } DELETE A PROPERTY FROM A REGISTRY RESOURCE¶ Resource: /registry-resources/properties?path={registry path}&name={property name} Description: Deletes a property from a registry resource. Note Only admin users can delete properties from a registry resource. Example: RequestResponse curl -X DELETE\ "https://localhost:9164/management/registry-resources/properties?path=registry/config/testFolder/test-text.txt&name=prop1" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "message": "Successfully deleted the registry property" } GET METADATA OF A REGISTRY RESOURCE¶ Resource: /registry-resources/properties?path={registry path} Description: Retrieves the media type of a registry resource. Example: RequestResponse curl -X GET\ "https://localhost:9164/management/registry-resources/metadata?path=registry/config/testFolder/test-text.txt" \ -H "accept: application/json" \ -H "Authorization: Bearer TOKEN" -k -i { "name":"test-text.txt", "mediaType":"text/plain" }