From 7bd7a681d960b9e5d4cfa7176a58ea019b8ff1cd Mon Sep 17 00:00:00 2001 From: SDK Automation Date: Tue, 10 Nov 2020 09:41:29 +0000 Subject: [PATCH] Generated from 73677f19181157fb0c154a084922a92fa6b528cd --- sdk/databoxedge/arm-databoxedge/LICENSE.txt | 21 + sdk/databoxedge/arm-databoxedge/README.md | 98 + sdk/databoxedge/arm-databoxedge/package.json | 58 + .../arm-databoxedge/rollup.config.js | 37 + .../src/dataBoxEdgeManagementClient.ts | 71 + .../src/dataBoxEdgeManagementClientContext.ts | 61 + .../src/models/alertsMappers.ts | 57 + .../src/models/bandwidthSchedulesMappers.ts | 57 + .../src/models/containersMappers.ts | 57 + .../src/models/devicesMappers.ts | 60 + .../arm-databoxedge/src/models/index.ts | 3708 +++++++++++++++++ .../arm-databoxedge/src/models/jobsMappers.ts | 17 + .../arm-databoxedge/src/models/mappers.ts | 3143 ++++++++++++++ .../src/models/nodesMappers.ts | 57 + .../src/models/operationsMappers.ts | 18 + .../src/models/operationsStatusMappers.ts | 17 + .../src/models/ordersMappers.ts | 57 + .../arm-databoxedge/src/models/parameters.ts | 126 + .../src/models/rolesMappers.ts | 57 + .../src/models/sharesMappers.ts | 57 + .../arm-databoxedge/src/models/skusMappers.ts | 18 + .../storageAccountCredentialsMappers.ts | 57 + .../src/models/storageAccountsMappers.ts | 57 + .../src/models/triggersMappers.ts | 57 + .../src/models/usersMappers.ts | 57 + .../arm-databoxedge/src/operations/alerts.ts | 200 + .../src/operations/bandwidthSchedules.ts | 330 ++ .../src/operations/containers.ts | 411 ++ .../arm-databoxedge/src/operations/devices.ts | 948 +++++ .../arm-databoxedge/src/operations/index.ts | 25 + .../arm-databoxedge/src/operations/jobs.ts | 91 + .../arm-databoxedge/src/operations/nodes.ts | 86 + .../src/operations/operations.ts | 125 + .../src/operations/operationsStatus.ts | 91 + .../arm-databoxedge/src/operations/orders.ts | 317 ++ .../arm-databoxedge/src/operations/roles.ts | 330 ++ .../arm-databoxedge/src/operations/shares.ts | 388 ++ .../arm-databoxedge/src/operations/skus.ts | 77 + .../operations/storageAccountCredentials.ts | 330 ++ .../src/operations/storageAccounts.ts | 329 ++ .../src/operations/triggers.ts | 332 ++ .../arm-databoxedge/src/operations/users.ts | 334 ++ sdk/databoxedge/arm-databoxedge/tsconfig.json | 19 + 43 files changed, 12843 insertions(+) create mode 100644 sdk/databoxedge/arm-databoxedge/LICENSE.txt create mode 100644 sdk/databoxedge/arm-databoxedge/README.md create mode 100644 sdk/databoxedge/arm-databoxedge/package.json create mode 100644 sdk/databoxedge/arm-databoxedge/rollup.config.js create mode 100644 sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClient.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClientContext.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/alertsMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/bandwidthSchedulesMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/containersMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/devicesMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/index.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/jobsMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/mappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/nodesMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/operationsMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/operationsStatusMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/ordersMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/parameters.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/rolesMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/sharesMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/skusMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/storageAccountCredentialsMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/storageAccountsMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/triggersMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/models/usersMappers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/alerts.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/bandwidthSchedules.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/containers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/devices.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/index.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/jobs.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/nodes.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/operations.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/operationsStatus.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/orders.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/roles.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/shares.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/skus.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/storageAccountCredentials.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/storageAccounts.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/triggers.ts create mode 100644 sdk/databoxedge/arm-databoxedge/src/operations/users.ts create mode 100644 sdk/databoxedge/arm-databoxedge/tsconfig.json diff --git a/sdk/databoxedge/arm-databoxedge/LICENSE.txt b/sdk/databoxedge/arm-databoxedge/LICENSE.txt new file mode 100644 index 000000000000..ea8fb1516028 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/LICENSE.txt @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2020 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 +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +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 +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. diff --git a/sdk/databoxedge/arm-databoxedge/README.md b/sdk/databoxedge/arm-databoxedge/README.md new file mode 100644 index 000000000000..31c750c6b8f5 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/README.md @@ -0,0 +1,98 @@ +## Azure DataBoxEdgeManagementClient SDK for JavaScript + +This package contains an isomorphic SDK for DataBoxEdgeManagementClient. + +### Currently supported environments + +- Node.js version 6.x.x or higher +- Browser JavaScript + +### How to Install + +```bash +npm install @azure/arm-databoxedge +``` + +### How to use + +#### nodejs - client creation and list operations as an example written in TypeScript. + +##### Install @azure/ms-rest-nodeauth + +- Please install minimum version of `"@azure/ms-rest-nodeauth": "^3.0.0"`. +```bash +npm install @azure/ms-rest-nodeauth@"^3.0.0" +``` + +##### Sample code + +While the below sample uses the interactive login, other authentication options can be found in the [README.md file of @azure/ms-rest-nodeauth](https://www.npmjs.com/package/@azure/ms-rest-nodeauth) package +```typescript +const msRestNodeAuth = require("@azure/ms-rest-nodeauth"); +const { DataBoxEdgeManagementClient } = require("@azure/arm-databoxedge"); +const subscriptionId = process.env["AZURE_SUBSCRIPTION_ID"]; + +msRestNodeAuth.interactiveLogin().then((creds) => { + const client = new DataBoxEdgeManagementClient(creds, subscriptionId); + client.operations.list().then((result) => { + console.log("The result is:"); + console.log(result); + }); +}).catch((err) => { + console.error(err); +}); +``` + +#### browser - Authentication, client creation and list operations as an example written in JavaScript. + +##### Install @azure/ms-rest-browserauth + +```bash +npm install @azure/ms-rest-browserauth +``` + +##### Sample code + +See https://github.com/Azure/ms-rest-browserauth to learn how to authenticate to Azure in the browser. + +- index.html +```html + + + + @azure/arm-databoxedge sample + + + + + + + + +``` + +## Related projects + +- [Microsoft Azure SDK for Javascript](https://github.com/Azure/azure-sdk-for-js) + +![Impressions](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-js/sdk/databoxedge/arm-databoxedge/README.png) diff --git a/sdk/databoxedge/arm-databoxedge/package.json b/sdk/databoxedge/arm-databoxedge/package.json new file mode 100644 index 000000000000..db93e4ac2bfd --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/package.json @@ -0,0 +1,58 @@ +{ + "name": "@azure/arm-databoxedge", + "author": "Microsoft Corporation", + "description": "DataBoxEdgeManagementClient Library with typescript type definitions for node.js and browser.", + "version": "1.0.0", + "dependencies": { + "@azure/ms-rest-azure-js": "^2.0.1", + "@azure/ms-rest-js": "^2.0.4", + "tslib": "^1.10.0" + }, + "keywords": [ + "node", + "azure", + "typescript", + "browser", + "isomorphic" + ], + "license": "MIT", + "main": "./dist/arm-databoxedge.js", + "module": "./esm/dataBoxEdgeManagementClient.js", + "types": "./esm/dataBoxEdgeManagementClient.d.ts", + "devDependencies": { + "typescript": "^3.5.3", + "rollup": "^1.18.0", + "rollup-plugin-node-resolve": "^5.2.0", + "rollup-plugin-sourcemaps": "^0.4.2", + "uglify-js": "^3.6.0" + }, + "homepage": "https://github.com/Azure/azure-sdk-for-js/tree/master/sdk/databoxedge/arm-databoxedge", + "repository": { + "type": "git", + "url": "https://github.com/Azure/azure-sdk-for-js.git" + }, + "bugs": { + "url": "https://github.com/Azure/azure-sdk-for-js/issues" + }, + "files": [ + "dist/**/*.js", + "dist/**/*.js.map", + "dist/**/*.d.ts", + "dist/**/*.d.ts.map", + "esm/**/*.js", + "esm/**/*.js.map", + "esm/**/*.d.ts", + "esm/**/*.d.ts.map", + "src/**/*.ts", + "README.md", + "rollup.config.js", + "tsconfig.json" + ], + "scripts": { + "build": "tsc && rollup -c rollup.config.js && npm run minify", + "minify": "uglifyjs -c -m --comments --source-map \"content='./dist/arm-databoxedge.js.map'\" -o ./dist/arm-databoxedge.min.js ./dist/arm-databoxedge.js", + "prepack": "npm install && npm run build" + }, + "sideEffects": false, + "autoPublish": true +} diff --git a/sdk/databoxedge/arm-databoxedge/rollup.config.js b/sdk/databoxedge/arm-databoxedge/rollup.config.js new file mode 100644 index 000000000000..b182f3e911be --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/rollup.config.js @@ -0,0 +1,37 @@ +import rollup from "rollup"; +import nodeResolve from "rollup-plugin-node-resolve"; +import sourcemaps from "rollup-plugin-sourcemaps"; + +/** + * @type {rollup.RollupFileOptions} + */ +const config = { + input: "./esm/dataBoxEdgeManagementClient.js", + external: [ + "@azure/ms-rest-js", + "@azure/ms-rest-azure-js" + ], + output: { + file: "./dist/arm-databoxedge.js", + format: "umd", + name: "Azure.ArmDataboxedge", + sourcemap: true, + globals: { + "@azure/ms-rest-js": "msRest", + "@azure/ms-rest-azure-js": "msRestAzure" + }, + banner: `/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */` + }, + plugins: [ + nodeResolve({ mainFields: ['module', 'main'] }), + sourcemaps() + ] +}; + +export default config; diff --git a/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClient.ts b/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClient.ts new file mode 100644 index 000000000000..a95d9e93d23e --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClient.ts @@ -0,0 +1,71 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "./models"; +import * as Mappers from "./models/mappers"; +import * as operations from "./operations"; +import { DataBoxEdgeManagementClientContext } from "./dataBoxEdgeManagementClientContext"; + + +class DataBoxEdgeManagementClient extends DataBoxEdgeManagementClientContext { + // Operation groups + operations: operations.Operations; + devices: operations.Devices; + alerts: operations.Alerts; + bandwidthSchedules: operations.BandwidthSchedules; + jobs: operations.Jobs; + nodes: operations.Nodes; + operationsStatus: operations.OperationsStatus; + orders: operations.Orders; + roles: operations.Roles; + shares: operations.Shares; + storageAccountCredentials: operations.StorageAccountCredentials; + storageAccounts: operations.StorageAccounts; + containers: operations.Containers; + triggers: operations.Triggers; + users: operations.Users; + skus: operations.Skus; + + /** + * Initializes a new instance of the DataBoxEdgeManagementClient class. + * @param credentials Credentials needed for the client to connect to Azure. + * @param subscriptionId The subscription ID. + * @param [options] The parameter options + */ + constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.DataBoxEdgeManagementClientOptions) { + super(credentials, subscriptionId, options); + this.operations = new operations.Operations(this); + this.devices = new operations.Devices(this); + this.alerts = new operations.Alerts(this); + this.bandwidthSchedules = new operations.BandwidthSchedules(this); + this.jobs = new operations.Jobs(this); + this.nodes = new operations.Nodes(this); + this.operationsStatus = new operations.OperationsStatus(this); + this.orders = new operations.Orders(this); + this.roles = new operations.Roles(this); + this.shares = new operations.Shares(this); + this.storageAccountCredentials = new operations.StorageAccountCredentials(this); + this.storageAccounts = new operations.StorageAccounts(this); + this.containers = new operations.Containers(this); + this.triggers = new operations.Triggers(this); + this.users = new operations.Users(this); + this.skus = new operations.Skus(this); + } +} + +// Operation Specifications + +export { + DataBoxEdgeManagementClient, + DataBoxEdgeManagementClientContext, + Models as DataBoxEdgeManagementModels, + Mappers as DataBoxEdgeManagementMappers +}; +export * from "./operations"; diff --git a/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClientContext.ts b/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClientContext.ts new file mode 100644 index 000000000000..69819cd0fb2d --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/dataBoxEdgeManagementClientContext.ts @@ -0,0 +1,61 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as Models from "./models"; +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; + +const packageName = "@azure/arm-databoxedge"; +const packageVersion = "1.0.0"; + +export class DataBoxEdgeManagementClientContext extends msRestAzure.AzureServiceClient { + credentials: msRest.ServiceClientCredentials; + apiVersion?: string; + subscriptionId: string; + + /** + * Initializes a new instance of the DataBoxEdgeManagementClient class. + * @param credentials Credentials needed for the client to connect to Azure. + * @param subscriptionId The subscription ID. + * @param [options] The parameter options + */ + constructor(credentials: msRest.ServiceClientCredentials, subscriptionId: string, options?: Models.DataBoxEdgeManagementClientOptions) { + if (credentials == undefined) { + throw new Error('\'credentials\' cannot be null.'); + } + if (subscriptionId == undefined) { + throw new Error('\'subscriptionId\' cannot be null.'); + } + + if (!options) { + options = {}; + } + if(!options.userAgent) { + const defaultUserAgent = msRestAzure.getDefaultUserAgentValue(); + options.userAgent = `${packageName}/${packageVersion} ${defaultUserAgent}`; + } + + super(credentials, options); + + this.apiVersion = '2019-08-01'; + this.acceptLanguage = 'en-US'; + this.longRunningOperationRetryTimeout = 30; + this.baseUri = options.baseUri || this.baseUri || "https://management.azure.com"; + this.requestContentType = "application/json; charset=utf-8"; + this.credentials = credentials; + this.subscriptionId = subscriptionId; + + if(options.acceptLanguage !== null && options.acceptLanguage !== undefined) { + this.acceptLanguage = options.acceptLanguage; + } + if(options.longRunningOperationRetryTimeout !== null && options.longRunningOperationRetryTimeout !== undefined) { + this.longRunningOperationRetryTimeout = options.longRunningOperationRetryTimeout; + } + } +} diff --git a/sdk/databoxedge/arm-databoxedge/src/models/alertsMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/alertsMappers.ts new file mode 100644 index 000000000000..2e3f33600298 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/alertsMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + AlertList, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/bandwidthSchedulesMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/bandwidthSchedulesMappers.ts new file mode 100644 index 000000000000..2b418d7533a1 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/bandwidthSchedulesMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BandwidthSchedulesList, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/containersMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/containersMappers.ts new file mode 100644 index 000000000000..93909d1ead83 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/containersMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + ContainerList, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/devicesMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/devicesMappers.ts new file mode 100644 index 000000000000..a5f3392bf299 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/devicesMappers.ts @@ -0,0 +1,60 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + DataBoxEdgeDeviceList, + DataBoxEdgeDevicePatch, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + UploadCertificateRequest, + UploadCertificateResponse, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/index.ts b/sdk/databoxedge/arm-databoxedge/src/models/index.ts new file mode 100644 index 000000000000..0fc7662a5065 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/index.ts @@ -0,0 +1,3708 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { BaseResource, CloudError, AzureServiceClientOptions } from "@azure/ms-rest-azure-js"; +import * as msRest from "@azure/ms-rest-js"; + +export { BaseResource, CloudError }; + +/** + * The shipping address of the customer. + */ +export interface Address { + /** + * The address line1. + */ + addressLine1: string; + /** + * The address line2. + */ + addressLine2?: string; + /** + * The address line3. + */ + addressLine3?: string; + /** + * The postal code. + */ + postalCode: string; + /** + * The city name. + */ + city: string; + /** + * The state name. + */ + state: string; + /** + * The country name. + */ + country: string; +} + +/** + * Error details for the alert. + */ +export interface AlertErrorDetails { + /** + * Error code. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly errorCode?: string; + /** + * Error Message. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly errorMessage?: string; + /** + * Number of occurrences. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly occurrences?: number; +} + +/** + * Represents the base class for all object models. + */ +export interface ARMBaseModel extends BaseResource { + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; +} + +/** + * Alert on the data box edge/gateway device. + */ +export interface Alert extends ARMBaseModel { + /** + * Alert title. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly title?: string; + /** + * Alert type. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly alertType?: string; + /** + * UTC time when the alert appeared. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly appearedAtDateTime?: Date; + /** + * Alert recommendation. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly recommendation?: string; + /** + * Severity of the alert. Possible values include: 'Informational', 'Warning', 'Critical' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly severity?: AlertSeverity; + /** + * Error details of the alert. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly errorDetails?: AlertErrorDetails; + /** + * Alert details. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly detailedInformation?: { [propertyName: string]: string }; +} + +/** + * Represent the secrets intended for encryption with asymmetric key pair. + */ +export interface AsymmetricEncryptedSecret { + /** + * The value of the secret. + */ + value: string; + /** + * Thumbprint certificate used to encrypt \"Value\". If the value is unencrypted, it will be + * null. + */ + encryptionCertThumbprint?: string; + /** + * The algorithm used to encrypt "Value". Possible values include: 'None', 'AES256', + * 'RSAES_PKCS1_v_1_5' + */ + encryptionAlgorithm: EncryptionAlgorithm; +} + +/** + * Symmetric key for authentication. + */ +export interface SymmetricKey { + /** + * Connection string based on the symmetric key. + */ + connectionString?: AsymmetricEncryptedSecret; +} + +/** + * Authentication mechanism for IoT devices. + */ +export interface Authentication { + /** + * Symmetric key for authentication. + */ + symmetricKey?: SymmetricKey; +} + +/** + * Azure container mapping of the endpoint. + */ +export interface AzureContainerInfo { + /** + * ID of the storage account credential used to access storage. + */ + storageAccountCredentialId: string; + /** + * Container name (Based on the data format specified, this represents the name of Azure + * Files/Page blob/Block blob). + */ + containerName: string; + /** + * Storage format used for the file represented by the share. Possible values include: + * 'BlockBlob', 'PageBlob', 'AzureFile' + */ + dataFormat: AzureContainerDataFormat; +} + +/** + * The bandwidth schedule details. + */ +export interface BandwidthSchedule extends ARMBaseModel { + /** + * The start time of the schedule in UTC. + */ + start: string; + /** + * The stop time of the schedule in UTC. + */ + stop: string; + /** + * The bandwidth rate in Mbps. + */ + rateInMbps: number; + /** + * The days of the week when this schedule is applicable. + */ + days: DayOfWeek[]; +} + +/** + * The mapping between a particular client IP and the type of access client has on the NFS share. + */ +export interface ClientAccessRight { + /** + * IP of the client. + */ + client: string; + /** + * Type of access to be allowed for the client. Possible values include: 'NoAccess', 'ReadOnly', + * 'ReadWrite' + */ + accessPermission: ClientPermissionType; +} + +/** + * Contains all the contact details of the customer. + */ +export interface ContactDetails { + /** + * The contact person name. + */ + contactPerson: string; + /** + * The name of the company. + */ + companyName: string; + /** + * The phone number. + */ + phone: string; + /** + * The email list. + */ + emailList: string[]; +} + +/** + * Fields for tracking refresh job on the share or container. + */ +export interface RefreshDetails { + /** + * If a refresh job is currently in progress on this share or container, this field indicates the + * ARM resource ID of that job. The field is empty if no job is in progress. + */ + inProgressRefreshJobId?: string; + /** + * Indicates the completed time for the last refresh job on this particular share or container, + * if any.This could be a failed job or a successful job. + */ + lastCompletedRefreshJobTimeInUTC?: Date; + /** + * Indicates the relative path of the error xml for the last refresh job on this particular share + * or container, if any. This could be a failed job or a successful job. + */ + errorManifestFile?: string; + /** + * Indicates the id of the last refresh job on this particular share or container,if any. This + * could be a failed job or a successful job. + */ + lastJob?: string; +} + +/** + * Represents a container on the Data Box Edge/Gateway device. + */ +export interface Container extends ARMBaseModel { + /** + * Current status of the container. Possible values include: 'OK', 'Offline', 'Unknown', + * 'Updating', 'NeedsAttention' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly containerStatus?: ContainerStatus; + /** + * DataFormat for Container. Possible values include: 'BlockBlob', 'PageBlob', 'AzureFile' + */ + dataFormat: AzureContainerDataFormat; + /** + * Details of the refresh job on this container. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly refreshDetails?: RefreshDetails; + /** + * The UTC time when container got created. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly createdDateTime?: Date; +} + +/** + * The SKU type. + */ +export interface Sku { + /** + * SKU name. Possible values include: 'Gateway', 'Edge', 'TEA_1Node', 'TEA_1Node_UPS', + * 'TEA_1Node_Heater', 'TEA_1Node_UPS_Heater', 'TEA_4Node_Heater', 'TEA_4Node_UPS_Heater', 'TMA' + */ + name?: SkuName; + /** + * The SKU tier. This is based on the SKU name. Possible values include: 'Standard' + */ + tier?: SkuTier; +} + +/** + * The Data Box Edge/Gateway device. + */ +export interface DataBoxEdgeDevice extends ARMBaseModel { + /** + * The location of the device. This is a supported and registered Azure geographical region (for + * example, West US, East US, or Southeast Asia). The geographical region of a device cannot be + * changed once it is created, but if an identical geographical region is specified on update, + * the request will succeed. + */ + location: string; + /** + * The list of tags that describe the device. These tags can be used to view and group this + * device (across resource groups). + */ + tags?: { [propertyName: string]: string }; + /** + * The SKU type. + */ + sku?: Sku; + /** + * The etag for the devices. + */ + etag?: string; + /** + * The status of the Data Box Edge/Gateway device. Possible values include: 'ReadyToSetup', + * 'Online', 'Offline', 'NeedsAttention', 'Disconnected', 'PartiallyDisconnected', 'Maintenance' + */ + dataBoxEdgeDeviceStatus?: DataBoxEdgeDeviceStatus; + /** + * The Serial Number of Data Box Edge/Gateway device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly serialNumber?: string; + /** + * The Description of the Data Box Edge/Gateway device. + */ + description?: string; + /** + * The description of the Data Box Edge/Gateway device model. + */ + modelDescription?: string; + /** + * The type of the Data Box Edge/Gateway device. Possible values include: 'DataBoxEdgeDevice' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceType?: DeviceType; + /** + * The Data Box Edge/Gateway device name. + */ + friendlyName?: string; + /** + * The Data Box Edge/Gateway device culture. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly culture?: string; + /** + * The Data Box Edge/Gateway device model. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceModel?: string; + /** + * The Data Box Edge/Gateway device software version. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceSoftwareVersion?: string; + /** + * The Data Box Edge/Gateway device local capacity in MB. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceLocalCapacity?: number; + /** + * The Data Box Edge/Gateway device timezone. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly timeZone?: string; + /** + * The device software version number of the device (eg: 1.2.18105.6). + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deviceHcsVersion?: string; + /** + * Type of compute roles configured. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly configuredRoleTypes?: RoleTypes[]; + /** + * The number of nodes in the cluster. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeCount?: number; +} + +/** + * The extended Info of the Data Box Edge/Gateway device. + */ +export interface DataBoxEdgeDeviceExtendedInfo extends ARMBaseModel { + /** + * The digital signature of encrypted certificate. + */ + encryptionKeyThumbprint?: string; + /** + * The public part of the encryption certificate. Client uses this to encrypt any secret. + */ + encryptionKey?: string; + /** + * The Resource ID of the Resource. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly resourceKey?: string; +} + +/** + * The Data Box Edge/Gateway device patch. + */ +export interface DataBoxEdgeDevicePatch { + /** + * The tags attached to the Data Box Edge/Gateway resource. + */ + tags?: { [propertyName: string]: string }; +} + +/** + * File source details. + */ +export interface FileSourceInfo { + /** + * File share ID. + */ + shareId: string; +} + +/** + * Compute role against which events will be raised. + */ +export interface RoleSinkInfo { + /** + * Compute role ID. + */ + roleId: string; +} + +/** + * Contains the possible cases for Trigger. + */ +export type TriggerUnion = Trigger | FileEventTrigger | PeriodicTimerEventTrigger; + +/** + * Trigger details. + */ +export interface Trigger { + /** + * Polymorphic Discriminator + */ + kind: "Trigger"; + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; +} + +/** + * Trigger details. + */ +export interface FileEventTrigger { + /** + * Polymorphic Discriminator + */ + kind: "FileEvent"; + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * File event source details. + */ + sourceInfo: FileSourceInfo; + /** + * Role sink info. + */ + sinkInfo: RoleSinkInfo; + /** + * A custom context tag typically used to correlate the trigger against its usage. For example, + * if a periodic timer trigger is intended for certain specific IoT modules in the device, the + * tag can be the name or the image URL of the module. + */ + customContextTag?: string; +} + +/** + * Metadata of IoT device/IoT Edge device to be configured. + */ +export interface IoTDeviceInfo { + /** + * ID of the IoT device/edge device. + */ + deviceId: string; + /** + * Host name for the IoT hub associated to the device. + */ + ioTHostHub: string; + /** + * Id for the IoT hub associated to the device. + */ + ioTHostHubId?: string; + /** + * IoT device authentication info. + */ + authentication?: Authentication; +} + +/** + * The share mount point. + */ +export interface MountPointMap { + /** + * ID of the share mounted to the role VM. + */ + shareId: string; + /** + * ID of the role to which share is mounted. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly roleId?: string; + /** + * Mount point for the share. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly mountPoint?: string; + /** + * Role type. Possible values include: 'IOT', 'ASA', 'Functions', 'Cognitive' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly roleType?: RoleTypes; +} + +/** + * Contains the possible cases for Role. + */ +export type RoleUnion = Role | IoTRole; + +/** + * Compute role. + */ +export interface Role { + /** + * Polymorphic Discriminator + */ + kind: "Role"; + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; +} + +/** + * Compute role. + */ +export interface IoTRole { + /** + * Polymorphic Discriminator + */ + kind: "IOT"; + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Host OS supported by the IoT role. Possible values include: 'Windows', 'Linux' + */ + hostPlatform: PlatformType; + /** + * IoT device metadata to which data box edge device needs to be connected. + */ + ioTDeviceDetails: IoTDeviceInfo; + /** + * IoT edge device to which the IoT role needs to be configured. + */ + ioTEdgeDeviceDetails: IoTDeviceInfo; + /** + * Mount points of shares in role(s). + */ + shareMappings?: MountPointMap[]; + /** + * Role status. Possible values include: 'Enabled', 'Disabled' + */ + roleStatus: RoleStatus; +} + +/** + * Details related to the IPv4 address configuration. + */ +export interface Ipv4Config { + /** + * The IPv4 address of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ipAddress?: string; + /** + * The IPv4 subnet of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly subnet?: string; + /** + * The IPv4 gateway of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly gateway?: string; +} + +/** + * Details related to the IPv6 address configuration. + */ +export interface Ipv6Config { + /** + * The IPv6 address of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ipAddress?: string; + /** + * The IPv6 prefix of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly prefixLength?: number; + /** + * The IPv6 gateway of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly gateway?: string; +} + +/** + * The job error items. + */ +export interface JobErrorItem { + /** + * The recommended actions. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly recommendations?: string[]; + /** + * The code intended for programmatic access. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly code?: string; + /** + * The message that describes the error in detail. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly message?: string; +} + +/** + * The job error information containing the list of job errors. + */ +export interface JobErrorDetails { + /** + * The error details. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly errorDetails?: JobErrorItem[]; + /** + * The code intended for programmatic access. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly code?: string; + /** + * The message that describes the error in detail. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly message?: string; +} + +/** + * Details about the download progress of update. + */ +export interface UpdateDownloadProgress { + /** + * The download phase. Possible values include: 'Unknown', 'Initializing', 'Downloading', + * 'Verifying' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly downloadPhase?: DownloadPhase; + /** + * Percentage of completion. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly percentComplete?: number; + /** + * Total bytes to download. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalBytesToDownload?: number; + /** + * Total bytes downloaded. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalBytesDownloaded?: number; + /** + * Number of updates to download. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly numberOfUpdatesToDownload?: number; + /** + * Number of updates downloaded. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly numberOfUpdatesDownloaded?: number; +} + +/** + * Progress details during installation of updates. + */ +export interface UpdateInstallProgress { + /** + * Percentage completed. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly percentComplete?: number; + /** + * Number of updates to install. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly numberOfUpdatesToInstall?: number; + /** + * Number of updates installed. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly numberOfUpdatesInstalled?: number; +} + +/** + * A device job. + */ +export interface Job { + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The name of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * The current status of the job. Possible values include: 'Invalid', 'Running', 'Succeeded', + * 'Failed', 'Canceled', 'Paused', 'Scheduled' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly status?: JobStatus; + /** + * The UTC date and time at which the job started. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly startTime?: Date; + /** + * The UTC date and time at which the job completed. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly endTime?: Date; + /** + * The percentage of the job that is complete. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly percentComplete?: number; + /** + * The error details. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly error?: JobErrorDetails; + /** + * The type of the job. Possible values include: 'Invalid', 'ScanForUpdates', 'DownloadUpdates', + * 'InstallUpdates', 'RefreshShare', 'RefreshContainer' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly jobType?: JobType; + /** + * Current stage of the update operation. Possible values include: 'Unknown', 'Initial', + * 'ScanStarted', 'ScanComplete', 'ScanFailed', 'DownloadStarted', 'DownloadComplete', + * 'DownloadFailed', 'InstallStarted', 'InstallComplete', 'InstallFailed', 'RebootInitiated', + * 'Success', 'Failure', 'RescanStarted', 'RescanComplete', 'RescanFailed' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly currentStage?: UpdateOperationStage; + /** + * The download progress. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly downloadProgress?: UpdateDownloadProgress; + /** + * The install progress. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly installProgress?: UpdateInstallProgress; + /** + * Total number of errors encountered during the refresh process. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalRefreshErrors?: number; + /** + * Local share/remote container relative path to the error manifest file of the refresh. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly errorManifestFile?: string; + /** + * ARM ID of the entity that was refreshed. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly refreshedEntityId?: string; + /** + * If only subfolders need to be refreshed, then the subfolder path inside the share or + * container. (The path is empty if there are no subfolders.) + */ + folder?: string; +} + +/** + * Metric Dimension v1. + */ +export interface MetricDimensionV1 { + /** + * Name of the metrics dimension. + */ + name?: string; + /** + * Display name of the metrics dimension. + */ + displayName?: string; + /** + * To be exported to shoe box. + */ + toBeExportedForShoebox?: boolean; +} + +/** + * Metric specification version 1. + */ +export interface MetricSpecificationV1 { + /** + * Name of the metric. + */ + name?: string; + /** + * Display name of the metric. + */ + displayName?: string; + /** + * Description of the metric to be displayed. + */ + displayDescription?: string; + /** + * Metric units. Possible values include: 'NotSpecified', 'Percent', 'Count', 'Seconds', + * 'Milliseconds', 'Bytes', 'BytesPerSecond', 'CountPerSecond' + */ + unit?: MetricUnit; + /** + * Metric aggregation type. Possible values include: 'NotSpecified', 'None', 'Average', + * 'Minimum', 'Maximum', 'Total', 'Count' + */ + aggregationType?: MetricAggregationType; + /** + * Metric dimensions, other than default dimension which is resource. + */ + dimensions?: MetricDimensionV1[]; + /** + * Set true to fill the gaps with zero. + */ + fillGapWithZero?: boolean; + /** + * Metric category. Possible values include: 'Capacity', 'Transaction' + */ + category?: MetricCategory; + /** + * Resource name override. + */ + resourceIdDimensionNameOverride?: string; + /** + * Support granularity of metrics. + */ + supportedTimeGrainTypes?: TimeGrain[]; + /** + * Support metric aggregation type. + */ + supportedAggregationTypes?: MetricAggregationType[]; +} + +/** + * The network adapter position. + */ +export interface NetworkAdapterPosition { + /** + * The network group. Possible values include: 'None', 'NonRDMA', 'RDMA' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly networkGroup?: NetworkGroup; + /** + * The port. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly port?: number; +} + +/** + * Represents the networkAdapter on a device. + */ +export interface NetworkAdapter { + /** + * Instance ID of network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly adapterId?: string; + /** + * Hardware position of network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly adapterPosition?: NetworkAdapterPosition; + /** + * Logical index of the adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly index?: number; + /** + * Node ID of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeId?: string; + /** + * Network adapter name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly networkAdapterName?: string; + /** + * Hardware label for the adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly label?: string; + /** + * MAC address. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly macAddress?: string; + /** + * Link speed. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly linkSpeed?: number; + /** + * Value indicating whether this adapter is valid. Possible values include: 'Inactive', 'Active' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly status?: NetworkAdapterStatus; + /** + * Value indicating whether this adapter is RDMA capable. Possible values include: 'Incapable', + * 'Capable' + */ + rdmaStatus?: NetworkAdapterRDMAStatus; + /** + * Value indicating whether this adapter has DHCP enabled. Possible values include: 'Disabled', + * 'Enabled' + */ + dhcpStatus?: NetworkAdapterDHCPStatus; + /** + * The IPv4 configuration of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ipv4Configuration?: Ipv4Config; + /** + * The IPv6 configuration of the network adapter. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ipv6Configuration?: Ipv6Config; + /** + * The IPv6 local address. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ipv6LinkLocalAddress?: string; + /** + * The list of DNS Servers of the device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly dnsServers?: string[]; +} + +/** + * The network settings of a device. + */ +export interface NetworkSettings extends ARMBaseModel { + /** + * The network adapter list on the device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly networkAdapters?: NetworkAdapter[]; +} + +/** + * Represents a single node in a Data box Edge/Gateway device + * Gateway devices, standalone Edge devices and a single node cluster Edge device will all have 1 + * node + * Multi-node Edge devices will have more than 1 nodes + */ +export interface Node extends ARMBaseModel { + /** + * The current status of the individual node. Possible values include: 'Unknown', 'Up', 'Down', + * 'Rebooting', 'ShuttingDown' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeStatus?: NodeStatus; + /** + * Serial number of the Chassis + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeChassisSerialNumber?: string; + /** + * Serial number of the individual node + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeSerialNumber?: string; + /** + * Display Name of the individual node + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeDisplayName?: string; + /** + * Friendly software version name that is currently installed on the node + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeFriendlySoftwareVersion?: string; + /** + * HCS version that is currently installed on the node + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeHcsVersion?: string; + /** + * Guid instance id of the node + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nodeInstanceId?: string; +} + +/** + * Operation display properties. + */ +export interface OperationDisplay { + /** + * Provider name. + */ + provider?: string; + /** + * The type of resource in which the operation is performed. + */ + resource?: string; + /** + * Operation to be performed on the resource. + */ + operation?: string; + /** + * Description of the operation to be performed. + */ + description?: string; +} + +/** + * Service specification. + */ +export interface ServiceSpecification { + /** + * Metric specification as defined by shoebox. + */ + metricSpecifications?: MetricSpecificationV1[]; +} + +/** + * Operations. + */ +export interface Operation { + /** + * Name of the operation. + */ + name?: string; + /** + * Properties displayed for the operation. + */ + display?: OperationDisplay; + /** + * Origin of the operation. + */ + origin?: string; + /** + * Service specification. + */ + serviceSpecification?: ServiceSpecification; +} + +/** + * Represents a single status change. + */ +export interface OrderStatus { + /** + * Status of the order as per the allowed status types. Possible values include: 'Untracked', + * 'AwaitingFulfilment', 'AwaitingPreparation', 'AwaitingShipment', 'Shipped', 'Arriving', + * 'Delivered', 'ReplacementRequested', 'LostDevice', 'Declined', 'ReturnInitiated', + * 'AwaitingReturnShipment', 'ShippedBack', 'CollectedAtMicrosoft' + */ + status: OrderState; + /** + * Time of status update. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly updateDateTime?: Date; + /** + * Comments related to this status change. + */ + comments?: string; + /** + * Dictionary to hold generic information which is not stored + * by the already existing properties + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly additionalOrderDetails?: { [propertyName: string]: string }; +} + +/** + * Tracking courier information. + */ +export interface TrackingInfo { + /** + * Serial number of the device being tracked. + */ + serialNumber?: string; + /** + * Name of the carrier used in the delivery. + */ + carrierName?: string; + /** + * Tracking ID of the shipment. + */ + trackingId?: string; + /** + * Tracking URL of the shipment. + */ + trackingUrl?: string; +} + +/** + * The order details. + */ +export interface Order extends ARMBaseModel { + /** + * The contact details. + */ + contactInformation: ContactDetails; + /** + * The shipping address. + */ + shippingAddress: Address; + /** + * Current status of the order. + */ + currentStatus?: OrderStatus; + /** + * List of status changes in the order. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly orderHistory?: OrderStatus[]; + /** + * Serial number of the device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly serialNumber?: string; + /** + * Tracking information for the package delivered to the customer whether it has an original or a + * replacement device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly deliveryTrackingInfo?: TrackingInfo[]; + /** + * Tracking information for the package returned from the customer whether it has an original or + * a replacement device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly returnTrackingInfo?: TrackingInfo[]; +} + +/** + * Periodic timer event source. + */ +export interface PeriodicTimerSourceInfo { + /** + * The time of the day that results in a valid trigger. Schedule is computed with reference to + * the time specified upto seconds. If timezone is not specified the time will considered to be + * in device timezone. The value will always be returned as UTC time. + */ + startTime: Date; + /** + * Periodic frequency at which timer event needs to be raised. Supports daily, hourly, minutes, + * and seconds. + */ + schedule: string; + /** + * Topic where periodic events are published to IoT device. + */ + topic?: string; +} + +/** + * Trigger details. + */ +export interface PeriodicTimerEventTrigger { + /** + * Polymorphic Discriminator + */ + kind: "PeriodicTimerEvent"; + /** + * The path ID that uniquely identifies the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly id?: string; + /** + * The object name. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: string; + /** + * The hierarchical type of the object. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * Periodic timer details. + */ + sourceInfo: PeriodicTimerSourceInfo; + /** + * Role Sink information. + */ + sinkInfo: RoleSinkInfo; + /** + * A custom context tag typically used to correlate the trigger against its usage. For example, + * if a periodic timer trigger is intended for certain specific IoT modules in the device, the + * tag can be the name or the image URL of the module. + */ + customContextTag?: string; +} + +/** + * The location info. + */ +export interface SkuLocationInfo { + /** + * The location. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly location?: string; + /** + * The zones. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly zones?: string[]; + /** + * The sites. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly sites?: string[]; +} + +/** + * The metadata for retrieving price info. + */ +export interface SkuCost { + /** + * Used for querying price from commerce. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly meterId?: string; + /** + * The cost quantity. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly quantity?: number; + /** + * Restriction of the SKU for the location/zone + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly extendedUnit?: string; +} + +/** + * The restriction info with locations and zones. + */ +export interface SkuRestrictionInfo { + /** + * The locations. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly locations?: string[]; + /** + * The zones. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly zones?: string[]; +} + +/** + * The restrictions because of which SKU cannot be used. + */ +export interface SkuRestriction { + /** + * The type of the restriction. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly type?: string; + /** + * The locations where sku is restricted. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly values?: string[]; + /** + * The SKU restriction reason. Possible values include: 'NotAvailableForSubscription', 'QuotaId' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly reasonCode?: SkuRestrictionReasonCode; + /** + * Restriction of the SKU for the location/zone + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly restrictionInfo?: SkuRestrictionInfo; +} + +/** + * SkuInformation object + */ +export interface ResourceTypeSku { + /** + * The type of the resource + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly resourceType?: string; + /** + * The Sku name. Possible values include: 'Gateway', 'Edge', 'TEA_1Node', 'TEA_1Node_UPS', + * 'TEA_1Node_Heater', 'TEA_1Node_UPS_Heater', 'TEA_4Node_Heater', 'TEA_4Node_UPS_Heater', 'TMA' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly name?: SkuName; + /** + * The Sku kind + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly kind?: string; + /** + * The Sku tier. Possible values include: 'Standard' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly tier?: SkuTier; + /** + * The Sku family + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly family?: string; + /** + * Availability of the SKU for the region + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly locations?: string[]; + /** + * The API versions in which SKU is available + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly apiVersions?: string[]; + /** + * Availability of the SKU for the location/zone + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly locationInfo?: SkuLocationInfo[]; + /** + * The pricing info of the Sku. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly costs?: SkuCost[]; + /** + * Restrictions of the SKU availability. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly restrictions?: SkuRestriction[]; +} + +/** + * The security settings of a device. + */ +export interface SecuritySettings extends ARMBaseModel { + /** + * Device administrator password as an encrypted string (encrypted using RSA PKCS #1) is used to + * sign into the local web UI of the device. The Actual password should have at least 8 + * characters that are a combination of uppercase, lowercase, numeric, and special characters. + */ + deviceAdminPassword: AsymmetricEncryptedSecret; +} + +/** + * The mapping between a particular user and the access type on the SMB share. + */ +export interface UserAccessRight { + /** + * User ID (already existing in the device). + */ + userId: string; + /** + * Type of access to be allowed for the user. Possible values include: 'Change', 'Read', 'Custom' + */ + accessType: ShareAccessType; +} + +/** + * Represents a share on the Data Box Edge/Gateway device. + */ +export interface Share extends ARMBaseModel { + /** + * Description for the share. + */ + description?: string; + /** + * Current status of the share. Possible values include: 'Offline', 'Unknown', 'OK', 'Updating', + * 'NeedsAttention' + */ + shareStatus: ShareStatus; + /** + * Current monitoring status of the share. Possible values include: 'Enabled', 'Disabled' + */ + monitoringStatus: MonitoringStatus; + /** + * Azure container mapping for the share. + */ + azureContainerInfo?: AzureContainerInfo; + /** + * Access protocol to be used by the share. Possible values include: 'SMB', 'NFS' + */ + accessProtocol: ShareAccessProtocol; + /** + * Mapping of users and corresponding access rights on the share (required for SMB protocol). + */ + userAccessRights?: UserAccessRight[]; + /** + * List of IP addresses and corresponding access rights on the share(required for NFS protocol). + */ + clientAccessRights?: ClientAccessRight[]; + /** + * Details of the refresh job on this share. + */ + refreshDetails?: RefreshDetails; + /** + * Share mount point to the role. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly shareMappings?: MountPointMap[]; + /** + * Data policy of the share. Possible values include: 'Cloud', 'Local' + */ + dataPolicy?: DataPolicy; +} + +/** + * Specifies the mapping between this particular user and the type of access he has on shares on + * this device. + */ +export interface ShareAccessRight { + /** + * The share ID. + */ + shareId: string; + /** + * Type of access to be allowed on the share for this user. Possible values include: 'Change', + * 'Read', 'Custom' + */ + accessType: ShareAccessType; +} + +/** + * Represents a Storage Account on the Data Box Edge/Gateway device. + */ +export interface StorageAccount extends ARMBaseModel { + /** + * Description for the storage Account. + */ + description?: string; + /** + * Current status of the storage account. Possible values include: 'OK', 'Offline', 'Unknown', + * 'Updating', 'NeedsAttention' + */ + storageAccountStatus?: StorageAccountStatus; + /** + * Data policy of the storage Account. Possible values include: 'Cloud', 'Local' + */ + dataPolicy?: DataPolicy; + /** + * Storage Account Credential Id + */ + storageAccountCredentialId?: string; + /** + * BlobEndpoint of Storage Account + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly blobEndpoint?: string; + /** + * The Container Count. Present only for Storage Accounts with DataPolicy set to Cloud. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly containerCount?: number; +} + +/** + * The storage account credential. + */ +export interface StorageAccountCredential extends ARMBaseModel { + /** + * Alias for the storage account. + */ + alias: string; + /** + * Username for the storage account. + */ + userName?: string; + /** + * Encrypted storage key. + */ + accountKey?: AsymmetricEncryptedSecret; + /** + * Connection string for the storage account. Use this string if username and account key are not + * specified. + */ + connectionString?: string; + /** + * Signifies whether SSL needs to be enabled or not. Possible values include: 'Enabled', + * 'Disabled' + */ + sslStatus: SSLStatus; + /** + * Blob end point for private clouds. + */ + blobDomainName?: string; + /** + * Type of storage accessed on the storage account. Possible values include: + * 'GeneralPurposeStorage', 'BlobStorage' + */ + accountType: AccountType; + /** + * Id of the storage account. + */ + storageAccountId?: string; +} + +/** + * Details about ongoing updates and availability of updates on the device. + */ +export interface UpdateSummary extends ARMBaseModel { + /** + * The current version of the device in format: 1.2.17312.13.", + */ + deviceVersionNumber?: string; + /** + * The current version of the device in text format. + */ + friendlyDeviceVersionName?: string; + /** + * The last time when a scan was done on the device. + */ + deviceLastScannedDateTime?: Date; + /** + * The time when the last scan job was completed (success/cancelled/failed) on the appliance. + */ + lastCompletedScanJobDateTime?: Date; + /** + * The time when the last Download job was completed (success/cancelled/failed) on the appliance. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly lastCompletedDownloadJobDateTime?: Date; + /** + * The time when the last Install job was completed (success/cancelled/failed) on the appliance. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly lastCompletedInstallJobDateTime?: Date; + /** + * The number of updates available for the current device version as per the last device scan. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalNumberOfUpdatesAvailable?: number; + /** + * The total number of items pending download. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalNumberOfUpdatesPendingDownload?: number; + /** + * The total number of items pending install. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalNumberOfUpdatesPendingInstall?: number; + /** + * Indicates if updates are available and at least one of the updates needs a reboot. Possible + * values include: 'NeverReboots', 'RequiresReboot', 'RequestReboot' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly rebootBehavior?: InstallRebootBehavior; + /** + * The current update operation. Possible values include: 'None', 'Scan', 'Download', 'Install' + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly ongoingUpdateOperation?: UpdateOperation; + /** + * The job ID of the download job in progress. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly inProgressDownloadJobId?: string; + /** + * The job ID of the install job in progress. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly inProgressInstallJobId?: string; + /** + * The time when the currently running download (if any) started. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly inProgressDownloadJobStartedDateTime?: Date; + /** + * The time when the currently running install (if any) started. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly inProgressInstallJobStartedDateTime?: Date; + /** + * The list of updates available for install. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly updateTitles?: string[]; + /** + * The total size of updates available for download in bytes. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly totalUpdateSizeInBytes?: number; +} + +/** + * The upload certificate request. + */ +export interface UploadCertificateRequest { + /** + * The authentication type. Possible values include: 'Invalid', 'AzureActiveDirectory' + */ + authenticationType?: AuthenticationType; + /** + * The base64 encoded certificate raw data. + */ + certificate: string; +} + +/** + * The upload registration certificate response. + */ +export interface UploadCertificateResponse { + /** + * Specifies authentication type. Possible values include: 'Invalid', 'AzureActiveDirectory' + */ + authType?: AuthenticationType; + /** + * The resource ID of the Data Box Edge/Gateway device. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly resourceId?: string; + /** + * Azure Active Directory tenant authority. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly aadAuthority?: string; + /** + * Azure Active Directory tenant ID. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly aadTenantId?: string; + /** + * Azure Active Directory service principal client ID. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly servicePrincipalClientId?: string; + /** + * Azure Active Directory service principal object ID. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly servicePrincipalObjectId?: string; + /** + * The azure management endpoint audience. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly azureManagementEndpointAudience?: string; + /** + * Identifier of the target resource that is the recipient of the requested token. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly aadAudience?: string; +} + +/** + * Represents a user who has access to one or more shares on the Data Box Edge/Gateway device. + */ +export interface User extends ARMBaseModel { + /** + * The password details. + */ + encryptedPassword?: AsymmetricEncryptedSecret; + /** + * List of shares that the user has rights on. This field should not be specified during user + * creation. + */ + shareAccessRights?: ShareAccessRight[]; + /** + * Type of the user. Possible values include: 'Share', 'LocalManagement', 'ARM' + */ + userType: UserType; +} + +/** + * Optional Parameters. + */ +export interface DevicesListBySubscriptionOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $expand=details to populate additional fields related to the resource or Specify + * $skipToken= to populate the next page in the list. + */ + expand?: string; +} + +/** + * Optional Parameters. + */ +export interface DevicesListByResourceGroupOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $expand=details to populate additional fields related to the resource or Specify + * $skipToken= to populate the next page in the list. + */ + expand?: string; +} + +/** + * Optional Parameters. + */ +export interface DevicesListBySubscriptionNextOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $expand=details to populate additional fields related to the resource or Specify + * $skipToken= to populate the next page in the list. + */ + expand?: string; +} + +/** + * Optional Parameters. + */ +export interface DevicesListByResourceGroupNextOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $expand=details to populate additional fields related to the resource or Specify + * $skipToken= to populate the next page in the list. + */ + expand?: string; +} + +/** + * Optional Parameters. + */ +export interface TriggersListByDataBoxEdgeDeviceOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $filter='CustomContextTag eq ' to filter on custom context tag property + */ + filter?: string; +} + +/** + * Optional Parameters. + */ +export interface TriggersListByDataBoxEdgeDeviceNextOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $filter='CustomContextTag eq ' to filter on custom context tag property + */ + filter?: string; +} + +/** + * Optional Parameters. + */ +export interface UsersListByDataBoxEdgeDeviceOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $filter='UserType eq ' to filter on user type property + */ + filter?: string; +} + +/** + * Optional Parameters. + */ +export interface UsersListByDataBoxEdgeDeviceNextOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $filter='UserType eq ' to filter on user type property + */ + filter?: string; +} + +/** + * Optional Parameters. + */ +export interface SkusListOptionalParams extends msRest.RequestOptionsBase { + /** + * Specify $filter='location eq ' to filter on location. + */ + filter?: string; +} + +/** + * An interface representing DataBoxEdgeManagementClientOptions. + */ +export interface DataBoxEdgeManagementClientOptions extends AzureServiceClientOptions { + baseUri?: string; +} + +/** + * @interface + * The list of operations used for the discovery of available provider operations. + * @extends Array + */ +export interface OperationsList extends Array { + /** + * Link to the next set of results. + */ + nextLink?: string; +} + +/** + * @interface + * The collection of Data Box Edge/Gateway devices. + * @extends Array + */ +export interface DataBoxEdgeDeviceList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of alerts. + * @extends Array + */ +export interface AlertList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * The collection of bandwidth schedules. + * @extends Array + */ +export interface BandwidthSchedulesList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of Nodes. + * @extends Array + */ +export interface NodeList extends Array { +} + +/** + * @interface + * List of order entities. + * @extends Array + */ +export interface OrderList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of all the roles on the Data Box Edge device. + * @extends Array + */ +export interface RoleList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of all the shares on the Data Box Edge/Gateway device. + * @extends Array + */ +export interface ShareList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * The collection of storage account credentials. + * @extends Array + */ +export interface StorageAccountCredentialList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of all the Storage Accounts on the Data Box Edge/Gateway device. + * @extends Array + */ +export interface StorageAccountList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of all the containers on the Data Box Edge/Gateway device. + * @extends Array + */ +export interface ContainerList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of all trigger on the data box edge device. + * @extends Array + */ +export interface TriggerList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * Collection of users. + * @extends Array + */ +export interface UserList extends Array { + /** + * Link to the next set of results. + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * @interface + * List of SKU Information objects + * @extends Array + */ +export interface SkuInformationList extends Array { + /** + * Links to the next set of results + * **NOTE: This property will not be serialized. It can only be populated by the server.** + */ + readonly nextLink?: string; +} + +/** + * Defines values for AlertSeverity. + * Possible values include: 'Informational', 'Warning', 'Critical' + * @readonly + * @enum {string} + */ +export type AlertSeverity = 'Informational' | 'Warning' | 'Critical'; + +/** + * Defines values for EncryptionAlgorithm. + * Possible values include: 'None', 'AES256', 'RSAES_PKCS1_v_1_5' + * @readonly + * @enum {string} + */ +export type EncryptionAlgorithm = 'None' | 'AES256' | 'RSAES_PKCS1_v_1_5'; + +/** + * Defines values for AzureContainerDataFormat. + * Possible values include: 'BlockBlob', 'PageBlob', 'AzureFile' + * @readonly + * @enum {string} + */ +export type AzureContainerDataFormat = 'BlockBlob' | 'PageBlob' | 'AzureFile'; + +/** + * Defines values for DayOfWeek. + * Possible values include: 'Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', + * 'Saturday' + * @readonly + * @enum {string} + */ +export type DayOfWeek = 'Sunday' | 'Monday' | 'Tuesday' | 'Wednesday' | 'Thursday' | 'Friday' | 'Saturday'; + +/** + * Defines values for ClientPermissionType. + * Possible values include: 'NoAccess', 'ReadOnly', 'ReadWrite' + * @readonly + * @enum {string} + */ +export type ClientPermissionType = 'NoAccess' | 'ReadOnly' | 'ReadWrite'; + +/** + * Defines values for ContainerStatus. + * Possible values include: 'OK', 'Offline', 'Unknown', 'Updating', 'NeedsAttention' + * @readonly + * @enum {string} + */ +export type ContainerStatus = 'OK' | 'Offline' | 'Unknown' | 'Updating' | 'NeedsAttention'; + +/** + * Defines values for SkuName. + * Possible values include: 'Gateway', 'Edge', 'TEA_1Node', 'TEA_1Node_UPS', 'TEA_1Node_Heater', + * 'TEA_1Node_UPS_Heater', 'TEA_4Node_Heater', 'TEA_4Node_UPS_Heater', 'TMA' + * @readonly + * @enum {string} + */ +export type SkuName = 'Gateway' | 'Edge' | 'TEA_1Node' | 'TEA_1Node_UPS' | 'TEA_1Node_Heater' | 'TEA_1Node_UPS_Heater' | 'TEA_4Node_Heater' | 'TEA_4Node_UPS_Heater' | 'TMA'; + +/** + * Defines values for SkuTier. + * Possible values include: 'Standard' + * @readonly + * @enum {string} + */ +export type SkuTier = 'Standard'; + +/** + * Defines values for DataBoxEdgeDeviceStatus. + * Possible values include: 'ReadyToSetup', 'Online', 'Offline', 'NeedsAttention', 'Disconnected', + * 'PartiallyDisconnected', 'Maintenance' + * @readonly + * @enum {string} + */ +export type DataBoxEdgeDeviceStatus = 'ReadyToSetup' | 'Online' | 'Offline' | 'NeedsAttention' | 'Disconnected' | 'PartiallyDisconnected' | 'Maintenance'; + +/** + * Defines values for DeviceType. + * Possible values include: 'DataBoxEdgeDevice' + * @readonly + * @enum {string} + */ +export type DeviceType = 'DataBoxEdgeDevice'; + +/** + * Defines values for RoleTypes. + * Possible values include: 'IOT', 'ASA', 'Functions', 'Cognitive' + * @readonly + * @enum {string} + */ +export type RoleTypes = 'IOT' | 'ASA' | 'Functions' | 'Cognitive'; + +/** + * Defines values for PlatformType. + * Possible values include: 'Windows', 'Linux' + * @readonly + * @enum {string} + */ +export type PlatformType = 'Windows' | 'Linux'; + +/** + * Defines values for RoleStatus. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type RoleStatus = 'Enabled' | 'Disabled'; + +/** + * Defines values for JobStatus. + * Possible values include: 'Invalid', 'Running', 'Succeeded', 'Failed', 'Canceled', 'Paused', + * 'Scheduled' + * @readonly + * @enum {string} + */ +export type JobStatus = 'Invalid' | 'Running' | 'Succeeded' | 'Failed' | 'Canceled' | 'Paused' | 'Scheduled'; + +/** + * Defines values for JobType. + * Possible values include: 'Invalid', 'ScanForUpdates', 'DownloadUpdates', 'InstallUpdates', + * 'RefreshShare', 'RefreshContainer' + * @readonly + * @enum {string} + */ +export type JobType = 'Invalid' | 'ScanForUpdates' | 'DownloadUpdates' | 'InstallUpdates' | 'RefreshShare' | 'RefreshContainer'; + +/** + * Defines values for UpdateOperationStage. + * Possible values include: 'Unknown', 'Initial', 'ScanStarted', 'ScanComplete', 'ScanFailed', + * 'DownloadStarted', 'DownloadComplete', 'DownloadFailed', 'InstallStarted', 'InstallComplete', + * 'InstallFailed', 'RebootInitiated', 'Success', 'Failure', 'RescanStarted', 'RescanComplete', + * 'RescanFailed' + * @readonly + * @enum {string} + */ +export type UpdateOperationStage = 'Unknown' | 'Initial' | 'ScanStarted' | 'ScanComplete' | 'ScanFailed' | 'DownloadStarted' | 'DownloadComplete' | 'DownloadFailed' | 'InstallStarted' | 'InstallComplete' | 'InstallFailed' | 'RebootInitiated' | 'Success' | 'Failure' | 'RescanStarted' | 'RescanComplete' | 'RescanFailed'; + +/** + * Defines values for DownloadPhase. + * Possible values include: 'Unknown', 'Initializing', 'Downloading', 'Verifying' + * @readonly + * @enum {string} + */ +export type DownloadPhase = 'Unknown' | 'Initializing' | 'Downloading' | 'Verifying'; + +/** + * Defines values for MetricUnit. + * Possible values include: 'NotSpecified', 'Percent', 'Count', 'Seconds', 'Milliseconds', 'Bytes', + * 'BytesPerSecond', 'CountPerSecond' + * @readonly + * @enum {string} + */ +export type MetricUnit = 'NotSpecified' | 'Percent' | 'Count' | 'Seconds' | 'Milliseconds' | 'Bytes' | 'BytesPerSecond' | 'CountPerSecond'; + +/** + * Defines values for MetricAggregationType. + * Possible values include: 'NotSpecified', 'None', 'Average', 'Minimum', 'Maximum', 'Total', + * 'Count' + * @readonly + * @enum {string} + */ +export type MetricAggregationType = 'NotSpecified' | 'None' | 'Average' | 'Minimum' | 'Maximum' | 'Total' | 'Count'; + +/** + * Defines values for MetricCategory. + * Possible values include: 'Capacity', 'Transaction' + * @readonly + * @enum {string} + */ +export type MetricCategory = 'Capacity' | 'Transaction'; + +/** + * Defines values for TimeGrain. + * Possible values include: 'PT1M', 'PT5M', 'PT15M', 'PT30M', 'PT1H', 'PT6H', 'PT12H', 'PT1D' + * @readonly + * @enum {string} + */ +export type TimeGrain = 'PT1M' | 'PT5M' | 'PT15M' | 'PT30M' | 'PT1H' | 'PT6H' | 'PT12H' | 'PT1D'; + +/** + * Defines values for NetworkGroup. + * Possible values include: 'None', 'NonRDMA', 'RDMA' + * @readonly + * @enum {string} + */ +export type NetworkGroup = 'None' | 'NonRDMA' | 'RDMA'; + +/** + * Defines values for NetworkAdapterStatus. + * Possible values include: 'Inactive', 'Active' + * @readonly + * @enum {string} + */ +export type NetworkAdapterStatus = 'Inactive' | 'Active'; + +/** + * Defines values for NetworkAdapterRDMAStatus. + * Possible values include: 'Incapable', 'Capable' + * @readonly + * @enum {string} + */ +export type NetworkAdapterRDMAStatus = 'Incapable' | 'Capable'; + +/** + * Defines values for NetworkAdapterDHCPStatus. + * Possible values include: 'Disabled', 'Enabled' + * @readonly + * @enum {string} + */ +export type NetworkAdapterDHCPStatus = 'Disabled' | 'Enabled'; + +/** + * Defines values for NodeStatus. + * Possible values include: 'Unknown', 'Up', 'Down', 'Rebooting', 'ShuttingDown' + * @readonly + * @enum {string} + */ +export type NodeStatus = 'Unknown' | 'Up' | 'Down' | 'Rebooting' | 'ShuttingDown'; + +/** + * Defines values for OrderState. + * Possible values include: 'Untracked', 'AwaitingFulfilment', 'AwaitingPreparation', + * 'AwaitingShipment', 'Shipped', 'Arriving', 'Delivered', 'ReplacementRequested', 'LostDevice', + * 'Declined', 'ReturnInitiated', 'AwaitingReturnShipment', 'ShippedBack', 'CollectedAtMicrosoft' + * @readonly + * @enum {string} + */ +export type OrderState = 'Untracked' | 'AwaitingFulfilment' | 'AwaitingPreparation' | 'AwaitingShipment' | 'Shipped' | 'Arriving' | 'Delivered' | 'ReplacementRequested' | 'LostDevice' | 'Declined' | 'ReturnInitiated' | 'AwaitingReturnShipment' | 'ShippedBack' | 'CollectedAtMicrosoft'; + +/** + * Defines values for AuthenticationType. + * Possible values include: 'Invalid', 'AzureActiveDirectory' + * @readonly + * @enum {string} + */ +export type AuthenticationType = 'Invalid' | 'AzureActiveDirectory'; + +/** + * Defines values for SkuRestrictionReasonCode. + * Possible values include: 'NotAvailableForSubscription', 'QuotaId' + * @readonly + * @enum {string} + */ +export type SkuRestrictionReasonCode = 'NotAvailableForSubscription' | 'QuotaId'; + +/** + * Defines values for ShareStatus. + * Possible values include: 'Offline', 'Unknown', 'OK', 'Updating', 'NeedsAttention' + * @readonly + * @enum {string} + */ +export type ShareStatus = 'Offline' | 'Unknown' | 'OK' | 'Updating' | 'NeedsAttention'; + +/** + * Defines values for MonitoringStatus. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type MonitoringStatus = 'Enabled' | 'Disabled'; + +/** + * Defines values for ShareAccessProtocol. + * Possible values include: 'SMB', 'NFS' + * @readonly + * @enum {string} + */ +export type ShareAccessProtocol = 'SMB' | 'NFS'; + +/** + * Defines values for ShareAccessType. + * Possible values include: 'Change', 'Read', 'Custom' + * @readonly + * @enum {string} + */ +export type ShareAccessType = 'Change' | 'Read' | 'Custom'; + +/** + * Defines values for DataPolicy. + * Possible values include: 'Cloud', 'Local' + * @readonly + * @enum {string} + */ +export type DataPolicy = 'Cloud' | 'Local'; + +/** + * Defines values for StorageAccountStatus. + * Possible values include: 'OK', 'Offline', 'Unknown', 'Updating', 'NeedsAttention' + * @readonly + * @enum {string} + */ +export type StorageAccountStatus = 'OK' | 'Offline' | 'Unknown' | 'Updating' | 'NeedsAttention'; + +/** + * Defines values for SSLStatus. + * Possible values include: 'Enabled', 'Disabled' + * @readonly + * @enum {string} + */ +export type SSLStatus = 'Enabled' | 'Disabled'; + +/** + * Defines values for AccountType. + * Possible values include: 'GeneralPurposeStorage', 'BlobStorage' + * @readonly + * @enum {string} + */ +export type AccountType = 'GeneralPurposeStorage' | 'BlobStorage'; + +/** + * Defines values for InstallRebootBehavior. + * Possible values include: 'NeverReboots', 'RequiresReboot', 'RequestReboot' + * @readonly + * @enum {string} + */ +export type InstallRebootBehavior = 'NeverReboots' | 'RequiresReboot' | 'RequestReboot'; + +/** + * Defines values for UpdateOperation. + * Possible values include: 'None', 'Scan', 'Download', 'Install' + * @readonly + * @enum {string} + */ +export type UpdateOperation = 'None' | 'Scan' | 'Download' | 'Install'; + +/** + * Defines values for UserType. + * Possible values include: 'Share', 'LocalManagement', 'ARM' + * @readonly + * @enum {string} + */ +export type UserType = 'Share' | 'LocalManagement' | 'ARM'; + +/** + * Contains response data for the list operation. + */ +export type OperationsListResponse = OperationsList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: OperationsList; + }; +}; + +/** + * Contains response data for the listNext operation. + */ +export type OperationsListNextResponse = OperationsList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: OperationsList; + }; +}; + +/** + * Contains response data for the listBySubscription operation. + */ +export type DevicesListBySubscriptionResponse = DataBoxEdgeDeviceList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDeviceList; + }; +}; + +/** + * Contains response data for the listByResourceGroup operation. + */ +export type DevicesListByResourceGroupResponse = DataBoxEdgeDeviceList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDeviceList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type DevicesGetResponse = DataBoxEdgeDevice & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDevice; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type DevicesCreateOrUpdateResponse = DataBoxEdgeDevice & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDevice; + }; +}; + +/** + * Contains response data for the update operation. + */ +export type DevicesUpdateResponse = DataBoxEdgeDevice & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDevice; + }; +}; + +/** + * Contains response data for the getExtendedInformation operation. + */ +export type DevicesGetExtendedInformationResponse = DataBoxEdgeDeviceExtendedInfo & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDeviceExtendedInfo; + }; +}; + +/** + * Contains response data for the getNetworkSettings operation. + */ +export type DevicesGetNetworkSettingsResponse = NetworkSettings & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: NetworkSettings; + }; +}; + +/** + * Contains response data for the getUpdateSummary operation. + */ +export type DevicesGetUpdateSummaryResponse = UpdateSummary & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: UpdateSummary; + }; +}; + +/** + * Contains response data for the uploadCertificate operation. + */ +export type DevicesUploadCertificateResponse = UploadCertificateResponse & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: UploadCertificateResponse; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type DevicesBeginCreateOrUpdateResponse = DataBoxEdgeDevice & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDevice; + }; +}; + +/** + * Contains response data for the listBySubscriptionNext operation. + */ +export type DevicesListBySubscriptionNextResponse = DataBoxEdgeDeviceList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDeviceList; + }; +}; + +/** + * Contains response data for the listByResourceGroupNext operation. + */ +export type DevicesListByResourceGroupNextResponse = DataBoxEdgeDeviceList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: DataBoxEdgeDeviceList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type AlertsListByDataBoxEdgeDeviceResponse = AlertList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: AlertList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type AlertsGetResponse = Alert & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Alert; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type AlertsListByDataBoxEdgeDeviceNextResponse = AlertList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: AlertList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type BandwidthSchedulesListByDataBoxEdgeDeviceResponse = BandwidthSchedulesList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: BandwidthSchedulesList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type BandwidthSchedulesGetResponse = BandwidthSchedule & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: BandwidthSchedule; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type BandwidthSchedulesCreateOrUpdateResponse = BandwidthSchedule & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: BandwidthSchedule; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type BandwidthSchedulesBeginCreateOrUpdateResponse = BandwidthSchedule & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: BandwidthSchedule; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type BandwidthSchedulesListByDataBoxEdgeDeviceNextResponse = BandwidthSchedulesList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: BandwidthSchedulesList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type JobsGetResponse = Job & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Job; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type NodesListByDataBoxEdgeDeviceResponse = NodeList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: NodeList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type OperationsStatusGetResponse = Job & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Job; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type OrdersListByDataBoxEdgeDeviceResponse = OrderList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: OrderList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type OrdersGetResponse = Order & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Order; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type OrdersCreateOrUpdateResponse = Order & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Order; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type OrdersBeginCreateOrUpdateResponse = Order & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Order; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type OrdersListByDataBoxEdgeDeviceNextResponse = OrderList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: OrderList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type RolesListByDataBoxEdgeDeviceResponse = RoleList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RoleList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type RolesGetResponse = RoleUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RoleUnion; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type RolesCreateOrUpdateResponse = RoleUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RoleUnion; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type RolesBeginCreateOrUpdateResponse = RoleUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RoleUnion; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type RolesListByDataBoxEdgeDeviceNextResponse = RoleList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: RoleList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type SharesListByDataBoxEdgeDeviceResponse = ShareList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: ShareList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type SharesGetResponse = Share & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Share; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type SharesCreateOrUpdateResponse = Share & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Share; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type SharesBeginCreateOrUpdateResponse = Share & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Share; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type SharesListByDataBoxEdgeDeviceNextResponse = ShareList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: ShareList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type StorageAccountCredentialsListByDataBoxEdgeDeviceResponse = StorageAccountCredentialList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountCredentialList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type StorageAccountCredentialsGetResponse = StorageAccountCredential & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountCredential; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type StorageAccountCredentialsCreateOrUpdateResponse = StorageAccountCredential & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountCredential; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type StorageAccountCredentialsBeginCreateOrUpdateResponse = StorageAccountCredential & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountCredential; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type StorageAccountCredentialsListByDataBoxEdgeDeviceNextResponse = StorageAccountCredentialList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountCredentialList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type StorageAccountsListByDataBoxEdgeDeviceResponse = StorageAccountList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type StorageAccountsGetResponse = StorageAccount & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccount; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type StorageAccountsCreateOrUpdateResponse = StorageAccount & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccount; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type StorageAccountsBeginCreateOrUpdateResponse = StorageAccount & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccount; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type StorageAccountsListByDataBoxEdgeDeviceNextResponse = StorageAccountList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: StorageAccountList; + }; +}; + +/** + * Contains response data for the listByStorageAccount operation. + */ +export type ContainersListByStorageAccountResponse = ContainerList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: ContainerList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type ContainersGetResponse = Container & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Container; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type ContainersCreateOrUpdateResponse = Container & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Container; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type ContainersBeginCreateOrUpdateResponse = Container & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: Container; + }; +}; + +/** + * Contains response data for the listByStorageAccountNext operation. + */ +export type ContainersListByStorageAccountNextResponse = ContainerList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: ContainerList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type TriggersListByDataBoxEdgeDeviceResponse = TriggerList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: TriggerList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type TriggersGetResponse = TriggerUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: TriggerUnion; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type TriggersCreateOrUpdateResponse = TriggerUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: TriggerUnion; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type TriggersBeginCreateOrUpdateResponse = TriggerUnion & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: TriggerUnion; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type TriggersListByDataBoxEdgeDeviceNextResponse = TriggerList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: TriggerList; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDevice operation. + */ +export type UsersListByDataBoxEdgeDeviceResponse = UserList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: UserList; + }; +}; + +/** + * Contains response data for the get operation. + */ +export type UsersGetResponse = User & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: User; + }; +}; + +/** + * Contains response data for the createOrUpdate operation. + */ +export type UsersCreateOrUpdateResponse = User & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: User; + }; +}; + +/** + * Contains response data for the beginCreateOrUpdate operation. + */ +export type UsersBeginCreateOrUpdateResponse = User & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: User; + }; +}; + +/** + * Contains response data for the listByDataBoxEdgeDeviceNext operation. + */ +export type UsersListByDataBoxEdgeDeviceNextResponse = UserList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: UserList; + }; +}; + +/** + * Contains response data for the list operation. + */ +export type SkusListResponse = SkuInformationList & { + /** + * The underlying HTTP response. + */ + _response: msRest.HttpResponse & { + /** + * The response body as text (string format) + */ + bodyAsText: string; + + /** + * The response body as parsed JSON or XML + */ + parsedBody: SkuInformationList; + }; +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/jobsMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/jobsMappers.ts new file mode 100644 index 000000000000..18867e1da432 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/jobsMappers.ts @@ -0,0 +1,17 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + CloudError, + Job, + JobErrorDetails, + JobErrorItem, + UpdateDownloadProgress, + UpdateInstallProgress +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/mappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/mappers.ts new file mode 100644 index 000000000000..0368dacebf8b --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/mappers.ts @@ -0,0 +1,3143 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +import { CloudErrorMapper, BaseResourceMapper } from "@azure/ms-rest-azure-js"; +import * as msRest from "@azure/ms-rest-js"; + +export const CloudError = CloudErrorMapper; +export const BaseResource = BaseResourceMapper; + +export const Address: msRest.CompositeMapper = { + serializedName: "Address", + type: { + name: "Composite", + className: "Address", + modelProperties: { + addressLine1: { + required: true, + serializedName: "addressLine1", + type: { + name: "String" + } + }, + addressLine2: { + serializedName: "addressLine2", + type: { + name: "String" + } + }, + addressLine3: { + serializedName: "addressLine3", + type: { + name: "String" + } + }, + postalCode: { + required: true, + serializedName: "postalCode", + type: { + name: "String" + } + }, + city: { + required: true, + serializedName: "city", + type: { + name: "String" + } + }, + state: { + required: true, + serializedName: "state", + type: { + name: "String" + } + }, + country: { + required: true, + serializedName: "country", + type: { + name: "String" + } + } + } + } +}; + +export const AlertErrorDetails: msRest.CompositeMapper = { + serializedName: "AlertErrorDetails", + type: { + name: "Composite", + className: "AlertErrorDetails", + modelProperties: { + errorCode: { + readOnly: true, + serializedName: "errorCode", + type: { + name: "String" + } + }, + errorMessage: { + readOnly: true, + serializedName: "errorMessage", + type: { + name: "String" + } + }, + occurrences: { + readOnly: true, + serializedName: "occurrences", + type: { + name: "Number" + } + } + } + } +}; + +export const ARMBaseModel: msRest.CompositeMapper = { + serializedName: "ARMBaseModel", + type: { + name: "Composite", + className: "ARMBaseModel", + modelProperties: { + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + } + } + } +}; + +export const Alert: msRest.CompositeMapper = { + serializedName: "Alert", + type: { + name: "Composite", + className: "Alert", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + title: { + readOnly: true, + serializedName: "properties.title", + type: { + name: "String" + } + }, + alertType: { + readOnly: true, + serializedName: "properties.alertType", + type: { + name: "String" + } + }, + appearedAtDateTime: { + readOnly: true, + serializedName: "properties.appearedAtDateTime", + type: { + name: "DateTime" + } + }, + recommendation: { + readOnly: true, + serializedName: "properties.recommendation", + type: { + name: "String" + } + }, + severity: { + readOnly: true, + serializedName: "properties.severity", + type: { + name: "String" + } + }, + errorDetails: { + readOnly: true, + serializedName: "properties.errorDetails", + type: { + name: "Composite", + className: "AlertErrorDetails" + } + }, + detailedInformation: { + readOnly: true, + serializedName: "properties.detailedInformation", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const AsymmetricEncryptedSecret: msRest.CompositeMapper = { + serializedName: "AsymmetricEncryptedSecret", + type: { + name: "Composite", + className: "AsymmetricEncryptedSecret", + modelProperties: { + value: { + required: true, + serializedName: "value", + type: { + name: "String" + } + }, + encryptionCertThumbprint: { + serializedName: "encryptionCertThumbprint", + type: { + name: "String" + } + }, + encryptionAlgorithm: { + required: true, + serializedName: "encryptionAlgorithm", + type: { + name: "String" + } + } + } + } +}; + +export const SymmetricKey: msRest.CompositeMapper = { + serializedName: "SymmetricKey", + type: { + name: "Composite", + className: "SymmetricKey", + modelProperties: { + connectionString: { + serializedName: "connectionString", + type: { + name: "Composite", + className: "AsymmetricEncryptedSecret" + } + } + } + } +}; + +export const Authentication: msRest.CompositeMapper = { + serializedName: "Authentication", + type: { + name: "Composite", + className: "Authentication", + modelProperties: { + symmetricKey: { + serializedName: "symmetricKey", + type: { + name: "Composite", + className: "SymmetricKey" + } + } + } + } +}; + +export const AzureContainerInfo: msRest.CompositeMapper = { + serializedName: "AzureContainerInfo", + type: { + name: "Composite", + className: "AzureContainerInfo", + modelProperties: { + storageAccountCredentialId: { + required: true, + serializedName: "storageAccountCredentialId", + type: { + name: "String" + } + }, + containerName: { + required: true, + serializedName: "containerName", + type: { + name: "String" + } + }, + dataFormat: { + required: true, + serializedName: "dataFormat", + type: { + name: "String" + } + } + } + } +}; + +export const BandwidthSchedule: msRest.CompositeMapper = { + serializedName: "BandwidthSchedule", + type: { + name: "Composite", + className: "BandwidthSchedule", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + start: { + required: true, + serializedName: "properties.start", + type: { + name: "String" + } + }, + stop: { + required: true, + serializedName: "properties.stop", + type: { + name: "String" + } + }, + rateInMbps: { + required: true, + serializedName: "properties.rateInMbps", + type: { + name: "Number" + } + }, + days: { + required: true, + serializedName: "properties.days", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const ClientAccessRight: msRest.CompositeMapper = { + serializedName: "ClientAccessRight", + type: { + name: "Composite", + className: "ClientAccessRight", + modelProperties: { + client: { + required: true, + serializedName: "client", + type: { + name: "String" + } + }, + accessPermission: { + required: true, + serializedName: "accessPermission", + type: { + name: "String" + } + } + } + } +}; + +export const ContactDetails: msRest.CompositeMapper = { + serializedName: "ContactDetails", + type: { + name: "Composite", + className: "ContactDetails", + modelProperties: { + contactPerson: { + required: true, + serializedName: "contactPerson", + type: { + name: "String" + } + }, + companyName: { + required: true, + serializedName: "companyName", + type: { + name: "String" + } + }, + phone: { + required: true, + serializedName: "phone", + type: { + name: "String" + } + }, + emailList: { + required: true, + serializedName: "emailList", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const RefreshDetails: msRest.CompositeMapper = { + serializedName: "RefreshDetails", + type: { + name: "Composite", + className: "RefreshDetails", + modelProperties: { + inProgressRefreshJobId: { + serializedName: "inProgressRefreshJobId", + type: { + name: "String" + } + }, + lastCompletedRefreshJobTimeInUTC: { + serializedName: "lastCompletedRefreshJobTimeInUTC", + type: { + name: "DateTime" + } + }, + errorManifestFile: { + serializedName: "errorManifestFile", + type: { + name: "String" + } + }, + lastJob: { + serializedName: "lastJob", + type: { + name: "String" + } + } + } + } +}; + +export const Container: msRest.CompositeMapper = { + serializedName: "Container", + type: { + name: "Composite", + className: "Container", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + containerStatus: { + readOnly: true, + serializedName: "properties.containerStatus", + type: { + name: "String" + } + }, + dataFormat: { + required: true, + serializedName: "properties.dataFormat", + type: { + name: "String" + } + }, + refreshDetails: { + readOnly: true, + serializedName: "properties.refreshDetails", + type: { + name: "Composite", + className: "RefreshDetails" + } + }, + createdDateTime: { + readOnly: true, + serializedName: "properties.createdDateTime", + type: { + name: "DateTime" + } + } + } + } +}; + +export const Sku: msRest.CompositeMapper = { + serializedName: "Sku", + type: { + name: "Composite", + className: "Sku", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + tier: { + serializedName: "tier", + type: { + name: "String" + } + } + } + } +}; + +export const DataBoxEdgeDevice: msRest.CompositeMapper = { + serializedName: "DataBoxEdgeDevice", + type: { + name: "Composite", + className: "DataBoxEdgeDevice", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + location: { + required: true, + serializedName: "location", + type: { + name: "String" + } + }, + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + }, + sku: { + serializedName: "sku", + type: { + name: "Composite", + className: "Sku" + } + }, + etag: { + serializedName: "etag", + type: { + name: "String" + } + }, + dataBoxEdgeDeviceStatus: { + serializedName: "properties.dataBoxEdgeDeviceStatus", + type: { + name: "String" + } + }, + serialNumber: { + readOnly: true, + serializedName: "properties.serialNumber", + type: { + name: "String" + } + }, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + modelDescription: { + serializedName: "properties.modelDescription", + type: { + name: "String" + } + }, + deviceType: { + readOnly: true, + serializedName: "properties.deviceType", + type: { + name: "String" + } + }, + friendlyName: { + serializedName: "properties.friendlyName", + type: { + name: "String" + } + }, + culture: { + readOnly: true, + serializedName: "properties.culture", + type: { + name: "String" + } + }, + deviceModel: { + readOnly: true, + serializedName: "properties.deviceModel", + type: { + name: "String" + } + }, + deviceSoftwareVersion: { + readOnly: true, + serializedName: "properties.deviceSoftwareVersion", + type: { + name: "String" + } + }, + deviceLocalCapacity: { + readOnly: true, + serializedName: "properties.deviceLocalCapacity", + type: { + name: "Number" + } + }, + timeZone: { + readOnly: true, + serializedName: "properties.timeZone", + type: { + name: "String" + } + }, + deviceHcsVersion: { + readOnly: true, + serializedName: "properties.deviceHcsVersion", + type: { + name: "String" + } + }, + configuredRoleTypes: { + readOnly: true, + serializedName: "properties.configuredRoleTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + nodeCount: { + readOnly: true, + serializedName: "properties.nodeCount", + type: { + name: "Number" + } + } + } + } +}; + +export const DataBoxEdgeDeviceExtendedInfo: msRest.CompositeMapper = { + serializedName: "DataBoxEdgeDeviceExtendedInfo", + type: { + name: "Composite", + className: "DataBoxEdgeDeviceExtendedInfo", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + encryptionKeyThumbprint: { + serializedName: "properties.encryptionKeyThumbprint", + type: { + name: "String" + } + }, + encryptionKey: { + serializedName: "properties.encryptionKey", + type: { + name: "String" + } + }, + resourceKey: { + readOnly: true, + serializedName: "properties.resourceKey", + type: { + name: "String" + } + } + } + } +}; + +export const DataBoxEdgeDevicePatch: msRest.CompositeMapper = { + serializedName: "DataBoxEdgeDevicePatch", + type: { + name: "Composite", + className: "DataBoxEdgeDevicePatch", + modelProperties: { + tags: { + serializedName: "tags", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const FileSourceInfo: msRest.CompositeMapper = { + serializedName: "FileSourceInfo", + type: { + name: "Composite", + className: "FileSourceInfo", + modelProperties: { + shareId: { + required: true, + serializedName: "shareId", + type: { + name: "String" + } + } + } + } +}; + +export const RoleSinkInfo: msRest.CompositeMapper = { + serializedName: "RoleSinkInfo", + type: { + name: "Composite", + className: "RoleSinkInfo", + modelProperties: { + roleId: { + required: true, + serializedName: "roleId", + type: { + name: "String" + } + } + } + } +}; + +export const Trigger: msRest.CompositeMapper = { + serializedName: "Trigger", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "kind", + clientName: "kind" + }, + uberParent: "Trigger", + className: "Trigger", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + kind: { + required: true, + serializedName: "kind", + type: { + name: "String" + } + } + } + } +}; + +export const FileEventTrigger: msRest.CompositeMapper = { + serializedName: "FileEvent", + type: { + name: "Composite", + polymorphicDiscriminator: Trigger.type.polymorphicDiscriminator, + uberParent: "Trigger", + className: "FileEventTrigger", + modelProperties: { + ...Trigger.type.modelProperties, + sourceInfo: { + required: true, + serializedName: "properties.sourceInfo", + type: { + name: "Composite", + className: "FileSourceInfo" + } + }, + sinkInfo: { + required: true, + serializedName: "properties.sinkInfo", + type: { + name: "Composite", + className: "RoleSinkInfo" + } + }, + customContextTag: { + serializedName: "properties.customContextTag", + type: { + name: "String" + } + } + } + } +}; + +export const IoTDeviceInfo: msRest.CompositeMapper = { + serializedName: "IoTDeviceInfo", + type: { + name: "Composite", + className: "IoTDeviceInfo", + modelProperties: { + deviceId: { + required: true, + serializedName: "deviceId", + type: { + name: "String" + } + }, + ioTHostHub: { + required: true, + serializedName: "ioTHostHub", + type: { + name: "String" + } + }, + ioTHostHubId: { + serializedName: "ioTHostHubId", + type: { + name: "String" + } + }, + authentication: { + serializedName: "authentication", + type: { + name: "Composite", + className: "Authentication" + } + } + } + } +}; + +export const MountPointMap: msRest.CompositeMapper = { + serializedName: "MountPointMap", + type: { + name: "Composite", + className: "MountPointMap", + modelProperties: { + shareId: { + required: true, + serializedName: "shareId", + type: { + name: "String" + } + }, + roleId: { + readOnly: true, + serializedName: "roleId", + type: { + name: "String" + } + }, + mountPoint: { + readOnly: true, + serializedName: "mountPoint", + type: { + name: "String" + } + }, + roleType: { + readOnly: true, + serializedName: "roleType", + type: { + name: "String" + } + } + } + } +}; + +export const Role: msRest.CompositeMapper = { + serializedName: "Role", + type: { + name: "Composite", + polymorphicDiscriminator: { + serializedName: "kind", + clientName: "kind" + }, + uberParent: "Role", + className: "Role", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + kind: { + required: true, + serializedName: "kind", + type: { + name: "String" + } + } + } + } +}; + +export const IoTRole: msRest.CompositeMapper = { + serializedName: "IOT", + type: { + name: "Composite", + polymorphicDiscriminator: Role.type.polymorphicDiscriminator, + uberParent: "Role", + className: "IoTRole", + modelProperties: { + ...Role.type.modelProperties, + hostPlatform: { + required: true, + serializedName: "properties.hostPlatform", + type: { + name: "String" + } + }, + ioTDeviceDetails: { + required: true, + serializedName: "properties.ioTDeviceDetails", + type: { + name: "Composite", + className: "IoTDeviceInfo" + } + }, + ioTEdgeDeviceDetails: { + required: true, + serializedName: "properties.ioTEdgeDeviceDetails", + type: { + name: "Composite", + className: "IoTDeviceInfo" + } + }, + shareMappings: { + serializedName: "properties.shareMappings", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MountPointMap" + } + } + } + }, + roleStatus: { + required: true, + serializedName: "properties.roleStatus", + type: { + name: "String" + } + } + } + } +}; + +export const Ipv4Config: msRest.CompositeMapper = { + serializedName: "Ipv4Config", + type: { + name: "Composite", + className: "Ipv4Config", + modelProperties: { + ipAddress: { + readOnly: true, + serializedName: "ipAddress", + type: { + name: "String" + } + }, + subnet: { + readOnly: true, + serializedName: "subnet", + type: { + name: "String" + } + }, + gateway: { + readOnly: true, + serializedName: "gateway", + type: { + name: "String" + } + } + } + } +}; + +export const Ipv6Config: msRest.CompositeMapper = { + serializedName: "Ipv6Config", + type: { + name: "Composite", + className: "Ipv6Config", + modelProperties: { + ipAddress: { + readOnly: true, + serializedName: "ipAddress", + type: { + name: "String" + } + }, + prefixLength: { + readOnly: true, + serializedName: "prefixLength", + type: { + name: "Number" + } + }, + gateway: { + readOnly: true, + serializedName: "gateway", + type: { + name: "String" + } + } + } + } +}; + +export const JobErrorItem: msRest.CompositeMapper = { + serializedName: "JobErrorItem", + type: { + name: "Composite", + className: "JobErrorItem", + modelProperties: { + recommendations: { + readOnly: true, + serializedName: "recommendations", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + code: { + readOnly: true, + serializedName: "code", + type: { + name: "String" + } + }, + message: { + readOnly: true, + serializedName: "message", + type: { + name: "String" + } + } + } + } +}; + +export const JobErrorDetails: msRest.CompositeMapper = { + serializedName: "JobErrorDetails", + type: { + name: "Composite", + className: "JobErrorDetails", + modelProperties: { + errorDetails: { + readOnly: true, + serializedName: "errorDetails", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "JobErrorItem" + } + } + } + }, + code: { + readOnly: true, + serializedName: "code", + type: { + name: "String" + } + }, + message: { + readOnly: true, + serializedName: "message", + type: { + name: "String" + } + } + } + } +}; + +export const UpdateDownloadProgress: msRest.CompositeMapper = { + serializedName: "UpdateDownloadProgress", + type: { + name: "Composite", + className: "UpdateDownloadProgress", + modelProperties: { + downloadPhase: { + readOnly: true, + serializedName: "downloadPhase", + type: { + name: "String" + } + }, + percentComplete: { + readOnly: true, + serializedName: "percentComplete", + type: { + name: "Number" + } + }, + totalBytesToDownload: { + readOnly: true, + serializedName: "totalBytesToDownload", + type: { + name: "Number" + } + }, + totalBytesDownloaded: { + readOnly: true, + serializedName: "totalBytesDownloaded", + type: { + name: "Number" + } + }, + numberOfUpdatesToDownload: { + readOnly: true, + serializedName: "numberOfUpdatesToDownload", + type: { + name: "Number" + } + }, + numberOfUpdatesDownloaded: { + readOnly: true, + serializedName: "numberOfUpdatesDownloaded", + type: { + name: "Number" + } + } + } + } +}; + +export const UpdateInstallProgress: msRest.CompositeMapper = { + serializedName: "UpdateInstallProgress", + type: { + name: "Composite", + className: "UpdateInstallProgress", + modelProperties: { + percentComplete: { + readOnly: true, + serializedName: "percentComplete", + type: { + name: "Number" + } + }, + numberOfUpdatesToInstall: { + readOnly: true, + serializedName: "numberOfUpdatesToInstall", + type: { + name: "Number" + } + }, + numberOfUpdatesInstalled: { + readOnly: true, + serializedName: "numberOfUpdatesInstalled", + type: { + name: "Number" + } + } + } + } +}; + +export const Job: msRest.CompositeMapper = { + serializedName: "Job", + type: { + name: "Composite", + className: "Job", + modelProperties: { + id: { + readOnly: true, + serializedName: "id", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + status: { + readOnly: true, + serializedName: "status", + type: { + name: "String" + } + }, + startTime: { + readOnly: true, + serializedName: "startTime", + type: { + name: "DateTime" + } + }, + endTime: { + readOnly: true, + serializedName: "endTime", + type: { + name: "DateTime" + } + }, + percentComplete: { + readOnly: true, + serializedName: "percentComplete", + type: { + name: "Number" + } + }, + error: { + readOnly: true, + serializedName: "error", + type: { + name: "Composite", + className: "JobErrorDetails" + } + }, + jobType: { + readOnly: true, + serializedName: "properties.jobType", + type: { + name: "String" + } + }, + currentStage: { + readOnly: true, + serializedName: "properties.currentStage", + type: { + name: "String" + } + }, + downloadProgress: { + readOnly: true, + serializedName: "properties.downloadProgress", + type: { + name: "Composite", + className: "UpdateDownloadProgress" + } + }, + installProgress: { + readOnly: true, + serializedName: "properties.installProgress", + type: { + name: "Composite", + className: "UpdateInstallProgress" + } + }, + totalRefreshErrors: { + readOnly: true, + serializedName: "properties.totalRefreshErrors", + type: { + name: "Number" + } + }, + errorManifestFile: { + readOnly: true, + serializedName: "properties.errorManifestFile", + type: { + name: "String" + } + }, + refreshedEntityId: { + readOnly: true, + serializedName: "properties.refreshedEntityId", + type: { + name: "String" + } + }, + folder: { + serializedName: "properties.folder", + type: { + name: "String" + } + } + } + } +}; + +export const MetricDimensionV1: msRest.CompositeMapper = { + serializedName: "MetricDimension_V1", + type: { + name: "Composite", + className: "MetricDimensionV1", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + displayName: { + serializedName: "displayName", + type: { + name: "String" + } + }, + toBeExportedForShoebox: { + serializedName: "toBeExportedForShoebox", + type: { + name: "Boolean" + } + } + } + } +}; + +export const MetricSpecificationV1: msRest.CompositeMapper = { + serializedName: "MetricSpecification_V1", + type: { + name: "Composite", + className: "MetricSpecificationV1", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + displayName: { + serializedName: "displayName", + type: { + name: "String" + } + }, + displayDescription: { + serializedName: "displayDescription", + type: { + name: "String" + } + }, + unit: { + serializedName: "unit", + type: { + name: "String" + } + }, + aggregationType: { + serializedName: "aggregationType", + type: { + name: "String" + } + }, + dimensions: { + serializedName: "dimensions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MetricDimensionV1" + } + } + } + }, + fillGapWithZero: { + serializedName: "fillGapWithZero", + type: { + name: "Boolean" + } + }, + category: { + serializedName: "category", + type: { + name: "String" + } + }, + resourceIdDimensionNameOverride: { + serializedName: "resourceIdDimensionNameOverride", + type: { + name: "String" + } + }, + supportedTimeGrainTypes: { + serializedName: "supportedTimeGrainTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + supportedAggregationTypes: { + serializedName: "supportedAggregationTypes", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const NetworkAdapterPosition: msRest.CompositeMapper = { + serializedName: "NetworkAdapterPosition", + type: { + name: "Composite", + className: "NetworkAdapterPosition", + modelProperties: { + networkGroup: { + readOnly: true, + serializedName: "networkGroup", + type: { + name: "String" + } + }, + port: { + readOnly: true, + serializedName: "port", + type: { + name: "Number" + } + } + } + } +}; + +export const NetworkAdapter: msRest.CompositeMapper = { + serializedName: "NetworkAdapter", + type: { + name: "Composite", + className: "NetworkAdapter", + modelProperties: { + adapterId: { + readOnly: true, + serializedName: "adapterId", + type: { + name: "String" + } + }, + adapterPosition: { + readOnly: true, + serializedName: "adapterPosition", + type: { + name: "Composite", + className: "NetworkAdapterPosition" + } + }, + index: { + readOnly: true, + serializedName: "index", + type: { + name: "Number" + } + }, + nodeId: { + readOnly: true, + serializedName: "nodeId", + type: { + name: "String" + } + }, + networkAdapterName: { + readOnly: true, + serializedName: "networkAdapterName", + type: { + name: "String" + } + }, + label: { + readOnly: true, + serializedName: "label", + type: { + name: "String" + } + }, + macAddress: { + readOnly: true, + serializedName: "macAddress", + type: { + name: "String" + } + }, + linkSpeed: { + readOnly: true, + serializedName: "linkSpeed", + type: { + name: "Number" + } + }, + status: { + readOnly: true, + serializedName: "status", + type: { + name: "String" + } + }, + rdmaStatus: { + serializedName: "rdmaStatus", + type: { + name: "String" + } + }, + dhcpStatus: { + serializedName: "dhcpStatus", + type: { + name: "String" + } + }, + ipv4Configuration: { + readOnly: true, + serializedName: "ipv4Configuration", + type: { + name: "Composite", + className: "Ipv4Config" + } + }, + ipv6Configuration: { + readOnly: true, + serializedName: "ipv6Configuration", + type: { + name: "Composite", + className: "Ipv6Config" + } + }, + ipv6LinkLocalAddress: { + readOnly: true, + serializedName: "ipv6LinkLocalAddress", + type: { + name: "String" + } + }, + dnsServers: { + readOnly: true, + serializedName: "dnsServers", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const NetworkSettings: msRest.CompositeMapper = { + serializedName: "NetworkSettings", + type: { + name: "Composite", + className: "NetworkSettings", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + networkAdapters: { + readOnly: true, + serializedName: "properties.networkAdapters", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "NetworkAdapter" + } + } + } + } + } + } +}; + +export const Node: msRest.CompositeMapper = { + serializedName: "Node", + type: { + name: "Composite", + className: "Node", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + nodeStatus: { + readOnly: true, + serializedName: "properties.nodeStatus", + type: { + name: "String" + } + }, + nodeChassisSerialNumber: { + readOnly: true, + serializedName: "properties.nodeChassisSerialNumber", + type: { + name: "String" + } + }, + nodeSerialNumber: { + readOnly: true, + serializedName: "properties.nodeSerialNumber", + type: { + name: "String" + } + }, + nodeDisplayName: { + readOnly: true, + serializedName: "properties.nodeDisplayName", + type: { + name: "String" + } + }, + nodeFriendlySoftwareVersion: { + readOnly: true, + serializedName: "properties.nodeFriendlySoftwareVersion", + type: { + name: "String" + } + }, + nodeHcsVersion: { + readOnly: true, + serializedName: "properties.nodeHcsVersion", + type: { + name: "String" + } + }, + nodeInstanceId: { + readOnly: true, + serializedName: "properties.nodeInstanceId", + type: { + name: "String" + } + } + } + } +}; + +export const OperationDisplay: msRest.CompositeMapper = { + serializedName: "OperationDisplay", + type: { + name: "Composite", + className: "OperationDisplay", + modelProperties: { + provider: { + serializedName: "provider", + type: { + name: "String" + } + }, + resource: { + serializedName: "resource", + type: { + name: "String" + } + }, + operation: { + serializedName: "operation", + type: { + name: "String" + } + }, + description: { + serializedName: "description", + type: { + name: "String" + } + } + } + } +}; + +export const ServiceSpecification: msRest.CompositeMapper = { + serializedName: "ServiceSpecification", + type: { + name: "Composite", + className: "ServiceSpecification", + modelProperties: { + metricSpecifications: { + serializedName: "metricSpecifications", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MetricSpecificationV1" + } + } + } + } + } + } +}; + +export const Operation: msRest.CompositeMapper = { + serializedName: "Operation", + type: { + name: "Composite", + className: "Operation", + modelProperties: { + name: { + serializedName: "name", + type: { + name: "String" + } + }, + display: { + serializedName: "display", + type: { + name: "Composite", + className: "OperationDisplay" + } + }, + origin: { + serializedName: "origin", + type: { + name: "String" + } + }, + serviceSpecification: { + serializedName: "properties.serviceSpecification", + type: { + name: "Composite", + className: "ServiceSpecification" + } + } + } + } +}; + +export const OrderStatus: msRest.CompositeMapper = { + serializedName: "OrderStatus", + type: { + name: "Composite", + className: "OrderStatus", + modelProperties: { + status: { + required: true, + serializedName: "status", + type: { + name: "String" + } + }, + updateDateTime: { + readOnly: true, + serializedName: "updateDateTime", + type: { + name: "DateTime" + } + }, + comments: { + serializedName: "comments", + type: { + name: "String" + } + }, + additionalOrderDetails: { + readOnly: true, + serializedName: "additionalOrderDetails", + type: { + name: "Dictionary", + value: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const TrackingInfo: msRest.CompositeMapper = { + serializedName: "TrackingInfo", + type: { + name: "Composite", + className: "TrackingInfo", + modelProperties: { + serialNumber: { + serializedName: "serialNumber", + type: { + name: "String" + } + }, + carrierName: { + serializedName: "carrierName", + type: { + name: "String" + } + }, + trackingId: { + serializedName: "trackingId", + type: { + name: "String" + } + }, + trackingUrl: { + serializedName: "trackingUrl", + type: { + name: "String" + } + } + } + } +}; + +export const Order: msRest.CompositeMapper = { + serializedName: "Order", + type: { + name: "Composite", + className: "Order", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + contactInformation: { + required: true, + serializedName: "properties.contactInformation", + type: { + name: "Composite", + className: "ContactDetails" + } + }, + shippingAddress: { + required: true, + serializedName: "properties.shippingAddress", + type: { + name: "Composite", + className: "Address" + } + }, + currentStatus: { + serializedName: "properties.currentStatus", + type: { + name: "Composite", + className: "OrderStatus" + } + }, + orderHistory: { + readOnly: true, + serializedName: "properties.orderHistory", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "OrderStatus" + } + } + } + }, + serialNumber: { + readOnly: true, + serializedName: "properties.serialNumber", + type: { + name: "String" + } + }, + deliveryTrackingInfo: { + readOnly: true, + serializedName: "properties.deliveryTrackingInfo", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "TrackingInfo" + } + } + } + }, + returnTrackingInfo: { + readOnly: true, + serializedName: "properties.returnTrackingInfo", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "TrackingInfo" + } + } + } + } + } + } +}; + +export const PeriodicTimerSourceInfo: msRest.CompositeMapper = { + serializedName: "PeriodicTimerSourceInfo", + type: { + name: "Composite", + className: "PeriodicTimerSourceInfo", + modelProperties: { + startTime: { + required: true, + serializedName: "startTime", + type: { + name: "DateTime" + } + }, + schedule: { + required: true, + serializedName: "schedule", + type: { + name: "String" + } + }, + topic: { + serializedName: "topic", + type: { + name: "String" + } + } + } + } +}; + +export const PeriodicTimerEventTrigger: msRest.CompositeMapper = { + serializedName: "PeriodicTimerEvent", + type: { + name: "Composite", + polymorphicDiscriminator: Trigger.type.polymorphicDiscriminator, + uberParent: "Trigger", + className: "PeriodicTimerEventTrigger", + modelProperties: { + ...Trigger.type.modelProperties, + sourceInfo: { + required: true, + serializedName: "properties.sourceInfo", + type: { + name: "Composite", + className: "PeriodicTimerSourceInfo" + } + }, + sinkInfo: { + required: true, + serializedName: "properties.sinkInfo", + type: { + name: "Composite", + className: "RoleSinkInfo" + } + }, + customContextTag: { + serializedName: "properties.customContextTag", + type: { + name: "String" + } + } + } + } +}; + +export const SkuLocationInfo: msRest.CompositeMapper = { + serializedName: "SkuLocationInfo", + type: { + name: "Composite", + className: "SkuLocationInfo", + modelProperties: { + location: { + readOnly: true, + serializedName: "location", + type: { + name: "String" + } + }, + zones: { + readOnly: true, + serializedName: "zones", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + sites: { + readOnly: true, + serializedName: "sites", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const SkuCost: msRest.CompositeMapper = { + serializedName: "SkuCost", + type: { + name: "Composite", + className: "SkuCost", + modelProperties: { + meterId: { + readOnly: true, + serializedName: "meterId", + type: { + name: "String" + } + }, + quantity: { + readOnly: true, + serializedName: "quantity", + type: { + name: "Number" + } + }, + extendedUnit: { + readOnly: true, + serializedName: "extendedUnit", + type: { + name: "String" + } + } + } + } +}; + +export const SkuRestrictionInfo: msRest.CompositeMapper = { + serializedName: "SkuRestrictionInfo", + type: { + name: "Composite", + className: "SkuRestrictionInfo", + modelProperties: { + locations: { + readOnly: true, + serializedName: "locations", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + zones: { + readOnly: true, + serializedName: "zones", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + } + } + } +}; + +export const SkuRestriction: msRest.CompositeMapper = { + serializedName: "SkuRestriction", + type: { + name: "Composite", + className: "SkuRestriction", + modelProperties: { + type: { + readOnly: true, + serializedName: "type", + type: { + name: "String" + } + }, + values: { + readOnly: true, + serializedName: "values", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + reasonCode: { + readOnly: true, + serializedName: "reasonCode", + type: { + name: "String" + } + }, + restrictionInfo: { + readOnly: true, + serializedName: "restrictionInfo", + type: { + name: "Composite", + className: "SkuRestrictionInfo" + } + } + } + } +}; + +export const ResourceTypeSku: msRest.CompositeMapper = { + serializedName: "ResourceTypeSku", + type: { + name: "Composite", + className: "ResourceTypeSku", + modelProperties: { + resourceType: { + readOnly: true, + serializedName: "resourceType", + type: { + name: "String" + } + }, + name: { + readOnly: true, + serializedName: "name", + type: { + name: "String" + } + }, + kind: { + readOnly: true, + serializedName: "kind", + type: { + name: "String" + } + }, + tier: { + readOnly: true, + serializedName: "tier", + type: { + name: "String" + } + }, + family: { + readOnly: true, + serializedName: "family", + type: { + name: "String" + } + }, + locations: { + readOnly: true, + serializedName: "locations", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + apiVersions: { + readOnly: true, + serializedName: "apiVersions", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + locationInfo: { + readOnly: true, + serializedName: "locationInfo", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SkuLocationInfo" + } + } + } + }, + costs: { + readOnly: true, + serializedName: "costs", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SkuCost" + } + } + } + }, + restrictions: { + readOnly: true, + serializedName: "restrictions", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "SkuRestriction" + } + } + } + } + } + } +}; + +export const SecuritySettings: msRest.CompositeMapper = { + serializedName: "SecuritySettings", + type: { + name: "Composite", + className: "SecuritySettings", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + deviceAdminPassword: { + required: true, + serializedName: "properties.deviceAdminPassword", + type: { + name: "Composite", + className: "AsymmetricEncryptedSecret" + } + } + } + } +}; + +export const UserAccessRight: msRest.CompositeMapper = { + serializedName: "UserAccessRight", + type: { + name: "Composite", + className: "UserAccessRight", + modelProperties: { + userId: { + required: true, + serializedName: "userId", + type: { + name: "String" + } + }, + accessType: { + required: true, + serializedName: "accessType", + type: { + name: "String" + } + } + } + } +}; + +export const Share: msRest.CompositeMapper = { + serializedName: "Share", + type: { + name: "Composite", + className: "Share", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + shareStatus: { + required: true, + serializedName: "properties.shareStatus", + type: { + name: "String" + } + }, + monitoringStatus: { + required: true, + serializedName: "properties.monitoringStatus", + type: { + name: "String" + } + }, + azureContainerInfo: { + serializedName: "properties.azureContainerInfo", + type: { + name: "Composite", + className: "AzureContainerInfo" + } + }, + accessProtocol: { + required: true, + serializedName: "properties.accessProtocol", + type: { + name: "String" + } + }, + userAccessRights: { + serializedName: "properties.userAccessRights", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "UserAccessRight" + } + } + } + }, + clientAccessRights: { + serializedName: "properties.clientAccessRights", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ClientAccessRight" + } + } + } + }, + refreshDetails: { + serializedName: "properties.refreshDetails", + type: { + name: "Composite", + className: "RefreshDetails" + } + }, + shareMappings: { + readOnly: true, + serializedName: "properties.shareMappings", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "MountPointMap" + } + } + } + }, + dataPolicy: { + serializedName: "properties.dataPolicy", + type: { + name: "String" + } + } + } + } +}; + +export const ShareAccessRight: msRest.CompositeMapper = { + serializedName: "ShareAccessRight", + type: { + name: "Composite", + className: "ShareAccessRight", + modelProperties: { + shareId: { + required: true, + serializedName: "shareId", + type: { + name: "String" + } + }, + accessType: { + required: true, + serializedName: "accessType", + type: { + name: "String" + } + } + } + } +}; + +export const StorageAccount: msRest.CompositeMapper = { + serializedName: "StorageAccount", + type: { + name: "Composite", + className: "StorageAccount", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + description: { + serializedName: "properties.description", + type: { + name: "String" + } + }, + storageAccountStatus: { + serializedName: "properties.storageAccountStatus", + type: { + name: "String" + } + }, + dataPolicy: { + serializedName: "properties.dataPolicy", + type: { + name: "String" + } + }, + storageAccountCredentialId: { + serializedName: "properties.storageAccountCredentialId", + type: { + name: "String" + } + }, + blobEndpoint: { + readOnly: true, + serializedName: "properties.blobEndpoint", + type: { + name: "String" + } + }, + containerCount: { + readOnly: true, + serializedName: "properties.containerCount", + type: { + name: "Number" + } + } + } + } +}; + +export const StorageAccountCredential: msRest.CompositeMapper = { + serializedName: "StorageAccountCredential", + type: { + name: "Composite", + className: "StorageAccountCredential", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + alias: { + required: true, + serializedName: "properties.alias", + type: { + name: "String" + } + }, + userName: { + serializedName: "properties.userName", + type: { + name: "String" + } + }, + accountKey: { + serializedName: "properties.accountKey", + type: { + name: "Composite", + className: "AsymmetricEncryptedSecret" + } + }, + connectionString: { + serializedName: "properties.connectionString", + type: { + name: "String" + } + }, + sslStatus: { + required: true, + serializedName: "properties.sslStatus", + type: { + name: "String" + } + }, + blobDomainName: { + serializedName: "properties.blobDomainName", + type: { + name: "String" + } + }, + accountType: { + required: true, + serializedName: "properties.accountType", + type: { + name: "String" + } + }, + storageAccountId: { + serializedName: "properties.storageAccountId", + type: { + name: "String" + } + } + } + } +}; + +export const UpdateSummary: msRest.CompositeMapper = { + serializedName: "UpdateSummary", + type: { + name: "Composite", + className: "UpdateSummary", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + deviceVersionNumber: { + serializedName: "properties.deviceVersionNumber", + type: { + name: "String" + } + }, + friendlyDeviceVersionName: { + serializedName: "properties.friendlyDeviceVersionName", + type: { + name: "String" + } + }, + deviceLastScannedDateTime: { + serializedName: "properties.deviceLastScannedDateTime", + type: { + name: "DateTime" + } + }, + lastCompletedScanJobDateTime: { + serializedName: "properties.lastCompletedScanJobDateTime", + type: { + name: "DateTime" + } + }, + lastCompletedDownloadJobDateTime: { + readOnly: true, + serializedName: "properties.lastCompletedDownloadJobDateTime", + type: { + name: "DateTime" + } + }, + lastCompletedInstallJobDateTime: { + readOnly: true, + serializedName: "properties.lastCompletedInstallJobDateTime", + type: { + name: "DateTime" + } + }, + totalNumberOfUpdatesAvailable: { + readOnly: true, + serializedName: "properties.totalNumberOfUpdatesAvailable", + type: { + name: "Number" + } + }, + totalNumberOfUpdatesPendingDownload: { + readOnly: true, + serializedName: "properties.totalNumberOfUpdatesPendingDownload", + type: { + name: "Number" + } + }, + totalNumberOfUpdatesPendingInstall: { + readOnly: true, + serializedName: "properties.totalNumberOfUpdatesPendingInstall", + type: { + name: "Number" + } + }, + rebootBehavior: { + readOnly: true, + serializedName: "properties.rebootBehavior", + type: { + name: "String" + } + }, + ongoingUpdateOperation: { + readOnly: true, + serializedName: "properties.ongoingUpdateOperation", + type: { + name: "String" + } + }, + inProgressDownloadJobId: { + readOnly: true, + serializedName: "properties.inProgressDownloadJobId", + type: { + name: "String" + } + }, + inProgressInstallJobId: { + readOnly: true, + serializedName: "properties.inProgressInstallJobId", + type: { + name: "String" + } + }, + inProgressDownloadJobStartedDateTime: { + readOnly: true, + serializedName: "properties.inProgressDownloadJobStartedDateTime", + type: { + name: "DateTime" + } + }, + inProgressInstallJobStartedDateTime: { + readOnly: true, + serializedName: "properties.inProgressInstallJobStartedDateTime", + type: { + name: "DateTime" + } + }, + updateTitles: { + readOnly: true, + serializedName: "properties.updateTitles", + type: { + name: "Sequence", + element: { + type: { + name: "String" + } + } + } + }, + totalUpdateSizeInBytes: { + readOnly: true, + serializedName: "properties.totalUpdateSizeInBytes", + type: { + name: "Number" + } + } + } + } +}; + +export const UploadCertificateRequest: msRest.CompositeMapper = { + serializedName: "UploadCertificateRequest", + type: { + name: "Composite", + className: "UploadCertificateRequest", + modelProperties: { + authenticationType: { + serializedName: "properties.authenticationType", + type: { + name: "String" + } + }, + certificate: { + required: true, + serializedName: "properties.certificate", + type: { + name: "String" + } + } + } + } +}; + +export const UploadCertificateResponse: msRest.CompositeMapper = { + serializedName: "UploadCertificateResponse", + type: { + name: "Composite", + className: "UploadCertificateResponse", + modelProperties: { + authType: { + serializedName: "authType", + type: { + name: "String" + } + }, + resourceId: { + readOnly: true, + serializedName: "resourceId", + type: { + name: "String" + } + }, + aadAuthority: { + readOnly: true, + serializedName: "aadAuthority", + type: { + name: "String" + } + }, + aadTenantId: { + readOnly: true, + serializedName: "aadTenantId", + type: { + name: "String" + } + }, + servicePrincipalClientId: { + readOnly: true, + serializedName: "servicePrincipalClientId", + type: { + name: "String" + } + }, + servicePrincipalObjectId: { + readOnly: true, + serializedName: "servicePrincipalObjectId", + type: { + name: "String" + } + }, + azureManagementEndpointAudience: { + readOnly: true, + serializedName: "azureManagementEndpointAudience", + type: { + name: "String" + } + }, + aadAudience: { + readOnly: true, + serializedName: "aadAudience", + type: { + name: "String" + } + } + } + } +}; + +export const User: msRest.CompositeMapper = { + serializedName: "User", + type: { + name: "Composite", + className: "User", + modelProperties: { + ...ARMBaseModel.type.modelProperties, + encryptedPassword: { + serializedName: "properties.encryptedPassword", + type: { + name: "Composite", + className: "AsymmetricEncryptedSecret" + } + }, + shareAccessRights: { + serializedName: "properties.shareAccessRights", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ShareAccessRight" + } + } + } + }, + userType: { + required: true, + serializedName: "properties.userType", + type: { + name: "String" + } + } + } + } +}; + +export const OperationsList: msRest.CompositeMapper = { + serializedName: "OperationsList", + type: { + name: "Composite", + className: "OperationsList", + modelProperties: { + value: { + required: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Operation" + } + } + } + }, + nextLink: { + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const DataBoxEdgeDeviceList: msRest.CompositeMapper = { + serializedName: "DataBoxEdgeDeviceList", + type: { + name: "Composite", + className: "DataBoxEdgeDeviceList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "DataBoxEdgeDevice" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const AlertList: msRest.CompositeMapper = { + serializedName: "AlertList", + type: { + name: "Composite", + className: "AlertList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Alert" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const BandwidthSchedulesList: msRest.CompositeMapper = { + serializedName: "BandwidthSchedulesList", + type: { + name: "Composite", + className: "BandwidthSchedulesList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "BandwidthSchedule" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const NodeList: msRest.CompositeMapper = { + serializedName: "NodeList", + type: { + name: "Composite", + className: "NodeList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Node" + } + } + } + } + } + } +}; + +export const OrderList: msRest.CompositeMapper = { + serializedName: "OrderList", + type: { + name: "Composite", + className: "OrderList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Order" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const RoleList: msRest.CompositeMapper = { + serializedName: "RoleList", + type: { + name: "Composite", + className: "RoleList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Role" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const ShareList: msRest.CompositeMapper = { + serializedName: "ShareList", + type: { + name: "Composite", + className: "ShareList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Share" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const StorageAccountCredentialList: msRest.CompositeMapper = { + serializedName: "StorageAccountCredentialList", + type: { + name: "Composite", + className: "StorageAccountCredentialList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StorageAccountCredential" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const StorageAccountList: msRest.CompositeMapper = { + serializedName: "StorageAccountList", + type: { + name: "Composite", + className: "StorageAccountList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "StorageAccount" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const ContainerList: msRest.CompositeMapper = { + serializedName: "ContainerList", + type: { + name: "Composite", + className: "ContainerList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Container" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const TriggerList: msRest.CompositeMapper = { + serializedName: "TriggerList", + type: { + name: "Composite", + className: "TriggerList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "Trigger" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const UserList: msRest.CompositeMapper = { + serializedName: "UserList", + type: { + name: "Composite", + className: "UserList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "User" + } + } + } + }, + nextLink: { + readOnly: true, + serializedName: "nextLink", + type: { + name: "String" + } + } + } + } +}; + +export const SkuInformationList: msRest.CompositeMapper = { + serializedName: "SkuInformationList", + type: { + name: "Composite", + className: "SkuInformationList", + modelProperties: { + value: { + readOnly: true, + serializedName: "", + type: { + name: "Sequence", + element: { + type: { + name: "Composite", + className: "ResourceTypeSku" + } + } + } + } + } + } +}; + +export const discriminators = { + 'Trigger.FileEvent' : FileEventTrigger, + 'Role.IOT' : IoTRole, + 'Trigger.PeriodicTimerEvent' : PeriodicTimerEventTrigger, + 'Role' : Role, + 'Trigger' : Trigger + +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/nodesMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/nodesMappers.ts new file mode 100644 index 000000000000..bec4ee3ff772 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/nodesMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + NodeList, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/operationsMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/operationsMappers.ts new file mode 100644 index 000000000000..2848e6d84029 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/operationsMappers.ts @@ -0,0 +1,18 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + CloudError, + MetricDimensionV1, + MetricSpecificationV1, + Operation, + OperationDisplay, + OperationsList, + ServiceSpecification +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/operationsStatusMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/operationsStatusMappers.ts new file mode 100644 index 000000000000..18867e1da432 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/operationsStatusMappers.ts @@ -0,0 +1,17 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + CloudError, + Job, + JobErrorDetails, + JobErrorItem, + UpdateDownloadProgress, + UpdateInstallProgress +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/ordersMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/ordersMappers.ts new file mode 100644 index 000000000000..3c61b28208ea --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/ordersMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderList, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/parameters.ts b/sdk/databoxedge/arm-databoxedge/src/models/parameters.ts new file mode 100644 index 000000000000..b39db8092cd1 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/parameters.ts @@ -0,0 +1,126 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; + +export const acceptLanguage: msRest.OperationParameter = { + parameterPath: "acceptLanguage", + mapper: { + serializedName: "accept-language", + defaultValue: 'en-US', + type: { + name: "String" + } + } +}; +export const apiVersion: msRest.OperationQueryParameter = { + parameterPath: "apiVersion", + mapper: { + required: true, + serializedName: "api-version", + type: { + name: "String" + } + } +}; +export const containerName: msRest.OperationURLParameter = { + parameterPath: "containerName", + mapper: { + required: true, + serializedName: "containerName", + type: { + name: "String" + } + } +}; +export const deviceName: msRest.OperationURLParameter = { + parameterPath: "deviceName", + mapper: { + required: true, + serializedName: "deviceName", + type: { + name: "String" + } + } +}; +export const expand: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "expand" + ], + mapper: { + serializedName: "$expand", + type: { + name: "String" + } + } +}; +export const filter: msRest.OperationQueryParameter = { + parameterPath: [ + "options", + "filter" + ], + mapper: { + serializedName: "$filter", + type: { + name: "String" + } + } +}; +export const name: msRest.OperationURLParameter = { + parameterPath: "name", + mapper: { + required: true, + serializedName: "name", + type: { + name: "String" + } + } +}; +export const nextPageLink: msRest.OperationURLParameter = { + parameterPath: "nextPageLink", + mapper: { + required: true, + serializedName: "nextLink", + type: { + name: "String" + } + }, + skipEncoding: true +}; +export const resourceGroupName: msRest.OperationURLParameter = { + parameterPath: "resourceGroupName", + mapper: { + required: true, + serializedName: "resourceGroupName", + type: { + name: "String" + } + } +}; +export const storageAccountName: msRest.OperationURLParameter = { + parameterPath: "storageAccountName", + mapper: { + required: true, + serializedName: "storageAccountName", + type: { + name: "String" + } + } +}; +export const subscriptionId: msRest.OperationURLParameter = { + parameterPath: "subscriptionId", + mapper: { + required: true, + serializedName: "subscriptionId", + type: { + name: "String" + } + } +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/rolesMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/rolesMappers.ts new file mode 100644 index 000000000000..7ab42593e57f --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/rolesMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleList, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/sharesMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/sharesMappers.ts new file mode 100644 index 000000000000..67f83a7fee93 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/sharesMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + ShareList, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/skusMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/skusMappers.ts new file mode 100644 index 000000000000..43ed0d98fec1 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/skusMappers.ts @@ -0,0 +1,18 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + CloudError, + ResourceTypeSku, + SkuCost, + SkuInformationList, + SkuLocationInfo, + SkuRestriction, + SkuRestrictionInfo +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/storageAccountCredentialsMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/storageAccountCredentialsMappers.ts new file mode 100644 index 000000000000..29454d1ded8a --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/storageAccountCredentialsMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + StorageAccountCredentialList, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/storageAccountsMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/storageAccountsMappers.ts new file mode 100644 index 000000000000..8453374abc84 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/storageAccountsMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + StorageAccountList, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/triggersMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/triggersMappers.ts new file mode 100644 index 000000000000..1c0f1eed0d3a --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/triggersMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + TriggerList, + UpdateSummary, + User, + UserAccessRight +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/models/usersMappers.ts b/sdk/databoxedge/arm-databoxedge/src/models/usersMappers.ts new file mode 100644 index 000000000000..5f4ba0bc8e3c --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/models/usersMappers.ts @@ -0,0 +1,57 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is regenerated. + */ + +export { + discriminators, + Address, + Alert, + AlertErrorDetails, + ARMBaseModel, + AsymmetricEncryptedSecret, + Authentication, + AzureContainerInfo, + BandwidthSchedule, + BaseResource, + ClientAccessRight, + CloudError, + ContactDetails, + Container, + DataBoxEdgeDevice, + DataBoxEdgeDeviceExtendedInfo, + FileEventTrigger, + FileSourceInfo, + IoTDeviceInfo, + IoTRole, + Ipv4Config, + Ipv6Config, + MountPointMap, + NetworkAdapter, + NetworkAdapterPosition, + NetworkSettings, + Node, + Order, + OrderStatus, + PeriodicTimerEventTrigger, + PeriodicTimerSourceInfo, + RefreshDetails, + Role, + RoleSinkInfo, + SecuritySettings, + Share, + ShareAccessRight, + Sku, + StorageAccount, + StorageAccountCredential, + SymmetricKey, + TrackingInfo, + Trigger, + UpdateSummary, + User, + UserAccessRight, + UserList +} from "../models/mappers"; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/alerts.ts b/sdk/databoxedge/arm-databoxedge/src/operations/alerts.ts new file mode 100644 index 000000000000..7e1eaa5f1f20 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/alerts.ts @@ -0,0 +1,200 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/alertsMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Alerts. */ +export class Alerts { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Alerts. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Gets all the alerts for a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * @summary Gets an alert by name. + * @param deviceName The device name. + * @param name The alert name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The alert name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The alert name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Gets all the alerts for a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/alerts", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AlertList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/alerts/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Alert + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.AlertList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/bandwidthSchedules.ts b/sdk/databoxedge/arm-databoxedge/src/operations/bandwidthSchedules.ts new file mode 100644 index 000000000000..57a41a58cb40 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/bandwidthSchedules.ts @@ -0,0 +1,330 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/bandwidthSchedulesMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a BandwidthSchedules. */ +export class BandwidthSchedules { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a BandwidthSchedules. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Gets all the bandwidth schedules for a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * Gets the properties of the specified bandwidth schedule. + * @param deviceName The device name. + * @param name The bandwidth schedule name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The bandwidth schedule name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The bandwidth schedule name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates or updates a bandwidth schedule. + * @param deviceName The device name. + * @param name The bandwidth schedule name which needs to be added/updated. + * @param parameters The bandwidth schedule to be added or updated. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, parameters: Models.BandwidthSchedule, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,parameters,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the specified bandwidth schedule. + * @param deviceName The device name. + * @param name The bandwidth schedule name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates or updates a bandwidth schedule. + * @param deviceName The device name. + * @param name The bandwidth schedule name which needs to be added/updated. + * @param parameters The bandwidth schedule to be added or updated. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, parameters: Models.BandwidthSchedule, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + parameters, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the specified bandwidth schedule. + * @param deviceName The device name. + * @param name The bandwidth schedule name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Gets all the bandwidth schedules for a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/bandwidthSchedules", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BandwidthSchedulesList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/bandwidthSchedules/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BandwidthSchedule + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/bandwidthSchedules/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "parameters", + mapper: { + ...Mappers.BandwidthSchedule, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.BandwidthSchedule + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/bandwidthSchedules/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.BandwidthSchedulesList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/containers.ts b/sdk/databoxedge/arm-databoxedge/src/operations/containers.ts new file mode 100644 index 000000000000..8767c4b61e32 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/containers.ts @@ -0,0 +1,411 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/containersMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Containers. */ +export class Containers { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Containers. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Lists all the containers of a storage Account in a Data Box Edge/Data Box Gateway + * device. + * @param deviceName The device name. + * @param storageAccountName The storage Account name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByStorageAccount(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param storageAccountName The storage Account name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByStorageAccount(deviceName: string, storageAccountName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param storageAccountName The storage Account name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByStorageAccount(deviceName: string, storageAccountName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByStorageAccount(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + storageAccountName, + resourceGroupName, + options + }, + listByStorageAccountOperationSpec, + callback) as Promise; + } + + /** + * @summary Gets a container by name. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container Name + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container Name + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container Name + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + storageAccountName, + containerName, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * @summary Creates a new container or updates an existing container on the device. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param container The container properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, storageAccountName: string, containerName: string, container: Models.Container, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,storageAccountName,containerName,container,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the container on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,storageAccountName,containerName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Refreshes the container metadata with the data from the cloud. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + refresh(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginRefresh(deviceName,storageAccountName,containerName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Creates a new container or updates an existing container on the device. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param container The container properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, storageAccountName: string, containerName: string, container: Models.Container, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + storageAccountName, + containerName, + container, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the container on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + storageAccountName, + containerName, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Refreshes the container metadata with the data from the cloud. + * @param deviceName The device name. + * @param storageAccountName The Storage Account Name + * @param containerName The container name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginRefresh(deviceName: string, storageAccountName: string, containerName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + storageAccountName, + containerName, + resourceGroupName, + options + }, + beginRefreshOperationSpec, + options); + } + + /** + * @summary Lists all the containers of a storage Account in a Data Box Edge/Data Box Gateway + * device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByStorageAccountNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByStorageAccountNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByStorageAccountNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByStorageAccountNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByStorageAccountNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByStorageAccountOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}/containers", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ContainerList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}/containers/{containerName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.containerName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Container + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}/containers/{containerName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.containerName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "container", + mapper: { + ...Mappers.Container, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Container + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}/containers/{containerName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.containerName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginRefreshOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}/containers/{containerName}/refresh", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.containerName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByStorageAccountNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ContainerList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/devices.ts b/sdk/databoxedge/arm-databoxedge/src/operations/devices.ts new file mode 100644 index 000000000000..0f6a3876940a --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/devices.ts @@ -0,0 +1,948 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/devicesMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Devices. */ +export class Devices { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Devices. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Gets all the Data Box Edge/Data Box Gateway devices in a subscription. + * @param [options] The optional parameters + * @returns Promise + */ + listBySubscription(options?: Models.DevicesListBySubscriptionOptionalParams): Promise; + /** + * @param callback The callback + */ + listBySubscription(callback: msRest.ServiceCallback): void; + /** + * @param options The optional parameters + * @param callback The callback + */ + listBySubscription(options: Models.DevicesListBySubscriptionOptionalParams, callback: msRest.ServiceCallback): void; + listBySubscription(options?: Models.DevicesListBySubscriptionOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + options + }, + listBySubscriptionOperationSpec, + callback) as Promise; + } + + /** + * Gets all the Data Box Edge/Data Box Gateway devices in a resource group. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByResourceGroup(resourceGroupName: string, options?: Models.DevicesListByResourceGroupOptionalParams): Promise; + /** + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByResourceGroup(resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByResourceGroup(resourceGroupName: string, options: Models.DevicesListByResourceGroupOptionalParams, callback: msRest.ServiceCallback): void; + listByResourceGroup(resourceGroupName: string, options?: Models.DevicesListByResourceGroupOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + resourceGroupName, + options + }, + listByResourceGroupOperationSpec, + callback) as Promise; + } + + /** + * Gets the properties of the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates or updates a Data Box Edge/Data Box Gateway resource. + * @param deviceName The device name. + * @param dataBoxEdgeDevice The resource object. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, dataBoxEdgeDevice: Models.DataBoxEdgeDevice, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,dataBoxEdgeDevice,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Modifies a Data Box Edge/Data Box Gateway resource. + * @param deviceName The device name. + * @param parameters The resource parameters. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + update(deviceName: string, parameters: Models.DataBoxEdgeDevicePatch, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param parameters The resource parameters. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + update(deviceName: string, parameters: Models.DataBoxEdgeDevicePatch, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param parameters The resource parameters. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + update(deviceName: string, parameters: Models.DataBoxEdgeDevicePatch, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + update(deviceName: string, parameters: Models.DataBoxEdgeDevicePatch, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + parameters, + resourceGroupName, + options + }, + updateOperationSpec, + callback) as Promise; + } + + /** + * @summary Downloads the updates on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + downloadUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDownloadUpdates(deviceName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Gets additional information for the specified Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + getExtendedInformation(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + getExtendedInformation(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + getExtendedInformation(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getExtendedInformation(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + getExtendedInformationOperationSpec, + callback) as Promise; + } + + /** + * @summary Installs the updates on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + installUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginInstallUpdates(deviceName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Gets the network settings of the specified Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + getNetworkSettings(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + getNetworkSettings(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + getNetworkSettings(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getNetworkSettings(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + getNetworkSettingsOperationSpec, + callback) as Promise; + } + + /** + * @summary Scans for updates on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + scanForUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginScanForUpdates(deviceName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Updates the security settings on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param securitySettings The security settings. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdateSecuritySettings(deviceName: string, securitySettings: Models.SecuritySettings, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdateSecuritySettings(deviceName,securitySettings,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Gets information about the availability of updates based on the last scan of the + * device. It also gets information about any ongoing download or install jobs on the device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + getUpdateSummary(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + getUpdateSummary(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + getUpdateSummary(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + getUpdateSummary(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + getUpdateSummaryOperationSpec, + callback) as Promise; + } + + /** + * Uploads registration certificate for the device. + * @param deviceName The device name. + * @param parameters The upload certificate request. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + uploadCertificate(deviceName: string, parameters: Models.UploadCertificateRequest, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param parameters The upload certificate request. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + uploadCertificate(deviceName: string, parameters: Models.UploadCertificateRequest, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param parameters The upload certificate request. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + uploadCertificate(deviceName: string, parameters: Models.UploadCertificateRequest, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + uploadCertificate(deviceName: string, parameters: Models.UploadCertificateRequest, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + parameters, + resourceGroupName, + options + }, + uploadCertificateOperationSpec, + callback) as Promise; + } + + /** + * Creates or updates a Data Box Edge/Data Box Gateway resource. + * @param deviceName The device name. + * @param dataBoxEdgeDevice The resource object. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, dataBoxEdgeDevice: Models.DataBoxEdgeDevice, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + dataBoxEdgeDevice, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Downloads the updates on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDownloadUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + resourceGroupName, + options + }, + beginDownloadUpdatesOperationSpec, + options); + } + + /** + * @summary Installs the updates on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginInstallUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + resourceGroupName, + options + }, + beginInstallUpdatesOperationSpec, + options); + } + + /** + * @summary Scans for updates on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginScanForUpdates(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + resourceGroupName, + options + }, + beginScanForUpdatesOperationSpec, + options); + } + + /** + * Updates the security settings on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param securitySettings The security settings. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdateSecuritySettings(deviceName: string, securitySettings: Models.SecuritySettings, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + securitySettings, + resourceGroupName, + options + }, + beginCreateOrUpdateSecuritySettingsOperationSpec, + options); + } + + /** + * Gets all the Data Box Edge/Data Box Gateway devices in a subscription. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listBySubscriptionNext(nextPageLink: string, options?: Models.DevicesListBySubscriptionNextOptionalParams): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listBySubscriptionNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listBySubscriptionNext(nextPageLink: string, options: Models.DevicesListBySubscriptionNextOptionalParams, callback: msRest.ServiceCallback): void; + listBySubscriptionNext(nextPageLink: string, options?: Models.DevicesListBySubscriptionNextOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listBySubscriptionNextOperationSpec, + callback) as Promise; + } + + /** + * Gets all the Data Box Edge/Data Box Gateway devices in a resource group. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByResourceGroupNext(nextPageLink: string, options?: Models.DevicesListByResourceGroupNextOptionalParams): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByResourceGroupNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByResourceGroupNext(nextPageLink: string, options: Models.DevicesListByResourceGroupNextOptionalParams, callback: msRest.ServiceCallback): void; + listByResourceGroupNext(nextPageLink: string, options?: Models.DevicesListByResourceGroupNextOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByResourceGroupNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listBySubscriptionOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices", + urlParameters: [ + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.expand + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDeviceList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByResourceGroupOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices", + urlParameters: [ + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.expand + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDeviceList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDevice + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const updateOperationSpec: msRest.OperationSpec = { + httpMethod: "PATCH", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "parameters", + mapper: { + ...Mappers.DataBoxEdgeDevicePatch, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDevice + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getExtendedInformationOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/getExtendedInformation", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDeviceExtendedInfo + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getNetworkSettingsOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/networkSettings/default", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.NetworkSettings + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getUpdateSummaryOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/updateSummary/default", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UpdateSummary + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const uploadCertificateOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/uploadCertificate", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "parameters", + mapper: { + ...Mappers.UploadCertificateRequest, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.UploadCertificateResponse + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "dataBoxEdgeDevice", + mapper: { + ...Mappers.DataBoxEdgeDevice, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDevice + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDownloadUpdatesOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/downloadUpdates", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginInstallUpdatesOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/installUpdates", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginScanForUpdatesOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/scanForUpdates", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateSecuritySettingsOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/securitySettings/default/update", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "securitySettings", + mapper: { + ...Mappers.SecuritySettings, + required: true + } + }, + responses: { + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listBySubscriptionNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.expand + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDeviceList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByResourceGroupNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.expand + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.DataBoxEdgeDeviceList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/index.ts b/sdk/databoxedge/arm-databoxedge/src/operations/index.ts new file mode 100644 index 000000000000..ff8cd85bb112 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/index.ts @@ -0,0 +1,25 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +export * from "./operations"; +export * from "./devices"; +export * from "./alerts"; +export * from "./bandwidthSchedules"; +export * from "./jobs"; +export * from "./nodes"; +export * from "./operationsStatus"; +export * from "./orders"; +export * from "./roles"; +export * from "./shares"; +export * from "./storageAccountCredentials"; +export * from "./storageAccounts"; +export * from "./containers"; +export * from "./triggers"; +export * from "./users"; +export * from "./skus"; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/jobs.ts b/sdk/databoxedge/arm-databoxedge/src/operations/jobs.ts new file mode 100644 index 000000000000..62743e305c3c --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/jobs.ts @@ -0,0 +1,91 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/jobsMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Jobs. */ +export class Jobs { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Jobs. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Gets the details of a specified job on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/jobs/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Job + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/nodes.ts b/sdk/databoxedge/arm-databoxedge/src/operations/nodes.ts new file mode 100644 index 000000000000..cb9c8479962e --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/nodes.ts @@ -0,0 +1,86 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/nodesMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Nodes. */ +export class Nodes { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Nodes. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Gets all the nodes currently configured under this Data Box Edge device + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/nodes", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.NodeList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/operations.ts b/sdk/databoxedge/arm-databoxedge/src/operations/operations.ts new file mode 100644 index 000000000000..2d93a6b1515b --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/operations.ts @@ -0,0 +1,125 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/operationsMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Operations. */ +export class Operations { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Operations. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary List all the supported operations. + * @param [options] The optional parameters + * @returns Promise + */ + list(options?: msRest.RequestOptionsBase): Promise; + /** + * @param callback The callback + */ + list(callback: msRest.ServiceCallback): void; + /** + * @param options The optional parameters + * @param callback The callback + */ + list(options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + list(options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + options + }, + listOperationSpec, + callback) as Promise; + } + + /** + * @summary List all the supported operations. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "providers/Microsoft.DataBoxEdge/operations", + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.OperationsList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.OperationsList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/operationsStatus.ts b/sdk/databoxedge/arm-databoxedge/src/operations/operationsStatus.ts new file mode 100644 index 000000000000..8ae899e87b5a --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/operationsStatus.ts @@ -0,0 +1,91 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/operationsStatusMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a OperationsStatus. */ +export class OperationsStatus { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a OperationsStatus. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Gets the details of a specified job on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The job name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/operationsStatus/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Job + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/orders.ts b/sdk/databoxedge/arm-databoxedge/src/operations/orders.ts new file mode 100644 index 000000000000..a8dbb013fe88 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/orders.ts @@ -0,0 +1,317 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/ordersMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Orders. */ +export class Orders { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Orders. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Lists all the orders related to a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * @summary Gets a specific order by name. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * @summary Creates or updates an order. + * @param deviceName The order details of a device. + * @param order The order to be created or updated. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, order: Models.Order, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,order,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * @summary Deletes the order related to the device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Creates or updates an order. + * @param deviceName The order details of a device. + * @param order The order to be created or updated. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, order: Models.Order, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + order, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * @summary Deletes the order related to the device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Lists all the orders related to a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/orders", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.OrderList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/orders/default", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Order + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/orders/default", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "order", + mapper: { + ...Mappers.Order, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Order + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/orders/default", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.OrderList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/roles.ts b/sdk/databoxedge/arm-databoxedge/src/operations/roles.ts new file mode 100644 index 000000000000..dc43262d677f --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/roles.ts @@ -0,0 +1,330 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/rolesMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Roles. */ +export class Roles { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Roles. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Lists all the roles configured in a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * Gets a specific role by name. + * @param deviceName The device name. + * @param name The role name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The role name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The role name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Create or update a role. + * @param deviceName The device name. + * @param name The role name. + * @param role The role properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, role: Models.RoleUnion, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,role,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the role on the device. + * @param deviceName The device name. + * @param name The role name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Create or update a role. + * @param deviceName The device name. + * @param name The role name. + * @param role The role properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, role: Models.RoleUnion, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + role, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the role on the device. + * @param deviceName The device name. + * @param name The role name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all the roles configured in a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/roles", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RoleList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/roles/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Role + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/roles/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "role", + mapper: { + ...Mappers.Role, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Role + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/roles/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.RoleList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/shares.ts b/sdk/databoxedge/arm-databoxedge/src/operations/shares.ts new file mode 100644 index 000000000000..cc0aaecde16f --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/shares.ts @@ -0,0 +1,388 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/sharesMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Shares. */ +export class Shares { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Shares. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Lists all the shares in a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * @summary Gets a share by name. + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * @summary Creates a new share or updates an existing share on the device. + * @param deviceName The device name. + * @param name The share name. + * @param share The share properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, share: Models.Share, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,share,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the share on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Refreshes the share metadata with the data from the cloud. + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + refresh(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginRefresh(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Creates a new share or updates an existing share on the device. + * @param deviceName The device name. + * @param name The share name. + * @param share The share properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, share: Models.Share, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + share, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the share on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Refreshes the share metadata with the data from the cloud. + * @param deviceName The device name. + * @param name The share name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginRefresh(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginRefreshOperationSpec, + options); + } + + /** + * @summary Lists all the shares in a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/shares", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ShareList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/shares/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Share + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/shares/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "share", + mapper: { + ...Mappers.Share, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Share + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/shares/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginRefreshOperationSpec: msRest.OperationSpec = { + httpMethod: "POST", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/shares/{name}/refresh", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.ShareList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/skus.ts b/sdk/databoxedge/arm-databoxedge/src/operations/skus.ts new file mode 100644 index 000000000000..f3037e4603ea --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/skus.ts @@ -0,0 +1,77 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as Models from "../models"; +import * as Mappers from "../models/skusMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Skus. */ +export class Skus { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Skus. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary List all the available Skus in the region and information related to them + * @param [options] The optional parameters + * @returns Promise + */ + list(options?: Models.SkusListOptionalParams): Promise; + /** + * @param callback The callback + */ + list(callback: msRest.ServiceCallback): void; + /** + * @param options The optional parameters + * @param callback The callback + */ + list(options: Models.SkusListOptionalParams, callback: msRest.ServiceCallback): void; + list(options?: Models.SkusListOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + options + }, + listOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/providers/Microsoft.DataBoxEdge/skus", + urlParameters: [ + Parameters.subscriptionId + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.filter + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.SkuInformationList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/storageAccountCredentials.ts b/sdk/databoxedge/arm-databoxedge/src/operations/storageAccountCredentials.ts new file mode 100644 index 000000000000..0e85c61945c5 --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/storageAccountCredentials.ts @@ -0,0 +1,330 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/storageAccountCredentialsMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a StorageAccountCredentials. */ +export class StorageAccountCredentials { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a StorageAccountCredentials. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Gets all the storage account credentials in a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * Gets the properties of the specified storage account credential. + * @param deviceName The device name. + * @param name The storage account credential name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The storage account credential name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The storage account credential name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates or updates the storage account credential. + * @param deviceName The device name. + * @param name The storage account credential name. + * @param storageAccountCredential The storage account credential. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, storageAccountCredential: Models.StorageAccountCredential, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,storageAccountCredential,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the storage account credential. + * @param deviceName The device name. + * @param name The storage account credential name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates or updates the storage account credential. + * @param deviceName The device name. + * @param name The storage account credential name. + * @param storageAccountCredential The storage account credential. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, storageAccountCredential: Models.StorageAccountCredential, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + storageAccountCredential, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the storage account credential. + * @param deviceName The device name. + * @param name The storage account credential name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Gets all the storage account credentials in a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccountCredentials", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccountCredentialList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccountCredentials/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccountCredential + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccountCredentials/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "storageAccountCredential", + mapper: { + ...Mappers.StorageAccountCredential, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.StorageAccountCredential + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccountCredentials/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccountCredentialList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/storageAccounts.ts b/sdk/databoxedge/arm-databoxedge/src/operations/storageAccounts.ts new file mode 100644 index 000000000000..fe54b67bdd6c --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/storageAccounts.ts @@ -0,0 +1,329 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/storageAccountsMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a StorageAccounts. */ +export class StorageAccounts { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a StorageAccounts. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * @summary Lists all the storage accounts in a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * @summary Gets a StorageAccount by name. + * @param deviceName The device name. + * @param storageAccountName The storage account name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param storageAccountName The storage account name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, storageAccountName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param storageAccountName The storage account name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, storageAccountName: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + storageAccountName, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * @summary Creates a new StorageAccount or updates an existing StorageAccount on the device. + * @param deviceName The device name. + * @param storageAccountName The StorageAccount name. + * @param storageAccount The StorageAccount properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, storageAccountName: string, storageAccount: Models.StorageAccount, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,storageAccountName,storageAccount,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the StorageAccount on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param storageAccountName The StorageAccount name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,storageAccountName,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * @summary Creates a new StorageAccount or updates an existing StorageAccount on the device. + * @param deviceName The device name. + * @param storageAccountName The StorageAccount name. + * @param storageAccount The StorageAccount properties. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, storageAccountName: string, storageAccount: Models.StorageAccount, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + storageAccountName, + storageAccount, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the StorageAccount on the Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param storageAccountName The StorageAccount name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, storageAccountName: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + storageAccountName, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * @summary Lists all the storage accounts in a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccountList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccount + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "storageAccount", + mapper: { + ...Mappers.StorageAccount, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.StorageAccount + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/storageAccounts/{storageAccountName}", + urlParameters: [ + Parameters.deviceName, + Parameters.storageAccountName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.StorageAccountList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/triggers.ts b/sdk/databoxedge/arm-databoxedge/src/operations/triggers.ts new file mode 100644 index 000000000000..c8e40cd00c2f --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/triggers.ts @@ -0,0 +1,332 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/triggersMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Triggers. */ +export class Triggers { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Triggers. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Lists all the triggers configured in the device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: Models.TriggersListByDataBoxEdgeDeviceOptionalParams): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: Models.TriggersListByDataBoxEdgeDeviceOptionalParams, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: Models.TriggersListByDataBoxEdgeDeviceOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * Get a specific trigger by name. + * @param deviceName The device name. + * @param name The trigger name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The trigger name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The trigger name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates or updates a trigger. + * @param deviceName Creates or updates a trigger + * @param name The trigger name. + * @param trigger The trigger. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, trigger: Models.TriggerUnion, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,trigger,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the trigger on the gateway device. + * @param deviceName The device name. + * @param name The trigger name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates or updates a trigger. + * @param deviceName Creates or updates a trigger + * @param name The trigger name. + * @param trigger The trigger. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, trigger: Models.TriggerUnion, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + trigger, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the trigger on the gateway device. + * @param deviceName The device name. + * @param name The trigger name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Lists all the triggers configured in the device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: Models.TriggersListByDataBoxEdgeDeviceNextOptionalParams): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: Models.TriggersListByDataBoxEdgeDeviceNextOptionalParams, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: Models.TriggersListByDataBoxEdgeDeviceNextOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/triggers", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.filter + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.TriggerList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/triggers/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.Trigger + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/triggers/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "trigger", + mapper: { + ...Mappers.Trigger, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.Trigger + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/triggers/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.filter + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.TriggerList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/src/operations/users.ts b/sdk/databoxedge/arm-databoxedge/src/operations/users.ts new file mode 100644 index 000000000000..56c768866c1c --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/src/operations/users.ts @@ -0,0 +1,334 @@ +/* + * Copyright (c) Microsoft Corporation. + * Licensed under the MIT License. + * + * Code generated by Microsoft (R) AutoRest Code Generator. + * Changes may cause incorrect behavior and will be lost if the code is + * regenerated. + */ + +import * as msRest from "@azure/ms-rest-js"; +import * as msRestAzure from "@azure/ms-rest-azure-js"; +import * as Models from "../models"; +import * as Mappers from "../models/usersMappers"; +import * as Parameters from "../models/parameters"; +import { DataBoxEdgeManagementClientContext } from "../dataBoxEdgeManagementClientContext"; + +/** Class representing a Users. */ +export class Users { + private readonly client: DataBoxEdgeManagementClientContext; + + /** + * Create a Users. + * @param {DataBoxEdgeManagementClientContext} client Reference to the service client. + */ + constructor(client: DataBoxEdgeManagementClientContext) { + this.client = client; + } + + /** + * Gets all the users registered on a Data Box Edge/Data Box Gateway device. + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: Models.UsersListByDataBoxEdgeDeviceOptionalParams): Promise; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options: Models.UsersListByDataBoxEdgeDeviceOptionalParams, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDevice(deviceName: string, resourceGroupName: string, options?: Models.UsersListByDataBoxEdgeDeviceOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + resourceGroupName, + options + }, + listByDataBoxEdgeDeviceOperationSpec, + callback) as Promise; + } + + /** + * Gets the properties of the specified user. + * @param deviceName The device name. + * @param name The user name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise; + /** + * @param deviceName The device name. + * @param name The user name. + * @param resourceGroupName The resource group name. + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, callback: msRest.ServiceCallback): void; + /** + * @param deviceName The device name. + * @param name The user name. + * @param resourceGroupName The resource group name. + * @param options The optional parameters + * @param callback The callback + */ + get(deviceName: string, name: string, resourceGroupName: string, options: msRest.RequestOptionsBase, callback: msRest.ServiceCallback): void; + get(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + deviceName, + name, + resourceGroupName, + options + }, + getOperationSpec, + callback) as Promise; + } + + /** + * Creates a new user or updates an existing user's information on a Data Box Edge/Data Box Gateway + * device. + * @param deviceName The device name. + * @param name The user name. + * @param user The user details. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + createOrUpdate(deviceName: string, name: string, user: Models.User, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginCreateOrUpdate(deviceName,name,user,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()) as Promise; + } + + /** + * Deletes the user on a databox edge/gateway device. + * @param deviceName The device name. + * @param name The user name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + deleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.beginDeleteMethod(deviceName,name,resourceGroupName,options) + .then(lroPoller => lroPoller.pollUntilFinished()); + } + + /** + * Creates a new user or updates an existing user's information on a Data Box Edge/Data Box Gateway + * device. + * @param deviceName The device name. + * @param name The user name. + * @param user The user details. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginCreateOrUpdate(deviceName: string, name: string, user: Models.User, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + user, + resourceGroupName, + options + }, + beginCreateOrUpdateOperationSpec, + options); + } + + /** + * Deletes the user on a databox edge/gateway device. + * @param deviceName The device name. + * @param name The user name. + * @param resourceGroupName The resource group name. + * @param [options] The optional parameters + * @returns Promise + */ + beginDeleteMethod(deviceName: string, name: string, resourceGroupName: string, options?: msRest.RequestOptionsBase): Promise { + return this.client.sendLRORequest( + { + deviceName, + name, + resourceGroupName, + options + }, + beginDeleteMethodOperationSpec, + options); + } + + /** + * Gets all the users registered on a Data Box Edge/Data Box Gateway device. + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param [options] The optional parameters + * @returns Promise + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: Models.UsersListByDataBoxEdgeDeviceNextOptionalParams): Promise; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, callback: msRest.ServiceCallback): void; + /** + * @param nextPageLink The NextLink from the previous successful call to List operation. + * @param options The optional parameters + * @param callback The callback + */ + listByDataBoxEdgeDeviceNext(nextPageLink: string, options: Models.UsersListByDataBoxEdgeDeviceNextOptionalParams, callback: msRest.ServiceCallback): void; + listByDataBoxEdgeDeviceNext(nextPageLink: string, options?: Models.UsersListByDataBoxEdgeDeviceNextOptionalParams | msRest.ServiceCallback, callback?: msRest.ServiceCallback): Promise { + return this.client.sendOperationRequest( + { + nextPageLink, + options + }, + listByDataBoxEdgeDeviceNextOperationSpec, + callback) as Promise; + } +} + +// Operation Specifications +const serializer = new msRest.Serializer(Mappers); +const listByDataBoxEdgeDeviceOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/users", + urlParameters: [ + Parameters.deviceName, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.filter + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UserList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const getOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/users/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.User + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginCreateOrUpdateOperationSpec: msRest.OperationSpec = { + httpMethod: "PUT", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/users/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + requestBody: { + parameterPath: "user", + mapper: { + ...Mappers.User, + required: true + } + }, + responses: { + 200: { + bodyMapper: Mappers.User + }, + 202: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const beginDeleteMethodOperationSpec: msRest.OperationSpec = { + httpMethod: "DELETE", + path: "subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataBoxEdge/dataBoxEdgeDevices/{deviceName}/users/{name}", + urlParameters: [ + Parameters.deviceName, + Parameters.name, + Parameters.subscriptionId, + Parameters.resourceGroupName + ], + queryParameters: [ + Parameters.apiVersion + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: {}, + 202: {}, + 204: {}, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; + +const listByDataBoxEdgeDeviceNextOperationSpec: msRest.OperationSpec = { + httpMethod: "GET", + baseUrl: "https://management.azure.com", + path: "{nextLink}", + urlParameters: [ + Parameters.nextPageLink + ], + queryParameters: [ + Parameters.apiVersion, + Parameters.filter + ], + headerParameters: [ + Parameters.acceptLanguage + ], + responses: { + 200: { + bodyMapper: Mappers.UserList + }, + default: { + bodyMapper: Mappers.CloudError + } + }, + serializer +}; diff --git a/sdk/databoxedge/arm-databoxedge/tsconfig.json b/sdk/databoxedge/arm-databoxedge/tsconfig.json new file mode 100644 index 000000000000..422b584abd5e --- /dev/null +++ b/sdk/databoxedge/arm-databoxedge/tsconfig.json @@ -0,0 +1,19 @@ +{ + "compilerOptions": { + "module": "es6", + "moduleResolution": "node", + "strict": true, + "target": "es5", + "sourceMap": true, + "declarationMap": true, + "esModuleInterop": true, + "allowSyntheticDefaultImports": true, + "forceConsistentCasingInFileNames": true, + "lib": ["es6", "dom"], + "declaration": true, + "outDir": "./esm", + "importHelpers": true + }, + "include": ["./src/**/*.ts"], + "exclude": ["node_modules"] +}