The basic level of the integration is:
- Chart of Accounts - API reference 'Product Custom Fields'
- Documents: Purchase Orders or Invoices and Payments
More robust integration level:
- Departments - API reference 'Document Custom Fields'
- Classes - API reference 'Document Custom Fields'
- Projects - API reference 'Document Custom Fields'
- Products - API reference 'Products'
Fields Chart of Accounts, Departments, Classes, Projects could be set on the document and item levels. Please, note, you have to set up fields in the Precoro account in accordance with your accounting system.
To set up the Document-level field, use Document Custom Fields, and the item-level field use Product Custom Field.
Document Custom Fields are described in the Purchase Orders/Invoices on two levels:
- values - 'dataDocumentCustomfields'
- references to the appropriate field in Precoro - 'documentCustomfield'
'dataDocumentCustomfields' contains the data about all of the Document Custom Fileds values (e.g., assigned values of the Departments, Projects).
'documentCustomfield' contains the Document Custom Filed ID, where you can get the corresponding name and available options.