Upload
Method: POST
URL: https://www.wellcomemat.com/api/media/upload.php
Notes:
-
You can use
media
ormedia_url
in the request BODY. For a direct upload, usemedia
. For a file hosted elsewhere, usemedia_url
. -
To upload a video to a specific user’s account contained under the main account’s key, use
user_id
(recommended for Individual integrators) orunique_id
(recommended for MLS integrators). -
To replace a video, specify either
customid
orhash
in the request BODY, along with #1. At this time, no other fields are accepted when replacing. -
Global distribution is not enabled for API uploads at this time.
Parameters
Key | Type | Description |
---|---|---|
key | text | {{key}} |
secret | text | {{secret}} |
media | file | This field or media_url is required. |
media_url | text | Publicly accessible video URL. This field or media is required. |
video_type | text | Select a video categorization that best describes the video you are uploading. WellcomeMat uses this information for better search engine placement and to better organize videos within your account. Video types also determine the distribution options that are available to you for each kind of video. Must be a valid type id |
user_id | text | This is WellcomeMat’s internal ID for users of our system. |
unique_id | text | This is an ID assigned to users externally from WellcomeMat (Example: agent, member or associate IDs) |
default_state | text | Media Activation Status. Sets this video to active or inactive when finished encoding, overriding the Default Video State in Global Videos Settings. Videos must be active before they can be seen on your channel or search engines.
|
title | text | [Limit 100 characters] |
description | text | [Limit 1500 characters] |
keywords | text | Comma separated by keyword or phrase. Limit 10 keywords(“tags”) or phrases. Suggested Limit 63 characters (including commas) |
customid | text | Custom/Listing ID |
external_link_url | text | Add a link to another location here so viewers can click through to more information about this video. [Limit 256 characters] |
external_link_name | text | Links themselves are often not descriptive enough to entice people to click through. The words you enter here will instigate viewers to click through to another web location where they can find more information about your video. [Limit 256 characters] |
slideshow | text | Based on hundreds of thousands of videos in the WellcomeMat database, we know that full motion videos are exactly twice as engaging (on average) as slideshows and animations. Please mark slideshows and animations properly so that we can better inform your content strategies and allow you to correctly integrate different forms of content on your website(s).
|
bedrooms | text | [Integer or Decimal] |
bathrooms | text | [Integer or Decimal] |
price | text | [Integer or Decimal] |
address | text | [Limit 100 characters] |
city | text | [Limit 50 characters] |
state | text | [Limit 50 characters] |
postal_code | text | [Limit 12 characters] |
disable_email | text | Disable Email Notification
|
distribute | text | Distribute to Service
|
default_photo | text | Default Photo
|
callback_location | text | Callback Location URL When the video file has been received, the media object will be pushed to this URL. NOTE: This is the only callback parameter that is usable on the Embedded Uploader Tool. We expect a 200 response back from the server handshake. The following GET parameters will be appended to the URL: success , error , media , and key .Example Callback: https://yourdomain.com/uploaded-location.php?success=1&media={MediaObject}&error=&key=yourKey |
callback_uploaded | text | Redirect URL The API will redirect the client to this URL upon upload completion. NOTE: If you use callback_uploaded , you cannot use callback_location as callback_uploaded sends a redirect which ends execution. The following GET parameters will be appended to the URL:success error hash key Example Callback: https://yourdomain.com/uploaded-callback.php?success=1&hash=abc123def&error=&key=youKey |
callback_processed | text | Processed Callback URL When the video has been processed, this URL will be called. The following GET parameters will be appended to the URL: hash status_code Example Callback: https://yourdomain.com/processed-callback.php?hash=abc123def&status_code=400 |
Response
type MediaUploadResponse = {
success: 0 | 1;
error: string;
warnings: string | string[];
frontendMessages: string[];
medias: Media[];
};