none
Outlook Mail Rest API (Office 365) using Powershell RRS feed

  • Question

  • I try to update a mail message using PowerShell and the REST API described here msdn.microsoft.com/.../mail-rest-operations I try to set the flag to true like this

    $uri='https://outlook.office.com/api/v1.0/me/messages/AQMkAGNhMTJjZjJkLWJkYzEtNDY0My1hNTZhLWVmZgA2YTk1NjE2ZDYARgAAA_7Xl9tlI5pJjN-oWribDGQHAFOydA6gG1ZPhkRvyZErSPAAAAIBDAAAAFOydA6gG1ZPhkRvyZErSPAAAAIBfwAAAA=='


    $contentType

    ="application/json"


    $body

    ="{""IsRead"": true }"



    $mail

    =Invoke-RestMethod -Uri $uri-ContentType$contentType-Body$body-Credential$MailCred-MethodPatch


    I always get a 403 error. I tried the v2.0 API as v1.0 API as well?

    Any suggestion?

    Thanks a lot!

    Thursday, February 18, 2016 3:29 PM

All replies

  • Hi ReturnOne,

    Based on my test with a simple command to get mail in inbox, I get 403 error too.

    I'm trying to involve some senior engineers into this issue and it will take some time. Your patience will be greatly appreciated.

    Regards

    Starain


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.


    Friday, February 19, 2016 6:52 AM
    Moderator
  • Hi Starain

    Thank you very much for your help. Ok, I will wait :), I hope you will find a solution soon.

    Best regards

    ReturnOne

    Saturday, February 20, 2016 8:23 PM
  • Hi ReturnOne,

    For the issue related to Office 365 API, this forum is the better place, you may post it there too.  

    Regards

    Starain


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.

    Monday, February 22, 2016 1:49 AM
    Moderator
  • Hi

    Any update on this issue?

    Cheers,

    Stefan

    Tuesday, February 23, 2016 6:58 AM