Skip to content
On this page

Authorization with callback

1. Configuration from Dashboard

Make sure you have created an application on Sigma's Dashboard (Staging, Production) DRM. To configure the use of callback authorization, perform the following steps:

Step 1: Select the application you want to configure

Chọn ứng dụng

Step 2: After that, please select some integration information Select informationStep 3: Change authorization to callback

Step 4: Select method for HTTP Method

Step 5: Enter the address to receive the callback

2. User authorization using Callback method

license-request

With this authorization method, the Sigma DRM system will make an http request to call the client's authorization system (Merchant) to ensure that the user requesting a license can see the license content. Request details as below.

Details

  • Method: HTTP(s) POST
  • URL: As configured in section 1.4
  • Body Type: Configured in 1.3(Json or URLencode)
  • Body Request:
FieldTypeRequireDescription
assetsStringRequiredId of the content the user applies for a license
userStringRequiredThe UserId is configured into the request. See Player Integration
sessionStringRequiredThe SessionId is configured into the request. See Player Integration
drmSchemeStringOptionalType of DRM the user is applying for (WIDEVINE, FAIRPLAY, PLAYREADY)
requestMetadataObjectOptionalAn object containing the user's IpAddress and user agent.
extraDataStringOptionalAn string containing the extra data of user/merchant

Example:

json
{
  "asset": "sigma_vtv1",
  "user": "example_user",
  "session": "example_session",
  "drmScheme": "WIDE_VINE",
  "requestMetadata": {
    "remoteAddr": "113.190.233.178",
    "userAgent": "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0 Safari/605.1.15"
  },
  "extraData": "There is no one who loves pain itself, who seeks after it and wants to have it, simply because it is pain..."
}

Response:

  • HTTP code:

    • 200: Allows viewing of content and Sigma DRM system will license
    • Other 200: Refused to grant license
  • If you want to use custom rights token, please response in json format with structure as below (describe at CRT):
json
{
    "payload": {
        "allowRoot": 1,
        "hdcpLevel": "Disable HDCP",
        "keyExpireTime": 60,
        "securityLevel": 1,
        "storeLicense": true,
        "storeLicenseTime": 300
    }
}