Creates or edits a tenant.
NAKIVO Backup & Replication must be running in multi-tenant mode. Refer to the Multi-Tenant Mode topic in the User Guide.
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":"save", "data":[ { "sessionUuid":null, "tenantInfoDto":{ "tenant":{ "id":null, "name":"test name", "allocatedPhysicalServers":0, "allocatedPhysicalWorkstations":1, "allocatedOffice365Users":1, "allocatedOracleDatabases":0, "allocatedBackupStorage":0, "usedBackupStorage":0, "email":"email@email.com", "phone":"12345", "website":"www.nakivo.com", "address":"Some address", "allocated":3, "allocatedEc2Instances":0, "showName":true, "labels":[ ] }, "tenantInventory":{ "itemObjectList":[ ], "nodes":{ "VMWARE":[ ], "HYPERV":[ ], "PHYSICAL":[ ] } }, "users":[ { "id":null, "username":"user1", "name":"User 1", "userType":"NORMAL", "generatePassword":false, "password":"1", "email":"user1@local.com", "description":"Description for user 1", "roleId":6, "action":"ADD_LOCAL" }, { "id":null, "username":"user2", "name":"User 2", "userType":"NORMAL", "generatePassword":false, "password":"123", "roleId":5, "action":"ADD_LOCAL" } ], "transporters":[], "repositories":[] } } ], "type":"rpc", "tid":"1" }
Request Fields
Field | Type | Value(s) | Description |
---|---|---|---|
| string |
| The action that is invoked |
| string |
| The method that is invoked |
| array | Parameters. See the | |
| string |
| Type of communication protocol |
| integer |
| Transaction ID. Used to identify the request by both the client and the server |
data
Field | Type | Description |
---|---|---|
| string | A pseudo-randomly generated value to identify one session from another. This unique value is used to set a tenant image creation session; the value can be null. Refer to Create Session for details |
| array | Information about the tenant |
| array | Tenant to be saved. See the tenant table below |
tenant
Field | Type | Description |
---|---|---|
| integer | ID of the tenant. Must be null if a new tenant is created |
| string | Name of the tenant |
| int | Number of physical server licenses to be allocated to the tenant |
| int | Number of physical workstation licenses to be allocated to the tenant |
| int | Number of Microsoft Office 365 licenses to be allocated to the tenant |
| int | Number of Oracle Database licenses to be allocated to the tenant |
| int | Amount of backup storage space allocated to the tenant |
| int | Amount of used backup storage space used by the tenant |
| string | Contact Email address of the tenant |
| string | Contact phone number of the tenant |
| string | URL address of the tenant |
| string | Address of the tenant |
| int | Licenses—machines or sockets—to be allocated to the tenant |
| int | Licenses—EC2 instances—to be allocated to the tenant |
| boolean | true if the tenant name is displayed. false otherwise |
| array | Labels of the tenant |
tenantInventory
Field | Type | Description |
---|---|---|
itemObjectList | ||
nodes | ||
VMWARE | ||
HYPERV | ||
PHYSICAL |
users
Field | Type | Description |
---|---|---|
| integer | ID of user. Null is a new user. |
| string | Username of user |
| string | Name of user |
| string | Type of user. Only accept ‘NORMAL’ |
| boolean | True will make password generated and send to user via email |
| string | Password to be set to a new user. Can be null if ‘generatePassword’ = true |
| string | Email of the tenant Mandatory if generatePassword = true |
| string | Description of user. |
| string | ID of the role assigned to the tenant |
| string | Possible value: "ADD_LOCAL" |
Response Sample
Note
The created tenant ID = 1.
Response Fields
Field | Value | Description |
---|---|---|
| string | Message if the request failed |
| string | Reference to the method where the problem occurred |
| string | Cause of failure |
| integer | The ID of the created or edited tenant |