Skip to content

Unable to update OOO via Update-MgBetaUserPresence #3287

@T00ma5z

Description

@T00ma5z

Describe the bug

I am trying to use Update-MgBetaUserPresence -OutOfOfficeSettings to update the OOO message on a user account who is on LOA but am getting an error message when running the following:

$OutOfOfficeSettings = @{
message = "Test - Out of Office"
isOutOfOffice = $true
}
Update-MgBetaUserPresence -UserId $UserId -OutOfOfficeSettings $OutOfOfficeSettings

Update-MgBetaUserPresence :
Status: 404 (NotFound)
ErrorCode: NotFound
Date: 2025-04-21T16:48:06
Headers:
Transfer-Encoding : chunked
Vary : Accept-Encoding
Strict-Transport-Security : max-age=31536000
request-id :
client-request-id :
x-ms-ags-diagnostic : {"ServerInfo":{"DataCenter":"West US 3","Slice":"E","Ring":"2","ScaleUnit":"000","RoleInstance":"PH1PEPF00011248"}}
scenario-id :
Date : Mon, 21 Apr 2025 16:48:05 GMT
At line:1 char:1

  • Update-MgBetaUserPresence -UserId $UserId -OutOfOfficeSettings $OutOf ...
  •   + CategoryInfo          : InvalidOperation: ({ UserId = 3053...GraphPresence }:<>f__AnonymousType6`3) [Update-MgBetaUserPresence_UpdateExpanded], Exception
      + FullyQualifiedErrorId : NotFound,Microsoft.Graph.Beta.PowerShell.Cmdlets.UpdateMgBetaUserPresence_UpdateExpanded
    
    

Expected behavior

I am not sure what if this is unsupported yet or if it is a bug

How to reproduce

$OutOfOfficeSettings = @{
message = "Test - Out of Office"
}
Update-MgBetaUserPresence -UserId $UserId -OutOfOfficeSettings $OutOfOfficeSettings

SDK Version

No response

Latest version known to work for scenario above?

No response

Known Workarounds

No response

Debug output

Click to expand log ```
</details>


### Configuration

_No response_

### Other information

_No response_

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions