Office 365 authentication sample

I am trying to play with your library to authenticate against an Office 365 tenant.
I implemented my code logic using your development guide (section 10.4), and I am actually capable of routing auth requests to your local demo site (HighLevelAPI / MVC), but I am getting an error once redirected to Office 365.

I am landing on the Microsoft page, with an error message ID 800478A1.
This Id does not seem to be documented, but I would like to know if I am not missing anything in the parameters I am giving out to the InitiateSSO method (especially the relayState parameter)

Thanks for your help,

Hi Ben
The relay state isn’t used for SSO with Office 365. We haven’t seen that error code before and couldn’t find any documentation on it either.
The problem will most likely be a configuration mismatch. Please double check the Office 365 configuration steps in section 10.4 of our Developer Guide.
If there’s still an issue, please enable SAML trace and email the log file as an email attachment to mentioning this topic.

For others who would fall onto the same message, the only thing I had to do was to used methods ReveiceSSO and SendSSO instead of only InitiateSSO, which stands for IdP-initiated access; it seems that Office 365 is making a difference here, and should be setting a cookie somewhere, thus giving this error.

Cheers, Ben