API referenceLibrary
Update a folder
PATCH
Needs a key withlibrary:write
Renames or reorders a folder.
Requires scope library:write.
apiKeyheader
x-api-key<token>An API key of your workspace (rmg_…), created in the web app. It acts for that workspace, not for a person, and keeps working when its creator leaves.
folderId*stringLength
1 <= length <= 128application/json- body
name?stringLength
1 <= length <= 120sort?integerRange
0 <= value <= 10000The folder.
application/json- response
A Library folder.
id*stringLength
1 <= length <= 128isDefault*booleanOne of the starting folders (can't be deleted).
itemCount*integerkind*stringWhat it is, as the starting folders sort it: character, sprite (a Sprite Studio character), scene, item, style, sound_effect or other.
Value in
"character""sprite""scene""item""style""sound_effect""other"name*stringparentId*string|nullscope*stringteam: every member of the workspace sees and uses it. private: only you (in this workspace). API keys act for the workspace, so they use team only.
Value in
"private""team"sort*integercurl -X PATCH 'https://api.remagica.com/api/v1/library/folders/899433f8-5b3d-4f60-8e2a-1d9c6b4f7e05' \ -H 'Content-Type: application/json' \ -d '{}'Example Response
{ "id": "a5614527-5b3d-4f60-8e2a-1d9c6b4f7e05", "isDefault": true, "itemCount": 1, "kind": "character", "name": "Autumn campaign", "parentId": "eb290249-5b3d-4f60-8e2a-1d9c6b4f7e05", "scope": "private", "sort": 1}