---
title: "Update a Data Feeds subscription"
method: PATCH
path: "/v1/subscriptions/{subscriptionId}"
---

# Update a Data Feeds subscription

`PATCH /v1/subscriptions/{subscriptionId}`

## Request

- Base URL: `https://api.ploti.ai`
- URL: `https://api.ploti.ai/v1/subscriptions/{subscriptionId}`
- Auth: HTTP bearer

Replace the fields sent and keep the rest. Send the revision read, as `revision` or, over REST, the If-Match header; a stale one is refused as precondition_failed, so two edits never overwrite each other. Datasets that join send feed.dataset.added, those that leave feed.dataset.removed.

## Path parameters

- `subscriptionId` string, required

## Headers

- `If-Match` string

## Request body

- object
  - `revision` integer: The revision the subscription was read at; over REST it may come as the If-Match header instead.
  - `name` string
  - `places` string[]: Place ids from list_feed_places. Every deliverable dataset in each place.
  - `topics` string[]: Only these topics within places, by the ids list_feed_topics gives. Every topic when left out.
  - `datasetIds` string[]: Datasets to include on their own, from any place in the coverage.

## Response `200`

Done

- object
  - `id` string, required
  - `name` string, required
  - `places` string[], required
  - `topics` string[], required
  - `datasetIds` string[], required
  - `revision` integer, required: Send it back as If-Match (or revision) to update.
  - `datasetCount` integer, required
  - `lastEventCursor` string, nullable, required
  - `createdAt` string, required

## Other responses

- `401`: The credential is missing or not valid.
- `413`: payload_too_large: the body is over 256 KB (2 MB for /v1/tools).
- `415`: unsupported_media_type: a body was sent without Content-Type: application/json.
- `429`: rate_limited: this credential is over its rate. Retry after the Retry-After header's seconds.
- `500`: internal: Ploti failed. Retry; if it keeps happening, contact support.
- `default`: Refused: nothing was done. The code says why and the links say where the person acts on it.

---

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