azsdk-common-generate-sdk-locally
Skill206 starsChanged 8 months agoMITView on GitHub
Generate, build, and test Azure SDKs locally from TypeSpec with automatic customization. WHEN: \"generate SDK locally\", \"build SDK\", \"run SDK tests\", \"run CI checks\", \"validate package\", \"run checks\", \"update changelog\", \"fix SDK build errors\", \"fix breaking changes\", \"resolve SDK generation errors\", \"customize TypeSpec\", \"rename SDK client\", \"rename SDK model\", \"hide operation from SDK\", \"fix analyzer errors\", \"resolve customization drift\", \"create subclient\", \"update metadata\", \"update version\". DO NOT USE FOR: publishing to package registries, CI pipeline configuration, API design review. INVOKES: azsdk_verify_setup, azsdk_package_generate_code, azsdk_package_build_code, azsdk_package_run_check, azsdk_package_run_tests, azsdk_customized_code_update, azsdk_package_update_changelog_content, azsdk_package_update_metadata, azsdk_package_update_version.
7 other projects use a version of this, 6 of them edited.
Adopted by
Most recently taken up by
- Azure/azure-sdkedited, first seen Sep 18, 2026
- Azure/azure-sdk-toolsedited, first seen Aug 31, 2026
- Azure/azure-sdk-for-iosword for word, first seen Jun 12, 2026
- Azure/azure-sdk-for-netedited, first seen Apr 18, 2026
- Azure/azure-sdk-for-javaedited, first seen Mar 18, 2025
- Azure/azure-sdk-for-jsedited, first seen Mar 18, 2025
Other versions7 projects use a version of this.
Word for word · 1
- Azure/azure-sdk-for-ios★ 197100% same
Edited · 6
- Azure/azure-sdk-for-net★ 6.1k100% same
- Azure/azure-sdk-for-python★ 5.6k67% same
- Azure/azure-sdk-for-java★ 2.6k67% same
- Azure/azure-sdk-for-js★ 2.3k67% same
- Azure/azure-sdk★ 600100% same
- Azure/azure-sdk-tools★ 13467% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository11 other files it gives its agents.
- AGENTS.mdAGENTS.md
- sdk/storage/AGENTS.mdAGENTS.md
- sdk/storage/azure-storage-blobs/AGENTS.mdAGENTS.md
- sdk/storage/azure-storage-files-datalake/AGENTS.mdAGENTS.md
- sdk/storage/azure-storage-files-shares/AGENTS.mdAGENTS.md
- .github/copilot-instructions.mdCopilot instructions
- azsdk-common-apiview-feedback-resolutionSkill
- azsdk-common-pipeline-troubleshootingSkill
- azsdk-common-prepare-release-planSkill
- azsdk-common-sdk-releaseSkill
- code-reviewSkill
The file
We split this skill into the rules it gives an agent
8 rules. 3 are common, 1 is distinctive, and 4 are very specific to this project.
3
Common
Most of the 6 edited versions we read keep these.
1
Distinctive
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- could be automatic: a setting could enforce it
- Distinctive: line 19
DO NOT USE FOR: publishing to package registries, CI pipeline configuration, API design review
- Common: line 24
Verify the target language repo and the correct TypeSpec configuration file before generation.
- Common: line 25
After generation or customization, run the check and test steps before updating metadata or finalizing changes.
- Very specific: line 64
If azure-sdk-mcp:azsdk_customized_code_update fails or times out, report the error to the user and suggest retrying.
- Common: line 65
Only the customization tool understands the correct layering of TypeSpec decorators vs code patches and ensures regenerated code stays …
- Very specific: line 86
Run azure-sdk-mcp:azsdk_verify_setup to confirm MCP and tools.
- Very specific: line 87
If build fails with type conflicts, breaking changes, analyzer errors, or customization drift, use …
- Very specific: line 89
If azure-sdk-mcp:azsdk_customized_code_update fails or times out, report the error and retry.
“Common” is measured: kept by at least 6 in 10 of the 6 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Generate SDK Locally
This skill generates, builds, and tests Azure SDKs locally from TypeSpec with automatic customization support, covering the end-to-end workflow for fixing generation issues, applying SDK-specific updates, and refreshing package metadata when needed.
Triggers
USE FOR: generate, build, and test Azure SDKs locally from TypeSpec with automatic customization; update changelog; fix SDK build errors; fix breaking changes; resolve SDK generation errors; customize TypeSpec; rename SDK client or model; hide operation from SDK; fix analyzer errors; resolve customization drift; create subclient; update metadata; update version WHEN: "generate SDK locally", "build SDK", "run SDK tests", "update changelog", "fix SDK build errors", "fix breaking changes", "resolve SDK generation errors", "customize TypeSpec", "rename SDK client", "rename SDK model", "hide operation from SDK", "fix analyzer errors", "resolve customization drift", "create subclient", "update metadata", "update version" DO NOT USE FOR: publishing to package registries, CI pipeline configuration, API design review
Rules
- Requires the
azure-sdk-mcpserver for the MCP workflow; without MCP, usenpm exec --prefix eng/common/tsp-client -- tsp-clientCLI. - Verify the target language repo and the correct TypeSpec configuration file before generation.
- After generation or customization, run the check and test steps before updating metadata or finalizing changes.
MCP Tools
| Tool | Purpose |
azure-sdk-mcp:azsdk_verify_setup | Verify environment |
azure-sdk-mcp:azsdk_package_generate_code | Generate SDK |
azure-sdk-mcp:azsdk_package_build_code | Build package |
azure-sdk-mcp:azsdk_package_run_check | Validate package |
azure-sdk-mcp:azsdk_package_run_tests | Run tests |
azure-sdk-mcp:azsdk_customized_code_update | Apply customizations (includes regeneration and build) |
azure-sdk-mcp:azsdk_package_update_changelog_content | Update changelog |
azure-sdk-mcp:azsdk_package_update_metadata | Update metadata including ci.yml |
azure-sdk-mcp:azsdk_package_update_version | Update version |
Prerequisites: azure-sdk-mcp server must be running. Without MCP, use npx tsp-client CLI.
Steps
- Select language — Confirm target language: .NET, Java, JavaScript, Python, Go, or Rust.
- Verify repo — Ensure the user has a local clone of the correct SDK repo. If not cloned, instruct user to clone it.
- Identify config file — Determine the path to the TypeSpec configuration file. See config file details.
- From
azure-rest-api-specsrepo: use path totspconfig.yaml. - From an SDK language repo: use path to
tsp-location.yaml.
- From
- Verify setup — Run
azure-sdk-mcp:azsdk_verify_setupto confirm environment. - Generate — Run
azure-sdk-mcp:azsdk_package_generate_codewith the config file path. - Build — Run
azure-sdk-mcp:azsdk_package_build_code. If build succeeds, proceed to step 8. - Customize — If build fails, or if user requests SDK modifications, run
azure-sdk-mcp:azsdk_customized_code_updatewith the build errors or user request. The tool handles the full workflow internally: it classifies the issue, applies TypeSpec decorators and/or code patches, regenerates the SDK, and builds — all in one call. See customization workflow. - Commit checkpoint — Prompt the user to commit generated changes before proceeding. See commit checkpoint details.
- Validate — Run
azure-sdk-mcp:azsdk_package_run_checkandazure-sdk-mcp:azsdk_package_run_tests. - Metadata — Run
azure-sdk-mcp:azsdk_package_update_changelog_content,azure-sdk-mcp:azsdk_package_update_metadata, andazure-sdk-mcp:azsdk_package_update_version. (Note: For .NET data plane, skip this step — metadata, changelog, and version updates are per-commit tasks, not part of the generate/build/test workflow.) - Final commit — Prompt the user to commit final changes (changelog, metadata, version). See commit checkpoint details.
SDK repos | Customization workflow | Detailed workflow
Guardrails
- NEVER modify generated SDK code files directly for customizations. Always use
azure-sdk-mcp:azsdk_customized_code_update. It handles classification, TypeSpec decorators, code patches, regeneration, and build as a single atomic workflow. - If
azure-sdk-mcp:azsdk_customized_code_updatefails or times out, report the error to the user and suggest retrying. Do not attempt to replicate its behavior by editing files manually. - Only the customization tool understands the correct layering of TypeSpec decorators vs code patches and ensures regenerated code stays consistent.
Examples
- "Generate the SDK locally for my TypeSpec service"
- "Build and test the Python SDK package"
- "Run CI checks for my SDK package"
- "Fix the SDK build errors on this PR"
- "The SDK generation has breaking changes, resolve them"
- "Rename FooClient to BarClient for .NET"
- "Hide the internal polling operation from the Python SDK"
- "Fix .NET analyzer errors AZC0030 and AZC0012"
- "The build is failing because a customization references a renamed property"
- "Create a subclient architecture for the Python SDK"
- "Apply TypeSpec customizations to fix compilation errors"
- "Update the changelog for this SDK package"
- "Update the package version"
- "Update the package metadata and ci.yml"
Troubleshooting
- Run
azure-sdk-mcp:azsdk_verify_setupto confirm MCP and tools. - If build fails with type conflicts, breaking changes, analyzer errors, or customization drift, use
azure-sdk-mcp:azsdk_customized_code_updateto apply customizations. - The customization tool uses a two-phase approach: TypeSpec decorators first (Phase A), then code repairs if needed (Phase B).
- If
azure-sdk-mcp:azsdk_customized_code_updatefails or times out, report the error and retry. Do not manually edit generated SDK code — manual edits will be overwritten on the next regeneration. - Without MCP, use
npx tsp-clientCLI.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

