Hosted Video Upload - v5.4(PRR)

Upload videos for a review, question, answer or comment.

🚧

Hosted Video is available to clients on our Conversations PRR platform.

Refer to Conversations PRR Only Features for more information.

Introduction

Video upload is a two step process:

  1. First the video file must be uploaded to Bazaarvoice.
  2. Then, the uploaded video must be associated with a review, question, answer or comment during submission of that content.

This page describes the upload process. See the submission documentation for the appropriate content type to learn how to associate an uploaded video.

Examples

🚧

Demonstration purposes only. Do not reuse the API passkeys below in your application.

Preview

Perform a GET request to see information about available submission options:

http://stg.api.bazaarvoice.com/data/uploadvideo.json?apiversion=5.4&ContentType=review&UserId=craiggil&passkey=2cpdrhohmgmwfz8vqyo48f52g

Upload

Upload a video file using HTTP POST:

POST /data/uploadvideo.[json|xml]?productid=[ID]&apiversion=5.4&passkey=[YOUR_API_KEY]&contentype=[review|question|answer||review_comment|]&userid=[ID] HTTP/1.1
Host: [stg.]api.bazaarvoice.com
Content-Type: multipart/form-data; boundary=----ExampleFormBoundary7MA4YWxkTrZu0gW
...

----ExampleFormBoundary7MA4YWxkTrZu0gW
Content-Disposition: form-data; name="Video"; filename="test_video.mp4"
Content-Type: video/mp4


----ExampleFormBoundary7MA4YWxkTrZu0gW

Ellipses (...) in above example indicate that your app may generate other headers.

Learn more about multipart/form-data.

Parameters

NameDescriptionAdditional Info
ApiVersionThe API version, e.g. 5.4.API
ContentTypeThe content type for which this media is being submitted. Valid values include: review, question, answer, review_comment.API
[FORMAT]Response format (xml or json)API
PasskeyAPI key is required to authenticate API user and check permission to access particular client's data.API
VideoThe video file of less than 200 MB in 3GP/3G2, ASF, AVI, DV, FLV, MOV, MP4/F4V, MPEG/MPG, QT, or WMV format.API
LocaleLocale to display Labels, Configuration, Product Attributes and Category Attributes in. The default value is the locale defined in the display associated with the API key.Business
UserValue of the encrypted user. This parameter demonstrates that a user has been authenticated. Note that the UserId parameter does not contain authentication information and should not be used for hosted authentication. See the Authenticate User method for more information.Configuration
UserIdUser's external ID. Do not use email addresses for this value.Configuration

Response format

The response to a successful video upload request will include a VideoUrl. The VideoUrl can then be included in a review, question, answer, comment submission which will associate the video with that content.

{
    "Video": {
        "VideoUrl":"http://api.bazaarvoice.com/stories/0001/vs_21/video.swf"
    },
    "Data": {
        "Field": {
            "video": {
                "Name":"video",
                "Type":"FileInput"
            }
        }
    },
    "Form":[
        {
            "Type":"Field",
            "ID":"video"
        }
    ]
}

Error codes

ValueDescription
ERROR_ACCESS_DENIEDInsufficient privileges to perform the operation
ERROR_FORM_DUPLICATEThe nickname is already in use.
ERROR_FORM_DUPLICATE_NICKNAMEThe nickname is already in use.
ERROR_FORM_FILE_PARSEThe uploaded video could not be processed. Ensure that the video is a valid 3GP/3G2, ASF, AVI, DV, FLV, MOV, MP4/F4V, MPEG/MPG, QT, or WMV file.
ERROR_FORM_FILE_TOO_LARGEThe uploaded video is too large. Videos must be less than 200 MB.
ERROR_FORM_INVALID_EMAILADDRESSEmail address is not in the proper format.
ERROR_FORM_INVALID_IPADDRESSThe IP address is invalid.
ERROR_FORM_INVALID_OPTIONThe selected option has been removed.
ERROR_FORM_PATTERN_MISMATCHThis field is not in the correct format.
ERROR_FORM_PROFANITYThe content contains inappropriate language.
ERROR_FORM_REJECTEDThe submission was rejected.
ERROR_FORM_REQUIREDA required field was not supplied.
ERROR_FORM_REQUIRED_EITHERBoth of the required hosted authentication parameters are missing.
ERROR_FORM_REQUIRED_NICKNAMEYou must enter a nickname.
ERROR_FORM_REQUIRES_TRUEA field requires a value of true. (e.g., "You must agree to the terms and conditions.")
ERROR_FORM_RESTRICTEDContent provider's age is too young. (e.g., "Content cannot be accepted from minors under age 13.")
ERROR_FORM_STORAGE_PROVIDER_FAILEDThe uploaded file could not be stored. Try uploading again later.
ERROR_FORM_SUBMITTED_NICKNAMEThis nickname has already been submitted.
ERROR_FORM_TOO_FEWThere must be a minimum number of items contributed for this field.
ERROR_FORM_TOO_HIGHThis field has too many items.
ERROR_FORM_TOO_LONGThe field has too many characters.
ERROR_FORM_TOO_LOWThis field has too few items.
ERROR_FORM_TOO_SHORTThe field doesn't have enough characters.
ERROR_FORM_UPLOAD_IOThe item could not be uploaded. Ensure that it is a valid file type.
ERROR_PARAM_INVALID_LOCALEInvalid locale code
ERROR_PARAM_INVALID_API_KEYInvalid API Key value
ERROR_PARAM_MISSING_USER_IDThis client does not allow unauthenticated submissions. A valid UserId is required.
ERROR_REQUEST_LIMIT_REACHEDRate limiting error, i.e. too many requests per time interval
ERROR_UNKNOWNUnknown error (internal server error, for instance)
ERROR_UNSUPPORTEDFor unsupported features, clients etc.