Monday, January 9, 2012

[YouTube-API] End Live Event Through API

While sending a PATCH request to the API indicating <yt:when end='now'/>, it responds that a start time is required. If I supply a start time, the API assumes that I am trying to start an already started event.

URL: https://gdata.youtube.com/feeds/api/users/#{youtube_username}/live/events/#{youtube_event_id} 
Method: POST

Request Headers:
User-Agent: GoogleDataRubyUtil-AnonymousApp
GData-Version: "2"
X-HTTP-Method-Override: PATCH
X-GData-Key: key=#{developer_key}
Content-Type: application/xml

Request Body:
<entry xmlns='http://www.w3.org/2005/Atom'
    xmlns:media='http://search.yahoo.com/mrss/'
xmlns:gd='http://schemas.google.com/g/2005'
    xmlns:yt='http://gdata.youtube.com/schemas/2007'
gd:fields='yt:when'>
  <yt:when end='now'/>
</entry>

--
You received this message because you are subscribed to the Google Groups "YouTube APIs Developer Forum" group.
To view this discussion on the web visit https://groups.google.com/d/msg/youtube-api-gdata/-/D3_CRqqW-M4J.
To post to this group, send email to youtube-api-gdata@googlegroups.com.
To unsubscribe from this group, send email to youtube-api-gdata+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/youtube-api-gdata?hl=en.

No comments:

Post a Comment