---
title: "Refresh cohort membership cache"
method: POST
path: "/api/v1/cohorts/refresh"
tags: ["cohorts"]
---

# Refresh cohort membership cache

`POST /api/v1/cohorts/refresh`

Re-evaluates cohort membership against current sprout state and
updates the cached membership. If a cohort name is provided in the
request body, only that cohort is refreshed. Otherwise all cohorts
are refreshed.

## Request body

- CohortRefreshRequest — Optional request body for cohort refresh. If a name is provided, only that cohort's membership cache is refreshed. If omitted or empty, all cohorts are refreshed.
  - `name` string — Name of a specific cohort to refresh

## Response `200`

Refresh results

- NATSEnvelope — Standard NATS proxy response envelope. On success, `result` contains the response data. On error, `error` contains a message string.
  - `result` unknown
  - `error` string — Error message (present only on failure)

## Other responses

- `400` — Bad request — missing or invalid parameters
- `502` — NATS communication error — farmer unreachable or returned an error

## Changes

- **2026-03-21** `011f9b67b17a` — 1 breaking, 2 info
  - the response's body type/format changed from ``/`` to `object`/`` for status `200`
  - added the optional property `error` to the response with the `200` status
  - added the optional property `result` to the response with the `200` status
- **2026-03-16** `6b54b763e29d` — 1 info
  - endpoint added
- **2026-03-15** `1aab0676c2b4` — 1 breaking
  - api path removed without deprecation
- **2026-03-13** `26871a2f667f` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/gogrlx/apis/grlx-cli-api/changes/api/v1/cohorts/refresh/post.md)

---

[API](https://skmtc.dev/gogrlx/apis/grlx-cli-api.md) · [All operations](https://skmtc.dev/gogrlx/apis/grlx-cli-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/gogrlx/grlx-cli-api/revisions/f88a30dcb10f/schema)
