libraries

Restore a library from trash

Changed on

Restores a previously-trashed library so it reappears in default list/search results. Works as long as the library row still exists — once get_library returns 404 the row is gone and restore is no longer possible. If the background drain has already started purging assets, restore succeeds but recovers only the assets the drain hasn't gotten to yet.

Pairs with trash_library. To restore individual trashed assets within an untrashed library, use restore_assets instead.

post/api/libraries/{library_id}/restore

Request

  • Base URL: https://api.gumnut.ai
  • URL: https://api.gumnut.ai/api/libraries/{library_id}/restore
  • Auth: one of:
    • HTTP bearer
    • HTTP bearer

Path parameters

library_idstring required

Library ID (with lib_ prefix) of the trashed library to restore.

Response

Successful Response

idstring required

Unique library identifier with 'lib_' prefix

namestring required

Display name of the library

descriptionstring nullable

Optional description text for the library

user_idstring required

ID of the user who owns this library

role'owner' | 'viewer' | 'collaborator' required
asset_countinteger required

Total number of assets in this library

storage_used_bytesinteger required

Bytes of assets currently stored in this library

storage_limit_bytesinteger nullable

Maximum bytes this library may store, or null if no per-library limit applies

created_atstring date-time required

When this library was created

updated_atstring date-time required

When this library was last updated

Changes

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • breaking

      response property detail list-of-types was widened by adding types string to media type application/json of response 422

    • info

      the response property became required for the status