cURL
curl --request PATCH \
--url https://api.mottostreaming.com/iam/projects/v1/{project_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"content_delivery_settings": {
"public_keys": [
"<string>"
],
"embed_domains": [
"<string>"
]
},
"preferred_regions": []
}
'import requests
url = "https://api.mottostreaming.com/iam/projects/v1/{project_id}"
payload = {
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"content_delivery_settings": {
"public_keys": ["<string>"],
"embed_domains": ["<string>"]
},
"preferred_regions": []
}
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({
id: '<string>',
org_id: '<string>',
name: '<string>',
content_delivery_settings: {public_keys: ['<string>'], embed_domains: ['<string>']},
preferred_regions: []
})
};
fetch('https://api.mottostreaming.com/iam/projects/v1/{project_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/iam/projects/v1/{project_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([
'id' => '<string>',
'org_id' => '<string>',
'name' => '<string>',
'content_delivery_settings' => [
'public_keys' => [
'<string>'
],
'embed_domains' => [
'<string>'
]
],
'preferred_regions' => [
]
]),
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/iam/projects/v1/{project_id}"
payload := strings.NewReader("{\n \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\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/iam/projects/v1/{project_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mottostreaming.com/iam/projects/v1/{project_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 \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\n}"
response = http.request(request)
puts response.read_body{
"project": {
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"disabled": true,
"content_delivery_settings": {
"public_keys": [
"<string>"
],
"embed_domains": [
"<string>"
]
},
"preferred_regions": []
}
}{
"code": 123,
"message": "<string>",
"details": [
{
"@type": "<string>"
}
]
}Projects
Update project
UpdateProject
Updates project’s basic fields (i.e. name)
PATCH
/
iam
/
projects
/
v1
/
{project_id}
cURL
curl --request PATCH \
--url https://api.mottostreaming.com/iam/projects/v1/{project_id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"content_delivery_settings": {
"public_keys": [
"<string>"
],
"embed_domains": [
"<string>"
]
},
"preferred_regions": []
}
'import requests
url = "https://api.mottostreaming.com/iam/projects/v1/{project_id}"
payload = {
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"content_delivery_settings": {
"public_keys": ["<string>"],
"embed_domains": ["<string>"]
},
"preferred_regions": []
}
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({
id: '<string>',
org_id: '<string>',
name: '<string>',
content_delivery_settings: {public_keys: ['<string>'], embed_domains: ['<string>']},
preferred_regions: []
})
};
fetch('https://api.mottostreaming.com/iam/projects/v1/{project_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/iam/projects/v1/{project_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([
'id' => '<string>',
'org_id' => '<string>',
'name' => '<string>',
'content_delivery_settings' => [
'public_keys' => [
'<string>'
],
'embed_domains' => [
'<string>'
]
],
'preferred_regions' => [
]
]),
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/iam/projects/v1/{project_id}"
payload := strings.NewReader("{\n \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\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/iam/projects/v1/{project_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mottostreaming.com/iam/projects/v1/{project_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 \"id\": \"<string>\",\n \"org_id\": \"<string>\",\n \"name\": \"<string>\",\n \"content_delivery_settings\": {\n \"public_keys\": [\n \"<string>\"\n ],\n \"embed_domains\": [\n \"<string>\"\n ]\n },\n \"preferred_regions\": []\n}"
response = http.request(request)
puts response.read_body{
"project": {
"id": "<string>",
"org_id": "<string>",
"name": "<string>",
"disabled": true,
"content_delivery_settings": {
"public_keys": [
"<string>"
],
"embed_domains": [
"<string>"
]
},
"preferred_regions": []
}
}{
"code": 123,
"message": "<string>",
"details": [
{
"@type": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Query Parameters
Body
application/json
Human readable, URL-compatible short identifier, like "motto" or "rtt-show". Must be unique.
Organization ID this project belongs to.
Name of the project, e.g. "Motto".
Settings relevant for the content delivery API
Show child attributes
Show child attributes
The region(s) that this project prefers to operate in. This is used to help the Studio frontend make decisions on how to create and display region-based resources.
Available options:
REGION_UNSPECIFIED, REGION_AF, REGION_AS, REGION_EU, REGION_NA, REGION_OC, REGION_SA Response
OK
Show child attributes
Show child attributes
⌘I

