2.2.2.9 SendEvent (Request and Response)

The purpose of the SendEvent request is to submit a remote event to the server. The most common remote event is "remote-log", which specifies rendering statistics independently of streaming statistics. It is possible for clients to send "remote-log" events to a server after having played content entirely from a cache without having had a streaming connection to the server. For more information about remote events, see section 2.2.5.

The SendEvent request is defined as an HTTP POST request that satisfies the ABNF syntax for WMS-SendEvent-Request [RFC4234] and satisfies all of the following conditions:

The syntax of the SendEvent response is defined as a WMS-SendEvent-Response, with the additional constraint that the response contains a zero-length message body.

 WMS-SendEvent-Request  = WMS-SE-Req-Line
                          WMS-SEReq-Headers
                          CRLF
                          WMS-SEReq-Body 
   
 WMS-SE-Req-Line        = "POST" SP Request-URI SP HTTP-Version CRLF
  
 WMS-SEReq-Headers      = *( SEReq-Header-REQ
                          / SEReq-Header-OPT
                          / SEReq-Pragma
                          / HTTP-Header-Types )
  
 SEReq-Header-REQ       = Content-Type              ; section 2.2.1.2
                          / User-Agent              ; section 2.2.1.8
  
 SEReq-Header-OPT       = Cookie                    ; section 2.2.1.3
                          / Supported               ; section 2.2.1.7
                          / X-Accept-Authentication ; section 2.2.1.9
                          / X-Proxy-Client-Verb     ; section 2.2.1.11 
  
 SEReq-Pragma           = "Pragma: " #SEReq-Pragma-Types CRLF
  
 SEReq-Pragma-Types     = SEReq-Token-OPT
  
 SEReq-Token-OPT        = client-id                ; section 2.2.1.4.5
                          / no-cache               ; section 2.2.1.4.12
                          / proxy-client-agent     ; section 2.2.1.4.21
                          / request-context        ; section 2.2.1.4.23
                          / xClientGuid            ; section 2.2.1.4.33
  
 WMS-SEReq-Body         = remote-event-message  ; section 2.2.5
  

WMS-SendEvent-Response:

 WMS-SendEvent-Response = Status-Line
                          WMS-SEResp-Headers CRLF
   
 WMS-SEResp-Headers     = *( SEResp-Header-REQ
                           / SEResp-Header-OPT
                           / SEResp-Pragma
                           / HTTP-Header-Types )
  
 SEResp-Header-REQ      = Cache-Control           ; section 2.2.1.1
                          / Server                ; section 2.2.1.5
  
 SEResp-Header-OPT      = Set-Cookie              ; section 2.2.1.6
                          / Supported             ; section 2.2.1.7
  
 SEResp-Pragma          = "Pragma: " #SEResp-Pragma-Types CRLF
  
 SEResp-Pragma-Types    = SEResp-Token-REQ
                          / SEResp-Token-OPT
  
 SEResp-Token-REQ       = no-cache                ; section 2.2.1.4.12
  
 SEResp-Token-OPT       = client-id               ; section 2.2.1.4.5
                          / timeout               ; section 2.2.1.4.29
  

The following example shows a SendEvent request.

 POST /industrial.wmv HTTP/1.1
 Accept: */*
 User-Agent: NSPlayer/11.0.5721.5145
 Host: SampleServer
 Pragma: xClientGUID={3300AD50-2C39-46c0-AE0A-4F6B136D663C}
 X-Accept-Authentication: Negotiate, NTLM, Digest, Basic
 Content-Length: 2975
 Content-Type: application/x-wms-sendevent
 Pragma: client-id=1953501979

The following example shows a SendEvent response.

 HTTP/1.1 200 OK
 Server: Cougar/9.5.6001.18000
 Date: Wed, 25 Jun 2008 09:33:55 GMT
 Pragma: no-cache, client-id=1953501979, features="seekable,stridable", timeout=60000
 Cache-Control: no-cache
 Supported: com.microsoft.wm.srvppair, com.microsoft.wm.sswitch, com.microsoft.wm.predstrm, com.microsoft.wm.fastcache, com.microsoft.wm.startupprofile
 Content-Length: 0