Delete API Key
curl --request POST \
--url https://api.example.com/delete_api_brx \
--header 'Content-Type: application/json' \
--data '
{
"apiKey": "<string>"
}
'import requests
url = "https://api.example.com/delete_api_brx"
payload = { "apiKey": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({apiKey: '<string>'})
};
fetch('https://api.example.com/delete_api_brx', 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.example.com/delete_api_brx",
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([
'apiKey' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://api.example.com/delete_api_brx"
payload := strings.NewReader("{\n \"apiKey\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.example.com/delete_api_brx")
.header("Content-Type", "application/json")
.body("{\n \"apiKey\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/delete_api_brx")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"apiKey\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"400": {},
"401": {},
"403": {},
"404": {},
"500": {},
"UpdateKeyResponse": {
"deleted": true
}
}API Key Management
Delete API Key
Deletes an API key for the authenticated user
POST
/
delete_api_brx
Delete API Key
curl --request POST \
--url https://api.example.com/delete_api_brx \
--header 'Content-Type: application/json' \
--data '
{
"apiKey": "<string>"
}
'import requests
url = "https://api.example.com/delete_api_brx"
payload = { "apiKey": "<string>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({apiKey: '<string>'})
};
fetch('https://api.example.com/delete_api_brx', 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.example.com/delete_api_brx",
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([
'apiKey' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"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://api.example.com/delete_api_brx"
payload := strings.NewReader("{\n \"apiKey\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
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://api.example.com/delete_api_brx")
.header("Content-Type", "application/json")
.body("{\n \"apiKey\": \"<string>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/delete_api_brx")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"apiKey\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"400": {},
"401": {},
"403": {},
"404": {},
"500": {},
"UpdateKeyResponse": {
"deleted": true
}
}This endpoint deletes an API key for the authenticated user. Once deleted, the API key can no longer be used to authenticate API requests. This action cannot be undone, so use it with caution.
Request
string
required
The API key to delete
Example Request
{
"apiKey": "brx_api_12345678-90ab-cdef-1234-567890abcdef"
}
Response
Example Response
{
"UpdateKeyResponse": {
"deleted": true
}
}
Error Codes
object
Bad Request - The request was malformed or missing required parameters
object
Unauthorized - Authentication credentials are missing or invalid
object
Forbidden - The authenticated user does not have permission to delete the specified API key
object
Not Found - The specified API key does not exist or does not belong to the authenticated user
object
Internal Server Error - An unexpected error occurred on the server
Notes
- Once an API key is deleted, it can no longer be used to authenticate API requests.
- This action cannot be undone, so use it with caution.
- You can only delete API keys that belong to your account.
- If an API key is compromised, it should be deleted immediately to prevent unauthorized access.
- To generate a new API key, use the Generate API Key endpoint.
- To list all API keys for the authenticated user, use the List API Keys endpoint.