JWT signed to use in the player to show a watermark

An alternative is for you to create your own signed JWT to use in our player to use Watermark. For that, you need some information to be able to generate, such as the id and secret of your watermark group that you can fetch through this request.

You need to be aware of the expiration of this JWT if it is expired, it cannot be used again.

Below is the attributes that go inside the JWT payload:

Atribute nameTypeDescriptionRequired
drm_group_iduuidWatermark Group idYes
exptimestampTimestamp expire jwt tokenYes
string1stringFirst labelNo
string2stringSecond labelNo
string3stringThird labelNo

Below is an example in NodeJS of how to create the JWT using the jsonwebtoken library:

const JWT = require('jsonwebtoken');
const jwtObj = {
  drm_group_id: "", // id from watermark group
  string1: "", // First Label
  string2: "", // Second Label
  string3: "" // Third Label
}
const expiresIn = 86400; // 24h
const secret = "" // secret from watermark group
const token = JWT.sign(jwtObj, secret, { expiresIn })

After generating the JWT, you can use it in the embed code with the following parameters watermark and drm_group_id. For example: ?watermark={jwt}

Follow the link to check the parameters available in the player.