---
title: "Create a relation"
method: POST
path: "/v1/tables/{tableId}/relations"
tags: ["Tables"]
---

# Create a relation

`POST /v1/tables/{tableId}/relations`

## Request

- Base URL: `https://api.banksync.io`
- URL: `https://api.banksync.io/v1/tables/{tableId}/relations`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Link this table to another. A relation and its reciprocal are ONE schema mutation: a half-created relation is a shape the model says cannot exist, and every reader would have to defend against it forever.

## Path parameters

- `tableId` string, required: Table ID

## Request body

- object
  - `label` string, required
  - `targetTableId` string, required
  - `cardinality` 'one' | 'many', required
  - `icon` string
  - `description` string
  - `previewFieldIds` string[]
  - `pickerCondition` union: A filter tree shared by tables, dashboards and widgets. A clause names a field by key (or one hop through a relation as `relation.field`), an operator, and a value; groups combine clauses with and / or / not.
    - union
      - object
        - `field` string, required: Field key, or `relation.field` for one hop.
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - union
            - string
            - string, nullable
          - union
            - number
            - number, nullable
          - union
            - boolean
            - boolean, nullable
          - union
            - union[], nullable
              - …
            - union[]
              - …
          - union
            - object, nullable: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
            - object: An inclusive date range.
              - …
          - union
            - object, nullable: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
            - object: An inclusive numeric range.
              - …
          - union
            - object, nullable: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
            - object: A relative date range, resolved when the query runs.
              - …
          - union
            - object, nullable: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
            - object: Compare against another field of the same row, by key.
              - …
          - union
            - object, nullable: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
            - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
              - …
          - union
            - object, nullable: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
            - object: Bind to a query parameter by name; resolved against the widget bindings.
              - …
        - `security` boolean: Server-bound clause: cannot be dropped by a viewer and is enforced at the data plane.
        - `optional` boolean: Skip the clause (treat as passing) for rows where `field` is absent, as opposed to present-but-null. Default false.
      - object
        - `logic` 'and', required
        - `conditions` FilterNode[], required
        - `field` string, required: Field key, or `relation.field` for one hop.
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - string
          - number
          - boolean
          - union[]
            - union
              - …
          - object: An inclusive date range.
            - `start` string, required
            - `end` string, required
          - object: An inclusive numeric range.
            - `min` number, required
            - `max` number, required
          - object: A relative date range, resolved when the query runs.
            - `rel` 'today' | 'yesterday' | '7d' | '30d' | '90d' | '12m' | 'mtd' | 'qtd' | 'ytd', required
          - object: Compare against another field of the same row, by key.
            - `$field` string, required
          - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
            - `$filter` string, required
          - object: Bind to a query parameter by name; resolved against the widget bindings.
            - `$param` string, required
        - `security` boolean: Server-bound clause: cannot be dropped by a viewer and is enforced at the data plane.
        - `optional` boolean: Skip the clause (treat as passing) for rows where `field` is absent, as opposed to present-but-null. Default false.
      - object
        - `logic` 'or', required
        - `conditions` FilterNode[], required
        - `field` string, required: Field key, or `relation.field` for one hop.
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - string
          - number
          - boolean
          - union[]
            - union
              - …
          - object: An inclusive date range.
            - `start` string, required
            - `end` string, required
          - object: An inclusive numeric range.
            - `min` number, required
            - `max` number, required
          - object: A relative date range, resolved when the query runs.
            - `rel` 'today' | 'yesterday' | '7d' | '30d' | '90d' | '12m' | 'mtd' | 'qtd' | 'ytd', required
          - object: Compare against another field of the same row, by key.
            - `$field` string, required
          - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
            - `$filter` string, required
          - object: Bind to a query parameter by name; resolved against the widget bindings.
            - `$param` string, required
        - `security` boolean: Server-bound clause: cannot be dropped by a viewer and is enforced at the data plane.
        - `optional` boolean: Skip the clause (treat as passing) for rows where `field` is absent, as opposed to present-but-null. Default false.
      - object
        - `logic` 'not', required
        - `condition` FilterNode, required (recursive)
        - `field` string, required: Field key, or `relation.field` for one hop.
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - string
          - number
          - boolean
          - union[]
            - union
              - …
          - object: An inclusive date range.
            - `start` string, required
            - `end` string, required
          - object: An inclusive numeric range.
            - `min` number, required
            - `max` number, required
          - object: A relative date range, resolved when the query runs.
            - `rel` 'today' | 'yesterday' | '7d' | '30d' | '90d' | '12m' | 'mtd' | 'qtd' | 'ytd', required
          - object: Compare against another field of the same row, by key.
            - `$field` string, required
          - object: Bind to a dashboard filter by id; resolved when the dashboard renders.
            - `$filter` string, required
          - object: Bind to a query parameter by name; resolved against the widget bindings.
            - `$param` string, required
        - `security` boolean: Server-bound clause: cannot be dropped by a viewer and is enforced at the data plane.
        - `optional` boolean: Skip the clause (treat as passing) for rows where `field` is absent, as opposed to present-but-null. Default false.
    - union
      - object
        - `field` string, required
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - string
          - number
          - boolean
          - unknown
          - union[]
            - union
              - …
          - object
            - `start` string, required
            - `end` string, required
          - object
            - `min` number, required
            - `max` number, required
          - object
            - `rel` 'today' | 'yesterday' | '7d' | '30d' | '90d' | '12m' | 'mtd' | 'qtd' | 'ytd', required
          - object
            - `$filter` string, required
          - object
            - `$param` string, required
          - object
            - `$field` string, required
        - `security` boolean
        - `optional` boolean
        - `logic` 'and' | 'or', required
        - `conditions` FilterNode[], required
      - object
        - `logic` 'and', required
        - `conditions` FilterNode[], required
      - object
        - `logic` 'or', required
        - `conditions` FilterNode[], required
    - union
      - object
        - `field` string, required
        - `op` 'eq' | 'neq' | 'gt' | 'gte' | 'lt' | 'lte' | 'in' | 'nin' | 'contains' | 'starts-with' | 'ends-with' | 'between' | 'is-null' | 'is-not-null' | 'matches' | 'has-passed' | 'not-passed', required
        - `value` union
          - string
          - number
          - boolean
          - unknown
          - union[]
            - union
              - …
          - object
            - `start` string, required
            - `end` string, required
          - object
            - `min` number, required
            - `max` number, required
          - object
            - `rel` 'today' | 'yesterday' | '7d' | '30d' | '90d' | '12m' | 'mtd' | 'qtd' | 'ytd', required
          - object
            - `$filter` string, required
          - object
            - `$param` string, required
          - object
            - `$field` string, required
        - `security` boolean
        - `optional` boolean
        - `logic` 'not', required
        - `condition` FilterNode, required (recursive)
      - object
        - `logic` 'not', required
        - `condition` FilterNode, required (recursive)
  - `reciprocal` object
    - `label` string, required
    - `cardinality` 'one' | 'many', required
  - `expectedSchemaVersion` integer, required

## Response `201`

Relation created

- object
  - `success` true, required
  - `data` object, required
    - `id` string, required
    - `workspaceId` string, required
    - `name` string, required
    - `icon` string
    - `folderId` string, nullable, required
    - `position` integer, required
    - `kind` 'typed' | 'freeform', required
    - `resourceType` 'transactions' | 'balances' | 'trades' | 'holdings' | 'orders' | 'loans' | 'receipts' | 'invoices' | 'documents'
    - `contractVersion` integer
    - `singleton` true
    - `dedupFieldIds` string[], required
    - `promoted` object, required
      - `primary` string, required
      - `date` string
      - `amount` string
    - `nextNumber` integer
    - `schemaVersion` integer, required
    - `revision` integer, required
    - `structureLocked` boolean, required
    - `originAppId` string
    - `origin` object
      - `install` object
        - `id` string, required
        - `resourceKey` string, required
      - `listing` object
        - `id` string, required
        - `kind` string, required
        - `releaseId` string, required
      - `app` object
        - `id` string, required
      - `managed` string
      - `adoptedFrom` object
        - `managed` string
    - `retention` union
      - object
        - `mode` 'forever', required
      - object
        - `mode` 'days', required
        - `days` integer, required
    - `rowCount` integer, required
    - `attachmentBytes` integer, required
    - `createdBy` union, required
      - object
        - `kind` 'user', required
        - `userId` string, required
      - object
        - `kind` 'sync', required
        - `feedId` string, required
        - `jobId` string
        - `cause` object
          - `automationId` string, required
          - `runId` string, required
          - `depth` integer, required
          - `untrustedSender` true
      - object
        - `kind` 'extractor', required
        - `feedId` string, required
        - `jobId` string
        - `untrustedSender` true
      - object
        - `kind` 'import', required
        - `importId` string, required
        - `userId` string, required
      - object
        - `kind` 'api', required
        - `clientId` string, required
      - object
        - `kind` 'system', required
        - `reason` string, required
      - object
        - `kind` 'automation', required
        - `automationId` string, required
        - `revision` string, required
        - `grantId` string, required
        - `runId` string, required
        - `node` string, required
        - `startedBy` ActorRef, required (recursive)
        - `depth` integer, required
        - `untrustedSender` true
    - `createdAt` string, required
    - `updatedAt` string, required
    - `deletedAt` string
    - `fields` union[], required
      - union
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'text', required
          - `config` object
            - `suggestFrom` object
              - …
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'long_text', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'number', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'checkbox', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'date', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'datetime', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'url', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'email', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'phone', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'json', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'created_time', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'last_edited_time', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'created_by', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'last_edited_by', required
          - `config` object
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'single_select', required
          - `config` object, required
            - `options` object[], required
              - …
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'multi_select', required
          - `config` object, required
            - `options` object[], required
              - …
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'status', required
          - `config` object, required
            - `options` object[], required
              - …
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'rating', required
          - `config` object, required
            - `maximum` integer
            - `icon` 'star' | 'heart' | 'flag'
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'user', required
          - `config` object, required
            - `multiple` boolean
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'auto_number', required
          - `config` object, required
            - `prefix` string
            - `digits` integer
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'attachment', required
          - `config` object, required
            - `accept` 'any' | 'images' | 'documents'
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'relation', required
          - `config` object, required
            - `targetTableId` string, required
            - `cardinality` 'one' | 'many'
            - `linkFieldId` string, required
            - `partnerFieldId` string
            - `pickerCondition` union: A filter tree shared by tables, dashboards and widgets. A clause names a field by key (or one hop through a relation as `relation.field`), an operator, and a value; groups combine clauses with and / or / not.
              - …
            - `previewFieldIds` string[]
        - object
          - `id` string, required
          - `tableId` string, required
          - `key` string, required
          - `label` string, required
          - `format` union
            - object
              - …
            - object
              - …
            - object
              - …
            - object
              - …
          - `position` integer, required
          - `contractFieldId` string
          - `required` boolean
          - `unique` boolean
          - `default` union
            - object
              - …
            - object
              - …
          - `icon` string
          - `description` string
          - `createdAt` string, required
          - `updatedAt` string, required
          - `deletedAt` string
          - `kind` 'formula', required
          - `config` object, required
            - `languageVersion` 1
            - `source` string, required
            - `preset` union
              - …
          - `computed` object, required
            - `resultKind` object, required
              - …
            - `state` 'ready' | 'recalculating' | 'error', required
            - `error` 'division_by_zero' | 'invalid_value' | 'missing_reference' | 'type_mismatch' | 'complexity_limit' | 'depth_limit' | 'link_limit' | 'unavailable'
            - `volatile` boolean

## Other responses

- `400`: Validation failed, or a read-only field was written — `code` names the refusal and `details[]` the offending field or cell
- `401`: Unauthorized
- `403`: Forbidden — missing scope, insufficient role, or plan limit reached
- `404`: Not found
- `409`: Conflict — the table is locked, the schema or row version moved, a cell the patch writes was changed by another edit (`ROW_CELL_CONFLICT`, with each cell’s current value in `details`), or a relation accepts one row. `code` says which.

---

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