Resource: product.nv
HTTP-method: POST
Note! If you are using Rackbeat inventory management in Netvisor, the API documentation can be found here: https://support.netvisor.fi/fi/support/solutions/articles/77000554491-rackbeat-stoplight-rajapinta
For extended product management, a new product can be imported via the interface as described below, but updating products is not supported with extended product management.
Querystring parameters:
| Parameter name | Occurs | Description | Example |
| method | 1 | add or edit | add |
| id | 0..1 | Must be included if method is edit, defines the product to update | 123 |
| checkdimensionvalidityperiod | 0...1 | Enables checking the validity period against the voucher date. Import will fail if the cost object or cost object header is not valid on the voucher date. 1 = check enabled | 1 |
| useonlyexistingdimensions | 0...1 | Prevents automatic creation of new cost object headers and cost objects. Returns an error if the given cost object does not exist. 1 = prevention enabled | 1 |
If method has not been set or the product to be updated is not found with the id, an INVALID_DATA error with further details is returned. The id for the product to be updated can be obtained with the product list resource.
Product information can be accurately represented using new weight fields (productnetweight, productgrossweigh and productweightunit). It is recommended not to use the old product weight field (unitweight) anymore. The field can still be used for backward compatibility, but in the user interface, all existing product weight units will change to kilograms (kg) and be expressed in the net weight field.
The data to import is sent with the request as an XML with the following structure (POST data):
| Level | Element name | Type and length | Occurs | Description | Example |
| Root | root | Aggr. | 1 | ||
| 1 | product | Aggr. | 1 | ||
| 2 | productbaseinformation | Aggr. | 1 | ||
| 3 | productcode | String, max 50 characters | 0...1 | Product code | CC |
| 3 | productgroup | String | 1 | Product group name, product is added to the group if it exists. If it does not exist, it will be created | Books |
| 3 | name | String, max 200 characters | 1 | Name of the product | Code Complete |
| 3 | description | String | 0...1 | Description | Second edition |
| 3 | unitprice | Numeric | 1 | Price of a single unit | 42,5 |
| Attr. | type | String | 1 | Indicates whether the given price is gross or net. | net |
| 3 | unit | String, max 50 characters | 0...1 | Unit of measurement, existing is used if found, otherwise new one is created. | pc |
| 3 | unitweight | String | 0...1 | Product unit weight with two decimals. It is recommended not to use this weight field (unitweight) anymore, but to use new weight fields (productnetweight, productgrossweigh and productweightunit). | 1,00 |
| 3 | purchaseprice | Numeric | 0...1 | Purchase price | 25 |
| 3 | tariffheading | String | 0...1 | Tariff heading | Code complete |
| 3 | comissionpercentage | Numeric | 0...1 | Commission percentage | 11 |
| 3 | isactive | Numeric | 1 | Is product active, 0 = inactive / 1 = active | 1 |
| 3 | issalesproduct | Numeric | 1 | Is this a sales product, 0 = no / 1 = yes | 0 |
| 3 | inventoryenabled | Numeric | 0...1 | Is the product in storage, 0 = no / 1 = yes | 1 |
| 3 | inventorybatchlinkingmode | Numeric | 0...1 | Product's batch processing type. Possible values: No batch processing = 1 Manual batch selection = 2 Newest first by delivery date = 3 Oldest first by delivery date = 4 (FIFO) Newest first by use-by date = 5 Oldest first by use-by date = 6 Newest first by manufacturing date = 7 Oldest first by manufacturing date = 8 | 4 |
| 3 | countryoforigin | String | 0...1 | Country of origin | FI |
| Attr. | type | String | 0...1 | Always ISO-3166 | ISO-3166 |
| 3 | primaryeancode | String | 0...1 | Product's primary EAN-code | 123456789012 |
| Attr. | type | String | 0...1 | Type of the EAN-code. The interface checks the format of the EAN-code according to the type. any, ean8, ean13, code128. | ean13 |
| 3 | secondaryeancode | String | 0...1 | Product's secondary EAN-code | 12345689012 |
| Attr | type | String | Type of the EAN-code. The interface checks the format of the EAN-code according to the type. any, ean8, ean13, code128. | ean13 | |
| 3 | inventoryalertlimit | Numeric | 0...1 | Alert limit | 20,50 |
| 2 | productbookkeepingdetails | Aggr. | 0...1 | ||
| 3 | defaultvatpercentage | Numeric | 1 | Vat rate, if the given tax rate is not found, an error is returned | 24 |
| 3 | defaultdomesticaccountnumber | Numeric | 0...1 | Domestic sales account | 3000 |
| 3 | defaulteuaccountnumber | Numeric | 0...1 | EU sales account | 3360 |
| 3 | defaultoutsideeuaccountnumber | Numeric | 0...1 | Sales account outside the community | 3380 |
| 2 | productadditionalinformation | Aggr. | 0...1 | ||
| 3 | productnetweight | Numeric | 0...1 | Net weight | 11,2 |
| 3 | productgrossweight | Numeric | 0...1 | Gross weight | 12,6 |
| 3 | productweightunit | String | 0...1 | Net and gross weight unit: g, kg or tn | kg |
| 3 | dimension | Aggr. | 0...1 | ||
| 4 | dimensionname | String | 1 | Cost object header name. Created if needed. | Project |
| 4 | dimensionitem | String | 1 | Cost object. Created if needed. | Project 1 |
| 4 | dimensionitemcode | String | 0...1 | Cost object code (when this is given, the dimensionitem element is ignored) | DIMC-001 |
| 4 | dimensionitemname | String | 0...1 | Cost object name (when this is given, the dimensionitem element is ignored) | Item Name 1 |
| 3 | productpackageinformation | Aggr. | 0...1 | ||
| 4 | packagewidth | Numeric | 1 | Package width in centimeters | 7,3 |
| 4 | packageheight | Numeric | 1 | Package height in centimeters | 15,0 |
| 4 | packagelength | Numeric | 1 | Package length in centimeters | 36,1 |
| 2 | productcustomtags | Aggr. | 0..1 | ||
| 3 | productcustomtag | Aggr. | 1...n | ||
| 4 | tagname | String | 1 | Additional information field name. | Date field |
| 4 | tagvalue | String | 1 | Additional information field value. | 2022-01-01 |
| Attr. | datatype | String | 1 | Additional information field type. date, text, decimal or enum | date |
Did you find it helpful? Yes No
Send feedback