---
title: "Update Datamate"
method: PATCH
path: "/datamates/{datamate_id}"
tags: ["Datamates"]
---

# Update Datamate

`PATCH /datamates/{datamate_id}`

## Path parameters

- `datamate_id` integer, required

## Request body

- UpdateDatamateRequest
  - `name` string, nullable
  - `description` string, nullable
  - `integrations` DatamateIntegration[], nullable
    - `id` union, required
      - string
      - integer
    - `tools` DatamateIntegrationTool[], required
      - `key` string, required
  - `memory_enabled` boolean, nullable
  - `knowledge_engine_enabled` boolean, nullable
  - `privacy` 'private' | 'public' | 'restricted' — Sharing modes for a workspace. Deliberately local rather than adding a member to the shared ``PrivacySetting``, which is imported by five resources (datamates, knowledge bases, notebooks, query bookmarks, custom skills). ``restricted`` is meaningless for the other four, and widening the shared enum would make it a legal value there. The two overlapping values keep identical strings, so rows written before this existed, and every cross-file read that compares against ``PrivacySetting.PUBLIC.value``, still work. Reviewers found this argument was made and then broken in the same diff: four ``CustomSkill`` schemas were swapped to this enum, which made ``restricted`` a legal value for a resource with no grant table behind it — ``_visible_to`` (``crud/custom_skills.py``) matches owner-or-public only, and ``custom_skills.privacy`` has no CHECK, so such a skill would persist and be permanently invisible to everyone but its creator. Custom skills are back on ``PrivacySetting``; keep them there until they implement sharing.
  - `knowledge_bases` integer[], nullable

## Response `200`

Successful Response

- DatamateResponse
  - `datamate` DatamateModel, required
    - `id` integer, nullable
    - `name` string, required
    - `description` string, nullable
    - `integrations` DatamateIntegration[], required
      - `id` union, required
        - string
        - integer
      - `tools` DatamateIntegrationTool[], required
        - `key` string, required
    - `user_id` integer, required
    - `memory_enabled` boolean
    - `knowledge_engine_enabled` boolean
    - `privacy` 'private' | 'public' | 'restricted' — Sharing modes for a workspace. Deliberately local rather than adding a member to the shared ``PrivacySetting``, which is imported by five resources (datamates, knowledge bases, notebooks, query bookmarks, custom skills). ``restricted`` is meaningless for the other four, and widening the shared enum would make it a legal value there. The two overlapping values keep identical strings, so rows written before this existed, and every cross-file read that compares against ``PrivacySetting.PUBLIC.value``, still work. Reviewers found this argument was made and then broken in the same diff: four ``CustomSkill`` schemas were swapped to this enum, which made ``restricted`` a legal value for a resource with no grant table behind it — ``_visible_to`` (``crud/custom_skills.py``) matches owner-or-public only, and ``custom_skills.privacy`` has no CHECK, so such a skill would persist and be permanently invisible to everyone but its creator. Custom skills are back on ``PrivacySetting``; keep them there until they implement sharing.
    - `knowledge_bases` integer[], nullable
    - `created_at` string, date-time, nullable
    - `skills` DatamateSkill[], nullable
      - `id` string, required
      - `name` string, required
      - `description` string, required
      - `content` string, required
      - `priority` integer, required
      - `related_tools` string[], nullable
      - `source` string, required
      - `integration_id` string, nullable
      - `always_active` boolean, required

## Other responses

- `403` — Forbidden
- `404` — Datamate not found
- `422` — Invalid request

## Changes

- **2026-09-04** `51aa5d004c49` — 2 breaking, 1 warning, 2 info
  - removed `#/components/schemas/PrivacySetting` from the `privacy` request property `anyOf` list
  - removed the media type `application/json` for the response with the status `422`
  - added the new `restricted` enum value to the `datamate/privacy` response property for the response status `200`
  - added `#/components/schemas/DatamatePrivacy` to the `privacy` request property `anyOf` list
  - …1 more

[Change history](https://skmtc.dev/myaltimate/apis/fastapi/changes/datamates/:datamate_id/patch.md)

---

[API](https://skmtc.dev/myaltimate/apis/fastapi.md) · [All operations](https://skmtc.dev/myaltimate/apis/fastapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/myaltimate/fastapi/revisions/51aa5d004c49/schema)
