# Cohorts API guide



## Choose a Cohorts operation



Start with the object your task needs. The groups below use the current catalogue; open an endpoint to check accepted identifiers, filters, price and availability before retrieving.



### Other operations



- [Create a cohort](https://www.monocrawl.com/docs/endpoints/cohorts/create) — Save a set of up to 100 accounts, subreddits or handles as a cohort you can sweep with one keyword.

- [Delete a cohort](https://www.monocrawl.com/docs/endpoints/cohorts/delete) — Delete one of your cohorts and every query it ran. A running sweep is cancelled first; its charge is refunded only if it had not started.

- [Get a cohort](https://www.monocrawl.com/docs/endpoints/cohorts/get) — One cohort with its members and the most recent keyword queries run against it.

- [Replace a cohort's members](https://www.monocrawl.com/docs/endpoints/cohorts/members) — Replace a cohort's member list in one call. Sweeps already completed keep the results they produced.

- [Submit a cohort query](https://www.monocrawl.com/docs/endpoints/cohorts/queries) — Run one keyword across every member of a cohort. Asynchronous: returns a query id to poll.



## Check fields and collection limits



Use the endpoint’s declared parameters and returned continuation. Filters from another platform do not automatically apply here. Preserve source identifiers, URLs and warnings; a successful page does not establish complete history. Published response schemas identify whether they come from a reviewed shaper or observed response shapes.



Agents can use `get_endpoint` for the current contract and `get_docs` with topic `platforms/cohorts` to read this page. The [coverage guide](https://www.monocrawl.com/docs/data-availability) explains nulls and partial results, and the [production guide](https://www.monocrawl.com/docs/production-checklist) covers budgets and recovery.



## Endpoint reference

## cohorts/create

`GET /v1/cohorts/create`

Save a set of up to 100 accounts, subreddits or handles as a cohort you can sweep with one keyword.

*Create a cohort*

| Parameter | Required | Description |
| --- | --- | --- |
| `name` | yes | Human label for this cohort (max 200 characters) — e.g. `Rust ecosystem` |
| `members` | yes | The accounts to sweep: a comma-separated platform:identifier list, or a JSON array of {"platform","identifier"} objects. 1-100 members; every platform must exist in the catalogue. — e.g. `reddit:rust,hackernews:steveklabnik,github:rust-lang/rust,bluesky:rust-lang.bsky.social` |
| `dry_run` | no | Read a zero-credit estimate without fetching sources, running AI, or reserving credits. Cache status is a snapshot, not a guarantee at execution. Accepted values: 1, 0, true, false. Case, spaces, hyphens and underscores are interchangeable. — e.g. `1` |

### Useful optional inputs

- `dry_run`: Read a free estimate before fetching sources or scheduling paid work. Zero credits; cache status and availability are snapshots rather than guarantees.

**Cost:** 1 credit at list price per successful uncached response; variable-cost operations may quote or settle a different charge. Confirmed uncharged or refunded failures report zero. Pending reconciliation can report credits_used:null; retain request_id and the original idempotency key.

```bash
curl "https://www.monocrawl.com/v1/cohorts/create?name=Rust%20ecosystem&members=reddit%3Arust%2Chackernews%3Asteveklabnik%2Cgithub%3Arust-lang%2Frust%2Cbluesky%3Arust-lang.bsky.social" \
  -H "x-api-key: mn_your_key_here"
```

### Response data

Illustrative abbreviated data; documented core fields are optional and may be null. Additional source fields are allowed.

```json
{
  "id": "cohort_example",
  "name": "Example cohort",
  "members": []
}
```

[Field reference](https://www.monocrawl.com/docs/endpoints/cohorts/create#response) · [JSON Schema for response.data](https://www.monocrawl.com/schemas/cohorts/create.json)


## cohorts/delete

`GET /v1/cohorts/delete`

Delete one of your cohorts and every query it ran. A running sweep is cancelled first; its charge is refunded only if it had not started.

*Delete a cohort*

| Parameter | Required | Description |
| --- | --- | --- |
| `cohort_id` | yes | Cohort id (the {cohortId} path segment) — e.g. `coh_0f2c8b1d4e6a7c9b0d1e2f3a` |
| `dry_run` | no | Read a zero-credit estimate without fetching sources, running AI, or reserving credits. Cache status is a snapshot, not a guarantee at execution. Accepted values: 1, 0, true, false. Case, spaces, hyphens and underscores are interchangeable. — e.g. `1` |

### Useful optional inputs

- `dry_run`: Read a free estimate before fetching sources or scheduling paid work. Zero credits; cache status and availability are snapshots rather than guarantees.

**Cost:** free — 0 credits.

```bash
curl "https://www.monocrawl.com/v1/cohorts/delete?cohort_id=coh_0f2c8b1d4e6a7c9b0d1e2f3a" \
  -H "x-api-key: mn_your_key_here"
```

### Response data

Illustrative abbreviated data; documented core fields are optional and may be null. Additional source fields are allowed.

```json
{
  "id": null,
  "deleted": false,
  "queries_cancelled": 0
}
```

[Field reference](https://www.monocrawl.com/docs/endpoints/cohorts/delete#response) · [JSON Schema for response.data](https://www.monocrawl.com/schemas/cohorts/delete.json)


## cohorts/get

`GET /v1/cohorts/get`

One cohort with its members and the most recent keyword queries run against it.

*Get a cohort*

| Parameter | Required | Description |
| --- | --- | --- |
| `cohort_id` | yes | Cohort id (the {cohortId} path segment) — e.g. `coh_0f2c8b1d4e6a7c9b0d1e2f3a` |
| `dry_run` | no | Read a zero-credit estimate without fetching sources, running AI, or reserving credits. Cache status is a snapshot, not a guarantee at execution. Accepted values: 1, 0, true, false. Case, spaces, hyphens and underscores are interchangeable. — e.g. `1` |

### Useful optional inputs

- `dry_run`: Read a free estimate before fetching sources or scheduling paid work. Zero credits; cache status and availability are snapshots rather than guarantees.

**Cost:** free — 0 credits.

```bash
curl "https://www.monocrawl.com/v1/cohorts/get?cohort_id=coh_0f2c8b1d4e6a7c9b0d1e2f3a" \
  -H "x-api-key: mn_your_key_here"
```

### Response data

Illustrative abbreviated data; documented core fields are optional and may be null. Additional source fields are allowed.

```json
{
  "id": null,
  "name": null,
  "created_at": null,
  "member_count": 0,
  "sweepable_count": 0,
  "members": [],
  "replaced": false
}
```

[Field reference](https://www.monocrawl.com/docs/endpoints/cohorts/get#response) · [JSON Schema for response.data](https://www.monocrawl.com/schemas/cohorts/get.json)


## cohorts/members

`GET /v1/cohorts/members`

Replace a cohort's member list in one call. Sweeps already completed keep the results they produced.

*Replace a cohort's members*

| Parameter | Required | Description |
| --- | --- | --- |
| `cohort_id` | yes | Cohort id (the {cohortId} path segment) — e.g. `coh_0f2c8b1d4e6a7c9b0d1e2f3a` |
| `members` | yes | The new member list, replacing the old one entirely: a comma-separated platform:identifier list, or a JSON array of {"platform","identifier"} objects. 1-100 members; every platform must exist in the catalogue. — e.g. `reddit:rust,hackernews:steveklabnik,github:rust-lang/rust` |
| `dry_run` | no | Read a zero-credit estimate without fetching sources, running AI, or reserving credits. Cache status is a snapshot, not a guarantee at execution. Accepted values: 1, 0, true, false. Case, spaces, hyphens and underscores are interchangeable. — e.g. `1` |

### Useful optional inputs

- `dry_run`: Read a free estimate before fetching sources or scheduling paid work. Zero credits; cache status and availability are snapshots rather than guarantees.

**Cost:** free — 0 credits.

```bash
curl "https://www.monocrawl.com/v1/cohorts/members?cohort_id=coh_0f2c8b1d4e6a7c9b0d1e2f3a&members=reddit%3Arust%2Chackernews%3Asteveklabnik%2Cgithub%3Arust-lang%2Frust" \
  -H "x-api-key: mn_your_key_here"
```

### Response data

Illustrative abbreviated data; documented core fields are optional and may be null. Additional source fields are allowed.

```json
{
  "id": null,
  "name": null,
  "created_at": null,
  "member_count": 0,
  "sweepable_count": 0,
  "members": [],
  "replaced": false
}
```

[Field reference](https://www.monocrawl.com/docs/endpoints/cohorts/members#response) · [JSON Schema for response.data](https://www.monocrawl.com/schemas/cohorts/members.json)


## cohorts/queries

`GET /v1/cohorts/queries`

Run one keyword across every member of a cohort. Asynchronous: returns a query id to poll.

*Submit a cohort query*

| Parameter | Required | Description |
| --- | --- | --- |
| `cohort_id` | yes | Cohort id (the {cohortId} path segment) — e.g. `coh_0f2c8b1d4e6a7c9b0d1e2f3a` |
| `keyword` | yes | The keyword swept across every member of the cohort (max 200 characters) — e.g. `async runtime` |
| `dry_run` | no | Read a zero-credit estimate without fetching sources, running AI, or reserving credits. Cache status is a snapshot, not a guarantee at execution. Accepted values: 1, 0, true, false. Case, spaces, hyphens and underscores are interchangeable. — e.g. `1` |

### Useful optional inputs

- `dry_run`: Read a free estimate before fetching sources or scheduling paid work. Zero credits; cache status and availability are snapshots rather than guarantees.

**Cost:** 10 credits at list price per successful uncached response; variable-cost operations may quote or settle a different charge. Confirmed uncharged or refunded failures report zero. Pending reconciliation can report credits_used:null; retain request_id and the original idempotency key.

```bash
curl "https://www.monocrawl.com/v1/cohorts/queries?cohort_id=coh_0f2c8b1d4e6a7c9b0d1e2f3a&keyword=async%20runtime" \
  -H "x-api-key: mn_your_key_here"
```

### Response data

Illustrative abbreviated data; documented core fields are optional and may be null. Additional source fields are allowed.

```json
{
  "id": "query_example",
  "status": "queued"
}
```

[Field reference](https://www.monocrawl.com/docs/endpoints/cohorts/queries#response) · [JSON Schema for response.data](https://www.monocrawl.com/schemas/cohorts/queries.json)

