Skip to main content
Glama

Extract an agent template

cs_extract_agent_template

Extract an existing Copilot Studio agent into a reusable YAML template, preserving topics, settings, and components, to replicate it in another environment or solution.

Instructions

Write a reusable YAML template from an existing agent (its topics, settings and components), for cs_create_agent_from_template in another environment or solution. Runs 'pac copilot extract-template' with the active pac auth profile.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
botYesAgent id or schema name
cwdNoWorking directory for pac (for project commands: the solution project folder)
profileNopac auth profile to run as: the admin account for tenant commands. Defaults to CPS_ADMIN_PROFILE for admin commands and CPS_PAC_PROFILE otherwise, then the active profile. cs_init lists the profiles.
overwriteNoOverwrite the file if it exists
backgroundNoRun in the background and return a jobId immediately, for a command that takes longer than the client will wait. Poll cs_job_status.
environmentNoEnvironment id or URL; default: the environment of the active pac auth profile
templateFileYesPath of the YAML template to write
templateNameNoTemplate name (default kickStartTemplate)
timeoutSecondsNoDefault 600
templateVersionNoTemplate version X.Y.Z (default 1.0.0)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.5

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It reveals the underlying command and that it writes a template file, but it does not disclose side effects on the source agent (likely read-only), overwrite consequences, permission requirements, or the shape of the response. For a tool with zero annotation coverage this leaves meaningful gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two efficient sentences with the purpose front-loaded and the underlying command stated for transparency. No filler; every clause earns its place. Slightly better than average due to the tight structure.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 10-parameter command runner with no output schema and no annotations, the description covers purpose, target consumer, and the pac command, but omits return-value/confirmation behavior and whether the operation is destructive to the source. Adequate but with clear gaps given the tool's complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema documents all 10 parameters, establishing the baseline of 3. The description adds only marginal context — e.g., that the output feeds cs_create_agent_from_template — but does not explain syntax or behavior beyond the schema's field descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific verb-resource pair: 'Write a reusable YAML template from an existing agent (its topics, settings and components)'. It names the downstream consumer (cs_create_agent_from_template) and the underlying command, clearly distinguishing it from creation/cloning siblings in the same family.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives useful context — the template is for use in another environment or solution via cs_create_agent_from_template — which implies the cross-environment use case. However, it never explicitly names alternatives (e.g., cs_clone_agent for same-environment duplication) or states when not to use it, leaving differentiation to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools