Update Campaign Sharing Permissions
curl --request PATCH \
--url https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"general_access_level": "<string>"
}
'import requests
url = "https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions"
payload = {
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"general_access_level": "<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({
recipient_permissions: [{recipient_email: '<string>', access_level: 'report_only'}],
general_access_level: '<string>'
})
};
fetch('https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions', 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.ontora.com/v1/interviews/{interview_id}/sharing/permissions",
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([
'recipient_permissions' => [
[
'recipient_email' => '<string>',
'access_level' => 'report_only'
]
],
'general_access_level' => '<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.ontora.com/v1/interviews/{interview_id}/sharing/permissions"
payload := strings.NewReader("{\n \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<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.ontora.com/v1/interviews/{interview_id}/sharing/permissions")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions")
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 \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"interview_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"share_access_level": "<string>",
"general_access_level": "<string>",
"link_enabled": true,
"recipients": [
"<string>"
],
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"share_link_url": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}campaign-sharing
Update Campaign Sharing Permissions
Apply independent per-person and general-channel permissions.
PATCH
/
v1
/
interviews
/
{interview_id}
/
sharing
/
permissions
Update Campaign Sharing Permissions
curl --request PATCH \
--url https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"general_access_level": "<string>"
}
'import requests
url = "https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions"
payload = {
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"general_access_level": "<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({
recipient_permissions: [{recipient_email: '<string>', access_level: 'report_only'}],
general_access_level: '<string>'
})
};
fetch('https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions', 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.ontora.com/v1/interviews/{interview_id}/sharing/permissions",
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([
'recipient_permissions' => [
[
'recipient_email' => '<string>',
'access_level' => 'report_only'
]
],
'general_access_level' => '<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.ontora.com/v1/interviews/{interview_id}/sharing/permissions"
payload := strings.NewReader("{\n \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<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.ontora.com/v1/interviews/{interview_id}/sharing/permissions")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ontora.com/v1/interviews/{interview_id}/sharing/permissions")
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 \"recipient_permissions\": [\n {\n \"recipient_email\": \"<string>\",\n \"access_level\": \"report_only\"\n }\n ],\n \"general_access_level\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"interview_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"share_access_level": "<string>",
"general_access_level": "<string>",
"link_enabled": true,
"recipients": [
"<string>"
],
"recipient_permissions": [
{
"recipient_email": "<string>",
"access_level": "report_only"
}
],
"share_link_url": "<string>"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
application/json
Versioned update for independent general and per-person grants.
A separate route is deliberate: during a rolling deployment, an older API pod returns 404 instead of silently ignoring the new fields and applying a partial, potentially wider permission change.
Response
Successful Response
Was this page helpful?