Workflows & Automation
XBuddy’s Automation module is the nerve center of your business operations — combining two distinct but complementary systems: Workflow Automation (rule-based approval chains and policies) and the AI Proactive Layer (intelligent agents that monitor, analyze, and act across all modules).
Navigate to Automation in the main nav to access: Workflow Builder, AI Scenarios, AI Feed, AI Suggestions, AI Insights, and Agent Settings.
Two Pillars
| Pillar | What it is | Best for |
|---|---|---|
| Workflow Automation | Rule-based triggers, approval chains, delegation, and auto-policies | Structured approval flows with human sign-off requirements |
| AI Proactive Layer | 210+ agents that observe data, surface findings, and act on your behalf | Continuous monitoring, anomaly detection, recommendations |
AI Proactive Layer
The Proactive Layer surfaces AI intelligence across four views under Automation:
Scenarios
Pre-built playbooks that bundle 2–5 agents tuned for a specific business situation. Enable a scenario to activate all its agents with recommended autonomy defaults.
Example scenarios:
- Cash Flow Crunch — activates Cash Flow Forecaster, AR Aging Intelligence, Dunning Effectiveness Monitor
- Payroll Risk — activates Payroll Readiness Checker, BHXH Reconciliation, PIT Compliance Checker
- Deal Pipeline Health — activates Deal Coach, Lead Scorer, Quote Followup Agent
How to enable: Automation → Scenarios → toggle ON → optionally customize individual agent autonomy.
AI Feed
Real-time stream of all agent activity: what ran, what was found, what was acted on. Filter by domain, agent, date range, or status.
- Green = action created / executed
- Amber = alert or warning issued
- Blue = record updated
- Grey = skipped (no findings)
Suggestions
The pending approval queue for AI recommendations. Populated when agents run in Notify or Semi-auto mode.
Each suggestion card includes:
- Agent name and the record it analyzed
- Recommended action (with reasoning)
- Confidence score
- Approve / Dismiss / Snooze buttons
Supports bulk approve/dismiss for high-volume queues.
Insights
Weekly cross-domain executive summary generated automatically (or on demand). Combines findings from Finance, Sales, HR, and Operations agents into a narrative with charts. Exportable as PDF.
Workflow Automation
Key Features
- Visual Workflow Builder — drag-and-drop steps: approval, parallel approval, AI decision, condition branch, auto-action, and notify-only
- 28+ pre-built approval templates — covering Finance, Procurement, HR, CRM, Manufacturing, Quality, OKR, and more
- Automation Policies — JSONLogic-based rules that auto-approve, auto-reject, or route requests to AI without human intervention
- Delegation Management — 25 system delegation templates; rules activate automatically based on date ranges and subject type
- Escalation Engine — SLA-based escalation to skip-level manager if approver does not act within configured time
- Parallel & Serial Chains — mix serial (A → B → C) and parallel (A AND B must approve) steps in one workflow
- AI Decision Step — route to AI scoring engine; auto-decide based on score threshold
- Complete Audit Trail — every approval, rejection, delegation, and escalation event timestamped and immutable
- Mobile-friendly — approve, reject, or request changes from any device via push notification
[Screenshot: Workflows — Visual Workflow Builder]
Placeholder — will be replaced with actual screenshot
[Video: Workflows — Building Approval Flows in XBuddy]
Watch on YouTube → @XBuddy (placeholder)
Getting Started
- Go to Automation → Workflow Builder and click New Workflow
- Choose a pre-built template or start from scratch
- Configure the Trigger — which entity and event starts the workflow (e.g., “Invoice submitted for approval”)
- Add Steps — approvers, conditions, or automatic actions
- Set SLA & Escalation rules for each approval step
- Activate the workflow and test it with a sample record from any module
Workflow Step Types
| Step Type | Description | Use When |
|---|---|---|
| Approval | Single approver must decide | Standard one-person sign-off |
| Parallel Approval | Multiple approvers simultaneously; all must approve | Board sign-off, dual control |
| Condition | Branch based on record values (JSONLogic) | Route by amount, department, or risk score |
| AI Decision | AI scores the request and decides based on threshold | High-volume, low-risk routing |
| Auto Action | Executes automatically — update field, send email, create task | Post-approval side effects |
| Notify Only | Informs recipients without blocking the workflow | FYI notifications, CC chains |
Approval Templates
XBuddy ships with 28+ pre-configured approval templates organized by domain:
Finance & Procurement
| Template | Steps | Trigger |
|---|---|---|
| Invoice Approval | Finance Manager → CFO (>$10K) | Invoice submitted |
| Budget Approval | Dept Head → Finance → CFO | Budget request |
| CapEx Approval | Manager → Finance → CEO | Capital expenditure |
| Credit Note Approval | Finance Manager | Credit note created |
| Purchase Order Approval | Dept Head → Procurement | PO submitted |
| Vendor Payment Approval | Finance Manager | Payment batch |
| RFQ Approval | Procurement Manager | RFQ submitted |
| Vendor Onboarding | Procurement → Legal | New vendor |
HR & People
| Template | Steps | Trigger |
|---|---|---|
| Recruitment Requisition | HR Manager → Dept Head | Job opening |
| Salary Adjustment | HR Director → CEO | Salary change |
| Promotion Approval | Manager → HR Director | Promotion request |
| Termination Approval | HR Director → Legal | Termination |
| Overtime Request | Direct Manager | Overtime submitted |
| Leave Approval | Direct Manager | Leave request |
| Payroll Run | Finance Manager | Payroll finalized |
Operations & Compliance
| Template | Steps | Trigger |
|---|---|---|
| Project Budget | Project Manager → Finance | Budget request |
| Contract Approval | Account Manager → Legal → Executive | Contract |
| Asset Purchase | Finance Manager | Asset request |
| Asset Disposal | Asset Manager → Finance | Disposal request |
| Inventory Write-off | Warehouse → Finance | Stock write-off |
| Quality CAPA | Quality Manager | CAPA initiated |
| Waiver/Deviation | QA Director | Waiver request |
CRM & Sales
| Template | Steps | Trigger |
|---|---|---|
| Quote Approval | Sales Manager | Quote submitted |
| Large Sales Order | Finance → Sales Director | Order >threshold |
| Contact Data Validation | Data Steward | New contact |
OKR & Performance
| Template | Steps | Trigger |
|---|---|---|
| Objective Approval | Manager | OKR submitted |
| IDP Approval | Manager | Development plan |
| PIP Approval | HR Director | Performance plan |
Escalation Rules
Every approval step can have an SLA with automatic escalation:
- Notify — approver gets in-app + email notification immediately
- Reminder — configurable reminder (e.g., 12 hours before SLA breach)
- Escalate — if SLA breached (default: 24 hours), route to skip-level manager
- Hard Escalation — if still unresolved (e.g., 72 hours), flag to admin and block entity
Configure SLA per step in the workflow builder under Step Settings → SLA & Escalation.
Delegation Rules & Templates
Delegation automatically routes approval requests to a delegate when the primary approver is unavailable.
How Delegation Works
- Admin or manager creates a Delegation Rule specifying: delegator, delegate, validity period, and which subject types or specific workflows apply
- When a workflow reaches an approval step, the engine checks if the approver has an active delegation
- If matched, the request routes to the delegate automatically — the delegator is notified
- Delegation is time-bounded and expires automatically
System Delegation Templates (25 templates)
XBuddy ships with delegation templates for common scenarios:
| Category | Examples |
|---|---|
| Absence | Annual Leave Coverage (14 days), Sick Leave Emergency, Public Holiday Coverage |
| Travel | Business Travel (7 days), International Conference, Field Visit |
| Emergency | Medical Emergency, Personal Emergency (open-ended) |
| Finance Domain | Finance Manager Absence, CFO Delegation, AP/AR Coverage |
| HR Domain | HR Manager Absence, Recruitment Delegation |
| CRM Domain | Account Manager Travel, Sales Director Coverage |
| Operations Domain | Operations Manager Absence, Warehouse Manager Coverage |
To activate a template, go to Automation → Delegation and click Use Template.
Automation Policies
Automation Policies eliminate repetitive approvals by automatically handling routine requests based on configurable conditions.
Policy Actions
| Action | Description | Example |
|---|---|---|
| Auto-Approve | Approve instantly without human intervention | Expense < 500,000 VND by trusted employee |
| Auto-Reject | Reject immediately based on violation | Request from blacklisted vendor |
| Route to AI | Send to AI decision engine for scoring | High-value invoice from new supplier |
| Notify Only | Skip approval, just notify | Informational FYI for small purchases |
| Escalate | Jump directly to senior approver | Budget overrun >20% |
Setting Up a Policy
- Go to Automation → Policies and click New Policy
- Select the Subject Type (e.g., Expense Claim, Invoice)
- Define Conditions using the visual rule builder (amount, vendor, department, etc.)
- Choose the Action (auto-approve, auto-reject, route-to-AI, etc.)
- Set Priority — lower number = evaluated first; first match wins
- Activate the policy
Policies are evaluated before any human approval step. If a policy matches, the workflow acts accordingly and logs the decision for audit.
Conditional Branching Example: Invoice Approval
TRIGGER: Invoice submitted for approval
│
├─ POLICY CHECK (evaluated first)
│ ├─ IF vendor is blacklisted → AUTO-REJECT
│ └─ IF amount < 1M VND AND trusted vendor → AUTO-APPROVE
│
└─ WORKFLOW STEPS (if no policy matched)
├─ IF amount ≤ 5M VND
│ └─ Department Manager → approve/reject
├─ IF amount 5M–20M VND
│ └─ Finance Manager → approve/reject
└─ IF amount > 20M VND
└─ Finance Manager → CFO (serial chain)
└─ If CFO absent → AI Decision EngineIntegration Points
Every module in XBuddy can plug into Workflows:
- Finance — Invoice, expense claim, bill, credit note, and payment approval
- Procurement — Purchase request, RFQ, PO, and vendor onboarding approval
- HR — Leave, overtime, recruitment, promotion, salary adjustment, and termination
- CRM — Quote approval and large sales order review
- Manufacturing — Work order release and rework authorization
- Quality — NCR approval, CAPA sign-off, deviation waiver
- OKR & Performance — Objective, IDP, and PIP approval
- Knowledge — Article publication approval
FAQ
Q: Can I mix serial and parallel approval steps?
A: Yes. Build a workflow where steps A and B run in parallel, then require C to approve once both A and B have decided. Fully configurable in the builder.
Q: What happens if an approver is on leave?
A: Set up a Delegation Rule before they leave. The system will automatically route to the delegate for the configured validity period. Use a delegation template for common scenarios like annual leave.
Q: Can policies and workflows run together?
A: Policies are evaluated first. If a policy matches (e.g., auto-approve), the workflow skips human steps. If no policy matches, the workflow runs normally.
Q: How do I see all pending approvals across modules?
A: Go to Automation → My Tasks to see all pending approval requests assigned to you, across every module, in one view.
Q: Can I add a comment or annotation when approving?
A: Yes. Every approval action includes an optional comment field. Comments are stored in the audit trail and visible to subsequent approvers and the initiator.
Q: How long are audit logs kept?
A: Permanently. Every approval event, delegation activation, policy match, and escalation is timestamped and immutable. You can export the full audit trail as CSV.
Q: Can I test a workflow without affecting real data?
A: Yes. Use the Test Mode in the workflow builder to run a simulated approval with a test record. Results show which steps would trigger without creating actual approvals.