This documentation is for WSO2 Private PaaS 4.1.0. View documentation for the latest release.
Getting Details of Tenants - WSO2 Private PaaS 4.1.0 - WSO2 Documentation
Skip to end of metadata
Go to start of metadata

You can get details of the tenants in Private PaaS using the CLI tool or REST API as shown below:


Getting details of tenants via the CLI

CLI command


DescriptionRetrieving details of all tenants.

Retrieve details of all the available tenants.

Sample output
| Domain    | Tenant ID | Email       | State     | Created Date                 |
| | 1         | [email protected] | De-active | Wed Oct 14 11:39:14 IST 2015 |
| | 2         | [email protected] | Active    | Wed Oct 14 12:10:11 IST 2015 |

Getting details of tenants via the REST API

DescriptionRetrieving details of all the tenants.
Resource Path/tenants
Request/Response Formatapplication/json
Command format
curl -X GET -H "Content-Type: application/json" -k -v -u <USERNAME>:<PASSWORD> https://<PRIVATE_PAAS_HOST>:<PRIVATE_PAAS_HTTPS_PORT>/api/tenants
  • By default, <USERNAME>:<PASSWORD> is admin:admin.
  • By default, <PRIVATE_PAAS_HOST> is localhost. However, if you are using a public IP, the respective IP address or domain needs to be specified.
  • By default, <PRIVATE_PAAS_HTTPS_PORT> has been set to 9443. However, if the port offset has been incremented by n, the default port value needs to be incremented by n.

Retrieve details of all the available tenants.

curl -X GET -H "Content-Type: application/json" -k -v -u admin:admin https://localhost:9443/api/tenants
Sample output

The  createdDate  is given in the Epoch time format.

> GET /api/tenants HTTP/1.1
> Host: localhost:9443
> Authorization: Basic YWRtaW46YWRtaW4=
> User-Agent: curl/7.43.0
> Accept: */*
> Content-Type: application/json
< HTTP/1.1 200 OK
< Date: Thu, 15 Oct 2015 04:49:31 GMT
< Content-Type: application/json
< Transfer-Encoding: chunked
< Server: WSO2 Carbon Server
* Connection #0 to host localhost left intact
[{"active":false,"createdDate":1444802954640,"email":"[email protected]","tenantDomain":"","tenantId":1},{"active":true,"createdDate":1444804811968,"email":"[email protected]","tenantDomain":"","tenantId":2}

You will come across the following HTTP status codes while getting the details of tenants in Private PaaS:

HTTP status code

200, 500

See the descriptions of the HTTP status codes here.




  • No labels