Create a new agent
cs_create_agentCreates a new Copilot Studio agent workspace on disk, with optional live environment bootstrap and solution placement. Supports classic and cli-copilot authoring modes.
Instructions
pac copilot init: create a new agent workspace on disk. Without 'environment' it is a local scaffold (no sign-in). With 'environment' it also creates the live agent and connects the workspace (needs pac auth profile and confirm: true). With 'solutionName' the agent is created inside that solution (existing unmanaged solution, or a new one with createSolution: true) via init, pack, import and clone; without it, pac puts the agent in a solution named after the agent. authoringMode 'classic' is the standard harness (topics, evaluations); 'cli-copilot' is the GitHub Copilot harness.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Agent display name | |
| confirm | No | Required to actually perform a change in a live environment. Without it the tool returns a dry run. | |
| template | No | classic only | |
| projectDir | Yes | Target directory (must be empty or not exist) | |
| schemaName | No | ||
| environment | No | Environment id or URL to bootstrap into (creates a live agent) | |
| instructions | No | ||
| solutionName | No | Unique name of the solution to create the agent in (requires environment) | |
| authoringMode | No | ||
| createSolution | No | Create solutionName if it does not exist | |
| publisherPrefix | Yes | Solution publisher prefix, e.g. contoso; must match the publisher of an existing target solution |