NuminaDevelopers
Dashboard
Create product

Create product

POST
/v1/products

Creates a product in the company's catalogue. Returns 409 when the product number is already used.

Requires one ofproducts:writewrite:draftwrite:ledger

Body

application/json

  • product_numberstring· nullable· max 64 chars
    Product number (varenummer). Must be unique within the company; null or empty clears it.
  • descriptionstringRequired· max 500 chars
    Product name (required)
  • quantitynumber· ≥ 0
    Default quantity (default 1)

    Default 1

  • unitstring
    Unit (default unit)
    One ofunithourdaykilometerweekmonth

    Default "unit"

  • unit_pricenumberRequired
    Unit price (excl. VAT)
  • sales_account_numberintegerRequired
    Account number of a sales account (from GET /v1/accounts)
  • Use the sales account's default VAT code. Cannot be combined with vat_code.
  • vat_codestring· nullable
    Sales VAT code (e.g. 'U25') from GET /v1/vat-codes, or null for no VAT. Setting it turns use_account_vat off.

Errors

  • 400Invalid input or validation failed
  • 401Invalid or missing authentication
  • 403Missing scope, or the company is archived
  • 409The product number is already used
  • 429Rate limit exceeded
  • 500Internal Server Error

Every error has the same shape. See Errors.

cURL
curl -X POST https://api.numina.app/v1/products \
  -H "Authorization: Bearer numi_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "product_number": "1001",
    "description": "Consulting hour",
    "quantity": 1,
    "unit": "hour",
    "unit_price": 950,
    "sales_account_number": 1000,
    "use_account_vat": true,
    "vat_code": "U25"
  }'
JavaScript
const response = await fetch("https://api.numina.app/v1/products", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${process.env.NUMINA_API_KEY}`,
    "Content-Type": "application/json",
  },
  body: JSON.stringify({
    "product_number": "1001",
    "description": "Consulting hour",
    "quantity": 1,
    "unit": "hour",
    "unit_price": 950,
    "sales_account_number": 1000,
    "use_account_vat": true,
    "vat_code": "U25"
  }),
});

const data = await response.json();
Python
import os

import requests

response = requests.post(
    "https://api.numina.app/v1/products",
    headers={
        "Authorization": f"Bearer {os.environ['NUMINA_API_KEY']}",
    },
    json={
        "product_number": "1001",
        "description": "Consulting hour",
        "quantity": 1,
        "unit": "hour",
        "unit_price": 950,
        "sales_account_number": 1000,
        "use_account_vat": True,
        "vat_code": "U25"
    },
)
data = response.json()
Response
201
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "product_number": "1001",
  "description": "Consulting hour",
  "quantity": 1,
  "unit": "hour",
  "unit_price": 950,
  "sales_account_number": 1000,
  "use_account_vat": true,
  "vat_code": null
}