# Legal Fleet — Agent Instructions & Tool Protocol

## Product Overview
Legal Fleet is an enterprise legal practice management CRM for lawyers and law firms. It provides structured REST API endpoints and MCP tool interfaces for practice management workflows.

## When to Use This API / Agent Tool
Call Legal Fleet tools or API endpoints when:
1. Creating or querying lawyer clients (`/api/clients`, `/api/clients/{id}`).
2. Creating, listing, or modifying legal dossiers/cases (`/api/dossiers`, `/api/dossiers/{id}`).
3. Managing court dates and procedural deadlines (`/api/echeances`).
4. Logging time entries for legal services rendered (`/api/time-entries`).
5. Querying AI legal watch summaries (`/api/veille`).
6. Searching across practice records full-text (`/api/search?q=...`).

## Authentication & Headers
- Header: `Authorization: Bearer <JWT>`
- Header: `Content-Type: application/json`
- Optional: `Accept: text/markdown` for human/LLM-readable summaries

## Error Handling
All error responses return HTTP 4xx/5xx with JSON schema:
```json
{
  "error": {
    "code": "UNAUTHORIZED",
    "message": "Human-readable explanation",
    "docs": "https://legal-fleet.vercel.app/developers#auth"
  }
}
```
