# Payroll tax for the month

`GET https://api.fiscalisto.com/v1/payroll_taxes`

Each state's payroll tax: the sum of the receipts stamped with a payment date in the month, by the state where each employee works (ClaveEntFed), minus the perceptions in excluded_perception_types, times the state's rate and its surcharges. It's declared and paid on each state's finance portal.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `issuer` | query |  | The issuer (iss_…). It can be left out if the key or the account has only one. |
| `month` | query | yes | The month: 2026-11. |

## With the TypeScript SDK

```ts
import { Fiscalisto } from "fiscalisto";

// La llave viene de FISCALISTO_API_KEY.
const fiscalisto = new Fiscalisto();

const payrollTax = await fiscalisto.payrollTaxes.get();
```

## With the Python SDK

```python
from fiscalisto import Fiscalisto

# La llave viene de FISCALISTO_API_KEY.
fiscalisto = Fiscalisto()

payroll_tax = fiscalisto.payroll_taxes.get()
```

## With the PHP SDK

```php
<?php

use Fiscalisto\Fiscalisto;

// La llave viene de FISCALISTO_API_KEY.
$fiscalisto = new Fiscalisto();

$payrollTax = $fiscalisto->payrollTaxes->get();
```

## With the .NET SDK

```csharp
using Fiscalisto;

// La llave viene de FISCALISTO_API_KEY.
var fiscalisto = new FiscalistoClient();

var payrollTax = await fiscalisto.PayrollTaxes.GetAsync();
```

## With the Go SDK

```go
package main

import (
	"context"
	"fmt"
	"log"

	fiscalisto "fiscalisto.com/go"
)

func main() {
	// La llave viene de FISCALISTO_API_KEY.
	client, err := fiscalisto.NewClient("")
	if err != nil {
		log.Fatal(err)
	}
	ctx := context.Background()

	payrollTax, err := client.PayrollTaxes.Get(ctx, nil)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Printf("%+v\n", *payrollTax)
}
```

## With the Java SDK

```java
import com.fiscalisto.FiscalistoClient;

// La llave viene de FISCALISTO_API_KEY.
var fiscalisto = new FiscalistoClient();

var payrollTax = fiscalisto.payrollTaxes().get();
System.out.println(payrollTax);
```

## Response 200

OK.

A `PayrollTax` object:

| Field | Type | Always present | Description |
| --- | --- | --- | --- |
| `object` | `"payroll_tax"` | yes | What kind of object it is («invoice», «customer»…). |
| `livemode` | boolean | yes | true in production (fk_live_ keys), false in test mode (fk_test_). Test objects aren't valid before the SAT. |
| `issuer` | string | yes | The issuer (iss_…). |
| `month` | string | yes | The month: 2026-11. |
| `total` | number | yes | What it pays across all states. |
| `states` | array of object | yes | Each state with receipts in the month, from largest to smallest base. |
| `states[].state` | string | yes | The state where they work (c_Estado from ClaveEntFed): CMX. |
| `states[].name` | string | yes | Its name. |
| `states[].employees` | integer | yes | The employees with a receipt. (from -9007199254740991 to 9007199254740991) |
| `states[].receipts` | integer | yes | The stamped receipts. (from -9007199254740991 to 9007199254740991) |
| `states[].paid` | number | yes | What their earnings paid, taxable and exempt. |
| `states[].excluded` | number | yes | The excluded_perception_types amount: it doesn't add to the base. |
| `states[].base` | number | yes | paid minus excluded. |
| `states[].rate` | number | yes | The rate (0.03 is 3%); in Sinaloa, the effective one from its table. |
| `states[].tax` | number | yes | The payroll tax: base times rate. |
| `states[].surcharges` | array of object | yes | The state's surcharges on the tax or the base. |
| `states[].surcharges[].label` | string | yes | The surcharge. |
| `states[].surcharges[].amount` | number | yes | Amount. |
| `states[].total` | number | yes | tax plus surcharges. |
| `states[].option` | string or null | yes | The rate option chosen, in the states that have one. |
| `states[].options` | array of object or null | yes | The state's rate options (company size), or null. |
| `states[].law` | string or null | yes | The article that levies it. |
| `perceptions` | array of object | yes | The month's earnings. |
| `perceptions[].type` | string | yes | c_TipoPercepcion. |
| `perceptions[].label` | string | yes | Its name in the SAT catalog. |
| `perceptions[].amount` | number | yes | What it paid in the month. |
| `perceptions[].excluded` | boolean | yes | Whether it doesn't add to the base. |
| `excluded_perception_types` | array of string | yes | The earnings that don't add to the base. |

```json
{
  "object": "payroll_tax",
  "livemode": false,
  "issuer": "iss_OufpKqnrvx9p",
  "month": "2026-10",
  "total": 8806.55,
  "states": [
    {
      "state": "CMX",
      "name": "Ciudad de México",
      "employees": 12,
      "receipts": 24,
      "paid": 196400,
      "excluded": 0,
      "base": 196400,
      "rate": 0.04,
      "tax": 7856,
      "surcharges": [],
      "total": 7856,
      "option": "general",
      "options": [
        {
          "id": "general",
          "label": "Mediana o grande (4%)"
        },
        {
          "id": "pequena",
          "label": "Pequeña empresa (3.5%)"
        },
        {
          "id": "micro",
          "label": "Microempresa (3%)"
        }
      ],
      "law": "art. 158 del Código Fiscal de la Ciudad de México"
    },
    {
      "state": "MEX",
      "name": "Estado de México",
      "employees": 2,
      "receipts": 4,
      "paid": 34515,
      "excluded": 2830,
      "base": 31685,
      "rate": 0.03,
      "tax": 950.55,
      "surcharges": [],
      "total": 950.55,
      "option": null,
      "options": null,
      "law": "art. 57 del Código Financiero del Estado de México y Municipios"
    }
  ],
  "perceptions": [
    {
      "type": "001",
      "label": "Sueldos, Salarios Rayas y Jornales",
      "amount": 228085,
      "excluded": false
    },
    {
      "type": "003",
      "label": "Participación de los Trabajadores en las Utilidades PTU",
      "amount": 2830,
      "excluded": true
    }
  ],
  "excluded_perception_types": [
    "003",
    "004",
    "014",
    "022",
    "023",
    "024",
    "025",
    "026",
    "027",
    "037",
    "039",
    "044",
    "050"
  ]
}
```

## Errors

- `feature_not_in_plan` (403): Live, this part of the API (inventario, portal de proveedores, pedidos, comprobación de gastos) follows the empresa's plan, as in the app: it comes with Operaciones (added to any paid plan; included in Corporativo). The books (the /v1/accounting routes except DIOT, cross checks, IVA refunds and fixed assets) come with Contabilidad (added to Independiente, Emprendedor or Negocio; included in Despacho and Corporativo): without it, changing the books answers this error, and reading them works only up to the last month it had it. Add either in Ajustes › Plan y pagos; test mode has everything.
- `issuer_archived` (400): The issuer is archived and no longer stamps. Its documents can still be read and canceled.
- `issuer_linked_empresa` (403): That issuer is an empresa of the app connected to your account: through the API it only offers its Portal de proveedores (/v1/portal_suppliers and /v1/supplier_invoices) and, once someone who may pay suppliers and change Configurar pagos turned them on, its supplier payouts (/v1/payouts and /v1/payroll_payouts). It also stops when whoever connected it (or turned its payouts on) no longer has that permission in the empresa: message_es says which. Do everything else in the app.
- `issuer_missing` (404): There is no such issuer in the account (or it belongs to the other mode).
- `issuer_not_allowed` (403): This key can't use that issuer.
- `issuer_required` (400): The account has several issuers and the request doesn't say which: send `issuer` (iss_…).
- `livemode_mismatch` (400): The object belongs to the other mode: an fk_test_ key only sees test data and an fk_live_ key only live data.
- `resource_missing` (404): There's no object with that id (or it belongs to another issuer or the other mode).

Plus those of any call (key, fields, limits): https://fiscalisto.com/en/docs/api/errores.md.
