curl --request POST \
--url https://api.rootfi.dev/v3/accounting/tax_rates \
--header 'Content-Type: application/json' \
--header 'api_key: <api-key>' \
--data '{
"company_id": 1,
"data": [
{
"name": "Rootfi Test Tax Rate",
"code": "1234567890",
"effective_tax_rate": 10,
"total_tax_rate": 10,
"tax_type": "VAT",
"components": [
{
"name": "Rootfi Test Tax Rate Component",
"is_compound": false,
"rate": 10,
"tax_agency": "igst"
}
]
}
]
}'
import { RootFiClient } from "rootfi-api";
const rootfi = new RootFiClient({ apiKey: "<api_key>" });
await rootfi.accounting.accounts.create({
company_id: 56789,
data: [
{
name: "Rootfi Test Tax Rate",
code: "1234567890",
effective_tax_rate: 10,
total_tax_rate: 10,
tax_type: "VAT",
components: [
{
name: "Rootfi Test Tax Rate Component",
is_compound: false,
rate: 10,
tax_agency: "igst",
},
],
},
],
});
{
"data": {
"rootfi_id": 25177,
"rootfi_deleted_at": null,
"rootfi_created_at": "2024-01-24T11:12:02.641Z",
"rootfi_updated_at": "2024-01-24T11:12:02.000Z",
"rootfi_company_id": 1109,
"platform_id": "123456_1",
"platform_unique_id": "123456",
"total_tax_rate": null,
"name": "Victoria Wilson",
"code": "6609425",
"updated_at": "2023-12-21T10:14:26.353Z",
"components": [
{
"name": "Victoria Wilson",
"rate": null,
"tax_agency": null,
"is_compound": false
}
],
"effective_tax_rate": null,
"tax_type": "VAT"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}Tax Rates
Create Tax Rate
Create a tax rate.
POST
/
accounting
/
tax_rates
curl --request POST \
--url https://api.rootfi.dev/v3/accounting/tax_rates \
--header 'Content-Type: application/json' \
--header 'api_key: <api-key>' \
--data '{
"company_id": 1,
"data": [
{
"name": "Rootfi Test Tax Rate",
"code": "1234567890",
"effective_tax_rate": 10,
"total_tax_rate": 10,
"tax_type": "VAT",
"components": [
{
"name": "Rootfi Test Tax Rate Component",
"is_compound": false,
"rate": 10,
"tax_agency": "igst"
}
]
}
]
}'
import { RootFiClient } from "rootfi-api";
const rootfi = new RootFiClient({ apiKey: "<api_key>" });
await rootfi.accounting.accounts.create({
company_id: 56789,
data: [
{
name: "Rootfi Test Tax Rate",
code: "1234567890",
effective_tax_rate: 10,
total_tax_rate: 10,
tax_type: "VAT",
components: [
{
name: "Rootfi Test Tax Rate Component",
is_compound: false,
rate: 10,
tax_agency: "igst",
},
],
},
],
});
{
"data": {
"rootfi_id": 25177,
"rootfi_deleted_at": null,
"rootfi_created_at": "2024-01-24T11:12:02.641Z",
"rootfi_updated_at": "2024-01-24T11:12:02.000Z",
"rootfi_company_id": 1109,
"platform_id": "123456_1",
"platform_unique_id": "123456",
"total_tax_rate": null,
"name": "Victoria Wilson",
"code": "6609425",
"updated_at": "2023-12-21T10:14:26.353Z",
"components": [
{
"name": "Victoria Wilson",
"rate": null,
"tax_agency": null,
"is_compound": false
}
],
"effective_tax_rate": null,
"tax_type": "VAT"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}{
"error": {
"message": "<string>",
"code": "<string>",
"field": "<string>"
}
}A Tax Rate is the percentage at which an individual or corporation is taxed.
[he Tax Rates Data Model] is designed to provide a unified representation of tax rates across various accounting platforms.
Additional Required Fields
To successfully create an tax rate, certain fields must be included in the raw_data object of the request body. The required fields are as follows:| Integration | Field | Description |
|---|---|---|
| MEKARI_JURNAL | buy_tax_account_id | The ID of the account that will be used to record the tax amount when a purchase is made. |
| MEKARI_JURNAL | sell_tax_account_id | The ID of the account that will be used to record the tax amount when a sale is made. |
curl --request POST \
--url https://api.rootfi.dev/v3/accounting/tax_rates \
--header 'Content-Type: application/json' \
--header 'api_key: <api-key>' \
--data '{
"company_id": 1,
"data": [
{
"name": "Rootfi Test Tax Rate",
"code": "1234567890",
"effective_tax_rate": 10,
"total_tax_rate": 10,
"tax_type": "VAT",
"components": [
{
"name": "Rootfi Test Tax Rate Component",
"is_compound": false,
"rate": 10,
"tax_agency": "igst"
}
]
}
]
}'
import { RootFiClient } from "rootfi-api";
const rootfi = new RootFiClient({ apiKey: "<api_key>" });
await rootfi.accounting.accounts.create({
company_id: 56789,
data: [
{
name: "Rootfi Test Tax Rate",
code: "1234567890",
effective_tax_rate: 10,
total_tax_rate: 10,
tax_type: "VAT",
components: [
{
name: "Rootfi Test Tax Rate Component",
is_compound: false,
rate: 10,
tax_agency: "igst",
},
],
},
],
});
Authorizations
Body
application/json