---
name: iblai-connect-everlaw
description: "Read and write Everlaw data through the Everlaw API (v1) and expose it to an ibl.ai agent as an MCP tool. Use when the user asks an agent to work with Everlaw data, or to set up an Everlaw MCP connection on ibl.ai."
metadata:
  kind: guide
---

# Everlaw connector for AI agents

> A starting point maintained on ibl.ai at https://ibl.ai/developer/connectors/everlaw — not part of the iblai/base repository. Checked against Everlaw's documentation on October 20, 2026; test it against your own Everlaw setup before you rely on it.

Everlaw is a cloud e-discovery platform. It holds databases and projects of processed documents with metadata, text and images, plus searches, coding, binders, productions, Storybuilder work product, legal holds and audit events.

## Auth & conventions

- **API:** Everlaw API (v1) (REST). JSON REST API with a published OpenAPI spec: projects and databases, searches and results, document metadata and text, codes, binders, productions, native uploads, legal holds, billing and audit events. Lists page with limit plus after or offset.
- **Base URL:** https://api.everlaw.com/v1/ (US); each Everlaw deployment hosts its own API and docs, e.g. https://api.everlaw.co.uk/v1/ for the UK
- **Access:** Issued by your administrator. Organization Admins create API keys on the Organization page and choose which endpoints each key may call; a key is shown once and is disabled after 90 days unused. OAuth2 clients are registered with an Everlaw administrator.
- **Auth:** API key (Bearer); OAuth 2.0 authorization code with PKCE; OAuth 2.0 client credentials. Send Authorization: Bearer with an API key or an opaque OAuth token. OAuth tokens last 1,800 seconds and carry scope groups such as REVIEW_READ or DATA_WRITE; the organization must enable OAuth2, which is off in FedRAMP.
- **Limits:** 25 requests per second per authenticating user; excess returns 429. Failed authentication has a stricter limit, and some endpoints add their own, e.g. Deep Dive per-project per-minute and per-day quotas. Retry with exponential backoff.
- Keep Everlaw credentials in environment variables or the ibl.ai credential store. Never print a token in chat and never commit one to a file.
- Destructive or outward-facing calls are marked **Confirm with the user first** — do.

## Reads

- **Projects and databases** — GET /v1/projects and /v1/databases, plus each database's datasets and source files.
- **Searches and results** — POST /v1/projects/{projectId}/search runs a query; GET /searchResult/{searchId} pages Bates numbers, metadata and text links.
- **Documents** — GET /v1/projects/{projectId}/document/{documentId} for a document's metadata, with options for text and AI-extracted values.
- **Review work product** — GET /v1/projects/{projectId}/codes, /binders and /productions for coding, binders and productions.
- **Deep Dive answers** — POST /v1/projects/{projectId}/deepDive/questions and GET the result: cited answers across a project. OAuth2 only; API keys get 403.
- **Audit events** — GET /v1/projects/{projectId}/events and /v1/organizations/{orgId}/events for activity logs.

## Writes

- **Native uploads** — Create datasets and source files under /v1/databases/{databaseId}/datasets and upload file parts for processing.
- **Metadata overlay** — PATCH /v1/projects/{projectId}/metadata edits metadata across every project on the database; a null value removes a field. **Confirm with the user first.**
- **Document image or text** — PUT /document/{documentId}/image or /text replaces a document's PDF or text; Everlaw says this is irreversible. **Confirm with the user first.**

## Expose it to an ibl.ai agent (MCP)

Everlaw publishes an official MCP server, Everlaw MCP Server (https://support.everlaw.com/hc/en-us/articles/49986656959771-Everlaw-MCP-Server). Register it below as-is, or host your own server that wraps the calls in this skill.

First install the ibl.ai platform skills and connect your organization (writes `IBLAI_ORG`, `IBLAI_USERNAME` and `IBLAI_API_KEY` to `.env`):

```bash
npx skills add iblai/base --all
# then, in your coding agent:
/iblai-api-login
```

Every call below sends `Authorization: Api-Token $IBLAI_API_KEY`.

1. **Register the server** — `POST https://api.iblai.app/dm/api/ai-mentor/orgs/$IBLAI_ORG/users/$IBLAI_USERNAME/mcp-servers/` with `name`, `url`, `transport` (`sse` | `websocket` | `streamable_http`) and `auth_type` (`none` | `token` | `oauth2`). Capture the returned `id`.
   - Everlaw supports per-user OAuth: `auth_type=oauth2` with `auth_scope=user` and a linked `oauth_service` makes each person connect their own account in the chat. It needs an `auth_{provider}` credential in the organization's credential store first.
2. **Create the connection** — `POST https://api.iblai.app/dm/api/ai-mentor/orgs/$IBLAI_ORG/users/$IBLAI_USERNAME/mcp-server-connections/` with `server`, `scope` (`platform` | `mentor` | `user`), `auth_type`, and either `credentials` + `authorization_scheme` or a `connected_service` id for OAuth. Credentials are masked on read; never send a masked value back.
3. **Enable it on the agent** — `GET https://api.iblai.app/dm/api/ai-mentor/orgs/$IBLAI_ORG/users/$IBLAI_USERNAME/mentors/{agent_id}/settings/`, add `mcp-tool` to `tool_slugs` and the server id to `mcp_servers`, then `PATCH` the full lists back. They are replaced, not merged.

Full reference: https://ibl.ai/developer/platform/mcp/mcp-connections and the `/iblai-api-agent-mcp` skill.

## Example prompts

- "How many documents in the Acme project mention the 2024 supply agreement?"
- "List the documents coded Hot in the Beta v. Gamma project with their Bates numbers"
- "Ask Deep Dive who approved the pricing change and cite the documents"
- "Show who opened the share link for our last production"

## Guardrails

- Review sets hold client documents, privilege coding and attorney work product; keep productions, privilege calls and search results inside the matter and its ethical walls.
- Request the narrowest Everlaw scopes or role the task needs, and prefer a read-only credential for agents that only answer questions.
- Return the fields the user asked for, not whole records; do not paste personal data into chat that the user did not request.
- Before any write, show the user exactly what will change and wait for a yes.
- Respect the documented limits above: page through results and back off on rate-limit responses instead of retrying in a loop.

## References

- Everlaw API reference (US): https://api.everlaw.com/docs/
- Everlaw MCP Server developer reference: https://support.everlaw.com/hc/en-us/articles/49986656959771-Everlaw-MCP-Server
- Organization Admin: Everlaw API: https://support.everlaw.com/hc/en-us/articles/360053498791-Organization-Admin-Everlaw-API
- Everlaw MCP Server: https://support.everlaw.com/hc/en-us/articles/49986656959771-Everlaw-MCP-Server
- This connector on ibl.ai: https://ibl.ai/developer/connectors/everlaw
- ibl.ai MCP server connections: https://ibl.ai/developer/platform/mcp/mcp-connections
