Deactivate
curl --request PATCH \
--url https://{defaultHost}/v1/affiliation_requests/{id}/deny \
--header 'Authorization: Bearer <token>'import requests
url = "https://{defaultHost}/v1/affiliation_requests/{id}/deny"
headers = {"Authorization": "Bearer <token>"}
response = requests.patch(url, headers=headers)
print(response.text)const options = {method: 'PATCH', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{defaultHost}/v1/affiliation_requests/{id}/deny', 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://{defaultHost}/v1/affiliation_requests/{id}/deny",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
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://{defaultHost}/v1/affiliation_requests/{id}/deny"
req, _ := http.NewRequest("PATCH", 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.patch("https://{defaultHost}/v1/affiliation_requests/{id}/deny")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{defaultHost}/v1/affiliation_requests/{id}/deny")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "bcb84c01-2ec4-412c-ba86-fd8bc56d25c8",
"object": "affiliation_request",
"bio": "I will promote your products to all my followers!",
"email": "test-affiliate-7@example.com",
"first_name": "Test",
"last_name": "Affiliate 7",
"metadata": {},
"payout_email": null,
"status": "denied",
"url": null,
"portal_url": "http://app.example.com/portal_redirect/affiliation_requests/bcb84c01-2ec4-412c-ba86-fd8bc56d25c8",
"created_at": 1793796844,
"updated_at": 1793796844
}Affiliation Requests
Deactivate
Deny a specific affiliation request.
PATCH
/
v1
/
affiliation_requests
/
{id}
/
deny
Deactivate
curl --request PATCH \
--url https://{defaultHost}/v1/affiliation_requests/{id}/deny \
--header 'Authorization: Bearer <token>'import requests
url = "https://{defaultHost}/v1/affiliation_requests/{id}/deny"
headers = {"Authorization": "Bearer <token>"}
response = requests.patch(url, headers=headers)
print(response.text)const options = {method: 'PATCH', headers: {Authorization: 'Bearer <token>'}};
fetch('https://{defaultHost}/v1/affiliation_requests/{id}/deny', 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://{defaultHost}/v1/affiliation_requests/{id}/deny",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
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://{defaultHost}/v1/affiliation_requests/{id}/deny"
req, _ := http.NewRequest("PATCH", 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.patch("https://{defaultHost}/v1/affiliation_requests/{id}/deny")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://{defaultHost}/v1/affiliation_requests/{id}/deny")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "bcb84c01-2ec4-412c-ba86-fd8bc56d25c8",
"object": "affiliation_request",
"bio": "I will promote your products to all my followers!",
"email": "test-affiliate-7@example.com",
"first_name": "Test",
"last_name": "Affiliate 7",
"metadata": {},
"payout_email": null,
"status": "denied",
"url": null,
"portal_url": "http://app.example.com/portal_redirect/affiliation_requests/bcb84c01-2ec4-412c-ba86-fd8bc56d25c8",
"created_at": 1793796844,
"updated_at": 1793796844
}Authorizations
Response
200 - application/json
Success
Was this page helpful?