POX Autodiscover Request Email Address Can't Be Found

Ben P 6 Reputation points
2021-05-11T18:03:38.993+00:00

I am trying to work with public folders on Exchange Online using EWS, and I need to do a POX Autodiscover request to determine the X-PublicFolderInformation header value as described here:
https://video2.skills-academy.com/en-us/exchange/client-developer/exchange-web-services/how-to-route-public-folder-hierarchy-requests#bk_makeautodrequest

I am getting this error:
95673-image.png

I am using OAuth and Exchange Online, but I try doing the same request to an on premise Exchange server using NTLM, it works fine. Is this something that is not supported with OAuth, or could there be some other configuration changes I need to make in order for this to work? Thanks!

Exchange Server Development
Exchange Server Development
Exchange Server: A family of Microsoft client/server messaging and collaboration software.Development: The process of researching, productizing, and refining new or existing technologies.
526 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Glen Scales 4,431 Reputation points
    2021-05-11T23:42:44.15+00:00

    The actual error is pointing towards an issue with the email address your trying to discover rather then an issue with the code, I would suggest trying to discover the address with the RCA first and see if that works https://testconnectivity.microsoft.com/tests/o365

    0 comments No comments

  2. Ben P 6 Reputation points
    2021-05-12T15:03:40.897+00:00

    The RCA test succeeded. I also testing my code using basic authentication instead of OAuth, and it succeeded! Is it possible that the POX autodiscover service does not support OAuth authentication? I am able to make SOAP autodiscover requests using OAuth.

    I found this question, and the individual is having the identical problem: https://video2.skills-academy.com/en-us/answers/questions/276346/pox-autodiscover-requests-using-oauth-for-o365-end.html

    0 comments No comments

  3. Ben P 6 Reputation points
    2021-05-12T16:09:09.443+00:00

    I've gotten further with this. OAuth works as long as I use delegated permissions. Application permissions are what does not work.

    0 comments No comments