Start or Stop Charging a Tax
curl --request PUT \
--url https://api.spotflow.co/api/v1/tax-configurations/{id}/status \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "inactive"
}
'import requests
url = "https://api.spotflow.co/api/v1/tax-configurations/{id}/status"
payload = { "status": "inactive" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({status: 'inactive'})
};
fetch('https://api.spotflow.co/api/v1/tax-configurations/{id}/status', 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.spotflow.co/api/v1/tax-configurations/{id}/status",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'status' => 'inactive'
]),
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.spotflow.co/api/v1/tax-configurations/{id}/status"
payload := strings.NewReader("{\n \"status\": \"inactive\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.spotflow.co/api/v1/tax-configurations/{id}/status")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"inactive\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.spotflow.co/api/v1/tax-configurations/{id}/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"status\": \"inactive\"\n}"
response = http.request(request)
puts response.read_body{
"id": 12,
"taxName": "VAT",
"taxType": "percentage",
"rate": 7.5,
"currency": "NGN",
"capAmount": 2000,
"thresholdAmount": 0,
"regionId": 1,
"regionName": "Nigeria",
"merchantName": "DEE LLC",
"status": "active",
"template": false,
"templateId": 1
}Tax Configuration
Start or Stop Charging a Tax
Changes the status of a tax rule. Set to active to start charging your customers during checkout, or inactive to pause it.
PUT
/
tax-configurations
/
{id}
/
status
Start or Stop Charging a Tax
curl --request PUT \
--url https://api.spotflow.co/api/v1/tax-configurations/{id}/status \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"status": "inactive"
}
'import requests
url = "https://api.spotflow.co/api/v1/tax-configurations/{id}/status"
payload = { "status": "inactive" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({status: 'inactive'})
};
fetch('https://api.spotflow.co/api/v1/tax-configurations/{id}/status', 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.spotflow.co/api/v1/tax-configurations/{id}/status",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'status' => 'inactive'
]),
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.spotflow.co/api/v1/tax-configurations/{id}/status"
payload := strings.NewReader("{\n \"status\": \"inactive\"\n}")
req, _ := http.NewRequest("PUT", 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.put("https://api.spotflow.co/api/v1/tax-configurations/{id}/status")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"status\": \"inactive\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.spotflow.co/api/v1/tax-configurations/{id}/status")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"status\": \"inactive\"\n}"
response = http.request(request)
puts response.read_body{
"id": 12,
"taxName": "VAT",
"taxType": "percentage",
"rate": 7.5,
"currency": "NGN",
"capAmount": 2000,
"thresholdAmount": 0,
"regionId": 1,
"regionName": "Nigeria",
"merchantName": "DEE LLC",
"status": "active",
"template": false,
"templateId": 1
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
The unique ID of the tax rule you want to activate or pause.
Example:
12
Body
application/json
Available options:
active, inactive Example:
"inactive"
Response
200 - application/json
Tax status updated successfully.
Example:
12
Example:
"VAT"
Available options:
flat, percentage Example:
"percentage"
Example:
7.5
Example:
"NGN"
Example:
2000
Example:
0
Example:
1
Example:
"Nigeria"
Example:
"DEE LLC"
Available options:
active, inactive Example:
"active"
Example:
false
Example:
1
⌘I

