> ## Documentation Index
> Fetch the complete documentation index at: https://f82cc46-productmetrics.manicule.dev/docs/llms.txt
> Use this file to discover all available pages before exploring further.
> For every page in one file, fetch https://f82cc46-productmetrics.manicule.dev/docs/llms-full.txt (large).
> To search and read these docs as tools, connect the MCP server at https://f82cc46-productmetrics.manicule.dev/docs/api/mcp.
> Every agent surface: https://f82cc46-productmetrics.manicule.dev/docs/.well-known/llms-manifest.json

# Save feed source settings (/docs/api/settings/feed-source-settings-update)

<!-- agent-signals: reading_time_min: 4 · est_tokens: 2174 · updated: 2026-11-16 -->
Related: [Generate the feed now](/docs/api/settings/feed-generate.md), [Get feed source settings](/docs/api/settings/feed-source-settings-get.md), [Get Product Segmentation settings](/docs/api/settings/get.md), [Get inventory planning settings](/docs/api/settings/inventory-settings-get.md), [Save an inventory planning setting](/docs/api/settings/inventory-settings-update.md), [Preview segmentation strategy](/docs/api/settings/preview-strategy.md)

> Saves which custom labels the supplemental feed writes the product segment and category priority to, and the custom fields.

`PUT https://prod-backend.productmetrics.io/api/public/v1/properties/{propertyId}/feed/source-settings`

**Scope** `write` · **Access** Changes data · **Operation id** `feed_source_settings.update`

## Try it

`productmetrics` runs after `productmetrics login`; curl needs `PM_TOKEN` (see [Authentication](/docs/api/overview#authentication)). Set `$PROPERTY_ID` first.



**productmetrics CLI:**

```bash
productmetrics feed-source-settings update \
  --property-id $PROPERTY_ID \
  --product-segment '{"enabled":true,"target_custom_label":"custom_label_0"}' \
  --category-priority '{"enabled":true,"target_custom_label":"custom_label_0"}' \
  --if-match '"<settings_version>"' \
  --json
```

**curl:**

```bash
curl -X PUT "https://prod-backend.productmetrics.io/api/public/v1/properties/$PROPERTY_ID/feed/source-settings" \
  -H "Authorization: Bearer $PM_TOKEN" \
  -H 'If-Match: "<settings_version>"' \
  -H "Content-Type: application/json" \
  -d '{
    "product_segment": {
      "enabled": true,
      "target_custom_label": "custom_label_0"
    },
    "category_priority": {
      "enabled": true,
      "target_custom_label": "custom_label_0"
    }
  }'
```

## Response

API response (200):

```json
{
  "data": {
    "product_segment": {
      "enabled": true,
      "target_custom_label": "custom_label_0"
    },
    "category_priority": {
      "enabled": true,
      "target_custom_label": "custom_label_0"
    },
    "force_override": true,
    "custom_fields": "custom_label_0",
    "preview": true,
    "configured": true,
    "settings_version": 1
  },
  "request_id": "req_01J36FGFJJ4B3K14DZ1TT43QTX"
}
```

**CLI output:** `productmetrics feed-source-settings update --json` prints `{ "ok": true, "data": …, "request_id": "…" }` with the same `data`.

## Before you call

Read them with [`feed_source_settings.get`](/docs/api/settings/feed-source-settings-get) first and send its `settings_version` as `If-Match: "<settings_version>"` (leave the header out only when it is null); a 409 settings_conflict means someone else saved in between: read again and retry. A label already holding product values is refused unless `force_override` is true. The change reaches the feed at the nightly run, or now with [`feed.generate`](/docs/api/settings/feed-generate). Needs an editor or admin and Product Segmentation subscription.

## Path parameters

| Name         | Type          | Description                                                           |
| ------------ | ------------- | --------------------------------------------------------------------- |
| `propertyId` | string (uuid) | A property_id from [`properties.list`](/docs/api/account/properties-list). |

## Query parameters

| Name         | Type   | Required | Description                                                                                                            |
| ------------ | ------ | -------- | ---------------------------------------------------------------------------------------------------------------------- |
| `feed_scope` | string | No       | Which feed of the property: a feed id, or `all` for the property-wide settings. Omitted: the property's default scope. |

## Body

| Name                                    | Type    | Required | Description                                                                                                                                                      |
| --------------------------------------- | ------- | -------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `product_segment`                       | object  | Yes      | Where the supplemental feed writes the product segment.                                                                                                          |
| `product_segment.enabled`               | boolean | Yes      | Whether the feed carries the product segment.                                                                                                                    |
| `product_segment.target_custom_label`   | enum    | Yes      | The custom label that carries it, for example `custom_label_0`. One of `custom_label_0`, `custom_label_1`, `custom_label_2`, `custom_label_3`, `custom_label_4`. |
| `category_priority`                     | object  | Yes      | Where the supplemental feed writes the category priority.                                                                                                        |
| `category_priority.enabled`             | boolean | Yes      | Whether the feed carries the category priority.                                                                                                                  |
| `category_priority.target_custom_label` | enum    | Yes      | The custom label that carries it, for example `custom_label_1`. One of `custom_label_0`, `custom_label_1`, `custom_label_2`, `custom_label_3`, `custom_label_4`. |
| `force_override`                        | boolean | No       | Write to a custom label that already holds product values from your own feed.                                                                                    |
| `custom_fields`                         | any     | No       | Extra feed columns, as [`feed_source_settings.get`](/docs/api/settings/feed-source-settings-get) returns them.                                                        |

## Errors

A failure answers with its HTTP status and `{ error: { code, message, details? }, request_id }`. Branch on `code` (stable, lower_snake); show `message` to the person. The CLI prints the same `error` with `"ok": false`.

```json
{
  "error": {
    "code": "insufficient_scope",
    "message": "This operation needs the write scope; connect again and allow it.",
    "details": {
      "required_scope": "write"
    }
  },
  "request_id": "req_01JE744WDPZ3Q023AZSGXR5EYK"
}
```

| Status | Code                 | When                                                                                                                                                                                                                                                                                          |
| ------ | -------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 400    | `invalid_request`    | A path, query or body value does not match this page. `details.issues` lists each `location`, `path` and `message`.                                                                                                                                                                           |
| 401    | `invalid_token`      | The token is missing, expired or revoked: sign in again (`productmetrics login`). The `WWW-Authenticate` header says why.                                                                                                                                                                     |
| 403    | `insufficient_scope` | The token lacks the `write` scope (`details.required_scope`): sign in again and allow it.                                                                                                                                                                                                     |
| 404    | `not_found`          | An id in the path does not exist, or the signed-in person cannot open it.                                                                                                                                                                                                                     |
| 409    | `settings_conflict`  | Read them with [`feed_source_settings.get`](/docs/api/settings/feed-source-settings-get) first and send its `settings_version` as `If-Match: "<settings_version>"` (leave the header out only when it is null); a 409 settings_conflict means someone else saved in between: read again and retry. |
| 429    | `rate_limited`       | More than 600 requests a minute for this person: wait the `Retry-After` seconds (60) and retry.                                                                                                                                                                                               |

[All Settings and rules operations](/docs/api/settings)
