---
title: "Sync Rules"
method: POST
path: "/datamates/{datamate_id}/rules/sync"
tags: ["WORKSPACE_RULES"]
---

# Sync Rules

`POST /datamates/{datamate_id}/rules/sync`

## Request

- Base URL: `https://api.myaltimate.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.myaltimate.com/datamates/{datamate_id}/rules/sync`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer
- TypeScript: <https://skmtc.dev/myaltimate/apis/myaltimate-api/docs/datamates/:datamate_id/rules/sync/post.ts> (a function with typed inputs; its response is checked against the schema)

Session pull: the active rules for this repository, the workspace
settings, and the caller's proposals reviewed since ``reviewed_since``.
One REPEATABLE READ snapshot.

## Path parameters

- `datamate_id` integer, required

## Request body

- SyncRulesRequest
  - `repo_remote` string, required
  - `known_revision` integer, nullable
  - `reviewed_since` string, date-time, nullable

## Response `200`

Successful Response

- SyncRulesResponse
  - `unchanged` boolean, required
  - `revision` integer, required
  - `repo_identity` string, required
  - `workspace_name` string, required
  - `owner_name` string, nullable
  - `is_owner` boolean, required
  - `settings` RuleSettings, required
    - `learning_enabled` boolean, required
    - `include_quotes` boolean, required
    - `share_across_repos` boolean, required
  - `pending_count` integer, required
  - `rules` RuleOut[], required
    - `public_id` string, required
    - `rule_key` string, required
    - `repo_identity` string, nullable
    - `text` string, required
    - `applies_to` string[], required
    - `tags` string[], required
    - `pinned` boolean, required
    - `version` integer, required
    - `updated_at` string, date-time, required
  - `my_reviewed` ProposalStatus[], required
    - `public_id` string, required
    - `rule_key` string, required
    - `text` string, required
    - `change` string, required
    - `status` string, required
    - `review_reason` string, nullable
    - `reviewed_by_name` string, nullable
    - `reviewed_at` string, date-time, nullable
    - `updated_at` string, date-time, required
  - `cursor` string, date-time, required

## Other responses

- `403`: Not the workspace's owner
- `404`: Workspace or rule not found
- `409`: Changed since read, or refused
- `422`: Validation Error

## Changes

- **2026-11-03** `868dfab8c7fe`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/myaltimate/apis/myaltimate-api/changes/datamates/:datamate_id/rules/sync/post.md)

---

[API](https://skmtc.dev/myaltimate/apis/myaltimate-api.md) - [All operations](https://skmtc.dev/myaltimate/apis/myaltimate-api/llms.txt) - [OpenAPI document](https://skmtc.dev/myaltimate/apis/myaltimate-api/revisions/01c038028180?raw)
