Displays the details for a video.

Note: ALL arguments are required.

Authenication

Authentication is optional. After authenticating and using sessionid parameter, you may ask about your private data using this method. Asking about private data without authentication will result with returning empty data set or an error.

Arguments

method
Should be set to “Viddler.videos.getDetails”
api_key
Assigned Viddler API Key
sessionid (optional)
Current session in generated by calling viddler.users.auth method
video_id
The ID of the video to get information for. This is the ID that’s returned by upload.video.
add_embed_code (optional, default: 0)
Include video oembed code in response (”1″ or “0″)
include_comments (optional, default: 1)
Include comments in response (”1″ or “0″)

Example Call

http://api.viddler.com/rest/v1/?method=viddler.videos.getDetails&api_key=key&video_id=video_id

Example Response

<?xml version="1.0" encoding="UTF-8"?>
<video>
  <author>username</author>
  <id>35104279</id>
  <title>My video</title>
  <length_seconds>188</length_seconds>
  <width>640</width>
  <height>480</height>
  <description></description>
  <view_count>121</view_count>
  <upload_time>1195445607000</upload_time>
  <comment_count>0</comment_count>
  <tags>
    <global>tag1</global>
    <global>tag2</global>
    <global>this is tag3</global>
    <timed offset="2220">timed tag4</timed> <!-- offset in milliseconds -->
    <timed offset="5550">this is timed tag5</timed>
  </tags>
  <url>http://www.viddler.com/explore/username/videos/11/</url>
  <thumbnail_url>http://cdn-ll-79.viddler.com/e2/thumbnail_2_34111279.jpg</thumbnail_url>
  <permalink>http://www.videopermalink.site.com/1008/08/08/</permalink>
  <update_time>1129803584</update_time>
  <!-- permissions section - for authenticated user videos only -->
  <permissions>
    <view level="shared_all">
      <secreturl>http://www.viddler.com/explore/username/videos/123/?secreturl=112635379</secreturl>
    </view>
    <embed level="shared">
      <user>friend1</user>
      <user>friend2</user>
      <list>my buddy list1</list>
    </embed>
    <tagging level="shared">
      <list>my buddy list2</list>
    </tagging>
    <commenting level="shared_all" />
    <download level="shared_all" />
  </permissions>
  <!-- comments section -->
  <comment_list>
    <comment>
      <id>1231233</id>
      <type>text</type>
      <author>steve</author>
      <rating>2</rating>
      <parent>33222</parent>
      <text>asdfasdf</text>
      <add_time>1129773022</add_time>
    </comment>
    <comment>
      <id>1211233</id>
      <type>video</type>
      <author>steve</author>
      <rating>2</rating>
      <parent>33222</parent>
      <video>
        <source>http://url.to.video/file.flv</source>
        <thumbnail>http://url.to.thumbnail/file.jpg</thumbnail>
      </video>
      <add_time>1129773022</add_time>
      <add_timepoint>1129773022</add_timepoint>
    </comment>
  </comment_list>
</video>

Details

  • Real API response won’t contain comments
  • All possible permission levels are: publicshared_allshared and private
  • only /video/permissions/view node may contain secreturl node
  • only shared permission level may contain user and list subnodes

Error Codes

Standard error codes plus:

Error # Description
100 Video could not be found.

Changelog

  • Version 1.2.0
    • Added permalink property to response
  • Version 1.1.0
    • Added video width and height to response
    • Added add_embed_code parameter
    • Added include_comments parameter
    • Response contains both timed and global video tags
    • Added permissions section (for authenticated user videos only!)