permit.api.tenants.get()
Fetch the tenant and the tenant information.
Parameters
tenantKey
- The key of the tenant. This is the unique identifier of the tenant.
Implementation
import io.permit.sdk.openapi.models.TenantRead;
// accepts both the tenant id and the tenant key
TenantRead tenant = permit.api.tenants.get("[TENANT ID OR KEY]");
// if you want to be explicit, you can use getByKey
TenantRead tenant2 = permit.api.tenants.getByKey("[TENANT KEY]");
// or getById
TenantRead tenant3 = permit.api.tenants.getById(new UUID("[TENANT ID]"));