Skip to content

Commit fc01efa

Browse files
Updating the Databox package to the latest stable rest api spec version (Azure#27577)
Co-authored-by: Govardhana D K <[email protected]>
1 parent b10c0f8 commit fc01efa

File tree

63 files changed

+1543
-1058
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

63 files changed

+1543
-1058
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
// Copyright (c) Microsoft Corporation. All rights reserved.
2+
// Licensed under the Apache License, Version 2.0 (the ""License"");
3+
// you may not use this file except in compliance with the License.
4+
// You may obtain a copy of the License at
5+
// http://www.apache.org/licenses/LICENSE-2.0
6+
// Unless required by applicable law or agreed to in writing, software
7+
// distributed under the License is distributed on an ""AS IS"" BASIS,
8+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
9+
// See the License for the specific language governing permissions and
10+
// limitations under the License.
11+
// Code generated by Microsoft (R) AutoRest Code Generator.Changes may cause incorrect behavior and will be lost if the code
12+
// is regenerated.
13+
14+
using System;
15+
using System.Reflection;
16+
using System.Runtime.CompilerServices;
17+
using System.Runtime.InteropServices;
18+
19+
[assembly: System.Reflection.AssemblyCompanyAttribute("Microsoft")]
20+
[assembly: System.Reflection.AssemblyCopyrightAttribute("Copyright © Microsoft")]
21+
[assembly: System.Reflection.AssemblyProductAttribute("Microsoft Azure PowerShell")]
22+
[assembly: System.Reflection.AssemblyTitleAttribute("Microsoft Azure PowerShell - DataBox")]
23+
[assembly: System.Reflection.AssemblyFileVersionAttribute("0.3.3")]
24+
[assembly: System.Reflection.AssemblyVersionAttribute("0.3.3")]
25+
[assembly: System.Runtime.InteropServices.ComVisibleAttribute(false)]
26+
[assembly: System.CLSCompliantAttribute(false)]
27+

src/DataBox/DataBox.Autorest/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ require:
3333
- $(this-folder)/../../readme.azure.noprofile.md
3434
input-file:
3535
# You need to specify your swagger files here.
36-
- $(repo)/specification/databox/resource-manager/Microsoft.DataBox/stable/2022-12-01/databox.json
36+
- "https://raw.githubusercontent.com/Azure/azure-rest-api-specs/cb5ef7fc4cb443bd5f6b21d02cbce41051beb6ae/specification/databox/resource-manager/Microsoft.DataBox/stable/2025-02-01/databox.json"
3737
# If the swagger has not been put in the repo, you may uncomment the following line and refer to it locally
3838
# - (this-folder)/relative-path-to-your-swagger
3939

@@ -148,7 +148,7 @@ directive:
148148

149149
- from: source-file-csharp
150150
where: $
151-
transform: $ = $.replace('internal Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20210301.IJobSecrets', 'public Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20210301.IJobSecrets');
151+
transform: $ = $.replace('internal Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IJobSecrets', 'public Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IJobSecrets');
152152

153153
- model-cmdlet:
154154
- DataBoxDiskJobDetails

src/DataBox/DataBox.Autorest/UX/Microsoft.DataBox/jobs.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"resourceType": "jobs",
3-
"apiVersion": "2022-12-01",
3+
"apiVersion": "2025-02-01",
44
"learnMore": {
55
"url": "https://learn.microsoft.com/powershell/module/az.databox"
66
},

src/DataBox/DataBox.Autorest/custom/AzDataBoxCustomerDiskJobDetailsObject.ps1

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -21,47 +21,47 @@ Create an in-memory object for DataBoxCustomerDiskJobDetails.
2121
Create an in-memory object for DataBoxCustomerDiskJobDetails.
2222
2323
.Outputs
24-
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxCustomerDiskJobDetails
24+
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxCustomerDiskJobDetails
2525
.Link
2626
https://learn.microsoft.com/powershell/module/Az.DataBox/new-AzDataBoxCustomerDiskJobDetailsObject
2727
#>
2828
function New-AzDataBoxCustomerDiskJobDetailsObject {
29-
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxCustomerDiskJobDetails')]
29+
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxCustomerDiskJobDetails')]
3030
[CmdletBinding(PositionalBinding=$false)]
3131
Param(
3232

3333
[Parameter(HelpMessage="Contains the map of disk serial number to the disk details for import jobs.")]
34-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataBoxCustomerDiskJobDetailsImportDiskDetailsCollection]
34+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataBoxCustomerDiskJobDetailsImportDiskDetailsCollection]
3535
$ImportDiskDetailsCollection,
3636
[Parameter(HelpMessage="Contains the map of disk serial number to the disk details for export jobs.")]
37-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataBoxCustomerDiskJobDetailsExportDiskDetailsCollection]
37+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataBoxCustomerDiskJobDetailsExportDiskDetailsCollection]
3838
$ExportDiskDetailsCollection,
3939
[Parameter(HelpMessage="Carrier Account Number of customer for customer disk.")]
4040
[string]
4141
$ReturnToCustomerPackageDetailCarrierAccountNumber,
4242
[Parameter(Mandatory, HelpMessage="Contact details for notification and shipping.")]
43-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IContactDetails]
43+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IContactDetails]
4444
$ContactDetail,
4545
[Parameter(HelpMessage="Details of the data to be exported from azure.")]
46-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataExportDetails[]]
46+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataExportDetails[]]
4747
$DataExportDetail,
4848
[Parameter(HelpMessage="Details of the data to be imported into azure.")]
49-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataImportDetails[]]
49+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataImportDetails[]]
5050
$DataImportDetail,
5151
[Parameter(HelpMessage="The expected size of the data, which needs to be transferred in this job, in terabytes.")]
5252
[int]
5353
$ExpectedDataSizeInTeraByte,
5454
[Parameter(HelpMessage="Details about which key encryption type is being used.")]
55-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IKeyEncryptionKey]
55+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IKeyEncryptionKey]
5656
$KeyEncryptionKey,
5757
[Parameter(HelpMessage="Preferences for the order.")]
58-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IPreferences]
58+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IPreferences]
5959
$Preference,
6060
[Parameter(HelpMessage="Optional Reverse Shipping details for order.")]
61-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IReverseShippingDetails]
61+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IReverseShippingDetails]
6262
$ReverseShippingDetail,
6363
[Parameter(HelpMessage="Shipping address of the customer.")]
64-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IShippingAddress]
64+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IShippingAddress]
6565
$ShippingAddress,
6666
[Parameter(Mandatory, HelpMessage="Indicates the type of job details.")]
6767
[ArgumentCompleter([Microsoft.Azure.PowerShell.Cmdlets.DataBox.Support.ClassDiscriminator])]
@@ -70,7 +70,7 @@ function New-AzDataBoxCustomerDiskJobDetailsObject {
7070
)
7171

7272
process {
73-
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxCustomerDiskJobDetails]::New()
73+
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxCustomerDiskJobDetails]::New()
7474

7575
if ($PSBoundParameters.ContainsKey('ImportDiskDetailsCollection')) {
7676
$Object.ImportDiskDetailsCollection = $ImportDiskDetailsCollection

src/DataBox/DataBox.Autorest/custom/autogen-model-cmdlets/New-AzDataBoxContactDetailsObject.ps1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ Create an in-memory object for ContactDetails.
2121
Create an in-memory object for ContactDetails.
2222
2323
.Outputs
24-
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.ContactDetails
24+
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.ContactDetails
2525
.Link
2626
https://learn.microsoft.com/powershell/module/Az.DataBox/new-AzDataBoxContactDetailsObject
2727
#>
2828
function New-AzDataBoxContactDetailsObject {
29-
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.ContactDetails')]
29+
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.ContactDetails')]
3030
[CmdletBinding(PositionalBinding=$false)]
3131
Param(
3232

@@ -40,7 +40,7 @@ function New-AzDataBoxContactDetailsObject {
4040
[string]
4141
$Mobile,
4242
[Parameter(HelpMessage="Notification preference for a job stage.")]
43-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.INotificationPreference[]]
43+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.INotificationPreference[]]
4444
$NotificationPreference,
4545
[Parameter(Mandatory, HelpMessage="Phone number of the contact person.")]
4646
[string]
@@ -51,7 +51,7 @@ function New-AzDataBoxContactDetailsObject {
5151
)
5252

5353
process {
54-
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.ContactDetails]::New()
54+
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.ContactDetails]::New()
5555

5656
if ($PSBoundParameters.ContainsKey('ContactName')) {
5757
$Object.ContactName = $ContactName

src/DataBox/DataBox.Autorest/custom/autogen-model-cmdlets/New-AzDataBoxDiskJobDetailsObject.ps1

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -21,44 +21,44 @@ Create an in-memory object for DataBoxDiskJobDetails.
2121
Create an in-memory object for DataBoxDiskJobDetails.
2222
2323
.Outputs
24-
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxDiskJobDetails
24+
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxDiskJobDetails
2525
.Link
2626
https://learn.microsoft.com/powershell/module/Az.DataBox/new-AzDataBoxDiskJobDetailsObject
2727
#>
2828
function New-AzDataBoxDiskJobDetailsObject {
29-
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxDiskJobDetails')]
29+
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxDiskJobDetails')]
3030
[CmdletBinding(PositionalBinding=$false)]
3131
Param(
3232

3333
[Parameter(HelpMessage="User entered passkey for DataBox Disk job.")]
3434
[string]
3535
$Passkey,
3636
[Parameter(HelpMessage="User preference on what size disks are needed for the job. The map is from the disk size in TB to the count. Eg. {2,5} means 5 disks of 2 TB size. Key is string but will be checked against an int.")]
37-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataBoxDiskJobDetailsPreferredDisks]
37+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataBoxDiskJobDetailsPreferredDisks]
3838
$PreferredDisk,
3939
[Parameter(Mandatory, HelpMessage="Contact details for notification and shipping.")]
40-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IContactDetails]
40+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IContactDetails]
4141
$ContactDetail,
4242
[Parameter(HelpMessage="Details of the data to be exported from azure.")]
43-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataExportDetails[]]
43+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataExportDetails[]]
4444
$DataExportDetail,
4545
[Parameter(HelpMessage="Details of the data to be imported into azure.")]
46-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataImportDetails[]]
46+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataImportDetails[]]
4747
$DataImportDetail,
4848
[Parameter(HelpMessage="The expected size of the data, which needs to be transferred in this job, in terabytes.")]
4949
[int]
5050
$ExpectedDataSizeInTeraByte,
5151
[Parameter(HelpMessage="Details about which key encryption type is being used.")]
52-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IKeyEncryptionKey]
52+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IKeyEncryptionKey]
5353
$KeyEncryptionKey,
5454
[Parameter(HelpMessage="Preferences for the order.")]
55-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IPreferences]
55+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IPreferences]
5656
$Preference,
5757
[Parameter(HelpMessage="Optional Reverse Shipping details for order.")]
58-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IReverseShippingDetails]
58+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IReverseShippingDetails]
5959
$ReverseShippingDetail,
6060
[Parameter(HelpMessage="Shipping address of the customer.")]
61-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IShippingAddress]
61+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IShippingAddress]
6262
$ShippingAddress,
6363
[Parameter(Mandatory, HelpMessage="Indicates the type of job details.")]
6464
[ArgumentCompleter([Microsoft.Azure.PowerShell.Cmdlets.DataBox.Support.ClassDiscriminator])]
@@ -67,7 +67,7 @@ function New-AzDataBoxDiskJobDetailsObject {
6767
)
6868

6969
process {
70-
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxDiskJobDetails]::New()
70+
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxDiskJobDetails]::New()
7171

7272
if ($PSBoundParameters.ContainsKey('Passkey')) {
7373
$Object.Passkey = $Passkey

src/DataBox/DataBox.Autorest/custom/autogen-model-cmdlets/New-AzDataBoxHeavyJobDetailsObject.ps1

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,41 +21,41 @@ Create an in-memory object for DataBoxHeavyJobDetails.
2121
Create an in-memory object for DataBoxHeavyJobDetails.
2222
2323
.Outputs
24-
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxHeavyJobDetails
24+
Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxHeavyJobDetails
2525
.Link
2626
https://learn.microsoft.com/powershell/module/Az.DataBox/new-AzDataBoxHeavyJobDetailsObject
2727
#>
2828
function New-AzDataBoxHeavyJobDetailsObject {
29-
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxHeavyJobDetails')]
29+
[OutputType('Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxHeavyJobDetails')]
3030
[CmdletBinding(PositionalBinding=$false)]
3131
Param(
3232

3333
[Parameter(HelpMessage="Set Device password for unlocking Databox Heavy. Should not be passed for TransferType:ExportFromAzure jobs. If this is not passed, the service will generate password itself. This will not be returned in Get Call. Password Requirements : Password must be minimum of 12 and maximum of 64 characters. Password must have at least one uppercase alphabet, one number and one special character. Password cannot have the following characters : IilLoO0 Password can have only alphabets, numbers and these characters : @#\-$%^!+=;:_()]+.")]
3434
[string]
3535
$DevicePassword,
3636
[Parameter(Mandatory, HelpMessage="Contact details for notification and shipping.")]
37-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IContactDetails]
37+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IContactDetails]
3838
$ContactDetail,
3939
[Parameter(HelpMessage="Details of the data to be exported from azure.")]
40-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataExportDetails[]]
40+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataExportDetails[]]
4141
$DataExportDetail,
4242
[Parameter(HelpMessage="Details of the data to be imported into azure.")]
43-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IDataImportDetails[]]
43+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IDataImportDetails[]]
4444
$DataImportDetail,
4545
[Parameter(HelpMessage="The expected size of the data, which needs to be transferred in this job, in terabytes.")]
4646
[int]
4747
$ExpectedDataSizeInTeraByte,
4848
[Parameter(HelpMessage="Details about which key encryption type is being used.")]
49-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IKeyEncryptionKey]
49+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IKeyEncryptionKey]
5050
$KeyEncryptionKey,
5151
[Parameter(HelpMessage="Preferences for the order.")]
52-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IPreferences]
52+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IPreferences]
5353
$Preference,
5454
[Parameter(HelpMessage="Optional Reverse Shipping details for order.")]
55-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IReverseShippingDetails]
55+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IReverseShippingDetails]
5656
$ReverseShippingDetail,
5757
[Parameter(HelpMessage="Shipping address of the customer.")]
58-
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.IShippingAddress]
58+
[Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.IShippingAddress]
5959
$ShippingAddress,
6060
[Parameter(Mandatory, HelpMessage="Indicates the type of job details.")]
6161
[ArgumentCompleter([Microsoft.Azure.PowerShell.Cmdlets.DataBox.Support.ClassDiscriminator])]
@@ -64,7 +64,7 @@ function New-AzDataBoxHeavyJobDetailsObject {
6464
)
6565

6666
process {
67-
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20221201.DataBoxHeavyJobDetails]::New()
67+
$Object = [Microsoft.Azure.PowerShell.Cmdlets.DataBox.Models.Api20250201.DataBoxHeavyJobDetails]::New()
6868

6969
if ($PSBoundParameters.ContainsKey('DevicePassword')) {
7070
$Object.DevicePassword = $DevicePassword

0 commit comments

Comments
 (0)