Export liability report as zipped CSVs
curl --request POST \
--url https://api.prod.commenda.io/api/v1/filings/liability-report/export \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filing_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"delivery_recipients": [
"tax-team@example.com"
]
}
'import requests
url = "https://api.prod.commenda.io/api/v1/filings/liability-report/export"
payload = {
"filing_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"delivery_recipients": ["tax-team@example.com"]
}
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({
filing_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
delivery_recipients: ['tax-team@example.com']
})
};
fetch('https://api.prod.commenda.io/api/v1/filings/liability-report/export', 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.prod.commenda.io/api/v1/filings/liability-report/export",
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([
'filing_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'delivery_recipients' => [
'tax-team@example.com'
]
]),
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://api.prod.commenda.io/api/v1/filings/liability-report/export"
payload := strings.NewReader("{\n \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\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://api.prod.commenda.io/api/v1/filings/liability-report/export")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prod.commenda.io/api/v1/filings/liability-report/export")
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 \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"job_id": "j1a2b3c4-d5e6-7890-abcd-ef1234567890"
},
"message": "Successfully queued liability report export."
}{
"error": {
"type": "CLIENT_INVALID_REQUEST_BODY",
"doc_url": "https://sales-tax-docs.commenda.io/",
"title": "Failed to validate the request body",
"detail": "<string>",
"status": 400,
"instance": "<string>",
"Errors": [
{
"details": "<string>",
"pointer": "<string>"
}
]
}
}{
"error": {
"type": "CLIENT_INVALID_REQUEST_BODY",
"doc_url": "https://sales-tax-docs.commenda.io/",
"title": "Failed to validate the request body",
"detail": "<string>",
"status": 400,
"instance": "<string>",
"Errors": [
{
"details": "<string>",
"pointer": "<string>"
}
]
}
}Filings
Export liability report
Queues an asynchronous export job that produces one CSV per filing, bundles them into a zip, uploads the zip to storage, and emails a signed download link to delivery_recipients when complete. All filings in a single request must belong to the same corporation (max 100 filings). Poll job status via the jobs endpoint, filtering by entity=FILING and operation=EXPORT_INDIRECT_TAX_FILINGS_LIABILITY_REPORT.
POST
/
filings
/
liability-report
/
export
Export liability report as zipped CSVs
curl --request POST \
--url https://api.prod.commenda.io/api/v1/filings/liability-report/export \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filing_ids": [
"3c90c3cc-0d44-4b50-8888-8dd25736052a"
],
"delivery_recipients": [
"tax-team@example.com"
]
}
'import requests
url = "https://api.prod.commenda.io/api/v1/filings/liability-report/export"
payload = {
"filing_ids": ["3c90c3cc-0d44-4b50-8888-8dd25736052a"],
"delivery_recipients": ["tax-team@example.com"]
}
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({
filing_ids: ['3c90c3cc-0d44-4b50-8888-8dd25736052a'],
delivery_recipients: ['tax-team@example.com']
})
};
fetch('https://api.prod.commenda.io/api/v1/filings/liability-report/export', 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.prod.commenda.io/api/v1/filings/liability-report/export",
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([
'filing_ids' => [
'3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'delivery_recipients' => [
'tax-team@example.com'
]
]),
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://api.prod.commenda.io/api/v1/filings/liability-report/export"
payload := strings.NewReader("{\n \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\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://api.prod.commenda.io/api/v1/filings/liability-report/export")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.prod.commenda.io/api/v1/filings/liability-report/export")
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 \"filing_ids\": [\n \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n ],\n \"delivery_recipients\": [\n \"tax-team@example.com\"\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"job_id": "j1a2b3c4-d5e6-7890-abcd-ef1234567890"
},
"message": "Successfully queued liability report export."
}{
"error": {
"type": "CLIENT_INVALID_REQUEST_BODY",
"doc_url": "https://sales-tax-docs.commenda.io/",
"title": "Failed to validate the request body",
"detail": "<string>",
"status": 400,
"instance": "<string>",
"Errors": [
{
"details": "<string>",
"pointer": "<string>"
}
]
}
}{
"error": {
"type": "CLIENT_INVALID_REQUEST_BODY",
"doc_url": "https://sales-tax-docs.commenda.io/",
"title": "Failed to validate the request body",
"detail": "<string>",
"status": 400,
"instance": "<string>",
"Errors": [
{
"details": "<string>",
"pointer": "<string>"
}
]
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
List of filing UUIDs to include in the export. Maximum 100 entries.
Required array length:
1 - 100 elementsEmail addresses that will receive a signed download link to the generated zip when the export job completes.
Minimum array length:
1Example:
["tax-team@example.com"]
Was this page helpful?
⌘I