# Create product

The method allows you to create a product

Endpoint: POST /locations/{location_id}/products
Version: 1.0.0
Security: BearerPartnerUser

## Security:

  - `BearerPartnerUser` (unknown)
    http bearer Bearer {PartnerToken}, User {UserToken}

## Path parameters:

  - `location_id` (number, required)
    Location ID

## Header parameters:

  - `Accept` (string, required)
    application/vnd.api.v2+json

  - `Content-Type` (string, required)
    application/json

  - `Authorization` (string, required)
    Bearer partner_token, User user_token

## Request fields (application/json):

  - `title` (string, required)
    Product Name

  - `print_title` (string)
    Title to be printed on receipt

  - `article` (string)
    vendor code

  - `barcode` (string)
    Barcode

  - `category_id` (integer, required)
    Product category ID

  - `cost` (number)
    Selling price

  - `actual_cost` (number)
    Cost price

  - `sale_unit_id` (integer, required)
    Sales unit

  - `service_unit_id` (integer, required)
    Write-off unit

  - `unit_equals` (number)
    The ratio of the unit of measure for sale to the unit of measure for write-off

  - `critical_amount` (number)
    critical residue

  - `desired_amount` (number)
    Desired balance

  - `netto` (number)
    Net weight

  - `brutto` (number)
    Gross weight

  - `comment` (string)
    A comment

  - `tax_variant` (integer)
    Taxation system

  - `vat_id` (integer)
    VAT

## Response 201:

  - `201` (unknown)
    Created

## Response 201 fields (application/json):

  - `success` (boolean)
    Execution success status (true)

  - `data` (object)
    Product data object

  - `data.title` (string)
    Name of product

  - `data.value` (string)
    Name of product

  - `data.label` (string)
    Product name with article number (if any)

  - `data.good_id` (number)
    Product ID

  - `data.cost` (number)
    Selling price

  - `data.unit_id` (number)
    Sales Unit ID

  - `data.unit_short_title` (string)
    Sales unit

  - `data.service_unit_id` (number)
    ID of unit of measure to write off

  - `data.service_unit_short_title` (string)
    Write-off unit

  - `data.actual_cost` (number)
    Cost price

  - `data.unit_actual_cost` (number)
    Unit cost

  - `data.unit_actual_cost_format` (string)
    Unit cost format

  - `data.unit_equals` (number)
    The ratio of the unit of measure for sale to the unit for write-off

  - `data.barcode` (string)
    Barcode

  - `data.loyalty_abonement_type_id` (number)
    Membership type identifier (if the product is a membership)

  - `data.loyalty_certificate_type_id` (number)
    Gift card type identifier (if the item is a gift card)

  - `data.loyalty_allow_empty_code` (boolean | number)
    Is it allowed to sell without a code (can be 0/1 or true/false)

  - `data.critical_amount` (number)
    Critical residue

  - `data.desired_amount` (number)
    Desired balance

  - `data.actual_amounts` (array)
    Remaining stock

  - `data.actual_amounts.storage_id` (number)
    Inventory ID

  - `data.actual_amounts.amount` (number)
    Quantity

  - `data.last_change_date` (string)
    The date the entity was last modified

  - `meta` (array)
    Metadata (empty array)

## Response 422:

  - `422` (unknown)
    Unprocessable Entity

## Response 422 fields (application/json):

  - `success` (boolean)
    Execution success status

  - `data` (string)
    Contains null

  - `meta` (object)
    Contains an error message

  - `meta.message` (string)

  - `meta.errors` (array)

  - `meta.errors.message` (string)

