Folders
Delete an empty folder
A folder that still holds sub-folders or resources is refused with 409: move or delete them first. Answers the deleted folder. With validate_only, the same checks run and 204 answers, nothing is deleted.
Authorization
AuthorizationstringheaderrequiredBearer <key>, where <key> is a workspace API key or a user API key. See Authentication.
workspace_id*integerThe workspace. List the ones your key can reach with GET /v1/workspaces.
folder_id*stringThe folder.
uuidregion*RegionsRegion of the resource: besg (Europe) or usnv (United States), as GET /v1/regions lists them
"besg""usnv"validate_only?Validate OnlyRun every check of the write and answer 204 without writing: a refused write answers the error the write would
falseOK
application/json- response
A folder of the workspace
folder_id*Folder Idfolder_name*Folder Namefolder_resource_id*Folder Resource Idparent_folder_id*|The folder it is in; None at the root
region*Regions"besg""usnv"curl -X DELETE 'https://api.stacksync.com/v1/workspaces/0/folders/497f6eca-6276-4993-bfeb-53cbbbba6f08?region=besg'{ "folder_id": "<folder_id>", "folder_name": "<folder_name>", "folder_resource_id": "<folder_resource_id>", "parent_folder_id": "<parent_folder_id>", "region": "besg"}PATCHRename a folder
A name another folder has in the region of the workspace is refused with 409, as a create refuses it. With validate_only, every check runs and 204 answers, nothing is saved.
POSTMove resources into a folder
Each resource (from GET .../resources) is filed under the folder; a resource of another region than the folder is not moved. Moving again to the same folder changes nothing, so a retry is safe. With validate_only, the answer tells what would move, without moving anything.