Void a paid invoice
curl --request POST \
--url https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void', 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.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
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.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void"
req, _ := http.NewRequest("POST", 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.post("https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "9b1d6a2a-2b3c-4d5e-8f9a-1a2b3c4d5e70",
"business_id": "8e2f6b2a-df9c-4c2a-9a0a-9e6a2a2b6a11",
"mode": "test",
"customer_id": "3c1e6a2a-2b3c-4d5e-8f9a-1a2b3c4d5e6f",
"invoice_number": "INV-AB12CD34EF",
"status": "void",
"currency": "USD",
"line_items": [
{
"description": "Consulting services",
"quantity": 2,
"unit_price": 500,
"amount": 1000
}
],
"subtotal": 1000,
"tax_rate": 7.5,
"tax_amount": 75,
"discount_amount": 50,
"total": 1025,
"due_date": "2026-07-01T00:00:00.000Z",
"paid_at": null,
"notes": "Thank you for your business.",
"provider_invoice_reference": null,
"cc_invoice_url": null,
"metadata": {
"order_ref": "ord_123"
},
"created_at": "2026-09-01T10:15:00.000Z",
"updated_at": "2026-09-01T10:15:00.000Z"
}{
"success": false,
"status": 400,
"message": "Only paid invoices can be voided.",
"timestamp": "2026-09-17T12:00:00.000Z"
}{
"success": false,
"status": 401,
"message": "Invalid or inactive API key.",
"timestamp": "2026-09-17T12:00:00.000Z"
}{
"success": false,
"status": 404,
"message": "Invoice not found.",
"timestamp": "2026-09-17T12:00:00.000Z"
}Invoices
Void a paid invoice
POST
/
api
/
v1
/
invoices
/
{invoice_id}
/
void
Void a paid invoice
curl --request POST \
--url https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void"
headers = {"Authorization": "Bearer <token>"}
response = requests.post(url, headers=headers)
print(response.text)const options = {method: 'POST', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void', 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.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
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.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void"
req, _ := http.NewRequest("POST", 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.post("https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.dexxify.com/api/v1/api/v1/invoices/{invoice_id}/void")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "9b1d6a2a-2b3c-4d5e-8f9a-1a2b3c4d5e70",
"business_id": "8e2f6b2a-df9c-4c2a-9a0a-9e6a2a2b6a11",
"mode": "test",
"customer_id": "3c1e6a2a-2b3c-4d5e-8f9a-1a2b3c4d5e6f",
"invoice_number": "INV-AB12CD34EF",
"status": "void",
"currency": "USD",
"line_items": [
{
"description": "Consulting services",
"quantity": 2,
"unit_price": 500,
"amount": 1000
}
],
"subtotal": 1000,
"tax_rate": 7.5,
"tax_amount": 75,
"discount_amount": 50,
"total": 1025,
"due_date": "2026-07-01T00:00:00.000Z",
"paid_at": null,
"notes": "Thank you for your business.",
"provider_invoice_reference": null,
"cc_invoice_url": null,
"metadata": {
"order_ref": "ord_123"
},
"created_at": "2026-09-01T10:15:00.000Z",
"updated_at": "2026-09-01T10:15:00.000Z"
}{
"success": false,
"status": 400,
"message": "Only paid invoices can be voided.",
"timestamp": "2026-09-17T12:00:00.000Z"
}{
"success": false,
"status": 401,
"message": "Invalid or inactive API key.",
"timestamp": "2026-09-17T12:00:00.000Z"
}{
"success": false,
"status": 404,
"message": "Invoice not found.",
"timestamp": "2026-09-17T12:00:00.000Z"
}Response
Invoice voided successfully.

