Update Interaction Retention Policy
curl --request PUT \
--url https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Tenant-Name: <tenant-name>' \
--data '
{
"scheduledDeletionAt": "2050-12-31T23:59:59.999999Z"
}
'const options = {
method: 'PUT',
headers: {
'Tenant-Name': '<tenant-name>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({scheduledDeletionAt: '2050-12-31T23:59:59.999999Z'})
};
fetch('https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));using RestSharp;
var options = new RestClientOptions("https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Tenant-Name", "<tenant-name>");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}", false);
var response = await client.PutAsync(request);
Console.WriteLine("{0}", response.Content);
import requests
url = "https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy"
payload = { "scheduledDeletionAt": "2050-12-31T23:59:59.999999Z" }
headers = {
"Tenant-Name": "<tenant-name>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'scheduledDeletionAt' => '2050-12-31T23:59:59.999999Z'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Tenant-Name: <tenant-name>"
],
]);
$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.{environment}.corti.app/v2/interactions/{id}/retention-policy"
payload := strings.NewReader("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Tenant-Name", "<tenant-name>")
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.put("https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy")
.header("Tenant-Name", "<tenant-name>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}")
.asString();{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}Interactions
Update Interaction Retention Policy
Schedules deletion of an interaction. Sets scheduledDeletionAt to a timestamp that must be in the future. Returns no body on success.
PUT
/
interactions
/
{id}
/
retention-policy
Update Interaction Retention Policy
curl --request PUT \
--url https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'Tenant-Name: <tenant-name>' \
--data '
{
"scheduledDeletionAt": "2050-12-31T23:59:59.999999Z"
}
'const options = {
method: 'PUT',
headers: {
'Tenant-Name': '<tenant-name>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({scheduledDeletionAt: '2050-12-31T23:59:59.999999Z'})
};
fetch('https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));using RestSharp;
var options = new RestClientOptions("https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Tenant-Name", "<tenant-name>");
request.AddHeader("Authorization", "Bearer <token>");
request.AddJsonBody("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}", false);
var response = await client.PutAsync(request);
Console.WriteLine("{0}", response.Content);
import requests
url = "https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy"
payload = { "scheduledDeletionAt": "2050-12-31T23:59:59.999999Z" }
headers = {
"Tenant-Name": "<tenant-name>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'scheduledDeletionAt' => '2050-12-31T23:59:59.999999Z'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"Tenant-Name: <tenant-name>"
],
]);
$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.{environment}.corti.app/v2/interactions/{id}/retention-policy"
payload := strings.NewReader("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Tenant-Name", "<tenant-name>")
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.put("https://api.{environment}.corti.app/v2/interactions/{id}/retention-policy")
.header("Tenant-Name", "<tenant-name>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"scheduledDeletionAt\": \"2050-12-31T23:59:59.999999Z\"\n}")
.asString();{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}{
"requestid": "<string>",
"status": 123,
"type": "<string>",
"detail": "<string>",
"validationErrors": [
{}
]
}Authorizations
Input your token
Headers
Identifies a distinct entity within Corti's multi-tenant system. Ensures correct routing and authentication of the request.
Example:
"base"
Path Parameters
The unique identifier of the interaction. Must be a valid UUID.
Example:
"f47ac10b-58cc-4372-a567-0e02b2c3d479"
Body
application/json
The UTC timestamp at which the interaction is scheduled for deletion. Must be in the future.
Example:
"2050-12-31T23:59:59.999999Z"
Response
The retention policy was updated. No response body is returned.
Was this page helpful?