How do I integrate with external systems like ERP, CRM, or accounting software?

Learn how to integrate %%APP_NAME%% with your external systems using formula fields

Integration Overview

Yes! 1Flow can integrate with your external systems—including ERP, CRM, accounting software, and databases—through Formula Fields using TxScript. This enables real-time data synchronization and validation during document extraction.

How It Works

Formula fields use HTTP requests to communicate with external systems. When documents are processed, you can:

  • Retrieve data from your ERP, CRM, or accounting systems to enrich extracted fields
  • Send data to external systems for validation, synchronization, or record creation
  • Query databases via REST APIs for reference data or validation rules
  • Validate information against external sources in real-time

Implementation

Integration is done using the tx.http.request() method in formula fields. This provides secure, rate-limited HTTP calls to your external systems with built-in error handling and authentication support.

Example: ERP Product Lookup

// Lookup product information from ERP system
const sku = tx.getCurrentLineItem()?.sku;

if (sku) {
  const response = await tx.http.request({
    url: "https://your-erp-system.com/api/products",
    method: "GET",
    headers: {
      "Authorization": "Bearer YOUR_API_TOKEN"
    },
    body: { sku: sku }
  });

  if (response.ok && response.body) {
    tx.setCurrentLineField("description", response.body.name);
    tx.setCurrentLineField("price", response.body.price);
  }
}

Supported Systems

You can integrate with any system that provides a REST API:

  • ERP Systems: SAP, Oracle, NetSuite, Microsoft Dynamics, etc.
  • CRM Systems: Salesforce, HubSpot, Zoho, etc.
  • Accounting Software: QuickBooks, Xero, Sage, etc.
  • Databases: Any database with a REST API wrapper
  • Custom APIs: Your own internal APIs and microservices

Security & Limits

  • Rate limits: Maximum 10 HTTP calls per formula field execution
  • Timeout: 5 seconds per HTTP request (configurable)
  • Authentication: Support for API keys, bearer tokens, and custom headers
  • Audit: All external API calls are logged for compliance

Getting Started

  1. Set up API credentials in your organization settings
  2. Create formula fields using TxScript in your document type schemas
  3. Use tx.http.request() to communicate with your external systems
  4. Test and validate the integration with sample documents

Learn More