# getSalesTaxRate

Source: https://pakdatakit.dev/api/typescript/salestax/functions/getsalestaxrate/

```ts
function getSalesTaxRate(query): 
  | SalesTaxRate
  | null;
```

Defined in: [salestax.ts:113](https://github.com/chmuzamil/pakdatakit/blob/a6eeaa47381308c4e4fcda45b29642fe4fbfb1fc/src/salestax.ts#L113)

Returns the standard sales tax rate for goods (federal, Sales Tax Act
1990) or for services in a province or Islamabad Capital Territory, on a
given date.

Only standard rates are covered, from 1 July 2019. Reduced, higher and
sector rates (telecom, restaurants paid by card, Third Schedule goods and
so on) are not. Every rate comes from the authority's own Act or Finance
Act; see DATA.md.

## Parameters

| Parameter | Type |
| :------ | :------ |
| `query` | [`SalesTaxRateQuery`](https://pakdatakit.dev/api/typescript/salestax/interfaces/salestaxratequery/) |

## Returns

  \| [`SalesTaxRate`](https://pakdatakit.dev/api/typescript/salestax/interfaces/salestaxrate/)
  \| `null`

The rate and its source, or `null` for an unknown province or
  kind, an invalid date, or a date before 1 July 2019. Never throws.

## Example

```ts
getSalesTaxRate({ kind: 'goods', date: '2026-11-18' })?.rate; // 18
getSalesTaxRate({ kind: 'services', province: 'Sindh', date: '2024-06-30' })?.rate; // 13
```
