Delete a composition delivery
curl --request DELETE \
--url https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_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.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"object": "composition_delivery",
"id": "<string>",
"deleted": true
}{
"type": "about:blank",
"title": "Not found",
"status": 404,
"code": "not_found",
"detail": "<string>",
"param": "<string>",
"request_id": "req_9f2b8c1d4e5a6b7c8d9e0f1a2b3c4d5e"
}Compositions
Delete a composition delivery
Removes a destination from where a composition will go. Only one never sent can be removed: a send stays on record. Needs the editor role. Refused with a 400 while the composition is scheduled, whose schedule sets where it goes. There is no update: to change a destination, delete it and create another.
Delete a composition delivery
curl --request DELETE \
--url https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_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.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}"
req, _ := http.NewRequest("DELETE", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.tightknit.ai/v1/composition_deliveries/{composition_delivery_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"object": "composition_delivery",
"id": "<string>",
"deleted": true
}{
"type": "about:blank",
"title": "Not found",
"status": 404,
"code": "not_found",
"detail": "<string>",
"param": "<string>",
"request_id": "req_9f2b8c1d4e5a6b7c8d9e0f1a2b3c4d5e"
}Authorizations
A Tightknit admin API key, sent as Authorization: Bearer <key>.
Path Parameters
The composition delivery's id.
Pattern:
^cpdl_[a-zA-Z0-9]{12}$Was this page helpful?

