> For the complete documentation index, see [llms.txt](https://integrate.lexamica.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://integrate.lexamica.com/readme.md).

# Lexamica Integration API Documentation

Build integrations that connect your systems with Lexamica's case management and referral platform.

***

## 🎯 What You Can Do

The Lexamica Integration API enables you to:

* **Send cases** from your CRM, intake forms, or case management system
* **Receive cases** when other firms refer work to you
* **Track case lifecycle** with real-time updates on relay matching, invitations, and status changes
* **Sync bidirectionally** between your systems and Lexamica
* **Manage files** by uploading and downloading case documents

***

## 📚 Documentation Overview

### Start Here

| Doc                                                                         | Description                                                        |
| --------------------------------------------------------------------------- | ------------------------------------------------------------------ |
| [Organizations and Authentication](/1.-organizations-and-authentication.md) | Get your API keys and understand the two-tier authentication model |
| [Mapping Engine](/2.-mapping-engine.md)                                     | Configure how your field names translate to Lexamica's fields      |
| [OpenAPI Spec (Redoc)](https://integration.lexamica.com/)                   | Ingest the OpenAPI spec directly                                   |

### Core Capabilities

| Doc                                                       | Description                                                |
| --------------------------------------------------------- | ---------------------------------------------------------- |
| [Inbound Webhooks](/3.-inbound-webhooks.md)               | Send data to Lexamica (cases, invitations, updates, files) |
| [Webhook Subscriptions](/4.-webhook-subscriptions.md)     | Receive real-time event notifications from Lexamica        |
| [Event Storage and Polling](/5.-event-storage-polling.md) | Poll for events when webhooks aren't an option             |
| [Enrichment Endpoints](/6.-enrichment-endpoints.md)       | Look up case types and law firms to build dynamic pickers  |

### Integration Examples

Step-by-step guides for common integration patterns:

| Guide                                                                                              | Use Case                                  |
| -------------------------------------------------------------------------------------------------- | ----------------------------------------- |
| [Integration Examples](/example-integrations.md)                                                   | Find the right guide for your integration |
| [Lead Form Submission](/example-integrations/1.-lead-form-submission.md)                           | Send cases from a web form (simplest)     |
| [Receive Cases via Webhook](/example-integrations/2a.-receive-cases-webhook.md)                    | Get notified when cases arrive            |
| [Receive Cases via Polling](/example-integrations/2b.-receive-cases-polling.md)                    | Poll for incoming cases                   |
| [Originator: Full Integration with Webhooks](/example-integrations/3a.-originator-full-webhook.md) | Send cases + receive all updates          |
| [Originator: Full Integration with Polling](/example-integrations/3b.-originator-full-polling.md)  | Send cases + poll for updates             |
| [Import Existing Cases with Webhooks](/example-integrations/5a.-import-existing-webhook.md)        | Import cases with known handlers          |
| [Import Existing Cases with Polling](/example-integrations/5b.-import-existing-polling.md)         | Import cases + poll for updates           |
| [Handler Firm: Full Integration with Webhooks](/example-integrations/4a.-handler-firm-webhook.md)  | Receive invitations + respond via API     |
| [Handler Firm: Full Integration with Polling](/example-integrations/4b.-handler-firm-polling.md)   | Receive invitations via polling           |
| [File Operations](/example-integrations/apx-1.-file-operations.md)                                 | Upload, download, and manage files        |
| [Dynamic Pickers with Enrichment Endpoints](/example-integrations/apx-2.-enrichment-pickers.md)    | Build live case-type & law-firm pickers   |

***

## 🚀 Quick Start

### 1. Get Your Credentials

Contact Lexamica to receive:

* **Organization ID** — identifies your firm
* **Public Key** — for sending data to Lexamica
* **Private Key** — for configuration and management operations

### 2. Choose Your Integration Pattern

```
Are you SENDING cases to other firms?
│
├─► YES: You're an ORIGINATOR
│   └─► Start with: Lead Form Submission or Originator guides
│
└─► NO: You're a HANDLER (receiving cases)
    └─► Start with: Receive Cases or Handler Firm guides
```

### 3. Read the Foundational Docs

Before diving into examples, understand the building blocks:

1. [Organizations and Authentication](/1.-organizations-and-authentication.md) — How API keys work
2. [Mapping Engine](/2.-mapping-engine.md) — How to configure field transformations
3. [Inbound Webhooks](/3.-inbound-webhooks.md) or [Webhook Subscriptions](/4.-webhook-subscriptions.md) — Depending on your data flow

### 4. Follow an Integration Example

Pick the [Integration Examples](/example-integrations.md) that matches your use case and follow it step-by-step.

***

## 🔧 Base URLs

| Environment    | URL                                     |
| -------------- | --------------------------------------- |
| **Production** | `https://integration.lexamica.com`      |
| **Sandbox**    | `https://integration-demo.lexamica.com` |

Use the sandbox environment for development and testing before going live.

***

## 💡 Webhooks vs. Polling

| Factor             | Webhooks                       | Polling                               |
| ------------------ | ------------------------------ | ------------------------------------- |
| **Latency**        | Real-time (seconds)            | Depends on poll frequency             |
| **Infrastructure** | Requires public HTTPS endpoint | Outbound requests only                |
| **Firewall**       | Needs inbound access           | Firewall-friendly                     |
| **Best for**       | Real-time sync                 | Batch processing, restricted networks |

Most integrations use **webhooks** for real-time updates. Use **polling** if your infrastructure doesn't support inbound connections.

***

## 📞 Support

* **Technical Issues**: Contact Lexamica integration support
* **API Access**: Request credentials through your Lexamica account manager

***

*Last updated: January 2026*
