Rename or move a folder
Moving takes everything in it along, into a folder of the same kind. 409 `folder_exists` for a name the destination has; 422 `folder_cycle` when moving it into itself or a folder inside it; 422 `folder_limit` past the depth.
Moving takes everything in it along, into a folder of the same kind. 409 folder_exists for a name the destination has; 422 folder_cycle when moving it into itself or a folder inside it; 422 folder_limit past the depth.
apiKey writeAuthorizationBearer <token>A workspace API key (pf_…), created under Developers → API keys.
Scope: write
id*stringuuididempotency-key?stringRun this write once: a retry with the same key gets the first answer (24 hours).
1 <= length <= 255application/json- body
name?string1 <= length <= 100parentId?|uuidOK
application/json- response
id*stringThe folder’s id
uuidname*stringparentId*|The folder it’s in; null at the top level
uuidfolders*integerFolders directly in it
createdAt*stringdate-timeupdatedAt*stringdate-timekind*"asset""asset"images*integerReady images directly in it
fonts*integerReady fonts directly in it
curl -X PATCH 'https://api.postforge.dev/v1/folders/497f6eca-6276-4993-bfeb-53cbbbba6f08' \ -H 'Content-Type: application/json' \ -d '{}'{ "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08", "name": "string", "parentId": "70850378-7d3c-4f45-91b7-942d4dfbbd43", "folders": 0, "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "kind": "asset", "images": 0, "fonts": 0}Create a folder POST
In the folder named by `parentId` (one of the same kind), or at the top level. 409 `folder_exists` when that folder has one by the name; 422 `folder_limit` past 1,000 folders of the kind or 10 levels.
Delete a folder DELETE
Deletes the folder and every folder inside it, and takes what’s in them out of the library: assets like `DELETE /v1/assets/{id}` (their files and URLs stay for emails that show them), templates like `DELETE /v1/templates/{id}`. The answer says how many of each went.