# OpenSign for agents

Agent-native signing, approvals, mandates and verifiable proofs. Agents prepare and request; people sign, approve and consent.

- REST API: https://opensign.run/api/v1 (OpenAPI 3.1: https://opensign.run/openapi.json)
- MCP (Streamable HTTP, JSON responses): https://opensign.run/api/v1/mcp
- Proof keys: https://opensign.run/.well-known/jwks.json
- Machine-readable catalog: https://opensign.run/agents (Accept: application/json)

## Authentication

Send `Authorization: Bearer osa_…`. A workspace owner registers an agent and creates a credential with explicit scopes in OpenSign settings. Agents never hold owner authority.

Scopes: `envelopes:read`, `envelopes:write`, `approvals:read`, `approvals:write`, `mandates:read`, `mandates:write`, `proofs:read`.

## What agents can and cannot do

- No tool signs for a recipient: signing happens only at the verified recipient ceremony against the exact document hash.
- No tool consents to a mandate or confirms a grant: the owner consents and OpenAgents confirms.
- Advanced and qualified signatures are never claimed without a contracted provider; requests fail closed (501).
- Public discovery never exposes tenant data.

## Tools

| Tool | Effect | Scope | Readiness | Human step |
| --- | --- | --- | --- | --- |
| `envelope.create_draft` | draft | envelopes:write | available | None: a draft has no effect. |
| `envelope.upload_document` | draft | envelopes:write | available | None: drafts only. |
| `envelope.request_signature` | draft | envelopes:write | available | None until envelope.send. |
| `envelope.place_field` | draft | envelopes:write | available | None: drafts only. |
| `envelope.send` | signing_handoff | envelopes:write | available | Each signer consents in person at the ceremony. |
| `envelope.get` | read | envelopes:read | available | None. |
| `envelope.list` | read | envelopes:read | available | None. |
| `envelope.evidence.get` | read | envelopes:read | available | None. |
| `envelope.cancel` | request | envelopes:write | available | None; recorded as evidence with the agent as actor. |
| `approval.request` | request | approvals:write | available | The approver decides against the payload SHA-256. |
| `approval.get` | read | approvals:read | available | None. |
| `approval.list` | read | approvals:read | available | None. |
| `approval.cancel` | request | approvals:write | available | None. |
| `mandate.propose` | request | mandates:write | available | The workspace owner consents to the exact scope; OpenAgents confirms the grant. |
| `mandate.evidence.get` | read | mandates:read | available | None. |
| `mandate.list` | read | mandates:read | available | None. |
| `mandate.execution.request` | request | mandates:write | fail_closed | A consented mandate and a grant confirmed by OpenAgents. |
| `mandate.revocation.request` | request | mandates:write | available | The owner revokes. |
| `proof.verify` | verify | public | available | None. |
| `proof.export` | read | proofs:read | available | None. |
| `provider.health` | read | public | available | None. |
| `integration.health` | read | public | available | None. |

Effects: `read` changes nothing; `draft` changes only unsent drafts; `request` asks a person or records a request;
`signing_handoff` invites people to sign at the ceremony; `verify` checks a proof.

## Errors

Errors are `{ "error": { "code", "message", "requestId" } }`. 401 means a missing or invalid credential, 403 a missing scope or
role (see `WWW-Authenticate`), 409 a state or hash conflict, 501 a capability not available in this deployment.
Writes accept an `idempotencyKey` where documented.

## Pricing

Receiving, signing and verifying are free. Paid plans are not yet active; sending limits will apply per plan.
