Skip to main content

getTenant

DocsCloudTenantWrapper getTenant(refresh)

GET /api/2.0/settings/docscloud/tenant

Get the Docs Connect tenant

Returns the Docs Connect tenant of the current portal: the Docs Connect server assigned to the portal, with its address, the date the tenant subscription ends and the payment the tenant was created for. A tenant exists only after a Docs Connect subscription has been granted, by POST api/2.0/settings/docscloud/trial or by a Docs Connect purchase, and only on an installation where the Docs Connect service is configured. The caller must be a portal administrator allowed to edit the portal settings. The call is read-only and idempotent, and it is served from a cache that keeps the tenant for an hour and the absence of a tenant for a minute, so pass refresh=true right after a subscription change to read the current state from Docs Connect instead. In the result, address is the absolute URL of the assigned server, isActive tells whether endDate is still in the future, and the dates are in UTC. An empty result means the portal has no Docs Connect tenant yet, which is the normal state before a subscription and not an error, so this is the operation to call to find out whether Docs Connect is activated at all. The license and server details, the editing settings, the user quota and the usage statistics are not part of it: they live in GET api/2.0/settings/docscloud/tenant/info, .../tenant/config, .../tenant/quota and .../tenant/usage, each of which fails with 400 while the portal has no activated tenant.

Parameters​

NameInTypeDescriptionNotes
refreshqueryBooleanPass true to skip the cached copy and request the tenant from Docs Connect again, replacing the cached one; with the default false the answer may be up to an hour old, or up to a minute old while the portal has no tenant.[optional] [default to false]

Responses​

Status codeDescriptionTypeResponse headers
200The Docs Connect tenant of the portal, or an empty result if no Docs Connect tenant is assigned to itDocsCloudTenantWrapperX-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
403The caller has no portal-settings right--
500The Docs Connect service is not configured on this installation, is unreachable, or answered with an error other than not found--
401UnauthorizedErrorApiResponse-
429Too Many Requests.ErrorApiResponseRetry-After
400Bad Request.ErrorApiResponse-
502Bad Gateway. Returned by the reverse proxy, response body may be HTML and not JSON.--
503Service Unavailable. Returned by the reverse proxy, response body may be HTML and not JSON.--

Return type​

DocsCloudTenantWrapper

Authorization​

Basic, OAuth2 (scopes: read, write), ApiKeyBearer, asc_auth_key, Bearer, OpenId

HTTP request headers​

  • Content-Type: Not defined
  • Accept: application/json