Azure / Azure/azure-powershell

Stop-AzDevCenterUserDevBox puts the dev box into hibernate, without the -Hibernate

Open
#28,756 2 comments 0 reactions 0 assignees View on GitHub
bug Dev Center Service Attention
Dominant language
C#
Stars
4.8k
Forks
4.3k
Avg merge
3d 14h
Merged PRs (30d)
54

Description

### Description

The Stop-AzDevCenterUserDevBox cmdlet put the Dev Box into hibernation mode without having the -Hibernate. It should stop the Dev Box, even when the Dev Box pool is hibernate enabled.
Az 14.5.0
Az.DevCenter 2.0.2

### Issue script & Debug output

```PowerShell
# PowerShell script to stop and delete an Azure Dev Box
# Requires Az.DevCenter PowerShell module

param(
[Parameter(Mandatory=$false)]
[string]$ResourceGroupName = "",

[Parameter(Mandatory=$false)]
[string]$DevBoxName = "",

[Parameter(Mandatory=$false)]
[string]$ProjectName = "",

[Parameter(Mandatory=$false)]
[string]$UserId = "",

[Parameter(Mandatory=$false)]
[string]$DevCenterEndpoint = ""
)

# Import required modules
Import-Module Az.Accounts -Force
Import-Module Az.DevCenter -Force

# Check if logged into Azure
$context = Get-AzContext
if (-not $context) {
Write-Host "Not logged into Azure. Please run Connect-AzAccount first." -ForegroundColor Red
exit 1
}

Write-Host "Current Azure context: $($context.Account.Id)" -ForegroundColor Green

try {
# Stop the Dev Box
Write-Host "Stopping Dev Box '$DevBoxName'..." -ForegroundColor Yellow
Stop-AzDevCenterUserDevBox -Endpoint $DevCenterEndpoint -ProjectName $ProjectName -UserId $UserId -DevBoxName $DevBoxName

# Wait for the Dev Box to stop
do {
Start-Sleep -Seconds 30
$devBoxStatus = Get-AzDevCenterUserDevBox -Endpoint $DevCenterEndpoint -ProjectName $ProjectName -UserId $UserId -DevBoxName $DevBoxName
Write-Host "Current status: $($devBoxStatus.PowerState)" -ForegroundColor Cyan
} while (!($devBoxStatus.PowerState -eq "Hibernated"))

Write-Host "Dev Box stopped successfully." -ForegroundColor Green

}
catch {
Write-Error "An error occurred: $($_.Exception.Message)"
exit 1
}

# Example usage:
# .\devboxstop.ps1 -ResourceGroupName "myResourceGroup" -DevBoxName "myDevBox" -ProjectName "myProject" -DevCenterEndpoint "https://your-custom-endpoint.devcenter.azure.com/"

OUTPUT:
PS C:\Experiments\DevBoxDelete> $DebugPreference='Continue'
PS C:\Experiments\DevBoxDelete> .\devboxstop.ps1 -debug
DEBUG: Initializing ConditionalAssemblyContext. PSEdition is [Core]. PSVersion is [7.5.4].
DEBUG: Initializing ConditionalAssemblyProvider. AssemblyRootPath is [C:\Users\\Documents\PowerShell\Modules\Az.Accounts\5.3.0\StartupScripts\..\lib].
DEBUG: Registering Az shared AssemblyLoadContext.
DEBUG: AssemblyLoadContext registered.
DEBUG: Initializing PSStyle.
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 12:21:08 PM - GetAzureRMContextCommand begin processing with ParameterSet 'GetSingleContext'.
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisplayBreakingChangeWarning], Module = [Az.Accounts], Cmdlet = [Get-AzContext]. Returning default value [True].
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisplayRegionIdentified], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [CheckForUpgrade], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 12:21:08 PM - No authentication telemetry is found for the current cmdlet with Id 35b94110-593a-42e6-a18a-7639820fa8b4.
DEBUG: AzureQoSEvent: Module: Az.Accounts:5.3.0; CommandName: Get-AzContext; PSVersion: 7.5.4; IsSuccess: True; Duration: 00:00:00.0021510; SanitizeDuration: 00:00:00.0000593
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [EnableDataCollection], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: 12:21:08 PM - GetAzureRMContextCommand end processing.
Current Azure context: @foxtrot.onmicrosoft.com
Stopping Dev Box 'testa'...
DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].
WARNING: Upcoming breaking changes in the cmdlet 'Stop-AzDevCenterUserDevBox' :
- The output type is changing from the existing type :'OperationStatus' to the new type :'OperationStatus'
- The following properties in the output type are being deprecated : 'Property'
- The following properties are being added to the output type : 'Property'
- This change will take effect on '11/18/2025'- The change is expected to take effect from Az version : '15.0.0'
- The change is expected to take effect from version : '3.0.0'
Note : Go to https://aka.ms/azps-changewarnings for steps to suppress this breaking change warning, and other information on breaking changes in Azure PowerShell.
DEBUG: [CmdletBeginProcessing]: Starting command
DEBUG: CmdletBeginProcessing:
DEBUG: CmdletProcessRecordStart:
DEBUG: CmdletGetPipeline:
DEBUG: CmdletBeforeAPICall:
DEBUG: URLCreated: /projects/TestAManualDC/users//devboxes/testa:stop?api-version=2024-05-01-preview
DEBUG: RequestCreated: /projects/TestAManualDC/users//devboxes/testa:stop?api-version=2024-05-01-preview
DEBUG: HeaderParametersAdded:
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
POST

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/TestAManualDC/users//devboxes/testa:stop?api-version=2024-05-01-preview

Headers:
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
CommandName : Az.DevCenterdata.internal\Stop-AzDevCenterUserDevBox
FullCommandName : Stop-AzDevCenterUserDevBox_Stop
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: 12:21:08 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: BeforeCall:
DEBUG: 12:21:08 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
Accepted

Headers:
Date : Mon, 27 Oct 2025 19:21:07 GMT
Connection : keep-alive
Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
x-ms-correlation-request-id : f1038224-5618-443e-804a-704c00062fe2
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 999
X-Rate-Limit-Reset : 2025-10-27T19:22:06.9081575Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"id": "/projects/TestAManualDC/operationStatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"name": "bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"status": "NotStarted",
"resourceId": "/projects/testamanualdc/users//devboxes/testa"
}

DEBUG: ResponseCreated:
DEBUG: DelayBeforePolling: Delaying 30 seconds before polling.
DEBUG: 12:21:39 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: 12:21:39 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true

Headers:
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
CommandName : Az.DevCenterdata.internal\Stop-AzDevCenterUserDevBox
FullCommandName : Stop-AzDevCenterUserDevBox_Stop
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
Accepted

Headers:
Date : Mon, 27 Oct 2025 19:21:37 GMT
Connection : keep-alive
Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 6ed34c29-8b04-42b7-bcf0-22b9a143ebe6
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 990
X-Rate-Limit-Reset : 2025-10-27T19:22:06.9081575Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"id": "/projects/testamanualdc/operationStatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"name": "bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"status": "Running",
"startTime": "2025-10-27T12:21:06.9221211-07:00"
}

DEBUG: Polling:
DEBUG: DelayBeforePolling: Delaying 30 seconds before polling.
DEBUG: 12:22:09 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: 12:22:09 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true

Headers:
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
CommandName : Az.DevCenterdata.internal\Stop-AzDevCenterUserDevBox
FullCommandName : Stop-AzDevCenterUserDevBox_Stop
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
Accepted

Headers:
Date : Mon, 27 Oct 2025 19:22:07 GMT
Connection : keep-alive
Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 6bcbf902-e582-4d3f-bc93-4ed39599604d
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 982
X-Rate-Limit-Reset : 2025-10-27T19:22:21.2680226Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"id": "/projects/testamanualdc/operationStatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"name": "bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"status": "Running",
"startTime": "2025-10-27T12:21:06.9221211-07:00"
}

DEBUG: Polling:
DEBUG: DelayBeforePolling: Delaying 30 seconds before polling.
DEBUG: 12:22:39 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: 12:22:39 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true

Headers:
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
CommandName : Az.DevCenterdata.internal\Stop-AzDevCenterUserDevBox
FullCommandName : Stop-AzDevCenterUserDevBox_Stop
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
OK

Headers:
Date : Mon, 27 Oct 2025 19:22:37 GMT
Connection : keep-alive
Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 78b66385-96a1-4211-b117-ef7680450932
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 998
X-Rate-Limit-Reset : 2025-10-27T19:23:22.9347949Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"id": "/projects/testamanualdc/operationStatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"name": "bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"status": "Succeeded",
"startTime": "2025-10-27T12:21:06.9221211-07:00",
"endTime": "2025-10-27T12:22:14.7671169-07:00"
}

DEBUG: Polling:
DEBUG: 12:22:39 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: 12:22:39 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true

Headers:
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
CommandName : Az.DevCenterdata.internal\Stop-AzDevCenterUserDevBox
FullCommandName : Stop-AzDevCenterUserDevBox_Stop
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
OK

Headers:
Date : Mon, 27 Oct 2025 19:22:37 GMT
Connection : keep-alive
Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 9cdfeaf7-1e33-400b-b0b4-316c5aafe552
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatLocation : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 9cdfeaf7-1e33-400b-b0b4-316c5aafe552
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview&monitor=true
Retry-After : 30
x-ms-correlation-request-id : 9cdfeaf7-1e33-400b-b0b4-316c5aafe552
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatRetry-After : 30
x-ms-correlation-request-id : 9cdfeaf7-1e33-400b-b0b4-316c5aafe552
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatx-ms-correlation-request-id : 9cdfeaf7-1e33-400b-b0b4-316c5aafe552
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
x-ms-client-request-id : e2f571f4-5155-42f7-a703-5826bd75234b
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 999
Operation-Location : https://.centralus.devcenter.azure.com/projects/testamanualdc/operationstatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 999
X-Rate-Limit-Reset : 2025-10-27T19:23:37.7681419Z
uses/bc1434a3-8ef5-4b78-b599-af2c2f1be142?api-version=2024-05-01-preview
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 999
X-Rate-Limit-Reset : 2025-10-27T19:23:37.7681419Z
X-Rate-Limit-Remaining : 999
X-Rate-Limit-Reset : 2025-10-27T19:23:37.7681419Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
X-Rate-Limit-Reset : 2025-10-27T19:23:37.7681419Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"id": "/projects/testamanualdc/operationStatuses/bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"name": "bc1434a3-8ef5-4b78-b599-af2c2f1be142",
"status": "Succeeded",
"startTime": "2025-10-27T12:21:06.9221211-07:00",
"endTime": "2025-10-27T12:22:14.7671169-07:00"
}

DEBUG: Polling:
DEBUG: BeforeResponseDispatch:
DEBUG: 12:22:39 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].

DEBUG: Finally:
DEBUG: CmdletAfterAPICall:
DEBUG: [CmdletProcessRecordAsyncEnd]: Finish HTTP process
DEBUG: CmdletProcessRecordAsyncEnd:
DEBUG: CmdletProcessRecordEnd:
DEBUG: 12:22:39 PM - [ConfigManager] Got nothing from [EnableDataCollection], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: AzureQoSEvent: Module: Az.DevCenter:2.0.2; CommandName: Stop-AzDevCenterUserDevBox; PSVersion: 7.5.4; IsSuccess: True; Duration: 00:01:31.4474134; SanitizeDuration: 00:00:00.0000423
DEBUG: 12:23:09 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: [CmdletBeginProcessing]: Starting command
DEBUG: CmdletBeginProcessing:
DEBUG: CmdletProcessRecordStart:
DEBUG: CmdletGetPipeline:
DEBUG: CmdletBeforeAPICall:
DEBUG: URLCreated: /projects/TestAManualDC/users//devboxes/testa?api-version=2024-05-01-preview
DEBUG: RequestCreated: /projects/TestAManualDC/users//devboxes/testa?api-version=2024-05-01-preview
DEBUG: HeaderParametersAdded:
DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://.centralus.devcenter.azure.com/projects/TestAManualDC/users//devboxes/testa?api-version=2024-05-01-preview

Headers:
x-ms-client-request-id : 0472e219-5945-4eb3-a2bb-c831b1da58f4
CommandName : Az.DevCenterdata.internal\Get-AzDevCenterUserDevBox
FullCommandName : Get-AzDevCenterUserDevBox_Get
ParameterSetName : __AllParameterSets
User-Agent : AzurePowershell/v14.5.0,PSVersion/v7.5.4,Az.DevCenterdata/2.0.1

Body:

DEBUG: 12:23:09 PM - [ConfigManager] Got nothing from [DisableInstanceDiscovery], Module = [], Cmdlet = []. Returning default value [False].
DEBUG: BeforeCall:
DEBUG: 12:23:09 PM - [ConfigManager] Got [False] from [EnableLoginByWam], Module = [], Cmdlet = [].
DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
OK

Headers:
Date : Mon, 27 Oct 2025 19:23:08 GMT
Connection : keep-alive
x-ms-correlation-request-id : 1a8ef50b-f4ef-44bb-b91b-4da848501e01
x-ms-client-request-id : 0472e219-5945-4eb3-a2bb-c831b1da58f4
X-Rate-Limit-Limit : 1m
X-Rate-Limit-Remaining : 999
X-Rate-Limit-Reset : 2025-10-27T19:24:08.0570730Z
Strict-Transport-Security : max-age=31536000; includeSubDomains
Access-Control-Allow-Origin : *
Access-Control-Max-Age : 86400
Access-Control-Expose-Headers : Location,Operation-Location,x-ms-correlation-request-id,x-ms-client-request-id

Body:
{
"uri": "https://.centralus.devcenter.azure.com/projects/testamanualdc/users//devboxes/testa",
"name": "testa",
"projectName": "TestAManualDC",
"poolName": "hibernatepool",
"hibernateSupport": "Enabled",
"provisioningState": "Succeeded",
"actionState": "Stopped",
"powerState": "Hibernated",
"uniqueId": "1b181f15-f1fa-47d5-9bbc-184a31d55ec1",
"location": "westus3",
"osType": "Windows",
"user": "",
"hardwareProfile": {
"vCPUs": 8,
"skuName": "general_i_8c32gb256ssd_v2",
"memoryGB": 32
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
"uniqueId": "1b181f15-f1fa-47d5-9bbc-184a31d55ec1",
"location": "westus3",
"osType": "Windows",
"user": "",
"hardwareProfile": {
"vCPUs": 8,
"skuName": "general_i_8c32gb256ssd_v2",
"memoryGB": 32
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
"location": "westus3",
"osType": "Windows",
"user": "",
"hardwareProfile": {
"vCPUs": 8,
"skuName": "general_i_8c32gb256ssd_v2",
"memoryGB": 32
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
"hardwareProfile": {
"vCPUs": 8,
"skuName": "general_i_8c32gb256ssd_v2",
"memoryGB": 32
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
"memoryGB": 32
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
},
"storageProfile": {
"osDisk": {
"diskSizeGB": 256
}
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
},
"imageReference": {
"name": "microsoftvisualstudio_visualstudioplustools_vs-2022-ent-general-win11-m365-gen2",
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
"version": "1.0.0",
"publishedDate": "2025-09-30T17:00:00-07:00"
},
},
"createdTime": "2025-10-24T12:08:40.895926-07:00",
"localAdministrator": "Enabled"
}

DEBUG: ResponseCreated:
DEBUG: BeforeResponseDispatch:
DEBUG: 12:23:09 PM - [ConfigManager] Got nothing from [DisplaySecretsWarning], Module = [], Cmdlet = []. Returning default value [True].
DEBUG: Finally:
DEBUG: CmdletAfterAPICall:
DEBUG: [CmdletProcessRecordAsyncEnd]: Finish HTTP process
DEBUG: CmdletProcessRecordAsyncEnd:
DEBUG: CmdletProcessRecordEnd:
DEBUG: AzureQoSEvent: Module: Az.DevCenter:2.0.2; CommandName: Get-AzDevCenterUserDevBox; PSVersion: 7.5.4; IsSuccess: True; Duration: 00:00:00.1186429; SanitizeDuration: 00:00:00.0000531
Current status: Hibernated
Dev Box stopped successfully.
EndTime Name OperationLocation
------- ---- -----------------
10/27/2025 7:22:14 PM bc1434a3-8ef5-4b78-b599-af2c2f1be142 https://.centralus.devcenter.azure.com/project…

PS C:\Experiments\DevBoxDelete>
```

### Environment data

```PowerShell
PS C:\Experiments\DevBoxDelete> $PSVersionTable

Name Value
---- -----
PSVersion 7.5.4
PSEdition Core
GitCommitId 7.5.4
OS Microsoft Windows 10.0.26200
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
```

### Module versions

```PowerShell
PS C:\Experiments\DevBoxDelete> Get-Module Az*

ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Script 5.3.0 Az.Accounts {Add-AzEnvironment, Clear-AzConfig, Clear-AzContext, Clear-AzDefault…}
Script 2.0.2 Az.DevCenter {Connect-AzDevCenterAdminCatalog, Connect-AzDevCenterAdminProjectCatalog, Deploy-…
Script 1.2.1 Az.ResourceGraph {Search-AzGraph, Get-AzResourceGraphQuery, New-AzResourceGraphQuery, Remove-AzRes…
```

### Error output

```PowerShell
No error, passes successfully.
```

Contributor guide

Open the contributing guide

Research direction

Start at the Stop-AzDevCenterUserDevBox entry point and reproduce the behavior with the supplied script, versions, and debug request to the /devboxes/{name}:stop endpoint. Confirm completion with Get-AzDevCenterUserDevBox: without -Hibernate, the Dev Box should report stopped rather than Hibernated, including when the pool allows hibernation.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, powershell
Domain
cli, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.