Add apps to folder

<Info>This API is in beta. Endpoints, fields, and behavior may still change, so avoid depending on it in production.</Info>

Puts apps in a folder. An app is in one folder at a time, so this moves an app that's already in another folder.

The apps must be in the workspace, not deleted, and of the folder's kind: builder apps for a user_app folder and agents for a user_agent one. You can add any app in the workspace, including one you can't open. If an app is in a folder you can't change, such as another user's personal folder, the request is refused. Send up to 500 IDs per request. IDs that aren't valid app IDs are ignored and aren't counted in the response.

You can change your own personal folders. Workspace folders need the editor role or higher, and any editor can change any workspace folder. A folder that doesn't exist, or another user's personal folder, returns a 404 with the code folder_not_found. A personal access token limited to selected apps can only use the apps it lists. Any other app ID returns a 404.

This is limited to 60 requests per minute, shared with the other endpoints that change folders. A signed-in session has its own limit, and every personal access token for the workspace shares one. Some workspaces have a different limit.

<Note>Call this with a personal access token sent as a Bearer token, or from a signed-in session. A token works on its own workspace's folders. Workspace API keys aren't accepted, and a read-only token is refused.</Note>

post/api/app-folders/{folder_id}/items

Path parameters

folder_idstring required

ID of the folder to add apps to. Get it from id in List app folders.

ID of the folder to add apps to. Get it from id in List app folders.

Request body

app_idsstring[] required

IDs of the apps to put in the folder, up to 500.

Example request

{
  "app_ids": [
    "6820f3a4e7b91d003c45a1f2"
  ]
}

Response

The apps are in the folder.

linked_countinteger required

Number of apps added to the folder.

skipped_countinteger required

Number of IDs skipped because the app was already in the folder or was listed twice.

folder_idstring required

ID of the folder.

Example response

{
  "linked_count": 1,
  "folder_id": "68c1f2a9b4e7d3005a2c9e11"
}

Changes

Changed in 1 of the 40 revisions of this API.1