Before a sales invoice can be retrieved, a list of sales invoices must be requested for the id of the wanted invoice. With the id, specific information can be retrieved one at a time. When importing a sales invoice, it is recommended that the customer- and product registers are being up to date.
Sales invoices' handling operations are divided into the following resources:
Integration | HTTP-method | Resource | DTD | Schema | Example |
Get sales invoice or order list | GET | salesinvoicelist.nv | Invoicelist Download Orderlist Download | ||
Get sales invoice or order details | GET | getsalesinvoice.nv / getorder.nv | |||
Import sales invoice, credit invoice or order | POST | salesinvoice.nv | Download | Download | |
Get sales personnel list | GET | salespersonnellist.nv | Download | ||
Delete sales invoice | GET | deletesalesinvoice.nv | |||
Update sales invoice status | POST | updatesalesinvoicestatus.nv |
Get sales invoice or order list
Resource: salesinvoicelist.nv
This resource can be used to retrieve a list of sales invoices and orders by changing the value of the ListType parameter.
Querystring parameters:
Parameter name | Occurs | Description | Example |
ListType | 0...1 | Empty value if fetching sales invoice list preinvoice if fetching order list | |
InvoicesAboveNetvisorKey | 0...1 | Includes only invoice after given id | 165 |
BeginInvoiceDate | 0...1 | Includes only invoice after given date | 2012-01-01 |
EndInvoiceDate | 0...1 | Includes only invoices before given date | 2012-12-31 |
InvoiceNumber | 0...1 | Includes only invoice with given invoice number | |
InvoiceStatus | 0...1 | Includes only invoice with specified status, see below what is included | open |
LastModifiedStart | 0...1 | Finds invoices that are modified after given date | 2012-10-23 |
LastModifiedEnd | 0...1 | Finds invoices that are modified before given date | 2012-10-24 |
salesinvoicebatchid | 0...1 | Includes only invoices with given Batch ID. See the description of the Sales Invoice Batch Handling |
InvoiceStatus parameter can have the following values:
InvoiceStatus | Returns invoices with status |
open | OPEN, OVERDUE, REMINDED, REQUESTED, COLLECTED |
overdue | OVERDUE, REMINDED, REQUESTED, COLLECTED |
paid | PAID |
unsent | UNSENT |
creditloss | CREDITLOSS |
rejected | REJECTED |
Response:
Level | Element name | Type and length | Occurs | Description | Example |
root | Root | Aggr. | |||
1 | SalesInvoiceList | Aggr. | 1 | ||
2 | SalesInvoice | Aggr. | 0...n | ||
3 | NetvisorKey | Numeric | 1 | Invoice identifier in Netvisor | 123 |
3 | InvoiceNumber | String | 1 | Invoice number | 1234 |
3 | InvoiceDate | Date | 1 | Invoice date | 2013-11-09 |
Attr. | format | String | 1 | Always ansi | ansi |
3 | InvoiceStatus | String | 1 | Status of the invoice or order. Returns sales invoice payment status. | See table below. |
Attr. | substatus | String | 0...1 | Invoice sub staus. Will return status of receivables on the invoice. This attribute is not used for orders. | open, overdue, reminded, requested or collected |
Attr. | isincollection | Numeric | 1 | Is invoice in collection or not (Intrum/Duetto) | 0 or 1 |
3 | CustomerCode | String | 1 | Billed customer's code | |
3 | CustomerName | String | 1 | Customer's name | |
3 | ReferenceNumber | String | 1 | Invoice reference number | |
3 | InvoiceSum | Numeric | 1 | Invoice sum, two decimals | 12,34 |
3 | OpenSum | Numeric | 1 | Open sum, two decimals | 12,34 |
3 | Uri | String | 1 | Uri that can be used to get details of invoice or order | See below |
Return value differences for orders and invoices:
InvoiceStatus | URI | |
Invoice | open, creditloss, paid, rejected | /getsalesinvoice.nv?netvisorkey=123 |
Order | archived, undelivered, delivered, billed | /getorder.nv?netvisorkey=123 |
Recourse: getsalesinvoice.nv or getorder.nv
Before a sales invoice can be retrieved, a list of sales invoices must be requested for the id of the wanted invoice. With the id, specific information can be retrieved one at a time. If user has modified the arrangement of the invoice's invoice rows in the Netvisor user interface, request retains that arrangement.
Same resource can be used to retrieve sales order. Follows same structure as salesinvoice and same parameters can be used.
Querystring parameters:
Parameter name | Occurs | Description | Example |
NetvisorKey | 1 | Invoice identifier of the salesinvoice | 125 |
pdfimage | 0...1 | If the parameter is not given, the response is the same as pdfimage=lastsentprintservice | |
showprocesshistory | 0...1 | Returns the sending and printing history of the sales invoice in ProcessHistory-element | 1 |
includeattachments | 0...1 | Returns all the attachments in Base64-encoding | 1 |
showcommentlines | 0...1 | Returns invoice's comment rows inside Invoiceline aggregate | 1 |
NetvisorKeyList | 0...1 | Can be used to get the full details of several invoices with given id. Max. 500 identifiers | 1,2,3 |
includedocuments | 0...1 | When getting salesinvoice, returns orders related to the invoice. | 1 |
Example: getsalesinvoice.nv?netvisorkey=1234&pdfimage=pdf&showprocesshistory=1
Example: getsorder.nv?netvisorkey=1234&pdfimage=pdf&showprocesshistory=1
Response:
Level | Element name | Type and legth | Occurs | Description | Example |
root | Root | Aggr. | 1 | ||
1 | SalesInvoice | Aggr. | 1 | ||
2 | SalesInvoiceNetvisorKey | String | 1 | Invoice Netvisor ID | |
2 | SalesInvoiceNumber | String | 1 | Invoice number | |
2 | SalesInvoiceDate | Date | 1 | Invoice date | 2012-01-27 |
Attr. | format | String | 1 | Date format, always ansi | ansi |
2 | SalesInvoiceEventDate | Date | 1 | Invoice event date | 2012-02-01 |
Attr. | format | String | 1 | Event date format, always ansi | ansi |
2 | SalesInvoiceValueDate | Date | 1 | Invoice's Valuedate | 2012-01-27 |
Attr. | format | String | 1 | Date format, always ansi | ansi |
2 | SalesInvoiceDeliveryDate | Date | 1 | Invoice's date of delivery | 2012-01-27 |
Attr. | format | String | 1 | Always ansi | ansi |
2 | SalesInvoiceDueDate | Date | 1 | Invoice's due date | 2012-01-27 |
Attr. | format | String | 1 | Always ansi | ansi |
2 | SalesInvoiceReferencenumber | String | 1 | Invoice's reference number | 7659221 |
2 | SalesInvoiceAmount | Numeric | 1 | Invoice total | 124,50 |
Attr. | iso4217currencycode | String | 0...1 | Currency used in invoice | USD |
Attr. | currencyrate | Numeric | 0...1 | Currency conversion rate | 0,91 |
2 | SellerIdentifier | String | 1 | Indentifier of the seller (name) | Matti Meikäläinen |
Attr. | type | String | 1 | Always name meaning that element SellerIdentifier is name of seller | name |
2 | InvoiceStatus | String | 1 | Status of the invoice/order | Paid |
2 | SalesInvoiceFreeTextBeforeLines | String | 1 | Free text before invoice lines | |
2 | SalesInvoiceFreeTextAfterLines | String | 1 | Free text after Invoice lines | |
2 | SalesInvoiceOurReference | String | 1 | Our refence | |
2 | SalesInvoiceYourReference | String | 1 | Your reference | |
2 | SalesInvoicePrivateComment | String | 1 | Comment that will not be visible on the invoice | |
2 | SalesInvoiceAgreementIdentifier | String | 1 | Contract ID | |
2 | InvoicingCustomerName | String | 1 | Customer's Name | |
2 | InvoicingCustomerNameExtension | String | 1 | Customer's Name Extension | |
2 | InvoicingCustomerNetvisorKey | String | 1 | Customer's Netvisor Key/ID | |
2 | InvoicingCustomerOrganizationIdentifier | String | 1 | Customer's Organization identifier | If customer is private customer, field will be empty. |
2 | InvoicingCustomerAddressline | String | 1 | Customer's Address | PL 316 |
2 | InvoicingCustomerAdditionalAddressLine | String | 1 | Customer's Adress, additional line | |
2 | InvoicingCustomerPostnumber | String | 1 | Customer's Post Number | 60123 |
2 | InvoicingCustomerTown | String | 1 | Customer's City | Lappeenranta |
2 | InvoicingCustomerCountryCode | String | 1 | Customer's Country code | FINLAND |
2 | MatchPartialPaymentsByDefault | String | 1 | Yes or No | Yes |
2 | DeliveryAddressName | String | 1 | Name for the delivery | |
2 | DeliveryAddressLine | String | 1 | Address of the delivery | |
2 | DeliveryAddressPostnumber | String | 1 | Post number of the delivery | |
2 | DeliveryAddressTown | String | 1 | City of the delivery | |
2 | DeliveryAddressCountryCode | String | 1 | Country code for the delivery | |
2 | DeliveryMethod | String | 1 | Method of delivery | Delivered |
2 | DeliveryTerm | String | 1 | Terms of delivery | Free Deliverer |
2 | PaymentTermNetDays | String | 1 | Days for the terms of payment | 11 |
2 | PaymentTermCashDiscountDays | String | 1 | Days for cash discount | 0 |
2 | PaymentTermCashDiscount | String | 1 | Amount of cash discount | 0 |
Attr. | type | String | 1 | Always percentage | percentage |
2 | Waybillidentifier | String | 1 | Waybill number | 033000050143 |
2 | DeliveryToCustomerDate | String | 0...1 | Sales order delivery to customer date | 2020-10-13 |
Attr. | format | String | 1 | Delivery date format, always ansi | ansi |
2 | DeliveryToCustomerWeek | String | 0...1 | Sales order delivery to customer week | 42/2020 |
2 | TaxHandlingClause | String | 0...1 | Sales invoice tax handling clause | AVL 8 c §, käännetty verovelvollisuus |
Attr. | NetvisorKey | String | 1 | Tax handling clause's NetvisorID | 14 |
2 | LastSentInvoicePDFBase64Data | Base64 | 0...1 | PDF information of previously sent invoice | S89O3Ly1Lr59NB |
2 | InvoiceLines | Aggr. | 1 | ||
3 | InvoiceLine | Aggr. | 1 | ||
4 | SalesInvoiceProductLine | Aggr. | 0...n | ||
5 | NetvisorKey | String | 1 | Id of the product line | 17536 |
5 | ProductIdentifier | String | 1 | Id of the product | TEMP1 |
Attr. | type | String | 1 | Always customer | customer |
5 | ProductName | String | 1 | Name of the product | Example product |
5 | ProductNetvisorKey | String | 1 | Netvisor Key/ID of the product | |
5 | ProductUnitPrice | Numeric | 1 | Unit price of the product | 7,00 |
5 | ProductPurchasePrice | Numeric | 1 | Purchase price of the product | |
5 | ProductVatPercentage | String | 1 | VAT percentage of the product | 24 |
Attr. | VatCode | String | 1 | VAT code | KOMY |
5 | SalesInvoiceProductLineQuantity | 1 | Quantity of product | ||
5 | SalesInvoiceProductLineDiscountPercentage | 1 | Discount percentage | ||
5 | SalesInvoiceProductLineFreeText | String | 1 | Free text for line | |
5 | SalesInvoiceProductLineVatSum | Numeric | 1 | Line vat sum rounded to two decimals | 1,68 |
5 | SalesInvoiceProductLineLinesum | Numeric | 1 | Line sum rounded to two decimals | 8,68 |
5 | SalesInvoiceProductLineInventoryID | Numeric | 1 | Warehouse ID of product | 1 |
5 | SalesInvoiceProductLineInventoryName | String | 1 | Warehouse name of product | Example warehouse |
5 | AccountingAccountSuggestion | String | 1 | Posting suggestion | 551 |
5 | dimension | 0...n | |||
6 | dimensionname | String | 1 | Dimension header | City |
6 | dimensionitem | String | 1 | Dimension name | Helsinki |
5 | ProvisionPercentage | Numeric | 1 | Provision percentage | 12 |
5 | SalesInvoiceCommentLine | Aggr. | 0...n | ||
6 | Comment | String | 1 | Comment line | Comment |
2 | SalesInvoiceAttachments | Aggr. | 0...1 | ||
3 | SalesinvoiceAttachment | Aggr. | 1...n | ||
3 | mimetype | String | 1 | Contents file format | image/jpeg |
3 | attachmentdescription | String | 1 | Description of attachment | |
3 | filename | String | 1 | Filename | Example_picture.jpg |
3 | documentdata | Base64 | 1 | Attachment in Base64-encoding | S89O3Ly1Lr59NBS89 |
2 | documents | Aggr. | 1 | Invoices/orders related to the order/invoice | |
3 | salesorder | Aggr. | 1...n | Note! If getorder.nv is used, the element name is salesinvoice | |
4 | netvisorkey | Numeric | 1 | Netvisor ID of order related to the invoice / Netvisor ID of invoice related to the order | 12345 |
4 | ordernumber | Numeric | 1 | Number of order related to the invoice / | 1001 |
Import sales invoice, credit invoice or order
Resource: salesinvoice.nv
The API makes it possible to add or edit a sales invoice, it's product- and comment lines, attachments, voucher lines and customer specific fields in Netvisor.
The required fields for importing a sales invoice are:
- Date of the invoice
- Sum total
- Invoice status
- Customer's linking information
- Net day of the terms of payment or due date
- At least one invoice line with the following information
- Product linking information
- Product name
- Product's unit price
- Product's VAT percentage and code
- Product's unit count
The salesinvoice can be imported as a salesinvoice draft with status "invoicedraft". It is not possible to give invoice number or import invoice voucherlines for invoice drafts. Invoice draft can be updated to salesinvoice with the parameter edit.
Credit invoice is imported trough the API with the same message structure. The only difference is that unit count and sum total are set to negative numbers. Also productline vat sum and productline sum are set to negative numbers if they are given. Credit invoice is not automatically focused to existing sales invoice. Connecting credit invoice and sales invoice must always be done manually.
Netvisor rounds invoice line rowsum and invoice total sum by 2 digits when importing XML
Billing and delivery customer is focused to sales invoice by Netvisor key or by customer code. Netvisor key is database ID and customer code is individual code given in customer register by Netvisor user. These can be fetched by using customerlist.nv resource.
When only Invoicingcustomeridentifier is given in the Sales Invoice XML and no other invoicing address or delivery address details are on the XML, the API will retrieve this information automatically from customer register. In other hand if any other billing customer detail (i.e. postal address) is given, nothing is retrieved from the customer register.
If an alternative billing customer has been determined to target customer, the API will automatically retrieve the alternative customers information to the imported invoice. In this case, the billing address information in the imported material is not used.
Querystring parameters:
Parameter name | Occurs | Description | Example |
Method | 1 | add or edit. When using method edit, all original order/invoice details must be given if wish to keep them. | Add |
Id | 0...1 | Must be defined if method = edit |
The following describes the XML message to import (POST) a purchase order into Netvisor:
Level | Element name | Type and length | Occurs | Description | Example |
Root | root | Aggr. | 1 | ||
1 | salesinvoice | Aggr. | 1 | ||
2 | salesinvoicenumber | Numeric max. length 15 digits | 0...1 | If number is not given, Netvisor automatically picks next free number. Cannot be given for invoice drafts. | 123456 |
2 | salesinvoicedate | Date | 1 | 2019-12-31 | |
Attr. | format | String | 1 | ansi | |
2 | salesinvoiceeventdate | Date | 0...1 | Invoice's event date. This forms the voucher date. | 2020-01-01 |
Attr. | format | String | 1 | Always ansi | ansi |
2 | salesinvoicevaluedate | Date | 0...1 | Invoice's valuedate. If given, the net days of payment term are applied to the valuedate | 2009-12-31 |
Attr. | format | String | 1 | Always ansi | 2009-12-31 |
2 | salesinvoicedeliverytocustomerdate | Date or week number | 0...1 | Delivery date for customer. Date or week number. For sales order only. | 2018-W12 |
Attr. | format | String | Delivery date for customer, format | ansi | |
Attr. | type | String | 1 | Delivery date for customer. date or weeknumber | weeknumber |
2 | salesinvoicewaybillidentifier | String, max. 35 characters | 0...1 | Waybill number/identifier. For sales order only. | 33000050143 |
2 | salesinvoiceproductpackagepallet | Number | 0...1 | Sales order package. For sales order only. | 2 |
Attr. | type | String | 1 | Pallet code type, GS1 | GS1 |
Attr. | amount | String | 0...1 | Pallet amount | 2 |
2 | salesinvoiceduedate | Date | 1 | Invoice due date, mandatory if payment term is not given. Message cannot have both due date and payment term, only one can be given. | 2017-21-31 |
Attr. | format | String | 1 | Invoice due date form | ansi |
2 | salesInvoicedeliverydate | Date | 0...1 | Invoice delivery or arrival date | 2009-12-31 |
Attr. | format | String | 1 | ansi | |
2 | salesinvoicereferencenumber | Referencenumber | 0...1 | Invoice reference number. Must be in correct format with checksum | 1070 |
2 | salesinvoiceamount | Numeric | 1 | Total amount of the invoice. Possible to give as empty value </salesinvoiceamount>, then the amount is calculated from the invoice rows | 100,99 |
Attr. | iso4217currencycode | String | 0...1 | If not given, currency code from company´s information is used. Otherwise code must be given in ISO 4217 standard | USD |
Attr. | currencyrate | String | 0...1 | If not given, daily currency rate from European central bank is used. If there is no existing currency rate value, then value 1 used automatically | 1,33 |
Attr. | pricetype | String | 0...1 | netvisor or customer. Customer does nothing but if value is netvisor, Netvisor's price groups and customer prices will be used for invoice rows. SalesInvoiceAmount -value should be 0 so that invoice amout is calculated correctly from invoice rows. | netvisor |
2 | SellerIdentifier | String | 0...1 | Id of seller in Netvisor. Name of the seller can be given separately in element sellername | 1 |
Attr. | type | String | 1 | Use netvisor | netvisor |
2 | sellername | String, max. length 50 | 0...1 | Free form name of the seller | Matti Mallikas |
2 | invoicetype | String | 0...1 | Invoice, Order or invoicedraft. | Invoice |
2 | salesinvoicestatus | String | 1 | Status of invoice Open or Unsent for invoice, delivered or undelivered for order | Open |
Attr. | type | String | 1 | Use netvisor | netvisor |
2 | salesinvoicefreetextbeforelines | String, max. length 500 | 0...1 | Free text before before invoice lines | |
2 | salesinvoicefreetextafterlines | String, max. length 500 | 0...1 | Free text after invoice lines | |
2 | salesinvoiceourreference | String, max. length 200 | 0...1 | Information for "our reference" field | |
2 | salesinvoiceyourreference | String, max. length 200 | 0...1 | Information for "your reference" field | |
2 | salesinvoiceprivatecomment | String, max. length 255 | 0...1 | Shown only in Netvisor interface, not printed on invoice form | |
2 | Invoicingcustomeridentifier | String | 1 | Information used to link invoicing customer to invoice. Customer must be already in Netvisor. Value can be customer code or id of customer record in Netvisor (see type attribute) | MM |
Attr. | type | String | 1 | Type of link: netvisor (=Netvisor ID), customer (=customer code), or organizationunitnumber (=OVT-identifier) | customer |
Attr. | contactpersonid | String | 0...1 | Customer's contact person's Netvisor ID. Can be retreived with getcustomer.nv. | 4012 |
2 | invoicingcustomername | String, max. length 250 | 0...1 | Will not be collected from Netvisor | Matti |
2 | invoicingcustomernameextension | String, max. length 250 | 0...1 | Will not be collected from Netvisor | Meikäläinen |
2 | invoicingcustomeraddressline | String, max. length 100 | 0...1 | Will not be collected from Netvisor | Pajukuja 1 |
2 | invoicingcustomeradditionaladdressline | String, max. length 100 | 0...1 | Will not be collected from Netvisor | |
2 | invoicingcustomerpostnumber | String, max. length 50 | 0...1 | Will not be collected from Netvisor | 53100 |
2 | invoicingcustomertown | String, max. length 50 | 0...1 | Will not be collected from Netvisor | Lappeenranta |
2 | invoicingcustomercountrycode | String | 0...1 | In ISO 3316 format. *) | FI |
Attr. | type | String | 1 | Will not be collected from Netvisor | ISO-3316 |
2 | deliveryaddressName | String, max. length 250 | 0...1 | Will not be collected from Netvisor | Maija |
2 | deliveryaddressline | String, max. length 100 | 0...1 | Will not be collected from Netvisor | Pajukuja 2 |
2 | deliveryaddresspostnumber | String, max. length 50 | 0...1 | Will not be collected from Netvisor | 55100 |
2 | deliveryaddresstown | String, max. length 50 | 0...1 | Will not be collected from Netvisor | Imatra |
2 | deliveryaddresscountrycode | String | 0...1 | Will not be collected from Netvisor | FI |
Attr. | type | String | 1 | Will not be collected from Netvisor | ISO-3316 |
2 | deliverymethod | String, max. length 50 | 0...1 | Free form text. If given value is not found from Netvisor, then value is created as new delivery method in Netvisor | Installed |
2 | deliveryterm | String, max. length 50 | 0...1 | Free form text. If given value is not found from Netvisor, then value is created as new delivery term in Netvisor | According to agreement |
2 | salesinvoicetaxhandlingtype | String | 0...1 | countrygroup, forcedomestic, domesticconstructionservice or notaxhandling. *1) If not given, taxhandlingtype from customer's information will be used | countrygroup |
2 | paymenttermnetdays | Numeric | 1 | Invoice date + paymenttermnetdays = invoice duedate. Payment term: "14 days net" | 14 |
2 | paymenttermcashdiscountdays | Numeric | 0...1 | Cash discount days for the payment term. Payment term: "14 days net, 5 days" | 5 |
2 | paymenttermcashdiscount | Numeric | 0...1 | Cash discount percent. Payment term: "14 days net, 5 days- 10%" | 10 |
Attr. | type | String | 1 | Type of discount, always percentage | percentage |
2 | expectpartialpayments | Numeric | 0...1 | 1 = yes, 0 = no. Default 0. If the invoice accepts partial payments, the invoice is also accepting payments outside the the cash discount tolerances | 1 |
2 | overridevouchersalesreceivablesaccountnumber | Numeric | 0...1 | When given, this will override the default sales receivables account number in Netvisor | 1703 |
2 | salesinvoiceagreementidentifier | String, max. length 35 | 0...1 | Contract ID | |
2 | printchannelformat | String | 0...1 | ||
Attr. | type | String | 1 | netvisor or customer | netvisor |
2 | secondname | String | 0...1 | supplementary firm name | Example name |
Attr. | type | String | 1 | netvisor (NetvisorKey) or customer (name) | customer |
2 | overriderateofoverdue | Numeric | 0...1 | Penalty interest-%, overrides Netvisor default | 5,5 |
2 | invoicelines | Aggr. | 1 |
Invoice lines can be either product lines or comment lines. Product in a product line must exist in Netvisor and be linked to the line either with Netvisor-key or customer specific key. However product name, price and other information can be altered. VAT -rate must be specified for the product line. If the imported invoice has both product- and comment lines, their order will be the same as in the imported material.
If product lines are needed, structure for InvoiceLine aggregate is this:
Level | Element name | Type and length | Occurs | Description | Example |
3 | invoiceline | Aggr. | 1...n | ||
4 | salesinvoiceproductline | Aggr. | 1 | ||
5 | productidentifier | String | 1 | Product identifier, either netvisorkey or given product code. Product must be founded in Netvisor. | |
Attr. | type | String | 1 | Type of indentifier: | netvisor |
5 | productname | String, max. 200 | 0...1 | Name of the product. If not given will be retrieved from Netvisor. | test product |
5 | productunitprice | Numeric | 1 | Product unit price, not retrieved from Netvisor | 10,05 |
Attr. | String | 1 | Type of unit price, net or gross | net | |
5 | productunitpurchaseprice | Numeric | 0...1 | Product unit purchase price | 1,05 |
Attr. | type | String | 1 | Type of unit purchase price, always net | net |
5 | productvatpercentage | Numeric | 1 | Must not conflict with vat code | 22 |
Attr. | vatcode | String | 1 | NONE, KOOS, EUOS, EUUO, EUPO, 100, KOMY, EUMY, EUUM, EUPM312, EUPM309, MUUL, EVTO, EVPO, RAMY, RAOS or EVRO | KOMY |
5 | salesinvoiceproductlinequantity | Numeric | 1 | Amount of products. Can be integer or decimal. Max two decimals (e.g. 3,55) | 5 |
5 | salesinvoiceproductlinediscountpercentage | Numeric | 0...1 | Discount percentage | 10 |
5 | salesinvoiceproductlinefreetext | String, max. 255 | 0...1 | Free text for the product line | |
5 | salesinvoiceproductlinevatsum | Numeric | 0...1 | Tax for the product line. Given if amount calculated by Netvisor is wished to be overridden | 11,00 |
5 | salesinvoiceproductlinesum | Numeric | 0...1 | Line's gross total sum. Given if sum calculated by Netvisor is wished to be overridden | 50,00 |
Note! Both salesinvoiceproductlinesum and salesinvoiceproductlinevatsum elements are required if sum calculated by Netvisor is wished to be overridden. | |||||
5 | salesinvoiceproductlineinventoryid | Numeric | 0...1 | Warehouse ID of productline | 1 |
5 | accountingaccountsuggestion | Numeric | 0...1 | Suggestion for accounting account. Must be found in the system | 3000 |
5 | skipaccrual | Numeric | 0...1 | Should the line be skipped in accruals. By default all lines will be included | 1 |
5 | dimension | 0...n | |||
6 | dimensionname | String, max. 50 | 1 | Dimension | |
6 | dimensionitem | String, max. 200 | 1 | Dimension name | |
5 | provisionpercentage | Numeric | 0...1 | Provision percentage | 12 |
5 | accrualrule | Aggr. | 0...1 | Accrual rule for invoice row, you can use equal division OR allocation curve. Invoicestatus has to be "open", that the voucher is generated. | |
6 | startmonth | Numeric | 1 | Starting month | 9 |
6 | startyear | Numeric | 1 | Starting year | 2019 |
6 | endmonth | Numeric | 0...1 | Ending month (only with equal division) | 12 |
6 | endyear | Numeric | 0...1 | Ending year (only with equal division) | 2019 |
6 | divisioncurvename | String | 0...1 | Allocation curve (only with allocation curve) Has to be predefined in Netvisor view: 'Financials > Budgeting settings > Allocation curves' | quarter |
5 | productunitname | String, max 14 | 0...1 | Product unit. If not given, Netvisor will use the product unit from product details in Netvisor. Cannot be given if the compay is using Extended product management. | pcs |
If comment lines are needed, use the following structure for InvoiceLine aggregate:
Level | Element name | Type and length | Occurs | Description | Example |
3 | invoiceline | Aggr. | 1...n | ||
4 | salesinvoicecommentline | Aggr. | 1 | ||
5 | comment | String | 1 | Comment for the invoice | Comment for the invoice |
After the invoice lines, the structure continues as follows:
Level | Element name | Type and length | Occurs | Description | Example |
2 | invoicevoucherlines | Aggr. | 0...1 | *2 | |
3 | voucherline | Aggr. | 1...n | ||
4 | linesum | Numeric | 1 | Line sum. Positive value will be recorded as debit, and negative as credit | 100 |
Attr. | type | String | 1 | Type of sum, net or gross | net |
4 | description | String, max. 255 | 0...1 | Free description text | |
4 | accountnumber | String | 1 | Account number, must be found in the system | 3000 |
4 | vatpercent | Numeric | 1 | VAT percent. Must not conflict with VAT code | 22 |
Attr. | vatcode | Numeric | 1 | NONE, KOOS, EUOS, EUUO, EUPO, 100, KOMY, EUMY, EUUM, EUPM312, EUPM309, MUUL, EVTO, EVPO, RAMY, RAOS or EVRO | KOMY |
4 | skipaccrual | Numeric | 0...1 | Will the line be skipped in accrual. Assumed that no lines will be skipped. | |
5 | dimension | Aggr. | 0...n | ||
6 | dimensionname | String | 1 | Dimension name | Project 1 |
6 | dimensionitem | String | 1 | Dimension item | Payroll |
2 | salesinvoiceaccrual | Aggr. | 0...1 | ||
3 | overridedefaultsalesaccrualaccountnumber | Numeric | 0...1 | Override default accrual account. Must be found in the system | |
3 | salesinvoiceaccrualtype | String | 0...1 | ||
3 | accrualvoucherentry | Aggr. | 1...n | Invoice accrual (Alternative to the element accrualrule, this is the old way) | |
4 | month | Numeric | 1 | Accrual month. Accrual voucher will be recorded on the last day of the chosen month of the chosen year | 10 |
4 | year | Numeric | 1 | Accrual Year | 2014 |
4 | sum | Numeric | 1 | Sum of the lines | |
2 | accrualrule | Aggr. | 0...1 | Accrual rule for the whole invoice, you can use equal division OR allocation curve. Invoicestatus has to be "open", that the voucher is generated. | |
3 | stratmonth | Numeric | 1 | Starting month | 9 |
3 | startyear | Numeric | 1 | Starting year | 2019 |
3 | endmonth | Numeric | 0...1 | Ending month (only with equal division) | 12 |
3 | endyear | Numeric | 0...1 | Ending year (only with equal division) | 2019 |
3 | divisioncurvename | String | 0...1 | Allocation curve (only with allocation curve) Has to be predefined in Netvisor view: 'Financials > Budgeting settings > Allocation curves' | quarter |
2 | salesinvoiceattachments | Aggr. | 0...1 | ||
3 | salesinvoiceattachment | Aggr. | 1...n | ||
4 | mimetype | String | 1 | MIME type of the attachment | Application/pdf |
4 | attachmentdescription | String | 1 | Description of the attachment | |
4 | filename | String | 1 | Filename of the attachment | project1.pdf |
4 | documentdata | String | 1 | Base64 encoded data of the attachment | |
Attr. | type | String | 1 | By default is used the pdf, if the attribute is not provided. Values: | |
4 | printbydefault | Numeric | 0...1 | NOTE! Is not given if the attachment type is Finvoice (otherwise the request is rejected) 1= true, 0 = false | 1 |
1*) If value is other than DomesticConstructionService is used in SalesInvoiceTaxHandling field, then value of this field is overriden with value DomesticConstructionService if invoice contains at least one line containing tax code Construction_Service_Sales. All lines in invoice must have same tax code.
2*) While importing a sales invoice, the material can include separate voucher lines, if the voucher is wanted to be formed manually. The system will use the voucher lines of the imported material, and not form voucher lines automatically if they have been included. The voucher lines in sales invoice are similar to those in Get Accounting Data request.
Resource: deletesalesinvoice.nv
This resource differs from others by it doesn't need XML message to work. Request is transferred in URI.
With this resource it is possible to remove sales invoice or sales order and its attachments, dimension links, vouchers and etc.
Querystring parameters:
Parameter name | Occurs | Description |
invoiceid | 1 | Invoice Netvisor ID |
orderid | 0...1 | Sales order Netvisor ID |
Resource: updatesalesinvoicestatus.nv
This resource differs from others by it doesn't need XML message to work. Request is transferred in URI.
With this resource it is possible to update one or multiple sales invoice statuses. If status is update to any other state than "unsent", sales invoice voucher is created automatically.
Querystring parameters:
Parameter name | Occurs | Example | Description |
netvisorkey | 1 | 145 | Invoice Netvisor ID |
netvisorkeylist | 0...1 | 1, 2, 3 | Invoices Netvisor ID list separated with comma |
status | 1 | open | To which status invoice/invoices will be set |
Oliko tästä vastauksesta apua? Kyllä Ei
Send feedback