Skip to content

Commit

Permalink
CodeGen from PR 30740 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge cc78cbf121fbc0b76982b89966bd65894a4f840b into 252cde28dc55358e310b177ee2de6a6c12cf12a4
  • Loading branch information
SDKAuto committed Sep 26, 2024
1 parent 4623dc4 commit 82ef45d
Show file tree
Hide file tree
Showing 177 changed files with 13,315 additions and 13,814 deletions.
887 changes: 466 additions & 421 deletions common/config/rush/pnpm-lock.yaml

Large diffs are not rendered by default.

18 changes: 8 additions & 10 deletions sdk/changes/arm-changes/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
# Release History

## 1.1.1 (Unreleased)

### Features Added


## 2.0.0 (2024-09-26)

### Breaking Changes

### Bugs Fixed

### Other Changes

- Interface ChangesListNextOptionalParams no longer has parameter skipToken
- Interface ChangesListNextOptionalParams no longer has parameter top
## 1.1.0 (2022-11-17)

### Features Added
Expand All @@ -19,4 +17,4 @@

## 1.0.0 (2022-05-09)

The package of @azure/arm-changes is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ).
The package of @azure/arm-changes is using our next generation design principles. To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart).
2 changes: 1 addition & 1 deletion sdk/changes/arm-changes/LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) 2022 Microsoft
Copyright (c) 2024 Microsoft

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down
8 changes: 4 additions & 4 deletions sdk/changes/arm-changes/_meta.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"commit": "20df2424a278ca19437e437a7dbf3a7857a0dd9d",
"commit": "0c82922a9310ff9d53b46d7b9dda62412bdbac31",
"readme": "specification/resources/resource-manager/readme.md",
"autorest_command": "autorest --version=3.8.4 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=D:\\Git\\azure-sdk-for-js ..\\azure-rest-api-specs\\specification\\resources\\resource-manager\\readme.md --use=@autorest/[email protected].0-rc.3.20221108.1 --generate-sample=true",
"autorest_command": "autorest --version=3.9.7 --typescript --modelerfour.lenient-model-deduplication --azure-arm --head-as-boolean=true --license-header=MICROSOFT_MIT_NO_VERSION --generate-test --typescript-sdks-folder=/mnt/vss/_work/1/s/azure-sdk-for-js ../azure-rest-api-specs/specification/resources/resource-manager/readme.md --use=@autorest/typescript@^6.0.12",
"repository_url": "https://github.com/Azure/azure-rest-api-specs.git",
"release_tool": "@azure-tools/js-sdk-release-tools@2.4.2",
"use": "@autorest/[email protected].0-rc.3.20221108.1"
"release_tool": "@azure-tools/js-sdk-release-tools@2.7.14",
"use": "@autorest/typescript@^6.0.12"
}
37 changes: 15 additions & 22 deletions sdk/changes/arm-changes/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
"sdk-type": "mgmt",
"author": "Microsoft Corporation",
"description": "A generated SDK for ChangesClient.",
"version": "1.1.1",
"version": "2.0.0",
"engines": {
"node": ">=18.0.0"
},
"dependencies": {
"@azure/core-paging": "^1.2.0",
"@azure/core-client": "^1.6.1",
"@azure/core-auth": "^1.3.0",
"@azure/core-rest-pipeline": "^1.8.0",
"@azure/core-client": "^1.7.0",
"@azure/core-auth": "^1.6.0",
"@azure/core-rest-pipeline": "^1.14.0",
"tslib": "^2.2.0"
},
"keywords": [
Expand All @@ -28,22 +28,23 @@
"devDependencies": {
"@microsoft/api-extractor": "^7.31.1",
"mkdirp": "^3.0.1",
"typescript": "~5.6.2",
"typescript": "~5.5.3",
"uglify-js": "^3.4.9",
"rimraf": "^5.0.5",
"@azure/identity": "^4.0.1",
"rimraf": "^5.0.0",
"dotenv": "^16.0.0",
"@azure/dev-tool": "^1.0.0",
"@azure/identity": "^4.2.1",
"@azure-tools/test-recorder": "^3.0.0",
"@azure-tools/test-credential": "^1.0.0",
"@azure-tools/test-credential": "^1.1.0",
"mocha": "^10.0.0",
"@types/mocha": "^10.0.0",
"tsx": "^4.7.1",
"@types/chai": "^4.2.8",
"chai": "^4.2.0",
"cross-env": "^7.0.2",
"@types/node": "^18.0.0",
"@azure/dev-tool": "^1.0.0",
"ts-node": "^10.0.0",
"@types/mocha": "^10.0.0"
"ts-node": "^10.0.0"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/changes/arm-changes",
"repository": {
"type": "git",
"url": "https://github.com/Azure/azure-sdk-for-js.git"
Expand Down Expand Up @@ -75,7 +76,6 @@
"pack": "npm pack 2>&1",
"extract-api": "dev-tool run extract-api",
"lint": "echo skipped",
"audit": "echo skipped",
"clean": "rimraf --glob dist dist-browser dist-esm test-dist temp types *.tgz *.log",
"build:node": "echo skipped",
"build:browser": "echo skipped",
Expand Down Expand Up @@ -104,12 +104,5 @@
]
},
"autoPublish": true,
"//sampleConfiguration": {
"productName": "",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://docs.microsoft.com/javascript/api/@azure/arm-changes?view=azure-node-preview"
}
}
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/changes/arm-changes"
}
2 changes: 0 additions & 2 deletions sdk/changes/arm-changes/review/arm-changes.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,6 @@ export type ChangesGetResponse = ChangeResourceResult;

// @public
export interface ChangesListNextOptionalParams extends coreClient.OperationOptions {
skipToken?: string;
top?: number;
}

// @public
Expand Down
29 changes: 15 additions & 14 deletions sdk/changes/arm-changes/src/changesClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import * as coreRestPipeline from "@azure/core-rest-pipeline";
import {
PipelineRequest,
PipelineResponse,
SendRequest
SendRequest,
} from "@azure/core-rest-pipeline";
import * as coreAuth from "@azure/core-auth";
import { ChangesImpl } from "./operations";
Expand All @@ -33,7 +33,7 @@ export class ChangesClient extends coreClient.ServiceClient {
constructor(
credentials: coreAuth.TokenCredential,
subscriptionId: string,
options?: ChangesClientOptionalParams
options?: ChangesClientOptionalParams,
) {
if (credentials === undefined) {
throw new Error("'credentials' cannot be null");
Expand All @@ -48,10 +48,10 @@ export class ChangesClient extends coreClient.ServiceClient {
}
const defaults: ChangesClientOptionalParams = {
requestContentType: "application/json; charset=utf-8",
credential: credentials
credential: credentials,
};

const packageDetails = `azsdk-js-arm-changes/1.1.1`;
const packageDetails = `azsdk-js-arm-changes/2.0.0`;
const userAgentPrefix =
options.userAgentOptions && options.userAgentOptions.userAgentPrefix
? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
Expand All @@ -61,20 +61,21 @@ export class ChangesClient extends coreClient.ServiceClient {
...defaults,
...options,
userAgentOptions: {
userAgentPrefix
userAgentPrefix,
},
endpoint:
options.endpoint ?? options.baseUri ?? "https://management.azure.com"
options.endpoint ?? options.baseUri ?? "https://management.azure.com",
};
super(optionsWithDefaults);

let bearerTokenAuthenticationPolicyFound: boolean = false;
if (options?.pipeline && options.pipeline.getOrderedPolicies().length > 0) {
const pipelinePolicies: coreRestPipeline.PipelinePolicy[] = options.pipeline.getOrderedPolicies();
const pipelinePolicies: coreRestPipeline.PipelinePolicy[] =
options.pipeline.getOrderedPolicies();
bearerTokenAuthenticationPolicyFound = pipelinePolicies.some(
(pipelinePolicy) =>
pipelinePolicy.name ===
coreRestPipeline.bearerTokenAuthenticationPolicyName
coreRestPipeline.bearerTokenAuthenticationPolicyName,
);
}
if (
Expand All @@ -84,7 +85,7 @@ export class ChangesClient extends coreClient.ServiceClient {
!bearerTokenAuthenticationPolicyFound
) {
this.pipeline.removePolicy({
name: coreRestPipeline.bearerTokenAuthenticationPolicyName
name: coreRestPipeline.bearerTokenAuthenticationPolicyName,
});
this.pipeline.addPolicy(
coreRestPipeline.bearerTokenAuthenticationPolicy({
Expand All @@ -94,9 +95,9 @@ export class ChangesClient extends coreClient.ServiceClient {
`${optionsWithDefaults.endpoint}/.default`,
challengeCallbacks: {
authorizeRequestOnChallenge:
coreClient.authorizeRequestOnClaimChallenge
}
})
coreClient.authorizeRequestOnClaimChallenge,
},
}),
);
}
// Parameter assignments
Expand All @@ -118,7 +119,7 @@ export class ChangesClient extends coreClient.ServiceClient {
name: "CustomApiVersionPolicy",
async sendRequest(
request: PipelineRequest,
next: SendRequest
next: SendRequest,
): Promise<PipelineResponse> {
const param = request.url.split("?");
if (param.length > 1) {
Expand All @@ -132,7 +133,7 @@ export class ChangesClient extends coreClient.ServiceClient {
request.url = param[0] + "?" + newParams.join("&");
}
return next(request);
}
},
};
this.pipeline.addPolicy(apiVersionPolicy);
}
Expand Down
7 changes: 1 addition & 6 deletions sdk/changes/arm-changes/src/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -192,12 +192,7 @@ export type ChangesGetResponse = ChangeResourceResult;

/** Optional parameters. */
export interface ChangesListNextOptionalParams
extends coreClient.OperationOptions {
/** (Optional) Set the maximum number of results per response. */
top?: number;
/** (Optional) The page-continuation token */
skipToken?: string;
}
extends coreClient.OperationOptions {}

/** Contains response data for the listNext operation. */
export type ChangesListNextResponse = ChangeResourceListResult;
Expand Down
Loading

0 comments on commit 82ef45d

Please sign in to comment.