API DOCUMENTATION
By using Tvider API , you can upload media in 3 formats i.e VIDEO, AUDIO, IMAGE .
API Methods
initChunkUpload
Method to initialize the Chunk Upload of a file.

Usage: http://tvider.com/api/initChunkUpload/fileName/{fileName}

Parameters:
fileName - The filename that has to be uploaded
contentMimeType - The MIME type of the content that is going to be uploaded using chunks. This has to be set in the request header 'content-type'. The header may be case sensitive.

Returns:
MediaUploadResponse, ServerResponse
chunkUpload
Method to upload a file in chunks. Each individual chunk of file is uploaded using this method. The offset has to be zero to indicate the start of the file. Include the Binary data of the file in the body of the request

Usage: http://tvider.com/api/chunkUpload/uploadId/{uploadId}/fileSize/{fileSize}/chunkOffset/{chunkOffset}/chunkLength/{chunkLength}

Parameters:
uploadId - The id of the file that was returned when the chunk upload was initialized
fileSize - The actual size of the file
chunkOffset - The offset from which the current chunk has to be appended.
chunkLength - The length of the current chunk

Returns:
MediaUploadResponse, ServerResponse
getUploadStatus
Method to get the status of the chunk upload in progress for the given upload id.

Usage: http://tvider.com/api/getUploadStatus/uploadId/{uploadId}

Parameters:
uploadId - The id of the file that was returned when the chunk upload was initialized

Returns:
MediaUploadResponse, ServerResponse
multipartUpload
The API call to upload a file to the server using the multipart approach. Set the paramter enctype="multipart/form-data"

Usage: http://tvider.com/api/multipartUpload

Parameters:
file - The name of the file that needs to be uploaded. It is basically the name of the file-field in the html page or elsewhere
Returns:
ServerResponse
postRichMediaTweet
The method to post a Rich Media Tweet in a users twitter account. All the parameters are sent to be in a POST Request Body

Usage:http://tvider.com/api/statuses/update.json

Authorization: Basic HTTP Authorization header required with Base64 encoded Username & Password eg. Authorization : Basic 32434324234343243243242==

Parameters:
mediaId - The id of the media that was uploaded and would be tweeted in users twitter account
text - The text status that goes along with the media
in_reply_to_status_id - Status id of a tweet

Returns:
RichMediaTweetResponse, ServerResponse
RichMediaTweetResponse
{
textTweet:http://tvider.com/u/r/9 Testing webcam capture...,
mediaId:10,
mobThumbUrl:http://tvider.com/Thumbnails/Mobile/UDH1098201762-wakeupsid0wakeups.flv_1.jpg,
sourceMediaType:VIDEO,
fromUser:umundotest,
webThumbUrl:http://Tvider.com/Thumbnails/Web/UDH1098201762-wakeupsid0wakeupsidpromo.flv_1.jpg,
isoLanguageCode:null,
logUrl:http://Tvider.com/Tvider/rmtanalytics/logview/9,
profileImageUrl:http://a3.twimg.com/profile_images/360469119/img_normal.png,
fromUserId:53282864,
mediaStatus:HOSTED,
fileUrl:null,
statusId:3556244101,
id:9,
duration:0,
toUser:xyz,
toUserId:-1,
views:0,
createdAt:1251293845000,
tweetSource:null,
streamUrl:null,
favourite:0
}
ServerResponse
{
result:
RichMediaTweetResponse,
error:
null,
responseTime:
"Response Time: 0.0 s"
}
MediaUploadResponse
{
error :
null,
responseTime :
"Response Time: 0.0 s";
result : {
mediaId : 159;
uploadStatus : "File upload in chunk is successfully initialized.";
uploadedFileLength : 0;
};
}