Skip to main content

unarchiveRoom

FileOperationWrapper unarchiveRoom(id, ArchiveRoomRequest)

PUT /api/2.0/files/rooms/{id}/unarchive

Unarchive a room

Queues a background job that moves one room from the Archive section back to the Rooms section, and returns the operation record of that job. The room becomes writable again with the membership, tags, logo and links it had before, while the pinned state of its members is not restored and has to be set again with PUT api/2.0/files/rooms/{id}/pin. The caller must be a manager of the room; a member who was only invited to it is refused, a room template is answered as missing, and a room that was never archived simply stays where it is. The room is not moved when the response arrives: poll GET api/2.0/files/fileops until finished is true, and expect a room that is still archived until then. deleteAfter decides only how long the finished record survives. Calling the operation twice in a row does not corrupt the room, and a deleted or unknown room id is reported as missing.

Parameters​

NameInTypeDescriptionNotes
idpathInteger (int32)The room to move, named by the identifier that GET api/2.0/files/rooms reports for it.[required] [example: 1]
ArchiveRoomRequestbodyArchiveRoomRequestThe body of the request. It carries only the lifetime of the job record, so an empty object is a normal request.[optional]

Responses​

Status codeDescriptionTypeResponse headers
200The queued unarchive operation to pollFileOperationWrapperX-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset
400A third-party identifier refers to a storage account that is not connected--
403The caller may not read or unarchive this room, the id names a folder that is not a room, or a file in the room is locked or being edited--
404The room does not exist or is a room template, or the id is neither a 32-bit number nor a third-party identifier of a known storage type--
500A third-party identifier carries a storage account number beyond the 32-bit range--
401UnauthorizedErrorApiResponse-
429Too Many Requests.ErrorApiResponseRetry-After
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​

FileOperationWrapper

Third-party storage​

For a file or folder in a connected third-party storage the identifier is a string such as sbox-42, and the call differs in these parts only:

NameInTypeDescriptionNotes
idpathStringThe room to move, named by the identifier that `GET api/2.0/files/rooms` reports for it.[required] [example: sbox-42]

Authorization​

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

HTTP request headers​

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