This resource provides a number of methods used to get Purchase invoices and to update Purchase invoices in Fivaldi. With these methods it is possible to modify invoice row data and to approve Purchase invoices in the Fivaldi Purchase invoice handling (ostolaskujen kierrätys)

GET /purchases/invoices

This method is used to retrieve all Purchase invoices matching the query parameters.

It is recommended to design the integration logic so that only relevant invoices are retrieved using creation time (createTimeAfter, createTimeBefore) or change time (changeTimeAfter, changeTimeBefore) to filter out results that have already been retrieved earlier.

If you also want to see the invoices where changes have been made only on Purchase invoice rows, you can use the fetchAllChangeTimes or includeRowChangeTimes parameter in the filter. fetchAllChangeTimes gives you changed invoices regardless on which invoice information has changed.  includeRowChangeTimes gives you invoices where information has changed on the Purchase invoice rows. 

Attachment IDs should be included in the search only if they are needed for the integration, as it will increase the query time. Attached files can be retrieved separately using GET /archive/files/{fileId}.

Required access level for Partner account: Ostolaskut - käyttö

OpenAPI documentation

POST /purchases/invoices/

This method is used to create a new purchase invoice. The purchase invoice will be set to “Syötössä” status. If a valid supplierId was also specified, the supplier’s information will automatically be retrieved and added to the purchase invoice.

Required access level for Partner account: Ostolaskut - Lisäys

OpenAPI documentation

GET /purchases/invoices/{invoiceId}

This method is used to retrieve one Purchase invoice. Attached files can be retrieved separately using GET /archive/files/{fileId}.

Required access level for Partner account: Ostolaskut - käyttö

OpenAPI documentation

PUT /purchases/invoices/{invoiceId}

This method is used to update all information on an existing Purchase invoice in Fivaldi.

Missing properties or null values will delete the existing data in Fivaldi.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

PATCH /purchases/invoices/{invoiceId}

This method is used to update some information on an existing Purchase invoice in Fivaldi.

Missing properties or null values will be ignored so the existing data in Fivaldi will not be altered.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

POST /purchases/invoices/{invoiceId}/approve

This method is used to approve the current step of Purchase invoice in the Purchase invoice handling process (Ostolaskujen kierrätys).

StepID must match the current step of the invoice. InvoiceID and stepID can be retrieved with methods GET /companies/{cuid}/purchases/invoices or GET /companies/{cuid}/purchases/invoices/{invoiceId}

The Partner account user is displayed as the approver in Fivaldi Purchase invoice handling log. As purchase invoice approval is a critical financial process, it is recommended to build a detailed and transparent audit trail log in the integrated system to verify the approval actions.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

POST /purchases/invoices/{invoiceId}/attachment

This method is used to add a file as an attachment to a specific existing purchase invoice that has the “Syötössä” status. The file has to comply with filename, filetype and file size restrictions specified in the OpenAPI documentation. Attachments can be viewed in the Purchase Invoice Circulation application in the purchase invoice’s detail view after they have been successfully added.

Required access level for Partner account: Ostolaskut - lisäys, Arkisto - lisäys

OpenAPI documentation

GET /purchases/invoices/{invoiceId}/comments

This method is used to retrieve all comments that have been made to a specific purchase invoice. Comments can be made in the Fivaldi Purchase Invoice Circulation -application or via POST method for this endpoint.

Required access level for Partner account: Ostolaskut - käyttö

OpenAPI documentation

POST /purchases/invoices/{invoiceId}/comments

This method is used to add comments for a specific purchase invoice. Comments can be read in the Fivaldi Purchase Invoice Circulation -application.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

GET /purchases/invoices/{invoiceId}/rows

This method is used to retrieve all rows of a Purchase invoice.

Required access level for Partner account: Ostolaskut - käyttö

OpenAPI documentation

POST /purchases/invoices/{invoiceId}/rows

This method is used to create a Purchase invoice row to an existing Purchase invoice.

The row object data model is described in the OpenAPI documentation. A created purchase invoice row is added as the last row on the invoice.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

GET /purchases/invoices/{invoiceId}/rows/{rowId}

This method is used to retrieve one invoice row on a Purchase invoice.

Required access level for Partner account: Ostolaskut - käyttö

OpenAPI documentation

PUT /purchases/invoices/{invoiceId}/rows/{rowId}

This method is used to update all information on an existing Purchase invoice row in Fivaldi.

Missing properties or null values will delete the existing data in Fivaldi.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

PATCH /purchases/invoices/{invoiceId}/rows/{rowId}

This method is used to update some information on an existing Purchase invoice row in Fivaldi.

Missing properties or null values will be ignored so the existing data in Fivaldi will not be altered.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

DELETE /purchases/invoices/{invoiceId}/rows/{rowId}

This method is used to delete a Purchase invoice row in Fivaldi.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

POST /purchases/invoices/{invoiceId}/rows/accrualData

This method is used to set accrual settings (jaksotus) for a Purchase invoice row.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

PUT /purchases/invoices/{invoiceId}/rows/{rowId}/accrualData/{accrualNumber}

This method is used to update all information on an existing Purchase invoice row accrual setting in Fivaldi.

Missing properties or null values will delete the existing data in Fivaldi.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

PATCH /purchases/invoices/{invoiceId}/rows/{rowId}/accrualData/{accrualNumber}

This method is used to update some information on an existing Purchase invoice row accrual setting in Fivaldi.

Missing properties or null values will be ignored so the existing data in Fivaldi will not be altered.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation

DELETE /purchases/invoices/{invoiceId}/rows/{rowId}/accrualData/{accrualNumber}

This method is used to delete a Purchase invoice row accrual setting in Fivaldi.

Required access level for Partner account: Ostolaskut - lisäys

OpenAPI documentation



Oliko tästä vastauksesta apua? Kyllä Ei

Send feedback
Pahoittelut, että emme voineet auttaa. Anna palautetta, jotta voimme parantaa tätä artikkelia.