» Tax Profile GET API Documentation

Getting All Tax Profiles

Endpoints: GET /admin/tax_profiles

Purpose

The GET /admin/tax_profiles API retrieves a paginated list of all tax profiles available in the system. It allows administrators to view and manage the tax profiles applied to different products and categories. This API helps maintain compliance with regional tax regulations by providing an overview of configured tax profiles.

Path Parameters

No path parameters for this endpoint.

Query Parameters

ParameterTypeDescription
limitIntegerNumber of products per request.
offsetIntegerStarting point for pagination. 
order_byStringField to sort results by.
directionStringSort order by ascending or descending.

Use Case

Administrators use this endpoint to fetch and review existing tax profiles. It is particularly useful when managing tax rules across multiple regions, verifying tax settings, or selecting an appropriate tax profile when creating or updating categories and products. The pagination feature allows efficient navigation through large sets of tax profiles.

Request Body

No data is required for the request body.

Response

The response includes a collection of tax profiles with key details such as the profile ID, name, description, whether it is the default profile, and timestamps for creation and last update. Pagination information is also included, allowing navigation through large datasets.

GET
https://{your_site_domain}/api/v4/admin/tax_profiles/
Try It Out
{
    "tax_profiles": [
        {
            "id": TAX_PROFILE_ID,
            "name": "TAX_PROFILE_NAME",
            "description": "TAX_PROFILE_DESCRIPTION",
            "default": IS_DEFAULT,
            "created_at": "CREATED_TIMESTAMP",
            "updated_at": "UPDATED_TIMESTAMP"
        }
    ],
    "pagination": {
        "records": TOTAL_RECORDS,
        "limit": PAGE_LIMIT,
        "offset": PAGE_OFFSET,
        "previous_page": "PREVIOUS_PAGE_URL",
        "next_page": "NEXT_PAGE_URL"
    }
}

Getting Specific Tax Profiles

Endpoints: GET /admin/tax_profiles/{id}

Purpose

The GET /admin/tax_profiles/{id} API retrieves detailed information about a specific tax profile. It provides a comprehensive view of an individual tax profile, including key metadata required for tax calculation and auditing.

Path Parameters

/admin/tax_profiles/{id}

Field
Type
Description
id
integer
The unique identifier of the categories

Query Parameters 

This endpoint does not have any query parameters.

Use Case

Administrators use this endpoint to fetch the details of a specific tax profile when reviewing, editing, or applying tax rules. This is useful when validating the tax profile's configuration, ensuring accurate tax calculations, or updating tax-related settings on categories or products.

Request Body

No data is required for the request body.

Response

The response returns detailed information about the specified tax profile, including the tax profile’s ID, name, description, default status, and timestamps for creation and last update.

GET
https://{your_site_domain}/api/v4/admin/tax_profiles/{id}
Try It Out
{
    "tax_profile": {
        "id": TAX_PROFILE_ID,
        "name": "TAX_PROFILE_NAME",
        "description": "TAX_PROFILE_DESCRIPTION",
        "default": IS_DEFAULT,
        "created_at": "CREATED_TIMESTAMP",
        "updated_at": "UPDATED_TIMESTAMP"
    }
}