βš–οΈVats

This page provides a description of the available API routes for managing VAT rates.

Each VAT rate is identified by its numeric category identifier and associated VAT rate with value between 0 and 100. The VAT data model is represented by Vat class.

API methods

Get VATs

GET http://{server-address}/vats

Returns all VATs that matches query parameters. Result is of type QueryResult<Vat>.

Query Parameters

Headers

{
    "items":
    [
        {
            "category": 1,
            "rate": 20.0,
            "_v": 1
        },
        {
            "category": 2,
            "rate": 10.0,
            "_v": 1
        },
        {
            "category": 3,
            "rate": 0.0,
            "_v": 1
        },
        {
            "category": 4,
            "rate": 0.0,
            "_v": 1
        },
        {
            "category": 5,
            "rate": 0.0,
            "_v": 1
        }
    ],
    "count": 5,
    "totalCount": 5
}

Get VAT by category

GET http://{server-address}/vats/{category}

Result is of type Vat.

Path Parameters

Headers

{
    "category": 1,
    "rate": 20.0,
    "_v": 1
}

Create VAT

POST http://{server-address}/vats

Creates new VAT. Result is of type Vat.

Required rights

Authorized user must have VatCreate right assigned.

Headers

Request Body

{
    "category": 1,
    "rate": 20.0,
    "_v": 1
}

Create or update VAT

PUT http://{server-address}/vats/{category}

Updates existing or creates new VAT. Result is of type Vat.

Required rights

Authorized user must have assigned VatCreate or VatUpdate right.

Path Parameters

Headers

Request Body

{
    "category": 1,
    "rate": 20.0,
    "_v": 2
}

Delete VAT by category

DELETE http://{server-address}/vats/{category}

Required rights

Authorized user must have VatDelete right assigned.

Path Parameters

Headers

{
    "category": 1,
    "rate": 20.0,
    "_v": 1
}

Last updated