// Tenants

Connect tenants to a project

Connect many tenants to a project at once - by ID, by tag, or both - with the same environments.

POST/api/project/tenants

Description

Connects the tenants you name, plus every active tenant with one of the tags, to the project. They all get the same environments.

Tenants that are already connected are left as they were - their environments are not changed - and are listed in alreadyConnected. To change the environments of one tenant use PUT /api/tenant/project.

The call is all or nothing: if a tenant, tag or environment is refused, no tenant is connected.

missingValues counts the required tenant variables each tenant still has to fill in. A new connection usually starts with some missing - set them with PUT /api/tenant/variables.

Parameters

NameInTypeRequiredDescription
projectId body string yes ID of the project.
tenantIds body array<string> no IDs of tenants in the project's workspace. Archived tenants are refused.
tagIds body array<string> no IDs of tags in the project's workspace. Every active tenant with at least one of these tags is connected.
environmentIds body array<string> no IDs of environments in the project's workspace the tenants can be deployed to. Leave out or send [] for none.

Errors

StatusMeaning
400 Invalid projectId. A project that belongs to another organization is reported the same way as one that does not exist.
400 No tenants or tags were sent, a tenant, tag or environment is not in this workspace, or a tenant is archived. Nothing is connected.
401 Missing or invalid Basic auth credentials, or the service account lacks permission to manage tenants in this workspace.