跳到主要内容

deleteThirdParty

StringWrapper deleteThirdParty(providerId)

DELETE /api/2.0/files/thirdparty/{providerId}

Remove a third-party account

Disconnects a third-party storage account from the portal and returns the ID of the folder that stood for it, in the provider-accountId form the Files operations use for third-party entries. Take providerId from GET api/2.0/files/thirdparty: it is the numeric account ID, not that composed folder ID. The member who connected the account can remove it; another member's request is refused unless they hold delete rights on the folder it stands for. Nothing is deleted at the storage service: the files stay with the provider, and what goes away is the portal's link to them together with the stored credentials, the sharing records and the tags kept for its entries. An account a room was created on is refused with 403 while the room exists: delete the room instead, which disconnects the account along with it. When the account being removed is the one connected for backups by POST api/2.0/files/thirdparty/backup, its backup schedule is deleted as well. The removal cannot be repeated: once the account is gone the same ID is refused rather than confirmed, so treat the first successful answer as the record of it.

Parameters​

NameInTypeDescriptionNotes
providerIdpathInteger (int32)The ID of the connected third-party storage account, as providerId of GET api/2.0/files/thirdparty.[required] [example: 12]

Responses​

Status codeDescriptionTypeResponse headers
200The ID of the folder that stood for the removed accountStringWrapperX-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
403The caller neither connected the account nor has the right to delete the folder it stands for--
404No third-party account with this ID exists on the portal--
401UnauthorizedErrorApiResponse-
429Too Many Requests.ErrorApiResponseRetry-After
500Internal Server Error.ErrorApiResponse-
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​

StringWrapper

Authorization​

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

HTTP request headers​

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