4.1.5 Subsequent Callback Messages

After the callback context is established as described in section 4.1.4, the client connects to the server by using a transport protocol that supports exchanging SOAP messages as specified in [SOAP1.2-1/2007].  The server then sends a SOAP message that is intended for the associated customer. The server sends this message to the endpoint reference that was stored when the callback context was established. The context identifier for the customer is as described in WS-Addressing [WSA].

 <s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" 
 xmlns:a="http://www.w3.org/2005/08/addressing">
 <s:Header>
 <a:Action 
 s:mustUnderstand="1">http://machine1.example.org/Sample/INotifyCustomer/ShippedItems</a:Action>
 <a:MessageID>urn:uuid:323d365c-e69a-4d9e-99f1-3c2a57490926</a:MessageID>
 <a:ReplyTo>
 <a:Address>http://www.w3.org/2005/08/addressing/anonymous</a:Address>
 </a:ReplyTo>
 <Context xmlns="http://schemas.microsoft.com/ws/2006/05/context">
 <Property name="instanceId">c4b4e186-a5eb-4a8c-9f64-f8bb099e84eb</Property>
 </Context>
 <a:To s:mustUnderstand="1">http://machine3.example.org</a:To>
 </s:Header>
 <s:Body>
 <ShippedItems xmlns="http://machine1.example.org/Sample">
 <item>scarf</item>
 </ShippedItems>
 </s:Body>
 </s:Envelope>
  

When the client receives the message, it creates a context identifier that is isomorphic to the CONTEXT_XML element from the SOAP message and invokes a business logic function according to its rules for processing SOAP messages. This function determines that the customer exists for the provided context identifier and performs the appropriate action on the customer instance by using the content of the SOAP message.