Smart Actions by Lodol
API actions for the Smart Actions by Lodol integration.
Smart Actions by Lodol
Perform intelligent actions like validation and extraction using Lodol's built-in Smart Actions.
Classify an expense transaction.
Classifies an expense into a primary category and optional sub-category from your provided list, and flags uncertain or miscellaneous classifications for review.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
transaction_data | object | Yes | Transaction object with date, amount, currency, merchant, and description. |
category_list | array | Yes | List of valid classification categories / GL codes. Include 'Miscellaneous' in this list if you want that category to be available. |
Response
{
"explanation": "Classified as travel based on flight-related merchant and description.",
"primary_category": "Travel",
"requires_review": false,
"sub_category": "Airfare"
}Extract specified fields from a document.
This action extracts specified fields from a document and stores them for further use. It allows you to specify which fields to extract based on their names.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
filepath | string | Yes | Upload the source document or enter a URL. |
fields | array | Yes | List of field names to extract |
Response
{
"fields": [
{}
]
}Extract and validate an invoice.
This action extracts key invoice fields, determines a GL code, validates line-item and overall totals, and returns structured invoice data with validation errors.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
file | string | Yes | Upload an invoice or enter a URL. |
Response
{
"currency": "USD",
"due_date": "2025-01-31",
"gl_code": "Software Subscription",
"invoice_date": "2025-01-01",
"invoice_number": "INV-1001",
"line_items": [
{
"description": "Software subscription",
"quantity": 1,
"total": 99.0,
"unit_price": 99.0
}
],
"requires_review": false,
"subtotal": 99.0,
"tax": 0.0,
"total": 99.0,
"validation_errors": [],
"vendor_name": "Example Vendor"
}Check ICP qualification.
Check if a lead matches the Ideal Customer Profile. Returns a qualification decision with a score and reason.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
company | string | Yes | Company name to evaluate. |
email | string | No | Contact email (optional context). |
name | string | No | Contact name (optional context). |
Response
{
"company": "Acme Corp",
"email": "jane@example.com",
"is_qualified": true,
"name": "Jane Doe",
"reason": "Company matches target profile criteria.",
"score": 85
}Reconcile invoice(s) against a purchase order.
This action extracts fields from one or more invoices and compares them against a purchase order to identify compliance discrepancies.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
invoice_files | array | Yes | Upload invoices or enter URLs. |
purchase_order | array | Yes | Purchase order line items. Each item has a description, quantity, and unit_price. |
total | number | Yes | Total amount for the purchase order. |
Response
{
"discrepancies": [],
"requires_review": false
}Validate a receipt for reimbursement.
This action extracts receipt fields and validates policy compliance against transaction data, category policies, duplicate submissions, and submission timing limits.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
receipt_file | string | Yes | Upload a receipt or enter a URL. |
transaction | object | No | Optional transaction context with date, amount, currency, merchant, and category. |
require_itemization | boolean | No | Whether itemized line items are required (default true). |
category_policies | object | No | Optional category policy map. Each category can specify max_days_after_transaction (maximum days allowed between transaction and submission) and spending_limit (maximum receipt amount for that category). |
fallback_max_days_after_transaction | number | No | Fallback max days allowed after transaction (default 30). |
fallback_spending_limit | number | No | Fallback spending limit when category policy is missing (default 500). |
Response
{
"currency": "USD",
"merchant_name": "mock_value",
"policy_compliant": true,
"policy_violations": [],
"total_amount": 42.0,
"transaction_date": "2025-01-01"
}Validate a resume against job requirements.
This action validates a resume to ensure it meets provided job requirements.
Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
filepath | string | Yes | Upload a resume PDF or enter a URL. |
requirements | string | Yes | The job requirements to validate against |
Response
{}