Skip to main content
PATCH
/
ott
/
pages
/
v1
/
{page_id}
cURL
curl --request PATCH \
  --url https://api.mottostreaming.com/ott/pages/v1/{page_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "page_id": "<string>",
  "platform_id": "<string>",
  "page_update": {
    "id": "<string>",
    "project_id": "<string>",
    "name": "<string>",
    "title": {},
    "description": {},
    "parameters": [
      "<string>"
    ],
    "page_component_ids": [
      "<string>"
    ],
    "css": "<string>",
    "platform_id": "<string>",
    "metadata_tags": {},
    "overrides": {},
    "page_components": [
      {
        "project_id": "<string>",
        "name": "<string>",
        "type": "<string>",
        "data": {},
        "props": {},
        "environments": [
          "<string>"
        ],
        "group_id": "<string>",
        "css_classes": [
          "<string>"
        ]
      }
    ],
    "is_preview": true,
    "source_page_id": "<string>",
    "redirects": [
      {
        "url": "<string>",
        "conditions": [
          {
            "authentication": {},
            "geolocation": {
              "on_countries": {
                "country_codes": [
                  "<string>"
                ]
              },
              "except_countries": {
                "country_codes": [
                  "<string>"
                ]
              }
            },
            "entitlement": {
              "entitled_to": {
                "offer_ids": [
                  "<string>"
                ]
              },
              "not_entitled_to": {
                "offer_ids": [
                  "<string>"
                ]
              }
            }
          }
        ]
      }
    ]
  },
  "update_mask": "<string>"
}
'
import requests

url = "https://api.mottostreaming.com/ott/pages/v1/{page_id}"

payload = {
    "page_id": "<string>",
    "platform_id": "<string>",
    "page_update": {
        "id": "<string>",
        "project_id": "<string>",
        "name": "<string>",
        "title": {},
        "description": {},
        "parameters": ["<string>"],
        "page_component_ids": ["<string>"],
        "css": "<string>",
        "platform_id": "<string>",
        "metadata_tags": {},
        "overrides": {},
        "page_components": [
            {
                "project_id": "<string>",
                "name": "<string>",
                "type": "<string>",
                "data": {},
                "props": {},
                "environments": ["<string>"],
                "group_id": "<string>",
                "css_classes": ["<string>"]
            }
        ],
        "is_preview": True,
        "source_page_id": "<string>",
        "redirects": [
            {
                "url": "<string>",
                "conditions": [
                    {
                        "authentication": {},
                        "geolocation": {
                            "on_countries": { "country_codes": ["<string>"] },
                            "except_countries": { "country_codes": ["<string>"] }
                        },
                        "entitlement": {
                            "entitled_to": { "offer_ids": ["<string>"] },
                            "not_entitled_to": { "offer_ids": ["<string>"] }
                        }
                    }
                ]
            }
        ]
    },
    "update_mask": "<string>"
}
headers = {
    "Authorization": "Bearer <token>",
    "Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.text)
const options = {
  method: 'PATCH',
  headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
  body: JSON.stringify({
    page_id: '<string>',
    platform_id: '<string>',
    page_update: {
      id: '<string>',
      project_id: '<string>',
      name: '<string>',
      title: {},
      description: {},
      parameters: ['<string>'],
      page_component_ids: ['<string>'],
      css: '<string>',
      platform_id: '<string>',
      metadata_tags: {},
      overrides: {},
      page_components: [
        {
          project_id: '<string>',
          name: '<string>',
          type: '<string>',
          data: {},
          props: {},
          environments: ['<string>'],
          group_id: '<string>',
          css_classes: ['<string>']
        }
      ],
      is_preview: true,
      source_page_id: '<string>',
      redirects: [
        {
          url: '<string>',
          conditions: [
            {
              authentication: {},
              geolocation: {
                on_countries: {country_codes: ['<string>']},
                except_countries: {country_codes: ['<string>']}
              },
              entitlement: {
                entitled_to: {offer_ids: ['<string>']},
                not_entitled_to: {offer_ids: ['<string>']}
              }
            }
          ]
        }
      ]
    },
    update_mask: '<string>'
  })
};

fetch('https://api.mottostreaming.com/ott/pages/v1/{page_id}', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.mottostreaming.com/ott/pages/v1/{page_id}",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "PATCH",
  CURLOPT_POSTFIELDS => json_encode([
    'page_id' => '<string>',
    'platform_id' => '<string>',
    'page_update' => [
        'id' => '<string>',
        'project_id' => '<string>',
        'name' => '<string>',
        'title' => [
                
        ],
        'description' => [
                
        ],
        'parameters' => [
                '<string>'
        ],
        'page_component_ids' => [
                '<string>'
        ],
        'css' => '<string>',
        'platform_id' => '<string>',
        'metadata_tags' => [
                
        ],
        'overrides' => [
                
        ],
        'page_components' => [
                [
                                'project_id' => '<string>',
                                'name' => '<string>',
                                'type' => '<string>',
                                'data' => [
                                                                
                                ],
                                'props' => [
                                                                
                                ],
                                'environments' => [
                                                                '<string>'
                                ],
                                'group_id' => '<string>',
                                'css_classes' => [
                                                                '<string>'
                                ]
                ]
        ],
        'is_preview' => true,
        'source_page_id' => '<string>',
        'redirects' => [
                [
                                'url' => '<string>',
                                'conditions' => [
                                                                [
                                                                                                                                'authentication' => [
                                                                                                                                                                                                                                                                
                                                                                                                                ],
                                                                                                                                'geolocation' => [
                                                                                                                                                                                                                                                                'on_countries' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'country_codes' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                '<string>'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ]
                                                                                                                                                                                                                                                                ],
                                                                                                                                                                                                                                                                'except_countries' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'country_codes' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                '<string>'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ]
                                                                                                                                                                                                                                                                ]
                                                                                                                                ],
                                                                                                                                'entitlement' => [
                                                                                                                                                                                                                                                                'entitled_to' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'offer_ids' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                '<string>'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ]
                                                                                                                                                                                                                                                                ],
                                                                                                                                                                                                                                                                'not_entitled_to' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                'offer_ids' => [
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                '<string>'
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                ]
                                                                                                                                                                                                                                                                ]
                                                                                                                                ]
                                                                ]
                                ]
                ]
        ]
    ],
    'update_mask' => '<string>'
  ]),
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer <token>",
    "Content-Type: application/json"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
package main

import (
	"fmt"
	"strings"
	"net/http"
	"io"
)

func main() {

	url := "https://api.mottostreaming.com/ott/pages/v1/{page_id}"

	payload := strings.NewReader("{\n  \"page_id\": \"<string>\",\n  \"platform_id\": \"<string>\",\n  \"page_update\": {\n    \"id\": \"<string>\",\n    \"project_id\": \"<string>\",\n    \"name\": \"<string>\",\n    \"title\": {},\n    \"description\": {},\n    \"parameters\": [\n      \"<string>\"\n    ],\n    \"page_component_ids\": [\n      \"<string>\"\n    ],\n    \"css\": \"<string>\",\n    \"platform_id\": \"<string>\",\n    \"metadata_tags\": {},\n    \"overrides\": {},\n    \"page_components\": [\n      {\n        \"project_id\": \"<string>\",\n        \"name\": \"<string>\",\n        \"type\": \"<string>\",\n        \"data\": {},\n        \"props\": {},\n        \"environments\": [\n          \"<string>\"\n        ],\n        \"group_id\": \"<string>\",\n        \"css_classes\": [\n          \"<string>\"\n        ]\n      }\n    ],\n    \"is_preview\": true,\n    \"source_page_id\": \"<string>\",\n    \"redirects\": [\n      {\n        \"url\": \"<string>\",\n        \"conditions\": [\n          {\n            \"authentication\": {},\n            \"geolocation\": {\n              \"on_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              },\n              \"except_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              }\n            },\n            \"entitlement\": {\n              \"entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              },\n              \"not_entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              }\n            }\n          }\n        ]\n      }\n    ]\n  },\n  \"update_mask\": \"<string>\"\n}")

	req, _ := http.NewRequest("PATCH", url, payload)

	req.Header.Add("Authorization", "Bearer <token>")
	req.Header.Add("Content-Type", "application/json")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.patch("https://api.mottostreaming.com/ott/pages/v1/{page_id}")
  .header("Authorization", "Bearer <token>")
  .header("Content-Type", "application/json")
  .body("{\n  \"page_id\": \"<string>\",\n  \"platform_id\": \"<string>\",\n  \"page_update\": {\n    \"id\": \"<string>\",\n    \"project_id\": \"<string>\",\n    \"name\": \"<string>\",\n    \"title\": {},\n    \"description\": {},\n    \"parameters\": [\n      \"<string>\"\n    ],\n    \"page_component_ids\": [\n      \"<string>\"\n    ],\n    \"css\": \"<string>\",\n    \"platform_id\": \"<string>\",\n    \"metadata_tags\": {},\n    \"overrides\": {},\n    \"page_components\": [\n      {\n        \"project_id\": \"<string>\",\n        \"name\": \"<string>\",\n        \"type\": \"<string>\",\n        \"data\": {},\n        \"props\": {},\n        \"environments\": [\n          \"<string>\"\n        ],\n        \"group_id\": \"<string>\",\n        \"css_classes\": [\n          \"<string>\"\n        ]\n      }\n    ],\n    \"is_preview\": true,\n    \"source_page_id\": \"<string>\",\n    \"redirects\": [\n      {\n        \"url\": \"<string>\",\n        \"conditions\": [\n          {\n            \"authentication\": {},\n            \"geolocation\": {\n              \"on_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              },\n              \"except_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              }\n            },\n            \"entitlement\": {\n              \"entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              },\n              \"not_entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              }\n            }\n          }\n        ]\n      }\n    ]\n  },\n  \"update_mask\": \"<string>\"\n}")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.mottostreaming.com/ott/pages/v1/{page_id}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n  \"page_id\": \"<string>\",\n  \"platform_id\": \"<string>\",\n  \"page_update\": {\n    \"id\": \"<string>\",\n    \"project_id\": \"<string>\",\n    \"name\": \"<string>\",\n    \"title\": {},\n    \"description\": {},\n    \"parameters\": [\n      \"<string>\"\n    ],\n    \"page_component_ids\": [\n      \"<string>\"\n    ],\n    \"css\": \"<string>\",\n    \"platform_id\": \"<string>\",\n    \"metadata_tags\": {},\n    \"overrides\": {},\n    \"page_components\": [\n      {\n        \"project_id\": \"<string>\",\n        \"name\": \"<string>\",\n        \"type\": \"<string>\",\n        \"data\": {},\n        \"props\": {},\n        \"environments\": [\n          \"<string>\"\n        ],\n        \"group_id\": \"<string>\",\n        \"css_classes\": [\n          \"<string>\"\n        ]\n      }\n    ],\n    \"is_preview\": true,\n    \"source_page_id\": \"<string>\",\n    \"redirects\": [\n      {\n        \"url\": \"<string>\",\n        \"conditions\": [\n          {\n            \"authentication\": {},\n            \"geolocation\": {\n              \"on_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              },\n              \"except_countries\": {\n                \"country_codes\": [\n                  \"<string>\"\n                ]\n              }\n            },\n            \"entitlement\": {\n              \"entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              },\n              \"not_entitled_to\": {\n                \"offer_ids\": [\n                  \"<string>\"\n                ]\n              }\n            }\n          }\n        ]\n      }\n    ]\n  },\n  \"update_mask\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "page": {
    "id": "<string>",
    "project_id": "<string>",
    "name": "<string>",
    "title": {},
    "description": {},
    "parameters": [
      "<string>"
    ],
    "page_component_ids": [
      "<string>"
    ],
    "css": "<string>",
    "platform_id": "<string>",
    "metadata_tags": {},
    "overrides": {},
    "page_components": [
      {
        "project_id": "<string>",
        "id": "<string>",
        "name": "<string>",
        "type": "<string>",
        "data": {},
        "props": {},
        "environments": [
          "<string>"
        ],
        "group_id": "<string>",
        "css_classes": [
          "<string>"
        ]
      }
    ],
    "is_preview": true,
    "source_page_id": "<string>",
    "redirects": [
      {
        "url": "<string>",
        "conditions": [
          {
            "authentication": {},
            "geolocation": {
              "on_countries": {
                "country_codes": [
                  "<string>"
                ]
              },
              "except_countries": {
                "country_codes": [
                  "<string>"
                ]
              }
            },
            "entitlement": {
              "entitled_to": {
                "offer_ids": [
                  "<string>"
                ]
              },
              "not_entitled_to": {
                "offer_ids": [
                  "<string>"
                ]
              }
            }
          }
        ]
      }
    ]
  }
}
{
  "code": 123,
  "message": "<string>",
  "details": [
    {
      "@type": "<string>"
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

page_id
string
required

Body

application/json
page_id
string
required
page_type
enum<string>
required
Available options:
PAGE_TYPE_UNSPECIFIED,
PAGE_TYPE_DEFAULT,
PAGE_TYPE_HOME,
PAGE_TYPE_EVENT,
PAGE_TYPE_CREATIVE_WORK,
PAGE_TYPE_ENTITY
platform_id
string
required
page_update
object
required

Page is a configuration object that defines the structure of a page, of which there can be arbitrarily many instances.

update_mask
string<field-mask>
required

Response

OK

page
object

Page is a configuration object that defines the structure of a page, of which there can be arbitrarily many instances.