> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mnemom.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Reclassification API

> API reference for violation reclassification, score recomputation, card amendments, and compliance export

<Note>
  Part of **[CLPI](/concepts/clpi) Phase 2: Card Lifecycle & Trust Recovery**. The Reclassification API enables violation reclassification and trust score recovery.
</Note>

The Reclassification API lets you reclassify a checkpoint violation, trigger score recomputation, review reclassification and card-amendment history, and export a compliance record for audit purposes. Reclassification data feeds into the [Trust Rating](/api-reference/reputation-overview) pipeline.

For authentication, the base URL, rate limits, and the shared error envelope, see the [API overview](/api-reference/overview) and [Errors](/api-reference/errors).

## Endpoints

<CardGroup cols={2}>
  <Card title="POST /agents/{agent_id}/reclassify" icon="arrows-rotate" href="/api-reference/endpoint/post-agents-agent-id-reclassify">
    Reclassify a checkpoint's verdict (to `clear`, `review_needed`, or `boundary_violation`), optionally linked to a card amendment that closed the gap.
  </Card>

  <Card title="POST /reputation/{agent_id}/recompute" icon="rotate" href="/api-reference/endpoint/post-reputation-agent-id-recompute">
    Recompute an agent's Trust Rating immediately, reflecting any reclassifications applied since the last computation.
  </Card>

  <Card title="GET /agents/{agent_id}/compliance-export" icon="file-export" href="/api-reference/endpoint/get-agents-agent-id-compliance-export">
    Export an agent's compliance record (JSON or CSV, optionally scoped to a `from`/`to` date range) for audit purposes.
  </Card>

  <Card title="GET /agents/{agent_id}/reclassifications" icon="list" href="/api-reference/endpoint/get-agents-agent-id-reclassifications">
    List an agent's reclassification history, paginated with `limit`/`offset`.
  </Card>

  <Card title="GET /agents/{agent_id}/card-amendments" icon="clock-rotate-left" href="/api-reference/endpoint/get-agents-agent-id-card-amendments">
    List an agent's alignment-card amendment history, paginated with `limit`/`offset`.
  </Card>
</CardGroup>

See each endpoint's page for its exact request/response schema, or the [Trust Recovery guide](/guides/trust-recovery) for the full step-by-step workflow (identify a card gap, reclassify it, amend the card, recompute the score, and watch propagation).

## SDK usage

`@mnemom/sdk` does not yet include dedicated helpers for reclassification, score recomputation, or compliance export. Call these endpoints directly over HTTP:

<CodeGroup>
  ```typescript TypeScript theme={null}
  const API_BASE = 'https://api.mnemom.ai';
  const headers = {
    'X-Mnemom-Api-Key': process.env.MNEMOM_API_KEY,
    'Content-Type': 'application/json',
  };
  const agentId = 'mnm-550e8400-e29b-41d4-a716-446655440000';

  // Reclassify a checkpoint violation
  const reclassification = await fetch(`${API_BASE}/v1/agents/${agentId}/reclassify`, {
    method: 'POST',
    headers,
    body: JSON.stringify({
      checkpoint_id: 'ic-abc12345',
      reason: 'Agent correctly used mcp__browser__navigate for research, but web_fetch was missing from card bounded_actions',
    }),
  }).then((r) => r.json());
  console.log(`Reclassified: ${reclassification.reclassification_id}`);

  // Trigger score recomputation
  const result = await fetch(`${API_BASE}/v1/reputation/${agentId}/recompute`, {
    method: 'POST',
    headers,
  }).then((r) => r.json());
  console.log(`Score: ${result.previous_score} → ${result.new_score} (Δ${result.delta})`);

  // Export compliance record
  const exportData = await fetch(`${API_BASE}/v1/agents/${agentId}/compliance-export`, {
    headers,
  }).then((r) => r.json());
  ```

  ```python Python theme={null}
  import httpx

  API_BASE = "https://api.mnemom.ai"
  headers = {"X-Mnemom-Api-Key": api_key}
  agent_id = "mnm-550e8400-e29b-41d4-a716-446655440000"

  # Reclassify a checkpoint violation
  reclassification = httpx.post(
      f"{API_BASE}/v1/agents/{agent_id}/reclassify",
      headers=headers,
      json={
          "checkpoint_id": "ic-abc12345",
          "reason": "Agent correctly used mcp__browser__navigate for research, but web_fetch was missing from card bounded_actions",
      },
  ).json()
  print(f"Reclassified: {reclassification['reclassification_id']}")

  # Trigger score recomputation
  result = httpx.post(f"{API_BASE}/v1/reputation/{agent_id}/recompute", headers=headers).json()
  print(f"Score: {result['previous_score']} -> {result['new_score']} (delta {result['delta']})")

  # Export compliance record
  export_data = httpx.get(f"{API_BASE}/v1/agents/{agent_id}/compliance-export", headers=headers).json()
  ```
</CodeGroup>

## See also

* [Card Lifecycle](/concepts/card-lifecycle) -- reclassification concepts and trust graph propagation
* [Trust Recovery Guide](/guides/trust-recovery) -- step-by-step workflow
* [Reputation Scores](/concepts/reputation-scores) -- score computation
* [Policy API](/api-reference/policy-overview) -- evaluating a card's policy


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.