Skip to content

Commit

Permalink
CodeGen from PR 32481 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 0197e66dba2dd4a222f1d4365b876fbc097a3ffa into 05b150757bd72ad78bd27216e5e662beaa49bd6c
  • Loading branch information
SDKAuto committed Feb 6, 2025
1 parent 6353087 commit 8201eb1
Show file tree
Hide file tree
Showing 42 changed files with 1,034 additions and 530 deletions.
17 changes: 9 additions & 8 deletions common/config/rush/pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

35 changes: 25 additions & 10 deletions sdk/attestation/arm-attestation/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,30 @@
# Release History

## 2.1.1 (Unreleased)

## 2.2.0 (2025-02-06)
### Features Added

### Breaking Changes

### Bugs Fixed

### Other Changes

- Added operation group PrivateLinkResources
- Added Interface AttestationServicePatchSpecificParams
- Added Interface LogSpecification
- Added Interface OperationProperties
- Added Interface PrivateLinkResource
- Added Interface PrivateLinkResourceListResult
- Added Interface PrivateLinkResourcesListByProviderOptionalParams
- Added Interface ServiceSpecification
- Added Type Alias PrivateLinkResourcesListByProviderResponse
- Added Type Alias PublicNetworkAccessType
- Added Type Alias TpmAttestationAuthenticationType
- Interface AttestationProvider has a new optional parameter publicNetworkAccess
- Interface AttestationProvider has a new optional parameter tpmAttestationAuthentication
- Interface AttestationServiceCreationSpecificParams has a new optional parameter publicNetworkAccess
- Interface AttestationServiceCreationSpecificParams has a new optional parameter tpmAttestationAuthentication
- Interface AttestationServicePatchParams has a new optional parameter properties
- Interface OperationsDefinition has a new optional parameter properties
- Added Enum KnownPublicNetworkAccessType
- Added Enum KnownTpmAttestationAuthenticationType


## 2.1.0 (2022-11-16)

### Features Added
Expand Down Expand Up @@ -38,4 +53,4 @@ To understand the detail of the change, please refer to [Changelog](https://aka.

To migrate the existing applications to the latest version, please refer to [Migration Guide](https://aka.ms/js-track2-migration-guide).

To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart ).
To learn more, please refer to our documentation [Quick Start](https://aka.ms/azsdk/js/mgmt/quickstart).
8 changes: 4 additions & 4 deletions sdk/attestation/arm-attestation/LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Copyright (c) Microsoft Corporation.
The MIT License (MIT)

MIT License
Copyright (c) 2025 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 All @@ -12,10 +12,10 @@ furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED *AS IS*, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
SOFTWARE.
36 changes: 13 additions & 23 deletions sdk/attestation/arm-attestation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,36 +44,27 @@ npm install @azure/identity
```

You will also need to **register a new AAD application and grant access to Azure AttestationManagement** by assigning the suitable role to your service principal (note: roles such as `"Owner"` will not grant the necessary permissions).
Set the values of the client ID, tenant ID, and client secret of the AAD application as environment variables: `AZURE_CLIENT_ID`, `AZURE_TENANT_ID`, `AZURE_CLIENT_SECRET`.

For more information about how to create an Azure AD Application check out [this guide](https://learn.microsoft.com/azure/active-directory/develop/howto-create-service-principal-portal).

Using Node.js and Node-like environments, you can use the `DefaultAzureCredential` class to authenticate the client.

```ts snippet:ReadmeSampleCreateClient_Node
import { AttestationManagementClient } from "@azure/arm-attestation";
import { DefaultAzureCredential } from "@azure/identity";
```javascript
const { AttestationManagementClient } = require("@azure/arm-attestation");
const { DefaultAzureCredential } = require("@azure/identity");
// For client-side applications running in the browser, use InteractiveBrowserCredential instead of DefaultAzureCredential. See https://aka.ms/azsdk/js/identity/examples for more details.

const subscriptionId = "00000000-0000-0000-0000-000000000000";
const client = new AttestationManagementClient(new DefaultAzureCredential(), subscriptionId);
```

For browser environments, use the `InteractiveBrowserCredential` from the `@azure/identity` package to authenticate.

```ts snippet:ReadmeSampleCreateClient_Browser
import { InteractiveBrowserCredential } from "@azure/identity";
import { AttestationManagementClient } from "@azure/arm-attestation";

const subscriptionId = "00000000-0000-0000-0000-000000000000";
const credential = new InteractiveBrowserCredential({
tenantId: "<YOUR_TENANT_ID>",
clientId: "<YOUR_CLIENT_ID>",
});
const client = new AttestationManagementClient(credential, subscriptionId);
// For client-side applications running in the browser, use this code instead:
// const credential = new InteractiveBrowserCredential({
// tenantId: "<YOUR_TENANT_ID>",
// clientId: "<YOUR_CLIENT_ID>"
// });
// const client = new AttestationManagementClient(credential, subscriptionId);
```

### JavaScript Bundle

### JavaScript Bundle
To use this client library in the browser, first you need to use a bundler. For details on how to do this, please refer to our [bundling documentation](https://aka.ms/AzureSDKBundling).

## Key concepts
Expand All @@ -88,9 +79,8 @@ To use this client library in the browser, first you need to use a bundler. For

Enabling logging may help uncover useful information about failures. In order to see a log of HTTP requests and responses, set the `AZURE_LOG_LEVEL` environment variable to `info`. Alternatively, logging can be enabled at runtime by calling `setLogLevel` in the `@azure/logger`:

```ts snippet:SetLogLevel
import { setLogLevel } from "@azure/logger";

```javascript
const { setLogLevel } = require("@azure/logger");
setLogLevel("info");
```

Expand Down
10 changes: 5 additions & 5 deletions sdk/attestation/arm-attestation/_meta.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"commit": "54ee1a9eb50c13e0790627749f986c886ad4f4db",
"readme": "specification\\attestation\\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\\attestation\\resource-manager\\readme.md --use=@autorest/[email protected].0-rc.3.20221108.1 --generate-sample=true",
"commit": "02131421fba10db6128f95d08e8f00d52802744f",
"readme": "specification/attestation/resource-manager/readme.md",
"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/attestation/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.18",
"use": "@autorest/typescript@^6.0.12"
}
6 changes: 3 additions & 3 deletions sdk/attestation/arm-attestation/api-extractor.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
"mainEntryPointFilePath": "dist/esm/index.d.ts",
"mainEntryPointFilePath": "./dist-esm/src/index.d.ts",
"docModel": {
"enabled": true
},
Expand All @@ -11,7 +11,7 @@
"dtsRollup": {
"enabled": true,
"untrimmedFilePath": "",
"publicTrimmedFilePath": "dist/arm-attestation.d.ts"
"publicTrimmedFilePath": "./types/arm-attestation.d.ts"
},
"messages": {
"tsdocMessageReporting": {
Expand All @@ -28,4 +28,4 @@
}
}
}
}
}
36 changes: 15 additions & 21 deletions sdk/attestation/arm-attestation/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,45 +3,46 @@
"sdk-type": "mgmt",
"author": "Microsoft Corporation",
"description": "A generated SDK for AttestationManagementClient.",
"version": "2.1.1",
"version": "2.2.0",
"engines": {
"node": ">=18.0.0"
},
"dependencies": {
"@azure/core-auth": "^1.9.0",
"@azure/core-client": "^1.9.2",
"@azure/core-paging": "^1.6.2",
"@azure/core-rest-pipeline": "^1.18.0",
"@azure/core-rest-pipeline": "^1.18.2",
"tslib": "^2.8.1"
},
"keywords": [
"node",
"azure",
"typescript",
"browser",
"isomorphic",
"cloud"
"isomorphic"
],
"license": "MIT",
"main": "./dist/commonjs/index.js",
"module": "./dist/esm/index.js",
"module": "./dist-esm/src/index.js",
"types": "./dist/commonjs/index.d.ts",
"devDependencies": {
"@azure-tools/test-credential": "^2.0.0",
"@azure-tools/test-recorder": "^4.1.0",
"@azure-tools/test-utils-vitest": "^1.0.0",
"@azure/dev-tool": "^1.0.0",
"@azure/identity": "^4.5.0",
"@azure/logger": "^1.1.4",
"@azure/identity": "^4.6.0",
"@types/node": "^18.0.0",
"@vitest/browser": "^3.0.3",
"@vitest/coverage-istanbul": "^3.0.3",
"playwright": "^1.49.1",
"typescript": "~5.7.2",
"dotenv": "^16.0.0",
"playwright": "^1.50.1",
"typescript": "~5.6.2",
"vitest": "^3.0.3"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/attestation/arm-attestation",
"repository": "github:Azure/azure-sdk-for-js",
"repository": {
"type": "git",
"url": "https://github.com/Azure/azure-sdk-for-js.git"
},
"bugs": {
"url": "https://github.com/Azure/azure-sdk-for-js/issues"
},
Expand Down Expand Up @@ -76,7 +77,7 @@
"unit-test": "npm run unit-test:node && npm run unit-test:browser",
"unit-test:browser": "echo skipped",
"unit-test:node": "dev-tool run test:vitest",
"update-snippets": "dev-tool run update-snippets"
"update-snippets": "echo skipped"
},
"sideEffects": false,
"//metadata": {
Expand All @@ -88,14 +89,7 @@
]
},
"autoPublish": true,
"//sampleConfiguration": {
"productName": "",
"productSlugs": [
"azure"
],
"disableDocsMs": true,
"apiRefLink": "https://learn.microsoft.com/javascript/api/@azure/arm-attestation?view=azure-node-preview"
},
"homepage": "https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/attestation/arm-attestation",
"type": "module",
"tshy": {
"project": "./tsconfig.src.json",
Expand Down Expand Up @@ -136,4 +130,4 @@
}
}
}
}
}
Loading

0 comments on commit 8201eb1

Please sign in to comment.