Get Tenant List
Returns detailed tenants list.
Endpoint
https://<Director_IP_address>:4443/c/router
Request Example
curl --request POST \
--url https://<Director_IP_address>:4443/c/router \
--header "content-type: application/json" \
--cookie @cookies.txt \
--data "{
"action": "MultitenancyManagement",
"method": "getTenants",
"data": [{
"filter": {
"start": 0,
"count": 2,
"criteria": []}}],
"type": "rpc",
"tid": 1}"
Request Fields
Field
|
Type
|
Value(s)
|
Description |
---|---|---|---|
action
|
string |
|
The action that is invoked |
method
|
string |
|
The method that is invoked |
data
|
array |
|
Filter parameters. See the |
type
|
string | rpc |
Type of communication protocol |
tid
|
int | 1 |
Transaction ID. Used to identify the request by both the client and the server |
filter
Field
|
Type
|
Description
|
---|---|---|
start
|
int | A start ID of the tenant to be returned |
count
|
int | Number of tenants to be returned |
|
string |
Tenant parameter to be sorted with |
|
boolean |
|
criteria
|
Json | Filter criteria. See the table below |
criteria
Field |
Type |
Description |
---|---|---|
|
string |
Name of criterion. ID means the tenant ID |
|
string |
Type of the criterion. Possible values: |
|
string |
Value of a criterion. |
|
list <string> |
Attribute values. Used for the |
Response Sample
{
"action": "MultitenancyManagement",
"method": "getTenants",
"tid": "1",
"type": "rpc",
"message": null,
"where": null,
"cause": null,
"data": {
"children": [
{ "id": 2,
"name": "Customer 1",
"uuid": "aaa6da10-97ea-43ac-80f8-6ddd22faeb93",
"allocated": 4,
"allocatedDesired": 4,
"allocatedEc2Instances": 0,
"allocatedEc2InstancesDesired": 0,
"allocatedPhysicalServersDesired": 0" "labels": [
{ "id": 2,
"name": "asdad",
"position": null } ],
"email": "",
"phone": "",
"website": "",
"address": "",
"logo": "/c/tenants/aaa6da10-97ea-43ac-80f8-6ddd22faeb93/tenant-data/d2071b7b-2bc1-4da5-864d-d4f153323e51.png",
"showName": true,
"enabled": true,
"state": "OK",
"status": "NONE",
"changeStatus": "NONE",
"alarmState": "OK",
"lockedShared": false,
"lockedExclusive": false,
"wasEdited": false,
"wasDiscoveredOnce": true,
"progress": 0,
"alarmCounters": [ 0, 0, 0, 0 ],
"usedVms": 0,
"usedSockets": 0,
"usedEc2Instances": 0,
"alertErrorCode": null,
"alertTitle": null,
"alertDescription": null },
{ "id": 3,
"name": "Customer 2",
"uuid": "e956fc69-b978-41d6-97d4-6e8577600434",
"allocated": 5,
"allocatedDesired": 5,
"allocatedEc2Instances": 0,
"allocatedEc2InstancesDesired": 0,
"labels": [],
"email": "",
"phone": "",
"website": "",
"address": "",
"logo": "/c/tenants/e956fc69-b978-41d6-97d4-6e8577600434/tenant-data/c5f2898a-6cab-4bfb-a107-192c461f7128.png",
"showName": true,
"enabled": false,
"state": "OK",
"status": "NONE",
"changeStatus": "NONE",
"alarmState": "OK",
"lockedShared": false,
"lockedExclusive": false,
"wasEdited": false,
"wasDiscoveredOnce": true,
"progress": 0,
"alarmCounters": [ 0, 0, 0, 0 ],
"usedVms": 0,
"usedSockets": 0,
"usedEc2Instances": 0,
"usedPhysicalServers ": 0" "alertErrorCode": null,
"alertTitle": null,
"alertDescription": null } ],
"total": 10 }
}
Response Fields
Field
|
Value
|
Description
|
---|---|---|
message
|
string | Message if the request failed |
where
|
string | Reference to the method where the problem occurred |
cause
|
string | Cause of failure |
data |
array | Tenant items. See the children table below |
children
Field
|
Value
|
Description
|
---|---|---|
|
long | ID of the tenant |
|
string | Name of the tenant |
|
string | UUid of the corresponding session |
|
int | Sockets allocated for the tenant |
|
int | Number of sockets to be allocated to the tenant at some point. It is saved in the database but not yet applied to the physical tenant. If allocatedDesired = actual , then either number of sockets is allocated for the tenant or it has not changed |
|
int | Number of EC2 instances allocated for the tenant |
|
int | Number of EC2 instances to be allocated to the tenant at some point. It is saved in the database but not yet applied to the physical tenant. If allocatedEc2InstancesDesired = actual, then either number of EC2 instances is allocated for the tenant or it has not changed |
|
int |
Number of physical servers allocated for the tenant |
|
int |
Number of physical machines to be allocated to the tenant at some point. It is saved in the database but not yet applied to the physical tenant |
|
array | Tenant labels |
|
string | Contact Email of the tenant |
|
string | Contact phone number of the tenant |
|
string | URL of the tenant website |
|
string | Contact address of the tenant |
|
string | A path to the tenant logo image |
|
boolean | If true , it will display the name of the tenant |
|
boolean | If true , the tenant will be enabled |
|
string | State of the tenant. Possible values: OK, WARNING, INACCESSIBLE, ERROR |
|
string | Status of the tenant. Possible values: NONE, UPDATING |
|
string | Defines the pending change in the tenant’s state. Possible values: NONE, CREATE_PENDING, CHANGE_PENDING |
|
string | State of the tenant alarms. Possible values: OK, WARNING, ERROR |
|
boolean | true if a shared lock is set for the tenant. false otherwise |
|
boolean | true if an exclusive lock is set for the tenant. false otherwise |
|
boolean | Indicates whether the tenant was edited |
|
boolean | Indicates whether the tenant state was discovered once |
|
int | A value from 0 to 100 . For a newly created tenant, the value is set to 0 |
|
array | Number of alarms in the tenant |
|
int | Number of VMs used by the tenant |
|
int | Number of sockets used by the tenant |
|
int | Number of EC2 instances used by the tenant |
|
int |
Number of physical machines used by the tenant |
|
string | Error code of the alert |
|
string | Title of the alert |
|
string | Description of the alert |
|
int | Number of tenant items |