Users

Registers a new user

$ curl 'http://www.wim.tv:8080/api/public/user/register' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "firstName" : "Jane",
  "birthDate" : "10/02/1971",
  "email" : "jane@cedeo.net",
  "password" : "secr3t",
  "userCode" : "jane",
  "lastName" : "Doe",
  "passwordConfirm" : "secr3t",
  "conditionsAccepted" : true,
  "activationUrl" : "http://www.wim.tv/activate?token=${token}"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

userCode

String

The user code.

* Required.
* Length must be between 4 and 50 inclusive.
* Must match the regular expression [a-zA-Z](\.[a-zA-Z][a-zA-Z0-9])*.
* Must not be blank.

password

String

The password to assign to the user.

* Required.
* Must not be blank.

passwordConfirm

String

Must be set with the same password set in the password field.

* Required.
* Must not be blank.

firstName

String

First name.

* Required.
* Length must be between 0 and 64 inclusive.
* Must not be blank.

lastName

String

Last name.

* Required.
* Length must be between 0 and 64 inclusive.
* Must not be blank.

birthDate

Date

Birth date.

* Required.
* Must not be null.
* The birth date must be at least 18 years before today..

email

String

E-mail.

* Required.
* Length must be between 0 and 128 inclusive.
* Must be a well-formed email address.
* Must not be blank.

conditionsAccepted

Boolean

Whether the user has accepted the service conditions or not.

* Required.
* Must be true.

activationUrl

URI

Template URL to user activation page. The procedure replaces all occurrences of the variable ${token} with the authentication token.

* Must be set only if the client enables the user activation process.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 291

{
  "profile" : {
    "firstName" : "Jane",
    "birthDate" : "10/02/1971",
    "email" : "jane@cedeo.net",
    "lastName" : "Doe"
  },
  "finance" : {
    "billingAddress" : { }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true
  },
  "userCode" : "jane"
}

Response fields

Activates a new user

$ curl 'http://www.wim.tv:8080/api/public/user/activate?token=e1a40ff0-b864-441f-a186-49bf2de635d3' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Request parameters

Parameter Description

token

The activation token.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 291

{
  "profile" : {
    "firstName" : "Jane",
    "birthDate" : "10/02/1971",
    "email" : "jane@cedeo.net",
    "lastName" : "Doe"
  },
  "finance" : {
    "billingAddress" : { }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true
  },
  "userCode" : "jane"
}

Response fields

Reads the logged user

$ curl 'http://www.wim.tv:8080/api/user/me' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 864

{
  "profile" : {
    "firstName" : "John",
    "birthDate" : "26/02/1972",
    "pageTitle" : "WimTV",
    "pageDescription" : "Test API",
    "email" : "john@cedeo.net",
    "facebookUrl" : "http://www.facebook.com/wimtv",
    "twitterContact" : "@wimtv",
    "linkedinUrl" : "http://www.linkedin.com/wimtv",
    "lastName" : "Doe",
    "thumbnailId" : "ac968beb-2e20-4491-880c-e57d573095e8"
  },
  "finance" : {
    "paypalEmail" : "john@cedeo.net",
    "companyName" : "WimLabs",
    "vatNumber" : "10539730019",
    "billingAddress" : {
      "street" : "Piazza De Amicis 121 bis",
      "zipCode" : "10126",
      "city" : "Torino",
      "country" : "IT",
      "countryName" : "Italy",
      "state" : "Torino"
    }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true,
    "livePassword" : "xXx"
  },
  "userCode" : "john"
}

Response fields

Path Type Description

userCode

String

The user code.

profile

Profile

The user profile.

finance

Finance

The user finance profile.

features

Features

The user features setting.

User profile

Path Type Description

firstName

String

First name.

lastName

String

Last name.

birthDate

Date

Birth date.

pageTitle

String

Page title. May be not provided.

pageDescription

String

Page description. May be not provided.

thumbnailId

String

Identifier of the thumbnail assigned to the user. May be not provided.

email

String

E-mail.

facebookUrl

String

Facebook profile URL. May be not provided.

twitterContact

String

Twitter contact. May be not provided.

linkedinUrl

String

LinkedIn profile URL. May be not provided.

User financial profile

Path Type Description

paypalEmail

String

PayPal account. May be not provided.

companyName

String

Company in the name of which the user deals. May be not provided.

taxCode

String

Tax code. May be not provided.

vatNumber

String

VAT number. May be not provided.

billingAddress

Address

Billing address. May be not provided.

User features settings

Path Type Description

transcoderNotifyEnabledField

Boolean

Whether the user would like to receive notifications about the transcoding process.

vodPublic

Boolean

Whether the WimVod items should be visible in public pages. See Searches for WimVod items in public pages.

livePassword

String

The password for WimLive services. May be not provided.

Updates the logged user

$ curl 'http://www.wim.tv:8080/api/user/me' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "profile" : {
    "firstName" : "John",
    "birthDate" : "26/02/1972",
    "pageTitle" : "WimTV",
    "pageDescription" : "Test API",
    "email" : "john@cedeo.net",
    "facebookUrl" : "http://www.facebook.com/wimtv",
    "twitterContact" : "@wimtv",
    "linkedinUrl" : "http://www.linkedin.com/wimtv",
    "lastName" : "Doe",
    "thumbnailId" : "ac968beb-2e20-4491-880c-e57d573095e8"
  },
  "finance" : {
    "paypalEmail" : "john@cedeo.net",
    "companyName" : "WimLabs",
    "vatNumber" : "10539730019",
    "companyConfirm" : true,
    "billingAddress" : {
      "street" : "Piazza De Amicis 121 bis",
      "zipCode" : "10126",
      "city" : "Torino",
      "country" : "IT",
      "state" : "Torino"
    }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true,
    "livePassword" : "xXx"
  }
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

profile

Profile

The user profile.

* Required.
* Must not be null.

finance

Finance

The user finance profile.

* Optional.

features

Features

The user features settings.

* Optional.

User profile

Path Type Description

firstName

String

First name.

* Required.
* Length must be between 0 and 64 inclusive.
* Must not be blank.

lastName

String

Last name.

* Required.
* Length must be between 0 and 64 inclusive.
* Must not be blank.

birthDate

Date

Birth date.

* Required.
* Must not be null.
* The birth date must be at least 18 years before today..

pageTitle

String

Page title.

* Optional.
* Length must be between 0 and 30 inclusive.

pageDescription

String

Page description.

* Optional.
* Length must be between 0 and 140 inclusive.

thumbnailId

String

Identifier of the thumbnail to assign to the user.

* Optional.
* Length must be between 0 and 36 inclusive.

email

String

E-mail.

* Required.
* Length must be between 0 and 128 inclusive.
* Must be a well-formed email address.
* Must not be blank.

facebookUrl

String

Facebook profile URL.

* Optional.
* Length must be between 0 and 255 inclusive.
* Must be a well-formed URL.

twitterContact

String

Twitter contact.

* Optional.
* Length must be between 0 and 128 inclusive.

linkedinUrl

String

LinkedIn profile URL.

* Optional.
* Length must be between 0 and 255 inclusive.
* Must be a well-formed URL.

User financial profile

Path Type Description

paypalEmail

String

PayPal account.

* Must be set if the user would deal financial transactions.
* Length must be between 0 and 128 inclusive.
* Must be a well-formed email address.

companyName

String

Company in the name of which the user would deal.

* Optional.
* Length must be between 0 and 80 inclusive.

companyConfirm

Boolean

Whether the user have the right to deal in the name of the specified company or not.

* Must be true if the user would deal in the name of the specified company.

taxCode

String

Tax code.

* Optional.
* Length must be between 0 and 16 inclusive.

vatNumber

String

VAT number.

* Optional.
* Length must be between 0 and 11 inclusive.

billingAddress

Address

Billing address.

* Optional.

User features settings

Path Type Description

trancoderNotifyEnabled

Boolean

Whether the user would like to receive notifications about the transcoding process.

vodPublic

Boolean

Whether the WimVod items should be visible in public pages. See Searches for WimVod items in public pages.

livePassword

String

The password for WimLive services.

* Must be set if the user would use WimLive services.
* Length must be between 0 and 32 inclusive.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 864

{
  "profile" : {
    "firstName" : "John",
    "birthDate" : "26/02/1972",
    "pageTitle" : "WimTV",
    "pageDescription" : "Test API",
    "email" : "john@cedeo.net",
    "facebookUrl" : "http://www.facebook.com/wimtv",
    "twitterContact" : "@wimtv",
    "linkedinUrl" : "http://www.linkedin.com/wimtv",
    "lastName" : "Doe",
    "thumbnailId" : "ac968beb-2e20-4491-880c-e57d573095e8"
  },
  "finance" : {
    "paypalEmail" : "john@cedeo.net",
    "companyName" : "WimLabs",
    "vatNumber" : "10539730019",
    "billingAddress" : {
      "street" : "Piazza De Amicis 121 bis",
      "zipCode" : "10126",
      "city" : "Torino",
      "country" : "IT",
      "countryName" : "Italy",
      "state" : "Torino"
    }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true,
    "livePassword" : "xXx"
  },
  "userCode" : "john"
}

Response fields

Changes the password of the logged user

$ curl 'http://www.wim.tv:8080/api/user/me/password/update' -i -X POST -H 'Content-Type: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "passwordConfirm" : "secr4t",
  "newPassword" : "secr4t",
  "currentPassword" : "secr3t"
}'

Request fields

Path Type Description

currentPassword

String

The current password.

* Required.
* Must not be blank.

newPassword

String

The new password.

* Required.
* Must not be blank.

passwordConfirm

String

Must be set with the same password set in the newPassword field.

* Required.
* Must not be blank.

Response

HTTP/1.1 204 No Content

Requests a new password for a user

$ curl 'http://www.wim.tv:8080/api/public/user/password/renew' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "userCode" : "john",
  "confirmationUrl" : "http://www.wim.tv/password/renew?token=${token}"
}'

Request fields

Path Type Description

userCode

String

The user code.

* Must be set only if the e-mail is not provided.
* Length must be between 4 and 50 inclusive.
* Must match the regular expression [a-zA-Z](\.[a-zA-Z][a-zA-Z0-9])*.

email

String

E-mail.

* Must be set only if the user code is not provided.
* Length must be between 0 and 128 inclusive.
* Must be a well-formed email address.

confirmationUrl

URI

Template URL to renew password page. The procedure replaces all occurrences of the variable ${token} with the authentication token.

* Required.
* Must not be blank.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 797

{
  "profile" : {
    "firstName" : "John",
    "birthDate" : "26/02/1972",
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "email" : "john@cedeo.net",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "lastName" : "Doe"
  },
  "finance" : {
    "paypalEmail" : "john@paypal.com",
    "vatNumber" : "13291920158",
    "billingAddress" : {
      "street" : "Via Pier Carlo Boggio 59",
      "zipCode" : "10129",
      "city" : "Torino",
      "country" : "IT",
      "countryName" : "Italy",
      "state" : "Torino"
    }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true,
    "livePassword" : "public"
  },
  "userCode" : "john"
}

Response fields

Renews the password of a user

$ curl 'http://www.wim.tv:8080/api/public/user/password/renew?token=991e1c4d-a204-40f2-92e6-ce6ceb8d602d' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request parameters

Parameter Description

token

The renew password token.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 797

{
  "profile" : {
    "firstName" : "John",
    "birthDate" : "26/02/1972",
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "email" : "john@cedeo.net",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "lastName" : "Doe"
  },
  "finance" : {
    "paypalEmail" : "john@paypal.com",
    "vatNumber" : "13291920158",
    "billingAddress" : {
      "street" : "Via Pier Carlo Boggio 59",
      "zipCode" : "10129",
      "city" : "Torino",
      "country" : "IT",
      "countryName" : "Italy",
      "state" : "Torino"
    }
  },
  "features" : {
    "transcoderNotifyEnabled" : false,
    "vodPublic" : true,
    "livePassword" : "public"
  },
  "userCode" : "john"
}

Response fields

Reads the logged user for showing in private pages

$ curl 'http://www.wim.tv:8080/api/user/me/overview' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 427

{
  "paypalEmail" : "john@paypal.com",
  "vatNumber" : "13291920158",
  "livePassword" : "public",
  "userCode" : "john",
  "billingAddress" : {
    "street" : "Via Pier Carlo Boggio 59",
    "zipCode" : "10129",
    "city" : "Torino",
    "country" : "IT",
    "countryName" : "Italy",
    "state" : "Torino"
  },
  "bandPercent" : "0,00",
  "licenseName" : "Basic",
  "daysToExpiration" : 11803,
  "storagePercent" : "0,00"
}

Response fields

Path Type Description

userCode

String

The user code.

licenseName

String

Name of the subscribed license. May be not provided.

daysToExpiration

Number

Number of days until the license expiration. May be not provided.

storagePercent

Percentage

Used storage.

bandPercent

Percentage

Used band.

paypalEmail

String

PayPal account. May be not provided.

taxCode

String

Tax code. May be not provided.

vatNumber

String

VAT number. May be not provided.

billingAddress

Address

Billing address. May be not provided.

livePassword

String

The password for WimLive services. May be not provided.

thumbnailId

String

Identifier of the thumbnail assigned to the user. May be not provided.

Reads a user for showing in his public pages

$ curl 'http://www.wim.tv:8080/api/public/user/john/overview' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/user/{userCode}/overview

Parameter Description

userCode

The user code.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 237

{
  "pageTitle" : "WimLabs",
  "pageDescription" : "Video Communications",
  "facebookUrl" : "http://www.facebook.com/wimlabs",
  "twitterContact" : "@wimlabs",
  "linkedinUrl" : "http://www.linkedin.com/wimlabs",
  "userCode" : "john"
}

Response fields

Path Type Description

userCode

String

The user code.

pageTitle

String

Page title. May be not provided.

pageDescription

String

Page description. May be not provided.

thumbnailId

String

The thumbnail identifier. May be not provided.

facebookUrl

String

Facebook profile URL. May be not provided.

twitterContact

String

Twitter contact. May be not provided.

linkedinUrl

String

LinkedIn profile URL. May be not provided.

$ curl 'http://www.wim.tv:8080/api/public/search/users' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

Query string

The query string applies on the following fields:

  • Username

  • First name

  • Last name

  • Page title

  • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 193

{
  "items" : [ {
    "userCode" : "andrew"
  }, {
    "userCode" : "kotas"
  }, {
    "userCode" : "mariya"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 3,
  "pageCount" : 1
}

Response fields

Item fields

Path Type Description

userCode

String

The user code.

pageTitle

String

Page title. May be not provided.

pageDescription

String

Page description. May be not provided.

thumbnailId

String

The thumbnail identifier. May be not provided.

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Last activity date

  3. Username

Licenses (aka commercial packets)

Pays to subscribe a license

This API acts as the payment API in a 2-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/license/Professional/subscribe' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/license/accepted",
  "cancelUrl" : "http://www.wim.tv/license/rejected"
}'

Path parameters

/api/license/{licenseName}/subscribe

Parameter Description

licenseName

The license name.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 380

{
  "embedded" : false,
  "resource" : {
    "price" : "60,00",
    "storage" : 65,
    "band" : 250,
    "name" : "Professional",
    "dayDuration" : 30,
    "id" : 3,
    "streamingAmount" : 500,
    "support" : "PHONE"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "43c33ccf-5696-4109-adf3-788ba3f15d98",
  "mobile" : false
}

Response fields

Resource fields

Path Type Description

id

Number

License ID.

name

String

License name.

price

Amount

Price.

duration

Number

Duration (days).

storage

Number

Maximum storage (Gb).

band

Number

Maximum band (Gb).

streamingAmount

Number

Approximate amount of time of streaming available (hours).

support

Support

Support mode.

Activates a license checking for the succeeded payment

This API acts as the check payment API in a 2-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/license/Professional/activate' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "trackingId" : "43c33ccf-5696-4109-adf3-788ba3f15d98"
}'

Path parameters

/api/license/{licenseName}/activate

Parameter Description

licenseName

The license name.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 431

{
  "paypalEmail" : "john@paypal.com",
  "vatNumber" : "13291920158",
  "livePassword" : "public",
  "userCode" : "john",
  "billingAddress" : {
    "street" : "Via Pier Carlo Boggio 59",
    "zipCode" : "10129",
    "city" : "Torino",
    "country" : "IT",
    "countryName" : "Italy",
    "state" : "Torino"
  },
  "bandPercent" : "0,00",
  "licenseName" : "Professional",
  "daysToExpiration" : 30,
  "storagePercent" : "0,00"
}

Response fields

Downgrades to the free license

$ curl 'http://www.wim.tv:8080/api/license/downgrade' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 396

{
  "paypalEmail" : "john@paypal.com",
  "vatNumber" : "13291920158",
  "livePassword" : "public",
  "userCode" : "john",
  "billingAddress" : {
    "street" : "Via Pier Carlo Boggio 59",
    "zipCode" : "10129",
    "city" : "Torino",
    "country" : "IT",
    "countryName" : "Italy",
    "state" : "Torino"
  },
  "bandPercent" : "0,00",
  "licenseName" : "Free",
  "storagePercent" : "0,00"
}

Response fields

WimBox

Uploads a new content in WimBox

$ curl 'http://www.wim.tv:8080/api/box' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -H 'X-Wimtv-progressbarId: 3581446a-a278-4c7d-a1c3-6e43cb185476' -F 'file=@sample.mp4' -F 'contentIdentifier=urn:wim:tv:content:762c5940-b1c1-450b-ade0-654ec12bfaeb' -F 'title=Title 1' -F 'description=Description 1' -F 'tag=tag1' -F 'tag=tag2'

Request headers

Name Description

X-Wimtv-progressbarId

The progress bar identifier. You can query the progress bar value through by the /api/progressbar/{progressbarId} API.

* Optional.

Accept

application/json

* Required.

Request parts

Part Type Description

file

Local Path

Content to upload.

* Required.
* Must not be empty.

contentIdentifier

String

The custom content identifier (e.g. a client can hold his own identifiers related to the resources).
We recommend using identifiers in your own namespace (e.g. urn:my:domain:12345678).

* Optional.
* Length must be between 0 and 80 inclusive.
* Must match the regular expression (:[\w-_])*.

title

String

Title.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

thumbnailId

String

Identifier of the thumbnail to assign to the content.

* Optional.
* Length must be between 0 and 36 inclusive.

tag

String

A tag.

* Optional.
* Multiple.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 391

{
  "status" : "READY",
  "valueDate" : "08/09/2017",
  "source" : "UPLOAD",
  "vodCount" : 0,
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "resourceId" : "b4941232-126a-4d92-ada2-e624dae29bf3",
  "contentId" : "urn:wim:tv:content:762c5940-b1c1-450b-ade0-654ec12bfaeb",
  "boxId" : "e821d208-66ac-493e-a506-1e7a955dfb7c",
  "duration" : "7:55"
}

Response fields

Reads a WimBox item

$ curl 'http://www.wim.tv:8080/api/box/e821d208-66ac-493e-a506-1e7a955dfb7c' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/box/{boxId}

Parameter Description

boxId

The WimBox item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 391

{
  "status" : "READY",
  "valueDate" : "08/09/2017",
  "source" : "UPLOAD",
  "vodCount" : 0,
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "resourceId" : "b4941232-126a-4d92-ada2-e624dae29bf3",
  "contentId" : "urn:wim:tv:content:762c5940-b1c1-450b-ade0-654ec12bfaeb",
  "boxId" : "e821d208-66ac-493e-a506-1e7a955dfb7c",
  "duration" : "7:55"
}

Response fields

Path Type Description

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

source

Source

The content source.

valueDate

Date

The created date.

expirationDate

Date

The expiration date. May be not provided.

status

Status

Ingestion status.

vodCount

Number

How many instance of a content are published in WimVod.

marketplaceLicense

Object

License conditions. Provided only for contents acquired from Market Place.

Market Place license conditions

Path Type Description

licenseId

String

The license identifier.

marketplaceId

String

The Market Place item identifier.

issuerCode

String

The issuer code.

licenseType

License Type

License type.

ccType

CC License

Creative Commons License. Provided only if the license type is CREATIVE_COMMONS.

activationPrice

Amount

Activation price. Provided if the license type is SPOT_PRICE, but also PAY_PER_VIEW and REVENUE_SHARING licenses may include an activation price.

pricePerView

Amount

The price per view. Provided only if the license type is PAY_PER_VIEW.

earningPercentage

Percentage

Earning percentage. Provided only if the license type is REVENUE_SHARING.

duration

Number

Duration. Provided only if the license has an expiration.

durationUnit

Duration Unit

Duration unit. Provided only if the license has an expiration.

download

Boolean

Whether the acquirer can download the content.

Updates an existing content in WimBox

$ curl 'http://www.wim.tv:8080/api/box/e821d208-66ac-493e-a506-1e7a955dfb7c' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "title" : "Title 1",
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "thumbnailId" : "626dbc83-f3e9-409f-a0bc-dc622712781f"
}'

Path parameters

/api/box/{boxId}

Parameter Description

boxId

The WimBox item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

title

String

Title.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

thumbnailId

String

Identifier of the thumbnail to assign to the content.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 448

{
  "status" : "READY",
  "valueDate" : "08/09/2017",
  "source" : "UPLOAD",
  "vodCount" : 0,
  "title" : "Title 1",
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "resourceId" : "b4941232-126a-4d92-ada2-e624dae29bf3",
  "contentId" : "urn:wim:tv:content:762c5940-b1c1-450b-ade0-654ec12bfaeb",
  "boxId" : "e821d208-66ac-493e-a506-1e7a955dfb7c",
  "duration" : "7:55",
  "thumbnailId" : "626dbc83-f3e9-409f-a0bc-dc622712781f"
}

Response fields

Deletes an existing content from WimBox

$ curl 'http://www.wim.tv:8080/api/box/e821d208-66ac-493e-a506-1e7a955dfb7c' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/box/{boxId}

Parameter Description

boxId

The WimBox item identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/box/contents' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

source

Source

The content source.

* Optional.

excludeBundleId

String

Identifier of the content bundle containing the items to exclude.

* Optional.
* Length must be between 0 and 36 inclusive.

marketplaceLicense

Object

License conditions.

* May be provided only if the sorce is MARKET_PLACE.

Query string

The query string applies on the following fields:

  • Title

  • Description

  • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1071

{
  "items" : [ {
    "status" : "READY",
    "valueDate" : "08/09/2017",
    "source" : "UPLOAD",
    "vodCount" : 0,
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "14ce3b44-ef7c-40c5-a88e-38f9c1e8d9b1",
    "contentId" : "urn:wim:tv:content:d10c7561-c608-428d-9901-98e81f361d40",
    "boxId" : "85d858c8-d929-4bf9-9960-015e6c77f863",
    "duration" : "5:24",
    "thumbnailId" : "0264d6e5-7812-4416-8517-e889347e573c"
  }, {
    "status" : "READY",
    "valueDate" : "08/09/2017",
    "source" : "UPLOAD",
    "vodCount" : 0,
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "b4b3abf2-2f5f-4a3a-a5c8-762d218ca6dd",
    "contentId" : "urn:wim:tv:content:dad90fc9-6d42-48fe-81ee-e355a2a701e4",
    "boxId" : "1b8f1a03-ce9a-4fe4-b150-babca56d5e95",
    "duration" : "8:32",
    "thumbnailId" : "746cbea2-110d-40c3-abfe-01aba2bde6b9"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Creation date (descending)

Plays a WimBox item

$ curl 'http://www.wim.tv:8080/api/box/f0393b51-4efd-49f8-aa23-7f8b09c1d61c/play' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/box/{boxId}/play

Parameter Description

boxId

The WimBox item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1602

{
  "resource" : {
    "status" : "READY",
    "valueDate" : "08/09/2017",
    "source" : "UPLOAD",
    "vodCount" : 0,
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "cd284801-c2dd-4ac5-a567-a8b204ce7f4e",
    "contentId" : "urn:wim:tv:content:e12586a9-4d78-47bc-b996-f970595576f1",
    "boxId" : "f0393b51-4efd-49f8-aa23-7f8b09c1d61c",
    "duration" : "8:53",
    "thumbnailId" : "1d5844d6-1ae6-4361-bb1f-e4875864dde8"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=23882353-dcb7-47bb-a920-adc8bc987741",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-83c3a856-be54-4dc9-a0c2-8718bf3be18d-tr.mp4/playlist.m3u8?token=23882353-dcb7-47bb-a920-adc8bc987741"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-83c3a856-be54-4dc9-a0c2-8718bf3be18d-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=23882353-dcb7-47bb-a920-adc8bc987741",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-83c3a856-be54-4dc9-a0c2-8718bf3be18d-tr.mp4?token=23882353-dcb7-47bb-a920-adc8bc987741"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-83c3a856-be54-4dc9-a0c2-8718bf3be18d-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=23882353-dcb7-47bb-a920-adc8bc987741",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-83c3a856-be54-4dc9-a0c2-8718bf3be18d-tr.mp4?token=23882353-dcb7-47bb-a920-adc8bc987741"
}

Response fields

Resource fields

Requests a token to authorize the downloading of a content

$ curl 'http://www.wim.tv:8080/api/content/urn:wim:tv:content:762c5940-b1c1-450b-ade0-654ec12bfaeb/download' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/content/{contentId}/download

Parameter Description

contentId

The content identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 54

{
  "token" : "82c110e0-6319-46a5-8d24-b0e8cceb0900"
}

Response fields

Path Type Description

token

String

The authorization token. You should use the token with the API /download/content/{contentId}.

WimVod

Publishes a content in WimVod

$ curl 'http://www.wim.tv:8080/api/box/ff077e09-c3d3-406c-98ec-1b8fc481b0e3/vod' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "licenseType" : "FREE",
  "public" : false
}'

Path parameters

/api/box/{boxId}/vod

Parameter Description

boxId

The WimBox item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

licenseType

License Type

License type.

* Required.
* Must not be null.

ccType

CC License

Creative Commons license.

* Must be set only if the license type is CREATIVE_COMMONS.

pricePerView

Amount

Price per view.

* Must be set only if the license type is PAY_PER_VIEW.
* Must be at least 0 (inclusive=false).

bundleId

String

The content bundle identifier.

* Must be set only if the license type is BUNDLE.
* Length must be between 0 and 36 inclusive.

public

Boolean

Whether the WimVod item has to be visible in public pages or not. See Searches for WimVod items in public pages.

* Optional.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 495

{
  "valueDate" : "08/09/2017",
  "licenseType" : "FREE",
  "vodId" : "9d93065a-d128-4b3b-9dd7-88e549a78922",
  "public" : false,
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "773955b6-79c2-4430-a6b9-1ad9a3c18e07",
  "contentId" : "urn:wim:tv:content:b6dd0fe4-e5c6-4ee5-a322-53c07b893cf6",
  "boxId" : "ff077e09-c3d3-406c-98ec-1b8fc481b0e3",
  "duration" : "8:05",
  "thumbnailId" : "374f18f3-eac0-4e8b-9215-9bc7e7c41a90"
}

Response fields

Reads a WimVod item in private pages

$ curl 'http://www.wim.tv:8080/api/vod/9d93065a-d128-4b3b-9dd7-88e549a78922' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/vod/{vodId}

Parameter Description

vodId

The WimVod item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 495

{
  "valueDate" : "08/09/2017",
  "licenseType" : "FREE",
  "vodId" : "9d93065a-d128-4b3b-9dd7-88e549a78922",
  "public" : false,
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "773955b6-79c2-4430-a6b9-1ad9a3c18e07",
  "contentId" : "urn:wim:tv:content:b6dd0fe4-e5c6-4ee5-a322-53c07b893cf6",
  "boxId" : "ff077e09-c3d3-406c-98ec-1b8fc481b0e3",
  "duration" : "8:05",
  "thumbnailId" : "374f18f3-eac0-4e8b-9215-9bc7e7c41a90"
}

Response fields

Path Type Description

vodId

String

The WimVod item identifier.

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

licenseType

License Type

License type.

ccType

CC License

Creative Commons license. Provided only if the license type is CREATIVE_COMMONS.

pricePerView

Amount

Price per view. Provided only if the license type is PAY_PER_VIEW.

bundle

Content Bundle

Content bundle. Provided only if the license type is BUNDLE.

valueDate

Date

The created date.

expirationDate

Date

Expiration date. May be not provided.

public

Boolean

Whether the WimVod item is visible in public pages or not. See Searches for WimVod items in public pages.

Reads a WimVod item in public pages

$ curl 'http://www.wim.tv:8080/api/public/vod/8df05626-a834-4308-8fa6-7e9ae79542d7' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/vod/{vodId}

Parameter Description

vodId

The item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 749

{
  "licenseType" : "PAY_PER_VIEW",
  "vodId" : "8df05626-a834-4308-8fa6-7e9ae79542d7",
  "publisher" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  },
  "title" : "Title 3",
  "description" : "Description 3",
  "tags" : [ "tag30", "tag31", "tag32" ],
  "resourceId" : "d5266ff8-4260-4c15-9323-339213148180",
  "contentId" : "urn:wim:tv:content:f48d454e-4e97-4ff6-8003-5cf9dcb1a59c",
  "boxId" : "a2f6c41d-b1e3-48dd-ae6a-0186c2f44c98",
  "duration" : "5:16",
  "thumbnailId" : "5f6b04e6-392d-48bd-b893-63caaadaf1dd",
  "pricePerView" : "1,20"
}

Response fields

Path Type Description

vodId

String

The WimVod item identifier.

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

licenseType

License Type

License type.

ccType

CC License

Creative Commons license. Provided only if the license type is CREATIVE_COMMONS.

pricePerView

Amount

Price per view. Provided only if the license type is PAY_PER_VIEW.

bundle

Content Bundle

Content bundle. Provided only if the license type is BUNDLE.

publisher

User

The publisher.

Updates an existing WimVod item

$ curl 'http://www.wim.tv:8080/api/vod/9d93065a-d128-4b3b-9dd7-88e549a78922' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "licenseType" : "CREATIVE_COMMONS",
  "ccType" : "BY_NC_SA",
  "public" : true
}'

Path parameters

/api/vod/{vodId}

Parameter Description

vodId

The WimVod item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 531

{
  "valueDate" : "08/09/2017",
  "licenseType" : "CREATIVE_COMMONS",
  "vodId" : "9d93065a-d128-4b3b-9dd7-88e549a78922",
  "public" : true,
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "773955b6-79c2-4430-a6b9-1ad9a3c18e07",
  "contentId" : "urn:wim:tv:content:b6dd0fe4-e5c6-4ee5-a322-53c07b893cf6",
  "boxId" : "ff077e09-c3d3-406c-98ec-1b8fc481b0e3",
  "duration" : "8:05",
  "thumbnailId" : "374f18f3-eac0-4e8b-9215-9bc7e7c41a90",
  "ccType" : "BY_NC_SA"
}

Response fields

Deletes an existing WimVod item

$ curl 'http://www.wim.tv:8080/api/vod/9d93065a-d128-4b3b-9dd7-88e549a78922' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/vod/{vodId}

Parameter Description

vodId

The WimVod item identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/vod/contents' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

public

Boolean

Whether the contents have to be visible in public pages.

* Optional.

conditions

Object

Publishing conditions.

* Optional.

Query string

The query string applies on the following fields:

  • Content

    • Title

    • Description

    • Tags

  • Content bundle (boost: 0.7; if not provided as filter)

    • Name

    • Description

    • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2988

{
  "items" : [ {
    "valueDate" : "08/09/2017",
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "8f467f97-43cf-4c89-aff9-0ad467394022",
    "public" : true,
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "e7f49028-07d9-4d2e-8ddd-47dab97678b8",
    "contentId" : "urn:wim:tv:content:06eafbe9-2e63-4830-9a18-561e96ef0fdc",
    "boxId" : "a949a397-8472-4adc-bd36-66b0b1125b99",
    "duration" : "8:16",
    "thumbnailId" : "bd47fc73-82cf-4fdf-94ab-c98a9f90a8e4",
    "pricePerView" : "1,20"
  }, {
    "valueDate" : "08/09/2017",
    "licenseType" : "CREATIVE_COMMONS",
    "vodId" : "c51ff8e6-0c2b-4997-9120-729451dbe7f5",
    "public" : true,
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "9f8eca8d-b607-4616-974e-5141819250a0",
    "contentId" : "urn:wim:tv:content:63f1f163-2283-4bea-8c59-0c4e1caea4d3",
    "boxId" : "9af1f4f4-b777-48a0-9d16-57907e7eeded",
    "duration" : "5:44",
    "thumbnailId" : "c35b67bc-837a-47c5-9eea-278a7940927c",
    "ccType" : "BY_SA"
  }, {
    "valueDate" : "08/09/2017",
    "licenseType" : "CONTENT_BUNDLE",
    "vodId" : "1633d8ac-bcba-401f-8290-418ccd239e5a",
    "public" : true,
    "bundle" : {
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "itemCount" : 2,
      "duration" : 1,
      "thumbnailId" : "45e799fe-5e48-458a-96f3-320bbab71b91",
      "durationUnit" : "MONTHS",
      "price" : "2,00",
      "bundleId" : "1686cc93-e48b-4725-a418-76ba7896b1ba",
      "name" : "Name 2"
    },
    "title" : "Title 7",
    "description" : "Description 7",
    "tags" : [ "tag70", "tag71", "tag72" ],
    "resourceId" : "54947138-90b4-45e4-842f-de2ef4e80b89",
    "contentId" : "urn:wim:tv:content:5dd763ab-2d1b-445c-9aca-c96ffdefb19c",
    "boxId" : "1b0d5814-1ec8-4534-9b9d-15e9eaf83214",
    "duration" : "9:00",
    "thumbnailId" : "babaf646-ae74-412d-b84c-7db336ce92b3"
  }, {
    "valueDate" : "08/09/2017",
    "licenseType" : "CONTENT_BUNDLE",
    "vodId" : "3d983e1a-6ca3-408d-90b4-d9e712c2cdee",
    "public" : true,
    "bundle" : {
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "itemCount" : 2,
      "duration" : 1,
      "thumbnailId" : "45e799fe-5e48-458a-96f3-320bbab71b91",
      "durationUnit" : "MONTHS",
      "price" : "2,00",
      "bundleId" : "1686cc93-e48b-4725-a418-76ba7896b1ba",
      "name" : "Name 2"
    },
    "title" : "Title 6",
    "description" : "Description 6",
    "tags" : [ "tag60", "tag61", "tag62" ],
    "resourceId" : "2f268a35-3ab4-44bd-9b89-22978a8e9cbd",
    "contentId" : "urn:wim:tv:content:4082d3be-d2c5-47d4-a1b4-1ec1d5ff3088",
    "boxId" : "6c9b9805-fd3f-4727-a2b4-2f0268e4709f",
    "duration" : "5:03",
    "thumbnailId" : "a049c505-9650-41c6-a633-ced4bc02e7de"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 4,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Searches for WimVod items in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/vod/contents' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'
If the public field of a WimVod item is set to false, that content is excluded from the search.
If the vodPublic field of the features section of a user is set to false, all contents published by that user are excluded from the search.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

conditions

Object

Publishing conditions.

* Optional.

Query string

The query string applies on the following fields:

  • Content

    • Title

    • Description

    • Tags

  • Content bundle (boost: 0.7; if not provided as filter)

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.5; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 4518

{
  "items" : [ {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "8df05626-a834-4308-8fa6-7e9ae79542d7",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "d5266ff8-4260-4c15-9323-339213148180",
    "contentId" : "urn:wim:tv:content:f48d454e-4e97-4ff6-8003-5cf9dcb1a59c",
    "boxId" : "a2f6c41d-b1e3-48dd-ae6a-0186c2f44c98",
    "duration" : "5:16",
    "thumbnailId" : "5f6b04e6-392d-48bd-b893-63caaadaf1dd",
    "pricePerView" : "1,20"
  }, {
    "licenseType" : "CREATIVE_COMMONS",
    "vodId" : "d20ce571-5399-4f38-9deb-f528c502fc3d",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "e6a136ac-cc84-4055-b42e-2b990989d04e",
    "contentId" : "urn:wim:tv:content:db1dd514-fbb8-41ab-9393-064f0356f72b",
    "boxId" : "784995f2-a070-497d-99cf-7db30b43221a",
    "duration" : "9:24",
    "thumbnailId" : "21d0748d-ff02-4dde-a7ea-9f7f29a32b08",
    "ccType" : "BY_SA"
  }, {
    "licenseType" : "CONTENT_BUNDLE",
    "vodId" : "2290de20-dfc6-49cc-9dd7-0b48dfc9face",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "bundle" : {
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "itemCount" : 2,
      "duration" : 1,
      "thumbnailId" : "cd7b966e-79bd-455d-b816-863392666f15",
      "durationUnit" : "MONTHS",
      "price" : "2,00",
      "bundleId" : "4e316132-520a-400a-88f6-335fecb87a0f",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Name 2"
    },
    "title" : "Title 7",
    "description" : "Description 7",
    "tags" : [ "tag70", "tag71", "tag72" ],
    "resourceId" : "5e46b04b-ee34-49e4-936e-54479b629508",
    "contentId" : "urn:wim:tv:content:fbddf0f8-b4de-413c-bffd-166fb47f15a8",
    "boxId" : "bc90a75b-9e49-4e63-aeb4-ec30c7548ea2",
    "duration" : "9:53",
    "thumbnailId" : "871bf60b-8c23-490e-a2f5-959aae84ec51"
  }, {
    "licenseType" : "CONTENT_BUNDLE",
    "vodId" : "ded2f404-4a41-4bbd-a2c4-f88d3ec0cfaf",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "bundle" : {
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "itemCount" : 2,
      "duration" : 1,
      "thumbnailId" : "cd7b966e-79bd-455d-b816-863392666f15",
      "durationUnit" : "MONTHS",
      "price" : "2,00",
      "bundleId" : "4e316132-520a-400a-88f6-335fecb87a0f",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Name 2"
    },
    "title" : "Title 6",
    "description" : "Description 6",
    "tags" : [ "tag60", "tag61", "tag62" ],
    "resourceId" : "b879a6a8-d465-4e15-86e1-2a5526b2d99e",
    "contentId" : "urn:wim:tv:content:8f20225b-4b2e-429a-a1a3-176de7678c91",
    "boxId" : "27c146dc-50e5-424a-93df-8de99e1b5261",
    "duration" : "6:13",
    "thumbnailId" : "4d0a45ba-a949-4c92-967f-edbdacd0a744"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 4,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Path Type Description

licenseType

License Type

License type.

* Must be provided if ccType or bundleId are provided.

ccType

CC License

Creative Commons license.

* May be provided only if the license type is CREATIVE_COMMONS.

bundleId

String

The content bundle identifier.

* May be provided only if the license type is CONTENT_BUNDLE.
* Length must be between 0 and 36 inclusive.

Plays a WimVod item

This API acts as the transaction API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/vod/4d7b28a7-5069-4807-9dd0-39f121094491/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Path parameters

/api/vod/{vodId}/play

Parameter Description

vodId

The WimVod item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

If the content is free, you should not provide none of the request fields, otherwise you must provide the parameters to check for the succeeded payment.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1868

{
  "resource" : {
    "licenseType" : "FREE",
    "vodId" : "4d7b28a7-5069-4807-9dd0-39f121094491",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "a01002e6-34f2-4c7c-9b68-9bea1b6d2583",
    "contentId" : "urn:wim:tv:content:6fc75aaf-ff24-4fa5-913d-b7190aa303c2",
    "boxId" : "db9c34c2-af1a-4e62-91de-b3e6b9d3b4a1",
    "duration" : "6:22",
    "thumbnailId" : "5668a479-249e-4468-8a2d-6a9b2fce828c"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4/playlist.m3u8?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
}

Response fields

If the content is free or the payment has succeeded, the response includes the parameters to setup your player, otherwise the response notifies that you have to pay.

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/vod/1ea056f2-ed07-4d50-afc6-ef6cf2f76dc4/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Pays to play a WimVod item

This API acts as the payment API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/vod/4c0eed29-097c-4714-9d64-1732382f8e86/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/vod/play",
  "cancelUrl" : "http://www.wim.tv/vod/rejected"
}'

Path parameters

/api/vod/{vodId}/pay

Parameter Description

vodId

The WimVod item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 983

{
  "embedded" : false,
  "resource" : {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "4c0eed29-097c-4714-9d64-1732382f8e86",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "5ce347ce-faa1-4503-b8df-1f0f8f541d00",
    "contentId" : "urn:wim:tv:content:f384d35f-3251-4610-8162-5f4049b2c0d7",
    "boxId" : "da763194-e09a-4002-95b8-ab20cf4fd301",
    "duration" : "7:04",
    "thumbnailId" : "ea582893-e008-4343-b4dd-9a800aadd68c",
    "pricePerView" : "1,20"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "146b85b9-c321-4956-9ee1-1c633e26c7ff",
  "mobile" : false
}

Response fields

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/vod/81562951-68f9-4008-b43f-8a0e2a6595d8/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/vod/play",
  "cancelUrl" : "http://www.wim.tv/vod/rejected"
}'

Previews a WimVod item

You can offer a free preview of a content (15 seconds) to your public.

$ curl 'http://www.wim.tv:8080/api/public/vod/81562951-68f9-4008-b43f-8a0e2a6595d8/preview' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/vod/{vodId}/preview

Parameter Description

vodId

The WimVod item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1983

{
  "resource" : {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "81562951-68f9-4008-b43f-8a0e2a6595d8",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "a3e57c9e-c4f4-452e-b051-9d4df9dd1091",
    "contentId" : "urn:wim:tv:content:a6eee27c-ba7a-4de5-a3df-5f13d8b3c405",
    "boxId" : "fdca50bc-f938-4316-a394-cb8ae32c9d9a",
    "duration" : "9:42",
    "thumbnailId" : "5f904aea-4e1e-404c-982b-04b882e318e4",
    "pricePerView" : "1,20"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-8fed0d3f-1115-472a-b4a9-78f18ffa9395-tr.mp4/playlist.m3u8?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-8fed0d3f-1115-472a-b4a9-78f18ffa9395-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-8fed0d3f-1115-472a-b4a9-78f18ffa9395-tr.mp4?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-8fed0d3f-1115-472a-b4a9-78f18ffa9395-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-8fed0d3f-1115-472a-b4a9-78f18ffa9395-tr.mp4?token=bf0ae205-5e05-4a8a-b2dc-eceaf5570dc4&type=preview"
}

Response fields

Resource fields

Content bundles

See also the WimBundle APIs.

Creates a new content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "duration" : 1,
  "thumbnailId" : "1aeb85cb-1fef-43b7-b0ee-37a30924fb26",
  "durationUnit" : "MONTHS",
  "price" : "5,20",
  "name" : "Bundle 1"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

name

String

Name.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

price

Amount

Price.

* Required.
* Must be at least 0 (inclusive=false).
* Must not be null.

duration

Number

Duration.

* Required.
* Must be at least 1.

durationUnit

Duration Unit

Duration unit.

* Required.
* Must not be null.

thumbnailId

String

Identifier of the thumbnail to assign to the content bundle.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 290

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "itemCount" : 0,
  "duration" : 1,
  "thumbnailId" : "1aeb85cb-1fef-43b7-b0ee-37a30924fb26",
  "durationUnit" : "MONTHS",
  "price" : "5,20",
  "bundleId" : "a790770d-1168-44aa-a186-60c70505df8a",
  "name" : "Bundle 1"
}

Response fields

Reads a content bundle in private pages

$ curl 'http://www.wim.tv:8080/api/contentbundle/a790770d-1168-44aa-a186-60c70505df8a' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/contentbundle/{bundleId}

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 290

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "itemCount" : 0,
  "duration" : 1,
  "thumbnailId" : "1aeb85cb-1fef-43b7-b0ee-37a30924fb26",
  "durationUnit" : "MONTHS",
  "price" : "5,20",
  "bundleId" : "a790770d-1168-44aa-a186-60c70505df8a",
  "name" : "Bundle 1"
}

Response fields

Path Type Description

bundleId

String

The content bundle identifier.

name

String

The name.

description

String

The description. May be not provided.

price

Amount

The price.

duration

Number

The duration.

durationUnit

Duration Unit

Duration unit.

itemCount

Number

How many items are included in the content bundle.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads a content bundle in public pages

$ curl 'http://www.wim.tv:8080/api/public/contentbundle/19bae07a-d47a-4967-acad-55f06f314509' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/contentbundle/{bundleId}

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 568

{
  "description" : "Description 3",
  "tags" : [ "tag30", "tag31", "tag32" ],
  "itemCount" : 2,
  "duration" : 1,
  "thumbnailId" : "51976f8e-f111-4778-935c-2ff0bdd2372c",
  "durationUnit" : "MONTHS",
  "price" : "2,00",
  "bundleId" : "19bae07a-d47a-4967-acad-55f06f314509",
  "publisher" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  },
  "name" : "Name 3"
}

Response fields

Path Type Description

bundleId

String

The content bundle identifier.

name

String

The name.

description

String

The description. May be not provided.

price

Amount

The price.

duration

Number

The duration.

durationUnit

Duration Unit

Duration unit.

publisher

User

The publisher.

itemCount

Number

How many items are included in the content bundle.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle/a790770d-1168-44aa-a186-60c70505df8a' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "duration" : 40,
  "thumbnailId" : "1aeb85cb-1fef-43b7-b0ee-37a30924fb26",
  "durationUnit" : "DAYS",
  "price" : "5,45",
  "name" : "Bundle 1"
}'

Path parameters

/api/contentbundle/{bundleId}

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 288

{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "itemCount" : 0,
  "duration" : 40,
  "thumbnailId" : "1aeb85cb-1fef-43b7-b0ee-37a30924fb26",
  "durationUnit" : "DAYS",
  "price" : "5,45",
  "bundleId" : "a790770d-1168-44aa-a186-60c70505df8a",
  "name" : "Bundle 1"
}

Response fields

Deletes an existing content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle/a790770d-1168-44aa-a186-60c70505df8a' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/contentbundle/{bundleId}

Parameter Description

bundleId

The content bundle identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/contentbundles' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

Query string

The query string applies on the following fields:

  • Name

  • Description

  • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 737

{
  "items" : [ {
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "itemCount" : 0,
    "duration" : 1,
    "thumbnailId" : "a37a2bc2-855e-4cf0-998e-d33751dce26c",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9b5a1b5a-d35f-402c-ae3d-265bdb3d55d0",
    "name" : "Name 3"
  }, {
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "itemCount" : 0,
    "duration" : 1,
    "thumbnailId" : "f31dddb7-5cce-4022-829f-e11ce8283bdd",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "4742e18b-0a76-4408-928f-164c3c01c38d",
    "name" : "Name 2"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Searches for content bundles in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/contentbundles' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

Query string

The query string applies on the following fields:

  • Content bundle

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.7; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1307

{
  "items" : [ {
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "itemCount" : 2,
    "duration" : 1,
    "thumbnailId" : "51976f8e-f111-4778-935c-2ff0bdd2372c",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "19bae07a-d47a-4967-acad-55f06f314509",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Name 3"
  }, {
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "itemCount" : 2,
    "duration" : 1,
    "thumbnailId" : "967ad3f4-929b-4033-8137-134aff663bd9",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9b011dff-53c9-444c-a8c3-5c8657626b4c",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Name 2"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Pays to subscribe a content bundle

This API acts as the payment API in a 2-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/contentbundle/64fa1083-f9c9-4d67-891b-d40754c30cfd/subscribe' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/contentbundle/accepted",
  "cancelUrl" : "http://www.wim.tv/contentbundle/rejected"
}'

Path parameters

/api/contentbundle/{bundleId}/subscribe

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 798

{
  "embedded" : false,
  "resource" : {
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "itemCount" : 0,
    "duration" : 1,
    "thumbnailId" : "fabea762-d011-48ef-890d-b49af68ee7e0",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "64fa1083-f9c9-4d67-891b-d40754c30cfd",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Name 1"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "3cae1013-8ab8-4049-b607-08679c44ae89",
  "mobile" : false
}

Response fields

Resource fields

Activates a content bundle subscription checking for the succeeded payment

This API acts as the check payment API in a 2-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/contentbundle/64fa1083-f9c9-4d67-891b-d40754c30cfd/activate' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "trackingId" : "3cae1013-8ab8-4049-b607-08679c44ae89"
}'

Path parameters

/api/contentbundle/{bundleId}/activate

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 568

{
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "itemCount" : 0,
  "duration" : 1,
  "thumbnailId" : "fabea762-d011-48ef-890d-b49af68ee7e0",
  "durationUnit" : "MONTHS",
  "price" : "2,00",
  "bundleId" : "64fa1083-f9c9-4d67-891b-d40754c30cfd",
  "publisher" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  },
  "name" : "Name 1"
}

Response fields

$ curl 'http://www.wim.tv:8080/api/search/contentbundle/subscriptions' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "expiredIncluded" : false,
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

bundleId

String

The content bundle identifier.

* Optional.
* Length must be between 0 and 36 inclusive.

expiredIncluded

Boolean

Whether the expired subscriptions should be included.

* Optional.

Query string

The query string applies on the following fields:

  • Content bundle

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.7)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 890

{
  "items" : [ {
    "valueDate" : "08/09/2017",
    "expirationDate" : "08/10/2017",
    "bundle" : {
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "itemCount" : 0,
      "duration" : 1,
      "thumbnailId" : "fabea762-d011-48ef-890d-b49af68ee7e0",
      "durationUnit" : "MONTHS",
      "price" : "2,00",
      "bundleId" : "64fa1083-f9c9-4d67-891b-d40754c30cfd",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Name 1"
    },
    "subscriptionId" : "1a300abe-c16d-476b-a43e-85de707e11a7"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 1,
  "pageCount" : 1
}

Response fields

Item fields

Path Type Description

subscriptionId

String

Subscription identifier.

bundle

Object

The content bundle.

valueDate

Date

Subscription date.

expirationDate

Date

Subscription expiration.

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Subscription date

  3. Subscription expiration

  4. Name

WimBundle

By using the common APIs for WimVod and Content bundles, a content bundle is just like a label with a price and an expiration that you can stick on a set of contents, that is no order is defined for the contents in the bundle.
By using the WimBundle APIs, a content bundle is an ordered list of contents, instead.

Reads content bundle in private pages

$ curl 'http://www.wim.tv:8080/api/contentbundle/9326e5e6-2da0-48df-a872-545e0ae96974/items' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/contentbundle/{bundleId}/items

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1348

{
  "items" : [ {
    "itemCode" : "b56a03d6-cdbc-4c77-a5be-662d5772cd73",
    "vodId" : "cf6e7b23-a895-4242-b2a7-5fcf4757e9e3",
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "00633b8e-4a64-4997-8015-3ed315407776",
    "contentId" : "urn:wim:tv:content:7717b0ac-17ff-4fb2-adc7-2a505cdf432a",
    "boxId" : "109fd6e1-ee36-4061-82bd-d4dd98bf4972",
    "duration" : "5:41",
    "thumbnailId" : "beea1320-635f-447f-8948-3cb3fdf09d5f"
  }, {
    "itemCode" : "bf81a3be-0132-4744-8c17-e4175f4aefba",
    "vodId" : "235ee67f-d1ba-426d-8485-80519f743569",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "363913a9-c985-4867-af10-438af73e1d59",
    "contentId" : "urn:wim:tv:content:aad4126e-6d3d-4ceb-b46b-3a43be447f5b",
    "boxId" : "467aeb70-3b14-4ff8-9b26-ee84790f11f8",
    "duration" : "5:55",
    "thumbnailId" : "8ab5e438-a9ab-4f21-82fb-a7ce7c084616"
  } ],
  "bundle" : {
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "itemCount" : 2,
    "duration" : 1,
    "thumbnailId" : "94d8a6f7-571d-4633-8e7e-680a18b72a85",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9326e5e6-2da0-48df-a872-545e0ae96974",
    "name" : "Name 1"
  }
}

Response fields

Path Type Description

bundle

Content Bundle

Content bundle.

items

Array

The items.

Item fields

Path Type Description

itemCode

String

The content bundle item identifier.

vodId

String

The WimVod item identifier.

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads content bundle in public pages

$ curl 'http://www.wim.tv:8080/api/public/contentbundle/19bae07a-d47a-4967-acad-55f06f314509/items' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/contentbundle/{bundleId}/items

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1633

{
  "items" : [ {
    "itemCode" : "f74d3445-fc03-40f7-96be-f6c1aed5997c",
    "vodId" : "0e03ca24-604b-477a-8c49-78d812f25d15",
    "title" : "Title 5",
    "description" : "Description 5",
    "tags" : [ "tag50", "tag51", "tag52" ],
    "resourceId" : "a60d8d47-0b42-4dbe-86ae-87b843c1696b",
    "contentId" : "urn:wim:tv:content:f47f0d03-a666-4ca4-a5b2-f496a8731bbb",
    "boxId" : "4c05a033-189b-4378-9795-33a172981264",
    "duration" : "5:08",
    "thumbnailId" : "65b97af9-9a6c-4301-8b34-fa907ad73baf"
  }, {
    "itemCode" : "796cfa3c-3fea-4065-9210-385cea2797a2",
    "vodId" : "7503cc90-99b0-488b-8897-3f71c1682245",
    "title" : "Title 6",
    "description" : "Description 6",
    "tags" : [ "tag60", "tag61", "tag62" ],
    "resourceId" : "fb9b0ce7-cdc7-4d1e-880f-0ba8f476755c",
    "contentId" : "urn:wim:tv:content:2e5a1916-d07c-4517-bf5c-77af14a8cb69",
    "boxId" : "b374e669-ff3f-43dc-84ad-8c78eba47013",
    "duration" : "6:05",
    "thumbnailId" : "74546d7b-baeb-4ca4-ae9a-1ea73e44376a"
  } ],
  "bundle" : {
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "itemCount" : 2,
    "duration" : 1,
    "thumbnailId" : "51976f8e-f111-4778-935c-2ff0bdd2372c",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "19bae07a-d47a-4967-acad-55f06f314509",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Name 3"
  }
}

Response fields

Path Type Description

bundle

Content Bundle

Content bundle.

items

Array

The items.

Inserts one or more contents in a content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle/9326e5e6-2da0-48df-a872-545e0ae96974/items/insert' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "sourceItems" : [ {
    "boxId" : "018f207b-7d12-46e8-865d-c385c82b2037"
  }, {
    "boxId" : "3d6f403c-48a4-4747-b3d4-e1ae659c66cb"
  } ],
  "index" : 1
}'

Path parameters

/api/contentbundle/{bundleId}/items/insert

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Insertion index.

* Required.
* Must be at least 0.

sourceItems

Array

Contents to insert.

* Required.
* Must not be null.

Content source

Path Type Description

boxId

String

The WimBox item identifier.

* Required.
* Length must be between 0 and 36 inclusive.
* Must not be blank.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2344

{
  "items" : [ {
    "itemCode" : "b56a03d6-cdbc-4c77-a5be-662d5772cd73",
    "vodId" : "cf6e7b23-a895-4242-b2a7-5fcf4757e9e3",
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "00633b8e-4a64-4997-8015-3ed315407776",
    "contentId" : "urn:wim:tv:content:7717b0ac-17ff-4fb2-adc7-2a505cdf432a",
    "boxId" : "109fd6e1-ee36-4061-82bd-d4dd98bf4972",
    "duration" : "5:41",
    "thumbnailId" : "beea1320-635f-447f-8948-3cb3fdf09d5f"
  }, {
    "itemCode" : "29b0bfa2-5af5-45b4-b3cc-cc7025061816",
    "vodId" : "1f74e1cf-abad-48b4-9568-79e998670105",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "606d076f-9166-4780-9bfa-7aaa22fca861",
    "contentId" : "urn:wim:tv:content:a8f1b96e-ae05-44a5-bd29-fee58d7b23c2",
    "boxId" : "018f207b-7d12-46e8-865d-c385c82b2037",
    "duration" : "6:58",
    "thumbnailId" : "3f72f378-d7ae-4d27-8c20-08f3a9827963"
  }, {
    "itemCode" : "96a06cc3-33da-4faf-8113-20eed2e5f6ed",
    "vodId" : "a923ddb0-c99a-4400-849c-cfd79e8c8020",
    "title" : "Title 4",
    "description" : "Description 4",
    "tags" : [ "tag40", "tag41", "tag42" ],
    "resourceId" : "e7c81a1b-af3d-43c8-9630-17b1e5371b6e",
    "contentId" : "urn:wim:tv:content:28110620-0b1d-4936-999b-c9f58d2b606f",
    "boxId" : "3d6f403c-48a4-4747-b3d4-e1ae659c66cb",
    "duration" : "8:58",
    "thumbnailId" : "97205575-eb46-4005-a2b7-698054732284"
  }, {
    "itemCode" : "bf81a3be-0132-4744-8c17-e4175f4aefba",
    "vodId" : "235ee67f-d1ba-426d-8485-80519f743569",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "363913a9-c985-4867-af10-438af73e1d59",
    "contentId" : "urn:wim:tv:content:aad4126e-6d3d-4ceb-b46b-3a43be447f5b",
    "boxId" : "467aeb70-3b14-4ff8-9b26-ee84790f11f8",
    "duration" : "5:55",
    "thumbnailId" : "8ab5e438-a9ab-4f21-82fb-a7ce7c084616"
  } ],
  "bundle" : {
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "itemCount" : 4,
    "duration" : 1,
    "thumbnailId" : "94d8a6f7-571d-4633-8e7e-680a18b72a85",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9326e5e6-2da0-48df-a872-545e0ae96974",
    "name" : "Name 1"
  }
}

Response fields

Moves a content in a content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle/9326e5e6-2da0-48df-a872-545e0ae96974/items/move' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "fromIndex" : 1,
  "toIndex" : 3
}'

Path parameters

/api/contentbundle/{bundleId}/items/move

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

fromIndex

Number

Index of the content to move.

* Required.
* Must be at least 0.

toIndex

Number

Index of the content before of which insert the moved content.

* Required.
* Must be at least 0.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2344

{
  "items" : [ {
    "itemCode" : "b56a03d6-cdbc-4c77-a5be-662d5772cd73",
    "vodId" : "cf6e7b23-a895-4242-b2a7-5fcf4757e9e3",
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "00633b8e-4a64-4997-8015-3ed315407776",
    "contentId" : "urn:wim:tv:content:7717b0ac-17ff-4fb2-adc7-2a505cdf432a",
    "boxId" : "109fd6e1-ee36-4061-82bd-d4dd98bf4972",
    "duration" : "5:41",
    "thumbnailId" : "beea1320-635f-447f-8948-3cb3fdf09d5f"
  }, {
    "itemCode" : "96a06cc3-33da-4faf-8113-20eed2e5f6ed",
    "vodId" : "a923ddb0-c99a-4400-849c-cfd79e8c8020",
    "title" : "Title 4",
    "description" : "Description 4",
    "tags" : [ "tag40", "tag41", "tag42" ],
    "resourceId" : "e7c81a1b-af3d-43c8-9630-17b1e5371b6e",
    "contentId" : "urn:wim:tv:content:28110620-0b1d-4936-999b-c9f58d2b606f",
    "boxId" : "3d6f403c-48a4-4747-b3d4-e1ae659c66cb",
    "duration" : "8:58",
    "thumbnailId" : "97205575-eb46-4005-a2b7-698054732284"
  }, {
    "itemCode" : "29b0bfa2-5af5-45b4-b3cc-cc7025061816",
    "vodId" : "1f74e1cf-abad-48b4-9568-79e998670105",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "606d076f-9166-4780-9bfa-7aaa22fca861",
    "contentId" : "urn:wim:tv:content:a8f1b96e-ae05-44a5-bd29-fee58d7b23c2",
    "boxId" : "018f207b-7d12-46e8-865d-c385c82b2037",
    "duration" : "6:58",
    "thumbnailId" : "3f72f378-d7ae-4d27-8c20-08f3a9827963"
  }, {
    "itemCode" : "bf81a3be-0132-4744-8c17-e4175f4aefba",
    "vodId" : "235ee67f-d1ba-426d-8485-80519f743569",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "363913a9-c985-4867-af10-438af73e1d59",
    "contentId" : "urn:wim:tv:content:aad4126e-6d3d-4ceb-b46b-3a43be447f5b",
    "boxId" : "467aeb70-3b14-4ff8-9b26-ee84790f11f8",
    "duration" : "5:55",
    "thumbnailId" : "8ab5e438-a9ab-4f21-82fb-a7ce7c084616"
  } ],
  "bundle" : {
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "itemCount" : 4,
    "duration" : 1,
    "thumbnailId" : "94d8a6f7-571d-4633-8e7e-680a18b72a85",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9326e5e6-2da0-48df-a872-545e0ae96974",
    "name" : "Name 1"
  }
}

Response fields

Removes one or more contents from a content bundle

$ curl 'http://www.wim.tv:8080/api/contentbundle/9326e5e6-2da0-48df-a872-545e0ae96974/items/remove' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "count" : 2,
  "index" : 1
}'

Path parameters

/api/contentbundle/{bundleId}/items/remove

Parameter Description

bundleId

The content bundle identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Index of the first content to remove.

* Required.
* Must be at least 0.

count

Number

Number of contents to remove.

* Required.
* Must be at least 1.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1348

{
  "items" : [ {
    "itemCode" : "b56a03d6-cdbc-4c77-a5be-662d5772cd73",
    "vodId" : "cf6e7b23-a895-4242-b2a7-5fcf4757e9e3",
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "00633b8e-4a64-4997-8015-3ed315407776",
    "contentId" : "urn:wim:tv:content:7717b0ac-17ff-4fb2-adc7-2a505cdf432a",
    "boxId" : "109fd6e1-ee36-4061-82bd-d4dd98bf4972",
    "duration" : "5:41",
    "thumbnailId" : "beea1320-635f-447f-8948-3cb3fdf09d5f"
  }, {
    "itemCode" : "bf81a3be-0132-4744-8c17-e4175f4aefba",
    "vodId" : "235ee67f-d1ba-426d-8485-80519f743569",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "363913a9-c985-4867-af10-438af73e1d59",
    "contentId" : "urn:wim:tv:content:aad4126e-6d3d-4ceb-b46b-3a43be447f5b",
    "boxId" : "467aeb70-3b14-4ff8-9b26-ee84790f11f8",
    "duration" : "5:55",
    "thumbnailId" : "8ab5e438-a9ab-4f21-82fb-a7ce7c084616"
  } ],
  "bundle" : {
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "itemCount" : 2,
    "duration" : 1,
    "thumbnailId" : "94d8a6f7-571d-4633-8e7e-680a18b72a85",
    "durationUnit" : "MONTHS",
    "price" : "2,00",
    "bundleId" : "9326e5e6-2da0-48df-a872-545e0ae96974",
    "name" : "Name 1"
  }
}

Response fields

Market Place

Publishes a content in Market Place

$ curl 'http://www.wim.tv:8080/api/box/4abb928c-ac59-4a14-a1b3-bf02c662c8a5/marketplace' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "licenseType" : "FREE",
  "download" : true
}'

Path parameters

/api/box/{boxId}/marketplace

Parameter Description

boxId

The WimBox item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

licenseType

License Type

License type.

* Required.
* Must not be null.

ccType

CC License

Creative Commons license.

* Must be set only if the license type is CREATIVE_COMMONS.

activationPrice

Amount

Activation price.

* Must be set if the license type is SPOT_PRICE, but may be set also if the license type is PAY_PER_VIEW or REVENUE_SHARING.
* Must be at least 0 (inclusive=false).

pricePerView

Amount

Price per view.

* Must be set only if the license type is PAY_PER_VIEW.
* Must be at least 0 (inclusive=false).

earningPercentage

Percentage

Earning percentage.

* Must be set only if the license type is REVENUE_SHARING.
* Must be at least 0 (inclusive=false).
* Must be at most 100.

duration

Number

Duration.

* May be set only if the license type is not CREATIVE_COMMONS.
* Must be at least 1.

durationUnit

Duration Unit

Duration unit.

* May be set only if the license type is not CREATIVE_COMMONS.

download

Boolean

Whether the acquirer can download the content.

* May be true only if the license type is not CREATIVE_COMMONS.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 501

{
  "conditions" : {
    "licenseType" : "FREE",
    "download" : true
  },
  "marketplaceId" : "36c9a812-d5a0-468f-ba9a-1af078da8d52",
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "386666f0-9bf2-4a18-9566-cf935bdc1141",
  "contentId" : "urn:wim:tv:content:d8b92ea7-8bf6-4c36-9c05-2e58c49835cd",
  "boxId" : "4abb928c-ac59-4a14-a1b3-bf02c662c8a5",
  "duration" : "7:07",
  "thumbnailId" : "b9ad05a4-a2ae-4ba8-8bb8-992e0828ff99"
}

Response fields

Reads a Market Place item

$ curl 'http://www.wim.tv:8080/api/marketplace/36c9a812-d5a0-468f-ba9a-1af078da8d52' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/marketplace/{marketplaceId}

Parameter Description

marketplaceId

The Market Place item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 501

{
  "conditions" : {
    "licenseType" : "FREE",
    "download" : true
  },
  "marketplaceId" : "36c9a812-d5a0-468f-ba9a-1af078da8d52",
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "386666f0-9bf2-4a18-9566-cf935bdc1141",
  "contentId" : "urn:wim:tv:content:d8b92ea7-8bf6-4c36-9c05-2e58c49835cd",
  "boxId" : "4abb928c-ac59-4a14-a1b3-bf02c662c8a5",
  "duration" : "7:07",
  "thumbnailId" : "b9ad05a4-a2ae-4ba8-8bb8-992e0828ff99"
}

Response fields

Path Type Description

marketplaceId

String

The Market Place item identifier.

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

conditions

Object

License conditions.

Reads a Market Place item in public pages

$ curl 'http://www.wim.tv:8080/api/public/marketplace/2fa071c8-0109-4c00-8a2d-2d96f5ac9393' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/marketplace/{marketplaceId}

Parameter Description

marketplaceId

The item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 806

{
  "conditions" : {
    "licenseType" : "SPOT_PRICE",
    "activationPrice" : "0,50",
    "download" : false
  },
  "marketplaceId" : "2fa071c8-0109-4c00-8a2d-2d96f5ac9393",
  "title" : "Title 3",
  "description" : "Description 3",
  "tags" : [ "tag30", "tag31", "tag32" ],
  "resourceId" : "2dff63d6-6ba6-4870-97d9-bebb6a9c8536",
  "contentId" : "urn:wim:tv:content:b5ff461a-b4d8-43ac-b80f-681ac14e0181",
  "boxId" : "c9a19548-7123-496b-9ca7-3f530492e15a",
  "duration" : "8:58",
  "thumbnailId" : "c1da9a24-7edc-499c-99da-9cb6754fe66c",
  "seller" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  }
}

Response fields

Path Type Description

marketplaceId

String

The Market Place item identifier.

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

seller

User

The issuer.

conditions

Object

License conditions.

License conditions

Path Type Description

licenseType

License Type

License type.

ccType

CC License

Creative Commons License. Provided only if the license type is CREATIVE_COMMONS.

activationPrice

Amount

Activation price. Provided if the license type is SPOT_PRICE, but also PAY_PER_VIEW and REVENUE_SHARING licenses may include an activation price.

pricePerView

Amount

The price per view. Provided only if the license type is PAY_PER_VIEW.

earningPercentage

Percentage

Earning percentage. Provided only if the license type is REVENUE_SHARING.

duration

Number

Duration. Provided only if the license has an expiration.

durationUnit

Duration Unit

Duration unit. Provided only if the license has an expiration.

download

Boolean

Whether the acquirer can download the content.

Updates an existing Market Place item

$ curl 'http://www.wim.tv:8080/api/marketplace/36c9a812-d5a0-468f-ba9a-1af078da8d52' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "licenseType" : "CREATIVE_COMMONS",
  "ccType" : "BY_NC_SA",
  "download" : false
}'

Path parameters

/api/marketplace/{marketplaceId}

Parameter Description

marketplaceId

The Market Place item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 541

{
  "conditions" : {
    "licenseType" : "CREATIVE_COMMONS",
    "ccType" : "BY_NC_SA",
    "download" : false
  },
  "marketplaceId" : "36c9a812-d5a0-468f-ba9a-1af078da8d52",
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "resourceId" : "386666f0-9bf2-4a18-9566-cf935bdc1141",
  "contentId" : "urn:wim:tv:content:d8b92ea7-8bf6-4c36-9c05-2e58c49835cd",
  "boxId" : "4abb928c-ac59-4a14-a1b3-bf02c662c8a5",
  "duration" : "7:07",
  "thumbnailId" : "b9ad05a4-a2ae-4ba8-8bb8-992e0828ff99"
}

Response fields

Deletes an existing Market Place item

$ curl 'http://www.wim.tv:8080/api/marketplace/36c9a812-d5a0-468f-ba9a-1af078da8d52' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/marketplace/{marketplaceId}

Parameter Description

marketplaceId

The Market Place item identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/marketplace/contents' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

conditions

Object

License conditions.

* Optional.

Query string

The query string applies on the following fields:

  • Content

    • Title

    • Description

    • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1237

{
  "items" : [ {
    "conditions" : {
      "licenseType" : "SPOT_PRICE",
      "activationPrice" : "0,50",
      "download" : false
    },
    "marketplaceId" : "5055db09-b886-4ca9-a888-477c90ee8092",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "fd776f57-9df4-448f-be8e-4bbd7fb86070",
    "contentId" : "urn:wim:tv:content:7c813158-dcee-4b5d-b678-1580675c9616",
    "boxId" : "0e169614-9a97-481a-93e5-b6c583671ce0",
    "duration" : "6:26",
    "thumbnailId" : "c06dd35f-e1f3-4500-b3d6-efd9cdc4d4ae"
  }, {
    "conditions" : {
      "licenseType" : "CREATIVE_COMMONS",
      "ccType" : "BY_SA",
      "download" : false
    },
    "marketplaceId" : "74a65524-aa54-4832-91b4-7851546f8e09",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "262d7855-c610-475b-bcc1-a1bf3b1335b3",
    "contentId" : "urn:wim:tv:content:240ef511-cb45-4cf3-b604-e700f9d9a0fd",
    "boxId" : "cb8b6683-5620-4b11-b04f-650cd4a15344",
    "duration" : "5:09",
    "thumbnailId" : "359dfe8c-d4df-4524-8684-ca8cfc16edce"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Searches for Market Place items in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/marketplace/contents' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "tag21 tag32",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

conditions

Object

License conditions.

* Optional.

excludeUserCode

String

Code of the user that has published the contents to exclude.

* Optional.
* Length must be between 0 and 50 inclusive.

Query string

The query string applies on the following fields:

  • Content

    • Title

    • Description

    • Tags

  • Seller (boost: 0.7; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1801

{
  "items" : [ {
    "conditions" : {
      "licenseType" : "SPOT_PRICE",
      "activationPrice" : "0,50",
      "download" : false
    },
    "marketplaceId" : "2fa071c8-0109-4c00-8a2d-2d96f5ac9393",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "2dff63d6-6ba6-4870-97d9-bebb6a9c8536",
    "contentId" : "urn:wim:tv:content:b5ff461a-b4d8-43ac-b80f-681ac14e0181",
    "boxId" : "c9a19548-7123-496b-9ca7-3f530492e15a",
    "duration" : "8:58",
    "thumbnailId" : "c1da9a24-7edc-499c-99da-9cb6754fe66c",
    "seller" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    }
  }, {
    "conditions" : {
      "licenseType" : "CREATIVE_COMMONS",
      "ccType" : "BY_SA",
      "download" : false
    },
    "marketplaceId" : "17d3105f-6932-462f-bbb6-565f808225f8",
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "resourceId" : "de413d6d-d0ae-4cdf-9f0b-4e5c7ab26cbd",
    "contentId" : "urn:wim:tv:content:7788b99b-c379-451e-acb1-81a8956bc74c",
    "boxId" : "1ed1559f-d0ed-4027-a25b-212004de1513",
    "duration" : "7:55",
    "thumbnailId" : "2591ab02-847c-439c-96dd-a45fd8f476ea",
    "seller" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    }
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Publishing date (descending)

Path Type Description

licenseType

License Type

License type.

* Must be provided if ccType is provided.

ccType

CC License

Creative Commons license.

* May be provided only if the license type is CREATIVE_COMMONS.

download

Boolean

Whether the buyer can download the contents.

* Optional.

Acquires a Market Place item

This API acts as the transaction API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/marketplace/5cda6c0d-1a59-44af-a0c3-5a32a70aad33/acquire' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Path parameters

/api/marketplace/{marketplaceId}/acquire

Parameter Description

marketplaceId

The Market Place item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

If the content is free, you should not provide none of the request fields, otherwise you must provide the parameters to check for the succeeded payment.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1547

{
  "boxContent" : {
    "valueDate" : "08/09/2017",
    "marketplaceLicense" : {
      "licenseId" : "86dfe213-865c-46ae-967c-8e3e1f933cf2",
      "marketplaceId" : "5cda6c0d-1a59-44af-a0c3-5a32a70aad33",
      "issuerCode" : "john",
      "licenseType" : "FREE",
      "download" : false
    },
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "37a97246-c063-4a53-a1bd-18bd9f2f0bee",
    "contentId" : "urn:wim:tv:content:328b961d-3a30-4db0-8196-3851d089d1e8",
    "boxId" : "7323fca0-8fea-48a5-b4b3-0a0e563cfe32",
    "duration" : "6:49",
    "thumbnailId" : "5fb2ee66-09a6-44bd-94f7-ac9b2a785b24"
  },
  "marketplaceContent" : {
    "conditions" : {
      "licenseType" : "FREE",
      "download" : false
    },
    "marketplaceId" : "5cda6c0d-1a59-44af-a0c3-5a32a70aad33",
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "37a97246-c063-4a53-a1bd-18bd9f2f0bee",
    "contentId" : "urn:wim:tv:content:328b961d-3a30-4db0-8196-3851d089d1e8",
    "boxId" : "c7a93992-d9e8-4f7b-916b-aad568814c51",
    "duration" : "6:49",
    "thumbnailId" : "5fb2ee66-09a6-44bd-94f7-ac9b2a785b24",
    "seller" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    }
  },
  "result" : "FULFILLED"
}

Response fields

Path Type Description

result

Result

Result of the request.

marketplaceContent

Object

The Market Place item.

boxContent

Object

The acquired WimBox item. Provided only if the result is FULFILLED.

Pays to acquire a Market Place item

This API acts as the payment API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/marketplace/a2a2a59b-ea46-47f5-bca2-2f206d7eb1ae/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/marketplace/acquire",
  "cancelUrl" : "http://www.wim.tv/marketplace/rejected"
}'

Path parameters

/api/marketplace/{marketplaceId}/pay

Parameter Description

marketplaceId

The Market Place item identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1046

{
  "embedded" : false,
  "resource" : {
    "conditions" : {
      "licenseType" : "SPOT_PRICE",
      "activationPrice" : "0,50",
      "download" : false
    },
    "marketplaceId" : "a2a2a59b-ea46-47f5-bca2-2f206d7eb1ae",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "0b57d596-b95a-40e9-8f43-ed76dcc42150",
    "contentId" : "urn:wim:tv:content:1eda5b7e-b5df-4e3e-bc52-cddb53715d29",
    "boxId" : "d8f2c96a-1ce3-47db-8ac8-517053c70594",
    "duration" : "9:23",
    "thumbnailId" : "73832b59-8134-4971-9809-b850af212467",
    "seller" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    }
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "fd9e846e-3da1-4bb2-9f9a-316235186531",
  "mobile" : false
}

Response fields

Resource fields

Previews a Market Place item

You can offer a free preview of a content (15 seconds) to your customers.

$ curl 'http://www.wim.tv:8080/api/public/marketplace/ee1c3351-ce5a-4cd4-b0a0-94682826ce76/preview' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/marketplace/{marketplaceId}/preview

Parameter Description

marketplaceId

The Market Place item identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2046

{
  "resource" : {
    "conditions" : {
      "licenseType" : "SPOT_PRICE",
      "activationPrice" : "0,50",
      "download" : false
    },
    "marketplaceId" : "ee1c3351-ce5a-4cd4-b0a0-94682826ce76",
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "7983f5cc-6435-487d-8703-264d24c2fae4",
    "contentId" : "urn:wim:tv:content:e9af7ef8-731d-4b1b-b94e-bca72c618ef0",
    "boxId" : "6e24fafb-6b51-4b91-b165-c64a526fd348",
    "duration" : "7:46",
    "thumbnailId" : "a19d2b22-879d-487a-8980-c223da52bc51",
    "seller" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    }
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-402a1127-4ccc-4190-aad2-38ef10b8afc5-tr.mp4/playlist.m3u8?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-402a1127-4ccc-4190-aad2-38ef10b8afc5-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-402a1127-4ccc-4190-aad2-38ef10b8afc5-tr.mp4?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-402a1127-4ccc-4190-aad2-38ef10b8afc5-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-402a1127-4ccc-4190-aad2-38ef10b8afc5-tr.mp4?token=b962e40c-ee34-4579-9eaf-16f58ae467a0&type=preview"
}

Response fields

Resource fields

Live channels

A WimLive channel is a stream through which you can broadcast your live events to your public.

Creates a new live channel

$ curl 'http://www.wim.tv:8080/api/live/channel' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "streamPath" : "channel1",
  "thumbnailId" : "1b1c2f0d-855c-4f4a-9068-a61b329fbaf2",
  "public" : true,
  "name" : "Channel 1"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

name

String

Name.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

streamPath

String

The stream path. You should generate the path through by the API /api/public/live/streampath.

* Required.
* Length must be between 0 and 128 inclusive.
* Must not be blank.

public

Boolean

Whether the live channel has to be visible in public pages or not. See Searches for live channels in public pages and Searches for live events in public pages.

* Optional.

thumbnailId

String

Identifier of the thumbnail to assign to the live channel.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 308

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "channelId" : "c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3",
  "streamPath" : "channel1",
  "thumbnailId" : "1b1c2f0d-855c-4f4a-9068-a61b329fbaf2",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
  "public" : true,
  "name" : "Channel 1"
}

Response fields

Reads a live channel in private pages

$ curl 'http://www.wim.tv:8080/api/live/channel/c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/live/channel/{channelId}

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 308

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "channelId" : "c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3",
  "streamPath" : "channel1",
  "thumbnailId" : "1b1c2f0d-855c-4f4a-9068-a61b329fbaf2",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
  "public" : true,
  "name" : "Channel 1"
}

Response fields

Path Type Description

channelId

String

The live channel identifier.

name

String

Name.

description

String

Description. May be not provided.

streamingBaseUrl

URI

The streaming base URL.

streamPath

String

The stream path.

public

Boolean

Whether the live channel is visible in public pages or not. See Searches for live channels in public pages and Searches for live events in public pages.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads a live channel in public pages

$ curl 'http://www.wim.tv:8080/api/public/live/channel/a43afb88-a6ef-402b-82e2-f0bb17c2b639' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/live/channel/{channelId}

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 500

{
  "description" : "Science",
  "tags" : [ "archeology", "history", "nature", "technology" ],
  "channelId" : "a43afb88-a6ef-402b-82e2-f0bb17c2b639",
  "thumbnailId" : "4c42b767-8f21-44e5-b319-92971e3ed31e",
  "publisher" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  },
  "name" : "JoeTV 3"
}

Response fields

Path Type Description

channelId

String

The live channel identifier.

name

String

Name.

description

String

Description. May be not provided.

publisher

User

The publisher.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing live channel

$ curl 'http://www.wim.tv:8080/api/live/channel/c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "streamPath" : "channel1",
  "public" : true,
  "name" : "Channel 1"
}'

Path parameters

/api/live/channel/{channelId}

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 249

{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "channelId" : "c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3",
  "streamPath" : "channel1",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
  "public" : true,
  "name" : "Channel 1"
}

Response fields

Deletes an existing live channel

$ curl 'http://www.wim.tv:8080/api/live/channel/c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/live/channel/{channelId}

Parameter Description

channelId

The live channel identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/live/channels' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "technology",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

public

Boolean

Whether the channels have to be visible in public pages.

* Optional.

Query string

The query string applies on the following fields:

  • Name

  • Description

  • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 811

{
  "items" : [ {
    "description" : "Science",
    "tags" : [ "archeology", "history", "nature", "technology" ],
    "channelId" : "17911654-4669-4f4b-8732-3bfad66225c9",
    "streamPath" : "joetv3",
    "thumbnailId" : "2efdd79e-b578-4ac2-b7b4-46e3a3d591ec",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "JoeTV 3"
  }, {
    "description" : "Educational",
    "tags" : [ "computer", "hardware", "maths", "software", "technology" ],
    "channelId" : "81e1d563-e3c1-4416-a0b5-bf292a807d8b",
    "streamPath" : "joetv1",
    "thumbnailId" : "0bd545b6-e5d0-48eb-a3b7-7ed17e1e85fe",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "JoeTV 1"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Name

Searches for live channels in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/live/channels' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "technology",
  "pageSize" : 20,
  "pageIndex" : 0
}'
If the public field of a channel is set to false, that channel is excluded from the search.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

Query string

The query string applies on the following fields:

  • Channel

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.7; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1169

{
  "items" : [ {
    "description" : "Science",
    "tags" : [ "archeology", "history", "nature", "technology" ],
    "channelId" : "a43afb88-a6ef-402b-82e2-f0bb17c2b639",
    "thumbnailId" : "4c42b767-8f21-44e5-b319-92971e3ed31e",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "JoeTV 3"
  }, {
    "description" : "Educational",
    "tags" : [ "computer", "hardware", "maths", "software", "technology" ],
    "channelId" : "e1da283c-7f47-45ae-92f6-fdd6f4f425e2",
    "thumbnailId" : "fff29430-1bbc-4ab3-9baf-5a714010e913",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "JoeTV 1"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Name

Generates a new stream path

$ curl 'http://www.wim.tv:8080/api/public/live/streampath?base=mychannel' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Request parameters

Parameter Description

base

The base name for the path. You should set the the name of the channel to which assign the stream path.

* Optional.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 32

{
  "streamPath" : "mychannel"
}

Response fields

Path Type Description

streamPath

String

The generated path.

Plays the on-air live event in a channel

This API acts as the transaction API in a 3-steps payment flow, but it is only a kind of shortcut to play a live channel avoiding to specify the current on-air event; however the response includes the data of the detected event, thus, if the event is not free, you can proceed with the payment and then with the playing using the APIs for the live event (see Pays to play a live event and Plays a live event). Anyway there is not a payment API to play a live channel.
$ curl 'http://www.wim.tv:8080/api/live/channel/0385cde8-3146-4b39-a0f0-f1ce4f227e50/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Path parameters

/api/live/channel/{channelId}/play

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

If the live event is free, you should not provide none of the request fields, otherwise you must provide the parameters to check for the succeeded payment.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1830

{
  "resource" : {
    "description" : "Episode 1",
    "tags" : [ "ishikawa", "nagai" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "11:21:01"
    },
    "thumbnailId" : "235f632a-eb20-4857-81b2-2cbc63db337c",
    "channel" : {
      "description" : "Anime",
      "tags" : [ "japan", "manga" ],
      "channelId" : "0385cde8-3146-4b39-a0f0-f1ce4f227e50",
      "thumbnailId" : "43beb411-c9a9-4ebb-a20b-775a423b6423",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "JoeTV 2"
    },
    "onAir" : false,
    "eventId" : "69348ac5-c099-43f8-b391-0f3260ad55a1",
    "shouldBeOnAir" : false,
    "name" : "Getter Robo",
    "paymentMode" : "FREE",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "10:58:31"
    }
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/live?token=53cd4c88-ccdc-44be-8acc-445440c66b27",
    "uniqueStreamer" : "http://www.wim.tv:1935/live/joetv2_aac/playlist.m3u8?token=53cd4c88-ccdc-44be-8acc-445440c66b27"
  }, {
    "mimeType" : "video/flash",
    "file" : "joetv2_aac",
    "streamer" : "rtmp://www.wim.tv:1935/live?token=53cd4c88-ccdc-44be-8acc-445440c66b27",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/joetv2_aac?token=53cd4c88-ccdc-44be-8acc-445440c66b27"
  } ],
  "mimeType" : "video/flash",
  "file" : "joetv2_aac",
  "streamer" : "rtmp://www.wim.tv:1935/live?token=53cd4c88-ccdc-44be-8acc-445440c66b27",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/joetv2_aac?token=53cd4c88-ccdc-44be-8acc-445440c66b27"
}

Response fields

If the live event is free or the payment has succeeded, the response includes the parameters to setup your player, otherwise the response notifies that you have to pay.

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/live/channel/e25ed79c-a781-4e6f-b76c-8dc946af8a50/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Tests a live channel

You can test if your encoder is properly configured to broadcast through a live channel with no need to define an event.

$ curl 'http://www.wim.tv:8080/api/live/channel/c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3/test' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/live/channel/{channelId}/test

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1166

{
  "resource" : {
    "description" : "Description 1",
    "tags" : [ "tag1", "tag2" ],
    "channelId" : "c88b33ec-1f04-4b2b-9ce0-d8ed06a784d3",
    "streamPath" : "channel1",
    "thumbnailId" : "1b1c2f0d-855c-4f4a-9068-a61b329fbaf2",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "Channel 1"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/live?token=a4127450-2b9c-4378-8f0d-152b6a6db775",
    "uniqueStreamer" : "http://www.wim.tv:1935/live/channel1_aac/playlist.m3u8?token=a4127450-2b9c-4378-8f0d-152b6a6db775"
  }, {
    "mimeType" : "video/flash",
    "file" : "channel1_aac",
    "streamer" : "rtmp://www.wim.tv:1935/live?token=a4127450-2b9c-4378-8f0d-152b6a6db775",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/channel1_aac?token=a4127450-2b9c-4378-8f0d-152b6a6db775"
  } ],
  "mimeType" : "video/flash",
  "file" : "channel1_aac",
  "streamer" : "rtmp://www.wim.tv:1935/live?token=a4127450-2b9c-4378-8f0d-152b6a6db775",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/channel1_aac?token=a4127450-2b9c-4378-8f0d-152b6a6db775"
}

Response fields

Resource fields

Live events

A WimLive event defines the time when you encode an event on a WimLive channel and the conditions (i.e. the price to pay) under which a viewer can watch your event.

Creates a new live event

$ curl 'http://www.wim.tv:8080/api/live/channel/0eaf6c72-1396-4b5e-83b7-0bd1b61c4fd2/event' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "eventDate" : {
    "date" : "29/10/2016",
    "time" : "14:00:00"
  },
  "endDate" : {
    "date" : "29/10/2016",
    "time" : "14:30:00"
  },
  "publicEvent" : false,
  "recordEvent" : true,
  "thumbnailId" : "40fe3850-53a1-4426-a111-0072fc721be7",
  "paymentMode" : "FREE",
  "name" : "Event 1"
}'

Path parameters

/api/live/channel/{channelId}/event

Parameter Description

channelId

The live channel identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

name

String

Title.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

paymentMode

License Type

License type.

* Required.
* Must not be null.

pricePerView

Amount

Price per view.

* Must be set only if the license type is PAY_PER_VIEW.
* Must be at least 0 (inclusive=false).

eventDate

DateTime

The date and time when the event starts.

* Required.
* Must not be null.

endDate

DateTime

The date and time when the event ends.

* Required.
* Must not be null.

publicEvent

Boolean

Whether the live event has to be visible in public pages or not. See Searches for live events in public pages.

* Optional.

recordEvent

Boolean

Whether the live event has to be recorded or not.

* Optional.

thumbnailId

String

Identifier of the thumbnail to assign to the live event.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 848

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "endDate" : {
    "date" : "29/10/2016",
    "time" : "14:30:00"
  },
  "thumbnailId" : "40fe3850-53a1-4426-a111-0072fc721be7",
  "channel" : {
    "description" : "Educational",
    "tags" : [ "computer", "hardware", "maths", "software", "technology" ],
    "channelId" : "0eaf6c72-1396-4b5e-83b7-0bd1b61c4fd2",
    "streamPath" : "joetv1",
    "thumbnailId" : "d3541f0e-e9bc-495a-a0e8-65cd424010bd",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "JoeTV 1"
  },
  "onAir" : false,
  "eventId" : "eb14b189-05b3-4234-91cb-4c79c65e5489",
  "shouldBeOnAir" : false,
  "name" : "Event 1",
  "paymentMode" : "FREE",
  "eventDate" : {
    "date" : "29/10/2016",
    "time" : "14:00:00"
  },
  "publicEvent" : false,
  "recordEvent" : true
}

Response fields

Reads a live event in private pages

$ curl 'http://www.wim.tv:8080/api/live/event/eb14b189-05b3-4234-91cb-4c79c65e5489' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/live/event/{eventId}

Parameter Description

eventId

The live event identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 848

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "endDate" : {
    "date" : "29/10/2016",
    "time" : "14:30:00"
  },
  "thumbnailId" : "40fe3850-53a1-4426-a111-0072fc721be7",
  "channel" : {
    "description" : "Educational",
    "tags" : [ "computer", "hardware", "maths", "software", "technology" ],
    "channelId" : "0eaf6c72-1396-4b5e-83b7-0bd1b61c4fd2",
    "streamPath" : "joetv1",
    "thumbnailId" : "d3541f0e-e9bc-495a-a0e8-65cd424010bd",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "JoeTV 1"
  },
  "onAir" : false,
  "eventId" : "eb14b189-05b3-4234-91cb-4c79c65e5489",
  "shouldBeOnAir" : false,
  "name" : "Event 1",
  "paymentMode" : "FREE",
  "eventDate" : {
    "date" : "29/10/2016",
    "time" : "14:00:00"
  },
  "publicEvent" : false,
  "recordEvent" : true
}

Response fields

Path Type Description

eventId

String

The live event identifier.

name

String

Title.

description

String

Description. May be not provided.

channel

Channel

Live channel.

paymentMode

License Type

License type.

pricePerView

Amount

Price per view. Provided only if the license type is PAY_PER_VIEW.

eventDate

DateTime

The date when the event starts.

endDate

DateTime

The date when the event ends.

publicEvent

Boolean

Whether the live event is visible in public pages or not. See Searches for live events in public pages.

recordEvent

Boolean

Whether the live event has to be recorded or not.

onAir

Boolean

Whether the event is on-air.

shouldBeOnAir

Boolean

Whether the event should be on-air because of the time.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads a live event in public pages

$ curl 'http://www.wim.tv:8080/api/public/live/event/208a2cbc-b3f5-4126-a164-507cf64f764a' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/live/event/{eventId}

Parameter Description

eventId

The live event identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 936

{
  "description" : "Episode 1",
  "tags" : [ "ishikawa", "nagai" ],
  "endDate" : {
    "date" : "08/09/2017",
    "time" : "13:21:01"
  },
  "thumbnailId" : "dfd8ffba-dedf-4d99-88ff-5e151c954110",
  "channel" : {
    "description" : "Anime",
    "tags" : [ "japan", "manga" ],
    "channelId" : "722ec07a-b4c7-46c4-a7be-dd87d796484a",
    "thumbnailId" : "8777d7d1-5d94-4903-bac1-522e988e4bd4",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "JoeTV 2"
  },
  "onAir" : false,
  "eventId" : "208a2cbc-b3f5-4126-a164-507cf64f764a",
  "shouldBeOnAir" : false,
  "name" : "Getter Robo",
  "paymentMode" : "FREE",
  "eventDate" : {
    "date" : "08/09/2017",
    "time" : "12:58:31"
  }
}

Response fields

Path Type Description

eventId

String

The live event identifier.

name

String

Title.

description

String

Description. May be not provided.

channel

Channel

Live channel.

paymentMode

License Type

License type.

pricePerView

Amount

Price per view. Provided only if the license type is PAY_PER_VIEW.

eventDate

DateTime

The date when the event starts.

endDate

DateTime

The date when the event ends.

onAir

Boolean

Whether the event is on-air.

shouldBeOnAir

Boolean

Whether the event should be on-air because of the time.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing live event

$ curl 'http://www.wim.tv:8080/api/live/event/eb14b189-05b3-4234-91cb-4c79c65e5489' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "eventDate" : {
    "date" : "29/10/2016",
    "time" : "14:30:00"
  },
  "endDate" : {
    "date" : "29/10/2016",
    "time" : "15:00:00"
  },
  "publicEvent" : true,
  "recordEvent" : false,
  "pricePerView" : "2,50",
  "paymentMode" : "PAY_PER_VIEW",
  "name" : "Event 1"
}'

Path parameters

/api/live/event/{eventId}

Parameter Description

eventId

The live event identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 824

{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "endDate" : {
    "date" : "29/10/2016",
    "time" : "15:00:00"
  },
  "channel" : {
    "description" : "Educational",
    "tags" : [ "computer", "hardware", "maths", "software", "technology" ],
    "channelId" : "0eaf6c72-1396-4b5e-83b7-0bd1b61c4fd2",
    "streamPath" : "joetv1",
    "thumbnailId" : "d3541f0e-e9bc-495a-a0e8-65cd424010bd",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
    "public" : true,
    "name" : "JoeTV 1"
  },
  "onAir" : false,
  "eventId" : "eb14b189-05b3-4234-91cb-4c79c65e5489",
  "shouldBeOnAir" : false,
  "name" : "Event 1",
  "paymentMode" : "PAY_PER_VIEW",
  "eventDate" : {
    "date" : "29/10/2016",
    "time" : "14:30:00"
  },
  "pricePerView" : "2,50",
  "publicEvent" : true,
  "recordEvent" : false
}

Response fields

Deletes an existing live event

$ curl 'http://www.wim.tv:8080/api/live/event/eb14b189-05b3-4234-91cb-4c79c65e5489' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/live/event/{eventId}

Parameter Description

eventId

The live event identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/live/events' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "pastIncluded" : true,
  "queryString" : "nagai ishikawa",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

channelId

String

The live channel identifier.

* Optional.
* Length must be between 0 and 36 inclusive.

public

Boolean

Whether the events have to be visible in public pages.

* Optional.

recorded

Boolean

Whether the events have to be recorded.

* Optional.

pastIncluded

Boolean

Whether the events in the past should be included.

* Optional.

conditions

Object

Streaming conditions.

* Optional.

Query string

The query string applies on the following fields:

  • Event

    • Title

    • Description

    • Tags

  • Channel (boost: 0.7; if not provided as filter)

    • Name

    • Description

    • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1814

{
  "items" : [ {
    "description" : "Episode 1",
    "tags" : [ "ishikawa", "nagai" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "13:21:01"
    },
    "thumbnailId" : "5e1f7cc8-80fa-4b63-8acd-aac0aee8e28c",
    "channel" : {
      "description" : "Anime",
      "tags" : [ "japan", "manga" ],
      "channelId" : "5c127a1b-8c28-4005-9379-4003c4fe8b13",
      "streamPath" : "joetv2",
      "thumbnailId" : "3c8c3339-a0ad-49aa-b70e-0c5de80e07a4",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
      "public" : true,
      "name" : "JoeTV 2"
    },
    "onAir" : false,
    "eventId" : "f307fa15-a27b-4676-9de5-c2283a537230",
    "shouldBeOnAir" : false,
    "name" : "Getter Robo",
    "paymentMode" : "FREE",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "12:58:31"
    },
    "publicEvent" : true,
    "recordEvent" : false
  }, {
    "description" : "Episode 1",
    "tags" : [ "nagai" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "09:56:01"
    },
    "thumbnailId" : "8cb1697f-9abe-4969-abf6-9e87b143424f",
    "channel" : {
      "description" : "Anime",
      "tags" : [ "japan", "manga" ],
      "channelId" : "5c127a1b-8c28-4005-9379-4003c4fe8b13",
      "streamPath" : "joetv2",
      "thumbnailId" : "3c8c3339-a0ad-49aa-b70e-0c5de80e07a4",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/live",
      "public" : true,
      "name" : "JoeTV 2"
    },
    "onAir" : false,
    "eventId" : "d67b2245-008c-4673-a502-be38e7d12e1e",
    "shouldBeOnAir" : false,
    "name" : "Mazinger Z",
    "paymentMode" : "FREE",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "08:56:01"
    },
    "publicEvent" : true,
    "recordEvent" : false
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Start time

  3. End time

Searches for live events in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/live/events' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "nagai ishikawa",
  "pageSize" : 20,
  "pageIndex" : 0
}'
If the publicEvent field of an event is set to false, that event is excluded from the search.
If the public field of a channel is set to false, all events published on that channel are excluded from the search.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

channelId

String

The live channel identifier.

* Optional.
* Length must be between 0 and 36 inclusive.

conditions

Object

Streaming conditions.

* Optional.

Query string

The query string applies on the following fields:

  • Event

    • Title

    • Description

    • Tags

  • Channel (boost: 0.7; if not provided as filter)

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.5; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1097

{
  "items" : [ {
    "description" : "Episode 1",
    "tags" : [ "ishikawa", "nagai" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "13:21:01"
    },
    "thumbnailId" : "dfd8ffba-dedf-4d99-88ff-5e151c954110",
    "channel" : {
      "description" : "Anime",
      "tags" : [ "japan", "manga" ],
      "channelId" : "722ec07a-b4c7-46c4-a7be-dd87d796484a",
      "thumbnailId" : "8777d7d1-5d94-4903-bac1-522e988e4bd4",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "JoeTV 2"
    },
    "onAir" : false,
    "eventId" : "208a2cbc-b3f5-4126-a164-507cf64f764a",
    "shouldBeOnAir" : false,
    "name" : "Getter Robo",
    "paymentMode" : "FREE",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "12:58:31"
    }
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 1,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Start time

  2. End time

Path Type Description

paymentMode

License Type

License type.

* Optional.

Plays a live event

This API acts as the transaction API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/live/event/9d256f10-2f0f-42b0-9e59-6bfd9ac4db19/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Path parameters

/api/live/event/{eventId}/play

Parameter Description

eventId

The live event identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

If the live event is free, you should not provide none of the request fields, otherwise you must provide the parameters to check for the succeeded payment.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1830

{
  "resource" : {
    "description" : "Episode 1",
    "tags" : [ "ishikawa", "nagai" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "11:21:01"
    },
    "thumbnailId" : "7bc55561-5d60-47b7-9e4c-fcc91a77ce30",
    "channel" : {
      "description" : "Anime",
      "tags" : [ "japan", "manga" ],
      "channelId" : "52603444-4c3c-4685-9ce1-12f68c60b199",
      "thumbnailId" : "c2997457-3448-4ec5-863f-149dfd238120",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "JoeTV 2"
    },
    "onAir" : false,
    "eventId" : "9d256f10-2f0f-42b0-9e59-6bfd9ac4db19",
    "shouldBeOnAir" : false,
    "name" : "Getter Robo",
    "paymentMode" : "FREE",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "10:58:31"
    }
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/live?token=097f7d75-2de1-4007-9455-4e5903cc33c9",
    "uniqueStreamer" : "http://www.wim.tv:1935/live/joetv2_aac/playlist.m3u8?token=097f7d75-2de1-4007-9455-4e5903cc33c9"
  }, {
    "mimeType" : "video/flash",
    "file" : "joetv2_aac",
    "streamer" : "rtmp://www.wim.tv:1935/live?token=097f7d75-2de1-4007-9455-4e5903cc33c9",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/joetv2_aac?token=097f7d75-2de1-4007-9455-4e5903cc33c9"
  } ],
  "mimeType" : "video/flash",
  "file" : "joetv2_aac",
  "streamer" : "rtmp://www.wim.tv:1935/live?token=097f7d75-2de1-4007-9455-4e5903cc33c9",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/live/joetv2_aac?token=097f7d75-2de1-4007-9455-4e5903cc33c9"
}

Response fields

If the live event is free or the payment has succeeded, the response includes the parameters to setup your player, otherwise the response notifies that you have to pay.

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/live/event/b3bdc4f2-6e38-4a96-a9f3-98e491081323/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Pays to play a live event

This API acts as the payment API in a 3-steps payment flow.
$ curl 'http://www.wim.tv:8080/api/live/event/4dfb8a5f-02da-4619-a7a1-a20ce9c6996c/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/live/event/play",
  "cancelUrl" : "http://www.wim.tv/live/event/rejected"
}'

Path parameters

/api/live/event/{eventId}/pay

Parameter Description

eventId

The live event identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1298

{
  "embedded" : false,
  "resource" : {
    "description" : "From Masai Park to Mara Park and return",
    "tags" : [ "nature" ],
    "endDate" : {
      "date" : "08/09/2017",
      "time" : "11:46:01"
    },
    "thumbnailId" : "8ea57b5a-110e-45a5-899e-7ac0d693b7b2",
    "channel" : {
      "description" : "Science",
      "tags" : [ "archeology", "history", "nature", "technology" ],
      "channelId" : "be5af8c2-8a49-430a-878c-fa057622ffa0",
      "thumbnailId" : "d34d9924-daf5-4702-94f7-2c2894aea8ec",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "JoeTV 3"
    },
    "onAir" : false,
    "eventId" : "4dfb8a5f-02da-4619-a7a1-a20ce9c6996c",
    "shouldBeOnAir" : false,
    "name" : "African predators and prey",
    "paymentMode" : "PAY_PER_VIEW",
    "eventDate" : {
      "date" : "08/09/2017",
      "time" : "10:58:31"
    },
    "pricePerView" : "2,50"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "ff534d71-29a7-42f9-8630-d5f664cc7b17",
  "mobile" : false
}

Response fields

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/live/event/0350e9c9-0f8d-4c80-bb9d-61f08c16f51d/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/live/event/play",
  "cancelUrl" : "http://www.wim.tv/live/event/rejected"
}'

WimCast channels

A WimCast channel is a stream on which you can schedule your programs (live events or prerecorded shows) and through which your public can watch them.

Creates a new WimCast channel

$ curl 'http://www.wim.tv:8080/api/cast/channel' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "streamPath" : "channel1",
  "thumbnailId" : "afe80fe5-f0e2-421e-bfc4-cf2457213d63",
  "name" : "Channel 1"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

name

String

Name.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

streamPath

String

The stream path. You should generate the path through by the API /api/public/cast/streampath.

* Required.
* Length must be between 0 and 128 inclusive.
* Must not be blank.

thumbnailId

String

Identifier of the thumbnail to assign to the channel.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 296

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "channelId" : "17dc002b-6a01-4f54-a294-e471b3f817d7",
  "streamPath" : "channel1",
  "thumbnailId" : "afe80fe5-f0e2-421e-bfc4-cf2457213d63",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Channel 1"
}

Response fields

Reads a WimCast channel in private pages

$ curl 'http://www.wim.tv:8080/api/cast/channel/17dc002b-6a01-4f54-a294-e471b3f817d7' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}

Parameter Description

channelId

The WimCast channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 296

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "channelId" : "17dc002b-6a01-4f54-a294-e471b3f817d7",
  "streamPath" : "channel1",
  "thumbnailId" : "afe80fe5-f0e2-421e-bfc4-cf2457213d63",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Channel 1"
}

Response fields

Path Type Description

channelId

String

The WimCast channel identifier.

name

String

Name.

description

String

Description. May be not provided.

streamingBaseUrl

URI

The streaming base URL.

streamPath

String

The stream path.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads a WimCast channel in public pages

$ curl 'http://www.wim.tv:8080/api/public/cast/channel/b8fc7122-f5f6-4a26-bab5-87781ddbe5ef' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/cast/channel/{channelId}

Parameter Description

channelId

The channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 483

{
  "description" : "Description 2",
  "tags" : [ "ch20", "ch21", "ch22" ],
  "channelId" : "b8fc7122-f5f6-4a26-bab5-87781ddbe5ef",
  "thumbnailId" : "e0bc471a-159a-4f11-be06-582f86ba5414",
  "publisher" : {
    "pageTitle" : "WimLabs",
    "pageDescription" : "Video Communications",
    "facebookUrl" : "http://www.facebook.com/wimlabs",
    "twitterContact" : "@wimlabs",
    "linkedinUrl" : "http://www.linkedin.com/wimlabs",
    "userCode" : "john"
  },
  "name" : "Channel 2"
}

Response fields

Path Type Description

channelId

String

The WimCast channel identifier.

name

String

Name.

description

String

Description. May be not provided.

publisher

User

The publisher.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing WimCast channel

$ curl 'http://www.wim.tv:8080/api/cast/channel/17dc002b-6a01-4f54-a294-e471b3f817d7' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "streamPath" : "channel1",
  "name" : "Channel 1"
}'

Path parameters

/api/cast/channel/{channelId}

Parameter Description

channelId

The WimCast channel identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 237

{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "channelId" : "17dc002b-6a01-4f54-a294-e471b3f817d7",
  "streamPath" : "channel1",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Channel 1"
}

Response fields

Deletes an existing WimCast channel

$ curl 'http://www.wim.tv:8080/api/cast/channel/17dc002b-6a01-4f54-a294-e471b3f817d7' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}

Parameter Description

channelId

The WimCast channel identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/cast/channels' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "ch10 ch21",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

Query string

The query string applies on the following fields:

  • Name

  • Description

  • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 739

{
  "items" : [ {
    "description" : "Description 2",
    "tags" : [ "ch20", "ch21", "ch22" ],
    "channelId" : "640be250-e93f-49c6-ae87-1c6356c5cc01",
    "streamPath" : "channel2",
    "thumbnailId" : "53c9964b-9204-4dee-873b-71663f7aa369",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 2"
  }, {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "e66348a1-e6da-46de-aaeb-7f1c26e13b73",
    "streamPath" : "channel1",
    "thumbnailId" : "f7e15df1-ddc0-4f80-9a57-6d667390d4bc",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Name

Searches for WimCast channels in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/cast/channels' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "ch10 ch21",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.

Query string

The query string applies on the following fields:

  • Channel

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.7; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1121

{
  "items" : [ {
    "description" : "Description 2",
    "tags" : [ "ch20", "ch21", "ch22" ],
    "channelId" : "b8fc7122-f5f6-4a26-bab5-87781ddbe5ef",
    "thumbnailId" : "e0bc471a-159a-4f11-be06-582f86ba5414",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Channel 2"
  }, {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "eb102064-6bab-4225-b721-d83bed98855d",
    "thumbnailId" : "92a04962-b77f-482b-be2d-d973b6b8d1cb",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Channel 1"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Name

Generates a new stream path

$ curl 'http://www.wim.tv:8080/api/public/cast/streampath?base=mychannel' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Request headers

Name Description

Accept

application/json

* Required.

Request parameters

Parameter Description

base

The base name for the path. You should set the the name of the channel or the name of the live stream to which assign the stream path.

* Optional.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 32

{
  "streamPath" : "mychannel"
}

Response fields

Path Type Description

streamPath

String

The generated path.

Plays a WimCast channel

$ curl 'http://www.wim.tv:8080/api/cast/channel/1240ed75-00d5-4d3b-887c-3d08050b00f5/play' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/play

Parameter Description

channelId

The WimCast channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1115

{
  "resource" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "1240ed75-00d5-4d3b-887c-3d08050b00f5",
    "thumbnailId" : "f8386d2a-7930-4b2d-a22f-3b5fdc7920d5",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Channel 1"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/programming",
    "uniqueStreamer" : "http://www.wim.tv:1935/programming/channel1/playlist.m3u8"
  }, {
    "mimeType" : "video/flash",
    "file" : "channel1",
    "streamer" : "rtmp://www.wim.tv:1935/programming",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/channel1"
  } ],
  "mimeType" : "video/flash",
  "file" : "channel1",
  "streamer" : "rtmp://www.wim.tv:1935/programming",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/channel1"
}

Response fields

Resource fields

Unauthenticated users

The same API is available to non authenticated users through by another end-point.

$ curl 'http://www.wim.tv:8080/api/public/cast/channel/e73bae19-9bba-43f8-b8c0-4a778afec891/play' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Tests a WimCast channel

You can check for the properly broadcasting of a WimCast channel.

$ curl 'http://www.wim.tv:8080/api/cast/channel/17dc002b-6a01-4f54-a294-e471b3f817d7/test' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/test

Parameter Description

channelId

The WimCast channel identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 916

{
  "resource" : {
    "description" : "Description 1",
    "tags" : [ "tag1", "tag2" ],
    "channelId" : "17dc002b-6a01-4f54-a294-e471b3f817d7",
    "streamPath" : "channel1",
    "thumbnailId" : "afe80fe5-f0e2-421e-bfc4-cf2457213d63",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/programming",
    "uniqueStreamer" : "http://www.wim.tv:1935/programming/channel1/playlist.m3u8"
  }, {
    "mimeType" : "video/flash",
    "file" : "channel1",
    "streamer" : "rtmp://www.wim.tv:1935/programming",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/channel1"
  } ],
  "mimeType" : "video/flash",
  "file" : "channel1",
  "streamer" : "rtmp://www.wim.tv:1935/programming",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/channel1"
}

Response fields

Resource fields

WimCast live streams

A WimCast live stream is a stream on which you can encode your live events in order to broadcast them through by a WimCast channel.

Creates a new live stream

$ curl 'http://www.wim.tv:8080/api/cast/stream' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "streamPath" : "stream1",
  "thumbnailId" : "3a57f985-ebcf-4830-9ef3-3f5cecf50835",
  "name" : "Stream 1"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

name

String

Name.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

streamPath

String

The stream path. You should generate the path through by the API /api/public/cast/streampath.

* Required.
* Length must be between 0 and 128 inclusive.
* Must not be blank.

thumbnailId

String

Identifier of the thumbnail to assign to the stream.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 293

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "streamPath" : "stream1",
  "thumbnailId" : "3a57f985-ebcf-4830-9ef3-3f5cecf50835",
  "streamId" : "4574568e-8707-4e8d-b68d-5360a76a158e",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Stream 1"
}

Response fields

Reads a live stream

$ curl 'http://www.wim.tv:8080/api/cast/stream/4574568e-8707-4e8d-b68d-5360a76a158e' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/stream/{streamId}

Parameter Description

streamId

The live stream identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 293

{
  "description" : "Description 1",
  "tags" : [ "tag1", "tag2" ],
  "streamPath" : "stream1",
  "thumbnailId" : "3a57f985-ebcf-4830-9ef3-3f5cecf50835",
  "streamId" : "4574568e-8707-4e8d-b68d-5360a76a158e",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Stream 1"
}

Response fields

Path Type Description

streamId

String

The live stream identifier.

name

String

Name.

description

String

Description. May be not provided.

streamingBaseUrl

URI

The streaming base URL.

streamPath

String

The stream path.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing live stream

$ curl 'http://www.wim.tv:8080/api/cast/stream/4574568e-8707-4e8d-b68d-5360a76a158e' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "streamPath" : "stream1",
  "name" : "Stream 1"
}'

Path parameters

/api/cast/stream/{streamId}

Parameter Description

streamId

The live stream identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 234

{
  "description" : "Description modified",
  "tags" : [ "tag3" ],
  "streamPath" : "stream1",
  "streamId" : "4574568e-8707-4e8d-b68d-5360a76a158e",
  "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
  "name" : "Stream 1"
}

Response fields

Deletes an existing live stream

$ curl 'http://www.wim.tv:8080/api/cast/stream/4574568e-8707-4e8d-b68d-5360a76a158e' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/stream/{streamId}

Parameter Description

streamId

The live stream identifier.

Response

HTTP/1.1 204 No Content
$ curl 'http://www.wim.tv:8080/api/search/cast/streams' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "st10 st21",
  "pageSize" : 20,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

Query string

The query string applies on the following fields:

  • Name

  • Description

  • Tags

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 733

{
  "items" : [ {
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "streamPath" : "stream1",
    "thumbnailId" : "620963f0-1bda-423e-92e6-6c94f6594170",
    "streamId" : "817de2bd-efe4-4ecc-a198-55912b97508f",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Stream 1"
  }, {
    "description" : "Description 2",
    "tags" : [ "st20", "st21", "st22" ],
    "streamPath" : "stream2",
    "thumbnailId" : "6828246a-7ed7-47ef-b835-e2d16cb835a3",
    "streamId" : "829e5395-06c7-4253-9856-b349693bcc0d",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Stream 2"
  } ],
  "pageSize" : 20,
  "pageIndex" : 0,
  "totalCount" : 2,
  "pageCount" : 1
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Relevance

  2. Name

Tests a live stream

You can test if your encoder is properly configured to broadcast through a live stream with no need to define a program.

$ curl 'http://www.wim.tv:8080/api/cast/stream/4574568e-8707-4e8d-b68d-5360a76a158e/test' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/stream/{streamId}/test

Parameter Description

streamId

The live stream identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 928

{
  "resource" : {
    "description" : "Description 1",
    "tags" : [ "tag1", "tag2" ],
    "streamPath" : "stream1",
    "thumbnailId" : "3a57f985-ebcf-4830-9ef3-3f5cecf50835",
    "streamId" : "4574568e-8707-4e8d-b68d-5360a76a158e",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Stream 1"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/programming",
    "uniqueStreamer" : "http://www.wim.tv:1935/programming/stream1_aac/playlist.m3u8"
  }, {
    "mimeType" : "video/flash",
    "file" : "stream1_aac",
    "streamer" : "rtmp://www.wim.tv:1935/programming",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/stream1_aac"
  } ],
  "mimeType" : "video/flash",
  "file" : "stream1_aac",
  "streamer" : "rtmp://www.wim.tv:1935/programming",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/programming/stream1_aac"
}

Response fields

Resource fields

WimCast programs

Let’s start with a definition of the noun program from http://translate.google.com/#en/it/programming:

the action or process of scheduling something, especially radio or television programs.
the programming of shows

In WimCast, a programming is a sequence of programs broadcasted by a channel.

A program has a start-time and an end-time. The unit of time is the second.

In an instant T, a channel is broadcasting the program if T is equal or after the program start-time, and T is before the program end-time.

A program starts in a day if the start-time is equal or after that day at 00:00:00, and the end-time is before the next day at 00:00:00.
A program that starts in a day may end in the next day, but should not be longer than 24 hours.

Usually, the first program in a day may start in that day from 00:00:00 until at 23:59:59.
However, the start-time of the programming in a day may depend from the end-time of the last program started the previous day.
For example, if the last program starts in a day and finishes in the next day at 01:40:00, the the first program in the next day may start that day from 01:40:00 until at 23:59:59.

You schedule the programs in a channel day-by-day.

Reads a program in private pages

$ curl 'http://www.wim.tv:8080/api/cast/program/6942a62c-60dc-42d1-af00-141dae2a1979' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/program/{programId}

Parameter Description

programId

The WimCast program identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 796

{
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "endDate" : {
    "date" : "08/09/2020",
    "time" : "03:31:36"
  },
  "startDate" : {
    "date" : "08/09/2020",
    "time" : "03:23:26"
  },
  "thumbnailId" : "b5094212-1b86-409a-8ce5-8625bfa2c572",
  "boxContent" : {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "ef3295ab-fc0b-4466-9733-8843bf420c8c",
    "contentId" : "urn:wim:tv:content:1c15a883-c73e-4df1-a671-8ba9b62144a4",
    "boxId" : "cadac65b-4204-4ef7-96a6-7b45b098583e",
    "duration" : "8:10",
    "thumbnailId" : "b5094212-1b86-409a-8ce5-8625bfa2c572"
  },
  "itemType" : "PRERECORDED",
  "programId" : "6942a62c-60dc-42d1-af00-141dae2a1979"
}

Response fields

Path Type Description

programId

String

The WimCast program identifier.

title

String

Title.

description

String

Description. May be not provided.

startDate

DateTime

The start-time.

endDate

DateTime

The end-time.

itemType

Item Type

Program type.

boxContent

Object

The content. Provided only if the item type is PRERECORDED.

stream

Object

The live stream. Provided only if the item type is LIVE.

offset

Number

Offset where to start playing the content (seconds). May be provided only if the item type is PRERECORDED.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Content fields

Path Type Description

boxId

String

The WimBox item identifier.

contentId

String

The content identifier.

title

String

Title.

description

String

Description. May be not provided.

resourceId

String

The resource identifier.

duration

Duration

Duration.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Reads a program in public pages

$ curl 'http://www.wim.tv:8080/api/public/cast/program/f19ad535-231c-4d31-a56e-0b3105d00401' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/public/cast/program/{programId}

Parameter Description

programId

The WimCast program identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 919

{
  "title" : "Title 1",
  "description" : "Description 1",
  "tags" : [ "tag10", "tag11", "tag12" ],
  "endDate" : {
    "date" : "08/09/2020",
    "time" : "04:27:13"
  },
  "startDate" : {
    "date" : "08/09/2020",
    "time" : "04:17:15"
  },
  "thumbnailId" : "8c053f08-0477-447d-a683-6e87a7e1f4c8",
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "eb102064-6bab-4225-b721-d83bed98855d",
    "thumbnailId" : "92a04962-b77f-482b-be2d-d973b6b8d1cb",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "name" : "Channel 1"
  },
  "itemType" : "PRERECORDED",
  "programId" : "f19ad535-231c-4d31-a56e-0b3105d00401"
}

Response fields

Path Type Description

programId

String

The WimCast program identifier.

title

String

Title.

description

String

Description. May be not provided.

channel

Channel

The channel.

startDate

DateTime

The start-time.

endDate

DateTime

The end-time.

itemType

Item Type

Program type.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Updates an existing program

Using this API you can update only the descriptive data of a program: if you want to update when a program starts or ends, you should use the WimCast daily programming APIs.

$ curl 'http://www.wim.tv:8080/api/cast/program/6942a62c-60dc-42d1-af00-141dae2a1979' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "title" : "Title modified",
  "description" : "Description modified",
  "tags" : [ "m1", "m2" ]
}'

Path parameters

/api/cast/program/{programId}

Parameter Description

programId

The WimCast program identifier.

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

title

String

Title.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

thumbnailId

String

Identifier of the thumbnail to assign to the program.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 737

{
  "title" : "Title modified",
  "description" : "Description modified",
  "tags" : [ "m1", "m2" ],
  "endDate" : {
    "date" : "08/09/2020",
    "time" : "03:31:36"
  },
  "startDate" : {
    "date" : "08/09/2020",
    "time" : "03:23:26"
  },
  "boxContent" : {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "ef3295ab-fc0b-4466-9733-8843bf420c8c",
    "contentId" : "urn:wim:tv:content:1c15a883-c73e-4df1-a671-8ba9b62144a4",
    "boxId" : "cadac65b-4204-4ef7-96a6-7b45b098583e",
    "duration" : "8:10",
    "thumbnailId" : "b5094212-1b86-409a-8ce5-8625bfa2c572"
  },
  "itemType" : "PRERECORDED",
  "programId" : "6942a62c-60dc-42d1-af00-141dae2a1979"
}

Response fields

Searches for WimCast programs in public pages

$ curl 'http://www.wim.tv:8080/api/public/search/cast/programs' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "queryString" : "ch10 ch21",
  "pageSize" : 3,
  "pageIndex" : 0
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

pageSize

Number

Number of item per page.

* Required.
* Must be at least 1.

pageIndex

Number

Index of the page to read.

* Required.
* Must be at least 0.

queryString

String

Query string.

* Optional.

userCode

String

A user code.

* Optional.
* Length must be between 0 and 50 inclusive.

channelId

String

The WimCast channel identifier.

* Optional.
* Length must be between 0 and 36 inclusive.

Query string

The query string applies on the following fields:

  • Program

    • Title

    • Description

    • Tags

  • Channel (boost: 0.7; if not provided as filter)

    • Name

    • Description

    • Tags

  • Publisher (boost: 0.5; if not provided as filter)

    • Username

    • First name

    • Last name

    • Page title

    • Page description

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 3029

{
  "items" : [ {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:27:13"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:17:15"
    },
    "thumbnailId" : "8c053f08-0477-447d-a683-6e87a7e1f4c8",
    "channel" : {
      "description" : "Description 1",
      "tags" : [ "ch10", "ch11", "ch12" ],
      "channelId" : "eb102064-6bab-4225-b721-d83bed98855d",
      "thumbnailId" : "92a04962-b77f-482b-be2d-d973b6b8d1cb",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Channel 1"
    },
    "itemType" : "PRERECORDED",
    "programId" : "f19ad535-231c-4d31-a56e-0b3105d00401"
  }, {
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:32:53"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:27:13"
    },
    "thumbnailId" : "06f5b8b3-daf6-446c-9e88-c56eb8a65401",
    "channel" : {
      "description" : "Description 1",
      "tags" : [ "ch10", "ch11", "ch12" ],
      "channelId" : "eb102064-6bab-4225-b721-d83bed98855d",
      "thumbnailId" : "92a04962-b77f-482b-be2d-d973b6b8d1cb",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Channel 1"
    },
    "itemType" : "PRERECORDED",
    "programId" : "377d872b-1ab6-4495-8ced-49f8c512bc81"
  }, {
    "title" : "Stream 2",
    "description" : "Description 2",
    "tags" : [ "st20", "st21", "st22" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:44:36"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:32:53"
    },
    "thumbnailId" : "46d50f5a-0c5a-46c7-9303-9589a6498e39",
    "channel" : {
      "description" : "Description 1",
      "tags" : [ "ch10", "ch11", "ch12" ],
      "channelId" : "eb102064-6bab-4225-b721-d83bed98855d",
      "thumbnailId" : "92a04962-b77f-482b-be2d-d973b6b8d1cb",
      "publisher" : {
        "pageTitle" : "WimLabs",
        "pageDescription" : "Video Communications",
        "facebookUrl" : "http://www.facebook.com/wimlabs",
        "twitterContact" : "@wimlabs",
        "linkedinUrl" : "http://www.linkedin.com/wimlabs",
        "userCode" : "john"
      },
      "name" : "Channel 1"
    },
    "itemType" : "LIVE",
    "programId" : "f7ab9ea8-784d-45ba-85d0-643399bafdfa"
  } ],
  "pageSize" : 3,
  "pageIndex" : 0,
  "totalCount" : 20,
  "pageCount" : 7
}

Response fields

Item fields

Sort

The items are sorted by the following fields:

  1. Start time

  2. End time

WimCast daily programming

You schedule the programs in a channel day-by-day.
You schedule the programs in a day within a daily timetable from the start-time (when the first program may start) to end-time (when the last program ends).

The programs sequence must be continuous, that is each program starts when the previous program finishes.
You can insert a break between two programs as a special kind of program, called BREAK, with a start-time and an end-time.

Reads a daily programming

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2453

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:56:31"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:05:41"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:56:31"
    },
    "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786",
    "boxContent" : {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "resourceId" : "118a4105-b91c-43b6-b64c-1e28611698ae",
      "contentId" : "urn:wim:tv:content:22e55528-9556-4fe5-9990-c9216ebb6cdf",
      "boxId" : "22affff5-1b84-49f4-ae0d-48b68b192814",
      "duration" : "9:10",
      "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786"
    },
    "itemType" : "PRERECORDED",
    "programId" : "7b61f385-ff9e-4a2c-bdd9-76e40a3f4845"
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:13:27"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "05:05:41"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "4496d132-22a4-4026-8f8b-cbaaae949df8"
  } ]
}

Response fields

Path Type Description

channel

Channel

WimCast channel.

targetDate

Date

The programming date.

startDateMin

DateTime

Minimum start-time of the programs.

endDateMax

DateTime

Maximum end-time of the programs.

programs

Array

Array of programs.

Program fields

Path Type Description

programId

String

The WimCast program identifier. Provided only if item type is PRERECORDED or LIVE.

title

String

Title.

description

String

Description. May be not provided.

startDate

DateTime

The start-time.

endDate

DateTime

The end-time.

itemType

Item Type

Program type.

boxContent

Object

The content. Provided only if the item type is PRERECORDED.

stream

Object

The live stream. Provided only if the item type is LIVE.

offset

Number

Offset where to start playing the content (seconds). May be provided only if the item type is PRERECORDED.

thumbnailId

String

The thumbnail identifier. May be not provided.

tags

Array of String

Array of tags. May be not provided.

Saves a daily programming

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "programs" : [ {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "sourceId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
    "programType" : "LIVE"
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "sourceId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a",
    "programType" : "PRERECORDED"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "sourceId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
    "programType" : "LIVE"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:14:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "sourceId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "programType" : "LIVE"
  } ]
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

programs

Array

Array of programs.

* Required.

The programs array must be properly sorted by startDate and endDate properties, otherwise you could get errors about programs that overlap each other.

Program fields

Path Type Description

programId

String

The program identifier.

* Must be set only if program already exists.
* Length must be between 0 and 36 inclusive.

title

String

Title.

* Required.
* Length must be between 0 and 50 inclusive.
* Must not be blank.

description

String

Description.

* Optional.
* Length must be between 0 and 400 inclusive.

startDate

DateTime

Start-time.

* Required.
* Must not be null.

endDate

DateTime

End-time.

* Required.
* Must not be null.

programType

Item Type

Program type.

* Required.
* Must not be null.

sourceId

String

The source identifier (WimBox item, WimCast live stream).

* Required.
* Length must be between 0 and 36 inclusive.
* Must not be blank.

offset

Number

Offset where to start playing the content (seconds).

* May be provided only if the item type is PRERECORDED.
* Must be at least 0.

thumbnailId

String

Identifier of the thumbnail to assign to the program.

* Optional.
* Length must be between 0 and 36 inclusive.

tags

Array of String

Array of tags.

* Optional.
* Length of each element must be between 1 and 80.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 3683

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "0c7c4015-0902-4ed9-aa7f-3c4fc40f121c",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "0c2d5c2c-8580-4c25-8f47-9264dce84308",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:14:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  } ]
}

Response fields

Removes all programs from a daily programming

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908' -i -X DELETE -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 541

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ ]
}

Response fields

Inserts one or more programs in a daily programming

You can pick up one or more programs to insert in the daily timetable from the following sources:

  • The contents in your WimBox.

  • The live streams in your WimCast. If you select one or more live streams, you have to set the duration of the broadcasting for each selected stream.

  • The programs scheduled in another channel in a certain day.

  • The programs scheduled in the same channel for another day.

  • The BREAK. If you insert a BREAK, you have to set its duration.


  • If you insert a program at the beginning of the daily timetable, the start-time is set to the start-time of the timetable, and the end-time is calculated in order to preserve the duration of the program.

  • If you insert a program below another program, the start-time is set to the end-time of the previous program, and the end-time is calculated in order to preserve the duration of the program.

If you have selected more than one program, the further programs are inserted below the first, and the start-time and the end-time of each program are calculated in order to preserve the duration of each program and to keep the programs sequence continuous.

Anyway, the programs below the insertion point are shifted in order to preserve the duration of each program and to keep the programs sequence continuous.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/insert' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "sourceItems" : [ {
    "sourceType" : "PRERECORDED",
    "sourceId" : "22affff5-1b84-49f4-ae0d-48b68b192814"
  }, {
    "sourceType" : "PROGRAM",
    "sourceId" : "e1ee631e-93b4-4360-8e45-24582035ac76"
  }, {
    "sourceType" : "BREAK",
    "duration" : 1200
  } ],
  "index" : 1
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/insert

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Insertion index.

* Required.
* Must be at least 0.

sourceItems

Array

Items to insert.

* Required.
* Must not be null.

Program source

Path Type Description

sourceType

Source Type

Source type.

* Required.
* Must not be null.

sourceId

String

The source identifier (WimBox item, WimCast live stream or WimCast program).

* Must be set only if the source type is PRERECORDED or LIVE or PROGRAM.
* Length must be between 0 and 36 inclusive.

duration

Number

Duration (seconds).

* Must be set only if the source type is LIVE or BREAK.
* Must be at least 1.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 4200

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:09:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786",
    "boxContent" : {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "resourceId" : "118a4105-b91c-43b6-b64c-1e28611698ae",
      "contentId" : "urn:wim:tv:content:22e55528-9556-4fe5-9990-c9216ebb6cdf",
      "boxId" : "22affff5-1b84-49f4-ae0d-48b68b192814",
      "duration" : "9:10",
      "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786"
    },
    "itemType" : "PRERECORDED",
    "programId" : "672010c6-255a-4221-a952-bf1286cc96e2"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:09:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:09:10"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:29:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "03:09:10"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:29:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "03:29:10"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "e1ee631e-93b4-4360-8e45-24582035ac76",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:36:56"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:29:10"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  } ]
}

Response fields

Moves a program in a daily programming

You can move the programs along the daily timetable.

  • If you move a program at the beginning of the daily timetable, the start-time is moved at the start-time of the timetable, and the end-time is recalculated in order to preserve the program duration.

  • If you move a program below another program, the start-time is moved at the end-time of the previous program, and the end-time is recalculated to preserve the program duration.

Anyway, the other programs are shifted in order to preserve the duration of each program and to keep the programs sequence continuous.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/move' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "fromIndex" : 1,
  "toIndex" : 4
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/move

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

fromIndex

Number

Index of the program to move.

* Required.
* Must be at least 0.

toIndex

Number

Index of the program before of which insert the moved program.

* Required.
* Must be at least 0.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 4200

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:00:00"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:20:00"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "03:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Title 2",
    "description" : "Description 2",
    "tags" : [ "tag20", "tag21", "tag22" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:29:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "03:20:00"
    },
    "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786",
    "boxContent" : {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "resourceId" : "118a4105-b91c-43b6-b64c-1e28611698ae",
      "contentId" : "urn:wim:tv:content:22e55528-9556-4fe5-9990-c9216ebb6cdf",
      "boxId" : "22affff5-1b84-49f4-ae0d-48b68b192814",
      "duration" : "9:10",
      "thumbnailId" : "0e1d0274-0997-4474-bbec-783ff1d15786"
    },
    "itemType" : "PRERECORDED",
    "programId" : "672010c6-255a-4221-a952-bf1286cc96e2"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:29:10"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "03:29:10"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "e1ee631e-93b4-4360-8e45-24582035ac76",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:36:56"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:29:10"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  } ]
}

Response fields

Splits a program

You can split a program, for example, in order to insert a BREAK or an advertising.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/split' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "index" : 1,
  "offset" : 233
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/split

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Index of the program to split.

* Required.
* Must be at least 0.

offset

Number

Offset where to split the program (seconds).

* Required.
* Must be at least 1.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 4551

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "0c7c4015-0902-4ed9-aa7f-3c4fc40f121c",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:20:33"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:20:33"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "b86b6f08-edac-4a22-9e91-2a1ad99bd77d",
    "offset" : 233
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "0c2d5c2c-8580-4c25-8f47-9264dce84308",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:14:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:31:06"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  } ]
}

Response fields

Removes one or more programs from a daily programming

You can remove one or more programs from a daily timetable.
The succeeding programs are shifted in order to preserve the duration of each program and to keep the programs sequence continuous.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/remove' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "count" : 3,
  "index" : 2
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/remove

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Index of the first program to remove.

* Required.
* Must be at least 0.

count

Number

Number of programs to remove.

* Required.
* Must be at least 1.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2370

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "00:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  }, {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:07:46"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "03:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:07:46"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  } ]
}

Response fields

Updating the time when a program starts or ends

You can update the start-time or the end-time of a program, but this may involve the entire daily programming, so you have to update individually the start-time or the end-time.

  • If your update results in a empty space before the modified program, a BREAK is inserted in order to preserve the programs sequence continuous.

  • If your update results in a empty space after the modified program, the succeeding programs are moved back in order to preserve the duration of each program and to keep the programs sequence continuous.

  • If your update results in a overlap among the modified program and the succeeding programs, the succeeding programs are moved forward in order to preserve the duration of each program and to keep the programs sequence continuous.

Remember that a program in a timetable for a day, must start at or after that day at 00:00:00 and before the next day at 00:00:00, but may end the next day; however the programs in the timetable for a day can not overlap with programs scheduled in the previous day neither in the next day.

Updates the time when a program starts

  • You cannot move the start-time back.

  • If the program has been picked up from your WimBox, the end-time is recalculated in order to preserve the duration.

  • If the program has not been picked up from your WimBox,

    • If you keep the start-time before the end-time, the result is a shorter duration.

    • If you put the start-time equal or after the end-time, the end-time is recalculated in order to preserve the duration.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/startdate' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "startDate" : {
    "date" : "08/09/2020",
    "time" : "02:00:00"
  },
  "index" : 0
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/startdate

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Index of the program to update.

* Required.
* Must be at least 0.

startDate

DateTime

The new date when the program will start.

* Required.
* Must not be null.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2587

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:00:00"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  }, {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:07:46"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:07:46"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:07:46"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  } ]
}

Response fields

Updates the time when a program ends

  • The end-time of a program cannot be equal to the start-time.

  • If the program has been picked up from your WimBox,

    • You cannot move the end-time back.

    • If you move forward the end-time, the start-time is recalculated in order to preserve the duration.

  • If the program has not been picked up from your WimBox, the start-time is kept, so:

    • If you move the end-time back, the result is a shorter duration.

    • If you move the end-time forward, the result is a longer duration.

$ curl 'http://www.wim.tv:8080/api/cast/channel/cb851923-3b08-4d88-a88e-46beee7c827b/dailyprogramming/20200908/enddate' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "endDate" : {
    "date" : "08/09/2020",
    "time" : "02:16:40"
  },
  "index" : 0
}'

Path parameters

/api/cast/channel/{channelId}/dailyprogramming/{date}/enddate

Parameter Description

channelId

The WimCast channel identifier.

date

Programming date (yyyyMMdd).

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

index

Number

Index of the program to update.

* Required.
* Must be at least 0.

endDate

DateTime

The new date when the program will end.

* Required.
* Must not be null.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 2587

{
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "cb851923-3b08-4d88-a88e-46beee7c827b",
    "streamPath" : "channel1",
    "thumbnailId" : "703aa038-f34d-40da-bd4a-bda5be7049a8",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  },
  "targetDate" : "08/09/2020",
  "startDateMin" : {
    "date" : "08/09/2020",
    "time" : "00:00:00"
  },
  "endDateMax" : {
    "date" : "10/09/2020",
    "time" : "00:00:00"
  },
  "programs" : [ {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "00:00:00"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:16:40"
    },
    "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b",
    "boxContent" : {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "resourceId" : "77af26a5-3737-418c-8143-b48384e4f815",
      "contentId" : "urn:wim:tv:content:1b36162a-fec2-472a-b209-e74e0416c77a",
      "boxId" : "92e22b0f-2e8e-4a45-9b34-5d66bdbd0caa",
      "duration" : "7:46",
      "thumbnailId" : "b7910c88-5959-4c87-99dd-20d6280e376b"
    },
    "itemType" : "PRERECORDED",
    "programId" : "e18d775c-cb58-49ea-88e1-637bf631599a"
  }, {
    "title" : "BREAK",
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "04:41:06"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "02:24:26"
    },
    "itemType" : "BREAK"
  }, {
    "title" : "Stream 1",
    "description" : "Description 1",
    "tags" : [ "st10", "st11", "st12" ],
    "endDate" : {
      "date" : "08/09/2020",
      "time" : "05:24:26"
    },
    "startDate" : {
      "date" : "08/09/2020",
      "time" : "04:41:06"
    },
    "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
    "itemType" : "LIVE",
    "programId" : "4fb64330-801a-4d6c-8ed3-ac2a9bf378f2",
    "stream" : {
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "streamPath" : "stream1",
      "thumbnailId" : "9372beb9-919a-4bc2-bf90-8ede973557a7",
      "streamId" : "2c0d5e8f-caf5-42d3-8c3a-b6d2b41d3836",
      "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
      "name" : "Stream 1"
    }
  } ]
}

Response fields

WimCast programming calendar

Reads a programming

$ curl 'http://www.wim.tv:8080/api/cast/channel/17259f97-ce0d-4a17-b8d2-5c9ae5699394/calendar/20200908/2' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/calendar/{startDate}/{dayCount}

Parameter Description

channelId

The WimCast channel identifier.

startDate

Start date of the programming (yyyyMMdd).

dayCount

Number of days of the programming.

You can select the daily programmings within any period you want.

Selects a week
$ curl 'http://www.wim.tv:8080/api/cast/channel/4e8ae0d0-f355-425a-9ee1-a63775b7d826/calendar/20201026/7' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 3600000'

October 2020

Mon

Tue

Wed

Thu

Fri

Sat

Sun

26

27

28

29

30

31

1 Nov

Selects a month
$ curl 'http://www.wim.tv:8080/api/cast/channel/4e8ae0d0-f355-425a-9ee1-a63775b7d826/calendar/20201001/31' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 3600000'
October 2020

1

2

3

…​

31

Selects a month of weekly programmings
$ curl 'http://www.wim.tv:8080/api/cast/channel/4e8ae0d0-f355-425a-9ee1-a63775b7d826/calendar/20200928/35' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 3600000'

October 2020

Mon

Tue

Wed

Thu

Fri

Sat

Sun

28 Sep

29 Sep

30 Sep

1

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

1 Nov

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 9184

{
  "endDate" : "09/09/2020",
  "startDate" : "08/09/2020",
  "dailyProgrammings" : [ {
    "targetDate" : "08/09/2020",
    "programs" : [ {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "endDate" : {
        "date" : "08/09/2020",
        "time" : "09:00:03"
      },
      "startDate" : {
        "date" : "08/09/2020",
        "time" : "08:54:40"
      },
      "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632",
      "boxContent" : {
        "title" : "Title 2",
        "description" : "Description 2",
        "tags" : [ "tag20", "tag21", "tag22" ],
        "resourceId" : "752fe5f3-d849-4b2a-b647-a513dd510421",
        "contentId" : "urn:wim:tv:content:fe423a40-c000-4382-87cb-f5889d5a0c0e",
        "boxId" : "c3ea0f87-f9ef-4339-aff7-b1b6754ba0ed",
        "duration" : "5:23",
        "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632"
      },
      "itemType" : "PRERECORDED",
      "programId" : "cd28f706-15e6-40c1-81c1-381cd66f8723"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "08/09/2020",
        "time" : "09:07:31"
      },
      "startDate" : {
        "date" : "08/09/2020",
        "time" : "09:00:03"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "20a2f038-26b1-4d67-8eaf-77d852d8d5f4"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "08/09/2020",
        "time" : "09:15:40"
      },
      "startDate" : {
        "date" : "08/09/2020",
        "time" : "09:08:12"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "3d5d3135-eece-4354-a649-25fe4110cdad"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "08/09/2020",
        "time" : "09:23:08"
      },
      "startDate" : {
        "date" : "08/09/2020",
        "time" : "09:15:40"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "2d59ec41-f051-48f9-b0f6-16ad94d322d6"
    }, {
      "title" : "Stream 2",
      "description" : "Description 2",
      "tags" : [ "st20", "st21", "st22" ],
      "endDate" : {
        "date" : "08/09/2020",
        "time" : "09:35:20"
      },
      "startDate" : {
        "date" : "08/09/2020",
        "time" : "09:23:08"
      },
      "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
      "itemType" : "LIVE",
      "programId" : "e387333c-06d1-47e9-881e-754ca72299c4",
      "stream" : {
        "description" : "Description 2",
        "tags" : [ "st20", "st21", "st22" ],
        "streamPath" : "stream2",
        "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
        "streamId" : "d37b1ae0-a5b2-4c5f-9556-63cb41041158",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 2"
      }
    } ]
  }, {
    "targetDate" : "09/09/2020",
    "programs" : [ {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "09/09/2020",
        "time" : "04:16:34"
      },
      "startDate" : {
        "date" : "09/09/2020",
        "time" : "04:09:07"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "a1c4f373-1e98-4658-9afc-5a430421e156",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "09/09/2020",
        "time" : "04:25:49"
      },
      "startDate" : {
        "date" : "09/09/2020",
        "time" : "04:16:34"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "b9106fbb-82b6-4323-b54d-6c957a2ed319",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "09/09/2020",
        "time" : "04:35:29"
      },
      "startDate" : {
        "date" : "09/09/2020",
        "time" : "04:25:49"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "392035c2-fb55-4f9b-899d-c1aacbbdad20",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "09/09/2020",
        "time" : "04:42:57"
      },
      "startDate" : {
        "date" : "09/09/2020",
        "time" : "04:35:29"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "dfa5e9c7-bb00-4ddb-a916-ee75dd1ba1ff"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "09/09/2020",
        "time" : "04:50:25"
      },
      "startDate" : {
        "date" : "09/09/2020",
        "time" : "04:42:57"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "297b1daf-7623-40ec-bae0-358d4f361c19"
    } ]
  } ],
  "channel" : {
    "description" : "Description 1",
    "tags" : [ "ch10", "ch11", "ch12" ],
    "channelId" : "17259f97-ce0d-4a17-b8d2-5c9ae5699394",
    "streamPath" : "channel1",
    "thumbnailId" : "8eaec2a8-82cf-4428-8bfc-91b61f4560fd",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 1"
  }
}

Response fields

Path Type Description

channel

Channel

WimCast channel.

startDate

Date

Start date of the programming.

endDate

Date

End date of the programming.

dailyProgrammings

Array

Array of daily programmings. May be empty.

The response includes always the whole selected period even the days with no programs within.

Programming fields

Path Type Description

targetDate

Date

The programming date.

programs

Array

Array of programs.

Copies a period of daily programmings to another period

$ curl 'http://www.wim.tv:8080/api/cast/calendar/copy' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "destChannelId" : "7ffa9dd1-fa1f-45cb-b341-bab11dfce2d2",
  "sourceStartDate" : "08/09/2020",
  "sourceDayCount" : 2,
  "destStartDate" : "18/09/2020",
  "destDayCount" : 3,
  "sourceChannelId" : "17259f97-ce0d-4a17-b8d2-5c9ae5699394"
}'

Request headers

Name Description

Content-Type

application/json

* Required.

Accept

application/json

* Required.

Request fields

Path Type Description

sourceChannelId

String

Source channel identifier.

* Required.
* Length must be between 0 and 36 inclusive.
* Must not be blank.

sourceStartDate

Date

Date of the first daily programming to copy.

* Required.
* Must not be null.

sourceDayCount

Number

Number of daily programmings to copy.

* Required.
* Must be at least 1.

destChannelId

String

Destination channel identifier. May be equal the source channel.

* Required.
* Length must be between 0 and 36 inclusive.
* Must not be blank.

destStartDate

Date

Date of the first day of the destination period.

* Required.
* Must not be null.

destDayCount

Number

Number of days in the destination period. It will be rounded-up to the nearest multiple of sourceDayCount not less than sourceDayCount.

* Required.
* Must be at least 1.

You can also replicate a period of daily programmings more than one time to a longer period.

Replicates a programming from a week to another week
$ curl 'http://www.wim.tv:8080/api/cast/calendar/copy' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 3600000' -d '{
  "destChannelId" : "85348238-76a5-4f86-919d-77b0b635651d",
  "sourceStartDate" : "02/03/2020",
  "sourceDayCount" : 7,
  "destStartDate" : "16/03/2030",
  "destDayCount" : 1,
  "sourceChannelId" : "f3fd1ef2-a72d-49ff-8e75-0cf1f9a72a6b"
}'

March 2020

Copy from

to

2

16

3

17

4

18

5

19

6

20

7

21

8

22

Replicates a programming from a week to other two weeks
$ curl 'http://www.wim.tv:8080/api/cast/calendar/copy' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 3600000' -d '{
  "destChannelId" : "85348238-76a5-4f86-919d-77b0b635651d",
  "sourceStartDate" : "12/10/2020",
  "sourceDayCount" : 7,
  "destStartDate" : "19/10/2020",
  "destDayCount" : 10,
  "sourceChannelId" : "f3fd1ef2-a72d-49ff-8e75-0cf1f9a72a6b"
}'

October 2020

Copy from

to

to

12

19

26

13

20

27

14

21

28

15

22

29

16

23

30

17

24

31

18

25

1 Nov

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 17944

{
  "endDate" : "21/09/2020",
  "startDate" : "18/09/2020",
  "dailyProgrammings" : [ {
    "targetDate" : "18/09/2020",
    "programs" : [ {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "endDate" : {
        "date" : "18/09/2020",
        "time" : "09:00:03"
      },
      "startDate" : {
        "date" : "18/09/2020",
        "time" : "08:54:40"
      },
      "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632",
      "boxContent" : {
        "title" : "Title 2",
        "description" : "Description 2",
        "tags" : [ "tag20", "tag21", "tag22" ],
        "resourceId" : "752fe5f3-d849-4b2a-b647-a513dd510421",
        "contentId" : "urn:wim:tv:content:fe423a40-c000-4382-87cb-f5889d5a0c0e",
        "boxId" : "c3ea0f87-f9ef-4339-aff7-b1b6754ba0ed",
        "duration" : "5:23",
        "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632"
      },
      "itemType" : "PRERECORDED",
      "programId" : "feb94b5d-a927-4df0-9a85-8b98e326efce"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "18/09/2020",
        "time" : "09:07:31"
      },
      "startDate" : {
        "date" : "18/09/2020",
        "time" : "09:00:03"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "39909eb0-ccb0-4fb3-ada3-a73bb99b6f8f"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "18/09/2020",
        "time" : "09:15:40"
      },
      "startDate" : {
        "date" : "18/09/2020",
        "time" : "09:08:12"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "b95b0eb4-de52-4e3f-a0ae-52b7684dbdff"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "18/09/2020",
        "time" : "09:23:08"
      },
      "startDate" : {
        "date" : "18/09/2020",
        "time" : "09:15:40"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "a57e50ae-375f-471f-a0eb-00ab51e52f76"
    }, {
      "title" : "Stream 2",
      "description" : "Description 2",
      "tags" : [ "st20", "st21", "st22" ],
      "endDate" : {
        "date" : "18/09/2020",
        "time" : "09:35:20"
      },
      "startDate" : {
        "date" : "18/09/2020",
        "time" : "09:23:08"
      },
      "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
      "itemType" : "LIVE",
      "programId" : "059eb475-ada9-4a9f-b1d5-7da50b863a39",
      "stream" : {
        "description" : "Description 2",
        "tags" : [ "st20", "st21", "st22" ],
        "streamPath" : "stream2",
        "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
        "streamId" : "d37b1ae0-a5b2-4c5f-9556-63cb41041158",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 2"
      }
    } ]
  }, {
    "targetDate" : "19/09/2020",
    "programs" : [ {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "19/09/2020",
        "time" : "04:16:34"
      },
      "startDate" : {
        "date" : "19/09/2020",
        "time" : "04:09:07"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "99bf026b-3891-47dc-9a92-f6608d915e63",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "19/09/2020",
        "time" : "04:25:49"
      },
      "startDate" : {
        "date" : "19/09/2020",
        "time" : "04:16:34"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "97ab8948-1fee-4b89-9919-215d12778b89",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "19/09/2020",
        "time" : "04:35:29"
      },
      "startDate" : {
        "date" : "19/09/2020",
        "time" : "04:25:49"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "7afc75e1-fb47-4ac9-8c1f-c16f71a94c33",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "19/09/2020",
        "time" : "04:42:57"
      },
      "startDate" : {
        "date" : "19/09/2020",
        "time" : "04:35:29"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "2cf30299-bc7a-470b-a173-2e61d73c5a05"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "19/09/2020",
        "time" : "04:50:25"
      },
      "startDate" : {
        "date" : "19/09/2020",
        "time" : "04:42:57"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "1b79f466-a36d-46d7-876a-608e7dc02bcf"
    } ]
  }, {
    "targetDate" : "20/09/2020",
    "programs" : [ {
      "title" : "Title 2",
      "description" : "Description 2",
      "tags" : [ "tag20", "tag21", "tag22" ],
      "endDate" : {
        "date" : "20/09/2020",
        "time" : "09:00:03"
      },
      "startDate" : {
        "date" : "20/09/2020",
        "time" : "08:54:40"
      },
      "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632",
      "boxContent" : {
        "title" : "Title 2",
        "description" : "Description 2",
        "tags" : [ "tag20", "tag21", "tag22" ],
        "resourceId" : "752fe5f3-d849-4b2a-b647-a513dd510421",
        "contentId" : "urn:wim:tv:content:fe423a40-c000-4382-87cb-f5889d5a0c0e",
        "boxId" : "c3ea0f87-f9ef-4339-aff7-b1b6754ba0ed",
        "duration" : "5:23",
        "thumbnailId" : "9d263453-871e-4f4c-82d1-a56444d59632"
      },
      "itemType" : "PRERECORDED",
      "programId" : "043547dc-060f-4331-972d-124d845cad61"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "20/09/2020",
        "time" : "09:07:31"
      },
      "startDate" : {
        "date" : "20/09/2020",
        "time" : "09:00:03"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "f496885f-8233-4709-9a85-d0abc40e4c9e"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "20/09/2020",
        "time" : "09:15:40"
      },
      "startDate" : {
        "date" : "20/09/2020",
        "time" : "09:08:12"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "2c5af272-9a18-448b-9bb3-3990d9f47709"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "20/09/2020",
        "time" : "09:23:08"
      },
      "startDate" : {
        "date" : "20/09/2020",
        "time" : "09:15:40"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "32c25be1-0561-4dcd-bff0-912419c09a2c"
    }, {
      "title" : "Stream 2",
      "description" : "Description 2",
      "tags" : [ "st20", "st21", "st22" ],
      "endDate" : {
        "date" : "20/09/2020",
        "time" : "09:35:20"
      },
      "startDate" : {
        "date" : "20/09/2020",
        "time" : "09:23:08"
      },
      "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
      "itemType" : "LIVE",
      "programId" : "2bcb340a-d976-4df7-83b2-4265a325f3dc",
      "stream" : {
        "description" : "Description 2",
        "tags" : [ "st20", "st21", "st22" ],
        "streamPath" : "stream2",
        "thumbnailId" : "b88a1c5b-883d-41dc-8f4a-2dd01f31e535",
        "streamId" : "d37b1ae0-a5b2-4c5f-9556-63cb41041158",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 2"
      }
    } ]
  }, {
    "targetDate" : "21/09/2020",
    "programs" : [ {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "21/09/2020",
        "time" : "04:16:34"
      },
      "startDate" : {
        "date" : "21/09/2020",
        "time" : "04:09:07"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "fe8723db-f02d-43d7-ab28-4a23f9c19573",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "21/09/2020",
        "time" : "04:25:49"
      },
      "startDate" : {
        "date" : "21/09/2020",
        "time" : "04:16:34"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "e5f0340d-ca74-4acf-b19a-ff4b038defe4",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Stream 1",
      "description" : "Description 1",
      "tags" : [ "st10", "st11", "st12" ],
      "endDate" : {
        "date" : "21/09/2020",
        "time" : "04:35:29"
      },
      "startDate" : {
        "date" : "21/09/2020",
        "time" : "04:25:49"
      },
      "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
      "itemType" : "LIVE",
      "programId" : "861772c0-0faa-4cc7-9249-e657eb3fb0b7",
      "stream" : {
        "description" : "Description 1",
        "tags" : [ "st10", "st11", "st12" ],
        "streamPath" : "stream1",
        "thumbnailId" : "bee9596d-add5-4444-9cb8-3f74e4e680d6",
        "streamId" : "91200906-db10-4f2f-b90d-5711350beb66",
        "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
        "name" : "Stream 1"
      }
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "21/09/2020",
        "time" : "04:42:57"
      },
      "startDate" : {
        "date" : "21/09/2020",
        "time" : "04:35:29"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "a46b8c77-d430-4af0-868c-01df4f6a232b"
    }, {
      "title" : "Title 1",
      "description" : "Description 1",
      "tags" : [ "tag10", "tag11", "tag12" ],
      "endDate" : {
        "date" : "21/09/2020",
        "time" : "04:50:25"
      },
      "startDate" : {
        "date" : "21/09/2020",
        "time" : "04:42:57"
      },
      "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b",
      "boxContent" : {
        "title" : "Title 1",
        "description" : "Description 1",
        "tags" : [ "tag10", "tag11", "tag12" ],
        "resourceId" : "15d7cb2d-d02b-4ffe-8567-f717f59e497c",
        "contentId" : "urn:wim:tv:content:53dbd7af-7ae5-430b-9ab7-2f9a26b82208",
        "boxId" : "8ed12866-f478-45cd-a64e-9c1a68a1a1be",
        "duration" : "7:28",
        "thumbnailId" : "e54c668c-5cb2-47c9-bfbd-0ee513be560b"
      },
      "itemType" : "PRERECORDED",
      "programId" : "951d848f-7a57-4d4c-88be-c16161cbc5af"
    } ]
  } ],
  "channel" : {
    "description" : "Description 2",
    "tags" : [ "ch20", "ch21", "ch22" ],
    "channelId" : "7ffa9dd1-fa1f-45cb-b341-bab11dfce2d2",
    "streamPath" : "channel2",
    "thumbnailId" : "b52be85d-65bf-4358-a36f-06c5edf465b0",
    "streamingBaseUrl" : "rtmp://www.wim.tv:1935/programming",
    "name" : "Channel 2"
  }
}

Response fields

The response includes always the whole destination period even the days with no programs within.
The response includes only the copied programs: if other programs have been already scheduled in the destination period, they are not included in the response.

Deletes a programming

$ curl 'http://www.wim.tv:8080/api/cast/channel/17259f97-ce0d-4a17-b8d2-5c9ae5699394/calendar/20200908/2' -i -X DELETE -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/cast/channel/{channelId}/calendar/{startDate}/{dayCount}

Parameter Description

channelId

The WimCast channel identifier.

startDate

Start date of the programming (yyyyMMdd).

dayCount

Number of days of the programming.

Response

HTTP/1.1 204 No Content

Payments

A payment process is always built up on two APIs: one for getting the payment parameters and one for checking whether the payment has succeeded or not.

Payment flow

2-steps payment flow
  1. You call the Payment API.

  2. You have to redirect your browser to the PayPal service page reachable through by the url field in the response.

  3. If the user accepts the payment, PayPal redirects to your Web page reachable through by the returnUrl field in the request.

  4. If the user rejects the payment, PayPal redirects to your Web page reachable through by the cancelUrl field in the request.

  5. When the browser returns to your Web page, you should call the Payment check API.

  6. If the payment has succeeded, the transaction will be performed, otherwise you will get an error.

Sometimes a transaction may be free or not free, in such cases the flow is slightly different.

3-steps payment flow
  1. You call the transaction API.

  2. If the transaction is free, it will be performed and that’s all.

  3. If the transaction is not free, the API returns a payment request.

  4. Now you call the Payment API.

  5. You have to redirect your browser to the PayPal service page reachable through by the url field in the response.

  6. If the user accepts the payment, PayPal redirects to your Web page reachable through by the returnUrl field in the request.

  7. If the user rejects the payment, PayPal redirects to your Web page reachable through by the cancelUrl field in the request.

  8. When the browser returns to your Web page, you should call again the transaction API integrating the request fields with the parameters to check for the succeeded payment.

  9. If the payment has succeeded, the transaction will be performed, otherwise you will be asked for the payment again.

Gets the payment parameters

$ curl 'http://www.wim.tv:8080/api/license/Professional/subscribe' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/license/accepted",
  "cancelUrl" : "http://www.wim.tv/license/rejected"
}'

Request fields

Path Type Description

returnUrl

String

URL where redirect to in case of succeeded payment.

* Required.
* Must be a well-formed URL.
* Must not be blank.

cancelUrl

String

URL where redirect to in case of rejected payment.

* Required.
* Must be a well-formed URL.
* Must not be blank.

embedded

Boolean

Whether the payment form has to be embedded in the client page.

* Optional.

mobile

Boolean

Whether the client is a mobile App.

* Optional.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 380

{
  "embedded" : false,
  "resource" : {
    "price" : "60,00",
    "storage" : 65,
    "band" : 250,
    "name" : "Professional",
    "dayDuration" : 30,
    "id" : 3,
    "streamingAmount" : 500,
    "support" : "PHONE"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "43c33ccf-5696-4109-adf3-788ba3f15d98",
  "mobile" : false
}

Response fields

Path Type Description

trackingId

String

The payment tracking ID.

embedded

Boolean

Whether the payment form has to be embedded in the client page.

url

URI

The PayPal service URL.

expType

String

The experience type. May be not provided.

mobile

Boolean

Whether the client is a mobile App.

payKey

String

The pay key. Provided only if the client is a mobile device.

pendingRequest

Object

The request to send to the WimTV payment service. Provided only if the client is a mobile App.

resource

Object

Describes the subject of the payment.

The resource object is useful to prompt the user for the payment giving him all the infos he would like.

Embedded payment form

If you would embed the payment form in your Web page, you should use an IFRAME element like the following:

<iframe id="PPDGFrame" name="PPDGFrame"
        src="http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1?expType=light&payKey=09966b16-58ec-4920-ab63-f414c8544c47"
        scrolling="no" frameborder="0" allowtransparency="true"
        style="top: 0px; width: 385px; height: 550px; border: none;"></iframe>
As you can see, you should you use the fields url, expType and payKey in the response to setup your IFRAME.

Mobile App

If the client is a mobile App, that App should manage the payment flow on its own, thus the response includes the request to send to the WimTV payment service (field pendingRequest).

Checking whether a payment has succeeded or not

$ curl 'http://www.wim.tv:8080/api/license/Professional/activate' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "trackingId" : "43c33ccf-5696-4109-adf3-788ba3f15d98"
}'

Request fields

Path Type Description

trackingId

String

Payment tracking ID.

* Required.
* Length must be between 0 and 36 inclusive.

payKey

String

Pay key.

* Must be provided if the client is a mobile device.
* Length must be between 0 and 255 inclusive.

Response

The response usually describes the subject of the payment.

Playing and Payments

Plays a free content

$ curl 'http://www.wim.tv:8080/api/vod/4d7b28a7-5069-4807-9dd0-39f121094491/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1868

{
  "resource" : {
    "licenseType" : "FREE",
    "vodId" : "4d7b28a7-5069-4807-9dd0-39f121094491",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 1",
    "description" : "Description 1",
    "tags" : [ "tag10", "tag11", "tag12" ],
    "resourceId" : "a01002e6-34f2-4c7c-9b68-9bea1b6d2583",
    "contentId" : "urn:wim:tv:content:6fc75aaf-ff24-4fa5-913d-b7190aa303c2",
    "boxId" : "db9c34c2-af1a-4e62-91de-b3e6b9d3b4a1",
    "duration" : "6:22",
    "thumbnailId" : "5668a479-249e-4468-8a2d-6a9b2fce828c"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4/playlist.m3u8?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-894e28ec-4d10-46dd-8575-b473ff1d4826-tr.mp4?token=393d98a9-8ceb-4d3a-b08e-e73d33d157ba"
}

Response fields

The response includes the parameters to setup your player.

Path Type Description

result

Result

Result of the request.

mimeType

String

Mime Type stream to play.

file

String

Name of the stream to play.

streamer

URI

Base URL of the streaming application.

uniqueStreamer

URI

Full URL of the stream to play.

srcs

Array

Array of Objects for all the streamable sources

resource

Object

Describes the resource to play.

The resource object is useful to enrich your player page with infos about the content.

Plays a not free content

$ curl 'http://www.wim.tv:8080/api/vod/4c0eed29-097c-4714-9d64-1732382f8e86/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{ }'

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 841

{
  "resource" : {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "4c0eed29-097c-4714-9d64-1732382f8e86",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "5ce347ce-faa1-4503-b8df-1f0f8f541d00",
    "contentId" : "urn:wim:tv:content:f384d35f-3251-4610-8162-5f4049b2c0d7",
    "boxId" : "da763194-e09a-4002-95b8-ab20cf4fd301",
    "duration" : "7:04",
    "thumbnailId" : "ea582893-e008-4343-b4dd-9a800aadd68c",
    "pricePerView" : "1,20"
  },
  "result" : "PAYMENT_REQUIRED"
}

Response fields

The response notifies that you have to pay.

Path Type Description

result

Result

Result of the request.

resource

Object

Describes the resource to play.

The resource object is useful to prompt the user for the payment giving him all the infos he would like.

Pays to play a not free content

$ curl 'http://www.wim.tv:8080/api/vod/4c0eed29-097c-4714-9d64-1732382f8e86/pay' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "embedded" : false,
  "mobile" : false,
  "returnUrl" : "http://www.wim.tv/vod/play",
  "cancelUrl" : "http://www.wim.tv/vod/rejected"
}'

Request fields

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 983

{
  "embedded" : false,
  "resource" : {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "4c0eed29-097c-4714-9d64-1732382f8e86",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "5ce347ce-faa1-4503-b8df-1f0f8f541d00",
    "contentId" : "urn:wim:tv:content:f384d35f-3251-4610-8162-5f4049b2c0d7",
    "boxId" : "da763194-e09a-4002-95b8-ab20cf4fd301",
    "duration" : "7:04",
    "thumbnailId" : "ea582893-e008-4343-b4dd-9a800aadd68c",
    "pricePerView" : "1,20"
  },
  "url" : "http://www.paypal.com/api/fa95ea54-5a48-4453-b4e6-c835f44e8cf1",
  "trackingId" : "146b85b9-c321-4956-9ee1-1c633e26c7ff",
  "mobile" : false
}

Response fields

Plays a content checking for the succeeded payment

$ curl 'http://www.wim.tv:8080/api/vod/4c0eed29-097c-4714-9d64-1732382f8e86/play' -i -X POST -H 'Content-Type: application/json' -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -d '{
  "trackingId" : "146b85b9-c321-4956-9ee1-1c633e26c7ff"
}'

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 1905

{
  "resource" : {
    "licenseType" : "PAY_PER_VIEW",
    "vodId" : "4c0eed29-097c-4714-9d64-1732382f8e86",
    "publisher" : {
      "pageTitle" : "WimLabs",
      "pageDescription" : "Video Communications",
      "facebookUrl" : "http://www.facebook.com/wimlabs",
      "twitterContact" : "@wimlabs",
      "linkedinUrl" : "http://www.linkedin.com/wimlabs",
      "userCode" : "john"
    },
    "title" : "Title 3",
    "description" : "Description 3",
    "tags" : [ "tag30", "tag31", "tag32" ],
    "resourceId" : "5ce347ce-faa1-4503-b8df-1f0f8f541d00",
    "contentId" : "urn:wim:tv:content:f384d35f-3251-4610-8162-5f4049b2c0d7",
    "boxId" : "da763194-e09a-4002-95b8-ab20cf4fd301",
    "duration" : "7:04",
    "thumbnailId" : "ea582893-e008-4343-b4dd-9a800aadd68c",
    "pricePerView" : "1,20"
  },
  "result" : "PLAY",
  "srcs" : [ {
    "mimeType" : "application/x-mpegurl",
    "streamer" : "http://www.wim.tv:1935/vods3/_definst_?token=f82ba83f-c05f-48ef-97c3-911631504734",
    "uniqueStreamer" : "http://www.wim.tv:1935/vods3/_definst_/mp4:sample-6a85673c-c78c-45e6-925a-964956439bef-tr.mp4/playlist.m3u8?token=f82ba83f-c05f-48ef-97c3-911631504734"
  }, {
    "mimeType" : "video/flash",
    "file" : "mp4:sample-6a85673c-c78c-45e6-925a-964956439bef-tr.mp4",
    "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=f82ba83f-c05f-48ef-97c3-911631504734",
    "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-6a85673c-c78c-45e6-925a-964956439bef-tr.mp4?token=f82ba83f-c05f-48ef-97c3-911631504734"
  } ],
  "mimeType" : "video/flash",
  "file" : "mp4:sample-6a85673c-c78c-45e6-925a-964956439bef-tr.mp4",
  "streamer" : "rtmp://www.wim.tv:1935/vods3/_definst_?token=f82ba83f-c05f-48ef-97c3-911631504734",
  "uniqueStreamer" : "rtmp://www.wim.tv:1935/vods3/_definst_/mp4:sample-6a85673c-c78c-45e6-925a-964956439bef-tr.mp4?token=f82ba83f-c05f-48ef-97c3-911631504734"
}

Response fields

Misc

Uploads a new thumbnail

$ curl 'http://www.wim.tv:8080/api/thumbnail' -i -X POST -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000' -H 'X-Wimtv-progressbarId: ceaa7240-3656-4014-857a-2dd3ef877f5b' -F 'thumbnail=@sample.png'

Request headers

Name Description

X-Wimtv-progressbarId

The progress bar identifier. You can query the progress bar value through by the /api/progressbar/{progressbarId} API.

* Optional.

Accept

application/json

* Required.

Request parts

Part Type Description

thumbnail

Local Path

Thumbnail to upload.

* Required.

Response

HTTP/1.1 201 Created
Content-Type: application/json;charset=UTF-8
Content-Length: 60

{
  "thumbnailId" : "4a3706de-c39e-43c4-b083-afd209f99b33"
}

Response fields

Path Type Description

thumbnailId

String

The thumbnail identifier.

You can include a thumbnail in your HTML pages through by the API /asset/thumbnail/{thumbnailId}.

Queries a progress bar

$ curl 'http://www.wim.tv:8080/api/progressbar/b113a962-fba1-4612-99e0-5c770ea4d6ca' -i -H 'Accept: application/json' -H 'Accept-Language: it' -H 'X-Wimtv-timezone: 7200000'

Path parameters

/api/progressbar/{progressbarId}

Parameter Description

progressbarId

The progress bar identifier.

Request headers

Name Description

Accept

application/json

* Required.

Response

HTTP/1.1 200 OK
Content-Type: application/json;charset=UTF-8
Content-Length: 17

{
  "value" : 5
}
When a process has been completed, it disposes its progress bar, so any further query of the progress bar fails with HTTP status 404 (Not Found).

Response fields

Path Type Description

value

Number

Value (percentage rounded to integer).

Request requirements

Headers

Name Description

Authorization

OAuth 2.0 public or private access token.

* Required.

Accept-Language

Language to be used for localization.

* Optional.

X-Wimtv-timezone

Time-zone offset of the client (milliseconds, including DST).
For example, you can set the header with the following JavaScript expression:

-(new Date().getTimezoneOffset() * 60 * 1000);

* Optional.

Error responses

Generic errors

HTTP/1.1 404 Not Found
Content-Type: application/json;charset=UTF-8
Content-Length: 236

{
  "message" : "Il contenuto 4a006479-bf16-44f1-85da-b188435cd353 non esiste su WimBox.",
  "error" : "Not Found",
  "timestamp" : 1504860931940,
  "status" : 404,
  "exception" : "net.cedeo.wimtv.ApplicationException",
  "path" : ""
}
Path Type Description

exception

String

Exception class.

message

String

Exception message.

status

Number

HTTP status.

error

String

HTTP status description.

path

String

API path.

timestamp

Number

Timestamp (millisecond value that is an offsetfrom the Epoch, January 1, 1970 00:00:00.000 GMT (Gregorian).

Validation errors

HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=UTF-8
Content-Length: 907

{
  "objectName" : "liveEventModel",
  "globalErrors" : [ ],
  "fieldErrors" : {
    "paymentMode" : {
      "rejectedValue" : "null",
      "errors" : [ "Il tipo di licenza è obbligatorio." ]
    },
    "name" : {
      "rejectedValue" : "null",
      "errors" : [ "Il nome è obbligatorio." ]
    },
    "tags" : {
      "rejectedValue" : "[tag1, 123456789012345678901234567890123456789012345678901234567890123456789012345678901234567890]",
      "errors" : [ "La lunghezza di ogni tag deve essere compresa tra 1 e 80 caratteri." ]
    },
    "eventDate" : {
      "rejectedValue" : "2016-10-29T12:30",
      "errors" : [ "L´ora di inizio 14:30:00 del 29/10/2016 deve precedere l´ora di fine 14:00:00 del 29/10/2016." ]
    }
  },
  "error" : "Bad Request",
  "timestamp" : 1504860932021,
  "status" : 400,
  "exception" : "org.springframework.web.bind.MethodArgumentNotValidException",
  "path" : ""
}

First of all, every request validates the object model made of the request parameters or the request payload.
If the validation fails, the exception field in the response payload is set to org.springframework.web.bind.MethodArgumentNotValidException.

Path Type Description

exception

String

Exception class.

objectName

String

Name of the object model.

globalErrors

Array of String

Array of error messages that do not concern any specific field.

fieldErrors

Map of Object

Map of objects that describes the validation errors detected for each field.

status

Number

HTTP status.

error

String

HTTP status description.

path

String

API path.

timestamp

Number

Timestamp (millisecond value that is an offsetfrom the Epoch, January 1, 1970 00:00:00.000 GMT (Gregorian).

The key of the fieldErrors map is the name of the field on which some validation error is detected.
The value of the fieldErrors map is an object with the following structure:

Path Type Description

errors

Array of String

Array of error messages detected on the field.

rejectedValue

Varies

The rejected value of the field.

Validation errors on nested object

HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=UTF-8
Content-Length: 805

{
  "objectName" : "userUpdateModel",
  "globalErrors" : [ ],
  "fieldErrors" : {
    "profile.lastName" : {
      "rejectedValue" : "null",
      "errors" : [ "Il cognome è obbligatorio." ]
    },
    "profile.email" : {
      "rejectedValue" : "xxx:yyy",
      "errors" : [ "La email non è corretta." ]
    },
    "finance.companyConfirm" : {
      "rejectedValue" : "false",
      "errors" : [ "È necessario che tu abbia il diritto di rappresentare l´azienda specificata." ]
    },
    "finance.billingAddress" : {
      "rejectedValue" : "null",
      "errors" : [ "L´indirizzo di fatturazione è obbligatorio." ]
    }
  },
  "error" : "Bad Request",
  "timestamp" : 1504860932093,
  "status" : 400,
  "exception" : "org.springframework.web.bind.MethodArgumentNotValidException",
  "path" : ""
}

If an object model contains some nested object, the key of the fieldErrors map may be the dot-separated path of fields reaching the target field.

Validation errors in multi-part requests

HTTP/1.1 400 Bad Request
Content-Type: application/json;charset=UTF-8
Content-Length: 355

{
  "objectName" : "boxCreateModel",
  "globalErrors" : [ ],
  "fieldErrors" : {
    "file" : {
      "rejectedValue" : "null",
      "errors" : [ "Il file è obbligatorio." ]
    }
  },
  "error" : "Bad Request",
  "timestamp" : 1504860931770,
  "status" : 400,
  "exception" : "net.cedeo.wimtv.model.validation.ValidationErrorException",
  "path" : ""
}

A multi-part content can’t be read field by field unless reading the whole request stream, so the object model can be validated only after the reading of every parts and the upload of every local file.
In such cases, exception field in the response payload is set to net.cedeo.wimtv.model.validation.ValidationErrorException.

Searching for data

Query string

The request payload for all search APIs includes a Lucene query string.

The query string is reserved to the user: If a front-end developer has to search data by particular criteria, he should not use the query string with some exotic syntax; he should ask some back-end developer for enrich the search API with the needed criteria.
For example, if a user is named “dario”, a front-end developer could set “dario” to the query string and he will get all the videos uploaded by dario, but he also get the video with title “Dario The Master”, the video with description “Dario is the best programmer in the world”, and so on.
Moreover, if a front-end developer uses the query string for internal application purposes, the user does not have any tool to apply further filters to the query.

Response fields

Path Type Description

pageSize

Number

Number of item per page.

pageIndex

Number

Index of the current page.

pageCount

Number

Total number of pages.

totalCount

Number

Total number of items.

items

Array

Array of items in the current page.

Custom types

Amount

An amount is a decimal number formatted as the client locale settings state.
For example, in Italian language, the value 2500.4 is formatted as 2,500.40.

Percentage

A percentage is a decimal number formatted as the client locale settings state.
For example, in Italian language, the value 22% is formatted as 22.00.

Date

A date is formatted as the client locale settings state.
For example, in Italian language, the date October 29, 2019 is formatted as 29/10/2019.

DateTime

A time in a day is defined by a JSON object.

Path Type Description

date

String

Date component formatted as the client locale settings state.
For example, in Italian language, the date October 29, 2019 is formatted as 29/10/2019.

time

String

Time component in 24H format relative to the client time-zone settings (including DST).
For example, the time 4 PM CET may be formatted as 15:00:00.

Duration

The amount of time formatting is defined by the following rules:

  1. If the amount is less than an hour, the time format does not include the hours; for example the amount 150 seconds is formatted as 2:30.

  2. if the amount is greater than or equal to an hour, the time format includes the hours, too; for example, the amount 150 seconds is formatted as 2:30, the amount 3620 seconds is formatted as 1:00:20.

Address

An address is defined by a JSON object.

Request fields

Path Type Description

street

String

Street.

* Optional.
* Length must be between 0 and 255 inclusive.

zipCode

String

Zip code.

* Optional.
* Length must be between 0 and 10 inclusive.

city

String

City.

* Optional.
* Length must be between 0 and 50 inclusive.

state

String

State.

* Optional.
* Length must be between 0 and 50 inclusive.

country

String

Country code.

* Optional.
* Length must be between 0 and 2 inclusive.

Response fields

Path Type Description

street

String

Street.

zipCode

String

Zip code.

city

String

City.

state

String

State.

country

String

Country code.

countryName

String

Country name.

License support modes

  • EMAIL

  • PHONE

WimBox sources

Value Description

UPLOAD

Content uploaded by the owner.

MARKET_PLACE

Content acquired from Market Place.

File resource status

Value Description

READY

Ready.

PENDING

Ingestion pending.

FAILED

Ingestion failed.

Content bundle duration units

Value Description

DAYS

Days.

MONTHS

Months.

Creative Commons licenses

Value Description

BY

Attribution.

BY_SA

Attribution, share-alike.

BY_ND

Attribution, no derivatives.

BY_NC

Attribution, non commercial.

BY_NC_SA

Attribution, non commercial, share-alike.

BY_NC_ND

Attribution, non commercial, no derivatives.

WimVod licenses

Value Description

FREE

Free.

CREATIVE_COMMONS

Creative Commons.

PAY_PER_VIEW

Pay-per-view.

CONTENT_BUNDLE

Content bundle.

Market Place licenses

Value Description

FREE

Free.

CREATIVE_COMMONS

Creative Commons.

SPOT_PRICE

Spot price.

PAY_PER_VIEW

Pay-per-view.

REVENUE_SHARING

Revenue sharing.

Market Place duration units

Value Description

DAYS

Days.

MONTHS

Months.

YEARS

Years.

Live event licenses

Value Description

FREE

Free.

PAY_PER_VIEW

Pay-per-view.

WimCast program type

Value Description

PRERECORDED

A content from WimBox.

LIVE

A WimCast live stream.

WimCast program type in daily programming

Value Description

PRERECORDED

A content from WimBox.

LIVE

A WimCast live stream.

BREAK

A break.

WimCast program source type

Value Description

PRERECORDED

A content from WimBox.

LIVE

A WimCast live stream.

PROGRAM

A program scheduled in another channel in a certain day or a program scheduled in the same channel for another day.

BREAK

A break.

Demand responses

Value Description

FULFILLED

The transaction has succeeded: the transaction is free or the payment has been accepted.

PAYMENT_REQUIRED

The user has to accept a payment.

Play responses

Value Description

PLAY

You can proceed to play the content: the content is free or the payment has been accepted.

PAYMENT_REQUIRED

The user has to accept a payment in order to play the content.

SUBSCRIPTION_REQUIRED

The user has to subscribe a content bundle in order to play the content (only for WimVod items).