cabinets resource on the Figranium Python SDK is the typed client for the Cabinets API. Cabinets are durable, installation-wide download queues. Tasks can route intercepted downloads into a selected Cabinet, and later actions can upload the newest unuploaded item from that queue.
Supported operations
cabinets covers the Cabinet lifecycle and item-management API.
Cabinet lifecycle
List, create, rename, migrate, clear, and delete Cabinets.
Item management
List Cabinet items, update upload status, and remove one or many items.
Archives
Create ZIP archives and safely extract compatible archives.
Downloads
Build item download URLs for files stored in a Cabinet.
Methods
list
list
List all Cabinets.
- HTTP endpoint:
GET /api/cabinets - Signature:
cabinets.list(*, options=None)
list_cabinets.py
create
create
Create a new Cabinet.
- HTTP endpoint:
POST /api/cabinets - Signature:
cabinets.create(name, *, options=None)
create_cabinet.py
rename
rename
Rename an existing Cabinet.
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/rename - Signature:
cabinets.rename(cabinet_id, name, *, options=None)
rename_cabinet.py
delete
delete
Delete a Cabinet. You can optionally migrate its items to another Cabinet first.When
- HTTP endpoint:
DELETE /api/cabinets/{cabinetId} - Signature:
cabinets.delete(cabinet_id, *, target_cabinet_id=None, migrate=False, options=None)
delete_cabinet.py
migrate=True, items are moved to target_cabinet_id before the Cabinet is removed.list_items
list_items
List the items inside a Cabinet.
- HTTP endpoint:
GET /api/cabinets/{cabinetId}/items - Signature:
cabinets.list_items(cabinet_id, *, options=None)
list_items.py
clear
clear
Remove every item from a Cabinet.
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/clear - Signature:
cabinets.clear(cabinet_id, *, options=None)
clear_cabinet.py
set_item_status
set_item_status
Update the status of one or more Cabinet items.Valid statuses are
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/items/status - Signature:
cabinets.set_item_status(cabinet_id, item_ids, status, *, options=None)
set_status.py
"pending" and "uploaded".remove_items
remove_items
Remove specific items from a Cabinet.
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/items/remove - Signature:
cabinets.remove_items(cabinet_id, item_ids, *, options=None)
remove_items.py
zip_items
zip_items
Create a ZIP archive from selected Cabinet items.
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/zip - Signature:
cabinets.zip_items(cabinet_id, item_ids, *, name=None, options=None)
zip_items.py
unzip_item
unzip_item
Extract a ZIP archive that is stored as a Cabinet item.
- HTTP endpoint:
POST /api/cabinets/{cabinetId}/unzip/{itemId} - Signature:
cabinets.unzip_item(cabinet_id, item_id, *, options=None)
unzip_item.py
get_item_download_url
get_item_download_url
Build a download URL for a Cabinet item. This method does not make an HTTP request. It returns a URL string synchronously.
- Signature:
cabinets.get_item_download_url(cabinet_id, item_id)
download_url.py
Use a Cabinet from a task
Tasks can setcabinetId to select where intercepted browser downloads are stored:
task_with_cabinet.py
cabinetId, Figranium uses the instance’s default Cabinet. An individual Upload action can override the task-level selection with its own cabinetId.
Upload status
Cabinet items track whether they have been uploaded. Theupload action normally selects the newest unuploaded item. You can mark an item uploaded immediately with markAsUploaded, or keep finalization separate and call finalize_uploads later in the workflow.
Async usage
Allcabinets methods are also available on AsyncFigranium. Use await for each call.
async_cabinets.py
Related resources
Action helpers
Build Upload and Finalize Uploads actions.
Tasks resource
Save and run tasks that select a Cabinet with
cabinetId.File downloads
Understand Cabinets, intercepted downloads, and the upload lifecycle.