Cancel Subscription
curl --request DELETE \
--url https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--header 'x-client-id: <api-key>' \
--data '
{
"cancellationReason": "I no longer attend this organization."
}
'import requests
url = "https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}"
payload = { "cancellationReason": "I no longer attend this organization." }
headers = {
"x-client-id": "<api-key>",
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {
'x-client-id': '<api-key>',
'x-api-key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({cancellationReason: 'I no longer attend this organization.'})
};
fetch('https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}', 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://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'cancellationReason' => 'I no longer attend this organization.'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>",
"x-client-id: <api-key>"
],
]);
$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://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}"
payload := strings.NewReader("{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-api-key", "<api-key>")
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.delete("https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}")
.header("x-client-id", "<api-key>")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["x-client-id"] = '<api-key>'
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}"
response = http.request(request)
puts response.read_bodyCancel Subscription
Cancels a donor subscription by its Id.
DELETE
/
api
/
v3
/
subscriptions
/
{donorId}
/
{subscriptionId}
Cancel Subscription
curl --request DELETE \
--url https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId} \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--header 'x-client-id: <api-key>' \
--data '
{
"cancellationReason": "I no longer attend this organization."
}
'import requests
url = "https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}"
payload = { "cancellationReason": "I no longer attend this organization." }
headers = {
"x-client-id": "<api-key>",
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {
'x-client-id': '<api-key>',
'x-api-key': '<api-key>',
'Content-Type': 'application/json'
},
body: JSON.stringify({cancellationReason: 'I no longer attend this organization.'})
};
fetch('https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}', 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://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'cancellationReason' => 'I no longer attend this organization.'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>",
"x-client-id: <api-key>"
],
]);
$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://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}"
payload := strings.NewReader("{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("x-client-id", "<api-key>")
req.Header.Add("x-api-key", "<api-key>")
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.delete("https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}")
.header("x-client-id", "<api-key>")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://server.stage.overflow.co/api/v3/subscriptions/{donorId}/{subscriptionId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["x-client-id"] = '<api-key>'
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"cancellationReason\": \"I no longer attend this organization.\"\n}"
response = http.request(request)
puts response.read_bodyAuthorizations
Client ID for API authentication
API Key for API authentication
Path Parameters
The Id of the donor to cancel the subscription for.
Example:
"2ea1ae03ca521e437db76d76"
The Id of the subscription to cancel.
Example:
"2ea1ae03ca521e437db76d76"
Body
application/json
Subscription cancellation details
The reason for cancelling the subscription.
Required string length:
1 - 150Example:
"I no longer attend this organization."
Response
Subscription cancelled successfully.
Last modified on July 14, 2026
Was this page helpful?
⌘I