Organizations use Pyrus forms for the approval of invoices, price lists, and other documents. If Pyrus data needs to be used in accounting software or an ERP system, use the registry export function. The registry is saved as a CSV file, which can be used with other programs.
Suppose you want to send the information on all payments to your accounting program. Select the form you need from the Forms List in Pyrus Sync. In this example, we’d use an AP Invoice.
Pyrus Tip: Only form Administrator can set up a form export. Ask one of the existing form administrators to give you privileges if you can’t find the form you require in the list.
On the right side of the screen, go to the Export section and run the download by clicking New Export. In the window that opens, click CSV File.
A window with standard JSON export settings will open. They correspond to a single export of the requests list, with all the fields. To save settings, click Save. To run the registry export, click Run Now.
The file will be saved in the Documents folder on the hard drive of your computer.
Suppose you want to export approved expenses every day at 12:15. Add this parameter to the configuration settings. In the Export Settings Section, add {ScheduledTime: “12:15”}. The quotation marks here specify the export time.
{ "Name": "AP Invoice Export", "Path": "C:\\Users\\bruce\\Documents", "Delimiter": ";", "ExportSettings":{ "ScheduledTime": "12:15" } }
If the export has to be carried out at regular intervals, such as every hour and a half, it can be similarly configured. In the Export Settings Section, add {ScheduledPeriod:}. The number after the colon is the time, in minutes, that passes between exports.
{ "Name": "AP Invoice Export", "Path": "C:\\Users\\bruce\\Documents", "Delimiter": ";", "ExportSettings":{ "ScheduledPeriod":90 } }
Sometimes only part of the information contained in a Pyrus form needs to be sent to an accounting program or other system, say, just the data on approved invoices or contracts. In this case, your registry export can be customized.
As an example, let's export a list of invoices that have already been approved (that is, they have been forwarded to the to the accounting department at the third stage) and are ready to be paid. In this case, we do not need to export all of the form’s fields. We only need the contractor's name, bank routing number, account number, and payment amount. After the export is completed, the invoices will be automatically archived in Pyrus.
Let's change the default export settings. To open the configuration window, click the gear icon in the export line.
Add the step number to your parameters (“StepNo”: 3) and set the rule to move on to the next step after export (“ApproveAfterExport”: true).
{ "Name": "AP Invoice Export", "Path": "C:\\Users\\bruce\\Documents", "Delimiter": ";", "StepNo": 3, "ApproveAfterExport": true, "ExportSettings": {} }
Now, define the conditions. We only need requests where the value in the Payment Type field is Wire Transfer. If this condition is not met, the request will not be exported. Let’s add “ColumnMap”: [] to the end, and also remove unnecessary fields from the exports file, leaving only the contractor’s name, their TIN, bank account number, and payment amount.
{ "Name": "AP Invoice Export", "Path": "C:\\Users\\bruce\\Documents", "Delimiter": ";", "StepNo": 3, "ApproveAfterExport": true, "ExportSettings": { "ExportRules": [ { "Conditions": [ { "PyrusField": "Inventory", "Values": [ "Inventory" ] } ], "ColumnMap": [] }, { "Conditions": [ { "PyrusField": "Payment Type", "Values": [ "Wire Transfer" ] } ], "ColumnMap": [ { "CsvColumn": "Amount, USD", "PyrusField": "Amount, USD" }, { "CsvColumn": "Contractor (new)", "PyrusField": "Contractor (new)" }, { "CsvColumn": "TIN", "PyrusField": "TIN" }, { "CsvColumn": "Bank Account No.", "PyrusField": "Bank Account No." }, { "CsvColumn": "Price", "PyrusField": "Price" } ] }, { "ColumnMap": [] } ] } }
Save the parameters. Now you can start exporting the registry.
Pyrus Sync data export is configured in JSON, a text format for storing and transfering structured data.
There are several rules and conditions that apply to export settings.
The following parameters can be used to configure export settings:
"Name": "AP Invoice Export",
"Path": "C:\\pyrus",
"Delimiter": ";",
"Encoding": "utf-8",
"ShowUserIds": [123183, 123193],
You can see a user's ID in the address bar on his or her profile page.
Setting export rules in the ExportSettings section:
Setting the conditions for processing and exporting tasks with ExportRules:
If you want to export only the tasks matching certain criteria, say, to run different types of exports for different types of tasks, then this section will be invaluable. Every rule (ExportRules) has two mandatory elements: a list of conditions (Conditions) and display rules (ColumnMap). If the form has a Table type field, export rules will be first applied to a task with such a field as a whole, and then to each row in the table.
Conditions element
ColumnMap element: Here you specify the list of columns to be included in the export file. You can also customize which Pyrus field writes data to which column of the CSV file. If this section is present, the list should contain at least one element. It is important to remember that the last element of the list should be ColumnMap[]. Otherwise, the export file will not include all necessary data.