-
Notifications
You must be signed in to change notification settings - Fork 211
Description
Describe the bug
I am trying to create a contact in outlook (in folder) per powershell using New-MgUserContactFolderContact.
The contact should have a "PersonalNote" with a number. For example: 123456
Error:
New-MgUserContactFolderContact : were unable to deserialize
Status: 400 (BadRequest)
ErrorCode: UnableToDeserializePostBody
- FullyQualifiedErrorId : UnableToDeserializePostBody,Microsoft.Graph.PowerShell.Cmdlets.NewMgUserContactFolderContact_Create
Expected behavior
New Contact created in a contact folder in outlook.
How to reproduce
$params = @{
GivenName = "A"
Surname = "B"
PersonalNotes = "123456"
}
Get-MgUserContactFolder -userid mr.test@contoso.com
$ContactFolderId = "........"
New-MgUserContactFolderContact -UserId mr.test@contoso.com -ContactFolderId $ContactFolderId -BodyParameter $params
SDK Version
2.26.1
Latest version known to work for scenario above?
2.25
Known Workarounds
PersonalNotes must include text, like "a123356".
$params = @{
GivenName = "A"
Surname = "B"
PersonalNotes = "text123456"
}
New-MgUserContactFolderContact -UserId "mr.test@contoso.com" -ContactFolderId $ContactFolderId -BodyParameter $params
Debug output
Click to expand log
```</details>
### Configuration
_No response_
### Other information
_No response_