Symptoms

POA cannot execute a task related to Office 365 service provisioning; the task fails with some confusing error message from the Microsoft API servers.

Office 365 APS application 2.2 or later is installed in POA.

The problem has to be investigated with the help of the Microsoft Support Team. The Microsoft Support Team needs the exact request and response XML packets which the MOSI Gateway Server (Microsoft Online Services Interface) uses to provision services in Microsoft Office 365 Cloud.

The article describes how to extract the request and response XML packets to/from the Microsoft Office 365 API servers on a POA-managed MOSI Gateway Server.

Resolution

Starting from the Office 365 2.2 the following features were implemented in part of MOSI Gateway logging:

  • Logging of XML payload of MOSI requests/responses is enabled by default.
  • XML payload of calls to the Microsoft cloud is logged separately for each Office 365 customer.
  • XML payload of callbacks from the Microsoft cloud is logged to the separate file which is rotated daily.
  • If a call to the Microsoft cloud is failed the XML request and response are shown in the appropriate task log in POA.

The MOSI Gateway log files containing XML payload of requests and responses are placed in the MOSI_GATEWAY_HOME\App_Data\XMLPayload folder, where MOSI_GATEWAY_HOME is the directory where MOSI Gateway is installed, see Knowledgebase article #114674 for instructions how to find the needed folder.

There are the following log files:

  • Customer-CustomerId, where CustomerId is a globally unique identifier (GUID) of a customer in the Microsoft Office 365 cloud. These log files contain XML data of calls to the Microsoft cloud per customer.
  • Callbacks - this log file contains XML data of callbacks from the Microsoft cloud to the Office 365 Gateway for the current day (it is rotated daily).
  • CallbacksYYYYMMDD - these log file contain XML data of callbacks from the Microsoft cloud to the Office 365 Gateway for the past days.

So, having Office 365 customer ID Provider may easily find all XML requests/responses to/from Microsoft cloud in the MOSI_GATEWAY_HOME\App_Data\XMLPayload\Customer-CustomerID file using timestamp which is stored in the log file along with the XML payload like in the example below:

2012-10-09 09:55:37,512 INFO Request: <s:Envelope xmlns:a="http://www.w3.org/2005/08/addressing" xmlns:s="http://www.w3.org/2003/05/soap-envelope">
<s:Header>
<a:Action s:mustUnderstand="1">http://www.microsoftonline.com/MOSI/1/0/action/CreateCustomerAccount</a:Action>
<a:MessageID>urn:uuid:41f5a857-838f-43b7-830d-ba1f70c97c8c</a:MessageID>
<ActivityId CorrelationId="1a284d57-0c03-4e84-952d-e39848f27b4d" xmlns="http://schemas.microsoft.com/2004/09/ServiceModel/Diagnostics">9d7d8afc-d1a3-4da5-b9e3-9453da839f17</ActivityId>
<a:ReplyTo>
  <a:Address>http://www.w3.org/2005/08/addressing/anonymous</a:Address>
</a:ReplyTo>
</s:Header>
<s:Body>
<CreateCustomerAccount xmlns="http://www.microsoftonline.com/MOSI/1/0/service/">
  <request xmlns:d4p1="http://www.microsoftonline.com/MOSI/1/0/messages/" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
    <d4p1:AlternateEmail>customer@customer.com</d4p1:AlternateEmail>
    <d4p1:BillingId>12345678-90ab-cdef-1234-567890abcd</d4p1:BillingId>
    <d4p1:CustomerAccount>
      <d4p1:Address>
        <d4p1:City>Seattle</d4p1:City>
        <d4p1:ISO3CountryCode>US</d4p1:ISO3CountryCode>
        <d4p1:Line1>Rodeo Drive</d4p1:Line1>
        <d4p1:Line2 />
        <d4p1:PhoneNumber>425--1234567</d4p1:PhoneNumber>
        <d4p1:PostalCode>98765</d4p1:PostalCode>
        <d4p1:State />
      </d4p1:Address>
      <d4p1:BusinessName>Customer LTD</d4p1:BusinessName>
      <d4p1:CommunicationCulture i:nil="true" />
      <d4p1:CommunicationLanguage i:nil="true" />
      <d4p1:FirstName>John</d4p1:FirstName>
      <d4p1:LastName>Doe</d4p1:LastName>
    </d4p1:CustomerAccount>
    <d4p1:CustomerId>98765432-10fe-dcba-1234-567890abcdef</d4p1:CustomerId>
    <d4p1:RequestId>5a6720f3-f7e6-4513-b6e4-d655928a53d2</d4p1:RequestId>
    <d4p1:SubDomain>cust1000001</d4p1:SubDomain>
  </request>
</CreateCustomerAccount>
</s:Body>
</s:Envelope>

Note: do not send the entire content of the XML packets; not all of this information is needed by the Microsoft Support Team for proper problem investigation. Send only the contents of the Header and Body tags.

Internal content