Skip to content
You are reading the pinned copy of v1.0, which is also the latest release. Read the latest.

Tax (admin API)

Admin routes of the tax module. Every route needs a staff session and the permission named on it; send X-Resolve-Locale: false to receive every locale of a translatable field for editing.

List tax classes

Parameters:

  • page in query (number, min 1, optional).
  • pageSize in query (number, min 1, max 100, optional).
  • zoneId in query (string, optional).

Responses:

  • 200: Classes retrieved.
  • 401: Unauthorized.
  • 403: Insufficient permissions.

Create tax class

Request body: CreateTaxClassAdminDto.

Responses:

  • 201: Class created.
  • 400: Invalid input.
  • 401: Unauthorized.
  • 403: Insufficient permissions.

List tax zones

Parameters:

  • page in query (number, min 1, optional).
  • pageSize in query (number, min 1, max 100, optional).

Responses:

  • 200: Zones retrieved.
  • 401: Unauthorized.
  • 403: Insufficient permissions.

Create tax zone

Request body: CreateTaxZoneAdminDto.

Responses:

  • 201: Zone created.
  • 400: Invalid input.
  • 401: Unauthorized.
  • 403: Insufficient permissions.

Get tax zone

Parameters:

  • id in path (string, required).

Responses:

  • 200: Zone retrieved.
  • 401: Unauthorized.
  • 403: Insufficient permissions.
  • 404: Zone not found.

Update tax zone

Parameters:

  • id in path (string, required).

Request body: UpdateTaxZoneAdminDto.

Responses:

  • 200: Zone updated.
  • 400: Invalid input.
  • 401: Unauthorized.
  • 403: Insufficient permissions.
  • 404: Zone not found.
  • zoneId (string, required).
  • name (string, required).
  • rate (number, min 0, max 1, required).
  • isDefault (boolean, optional).
  • name (TranslatableDto, required).
  • countries (array of string, required).
  • rate (number, min 0, max 1, required).
  • isDefault (boolean, optional).
  • isCompound (boolean, optional).
  • priority (number, min 0, optional).
  • isActive (boolean, optional).
  • fr (string, optional).
  • en (string, optional).
  • ar (string, optional).
  • default (string, required).
As seen on Open Source Alternatives The Merchant Engine badge