VAT rate management
Add, modify, or delete VAT rates
Add a VAT rate
POST https://kash.click/workers/addVat.php
Add a new VAT rate to your configuration
POST parameters
| ?? | ?? | ?? |
|---|---|---|
shopID | ? | Your institution's identifier |
key | ? | Your API key |
data[title] | ? | Title (required) |
data[accountingChapter] | ?? | Accounting chapter |
data[rate] | ? | Rate (required) |
data[legal] | ?? | ??? |
Change a VAT rate
POST https://kash.click/workers/editVat.php
Modify an existing VAT
POST parameters
| ?? | ?? | ?? |
|---|---|---|
shopID | ? | Your institution's identifier |
key | ? | Your API key |
id | ? | VAT rate identifier |
data[title] | ?? | Title (required) |
data[accountingChapter] | ?? | Accounting chapter |
data[rate] | ?? | Rate (required) |
data[legal] | ?? | ??? |
Delete a VAT rate
POST https://kash.click/workers/delVat.php
Remove an existing VAT
POST parameters
| ?? | ?? | ?? |
|---|---|---|
shopID | ? | Your institution's identifier |
key | ? | Your API key |
id | ? | VAT rate identifier |
JavaScript example
async function editVAT(){
const body = new URLSearchParams({
shopID: SHOPID,
key: 'REMPLACER_PAR_VOTRE_CLE_API_GENEREE',
id: 123,
'data[title]': '20% VAT',
'data[rate]': 20
});
const res = await fetch("https://kash.click/workers/editVat.php", {
method: "POST",
headers: { "Content-Type": "application/x-www-form-urlencoded" },
body
});
let payload; try{ payload = await res.json(); }catch{ payload = await res.text(); }
console.log(payload);
}