---
title: "Move Agents To Folder"
method: POST
path: "/v2/teams/{teamId}/agent-folders/move-agents"
tags: ["Agent Folders"]
---

# Move Agents To Folder

`POST /v2/teams/{teamId}/agent-folders/move-agents`

## Request

- Base URL: `https://api.duvo.ai`
- URL: `https://api.duvo.ai/v2/teams/{teamId}/agent-folders/move-agents`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/duvo/apis/duvo-public-api/docs/v2/teams/:teamId/agent-folders/move-agents/post.ts> (a function with typed inputs; its response is checked against the schema)

Move one or more agents (assignments) into a folder, or to the root level.

## Path parameters

- `teamId` string, required

## Request body

- object
  - `agent_ids` string[], required: IDs of the agents (assignments) to move. Must be unique.
  - `folder_id` string, uuid, nullable, required: Destination folder ID. Pass null to move the agents to the root level.

## Response `200`

Default Response

- object
  - `success` boolean, required: Always true on success
  - `moved_count` number, required: Number of agents that were moved

## Other responses

- `400`: Default Response
- `401`: Default Response
- `404`: Default Response
- `409`: Default Response
- `500`: Default Response

---

[API](https://skmtc.dev/duvo/apis/duvo-public-api.md) - [All operations](https://skmtc.dev/duvo/apis/duvo-public-api/llms.txt) - [OpenAPI document](https://skmtc.dev/duvo/apis/duvo-public-api/revisions/dafcf3d868a9?raw)
