Endpoints
Disconnect Platform
Disconnect one of the authenticated user’s linked platforms.
POST
/
api
/
v1
/
disconnect
Disconnect a platform
curl --request POST \
--url https://mallary.ai/api/v1/disconnect \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"platform": "<string>",
"profile_id": "AbC123xYz90"
}
'import requests
url = "https://mallary.ai/api/v1/disconnect"
payload = {
"platform": "<string>",
"profile_id": "AbC123xYz90"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({platform: '<string>', profile_id: 'AbC123xYz90'})
};
fetch('https://mallary.ai/api/v1/disconnect', 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://mallary.ai/api/v1/disconnect",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'platform' => '<string>',
'profile_id' => 'AbC123xYz90'
]),
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://mallary.ai/api/v1/disconnect"
payload := strings.NewReader("{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://mallary.ai/api/v1/disconnect")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mallary.ai/api/v1/disconnect")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}"
response = http.request(request)
puts response.read_body{
"status": "ok",
"platform": "<string>",
"profile_id": "<string>"
}Use
profile_id to disconnect a platform from a non-default connection profile. Omit it to disconnect from the default profile.Authorizations
Use Authorization: Bearer {api_key}
Body
application/json
Last modified on May 13, 2026
Was this page helpful?
⌘I
Disconnect a platform
curl --request POST \
--url https://mallary.ai/api/v1/disconnect \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"platform": "<string>",
"profile_id": "AbC123xYz90"
}
'import requests
url = "https://mallary.ai/api/v1/disconnect"
payload = {
"platform": "<string>",
"profile_id": "AbC123xYz90"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({platform: '<string>', profile_id: 'AbC123xYz90'})
};
fetch('https://mallary.ai/api/v1/disconnect', 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://mallary.ai/api/v1/disconnect",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'platform' => '<string>',
'profile_id' => 'AbC123xYz90'
]),
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://mallary.ai/api/v1/disconnect"
payload := strings.NewReader("{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}")
req, _ := http.NewRequest("POST", 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.post("https://mallary.ai/api/v1/disconnect")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mallary.ai/api/v1/disconnect")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"platform\": \"<string>\",\n \"profile_id\": \"AbC123xYz90\"\n}"
response = http.request(request)
puts response.read_body{
"status": "ok",
"platform": "<string>",
"profile_id": "<string>"
}
