---
title: "Set CRM Recency Window"
method: PATCH
path: "/api/platform/v1/connections/{id}/crm-recency"
tags: ["data"]
---

# Set CRM Recency Window

`PATCH /api/platform/v1/connections/{id}/crm-recency`

## Request

- Base URL: `https://docs.amdahl.ai`
- URL: `https://docs.amdahl.ai/api/platform/v1/connections/{id}/crm-recency`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Set how much CRM activity history (emails, meetings, calls, notes, tasks) a Salesforce / HubSpot / Pipedrive connection imports on first sync — a month window or all-history — while account, contact and deal records always land in full. Use when a workspace wants to bound (or widen) how far back CRM communications are pulled; editing it re-pulls only the affected activity streams.

## Path parameters

- `id` string, required: UUID of the CRM connection to configure.

## Request body

- object
  - `config` object, required: The recency window: window_months (1–120) OR all_history. Omit both for the 12-month default.
    - `window_months` integer: Import the last N months of CRM activity/comms.
    - `all_history` boolean: Import ALL activity history (unbounded). Mutually exclusive with window_months.

## Response `200`

OK

- object
  - `data` unknown

## Other responses

- `400`: Invalid input - failed schema validation
- `401`: Authentication required
- `403`: Forbidden - missing scope or role
- `404`: Not found
- `500`: Internal server error

---

[API](https://skmtc.dev/amdahl/apis/amdahl-platform-api.md) · [All operations](https://skmtc.dev/amdahl/apis/amdahl-platform-api/llms.txt) · [OpenAPI document](https://skmtc.dev/amdahl/apis/amdahl-platform-api/revisions/d4eee33e2472?raw)
