跳到主要内容

setTenantQuotaSettings

TenantQuotaSettingsWrapper setTenantQuotaSettings(TenantQuotaSettingsRequestDto)

PUT /api/2.0/settings/tenantquotasettings

Save the tenant quota settings

Sets or removes the storage quota for a given tenant. Available only on a Standalone (self-hosted) installation; on SaaS the call is always refused. Requires a DocSpace administrator, and the portal's plan must include the statistics feature or the call is rejected as not covered by the plan. Pass a non-negative quota in bytes to enable the limit for the tenant identified by tenantId, or a negative value to remove any limit. This is a mutating, idempotent call: sending the same body again leaves the quota unchanged. It returns the saved quota settings for that tenant, not its current usage.

Parameters​

NameInTypeDescriptionNotes
TenantQuotaSettingsRequestDtobodyTenantQuotaSettingsRequestDto[optional]

Responses​

Status codeDescriptionTypeResponse headers
200Saved tenant storage quota settingsTenantQuotaSettingsWrapperX-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
400The request body cannot be read or has no tenantId--
402The portal's pricing plan does not include the statistics feature required for tenant quotas--
403The caller has no portal-settings right--
415The caller is not a DocSpace administrator, or the portal is not a Standalone installation--
401UnauthorizedErrorApiResponse-
429Too Many Requests.ErrorApiResponseRetry-After
500Internal Server Error.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​

TenantQuotaSettingsWrapper

Authorization​

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

HTTP request headers​

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