Skip to main content

Tax Service

Tax describe the taxes that are associated with the Tenant. You can retrieve taxes by using API.

Tax Object​

Attributes​


AttributeTypeDescription
idlongUnique identifier for the object.
namestringName of the tax.
taxCodestringCode of Tax.
accountCodestringAccount code of tax's account.
accountNamestringName of Tax's account.
typeenumType of taxes. Possible values for type.
descriptionstringTax account description.
percentBigDecimalTax's percentage.
codestringTax code.
statusstringTax Status.
deletedbooleanHas the value true if the tax is deleted or false if the tax still exist.
tenantIdlongUnique identifier for the object.
categoryenumType of tax category. Possible values for category.
taxSectionAusenumAustralia BAS tax section. Possible values for taxSectionAus.
basReportingstringAustralia BAS reporting value.
taxAccountCodestringTax account code.
taxGroupDetailslistList of taxes that make up this tax group, when isTaxGroup is true. Attribute for TaxGroupDetails.
netAmountBeforestringNet amount before memo text.
taxAmountInstringTax amount included memo text.
isTaxGroupbooleanHas the value true if this tax is a group of multiple taxes or false otherwise.
isDefaultbooleanHas the value true if this tax is the default tax or false otherwise.
taxAgencyCanstringCanada tax agency.
netAmountUkstringUK net amount before memo text.
taxAmountUkstringUK tax amount included memo text.
defaultMemoUkstringUK default memo text.
flatRateSchemeUkbooleanHas the value true if UK flat rate VAT scheme applies or false otherwise.
showInReportsIDbooleanHas the value true if the tax should be shown in Indonesia reports or false otherwise.
netAmountBeforeNLstringNetherlands net amount before memo text.
taxAmountInNLstringNetherlands tax amount included memo text.
defaultMemoNLstringNetherlands default memo text.
netAmountBeforeBEstringBelgium net amount before memo text.
taxAmountInBEstringBelgium tax amount included memo text.
defaultMemoBEstringBelgium default memo text.
netAmountDestringGermany net amount before memo text.
taxAmountDestringGermany tax amount included memo text.
defaultMemoDestringGermany default memo text.
additionalTaxInbooleanHas the value true if this is an additional inclusive tax or false otherwise.
taxSectionSARstringSaudi Arabia tax section.
effectiveStartDatestringDate the tax rate becomes effective.
effectiveEndDatestringDate the tax rate stops being effective.

API​


List All Taxes​

Returns a paginated list of taxes.

Parameters​

  • accessToken string
  • search string
  • query string
  • sort string
  • sortDir string
  • page int
  • limit int

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public Page<TaxDto> getTaxes(String accessToken, String search, String query, String sort,
String sortDir, Integer page, Integer limit){
return this.taxesApiClient.getTaxes(accessToken, search, query, sort, sortDir, page, limit);
}

Retrieve Tax​

Retrieves the details of an existing tax. You only need to supply the unique identifier that was returned upon tax creation.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public TaxDto getById(String accessToken, Long id){
return this.taxesApiClient.getById(accessToken, id);
}

Create Tax​

Creates a new tax.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public Long createTax(TaxDto taxDto, String accessToken){
return this.taxesApiClient.createTax(taxDto, accessToken);
}

Update Tax​

Updates an existing tax. You only need to supply the unique identifier that was returned upon tax creation.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public void updateTax(Long id, TaxDto taxDto, String accessToken){
this.taxesApiClient.updateTax(id, taxDto, accessToken);
}

Update Tax Status​

Updates the status (active/inactive) of an existing tax.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public Boolean updateTaxStatus(Long id, String status, String accessToken){
return this.taxesApiClient.updateTaxStatus(id, status, accessToken);
}

Delete Tax​

Deletes an existing tax. You only need to supply the unique identifier that was returned upon tax creation.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public void deleteTaxById(Long id, String accessToken){
this.taxesApiClient.deleteTaxById(id, accessToken);
}

Bulk Delete Tax​

Deletes a list of existing taxes.

Parameters​

Code​

  @Autowired
private TaxesApiClient taxesApiClient;

public List<BulkTaxDeleteResponse> deleteTax(DeleteTaxCriteria deleteTaxCriteria, String accessToken){
return this.taxesApiClient.deleteTax(deleteTaxCriteria, accessToken);
}

Objects​


TaxGroupDetails​

AttributeTypeDescription
idlongUnique identifier for the grouped tax.
codestringCode of the grouped tax.
namestringName of the grouped tax.
percentageBigDecimalPercentage of the grouped tax.
typestringType of the grouped tax.
applyTostringWhat the grouped tax applies to.
additionalTaxInbooleanHas the value true if this is an additional inclusive tax or false otherwise.

DeleteTaxCriteria​

AttributeTypeDescription
taxIdListlistList of tax ids to delete.

BulkTaxDeleteResponse​

AttributeTypeDescription
idlongIdentifier of the tax the response is for.
httpStatusstringHTTP status of the delete attempt for this tax.
Example: "404 NOT_FOUND"
reasonstringReason for failure, when the delete attempt did not succeed.

Enums​


TYPE​

  • SALES
  • PURCHASE
  • BOTH

CATEGORY​

  • SYSTEM
  • CUSTOM

TAX_SECTION_AUS​

  • DEFAULT_GST
  • EXPORT_SALES
  • OTHER_GST
  • INPUT_TAX_SALES
  • CAPITAL_PURCHASES
  • NONCAPITAL_PURCHASES
  • INPUT_TAX_PURCHASES
  • EXCLUDED_FROM_BAS