> ## Documentation Index
> Fetch the complete documentation index at: https://developers.meet-oj.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Agents

> Connect an AI agent over MCP or A2A.

## MCP

O.J.'s MCP server is at `https://console.meet-oj.com/mcp`. Its tools do the same things as the matching REST endpoints and use the same OAuth client.

Tools that contact a borrower or record a credit decision return `input_required` and wait for a person to confirm.

| Tool                     | Access           | Equivalent                                                    |
| ------------------------ | ---------------- | ------------------------------------------------------------- |
| `create-referral`        | write            | `POST /referrals`                                             |
| `get-referral`           | read             | `GET /referrals/{id}`                                         |
| `list-document-requests` | read             | `GET /referrals/{id}/document_requests`                       |
| `attach-documents`       | write            | `POST /referrals/{id}/documents`                              |
| `list-offers`            | read             | `GET /referrals/{id}/offers`                                  |
| `list-payouts`           | read             | `GET /payouts`                                                |
| `get-conversation`       | read             | `GET /referrals/{id}/conversation`                            |
| `send-message`           | write            | `POST /referrals/{id}/messages`                               |
| `get-policy`             | read             | `GET /partner/policy`                                         |
| `list-submissions`       | read             | `GET /programs/{id}/submissions`                              |
| `record-decision`        | write, confirmed | `POST /submissions/{id}/decision`                             |
| `request-documents`      | write, confirmed | Requests an extra document from the borrower                  |
| `submit-to-lender`       | write            | Releases a submission when your policy requires send approval |

No tool can change a payout destination.

## A2A

<Note>
  Coming soon.
</Note>

O.J. will publish an Agent Card at `/.well-known/agent-card.json` with one skill, `refer_business`, and the HTTP+JSON binding at `https://api.meet-oj.com/a2a/v1`. A referral maps to an A2A task:

| Referral `status`                                | A2A task state                                  |
| ------------------------------------------------ | ----------------------------------------------- |
| `received`, `prequalified`, `submitted`, `offer` | `working`                                       |
| `needs_borrower`, `needs_partner`                | `input-required` (`todos` is the input request) |
| `funded`                                         | `completed`                                     |
| `declined`                                       | `rejected`                                      |
| `closed`                                         | `canceled`                                      |

Streaming maps to `GET /referrals/{id}/events:stream`, and push notifications map to per-referral webhooks.

## Machine-readable docs

* The OpenAPI file is the source for the [API reference](/api-reference).
* Append `.md` to any page URL to get it as Markdown.
* `/llms.txt` indexes the site for agents.
