Revision [229]Most recent edit made on 2008-11-12 03:41:19 by WikiAdminAdditions:<bufsize>[RC Buffer Size]</bufsize> Deletions:<bufsize>[RC Buffer Size]</bufisize> Revision [227]Edited on 2008-11-11 03:55:38 by WikiAdminAdditions: Note: The media will get 'Ready to process' status only if at least one <format> was specified. Deletions: Note: The media will get 'Ready for processing' status only if at least one <format> was specified. Revision [226]Edited on 2008-11-11 03:49:03 by WikiAdminAdditions:
Deletions:
Revision [224]Edited on 2008-11-06 06:16:48 by WikiAdminAdditions:All: WxH, where W and N are any even integers. Note: You can specify only one dimension: either width or height. In this case, set other dimension to 0. (I.e. 640x0).Deletions:All: WxH, whereW and N are any non-zero even integers. Revision [223]Edited on 2008-11-05 04:23:55 by WikiAdminAdditions:If you don't specify AWS key/secret, the bucket must have READ and WRITE permissions for AWS user 1a85ad8fea02b4d948b962948f69972a72da6bed800a7e9ca7d0b43dc61d5869, See http://docs.amazonwebservices.com/AmazonS3/2006-03-01/S3_ACLs.html#S3_ACLs_Grantees∞ for details. Deletions:If you don't specify AWS key/secret, the bucket must have WRITE permission for AWS user 1a85ad8fea02b4d948b962948f69972a72da6bed800a7e9ca7d0b43dc61d5869, See http://docs.amazonwebservices.com/AmazonS3/2006-03-01/S3_ACLs.html#S3_ACLs_Grantees∞ for details. Revision [222]Edited on 2008-10-21 10:15:16 by WikiAdminAdditions:bufsize [optional] - Rate control buffer size (bits).
rc_init_occpancy [optional] - Initial rate control buffer occupancy (bits). Deletions:bufsize [optional] - Rate control buffer size (bytes).
rc_init_occpancy [optional] - Initial rate control buffer occupancy (bytes). Revision [219]Edited on 2008-10-21 09:52:59 by WikiAdminAdditions:bufsize [optional] - Rate control buffer size (bytes).
rc_init_occpancy [optional] - Initial rate control buffer occupancy (bytes). Deletions:bufsize [optional] - Rate control buffer size (bits).
rc_init_occpancy [optional] - Initial rate control buffer occupancy (bits). Revision [217]Edited on 2008-10-21 08:35:21 by WikiAdminAdditions:<rc_init_occupancy>[RC Occupancy]</rc_init_occupancy> maxrate [optional] - Maximum allowed video bitrate.<minrate>[Min Rate]</minrate> <maxrate>[Max Rate]</maxrate> <bufsize>[RC Buffer Size]</bufisize> N or Nk - where N is any non-zero integer. N or Nk - where N is any non-zero integer. N or Nk - where N is any non-zero integer. N or Nk - where N is any non-zero integer. Revision [213]Edited on 2008-10-20 09:37:27 by WikiAdminAdditions:http://[AWS_KEY:AWS_SECRET@][bucket].s3.amazonaws.com/[filename] Deletions:http://[bucket].s3.amazonaws.com/[filename] (the bucket must have WRITE permission for AWS user 1a85ad8fea02b4d948b962948f69972a72da6bed800a7e9ca7d0b43dc61d5869, See http://docs.amazonwebservices.com/AmazonS3/2006-03-01/S3_ACLs.html#S3_ACLs_Grantees∞ for details). Revision [211]Edited on 2008-10-20 09:32:42 by WikiAdminAdditions:Also, you can add ?acl=public-read OR ?acl=authenticated-read after the filename. This will explicitly set access rights to the saved object instead of the default settings. Deletions:Also, you can add ?acl=public-read OR ?acl=authenticated-read after the filename. Revision [210]Edited on 2008-10-20 09:30:46 by WikiAdminAdditions:
Deletions:
Revision [207]Edited on 2008-10-20 09:13:23 by WikiAdminAdditions:<thumb_destination>[Thumb Dest]</thumb_destination> Logo fieldslogo_source [required] - The URL of the logo image. The image format can be GIF, JPG or PNG.
http://[user]:[password]@ [server]/[path]/[filename], Default: sftp://[user]:[password]@[server]/[path]/[filename], none non-negative integer Default: 10 non-negative integer Default: 10 Deletions:<thumb_destination>[Thumb Dest]</thumb_destination> Revision [197]Edited on 2008-10-03 04:00:40 by WikiAdminAdditions:Non-negative number greater than 0.01 or hh:mm:ss.ms Deletions:Non-negative integer or hh:mm:ss.ms Revision [191]Edited on 2008-10-01 04:36:39 by WikiAdminAdditions:Note: Adding ?passive=yes to the FTP URL forces downloader/uploader use Passive Mode for FTP Transfer. Also, you can specify ?passive=no (the default) explicitly. It will take the same effect that if you don't specify this parameter at all.
Deletions:Note: Adding ?passive=yes to the FTP URL forces downloader/uploader use Passive Mode for FTP Transfer.
Revision [190]Edited on 2008-09-29 09:38:43 by WikiAdminAdditions:
Deletions:
Revision [187]Edited on 2008-09-29 09:34:17 by WikiAdminAdditions:
Deletions:
Revision [186]Edited on 2008-09-29 09:28:35 by WikiAdminAdditions:ftp://[user]:[password]@[server]/[path]/[filename][?passive=yes], Revision [185]Edited on 2008-09-29 09:26:22 by WikiAdminAdditions:<time_left>[TotalTimeLeft]</time_left>
TotalTimeLeft is an estimated time until the media processing would be finished<progress>[TotalProgress]</progress> <time_left_current>[StatusTimeLeft]</time_left_current> <progress_current>[StatusProgress]</progress_current> <s3_destination>[TempS3Link]</s3_destination> StatusTimeLeft is an estimated time left for the media's current status TotalProgress is an estimated progress for entire media processing (in percent) StatusProgress is an estimated progress for the media's current status (in percent) TempS3Link S3 URL of the encoded file, if the <destination> was empty Revision [183]Edited on 2008-09-23 05:33:16 by WikiAdminAdditions:
Deletions:
Revision [174]The oldest known version of this page was edited on 2008-08-28 12:28:17 by WikiAdminXML format for user’s API request Server Response XML format Error Messages Encoding Result XML format The XML API OverviewThe communication with the encoding.com is realized through a single interface: by sending HTTP(S) requests to the manage.encoding.com/. All client requests and server answers use XML format. Client must send HTTP(S) POST request with single parameter named xml. The server response is a normal XML document. XML format for user’s API request<?xml version="1.0"?>
<query> <!-- Main fields --> <userid>[UserID]</userid> <userkey>[UserKey]</userkey> <action>[Action]</action> <mediaid>[MediaID]</mediaid> <source>[SourceFile]</source> <notify>[NotifyURL]</notify> <format> <!-- Format fields --> <output>[Output format]</output> <video_codec>[Video Codec]</video_codec> <audio_codec>[Audio Codec]</audio_codec> <bitrate>[Video bitrate]</bitrate> <audio_bitrate>[Audio bitrate]</audio_bitrate> <audio_sample_rate>[Audio quality]</audio_sample_rate> <size>[Size]</size> <crop_left>[Crop Left]</crop_left> <crop_top>[Crop Top]</crop_top> <crop_right>[Crop Right]</crop_right> <crop_bottom>[Crop Bottom]</crop_bottom> <thumb_time>[Thumb time]</thumb_time> <thumb_size>[Thumb size]</thumb_size> <add_meta>[yes/no]</add_meta> <!-- Destination fields --> <destination>[DestFile]</destination> <thumb_destination>[Thumb Dest]</thumb_destination> </format> </query> Fields valuesMain fields
Format fieldsNote: There may be more than one <format> elements in a single query Output (required) – output format. Specify format of encoded file.
Allowed values: flv, fl9, wmv, 3gp, mp4, m4v, ipod, iphone, appletv, psp, zune, vp6* and thumbnail**. Default: none * - see VP6 Features chapter below ** - see Thumbnail Features chapter below Allowed values: All: WxH, whereW and N are any non-zero even integers. Default:3gp: 128x96, 176x144, 352x288, 704x576, 1408x1152 ipod: 320x240, 640x480 iphone: 480x368 appletv: 710x480 zune: 320x180, 320x240 All: none 3gp: 176x144 iphone: 480x368 appletv: 710x480 psp: 368x192 zune: 320x180 Allowed values: Nk - where N is any non-zero integer. Default:All: 512k 3gp: 256k ipod, iphone, psp: 1024k Allowed values: any non-zero integer or N/M where N and M are non-zero integers. Default:All: 25 psp: 30000/1001 Allowed values: flv: flv Default:fl9: libx264 wmv, zune: wmv2, msmpeg4 3gp: h263 mp4, m4v, ipod, iphone, appletv, psp: mpeg4 flv: flv fl9: libx264 wmv, zune: wmv2 3gp: h263 mp4, m4v, ipod, iphone, appletv, psp: mpeg4 Allowed values: Nk - where N is any non-zero integer Default:3gp: 4.75k, 5.15k, 5.9k, 6.7k, 7.4k, 7.95k, 10.2k, 12.2k flv, wmv, zune: 32k, 40k, 48k, 56k, 64k, 80k, 96k, 112k, 128k, 144k, 160k, 192k, 224k, 256k, 320k All: 64k 3gp: 12.2k ipod, iphone, psp: 128k Allowed values: All: any non-zero integer. Default:3gp: 8000 flv: 11025, 22050, 44100 wmv, zune: 11025, 22050, 32000, 44100, 48000 All: none 3gp: 8000 flv, zune: 44100 audio_codec [optional] - Audio codec.
Allowed values: flv: libmp3lame Default:fl9, mp4, m4v, ipod, iphone, appletv, psp: libfaac wmv, zune: wmav2, libmp3lame 3gp: libamr_nb flv: libmp3lame fl9, mp4, m4v, ipod, iphone, appletv, psp: libfaac wmv, zune: wmav2 3gp: libamr_nb Allowed values: All: any non-zero integer. Default:3gp: 1 All: 2 3gp: 1 Allowed values: yes, no Defualt: no cbr [optional] - Whether to use CBR (Constant bitrate)
Allowed values: yes, no Defualt: no Allowed values: yes, no Defualt: no Allowed values: even integer Default:None Allowed values: even integer Default:None Allowed values: even integer Default:None Allowed values: even integer Default:None Allowed values: integer Default:None Allowed values: WxH, where W and H are any non-zero integers. Default:None add_meta [optional] - FLV only. Whether to add meta data to the file.
Allowed values: yes, no. Default:All: None flv: no Destination fieldsdestination [optional] - The destination URL to put the encoded file.
Allowed values: ftp://[user]:[password]@[server]/[path]/[filename], Default:sftp://[user]:[password]@[server]/[path]/[filename], http://[bucket].s3.amazonaws.com/[filename] (the bucket must have WRITE permission for AWS user 1a85ad8fea02b4d948b962948f69972a72da6bed800a7e9ca7d0b43dc61d5869, See http://docs.amazonwebservices.com/AmazonS3/2006-03-01/S3_ACLs.html#S3_ACLs_Grantees∞ for details). None Allowed values: ftp://[user]:[password]@[server]/[path]/[filename], Default:http://[bucket].s3.amazonaws.com/[filename] (the bucket must have WRITE permission for AWS user 1a85ad8fea02b4d948b962948f69972a72da6bed800a7e9ca7d0b43dc61d5869, See http://docs.amazonwebservices.com/AmazonS3/2006-03-01/S3_ACLs.html#S3_ACLs_Grantees∞ for details). None VP6 FeaturesIf you choose vp6 for output format, your XML query will differ (you can specify only two parameters in addition to output at format fields section): <format>
<!-- Format fields --> <output>vp6</output> <profile>[VP6 profile]</profile> <size>[Size]</size> <!-- Destination fields --> <destination>[DestFile]</destination> </format> The specific parameter profile is added: profile [optional] – VP6 profile.
Allowed values: VP6-E, VP6-S Default: VP6-Edestination [required] - The destination URL to put the encoded file.
Note: There must be only one <format> for each profile per one source media. In other words, you must not send more than two vp6 <format> items per media, and they must have different profiles. Thumbnail FeaturesInstead of using thumb_ parameters within <format>, you can specify separate encoding task with output = thumbnail: <format>
<!-- Format fields --> <output>thumbnail</output> <time>[Time]</time> <width>[Width]</width> <height>[Size]</height> <!-- Destination fields --> <destination>[DestFile]</destination> </format> With the following specific parameters: time [optional] – Timestamp (in seconds) to capture thumbnail.
If you specify both width and height, you'll get a thumbnail with these dimensions, and if your video have another aspect ratio than the thumbnail, black spaces will be added to the picture.Allowed values: Non-negative integer or hh:mm:ss.ms Default: 5Allowed values: Non-negative integer Default: noneAllowed values: Non-negative integer Default: noneIf you specify only one parameter from this pair, the other one will be calculated according to your video size. If none of those parameters specified, the thumbnail will have the same size as your video have. Now only JPEG format is supported for thumbnails. Server Response XML formatThe response for API request can vary depending on action: AddMedia action<?xml version="1.0"?>
<response> <message>Added</message> <MediaID>[MediaID]</MediaID> </response> GetMediaList action<?xml version="1.0"?>
<response> <media> <mediafile>[""SourceFile""]</mediafile> <mediaid>[""MediaID""]</mediaid> <mediastatus>Closed</mediastatus> <createdate>[Date]</createdate> <startdate>[Date]</startdate> <finishdate>[Date]</finishdate> </media> <media> ... </media> </response> Where Date is of the format: YYYY-MM-DD HH:MM:SS GetStatus action<?xml version="1.0"?>
<response> <id>[MediaID]</id> <userid>[UserID]</userid> <sourcefile>[SourceFile]</sourcefile> <status>[MediaStatus]</status> <notifyurl>[NotifyURL]</notifyurl> <created>[Date]</created> <started>[Date]</started> <finished>[Date]</finished> <prevstatus>[MediaStatus]</prevstatus> <downloaded>[Date]</downloaded> <uploaded>[Date]</uploaded> <format> <id>[ID]</id> <status>[Status]</status> <created>[Date]</created> <started>[Date]</started> <finished>[Date]</finished> [FormatFields] </format> <format> … </format> </response> Where Date is of the format: YYYY-MM-DD HH:MM:SS FormatFields is a set of fields corresponding to <format> section of an user’s API request GetMediaInfo action<?xml version="1.0"?>
<response> <bitrate>364k</bitrate> <duration>175.21</duration> <video_codec>h264</video_codec> <frame_rate>23.98</frame_rate> <audio_sample_rate>44100</audio_sample_rate> <size>352x288</size> </response> Other actions<?xml version="1.0"?>
<response> <!-- Message section --> <message>[Message]</message> <!-- Errors section --> <errors> <error>[Error]</error> <error>[Error]</error> … </errors> </response> Error MessagesError Messages appears in the response if the action was failed. Common ErrorsNo XML - No XML query provided in the request.
Wrong XML - The XML query provided in the request is not well-formed Wrong query format - The XML does not contain <query> root element Invalid action - The Action parameter is empty or has not in the list of allowed actions Authentication ErrorsWrong user id or key - The user ID/userkey pair was not found
Source Media Handling ErrorsMedia ID is not indicated - The MediaID parameter is omitted in the query
Actions: UpdateMedia, GetStatus Actions: AddMedia, UpdateMedia Actions: AddMedia, UpdateMedia Actions: UpdateMedia, GetStatus Queue Handling ErrorsNo formats specified - There is no a single <format> element presents in the query.
Actions: AddMedia, UpdateMedia Actions: AddMedia, UpdateMedia Actions: AddMedia, UpdateMedia Actions: AddMedia, UpdateMedia Actions: all Encoding Result XML formatIf " http:// " link is specified in the <notify> part of the <query>, HTTP POST request will be sent to the specified location. The POST data will contain one parameter named xml, containing XML of the following format: <?xml version="1.0"?>
<result> <mediaid>[MediaID]</mediaid> <source>[SourceFile]</source> <status>[MediaStatus]</status> <description>[ ErrorDescription]</description> <format> <output>[OutputFormat]</output> <destination>[DestFile]</destination> <status>[TaskStatus]</status> <description>[ErrorDescription]</description> <suggestion>[ErrorSuggestion]</suggestion> <thumb_destination>[ThumbDest]</thumb_destination> </format> </result> Fields values
|
||||||||||||||||||||||||||||||||||||