# Create a product

`POST https://api.fiscalisto.com/v1/products`

A product or service in the issuer's catalog, with its SAT key, its unit, its price and its taxes, to use in items with product.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `Idempotency-Key` | header |  | Optional (the SDKs send it on their own). If the response is lost, repeat the request with the same value within 24 hours: it answers the same, with idempotent-replayed: true, and doesn't do it twice (it doesn't create, send emails or charge). |

## Body

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `issuer` | string |  | Issuer (iss_…). If the key has a single issuer or the account has only one, it can be left out. |
| `name` | string or null |  | Short name to find it, just for you; the CFDI carries description. |
| `description` | string | yes | Description. (up to 1000 characters) |
| `product_key` | string | yes | Product or service key (ClaveProdServ), 8 digits from c_ClaveProdServ. Look it up with GET /v1/sat_catalogs/product_keys?q=… |
| `unit_key` | string |  | Unit key (ClaveUnidad) from c_ClaveUnidad: E48 service unit, H87 piece, ACT activity… By default H87 if the product key is for goods (segments 10 to 60) and E48 if it's for a service. (up to 5 characters) |
| `unit_name` | string or null |  | Unit name (Unidad), up to 20 characters. |
| `sku` | string or null |  | Identification number or SKU (NoIdentificacion). |
| `unit_price` | number |  | Unit price before taxes (ValorUnitario). (from 0 to 1000000000000) |
| `open_price` | boolean |  | Open price: no fixed price (a hotel night that changes every day); each invoice sends its unit_price. |
| `taxability` | `01`, `02`, `03`, `04`, `05`, `06`, `07`, `08` |  | Tax object (ObjetoImp), c_ObjetoImp: 01 not subject, 02 subject (the default), 03 not broken out, 04 not taxable… |
| `iva` | `0`, `0.16`, `0.08`, `exento` |  | Transferred VAT rate: 0.16 (the default), 0.08 (border region), 0 or exento. |
| `ieps` | number or null |  | Transferred IEPS: rate (0.265…) or amount in pesos per unit, depending on ieps_factor. |
| `ieps_factor` | `Tasa`, `Cuota` |  | Tasa or Cuota (IEPS TipoFactor). |
| `iva_retention` | number |  | Withheld VAT rate (for example 0.106667, two thirds of 16%). (from 0 to 0.16) |
| `isr_retention` | number |  | Withheld ISR rate (for example 0.10 professional fees, 0.0125 RESICO). (from 0 to 0.35) |
| `local_taxes` | array of object |  | Local taxes it carries, like the 3% ISH on lodging: they go on each invoice with it, on its line items. (up to 20) |
| `local_taxes[].retention` | boolean | yes | true if it's a local withholding; false if it's a transfer. |
| `local_taxes[].name` | string | yes | Name of the local tax (ImpLocTrasladado or ImpLocRetenido), like ISH. (up to 100 characters) |
| `local_taxes[].rate` | number | yes | Rate in percent (TasadeTraslado or TasadeRetencion). (greater than 0 and up to 100) |
| `hydrocarbon` | object or null |  | Diesel (15101505) and gasoline (15101514, 15101515): the CNE permit each invoice with it carries in the Hidrocarburos y Petrolíferos complement. An invoice whose line item carries its own hydrocarbon uses that one. null removes it. |
| `hydrocarbon.permit_type` | string | yes | CNE or CRE permit type (TipoPermiso, c_TipoPermiso): PER01 to PER11. |
| `hydrocarbon.permit_number` | string | yes | CNE or CRE permit number (NumeroPermiso), like PL/12345/EXP/ES/2016: from 15 to 35 characters. (up to 35 characters) |
| `hydrocarbon.subproduct` | string |  | Subproduct (SubProductoHYP, c_SubProductoHYP): SP16 regular gasoline, SP17 premium, SP18 automotive diesel… |
| `track_stock` | boolean |  | It tracks stock (Inventario): each invoice that sells it takes it out of its branch's warehouse, and a canceled one returns it. See GET /v1/products/{id}/stock. |
| `cost` | number or null |  | Its cost per unit in pesos without VAT, until its purchases give another: it values the stock that comes in without unit_cost. |
| `barcode` | string or null |  | Barcode (EAN, UPC or your own). An invoice whose line item carries it as NoIdentificacion takes stock out of this product. |
| `min_stock` | number or null |  | Minimum stock: below it, the low-stock alert includes it. |
| `portal_visible` | boolean |  | It's sold on the customer portal: your customers order it from there, at their prices (price lists), and the order arrives to be confirmed. |
| `min_order_qty` | number or null |  | The least that can be ordered from the portal, in its unit. |
| `order_step` | number or null |  | It's ordered in multiples from the portal (12: in 12s). |
| `category` | string or null |  | Its category, with the ones above separated by › (also > or /): «Ferretería › Tornillos». If it doesn't exist, it's created. null removes it. |

Example:

```json
{
  "description": "Mensualidad",
  "product_key": "86121700",
  "sku": "MEN-1",
  "unit_price": 2500
}
```

## With the TypeScript SDK

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

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

const product = await fiscalisto.products.create({
  description: "Mensualidad",
  product_key: "86121700",
  sku: "MEN-1",
  unit_price: 2500,
}, { idempotencyKey: "pedido-A-1042" });
```

## With the Python SDK

```python
from fiscalisto import Fiscalisto

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

product = fiscalisto.products.create({
    "description": "Mensualidad",
    "product_key": "86121700",
    "sku": "MEN-1",
    "unit_price": 2500,
}, idempotency_key="pedido-A-1042")
```

## With the PHP SDK

```php
<?php

use Fiscalisto\Fiscalisto;

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

$product = $fiscalisto->products->create([
    'description' => 'Mensualidad',
    'product_key' => '86121700',
    'sku' => 'MEN-1',
    'unit_price' => 2500,
], ['idempotency_key' => 'pedido-A-1042']);
```

## With the .NET SDK

```csharp
using Fiscalisto;

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

var product = await fiscalisto.Products.CreateAsync(new CreateProductParams
{
    Description = "Mensualidad",
    ProductKey = "86121700",
    Sku = "MEN-1",
    UnitPrice = 2500,
}, new RequestOptions { IdempotencyKey = "pedido-A-1042" });
```

## 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()

	product, err := client.Products.Create(ctx, &fiscalisto.CreateProductParams{
		Description: "Mensualidad",
		ProductKey:  "86121700",
		SKU:         fiscalisto.String("MEN-1"),
		UnitPrice:   fiscalisto.Float64(2500),
	}, fiscalisto.WithIdempotencyKey("pedido-A-1042"))
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(product.ID)
}
```

## With the Java SDK

```java
import com.fiscalisto.FiscalistoClient;
import com.fiscalisto.RequestOptions;
import com.fiscalisto.model.CreateProductParams;

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

var product = fiscalisto.products().create(new CreateProductParams()
        .setDescription("Mensualidad")
        .setProductKey("86121700")
        .setSku("MEN-1")
        .setUnitPrice(2500), RequestOptions.idempotencyKey("pedido-A-1042"));
System.out.println(product.getId());
```

## Response 201

OK.

A `Product` object:

| Field | Type | Always present | Description |
| --- | --- | --- | --- |
| `id` | string | yes | Object identifier, with its prefix (iss_, inv_, ret_, cus_, prd_, emp_, bat_, brn_, whs_, stm_, adj_, evt_, whe_). |
| `livemode` | boolean | yes | true in production (fk_live_ keys), false in test mode (fk_test_). Test objects aren't valid before the SAT. |
| `object` | `"product"` | yes | What kind of object it is («invoice», «customer»…). |
| `issuer` | string | yes | The issuer (iss_…). |
| `name` | string or null | yes | Short name to find it, just for you. |
| `description` | string | yes | Description that goes in the CFDI (Descripcion). |
| `product_key` | string | yes | Product or service key (ClaveProdServ), 8 digits from c_ClaveProdServ. Look it up with GET /v1/sat_catalogs/product_keys?q=… |
| `unit_key` | string | yes | Unit key (ClaveUnidad) from c_ClaveUnidad: E48 service unit, H87 piece, ACT activity… By default H87 if the product key is for goods (segments 10 to 60) and E48 if it's for a service. |
| `unit_name` | string or null | yes | Unit name (Unidad), up to 20 characters. |
| `sku` | string or null | yes | Identification number or SKU (NoIdentificacion). |
| `category` | string or null | yes | Its category, with the ones above separated by › («Ferretería › Tornillos»), or null if it has none. |
| `unit_price` | number | yes | Unit price before taxes (ValorUnitario). |
| `open_price` | boolean | yes | Open price: the product has no fixed price and each line item with it sends its unit_price. |
| `taxability` | string | yes | Tax object (ObjetoImp), c_ObjetoImp: 01 not subject, 02 subject (the default), 03 not broken out, 04 not taxable… |
| `iva` | string | yes | Transferred VAT rate: 0.16 (the default), 0.08 (border region), 0 or exento. |
| `ieps` | number or null | yes | Transferred IEPS: rate (0.265…) or amount in pesos per unit, depending on ieps_factor. |
| `ieps_factor` | string or null | yes | Tasa or Cuota (IEPS TipoFactor). |
| `iva_retention` | number | yes | Withheld VAT rate (for example 0.106667, two thirds of 16%). |
| `isr_retention` | number | yes | Withheld ISR rate (for example 0.10 professional fees, 0.0125 RESICO). |
| `local_taxes` | array of object | yes | Local taxes (implocal complement): state transfers and withholdings. |
| `local_taxes[].retention` | boolean | yes | true if it's a local withholding; false if it's a transfer. |
| `local_taxes[].name` | string | yes | Name of the local tax (ImpLocTrasladado or ImpLocRetenido), like ISH. |
| `local_taxes[].rate` | number | yes | Rate in percent (TasadeTraslado or TasadeRetencion). |
| `hydrocarbon` | object or null | yes | Hidrocarburos y Petrolíferos complement: required on each line item of diesel (15101505) or gasoline (15101514, 15101515) of an invoice or credit note, in liters (LTR). |
| `hydrocarbon.permit_type` | string | yes | CNE or CRE permit type (TipoPermiso, c_TipoPermiso): PER01 to PER11. |
| `hydrocarbon.permit_number` | string | yes | CNE or CRE permit number (NumeroPermiso), like PL/12345/EXP/ES/2016: from 15 to 35 characters. |
| `hydrocarbon.subproduct` | string | yes | Subproduct (SubProductoHYP, c_SubProductoHYP): SP16 regular gasoline, SP17 premium, SP18 automotive diesel… |
| `track_stock` | boolean | yes | true if it tracks stock (Inventario). |
| `cost` | number or null | yes | Its unit cost in pesos without IVA, or null. |
| `barcode` | string or null | yes | Its barcode, or null. |
| `min_stock` | number or null | yes | Its minimum stock, or null. |
| `portal_visible` | boolean | yes | true if it is offered in the Portal del cliente for placing orders. |
| `min_order_qty` | number or null | yes | The least that can be ordered of it in the Portal del cliente, or null with no minimum. |
| `order_step` | number or null | yes | In what steps it is ordered in the Portal del cliente (6 to order 6, 12, 18…), or null for one at a time. |
| `created_at` | string (date-time) | yes | When it was created, ISO 8601 with Mexico City time (-06:00). |
| `updated_at` | string (date-time) or null | yes | When it last changed, ISO 8601 (-06:00). |

```json
{
  "id": "prd_OufpKqnrvx9p1",
  "object": "product",
  "livemode": false,
  "issuer": "iss_OufpKqnrvx9p",
  "name": null,
  "description": "Mensualidad",
  "product_key": "86121700",
  "unit_key": "E48",
  "unit_name": "Unidad de servicio",
  "sku": "MEN-1",
  "category": "Servicios › Mensualidades",
  "unit_price": 2500,
  "open_price": false,
  "taxability": "02",
  "iva": "0.16",
  "ieps": null,
  "ieps_factor": null,
  "iva_retention": 0,
  "isr_retention": 0,
  "local_taxes": [],
  "hydrocarbon": null,
  "track_stock": false,
  "cost": null,
  "barcode": null,
  "min_stock": null,
  "portal_visible": false,
  "min_order_qty": null,
  "order_step": null,
  "created_at": "2026-10-20T09:02:11-06:00",
  "updated_at": "2026-10-24T10:15:42-06:00"
}
```

## Errors

- `customer_exists` (400): There's already a customer with that RFC in the issuer's catalog (or a product with that SKU). For a customer, `customer` is its id (cus_…): use it, or update it with POST /v1/customers/{id}.
- `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.
