Resource: purchaseinvoice.nv

HTTP-method: POST

An e-invoice transaction payment will be charged for each purchase invoice imported to Netvisor via API.

Attachments can also be imported for purchase invoice. Purchase invoice attachments have to be in PDF-format.

InvoiceSource must be finvoice to import an attachment.

During the import vendor card is created if vendor is missing from Netvisor. When importing, the vendor is focused to existing vendor by following rules:

  1. Focus on existing vendor if account number and name matches with the invoice and VAT number is the same as on invoice
  2. Focus on existing vendor if account number matches with the invoice and VAT number is the same as on invoice
  3. Focus on existing vendor if account number and name matches with the invoice
  4. Focus on existing vendor if name matches with the invoice and VAT number is the same as on invoice
  5. Focus on existing vendor if account number matches with the invoice and VAT number is empty
  6. Focus on existing vendor if account number matches with the invoice
  7. Focus on existing vendor if VAT number is the same as on invoice
  8. Focus on existing vendor if name matches with the invoice

If non of the above applies, new vendor is created.

Request:

LevelElement nameType and lengthOccursDescriptionExample
RootrootAggr.1 
1purchaseinvoiceAggr.1 
2invoicenumberString1Number of the invoice12345
2invoicedateDate 1Date of the invoice 2014-03-03
Attr.formatString1Date format, always ansiansi
Attr.findopendateString0...1Only true is acceptedtrue
2invoicesourceString0...1Can be manual or finvoice, must be finvoice in order to import attachments. When using finvoice there is approx one (1) minute delay in importing the invoice to Netvisor because the invoice is processed using Finvoice handler.finvoice
2valuedateDate 0...1Currently this is needed in order to import purchase invoices in despite of being marked optional in DTD2014-03-03
Attr.formatString1Date format, always ansiansi
2eventdateDate0...1Event date for purchase invoice voucer2014-03-31
Attr.formatString1Date format, always ansiansi
2duedateDate 1Due date of the invoice2014-03-17
Attr.formatString1Date format, always ansi
2purchaseinvoiceonroundString0...1Defines the status of PurchaseInvoice. Can be open, approved or acceptedopen
Attr.typeString1Type of status, default netvisor netvisor
2vendornameString, max 2500...1Name of the vendorMy Vendor
2vendoraddresslineString, max 800...1Address of the vendor 
2vendorpostnumberString, max 500...1Post number of the vendor 
2vendorcityString, max 500...1City of the vendor 
2vendorcountryString, max 500...1Country code of the vendor FI
2vendorphonenumberString, max 800...1Vendor's phone number 
2vendorfaxnumberString, max 800...1Vendor's fax number 
2vendoremailString, max 800...1Vendor's E-mail address 
2vendorhomepageString, max 800...1Vendor homepage 
2amountNumeric1Total of the invoice, this will be approximated to 2 decimals100,00
2accountnumberString0...1Account number FI1000111234567
2organizationindentifierString0...1Organiztion identifier 123456-7
2deliverydateDate 0...1Invoice delivery date 2014-03-03
Attr.formatString1Date format, always ansi 
2overduefinepercentNumeric 0...1overduefine percent 
2bankreferencenumberString, max 700...1Bank reference or purchase order message1234567
2ourreferenceString, max 2000...1Our reference 
2yourreferenceString, max 2000...1Your reference 
2currencycodeString0...1Currency, currencycode and accountnumber must be given in order to have the exchange calculation done correctlyGBP
2deliverytermsString, max 2550...1Terms of delivery 
2deliverymethodString, max 2550...1Method of delivery 
2commentString, max 255 0...1Comment 
2checksumString0...1Checksum 
2pdfextrapagesNumeric 0...1 
2readyforaccountingNumeric 0...1If given ( and invoices status is approved/accepted ), interface will approve / accept it and form a voucher for accounting1
2primaryvendormatchtypeString0...1Possible to force vendormatch by value:
- code
- name
- bankaccountnumber
- organizationid
If no vendor found with the given value, then default procedure is followed
code
2purchaseinvoicelinesAggr.1 
3purchaseinvoicelineAggr.1...n 
4productcodeString, max 50 0...1Product code 340
4productnameString, max 2001Name of the product Test Product
4orderedamountNumeric 0...1Amount ordered 12
4deliveredamountNumeric 1Amount delivered 12
4unitnameString0...1Unit of measurement 
4unitpriceNumeric 1Price of a single unit with tax 3,81
4discountpercentageNumeric 0...1Discount percentage 1,52
4vatpercentNumeric1VAT percentage 24
4linesumNumeric 1Total of the line, this will be approximated to 2 decimals45,72
Attr.typeString1Type of sum, default is brutto (gross)brutto
4descriptionString, max 200 0...1Description text
4sortNumeric 0...1 
4accountingsuggestionNumeric 0...1If not given, default from company's default accounts will be used (based on vendor's country code)4000
4dimensionAggr.0...n 
5dimensionnameString, max 501Dimension header
Project
5dimensionitemString, max 2001Dimension name 8890
2purchaseinvoicecommentlinesAggr.0...1 
3purchaseinvoicecommentlineAggr.1...n 
4commentString1Comment text 
4sortString0...1 
2purchaseinvoiceattachmentsAggr.0...1

 


3purchaseinvoiceattachmentAggr.1...nOnly PDF-format supported. Attachmnet is handled as a picture of the invoice. 
4mimetypeString1MIME-type of the attachment
4attachmentdescriptionString1Description of the attachment Max 100 character
4filenameString1The name of attached file
4documentdataString1In Base64 format
Attr.documenttypeString0...1Type of the document. invoiceimage or otherattachment. Default is invoiceimage. invoiceimage


Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.