# Store Listing
API call format
POST /broker/listings //Use token autorization
POST /broker/private/listings //Use Api Key
{
"color": "string",
"imageUrl": "string",
"channel": "string",
"start": 0,
"description": "string",
"end": 0,
"title": "string"
}
Description
This call creates a new video channel.
Precondition
- Authorization token/Api key is needed.
- Mandatory elements (should be specified):
- "channel" - valid channel guid. Take a specific channel guid using Channels List API call.
- "start" - valid Unix timestamp
- "end" - valid Unix timestamp
- "title" - listing title
- Not mandatory (optional):
- "color" - valid color code.
- "imageUrl" - valid image link.
- "description" - listing description.
Postcondition
- On success response code should be 200
- On success message for successful creation in JSON format is returned.
- On failure an error will be returned with the right error code and description.
Example:
[Request] POST https://<base_api_url>/broker/listings
[Request] POST https://<base_api_url>/broker/private/listings
{
"color": "<color_code>",
"imageUrl": "<image_url>",
"channel": "<channel_guid>",
"start": <start_timestamp>,
"description": "<listing_description>",
"end": <start_timestamp>,
"title": "<listing_title>"
}
[Request Headers] {"Content-Type":"application/json","Accept":"application/json","Authorization":"<IdToken>"} //Use token autorization
[Request Headers] {"Content-Type":"application/json","Accept":"application/json","X-Api-Key":"<api_key>"} //Use Api Key
[Response] 200
[Response Headers] {"Content-Type":["application/json"],"Content-Length":["..."],"Connection":["keep-alive"],"Date":["..... GMT"],"x-amzn-RequestId":["....."],....]}
[Response]
{
"status":true,
"data":"Item was created successfully"
}