Top

Tax

List taxes
GET /settings/taxes
List of simple tax, compound tax and tax groups with pagination.
Get a tax
GET /settings/taxes/:tax_id
Get the details of a simple tax, compound tax or tax group.
Create a tax
POST /settings/taxes
Create a simple or compound tax that can be associated with an item.
Update a tax
PUT /settings/taxes/:tax_id
Update the details of a simple or compound tax.
Delete a tax
DELETE /settings/taxes/:tax_id
Delete a simple or compound tax.
Get a tax group
GET /settings/taxgroups/:tax_group_id
Get the details of a tax group with associated.
Create a tax group
POST /settings/taxgroups
Create a tax group associating multiple taxes.A tax group should contain minimum of 2 taxes.Only one compund tax can be associated to a tax group along with other taxes.
Update tax group
PUT /settings/taxgroups/:tax_group_id
Update the details of a tax group.
Delete a tax group
DELETE /settings/taxgroups/:tax_group_id
Delete a created tax group.


Specific to Sales Tax in US

List tax authorities
GET /settings/taxauthorities
List of tax authorities.
Get a tax authority
GET /settings/taxauthorities/:tax_authority_id
Get the details of a tax authority.
Update a tax authority
PUT /settings/taxauthorities/:tax_authority_id
Update the details of a tax authority.
Delete a tax authority
DELETE /settings/taxauthorities/:tax_authority_id
Delete a tax authority.
List tax exemptions
GET /settings/taxexemptions
List of tax exemptions.
Get a tax exemption
GET /settings/taxexemptions/:tax_exemption_id
Get the details of a tax exemption.
Update a tax exemption
PUT /settings/taxexemptions/:tax_exemption_id
Update the details of a tax exemption.
Delete a tax exemption
DELETE /settings/taxexemptions/:tax_exemption_id
Delete a tax exemption.

List taxes

GET  /settings/taxes

List of simple tax, compound tax and tax groups with pagination.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "taxes": [
    {
      "tax_id": "460000000056001",
      "tax_name": "Sales Group",
      "tax_percentage": 23,
      "tax_type": "tax_group"
    },
    {
      "tax_id": "460000000027007",
      "tax_name": "Sales Tax",
      "tax_percentage": 10.5,
      "tax_type": "tax"
    },
    {
      "tax_id": "460000000027005",
      "tax_name": "VAT",
      "tax_percentage": 12.5,
      "tax_type": "tax"
    }
  ],
  "page_context": {
    "page": 1,
    "per_page": 200,
    "has_more_page": false,
    "report_name": "Taxes",
    "sort_column": "tax_name",
    "sort_order": "A"
  }
}

Get a tax

GET  /settings/taxes/:tax_id

Get the details of a simple tax, compound tax or tax group.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax": {
    "tax_id": "460000000027007",
    "tax_name": "Sales Tax",
    "tax_percentage": 10.5,
    "tax_type": "tax"
  }
}

Create a tax

POST  /settings/taxes

Create a simple or compound tax that can be associated with an item.

Request attributes

tax_name* string
[50]
Name of the tax to be created.
tax_percentage* double Number of percentage taxable.
tax_type string Type to determine whether it is a simple or compound tax.
Allowed Values: tax and compound_tax
tax_authority_id
(US Edition only)
string ID of the tax authority. Tax authority depends on the location of the customer. For example, if the customer is located in NY, then the tax authority is NY tax authority.

Sample Request

{
  "tax_name": "Sales Tax",
  "tax_percentage": 10.5,
  "tax_type": "tax"
}

Sample Response

Status: 201 Created
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The tax has been added.",
  "tax": {
    "tax_id": "460000000027007",
    "tax_name": "Sales Tax",
    "tax_percentage": 10.5,
    "tax_type": "tax"
  }
}

Update a tax

PUT  /settings/taxes/:tax_id

Update the details of a simple or compound tax.

Request attributes

tax_name* string
[50]
Name of the tax to be created.
tax_percentage* double Number of percentage taxable.
tax_type string Type to determine whether it is a simple or compound tax.
Allowed Values: tax and compound_tax
tax_authority_id
(US Edition only)
string ID of the tax authority. Tax authority depends on the location of the customer. For example, if the customer is located in NY, then the tax authority is NY tax authority.

Sample Request

{
      "tax_name": "Sales Tax",
      "tax_percentage": 10.5,
      "is_compound": false
    }

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
      "code": 0,
      "message": "Tax information has been saved.",
      "tax": {
        "tax_id": "460000000027007",
        "tax_name": "Sales Tax",
        "tax_percentage": "10.5",
        "tax_type": "tax"
      }
    }

Delete a tax

DELETE  /settings/taxes/:tax_id

Delete a simple or compound tax.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The record has been deleted."
}

Get a tax group

GET  /settings/taxgroups/:tax_group_id

Get the details of a tax group with associated taxes.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax_group": {
    "tax_group_id": "460000000056001",
    "tax_group_name": "Sales Group",
    "tax_group_percentage": 23,
    "taxes": [
      {
        "tax_id": "460000000027005",
        "tax_name": "VAT",
        "tax_percentage": 12.5,
        "tax_type": "tax"
      },
      {
        "tax_id": "460000000027007",
        "tax_name": "Sales Tax",
        "tax_percentage": 10.5,
        "tax_type": "tax"
      }
    ]
  }
}

Create a tax group

POST  /settings/taxgroups

Create a tax group associating multiple taxes.A tax group should contain minimum of 2 taxes.Only one compund tax can be associated to a tax group along with other taxes.

Request attributes

tax_group_name string
[50]
Name of the tax group.
taxes string
[100]
List of tax IDs that are to be associated to the tax group.

Sample Request

{
      "tax_group_name": "Purchase Tax",
      "taxes": "460000000027005,460000000027007"
    }

Sample Response

Status: 201 Created
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The tax group has been created.",
  "tax_group": {
    "tax_group_id": "460000000056001",
    "tax_group_name": "Sales Group",
    "tax_group_percentage": 23,
    "taxes": [
      {
        "tax_id": "460000000027005",
        "tax_name": "VAT",
        "tax_percentage": 12.5,
        "tax_type": "tax"
      },
      {
        "tax_id": "460000000027007",
        "tax_name": "Sales Tax",
        "tax_percentage": 10.5,
        "tax_type": "tax"
      }
    ]
  }
}

Update tax group

PUT  /settings/taxgroups/:tax_group_id

Update the details of a tax group.

Request attributes

tax_group_name string
[50]
Name of the tax group.
taxes string
[100]
List of tax IDs that are to be associated to the tax group.

Sample Request

{
      "tax_group_name": "Purchase Tax",
      "taxes": "460000000027005,460000000027007"
    }

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
      "code": 1002,
      "message": "Tax Group information has been saved."
    }

Delete a tax group

DELETE  /settings/taxgroups/:tax_group_id

Delete a created tax group.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "The tax group has been deleted."
}

List tax authorities (US Edition only)

GET  /settings/taxauthorities

List of tax authorities.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax_authorities": [
    {
      "tax_authority_id": "460000000066001",
      "tax_authority_name": "NY Tax authority",
      "description": "The New York State Department of  Taxation and Finance"
    },
    {
      "tax_authority_id": "460000000066002",
      "tax_authority_name": "CA Tax authority",
      "description": "State of California Franchise Tax Board"
    },
    {
      "tax_authority_id": "460000000066003",
      "tax_authority_name": "DC Tax authority",
      "description": "Office of Tax and Revenue, Washington DC"
    }
  ]
}

Get a tax authority (US Edition only)

GET  /settings/taxauthorities/:tax_authority_id

Get the details of a tax authority.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax_authority": {
      "tax_authority_id": "460000000066001",
      "tax_authority_name": "NY Tax authority",
      "description": "The New York State Department of  Taxation and Finance"
    }
}

Create a tax authority (US Edition only)

POST  /settings/taxauthorities

Create a tax authority.

Request attributes

tax_authority_name* string Name of the tax authority.
description string Description.

Sample Request

{
   "tax_authority_name": "NY Tax authority",
   "description": "The New York State Department of  Taxation and Finance"
}

Sample Response

Status: 201 Created
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax authority has been successfully added.",
  "tax_authority": {
      "tax_authority_id": "460000000066001",
      "tax_authority_name": "NY Tax authority",
      "description": "The New York State Department of  Taxation and Finance"
    }
}

Update a tax authority (US Edition only)

PUT  /settings/taxauthorities/:tax_authority_id

Update the details of a tax authority.

Request attributes

tax_authority_name* string Name of the tax authority.
description string Description.

Sample Request

{
   "tax_authority_name": "New York Tax authority",
   "description": "The New York State Department of  Taxation and Finance"
}

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax authority information has been updated successfully.",
  "tax_authority": {
      "tax_authority_id": "460000000066001",
      "tax_authority_name": "New York Tax authority",
      "description": "The New York State Department of  Taxation and Finance"
    }
}

Delete a tax authority (US Edition only)

DELETE  /settings/taxauthorities/:tax_authority_id

Delete a tax authority.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax authority has been deleted successfully."
}

List tax exemptions (US Edition only)

GET  /settings/taxexemptions

List of tax exemptions.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax_exemptions": [
    {
      "tax_exemption_id": "460000000076002",
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
    },
    {
      "tax_exemption_id": "460000000076001",
      "tax_exemption_code": "CLOTHING",
      "description": "Tax Exempted Goods.",
      "type" : "item"
    }
  ]
}

Get a tax exemption (US Edition only)

GET  /settings/taxexemption/:tax_exemption_id

Get the details of a tax exemption.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "success",
  "tax_exemption": {
      "tax_exemption_id": "460000000076002",
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
    }
}

Create a tax exemption (US Edition only)

POST  /settings/taxexemptions

Create a tax exemption.

Request attributes

tax_exemption_code* string Name of the tax authority.
type* string Type of the tax exemption, can be customer or item.
description string Description.

Sample Request

{
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
}

Sample Response

Status: 201 Created
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax exemption has been successfully added.",
  "tax_exemption": {
      "tax_exemption_id": "460000000076002",
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
    }
}

Update a tax exemption (US Edition only)

PUT  /settings/taxexemptions/:tax_exemption_id

Update the details of a tax exemption.

Request attributes

tax_exemption_code* string Name of the tax authority.
type* string Type of the tax exemption, can be customer or item. Note that the type cannot be changed if the tax exemption is associated with any other entity.
description string Description.

Sample Request

{
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
}

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax exemption has been updated successfully.",
  "tax_exemption": {
      "tax_exemption_code": "RESELLER",
      "description": "Tax exempted because the contact is a reseller.",
      "type" : "customer"
    }
}

Delete a tax exemption (US Edition only)

DELETE  /settings/taxexemptions/:tax_exemption_id

Delete a tax exemption.

Sample Response

Status: 200 OK
Content Type: application/json;charset=UTF-8
{
  "code": 0,
  "message": "Tax exemption has been deleted successfully."
}