Resource: accountingedit.nv

HTTP-method: POST

Accounting edit can be used for editing existing voucher, voucher lines, voucher line dimensions and voucher attachments. The request doesn't have parameters. One request can include only one voucher. Accounting edit can be used for editing voucher's basic info and voucher lines. Basic info is not compulsory if only voucher lines are being edited. Accounting edit invalidates existing voucher lines and imports requests voucher lines as new voucher lines. If voucher lines are not imported in the request, no changes are made to the existing vouher lines.

The data to be imported must be included in the request as an XML with the following structure:

LevelElement nameType and lengthOccursDescriptionExample
RootrootAggr.1  
1voucherAggr.1

2netvisorkeyNumeric1Netvisor key of the voucher being edited. Netvisor key can be retreived with the resource accountingledger.nv123
2calculationmodeString0...1Calculation mode for the voucher. Net (vat lines are not calculated automatically) or gross (vat lines are calculated automatically).gross
2voucherdateDate0...1Voucher date2009-1-1
Attr.formatString1Date format, always ansiandi
2numberNumeric, max. 90...1Voucher number. If not given, the system automatically picks next number from the chosen voucher class1
2descriptionString, max. 2550...1Voucher descriptionDescription
2voucherclassString0...1Voucher class. See possible voucher classes above. It is also possible to create own voucher classes.Myyntilasku
2voucherlineAggr.0...n

3linesumNumeric1Line sum. Negative value is recorded to credit side and positive value on debet side. Two decimal maximum.
-100,00
Attr.typeString0...1net or grossnet
3descriptionString, max. 2550...1Voucher line descriptionDescription
3accountnumberNumeric1Accounting account number, must be found or an error is returned.3000
3vatpercentNumeric1Vat percent. Must not be in conflict with vatcode attribute.
24
Attr.vatcodeString0...1VAT code. If not given, value behind account number is used. Valid values are listed here
KOMY
3accountdimensionString0...1Voucher line's follow-up object.Seurantakohde 1
Attr.typeString1name or netvisorkey (shown only in Netvisor)name
3dimensionAggr.0...1

4dimensionnameString, max. 501Dimension name. If dimension is not found from system, it is created.Project
4dimensionitemString, max. 2001Dimension item. If item in dimension is not found from system, it is created.Project x
2voucherattachmentsAggr.0...1

3voucherattachmentAggr.1...n

4mimetypeString1MIME-type of the attachmentapplication/pdf
4attachmentdescriptionString1Description text for the attachmentExample attachment
4filenameString1File name of the attachmentAttachment.pdf
4documentdataString1Data of the attachment as base64 encoded string


Did you find it helpful? Yes No

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