Webinar: Automating Your Simpro AP with EzzyBills – Recording

Skip to main content

EzzyBills User Guide

03. Guide: Setting Up Per-Line Approval Workflow Using AI Tasks

This guide walks through the process of creating a customized per-line approval process using AI tasks in the EzzyBills platform. The setup requires two workflows:

  1. Main Workflow – Handles data extraction, routes designated approval workflows per line items and bill export.
  2. Specific Approver Workflows – Handles specific approval workflow

I. Main Workflow Configuration

This will be the primary workflow, managing the overall document flow.

The screenshot below shows a typical Main workflow for a Xero user that requires line-level approval. Please set it up according to the step-by-step instructions below.

In the screenshot below, you will see

  • two tasks “Submit Approval 1” and “Approved 1”, which is for you team to assign or view invoice data, such as job, supplier, or account code.
  • Below them is the task “Set approver for each line …”, which is an AI task – there is a global task for it – but you may want to create a new similar to this, but including your special approver logics.
  • The task “Switch here” is to switch a specific approver’s workflow.
  • The task “Approve each of the invoice” is a global task that will control the approver switch.

Step I.1: Start a new main workflow

  • Navigate to the Workflows.
  • Duplicate the existing “active” workflow (such as a XeroBills workflow)

Step I.2: Create a new AI task to add logics on how to set approvers

There is an existing global AI task that is for testing purpose, which is “set approver on each line for account code 300 only.

You will need to create a new one to meet your requirement.
sample specific use case: https://www.ezzybills.com/user-guide/guide-line-item-approval-specific-use-case/

To add these tasks:

  • Go to the Automation (AI) section.
  • Click the ‘AI Task’ tab.
  • Provide a Task Name and a Description of what the AI should do.

In here, you will need to read the list of values from a CSV file that has already been uploaded to EzzyBills to determine approvers.

Step I.3: Add additional tasks to the main workflow

  • Add two tasks for level-1 approval
  • Add the existing test AI Task ID #104414 (Set approver based on account code), or your AI task that you have created in Step 2.
  • Add “Switch here”
  • Add AI Task ID #104416. This task is to switch to specific approver’s workflow.

II. Configuring Specific Approvers’ Workflows

Step II.1: Create a workflow for the first approver.

In this example, we set up workflows for Mike and Fred. But set up only one of them first, and then duplicate this and set up the 2nd one.

Step II.2: Add tasks for the approver’s workflow.

Each workflow will contain the following tasks,

Step II.2: Configure Workflow Switch

  • For the task “Submit Approval1”, edit the setting to set a default approver.
  • For the AI task for line-level approval, “Approve My Approval Lines”, you do not need to set up any setting.
  • For the task Switch Workflow [390], use the setting below to switch to the main workflow.

Below is the JSON text example, where “approve_per_line-customer" is the main workflow name. If your main workflow has a different name, replace this text string with yours.

{
  "state": 390,
  "keywords": [
    {
      "name": "changeWorkflow",
      "value": "approve_per_line-customer"
    }
  ]
}

III. Final Steps

Once configuration is complete:

  • Upload a test document to validate the workflow.
  • Review the processing logs to confirm expected behavior.
Sections of Article