> ## Documentation Index
> Fetch the complete documentation index at: https://docs.voyantcloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Collection

> Update collection properties by ID.

## Method

`PATCH` `/v1/collections/:id`

## Path Parameters

<ParamField path="id" type="string" required>Collection ID</ParamField>

## Body Parameters

<ParamField path="base" type="object">Partial base updates</ParamField>

<ResponseField path="base" type="object">
  <Expandable title="updatable properties" defaultOpen>
    <ResponseField name="name" type="string">Display name (when not using translation update)</ResponseField>
    <ResponseField name="slug" type="string">Slug (nullable)</ResponseField>
    <ResponseField name="status" type="string">`active` | `draft` | `archived`</ResponseField>
    <ResponseField name="sortStrategy" type="string">`manual` | `newest` | `price_asc` | `price_desc` | `random` | `custom` (alias: `sort_strategy`)</ResponseField>
    <ResponseField name="definition" type="object">Rules/definition (alias: `rules`)</ResponseField>
  </Expandable>
</ResponseField>

<ParamField path="translation" type="object">Partial translation updates (requires `locale`)</ParamField>

<ResponseField path="translation" type="object">
  <Expandable title="updatable properties" defaultOpen>
    <ResponseField name="locale" type="string" required>Locale code</ResponseField>
    <ResponseField name="name" type="string">Localized name</ResponseField>
    <ResponseField name="slug" type="string">Localized slug (nullable)</ResponseField>
    <ResponseField name="description" type="string">Localized description (nullable)</ResponseField>
  </Expandable>
</ResponseField>

## Headers

<ParamField header="Authorization" type="string" required>Bearer token (e.g. <code>Authorization: Bearer YOUR\_API\_KEY</code>)</ParamField>
<ParamField header="content-type" type="string">application/json</ParamField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X PATCH https://api.voyantcloud.com/v1/collections/col_123 \
    -H "Authorization: Bearer YOUR_API_KEY" \
    -H "content-type: application/json" \
    -d '{ "base": { "status": "active", "sort_strategy": "manual" } }'
  ```

  ```javascript Node.js theme={null}
  await fetch("https://api.voyantcloud.com/v1/collections/col_123", {
    method: "PATCH",
    headers: { Authorization: `Bearer ${process.env.VOYANT_API_KEY}`, "content-type": "application/json" },
    body: JSON.stringify({ base: { status: "active", sort_strategy: "manual" } }),
  })
  ```

  ```python Python theme={null}
  import os, requests
  requests.patch(
    "https://api.voyantcloud.com/v1/collections/col_123",
    headers={"Authorization": f"Bearer {os.environ['VOYANT_API_KEY']}", "content-type": "application/json"},
    json={"base": {"status": "active", "sort_strategy": "manual"}},
  )
  ```
</RequestExample>

<ResponseExample>
  ```json 200 OK theme={null}
  {
    "id": "col_123",
    "status": "active"
  }
  ```
</ResponseExample>
