You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: "Use this skill when authoring or modifying Azure TypeSpec API specifications in the azure-rest-api-specs repository. Triggers for any TypeSpec related tasks, including: adding new API versions (preview or stable), creating or modifying ARM resources or data-plane services, defining models/enums/unions, adding operations to resources or interfaces, updating TypeSpec definitions for Azure services, or fixing TypeSpec compilation errors. Keywords: TypeSpec, tsp, ARM, resource-manager, data-plane, API version, preview version, stable version, Azure resource, Azure service, resource provider."
4
+
---
5
+
6
+
# Azure TypeSpec Author
7
+
8
+
## Operating Principles (non-negotiable)
9
+
10
+
1.**Do not edit any files until you have required inputs and have retrieved solution** Use the `azure-sdk-mcp/azsdk_typespec_generate_authoring_plan` tool.
11
+
2. Make **minimal, scoped edits** to satisfy the request. Avoid refactors unless explicitly asked.
12
+
3. After edits, **validate** (compile / lint / emitter checks if available) and report results.
13
+
4. Always provide **references** (titles/sections/links) from retrieved context that justify the recommended approach.
14
+
15
+
## Required Inputs Checklist (ask if missing)
16
+
Before planning edits, ensure you have:
17
+
-**Spec root / folder** (where the TypeSpec project lives)
18
+
-**Service Type**: management-plane vs data-plane
19
+
-**Existing API versions**
20
+
-**Target API version(s)** (existing or new; preview/stable)
-**Constraints**: breaking-change limits, naming/versioning rules, emitter targets, etc.
24
+
25
+
If any of the above is missing, ask **up to 6 concise questions** and stop.
26
+
27
+
## Workflow
28
+
29
+
When encountering a TypeSpec authoring cases, follow this workflow (must follow exactly):
30
+
31
+
### Step 1 — Intake & Clarification (no file edits)
32
+
- Read the user request.
33
+
- Extract any provided values for the Required Inputs Checklist.
34
+
- If missing, ask concise questions and wait for the user reply. ask the questions one by one, with each question confirming a specific piece of information.
35
+
36
+
### Step 2 — Retrieve Solution
37
+
38
+
Call the `azure-sdk-mcp/azsdk_typespec_generate_authoring_plan` tool:
39
+
40
+
- Provide the best available arguments derived from the intake:
41
+
- Service Type
42
+
- apiVersion / versions
43
+
- intent
44
+
- resource/interface/operation names
45
+
- key constraints / keywords
46
+
- Use user request (verbatim) as parameter `request`
47
+
- Read the relative code (.tsp) for this request, and put it as `additionalInformation` parameter
48
+
- use typespec project root path as `typeSpecProjectRootPath` parameter
49
+
50
+
### Step 3 — Apply Changes (edits)
51
+
52
+
Only after a grounded plan is produced:
53
+
54
+
- Make the minimal changes required in the relevant `.tsp` files
55
+
- Prefer following the official template/pattern from RETRIEVED_CONTEXT even if the repo has older patterns
56
+
57
+
### Step 4 — Validate
58
+
59
+
- Run `azure-sdk-mcp/azsdk_run_typespec_validation` tool to run validation
60
+
- If validation fails, fix forward with minimal changes
61
+
62
+
### Step 5 — Summarize
63
+
64
+
Return:
65
+
66
+
- Files changed (list)
67
+
- What changed and why (brief)
68
+
- Validation results (pass/fail + key output)
69
+
- References from RETRIEVED_CONTEXT used to justify important decisions
Copy file name to clipboardExpand all lines: specification/network/resource-manager/Microsoft.Network/Network/ApplicationGatewayAvailableSslOptions.tsp
+4-1Lines changed: 4 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -51,12 +51,13 @@ alias ApplicationGatewayAvailableSslOptionsOps = Azure.ResourceManager.Legacy.Ro
51
51
52
52
#suppress"@azure-tools/typespec-azure-core/no-legacy-usage""FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
Copy file name to clipboardExpand all lines: specification/network/resource-manager/Microsoft.Network/Network/ApplicationGatewayWafDynamicManifestResult.tsp
+3-1Lines changed: 3 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -61,12 +61,13 @@ alias ApplicationGatewayWafDynamicManifestResultOps = Azure.ResourceManager.Lega
61
61
62
62
#suppress"@azure-tools/typespec-azure-core/no-legacy-usage""FIXME: Update justification, follow aka.ms/tsp/conversion-fix for details"
Copy file name to clipboardExpand all lines: specification/network/resource-manager/Microsoft.Network/Network/diff-output/ApplicationGateway/API_CHANGES.md
0 commit comments