Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
116 commits
Select commit Hold shift + click to select a range
32f0e6d
bump @apidevtools/json-schema-ref-parser from 14.2.1 to 15.1.3 (#38733)
mikeharder Dec 8, 2025
67ee90e
Sync eng/common directory with azure-sdk-tools for PR 13267 (#39131)
azure-sdk Dec 9, 2025
3528991
Fix Go suppression problem (#39038)
tadelesh Dec 9, 2025
3cb1128
LogGroupStart should have local build output (#39141)
azure-sdk Dec 9, 2025
93c7d7a
[Minor] use arm operations for ov api (#39120)
abaranwal-ms Dec 9, 2025
4705507
Fix comment (#39147)
nick863 Dec 9, 2025
feba0ef
Fix broken links in copilot intructions (#39096)
smw-ms Dec 9, 2025
0d9a770
[arm-auto-signoff] Refactor to code+status pattern (#39149)
mikeharder Dec 9, 2025
722156d
build(deps-dev): bump the eslint group across 2 directories with 1 up…
dependabot[bot] Dec 10, 2025
cd9e490
[Peering] Typespec migration (#38357)
msyyc Dec 10, 2025
68f302a
Add public preview version 2026-01-01-preview to computeschedule for …
haojinglu-dev Dec 10, 2025
a7c8ea6
Revert "Added new API version 2026-01-01-preview to Microsoft.DBforPo…
petarperin-mdcs Dec 10, 2025
d4803cf
Add Dotnet SDK generation for Microsoft.ResourceConnector via TypeSpe…
AzureMarker Dec 10, 2025
4b3818b
Sync eng/common directory with azure-sdk-tools for PR 13134 (#39091)
azure-sdk Dec 10, 2025
e22dcfd
Upgrade typespec 1.7, Azure libraries 0.63 (#39167)
timotheeguerin Dec 10, 2025
f9affc3
Sync eng/common directory with azure-sdk-tools for PR 13281 (#39151)
azure-sdk Dec 10, 2025
be285b3
Sync eng/common directory with azure-sdk-tools for PR 13076 (#39173)
azure-sdk Dec 10, 2025
5e9c3fb
Add #Requires statement to common.ps1 (#39172)
azure-sdk Dec 10, 2025
5ae13c5
bump the targeted proxy version (#39156)
azure-sdk Dec 10, 2025
7e20c77
Sync eng/common directory with azure-sdk-tools for PR 13100 (#39169)
azure-sdk Dec 11, 2025
74db5e7
fix python breaking (#39164)
msyyc Dec 11, 2025
167a19c
Updating documentation based on Cx requirement. (#38982)
Shashank1306s Dec 11, 2025
2bf4f60
Update client setting for Carbon (#39146)
ArthurMa1978 Dec 11, 2025
d25153a
Added new preview api-version (#39184)
mjmadhu Dec 11, 2025
862ba14
[NetAppFiles]Add missing bucket operation (#39143)
audunn Dec 11, 2025
0942611
Add 2026-01-01-preview API version for Microsoft.DevCenter (#39180)
ArberH Dec 11, 2025
e066e73
fix base url typo (#39187)
LakshmanDunna Dec 11, 2025
1595891
Prevent language exclusion when SDK generation fails (#39132)
smw-ms Dec 11, 2025
3d34acb
Sync eng/common directory with azure-sdk-tools for PR 13218 (#39179)
azure-sdk Dec 11, 2025
be841f5
Sync eng/common directory with azure-sdk-tools for PR 13304 (#39190)
azure-sdk Dec 11, 2025
e2ce376
Fix GroupId property access (#39195)
azure-sdk Dec 11, 2025
509e3e2
Sync eng/common directory with azure-sdk-tools for PR 13235 (#39192)
azure-sdk Dec 11, 2025
36369d6
[changed-files.js] Add markdown() filter (#39198)
mikeharder Dec 11, 2025
ee2fa72
[ARM Auto SignOff] Fix casing of workflow name (#39200)
mikeharder Dec 11, 2025
9c17af8
Skip verify setup tool when running on coding agent (#39130)
smw-ms Dec 11, 2025
fdeaba4
Update trigger and PR settings in YAML pipeline (#39194)
azure-sdk Dec 11, 2025
d9eabac
Sync eng/common directory with azure-sdk-tools for PR 13325 (#39203)
azure-sdk Dec 11, 2025
e628469
Sync eng/common directory with azure-sdk-tools for PR 13307 (#39201)
azure-sdk Dec 11, 2025
706a583
[dependabot.yml] Enable for github actions (#39204)
mikeharder Dec 11, 2025
25496b6
Add 2025-09-01 to Main for ACS Email GA (#37848)
ddouglas-msft Dec 12, 2025
342e854
[mysqlflexibleservers] add config for python to keep compatibility (#…
msyyc Dec 12, 2025
d943cf8
build(deps): bump actions/checkout from 4 to 6 (#39206)
dependabot[bot] Dec 12, 2025
9f292a0
build(deps): bump actions/setup-dotnet from 4 to 5 (#39208)
dependabot[bot] Dec 12, 2025
b0ee8ff
build(deps): bump actions/upload-artifact from 4 to 5 (#39207)
dependabot[bot] Dec 12, 2025
7814c23
[TSP Migration][attestation] Migrate attestation to TypeSpec (#37548)
melina5656 Dec 12, 2025
5bcc366
[TypeSpec-Migration] ManagementGroups (#38384)
XiaofeiCao Dec 12, 2025
ceebad7
Add configuration to verify the new code generation (#39024)
mzhongl524 Dec 12, 2025
9259b9b
Add a step explicitly to verify setup (#39213)
azure-sdk Dec 12, 2025
8ddf0b8
Restructure copilot instructions to move typespec and sdk generation …
praveenkuttappan Dec 12, 2025
f2ddf93
Update Chat event to include sequenceId (#39046)
osaghaso Dec 12, 2025
1801af2
[dependabot.yml] Remove cooldown for github-actions (#39222)
mikeharder Dec 12, 2025
ec3df31
Migrate Storage from swagger to TypeSpec (#35403)
welovej Dec 12, 2025
c0ae033
Search tsp rc (#38841)
xiangyan99 Dec 12, 2025
fd8fd88
Omit constructors for Rust Key Vault clients (#39209)
chlowell Dec 12, 2025
2f23a4c
build(deps): bump actions/upload-artifact from 5 to 6 (#39223)
dependabot[bot] Dec 12, 2025
8881d4f
build(deps): bump github/codeql-action from 3 to 4 (#39224)
dependabot[bot] Dec 12, 2025
2264e38
[EngSys] Update default node version from 22 to 24 (#39227)
mikeharder Dec 12, 2025
47e8601
Add 'APIView prod deployment' to internal service connections (#39216)
azure-sdk Dec 12, 2025
924f332
[EngSys] Update default node version from 22 to 24 (part 2) (#39228)
mikeharder Dec 12, 2025
4b2c9cb
Improve Description Per feedback (#39220)
Yuqing-cat Dec 12, 2025
13d73d3
[search] tsp format (#39230)
mikeharder Dec 13, 2025
de80059
build(deps): bump actions/github-script from 7 to 8 (#39205)
dependabot[bot] Dec 13, 2025
261da75
[dependabot.yml] Remove ignores for prettier, vitest, typescript (#39…
mikeharder Dec 13, 2025
162c1c3
[EngSys] Add action to install deps for github-script (#39244)
mikeharder Dec 13, 2025
efa49a1
Azure Databricks 2026-01-01 API Version (#38900)
Yuqing-cat Dec 15, 2025
b971916
Clean up typespec issues in ACR (#39031)
ArcturusZhang Dec 15, 2025
b772ed8
update the typespec and remove the operationId decorator for SAPVirtu…
ArcturusZhang Dec 15, 2025
213be19
[avs] Update client.tsp (#39253)
ChenxiJiang333 Dec 15, 2025
be82b6c
[.github] Rename workflow files from *.yml to *.yaml (#39233)
mikeharder Dec 15, 2025
cb0b423
Update paths to include all files in .github directory for evals (#39…
azure-sdk Dec 15, 2025
bb837f7
Update Quantum Control Plane API adding new 2025-12-15 version with Q…
rigidit Dec 15, 2025
56a7ec9
[.github] Add test to ensure workflows use extension `.yaml` (#39279)
mikeharder Dec 15, 2025
ac51c03
Updated property descriptions for several weather service object prop…
stevemunk Dec 15, 2025
f0a5127
[OpenAI.v1] Updating spec to latest from the new ingestion pipeline. …
glecaros Dec 16, 2025
407461a
[TSV] share a helper to get the last segment of emitter-output-dir (#…
skywing918 Dec 16, 2025
c6a6145
remove package-name in tspconfig.yaml (#39285)
haiyuazhang Dec 16, 2025
315a75f
update (#39254)
welovej Dec 16, 2025
c0f15e4
[Draft] Updates to TextTranslation 2025-10-01-preview (#38621)
jrjrguo Dec 16, 2025
c5c49c6
Update Nginx spec (#39215)
ArthurMa1978 Dec 16, 2025
18609d6
[TSV] Add new rule for python configuration validation for mgmt SDKs …
msyyc Dec 16, 2025
e9b44e3
mgmt, flatten only for autorest (#39252)
weidongxu-microsoft Dec 17, 2025
be31c77
Migrate PostgreSql to TypeSpec (#36556)
mcgallan Dec 17, 2025
e2a00cb
Update emitter output directories in tspconfig.yaml for Confidential …
skywing918 Dec 17, 2025
7ab857c
Storage STG 101 Typespec (#39128)
seanmcc-msft Dec 17, 2025
ee4c603
remove outdated TypeSpecValidation suppressions (#39247)
skywing918 Dec 17, 2025
5001bc8
build(deps-dev): bump @typespec/compiler (#39284)
dependabot[bot] Dec 17, 2025
5df531e
bump prettier from 3.6.2 to 3.7.4 (#39308)
mikeharder Dec 17, 2025
8881cc8
[.github] ignore shared/coverage in eslint (#39312)
mikeharder Dec 17, 2025
0bc88a5
[EngSys] npm update --before 2025-12-16 (#39313)
mikeharder Dec 17, 2025
0f5563c
[TSP Migration]--RedisEnterprise (#38436)
welovej Dec 17, 2025
3a5c9bf
[.github] bump vitest from 3.2.4 to 4.0.15 (#39309)
mikeharder Dec 17, 2025
def6e8d
[eng/tools] Bump @types/node from 18 to 20 (#39314)
mikeharder Dec 17, 2025
d6dc255
Update StorageSync TypeSpec definitions for new .NET MPG support (#39…
ArthurMa1978 Dec 17, 2025
aed3f19
build(deps-dev): bump @azure-tools/spec-gen-sdk from 0.9.3 to 0.9.4 (…
dependabot[bot] Dec 17, 2025
59930ee
Merge GalleryRP 2025-03-03 Features into Main (#38715)
ookoka Dec 17, 2025
c590866
add .net sdk config (#39177)
ryanzhang-oss Dec 17, 2025
48fcf12
Made dotnet SDK validation required (#39318)
raych1 Dec 17, 2025
1927b65
Remove Invoke-ToolDescriptionEvaluator script (#39321)
azure-sdk Dec 17, 2025
a1ea06e
Rename body (#39265)
xiangyan99 Dec 17, 2025
edc6c7e
Bump @microsoft.azure/openapi-validator-rulesets from 2.1.10 to 2.2.0…
tejaswiMinnu Dec 18, 2025
19c21a8
Dell public swagger API release (#39310)
KajalSethi Dec 18, 2025
96392fc
typespec move for november preview (#38980)
abaranwal-ms Dec 18, 2025
3fde27c
Update client setting of Terraform (#39304)
ArthurMa1978 Dec 18, 2025
f3ea045
update descriptions for execute create and delete (#39218)
NneOkeke Dec 18, 2025
bde57df
[EngSys] npm update --before 2025-12-17 (#39336)
mikeharder Dec 18, 2025
a0203e3
[eng/tools] bump vitest from 3.2.4 to 4.0.15 (#39315)
mikeharder Dec 18, 2025
e5bd77c
Set StagedArtifactsFolder to empty if it's undefined (#39303)
raych1 Dec 18, 2025
1c6d377
build(deps-dev): bump @azure-tools/spec-gen-sdk from 0.9.4 to 0.9.5 (…
dependabot[bot] Dec 19, 2025
4e8946e
build(deps-dev): bump @azure-tools/typespec-client-generator-core (#3…
dependabot[bot] Dec 19, 2025
5214e00
fix flatten breakings for avs (#39325)
kazrael2119 Dec 19, 2025
c920bd9
Add swagger and typespec `module` version suffix (#39133)
jliusan Dec 19, 2025
651744e
Cleaned up obsolete content (#39225)
raych1 Dec 19, 2025
39a03af
[typespec-requirement] enable eslint (#39348)
mikeharder Dec 19, 2025
1253854
[eslint] Enable debug category "eslint:linter" (#39349)
mikeharder Dec 19, 2025
0c932f4
[tsp-client-tests] enable eslint (#39350)
mikeharder Dec 19, 2025
fc439d5
Merge branch main into release-feature/cplat-2025-11-01
azure-sdk Dec 19, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions .github/actions/install-deps-github-script/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: Install dependencies for github-script actions
description: Installs dependencies for github-script actions

runs:
using: composite

steps:
- uses: ./.github/actions/setup-node-install-deps
with:
# actions/github-script@v8 uses Node 24
node-version: 24.x
# "--no-audit": improves performance
# "--omit dev": not needed at runtime, improves performance
install-command: "npm ci --no-audit --omit dev"
working-directory: ./.github
2 changes: 1 addition & 1 deletion .github/actions/setup-node-install-deps/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: Uses specified Node version and installs dependencies (typically us
inputs:
node-version:
description: "Node version to use"
default: 22.x
default: 24.x
install-command:
description: "Command to install dependencies"
default: "npm ci"
Expand Down
371 changes: 14 additions & 357 deletions .github/copilot-instructions.md

Large diffs are not rendered by default.

14 changes: 4 additions & 10 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
- package-ecosystem: "npm"
directories:
- "/"
Expand All @@ -20,11 +24,6 @@ updates:
ignore:
# Updated manually to align with minimum supported Node version
- dependency-name: "@types/node"
# Updated manually to align with repo microsoft/typespec
- dependency-name: "@vitest/coverage-v8"
- dependency-name: "prettier"
- dependency-name: "vitest"
- dependency-name: "typescript"
# Updated manually by the Liftr team
- dependency-name: "@azure-tools/typespec-liftr-base"
# Only allow patch updates for spec-gen-sdk
Expand Down Expand Up @@ -57,11 +56,6 @@ updates:
ignore:
# Updated manually to align with minimum supported Node version
- dependency-name: "@types/node"
# Updated manually to align with repo microsoft/typespec
- dependency-name: "@vitest/coverage-v8"
- dependency-name: "prettier"
- dependency-name: "vitest"
- dependency-name: "typescript"
# Points to "github:actions/github-script" since package isn't published to npmjs
- dependency-name: "@types/github-script"
groups:
Expand Down
19 changes: 14 additions & 5 deletions .github/eslint.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,16 @@
import { defineConfig } from "eslint/config";
import { defineBaseConfig } from "./shared/eslint.base.config.js";

export default defineBaseConfig({
// ensures the tsconfig path resolves relative to this file (so cannot be defined in base file)
// default is process.cwd() when running eslint, which may be incorrect
tsconfigRootDir: import.meta.dirname,
});
export default defineConfig(
defineBaseConfig({
// ensures the tsconfig path resolves relative to this file (so cannot be defined in base file)
// default is process.cwd() when running eslint, which may be incorrect
tsconfigRootDir: import.meta.dirname,
}),
{
ignores: [
// generated by `vitest --coverage`
"shared/coverage/**",
],
},
);
18 changes: 18 additions & 0 deletions .github/instructions/github-codingagent.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Run SDK generation using pipeline in GitHub coding agent

Run only SDK generation using pipeline and do not run SDK generation using local SDK generation tools. This is applicable only when GitHub copilot coding agent is used to generate SDK and if a Release Plan is available in the context. Run SDK generation tool even if release plan already has SDK generation pipeline URL to support regenerating SDK. Coding agent must wait until all SDK generation pipeline are in completed status and then fetch the SDK details from pipeline run. This is applicable only when a GitHub issue is assigned to GitHub coding agent to generate SDK from a TypeSpec project. This is not applicable when running Copilot from Visual Studio and VS Code.

## Additional instructions:

- Run SDK generation pipeline for the given TypeSpec path for all languages mentioned in the description.
- Identify absolute path of TypeSpec project root path and send it to Run SDK generation MCP tool call.
- Keep checking the pipeline status every 10 minutes until pipeline is in completed or failed status.
- Find SDK pull request links from the pipeline run.
- Do not mark as language as excluded in the release plan just because SDK generation pipeline failed for that language. Inform user about the failure and suggest to check pipeline logs for more information.
- Do not run verify setup, TypeSpec validation, service label check and analyze pipeline tools when running SDK generation using GitHub coding agent.

## Constraints:

- Do not invoke other steps.
- Do not modify main.tsp file or any files in TypeSpec project.
- Do not add API version to an existing main.tsp if input API version is not present.
35 changes: 35 additions & 0 deletions .github/instructions/language-emitter.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
Use this guidance whenever someone needs to add language emitters to an existing `tspconfig.yaml`, or when SDK generation fails because an emitter block is missing.

- Decide whether the service is ARM or data-plane.
- Open the matching widget `tspconfig.yaml` template.
- Copy the entire emitter block for the requested language.
- Replace every `Widget`/`widget` token with the service name and drop the block under `options:`.

## 1. Identify the service type

- Path contains `/resource-manager/` or linter references `@azure-tools/typespec-azure-rulesets/resource-manager` → ARM
- Path contains `/data-plane/` or linter references `@azure-tools/typespec-azure-rulesets/data-plane` → Data plane

## 2. Reference the official widget template

- ARM: `specification/widget/resource-manager/Microsoft.Widget/Widget/tspconfig.yaml`
- Data plane: `specification/widget/data-plane/WidgetAnalytics/tspconfig.yaml`

Always read the template before editing so you follow the canonical configuration.

## 3. Copy and customize the emitter block

- Select the entire block for the language.
- Only replace service-specific tokens (`Widget`, `widget`, namespaces, package names) with your service name.
- Leave the rest of the properties (`flavor`, boolean flags, `{service-dir}` placeholders, etc.) unchanged.

## 4. Insert into the project config

- Paste the customized block under `options:` in the target `tspconfig.yaml`, keeping YAML indentation intact.
- Confirm the `parameters:` section defines `"service-dir"` (for example `sdk/<servicename>`); add it if missing.

**Quick checks**

- Do not mix ARM and data-plane templates.
- Do not cherry-pick individual properties—copy the whole block or errors will persist.
- If the SDK pipeline still reports missing configuration, re-open the template and verify every `Widget` reference was replaced.
145 changes: 145 additions & 0 deletions .github/instructions/sdk-generation.instructions.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,145 @@
## Prerequisites

- run `npm ci` to install the dependencies
- To use Azure MCP tool calls, the user must have PowerShell installed. Provide [PowerShell installation instructions](https://learn.microsoft.com/powershell/scripting/install/installing-powershell) if not installed, and recommend restarting the IDE to start the MCP server.
- When using Copilot from Visual Studio or VS Code (not applicable when using Coding Agent on Github.com):
- **Always run** the [`azsdk_verify_setup`](../../eng/common/instructions/azsdk-tools/verify-setup.instructions.md) tool first to validate the user's development environment for SDK MCP tools.
- **Do not proceed** with any other tool execution until this step is complete.
- **Skip this check only** for queries that do not require tool execution.

## Basic Rules for SDK Generation from TypeSpec

1. **User Guidance**:
- Assume the user is unfamiliar with the SDK release process. Provide clear, concise instructions for each step.

2. **File Handling**:
- Do not overwrite `tspconfig.yaml` or `main.tsp`. Use existing files and suggest updates if necessary.
- Use the path of the `tspconfig.yaml` file or the `.tsp` file path as the project root.
- If no `.tsp` file or folder is in the current context, prompt the user to select a valid TypeSpec project root path.

3. **Process Visibility**:
- Highlight all steps in the SDK generation process, showing completed and remaining steps.
- Do not skip any main steps. Ensure all steps are completed before moving to the next.

4. **Git Operations**:
- Avoid using the `main` branch for pull requests. Prompt the user to create or switch to a new branch if necessary.
- Display git commands (e.g., `git checkout`, `git add`, `git commit`, `git push`) with a "Run" button instead of
asking the user to copy and paste.
- Do not run `git diff`

5. **Azure-Specific Rules**:
- Always use `Azure` as the repo owner in MCP tool calls.
- Confirm with the user if they want to change the repo owner or target branch, and prompt for new values if needed.

6. **Exclusions**:
- Exclude changes to the `.gitignore` file and contents within the `.github` and `.vscode` folders from API spec and SDK pull requests.

7. **Working Branch Rule**:
- If the typespec pull request already exists or is merged stay on the `main` branch, otherwise ensure the TypeSpec project repository and the current working repository are not on the `main` branch:
- Check the current branch name for the cloned GitHub repository:
- If the current branch is `main`, prompt the user to create a new branch using
`git checkout -b <branch name>`.
- If the current branch is not `main`, prompt the user to either select an existing branch or create a
new one.
- For branch switching:
- If a branch already exists and differs from the current branch, prompt the user to switch using
`git checkout <branch name>`.
- GitHub pull requests cannot be created from the `main` branch. Ensure all changes are made on a non-`main` branch.

8. **Language Exclusion Policy**:
- **CRITICAL**: Mark a language as excluded in a release plan **ONLY** when the language emitter configuration is intentionally missing or not configured in the `tspconfig.yaml` file.
- **DO NOT** mark a language as excluded if:
- SDK generation pipeline fails due to compilation errors, validation errors, or other technical issues
- The language emitter is configured in `tspconfig.yaml` but the pipeline encounters runtime errors
- There are temporary infrastructure or service issues causing pipeline failures
- **DO** mark a language as excluded if:
- The language emitter configuration is intentionally missing from `tspconfig.yaml`
- The service team has made a deliberate decision not to support a particular language
- The user provides explicit justification for not including a language in the release
- **When SDK generation fails**:
- Investigate the pipeline failure logs to identify the root cause
- Help the user fix compilation errors, configuration issues, or other problems
- Re-run the SDK generation pipeline after fixes are applied
- Only suggest language exclusion if the user explicitly states the language will not be supported

By following these rules, the SDK release process will remain clear, structured, and user-friendly.

## Steps to generate SDK from TypeSpec API specification

Follow below steps to generate and release SDK from TypeSpec API specification. The process is divided into several steps, each with specific actions to ensure a smooth SDK generation and release process.
Do not skip the step that choose SDK generation method to ensure the user selects the appropriate method for SDK generation, either locally or using the SDK generation pipeline. Do not repeat the steps. Before using tools, check if user has Powershell installed.

Your goal is to guide the user through the process of generating SDKs from TypeSpec projects. **Before starting**, show all the high level steps to the user and ask:

> "Would you like to begin the SDK generation process now? (yes/no)"

Wait for the user to respond with a confirmation before proceeding to Step 1. Use the provided tools to perform actions and gather information as needed.

### Verify API spec

Step 1: Identify TypeSpec Project
**Goal**: Locate the TypeSpec project root path
**Actions**:

1. Check if `tspconfig.yaml` or `main.tsp` files are open in editor
2. If found, use the parent directory as project root
3. If not found, prompt user: "Please provide the path to your TypeSpec project root directory"
4. Validate the provided path contains required TypeSpec files main.tsp and tspconfig.yaml
5. Run `azsdk_typespec_check_project_in_public_repo` to verify repository
6. If not in public repo, inform: "Please make spec changes in Azure/azure-rest-api-specs public repo to generate SDKs". User can still generate SDKs locally from private repo but they should not push the changes to public SDK repo.
**Success Criteria**: Valid TypeSpec project path identified

Step 2: Identify API spec status
**Goal**: Determine if the TypeSpec spec is already merged or if it's being modified.
**Actions**:

1. Prompt user to confirm if the TypeSpec spec is already merged in the main branch of https://github.com/Azure/azure-rest-api-specs : "Is your TypeSpec specification already merged in the main branch of repository(https://github.com/Azure/azure-rest-api-specs)? (yes/no)"
2. If already merged, follow the steps in [typespec to sdk](../../eng/common/instructions/azsdk-tools/typespec-to-sdk.instructions.md) to generate the SDK
3. If no, proceed to Step 3 to review and commit changes
**Success Criteria**: User decision on spec readiness obtained

Step 3: Validate TypeSpec Specification
**Goal**: Ensure TypeSpec specification compiles without errors. Provide a complete summary after running the tool. Highlight any errors and help user fix them.
**Condition**: Only if the spec is not already merged (from Step 2)
**Message to user**: "TypeSpec validation takes around 20 - 30 seconds."
**Actions**:

1. Run `azsdk_run_typespec_validation` to validate the TypeSpec project.
2. If validation succeeds, proceed to Step 4
3. If validation fails: - Display all compilation errors to user - Agent should provide suggestions to fix them and prompt the user to verify the fixes. If agent cannot resolve the errors, then prompt the user to fix compilation errors" - Wait for user to fix errors and re-run validation. Provide detailed information about all the changes done by copilot and prompt the user before rerunning the validation.
**Success Criteria**: TypeSpec compilation passes without errors

Step 4: Review and Commit Changes
**Goal**: Stage and commit TypeSpec modifications
**Condition**: Only if the TypeSpec validation succeeds (from Step 3)
**Actions**:

1. Run `azsdk_get_modified_typespec_projects` to identify changes
2. If no changes found, inform: "No TypeSpec projects were modified in current branch" and go to SDK generation mentioned in [typespec to sdk](../../eng/common/instructions/azsdk-tools/typespec-to-sdk.instructions.md).
3. Display all modified files (excluding `.github` and `.vscode` folders)
4. Prompt user: "Please review the modified files. Do you want to commit these changes? (yes/no)"
5. If yes: - If on main branch, prompt user: "You are currently on the main branch. Please create a new branch using `git checkout -b <branch-name>` before proceeding." - Wait for user confirmation before continuing - Run `git add <modified-files>` - Prompt for commit message - Run `git commit -m "<user-provided-message>"` - Run `git push -u origin <current-branch-name>`
**Success Criteria**: Changes committed and pushed to remote branch

Step 5: Create Specification Pull Request
**Goal**: Create PR for TypeSpec changes if not already created
**Condition**: Only if there are committed changes (from Step 4)
**Actions**:

1. Prompt the user to confirm if a pull request already exists for API spec changes. If answer is no or unsure then check if spec PR already exists using `azsdk_get_pull_request_link_for_current_branch`
2. If PR exists, display PR details and proceed to next steps in SDK generation.
3. If no PR exists:
- Inform user: "No pull request found for the current branch. Proceeding to create a new pull request."
- Create a pull request using `azsdk_create_pull_request_for_current_branch`
- Prompt for PR title and description
- Display PR creation progress
- Wait for PR creation confirmation
- Display created PR details
4. Inform the user to follow the instructions on spec PR to get approval from API reviewers and merge the spec PR.
**Success Criteria**: Specification pull request exists

Follow the steps in [typespec to sdk](../../eng/common/instructions/azsdk-tools/typespec-to-sdk.instructions.md) to generate the SDK.

## SDK customizations in TypeSpec projects

TypeSpec supports making client-specific customizations to a TypeSpec project to change how an SDK is generated. When making client-specific changes, read the [typespec client customizations reference](../../eng/common/knowledge/customizing-client-tsp.md) to understand the types of customizations supported and how to apply them.
Loading