@nivaro/sdk 0.1.25 → 0.1.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1889,6 +1889,81 @@ When SLA rules, scheduled flows, or other time-tracking systems are active:
1889
1889
 
1890
1890
  ---
1891
1891
 
1892
+ ## SDK — Layout Editor
1893
+
1894
+ The layout editor saves through a bundle + ops model: read the layout as `{ layout, groups, placements, rev }`, send a batch of small ops with the `rev` you read, and get the new bundle back. A batch applies all or nothing. Every call below except the picker and scheduled-change tools is admin only.
1895
+
1896
+ ```typescript
1897
+ import {
1898
+ readLayoutBundle, submitLayoutOps,
1899
+ readLayoutOverview, explainLayout,
1900
+ createCollectionLayout, cloneLayout, readActiveLayout
1901
+ } from '@nivaro/sdk'
1902
+
1903
+ const bundle = await nivaro.request(readLayoutBundle(42))
1904
+
1905
+ try {
1906
+ const next = await nivaro.request(
1907
+ submitLayoutOps(42, {
1908
+ base_rev: bundle.rev,
1909
+ note: 'Move Status into the header',
1910
+ ops: [
1911
+ { op: 'move', from: { field: 'status', group_key: 'details' }, to_group_key: null, index: 0 },
1912
+ { op: 'update_placement', at: { field: 'owner', group_key: null }, patch: { col_span: 6 } },
1913
+ { op: 'layout_update', patch: { disable_clone: true } }
1914
+ ]
1915
+ })
1916
+ )
1917
+ } catch (err) {
1918
+ // 409 { error: 'stale', bundle }: the layout changed since base_rev. Re-apply on err.response.bundle.
1919
+ // 400 { error, op_index }: the op at op_index was refused; nothing was saved.
1920
+ }
1921
+ ```
1922
+
1923
+ The op union (`LayoutOp`), `LayoutBundle`, `PlacementPatch`, `GroupPatch` and `LayoutPatch` are exported as types, with `PLACEMENT_PATCH_KEYS`, `GROUP_PATCH_KEYS` and `LAYOUT_PATCH_KEYS` as runtime lists. A batch holds at most 500 ops.
1924
+
1925
+ #### Commands
1926
+
1927
+ | Command | Route | Notes |
1928
+ | --- | --- | --- |
1929
+ | readLayoutBundle(id) | GET /collection-layouts/:id/bundle | Returns the bundle itself (no `data` wrapper). |
1930
+ | submitLayoutOps(id, { ops, base_rev, note? }) | POST /collection-layouts/:id/ops | Returns the new bundle; 409 stale carries the current bundle, 400 carries `op_index`. |
1931
+ | readLayoutOverview(collection) | GET /collection-layouts/overview | Every layout, sectioned the way the active-layout resolution checks them, with references and warnings. |
1932
+ | explainLayout({ collection, item?, role_id?, slug? }) | GET /collection-layouts/explain | Which layout a record opens with, why, and each candidate's check. |
1933
+ | createCollectionLayout(collection, name, { slug?, layout_type?, seed_fields? }) | POST /collection-layouts | `seed_fields` starts the layout with one Main section holding every visible field. |
1934
+ | cloneLayout(id, name, { slug?, layout_type? }) | POST /collection-layouts/:id/clone | The copy starts hidden from the New menu (`create_hidden`); an admin opts it in. |
1935
+ | readActiveLayout(collection, { slug?, item? }) | GET /collection-layouts/active | Placements carry `col_span`; the result includes `ungrouped_sort`. |
1936
+ | updateCollectionLayout(id, patch) | PATCH /collection-layouts/:id | Any `LayoutPatch` setting. |
1937
+ | readLayoutVersion / diffLayoutVersion / restoreLayoutVersion | /collection-layouts/:id/versions/... | A restore snapshots the current state first, so it is reversible. |
1938
+ | projectFieldConfig(collection, placements) | POST /field-config/:collection/project | The field-config rows a draft would produce. A read; writes nothing. |
1939
+ | listInternalWidgetPlacements(widgetId) | GET /widgets-internal/:id/placements | The layouts that place a widget. |
1940
+
1941
+ #### Layout-gated record tools
1942
+
1943
+ Disabling a record in pickers and scheduling a change accept `layout`, the `?layout=` slug of the form the record was opened with. A non-admin may use them only when that form grants it (`allow_disable_pickers`, `allow_schedule`) and they may update the record. Scheduled changes for non-admins are limited to real, writable columns they may update; a read-only, computed or alias field is refused with 400.
1944
+
1945
+ ```typescript
1946
+ import { excludeFromPickers, includeInPickers, createScheduledChange } from '@nivaro/sdk'
1947
+
1948
+ await nivaro.request(excludeFromPickers({ collection: 'vendors', item_id: 17, layout: 'intake' }))
1949
+ await nivaro.request(includeInPickers({ collection: 'vendors', item_id: 17, layout: 'intake' }))
1950
+
1951
+ await nivaro.request(
1952
+ createScheduledChange({
1953
+ collection: 'vendors',
1954
+ item_id: '17',
1955
+ change_type: 'field_update',
1956
+ changes: { status: 'inactive' },
1957
+ scheduled_at: '2026-12-01T09:00:00Z',
1958
+ layout: 'intake'
1959
+ })
1960
+ )
1961
+ ```
1962
+
1963
+ > **Note:** Retired layout settings are no longer writable: `summary_show_all`, `allow_clone` (use `disable_clone`), `addendum_lock_fields` and `hide_actions_when_collapsed`. They stay optional and deprecated on the `CollectionLayout` read type.
1964
+
1965
+ ---
1966
+
1892
1967
  ## SDK — Schema Snapshots
1893
1968
 
1894
1969
  Capture point-in-time snapshots of your entire metadata registry (collections, fields, relations). Useful for version control, environment promotion, and disaster recovery.
package/dist/index.d.ts CHANGED
@@ -3149,6 +3149,12 @@ declare function createScheduledChange(body: {
3149
3149
  changes: Record<string, unknown>;
3150
3150
  /** ISO date string. */
3151
3151
  scheduled_at: string;
3152
+ /**
3153
+ * The ?layout= slug of the form the record was opened with. A non-admin may
3154
+ * schedule only when that form grants it (allow_schedule) and only fields
3155
+ * they may update that are real, writable columns.
3156
+ */
3157
+ layout?: string | null;
3152
3158
  }): Command<{
3153
3159
  data: ScheduledChange;
3154
3160
  }>;
@@ -3198,8 +3204,12 @@ interface FieldConfig {
3198
3204
  repeater_schema: unknown | null;
3199
3205
  is_translatable: boolean;
3200
3206
  }
3201
- declare function readFieldConfig(collection: string): Command<{
3207
+ /** Field config overlaid with a layout's placements (`layout_id`, else the active layout). */
3208
+ declare function readFieldConfig(collection: string, opts?: {
3209
+ layout_id?: number;
3210
+ }): Command<{
3202
3211
  data: FieldConfig[];
3212
+ ungrouped_sort?: number | null;
3203
3213
  }>;
3204
3214
  /** Update one field's behavioral config (admin). */
3205
3215
  declare function updateFieldConfig(collection: string, field: string, body: Partial<Omit<FieldConfig, 'field'>>): Command<{
@@ -3667,6 +3677,361 @@ declare function readDistinctValues(collection: string, field: string, options?:
3667
3677
  data: unknown[];
3668
3678
  }>;
3669
3679
 
3680
+ /**
3681
+ * Layout editor commands: the bundle + atomic ops save model, the overview and
3682
+ * "which form opens" explain reads, the editor's read-only canvas projection,
3683
+ * and the layout-gated record tools (picker toggle, scheduled changes).
3684
+ *
3685
+ * The block between the BEGIN/END markers mirrors
3686
+ * packages/shared/src/lib/layout-ops.ts (types and patch-key lists) so the SDK
3687
+ * needs no runtime dependency on @nivaro/shared. It must stay byte-identical:
3688
+ * packages/shared/src/lib/layout-ops-sdk.test.ts fails when the two drift.
3689
+ */
3690
+
3691
+ type PlacementKey = {
3692
+ field: string;
3693
+ group_key: string | null;
3694
+ };
3695
+ interface PlacementPatch {
3696
+ label_override?: string | null;
3697
+ is_visible?: boolean;
3698
+ default_expanded?: boolean;
3699
+ col_span?: number | null;
3700
+ overrides?: unknown;
3701
+ show_row_revisions?: boolean;
3702
+ allow_revision_restore?: boolean | null;
3703
+ lock_conditions?: string | null;
3704
+ input_bindings?: unknown;
3705
+ widget_id?: number | null;
3706
+ show_approval_chain?: boolean;
3707
+ }
3708
+ interface PlacementRow {
3709
+ id?: number;
3710
+ field: string;
3711
+ group_key: string | null;
3712
+ sort: number;
3713
+ label_override: string | null;
3714
+ is_visible: boolean;
3715
+ default_expanded: boolean;
3716
+ col_span: number | null;
3717
+ overrides: unknown;
3718
+ show_row_revisions: boolean;
3719
+ allow_revision_restore: boolean | null;
3720
+ lock_conditions: string | null;
3721
+ input_bindings: unknown;
3722
+ widget_id: number | null;
3723
+ show_approval_chain: boolean;
3724
+ }
3725
+ /** Group JSON settings (summary_fields, swap_config, …) travel as their stored JSON text. */
3726
+ interface GroupPatch {
3727
+ label?: string;
3728
+ type?: string;
3729
+ icon?: string | null;
3730
+ is_collapsed?: boolean;
3731
+ tab_mode?: string | null;
3732
+ hide_when_empty?: boolean;
3733
+ visibility_mode?: string | null;
3734
+ summary_fields?: string | null;
3735
+ summary_hide_empty?: boolean;
3736
+ swap_config?: string | null;
3737
+ skip_if_filled?: string | null;
3738
+ content?: string | null;
3739
+ content_tone?: string | null;
3740
+ visible_when?: string | null;
3741
+ hidden_for_roles?: string | null;
3742
+ locked_for_roles?: string | null;
3743
+ read_width?: string | null;
3744
+ }
3745
+ interface GroupRow {
3746
+ id?: number;
3747
+ key: string;
3748
+ parent_key: string | null;
3749
+ sort: number;
3750
+ label: string;
3751
+ type: string;
3752
+ icon: string | null;
3753
+ is_collapsed: boolean;
3754
+ tab_mode: string | null;
3755
+ hide_when_empty: boolean;
3756
+ visibility_mode: string | null;
3757
+ summary_fields: string | null;
3758
+ summary_hide_empty: boolean;
3759
+ swap_config: string | null;
3760
+ skip_if_filled: string | null;
3761
+ content: string | null;
3762
+ content_tone: string | null;
3763
+ visible_when: string | null;
3764
+ hidden_for_roles: string | null;
3765
+ locked_for_roles: string | null;
3766
+ read_width: string | null;
3767
+ }
3768
+ /** The layout settings PATCH /collection-layouts/:id accepts. */
3769
+ type LayoutPatch = Partial<{
3770
+ name: string;
3771
+ slug: string | null;
3772
+ create_label: string | null;
3773
+ create_hidden: boolean;
3774
+ sort: number;
3775
+ is_active: boolean;
3776
+ disable_comments: boolean;
3777
+ disable_tasks: boolean;
3778
+ tab_mode: string;
3779
+ validate_before_next: boolean;
3780
+ summary_enabled: boolean;
3781
+ summary_hide_empty: boolean;
3782
+ ai_enabled: boolean;
3783
+ accordion_mode: boolean;
3784
+ disable_revisions: boolean;
3785
+ disable_clone: boolean;
3786
+ disable_delete: boolean;
3787
+ row_order_field: string | null;
3788
+ pdf_theme: string | null;
3789
+ pdf_template_id: number | null;
3790
+ pdf_cover_enabled: boolean;
3791
+ pdf_cover_title_field: string | null;
3792
+ pdf_cover_subtitle: string | null;
3793
+ pdf_show_logo: boolean;
3794
+ pdf_page_size: string;
3795
+ pdf_orientation: string;
3796
+ pdf_button_label: string | null;
3797
+ conditions: {
3798
+ role_ids?: string[];
3799
+ } | null;
3800
+ allow_schedule: boolean;
3801
+ allow_disable_pickers: boolean;
3802
+ layout_type: string;
3803
+ addendum_layout_id: number | null;
3804
+ workflow_template_id: string | null;
3805
+ single_active_addendum: boolean;
3806
+ addendum_default_view: boolean;
3807
+ record_conditions: Array<{
3808
+ field: string;
3809
+ op: string;
3810
+ value?: unknown;
3811
+ }> | null;
3812
+ default_values: Record<string, unknown> | null;
3813
+ display_mode: string | null;
3814
+ parent_layout_id: number | null;
3815
+ hide_integrity_banner: boolean;
3816
+ hide_sla_banner: boolean;
3817
+ changes_tray: boolean;
3818
+ dossier_enabled: boolean;
3819
+ dossier_label: string | null;
3820
+ quick_picker: string[] | null;
3821
+ sheet_width: number | null;
3822
+ header_fields: string[] | null;
3823
+ hide_empty: boolean;
3824
+ }>;
3825
+ type LayoutRow = Record<string, unknown> & {
3826
+ id: number;
3827
+ collection: string;
3828
+ };
3829
+ type LayoutOp = {
3830
+ op: 'place';
3831
+ field: string;
3832
+ group_key: string | null;
3833
+ index: number;
3834
+ patch?: PlacementPatch;
3835
+ } | {
3836
+ op: 'move';
3837
+ from: PlacementKey;
3838
+ to_group_key: string | null;
3839
+ index: number;
3840
+ } | {
3841
+ op: 'update_placement';
3842
+ at: PlacementKey;
3843
+ patch: PlacementPatch;
3844
+ } | {
3845
+ op: 'remove';
3846
+ at: PlacementKey;
3847
+ } | {
3848
+ op: 'group_create';
3849
+ key: string;
3850
+ label: string;
3851
+ group_type: string;
3852
+ parent_key: string | null;
3853
+ index: number;
3854
+ patch?: GroupPatch;
3855
+ } | {
3856
+ op: 'group_update';
3857
+ key: string;
3858
+ patch: GroupPatch;
3859
+ } | {
3860
+ op: 'group_move';
3861
+ key: string;
3862
+ parent_key: string | null;
3863
+ index: number;
3864
+ } | {
3865
+ op: 'group_remove';
3866
+ key: string;
3867
+ placements: 'ungroup' | 'delete';
3868
+ } | {
3869
+ op: 'layout_update';
3870
+ patch: LayoutPatch;
3871
+ };
3872
+ interface LayoutBundle {
3873
+ layout: LayoutRow;
3874
+ groups: GroupRow[];
3875
+ placements: PlacementRow[];
3876
+ rev: string;
3877
+ }
3878
+ declare const PLACEMENT_PATCH_KEYS: readonly ["label_override", "is_visible", "default_expanded", "col_span", "overrides", "show_row_revisions", "allow_revision_restore", "lock_conditions", "input_bindings", "widget_id", "show_approval_chain"];
3879
+ declare const GROUP_PATCH_KEYS: readonly ["label", "type", "icon", "is_collapsed", "tab_mode", "hide_when_empty", "visibility_mode", "summary_fields", "summary_hide_empty", "swap_config", "skip_if_filled", "content", "content_tone", "visible_when", "hidden_for_roles", "locked_for_roles", "read_width"];
3880
+ declare const LAYOUT_PATCH_KEYS: readonly ["name", "slug", "create_label", "create_hidden", "sort", "is_active", "disable_comments", "disable_tasks", "tab_mode", "validate_before_next", "summary_enabled", "summary_hide_empty", "ai_enabled", "accordion_mode", "disable_revisions", "disable_clone", "disable_delete", "row_order_field", "pdf_theme", "pdf_template_id", "pdf_cover_enabled", "pdf_cover_title_field", "pdf_cover_subtitle", "pdf_show_logo", "pdf_page_size", "pdf_orientation", "pdf_button_label", "conditions", "allow_schedule", "allow_disable_pickers", "layout_type", "addendum_layout_id", "workflow_template_id", "single_active_addendum", "addendum_default_view", "record_conditions", "default_values", "display_mode", "parent_layout_id", "hide_integrity_banner", "hide_sla_banner", "changes_tray", "dossier_enabled", "dossier_label", "quick_picker", "sheet_width", "header_fields", "hide_empty"];
3881
+ /** Why a layout won resolution. */
3882
+ interface LayoutPickReason {
3883
+ kind: 'record_rule' | 'role' | 'default' | 'fallback' | 'slug' | 'type_use';
3884
+ rules?: Array<{
3885
+ field: string;
3886
+ op: string;
3887
+ value?: unknown;
3888
+ }>;
3889
+ role_ids?: string[];
3890
+ role_names?: string[];
3891
+ type_use?: string;
3892
+ }
3893
+ interface LayoutOverviewRow {
3894
+ layout_id: number;
3895
+ name: string;
3896
+ layout_type: string;
3897
+ slug: string | null;
3898
+ section: 'forms' | 'link_only' | 'other_views' | 'unused';
3899
+ reason: LayoutPickReason;
3900
+ is_default: boolean;
3901
+ new_menu: {
3902
+ label: string;
3903
+ hidden: boolean;
3904
+ } | null;
3905
+ shape: {
3906
+ groups: number;
3907
+ steps_or_tabs: number;
3908
+ fields: number;
3909
+ container_mode: 'tabs' | 'steps' | null;
3910
+ };
3911
+ references: Array<{
3912
+ kind: string;
3913
+ id: string | number;
3914
+ label: string;
3915
+ }>;
3916
+ warnings: string[];
3917
+ }
3918
+ /**
3919
+ * "Which form does each kind of record get?" Every layout of a collection,
3920
+ * sectioned and ordered as the active-layout resolution checks them. Admin only.
3921
+ */
3922
+ declare function readLayoutOverview(collection: string): Command<{
3923
+ data: {
3924
+ rows: LayoutOverviewRow[];
3925
+ warning: string | null;
3926
+ };
3927
+ }>;
3928
+ /**
3929
+ * Which layout a saved record opens with, and why: the resolution itself, with
3930
+ * each candidate's check. `role_id` tests as that role (none = as an admin);
3931
+ * `slug` pins a layout by its link name. Admin only.
3932
+ */
3933
+ declare function explainLayout(query: {
3934
+ collection: string;
3935
+ item?: string | number;
3936
+ role_id?: string;
3937
+ slug?: string;
3938
+ }): Command<{
3939
+ data: {
3940
+ layout_id: number | null;
3941
+ reason: LayoutPickReason | null;
3942
+ checked: Array<{
3943
+ layout_id: number;
3944
+ matched: boolean;
3945
+ why: string;
3946
+ }>;
3947
+ };
3948
+ }>;
3949
+ /**
3950
+ * The layout, its groups and placements as the editor edits them, with the
3951
+ * `rev` the next ops batch must name. Not wrapped in `data`. Admin only.
3952
+ */
3953
+ declare function readLayoutBundle(layoutId: number): Command<LayoutBundle>;
3954
+ /**
3955
+ * Apply a batch of ops (at most 500) all or nothing and get the new bundle.
3956
+ * Rejections arrive as thrown errors carrying `status` and `response`:
3957
+ * 409 `{ error: 'stale', bundle }` when the layout changed since `base_rev`
3958
+ * (re-apply on `response.bundle`), 400 `{ error, op_index }` when an op is
3959
+ * refused. Admin only.
3960
+ */
3961
+ declare function submitLayoutOps(layoutId: number, body: {
3962
+ ops: LayoutOp[];
3963
+ base_rev: string;
3964
+ note?: string | null;
3965
+ }): Command<LayoutBundle>;
3966
+ /** One saved version of a layout (the snapshot itself). Admin only. */
3967
+ declare function readLayoutVersion(layoutId: number, versionId: number): Command<{
3968
+ data: Record<string, unknown>;
3969
+ }>;
3970
+ /**
3971
+ * What changed between a version and now (`against` omitted or 'current') or
3972
+ * another version id. `versionId` 'newest' answers "what did the last save change".
3973
+ */
3974
+ declare function diffLayoutVersion(layoutId: number, versionId: number | 'newest', against?: number | 'current'): Command<{
3975
+ data: Record<string, unknown>;
3976
+ }>;
3977
+ /** Layouts whose last save shows a data-losing shape. Admin only. */
3978
+ declare function readLayoutDrift(): Command<{
3979
+ data: unknown[];
3980
+ }>;
3981
+ /** A placement as the projection route takes it: `field` plus any placement columns. */
3982
+ type ProjectedPlacement = {
3983
+ field: string;
3984
+ } & Partial<Omit<PlacementRow, 'field' | 'id'>>;
3985
+ /**
3986
+ * The field-config rows the saved layout would answer if these placements
3987
+ * were it (at most 2000): the editor's canvas renders its unsaved draft
3988
+ * through this. A read; writes nothing. Admin only.
3989
+ */
3990
+ declare function projectFieldConfig(collection: string, assignments: ProjectedPlacement[]): Command<{
3991
+ data: Array<Record<string, unknown>>;
3992
+ ungrouped_sort: number | null;
3993
+ }>;
3994
+ /** The layouts that place an internal widget: a config change reaches every one. Admin only. */
3995
+ declare function listInternalWidgetPlacements(widgetId: number): Command<{
3996
+ data: Array<{
3997
+ layout_id: number;
3998
+ name: string;
3999
+ collection: string;
4000
+ }>;
4001
+ }>;
4002
+ /** Is a record excluded from relation pickers? */
4003
+ declare function readPickerExclusion(collection: string, itemId: string | number): Command<{
4004
+ data: {
4005
+ excluded: boolean;
4006
+ };
4007
+ }>;
4008
+ /** Which of these ids are excluded from pickers? */
4009
+ declare function readPickerExclusions(collection: string, ids: Array<string | number>): Command<{
4010
+ data: {
4011
+ excluded: string[];
4012
+ };
4013
+ }>;
4014
+ /** Exclude a record from relation pickers. */
4015
+ declare function excludeFromPickers(body: {
4016
+ collection: string;
4017
+ item_id: string | number;
4018
+ layout?: string | null;
4019
+ }): Command<{
4020
+ data: {
4021
+ excluded: true;
4022
+ };
4023
+ }>;
4024
+ /** Put a record back into relation pickers. */
4025
+ declare function includeInPickers(body: {
4026
+ collection: string;
4027
+ item_id: string | number;
4028
+ layout?: string | null;
4029
+ }): Command<{
4030
+ data: {
4031
+ excluded: false;
4032
+ };
4033
+ }>;
4034
+
3670
4035
  /**
3671
4036
  * Developer-experience commands: dev-tools exports, webhook deliveries,
3672
4037
  * persisted GraphQL queries, saved views, global search, API keys,
@@ -4000,20 +4365,34 @@ declare function retryDeadLetter(runId: string): Command<{
4000
4365
  retried: string;
4001
4366
  };
4002
4367
  }>;
4368
+ type CollectionLayoutType = 'grouped' | 'summary' | 'detail' | 'file' | 'addendum' | 'table';
4003
4369
  interface CollectionLayout {
4004
4370
  id: number;
4005
4371
  collection: string;
4006
4372
  name: string;
4373
+ slug?: string | null;
4374
+ layout_type?: CollectionLayoutType | (string & {});
4007
4375
  is_active: boolean | number;
4008
4376
  sort: number;
4009
4377
  created_at: string;
4378
+ /** Show in the New-item menu; clones start hidden until an admin opts in. */
4379
+ create_hidden?: boolean | number;
4380
+ create_label?: string | null;
4010
4381
  tab_mode?: 'tabs' | 'steps';
4011
4382
  validate_before_next?: boolean | number;
4012
4383
  summary_enabled?: boolean | number;
4384
+ /** @deprecated Retired: no longer writable; the API may still return it. */
4013
4385
  summary_show_all?: boolean | number;
4014
4386
  ai_enabled?: boolean | number;
4015
4387
  disable_comments?: boolean | number;
4016
4388
  disable_tasks?: boolean | number;
4389
+ disable_clone?: boolean | number;
4390
+ /** @deprecated Retired: replaced by `disable_clone`; no longer writable. */
4391
+ allow_clone?: boolean | number;
4392
+ /** @deprecated Retired: no longer writable. */
4393
+ addendum_lock_fields?: unknown;
4394
+ /** @deprecated Retired: no longer writable. */
4395
+ hide_actions_when_collapsed?: boolean | number;
4017
4396
  conditions?: {
4018
4397
  role_ids?: string[];
4019
4398
  } | null;
@@ -4025,6 +4404,15 @@ interface LayoutAssignment {
4025
4404
  label_override?: string | null;
4026
4405
  is_visible?: boolean | number;
4027
4406
  default_expanded?: boolean | number;
4407
+ /** Column span on the record page (slot cards size by it). */
4408
+ col_span?: number | null;
4409
+ lock_conditions?: string | null;
4410
+ overrides?: unknown;
4411
+ show_row_revisions?: boolean | number;
4412
+ show_approval_chain?: boolean | number;
4413
+ allow_revision_restore?: boolean | number | null;
4414
+ widget_id?: number | null;
4415
+ input_bindings?: unknown;
4028
4416
  }
4029
4417
  interface LayoutGroup {
4030
4418
  id: number;
@@ -4047,11 +4435,17 @@ declare function readCollectionLayouts(collection: string): Command<{
4047
4435
  data: CollectionLayout[];
4048
4436
  }>;
4049
4437
  /** Read the active layout for a collection with groups + assignments. */
4050
- declare function readActiveLayout(collection: string): Command<{
4438
+ declare function readActiveLayout(collection: string,
4439
+ /** `slug` pins a layout by link name; `item` resolves record-conditional layouts. */
4440
+ opts?: {
4441
+ slug?: string;
4442
+ item?: string | number;
4443
+ }): Command<{
4051
4444
  data: {
4052
4445
  layout: CollectionLayout;
4053
4446
  groups: LayoutGroup[];
4054
4447
  assignments: LayoutAssignment[];
4448
+ ungrouped_sort: number | null;
4055
4449
  };
4056
4450
  }>;
4057
4451
  /** Read groups for a specific layout by collection + layout id. */
@@ -4066,28 +4460,41 @@ declare function readLayoutAssignments(layoutId: number): Command<{
4066
4460
  declare function activateLayout(layoutId: number): Command<{
4067
4461
  data: CollectionLayout;
4068
4462
  }>;
4069
- /** Clone a layout under a new name. */
4070
- declare function cloneLayout(layoutId: number, name: string): Command<{
4463
+ /**
4464
+ * Clone a layout under a new name. The copy lands hidden from the New menu
4465
+ * (`create_hidden`) until an admin opts in; `layout_type` may differ from the source.
4466
+ */
4467
+ declare function cloneLayout(layoutId: number, name: string, opts?: {
4468
+ slug?: string | null;
4469
+ layout_type?: CollectionLayoutType;
4470
+ }): Command<{
4071
4471
  data: CollectionLayout;
4072
4472
  }>;
4073
- /** Create a new layout for a collection. */
4074
- declare function createCollectionLayout(collection: string, name: string): Command<{
4473
+ /**
4474
+ * Create a new layout for a collection. `seed_fields` starts it with one
4475
+ * "Main" section holding every visible field.
4476
+ */
4477
+ declare function createCollectionLayout(collection: string, name: string, opts?: {
4478
+ slug?: string | null;
4479
+ layout_type?: CollectionLayoutType;
4480
+ seed_fields?: boolean;
4481
+ }): Command<{
4075
4482
  data: CollectionLayout;
4076
4483
  }>;
4077
- /** Update layout behaviour/metadata. */
4078
- declare function updateCollectionLayout(layoutId: number, patch: Partial<Pick<CollectionLayout, 'name' | 'sort' | 'tab_mode' | 'validate_before_next' | 'summary_enabled' | 'summary_show_all' | 'ai_enabled' | 'disable_comments' | 'disable_tasks' | 'conditions'>>): Command<{
4484
+ /** Update layout behaviour/metadata (any of the settings in `LayoutPatch`). */
4485
+ declare function updateCollectionLayout(layoutId: number, patch: LayoutPatch): Command<{
4079
4486
  data: CollectionLayout;
4080
4487
  }>;
4081
4488
  declare function deleteCollectionLayout(layoutId: number): Command<void>;
4082
- /** Bulk-replace a layout's field→group assignments (and slot sentinels). */
4489
+ /**
4490
+ * Bulk-replace a layout's field→group assignments (and slot sentinels).
4491
+ * The layout editor saves through `submitLayoutOps` instead.
4492
+ */
4083
4493
  declare function updateLayoutAssignments(layoutId: number, assignments: Array<{
4084
4494
  field: string;
4085
4495
  group_key: string | null;
4086
4496
  sort: number;
4087
- label_override?: string | null;
4088
- is_visible?: boolean;
4089
- default_expanded?: boolean;
4090
- }>): Command<{
4497
+ } & PlacementPatch>): Command<{
4091
4498
  data: LayoutAssignment[];
4092
4499
  }>;
4093
4500
  interface InternalWidget {
@@ -6962,12 +7369,15 @@ interface PickerExclusionStatus {
6962
7369
  }
6963
7370
  /**
6964
7371
  * Check whether a specific item is excluded from relation pickers.
7372
+ * @deprecated Use `readPickerExclusion` (commands/layout-editor).
6965
7373
  */
6966
7374
  declare function getPickerExclusionStatus(collection: string, itemId: string): Command<{
6967
7375
  data: PickerExclusionStatus;
6968
7376
  }>;
6969
7377
  /**
6970
7378
  * Exclude an item from appearing in relation pickers across the admin UI.
7379
+ * @deprecated Use `excludeFromPickers`, which can pass the record's `layout` so a
7380
+ * non-admin whose form grants it may call it.
6971
7381
  */
6972
7382
  declare function excludeFromPicker(collection: string, itemId: string): Command<{
6973
7383
  data: {
@@ -6976,6 +7386,7 @@ declare function excludeFromPicker(collection: string, itemId: string): Command<
6976
7386
  }>;
6977
7387
  /**
6978
7388
  * Remove a picker exclusion — the item will appear in relation pickers again.
7389
+ * @deprecated Use `includeInPickers`, which can pass the record's `layout`.
6979
7390
  */
6980
7391
  declare function includeInPicker(collection: string, itemId: string): Command<{
6981
7392
  data: {
@@ -6985,6 +7396,7 @@ declare function includeInPicker(collection: string, itemId: string): Command<{
6985
7396
  /**
6986
7397
  * Check exclusion status for multiple items in one call.
6987
7398
  * Returns the list of ids that ARE excluded.
7399
+ * @deprecated Use `readPickerExclusions` (commands/layout-editor).
6988
7400
  */
6989
7401
  declare function batchPickerExclusionStatus(collection: string, ids: string[]): Command<{
6990
7402
  data: {
@@ -7940,4 +8352,4 @@ declare function submitFormItem(collection: string, values: Record<string, unkno
7940
8352
  data: Record<string, unknown>;
7941
8353
  }>;
7942
8354
 
7943
- export { type AccessAudit, type AccessAuditFinding, type AccessAuditRun, type AccessAuditSubject, type AccessReason, type ActivityEntry, type ActivityQuery, type ActivityReportQuery, type ActivityReportRow, type ActivityReportSummary, type Addendum, type AddendumStatus, type AggregateQuery, type AggregateRow, type AiChatTraceEntry, type AiCollectionSettings, type AiColumnMapping, type AiDuplicateMatch, type AiQueryFilter, type AiQueryResult, type AiReviewFinding, type AiViolation, type AlertDefinition, type AlertLogEntry, type AlertSubscription, type AnomalyDefinition, type AnomalyRule, type ApiAnalyticsBucket, type ApiAnalyticsCollection, type ApiAnalyticsPath, type ApiAnalyticsSummary, type ApiErrorLog, type ApiKey, type ApiKeyScope, type ApprovalBrief, type ApprovalChain, type ApprovalChainStep, type ApprovalDecision, type ApprovalInstance, type ApprovalInstanceDetail, type ApprovalStatus, type ApprovalStepInput, type AtRiskCondition, type AtRiskOp, type AtRiskResult, type AtRiskRule, type AtRiskSummaryEntry, type AttributeDefinition, type AttributeValue, type BatchRead, type BatchReadResult, type BlackoutDate, type BoolFilterOps, type CMSCollection, type CascadeFilterRule, type ChangeOrder, type ChatChannel, type ChatChannelMember, type ChatDirectoryChannel, type ChatMessage, type ChatPin, type ChatReaction, type ChatRoomKind, type ChatRoomSummary, type ChatRoomType, type ChatSearchHit, type CollectionLayout, type CollectionPresetSummary, type Command, type Comment, type CommentVersion, type ConfigSnapshot, type ConfigTableClassification, type ContentBundle, type ContentExportFormat, type ContentExportOptions, type CoverageGapItem, type CoverageGapOwner, type CoverageGapReport, type CpuProfileSummary, type CronJob, type CustomQuery, type CustomQueryCatalogEntry, type DataQualityRule, type DataQualityRuleResult, type DataQualityRuleType, type DataQualityRun, type DataQualitySeverity, type DeadLetter, type DmvResult, type DraftPublishConfig, type DraftStatus, type DryRunReport, type ErpSubmission, type ErpSubmissionStatus, type ExpensiveStatement, type ExtensionManifest, type ExternalApi, type ExternalApiEndpoint, type ExternalApiSchema, type ExternalApiSlotContext, type ExternalApiSpecImportResult, type ExternalApiTestResult, type FieldChangeEntry, type FieldCondition, type FieldConfig, type FieldDependencyConfig, type FieldFilter, type FieldGroup, type FieldTranslations, type FieldVisibilityRules, type FieldWatch, type FileRecord, type FileUploadResult, type FileUsageEntry, type Filter, type FlowReplayResult, type FlowRun, type FlowTestStep, type FormFieldDescriptor, type FormFieldRelation, type FormGroupDescriptor, type FormLockCondition, type FormSchema, type FormValidationRule, type FormVisibilityRule, type GlobalSearchRecord, type GlobalSearchResults, type GraphQLResponse, type HealthDetailed, type HelpVideo, type HelpVideoClick, type HelpVideoContext, type HelpVideoDownloadUrls, type HelpVideoFinalizedUpload, type HelpVideoProgress, type HelpVideoUploadSession, type HelpVideoVersion, type HelpVideoVisibility, type HelpVideoWalkStep, type HelpVideoWhatsNew, type HierarchyConfigDef, type HierarchyFlatNode, type HierarchyLevelDef, type HierarchyNestedNode, type IDFilterOps, type ISODate, type ImportDefinition, type ImportJob, type ImportParseResponse, type ImportPreview, type ImportPreviewDiff, type ImportTemplateSummary, type InstanceOwner, type IntegrationApiHealth, type InternalWidget, type Issue, type IssueSeverity, type IssueStatus, type IssueSummary, type ItemLock, type JobRegistryCron, type JobRun, type LastTouch, type LayoutAssignment, type LayoutGroup, type LayoutVersion, type ListResponse, type ManagedUser, type MetricAlertRule, type MetricAlertSubscription, type MetricDefinition, type MyTask, type MyWorkOwnedEntry, type MyWorkSla, type MyWorkSummary, type NivaroClient, type NivaroClientOptions, type NivaroExtensionPlugin, type NivaroRealtime, type NivaroRuntime, type NotificationItem, type NotificationPage, type NotificationSubscription, type NumberFilterOps, type OmniSearchHit, type OnlinePresenceConfig, type OnlinePresenceUser, type Page, type PageLayout, type PageSlotKey, type PageWidget, type PdfTemplate, type PermissionSimulation, type PersistedQuery, type PickerExclusionStatus, type PipelineFlowEdge, type PipelineFlowState, type PipelineImpactResult, type PipelineOwnerGroup, type PipelineOwnerGroupUser, type PipelineSimulation, type PipelineState, type PipelineVersionEntry, type PluginSlots, type Policy, type PoolStats, type PreflightCheck, type PreflightReport, type PreflightSeverity, type PresenceClient, type PresenceOptions, type PresenceSession, type PresenceSessionInfo, type PresenceViewer, type PromotionApplyResult, type PromotionPreview, type Query, type Queue, type QueueColumnPrefs, type QueueCondition, type QueueDetail, type QueueDisplayConfig, type QueueItem, type QueueItemsResult, type QueueOwner, type QueueRowClickMode, type QueueScope, type QueueSource, type QueueSourceType, type QueueStats, type QueueTrendPoint, type QueueView, type QueueViewKind, type QueueWorkloadRow, READ_MANY_MAX, type ReadyReport, type RealtimeEvent, type RecordGraphEdge, type RecordGraphNode, type RecordLink, type RecordLinkType, type RecordTemplate, type RecordViewRecap, type RegisteredAction, type RelatedCommentEntry, type RelationFilter, type RelationOption, type ReportAlert, type ReportAlertCondition, type ReportAlertLogEntry, type ReportAnnotation, type ReportColumnFormat, type ReportDateRange, type ReportDef, type ReportEntityFilter, type ReportFilterPreset, type ReportQueryColumn, type ReportQueryWidgetConfig, type ReportSnapshotEntry, type ReportSubscription, type ReportTemplateEntry, type ReportVersionEntry, type ReportWidget, type ReportWidgetConfig, type ReportWidgetData, type ReportWidgetPreset, type ReportWidgetType, type RequestTrace, type ResolvedOwner, type RetentionPolicy, type RetentionRun, type RetentionRunResult, type Revision, type Role, type Rule, type RuntimeStats, type SavedView, type ScheduledChange, type ScheduledReport, type ScopeDimension, type ScopeDimensionInfo, type SemanticSearchMatch, type SessionRecording, type SessionReplayMasking, type ShareLink, type SlaBatchStatus, type SlaRule, type SlaStatus, type StagedImportRun, type StagedImportStats, type StringFilterOps, type SubRow, type SubRowTemplate, type SyncJob, type Task, type TaskDoneWhenRule, type TaskPriority, type TaskStatus, type TimelineEvent, type TraceSpan, type TrafficSnapshot, type TrafficSnapshotEntity, type TreeFlatNode, type TreeNestedNode, type TreeNodeConfig, type TreePermission, type TreePermissionAction, type UUID, type UserActivityEntry, type UserActivitySummary, type UserScopesInfo, type ViewSubscription, type VirtualCollection, type Webhook, type WebhookDelivery, type WidgetFeed, type WorkflowBinding, type WorkflowHistoryEntry, type WorkflowInstance, type WorkflowInstanceData, type WorkflowState, type WorkflowTransition, type Workspace, type WorkspaceQuotas, type WorkspaceTemplate, type WorkspaceUsage, _and, _contains, _ends_with, _eq, _gt, _gte, _in, _lt, _lte, _ncontains, _neq, _nin, _nnull, _none, _null, _or, _some, _starts_with, abandonHelpVideoUpload, acquireItemLock, activateLayout, addChatChannelMember, addInstanceOwner, addSubRow, aggregateItems, aiBrief, aiBuildReport, aiChat, aiCheckDuplicates, aiGenerate, aiMapColumns, aiQuery, aiReportFilters, aiReview, aiSummarize, aiValidate, appendSessionRecordingEvents, applyContentBundle, applyHelpVideoPackageImport, applyRecordTemplate, applySubRowTemplate, approveAddendum, approveAiProposal, archiveHelpVideo, asc, backupExportPath, batchPickerExclusionStatus, bulkPickerExclusion, callExternalApi, callExternalApiEndpoint, cancelScheduledChange, cancelStagedImport, captureCpuProfile, cascadeFieldDependencies, checkBlackoutDate, claimQueueItem, claimTask, clearTraces, cloneItem, cloneLayout, cloneReport, compareConfigSnapshot, completeTask, copyReportWidget, createAccessAudit, createAddendum, createAlertDefinition, createAlertSubscription, createAnomalyRule, createApiKey, createApprovalChain, createAtRiskRule, createAttributeDefinition, createBlackoutDate, createChatChannel, createChatRoomType, createCollectionLayout, createComment, createDataQualityRule, createExternalApi, createExternalApiEndpoint, createFieldGroup, createFieldWatch, createGroupDm, createHelpVideo, createHierarchyConfig, createImportDefinition, createImportJob, createImportJobFromUrl, createInternalWidget, createIssue, createItem, createMetricAlertRule, createNivaro, createNotification, createNotificationSubscription, createPage, createPdfTemplate, createPersistedQuery, createPresence, createQueue, createQueueView, createRealtime, createRecordLink, createRecordTemplate, createReport, createReportAlert, createReportAnnotation, createReportFromTemplate, createReportSnapshot, createReportWidgetPreset, createRetentionPolicy, createRole, createRolePolicy, createRule, createSavedView, createScheduledChange, createScheduledReport, createShareLink, createSlaRule, createSubRowTemplate, createSyncJob, createTask, createTreePermission, createUser, createViewSubscription, createVirtualCollection, createWebhook, createWidgetFeed, createWorkspace, createWorkspaceTemplate, decideApproval, deleteAccessAudit, deleteAddendum, deleteAlertDefinition, deleteAlertSubscription, deleteAnomalyRule, deleteApiKey, deleteApprovalChain, deleteAtRiskRule, deleteAttributeDefinition, deleteBlackoutDate, deleteChatMessage, deleteCollectionLayout, deleteComment, deleteDataQualityRule, deleteExternalApi, deleteExternalApiEndpoint, deleteExternalApiSchema, deleteFieldGroup, deleteFieldTranslations, deleteFieldWatch, deleteFile, deleteHierarchyConfig, deleteImportJob, deleteInternalWidget, deleteIssue, deleteItem, deleteMetricAlertRule, deleteNotification, deleteNotificationSubscription, deletePage, deletePdfTemplate, deletePersistedQuery, deleteQueue, deleteQueueView, deleteRecordLink, deleteRecordTemplate, deleteReport, deleteReportAlert, deleteReportAnnotation, deleteReportFilterPreset, deleteReportSnapshot, deleteReportTemplate, deleteReportWidgetPreset, deleteRetentionPolicy, deleteRole, deleteRolePolicy, deleteRule, deleteSavedView, deleteScheduledReport, deleteSessionRecording, deleteSlaRule, deleteSubRow, deleteSubRowTemplate, deleteSyncJob, deleteTask, deleteTreePermission, deleteUser, deleteViewSubscription, deleteVirtualCollection, deleteWebhook, deleteWidgetFeed, deleteWorkspace, deleteWorkspaceTemplate, deployImportProcedure, desc, disableTwoFactor, discardHelpVideoPackageImport, drillReportRow, editChatMessage, endSessionRecording, evaluateAlerts, evaluateAtRisk, evaluateFieldDefaults, evaluateFieldLock, evaluateFieldRules, evaluateFieldVisibility, excludeFromPicker, executeBulkAction, executeCustomQuery, executeImportTemplate, executeItemAction, executeScheduledChange, explainRecordAccess, explainReportTrend, exportBlueprint, exportConfigSnapshot, exportContent, exportContentBundle, exportHelpVideoPackage, exportSchemaSnapshot, fetchFormSchema, fileDownloadPath, fileTransformPath, finalizeHelpVideoUpload, generateToken, generateUserToken, getAlertDefinition, getAttributeValues, getBrunoCollection, getCommentHistory, getExternalApi, getExternalApiEndpoint, getFieldTranslations, getFlowRun, getLocales, getOpenApi, getPickerExclusionStatus, getPostmanCollection, getPresence, getRetentionPolicy, getSlaRule, getSlaStatus, getTranslations, getTypes, getWebhook, globalSearch, heartbeatItemLock, helpVideosFor, importExternalApiSpec, importSchemaSnapshot, includeInPicker, installBlueprint, installCollectionPreset, invokeInternalWidgetAction, isPageSlot, joinChatRoom, leaveChatRoom, listAccessAuditRuns, listAccessAudits, listActiveAtRiskRules, listActivePresence, listAddendums, listAlertDefinitions, listAlertSubscriptions, listAllNotificationSubscriptions, listAnomalyDefinitions, listAnomalyRules, listApiKeys, listApprovalChains, listApprovalInstances, listAtRiskRules, listAttributeDefinitions, listBlackoutDates, listBulkActions, listChangeOrders, listChatChannelMembers, listChatMessages, listChatPins, listChatRoles, listChatRoomTypes, listChatRooms, listCollectionPresets, listCollectionRecordTemplates, listComments, listCronJobs, listCustomQueries, listCustomQueryCatalog, listDataQualityRules, listDataQualityRuns, listDeadLetters, listExternalApiEndpoints, listExternalApiSchemas, listExternalApis, listFieldGroups, listFieldWatches, listFiles, listFlowRuns, listHelpVideoPages, listHelpVideoVersions, listHelpVideos, listHierarchyConfigs, listImportDefinitionVersions, listImportDefinitions, listImportJobs, listImportTemplates, listInternalWidgets, listIssues, listItemActions, listItemScheduledChanges, listJobRuns, listLayoutVersions, listMetricAlertRules, listMetricAlertSubscriptions, listMetricDefinitions, listMyHelpVideoUploads, listMyTasks, listNotificationSubscriptions, listNotifications, listOrphanFiles, listPages, listPdfTemplates, listPersistedQueries, listPinnedItems, listPipelineVersions, listQueueViews, listQueues, listRecordLinks, listRecordTemplates, listRegisteredExtensions, listRegisteredFlowOperations, listRegisteredFlowTriggers, listRelatedComments, listReportAlerts, listReportAnnotations, listReportFilterPresets, listReportSnapshots, listReportTemplates, listReportVersions, listReportWidgetPresets, listReports, listRequestedTasks, listRetentionPolicies, listRetentionRuns, listRolePolicies, listRoleUsers, listRoles, listRules, listSavedViews, listScheduledChanges, listScheduledReports, listScopeDimensions, listSessionRecordings, listShareLinks, listSlaRules, listStagedImports, listSubRowTemplates, listSubRows, listSyncJobs, listTasks, listTeamTasks, listThroughputCollections, listTraces, listTreePermissions, listViewSubscriptions, listVirtualCollections, listWebhookDeliveries, listWebhooks, listWidgetFeeds, listWorkspaceTemplates, listWorkspaces, markAllNotificationsRead, markChatRoomRead, markNotificationRead, markNotificationsRead, moveTreeNode, nudgeTask, omniSearch, openHelpVideoPackageImport, openHelpVideoUpload, presignFileUpload, previewContentBundle, previewHelpVideoPackageImport, previewImportJob, previewReportWidget, publishHelpVideo, publishItem, queryVirtualCollection, readAccessAuditFindings, readActiveLayout, readActivity, readActivityReportSummary, readAddendum, readAiSettings, readAlertLog, readAllStateOwners, readAnomalyLog, readApiAnalyticsErrors, readApiAnalyticsSummary, readApiAnalyticsTimeseries, readApiAnalyticsTopCollections, readApiAnalyticsTopPaths, readApiKey, readApprovalBrief, readApprovalChain, readAtRiskSummary, readBackupManifest, readChatConfig, readChatDirectory, readChatPeerRead, readCollection, readCollectionLayout, readCollectionLayouts, readCollections, readConfigInventory, readCoverageGaps, readDataQualityRun, readDbPool, readDetailLayout, readDistinctValues, readDraftPublishConfig, readErpSubmissionHistory, readExpensiveSql, readFieldChangeHistory, readFieldConfig, readFieldImpact, readFieldWatch, readFileMeta, readFileUsage, readFilesByIds, readHealthDetailed, readHelpVideo, readHelpVideoAnalytics, readHelpVideoDownloadLink, readHelpVideoDraft, readHelpVideoWalk, readHierarchyConfig, readHierarchyNodeAncestors, readHierarchyNodeChildren, readHierarchyNodes, readHierarchyTree, readImportJob, readImportProcedure, readInstanceOwners, readInstanceRoster, readIntegrationHealth, readInternalWidget, readIssue, readIssueSummary, readItem, readItemLock, readItemLockConfig, readItems, readJobRegistry, readLastTouch, readLayoutAssignments, readLayoutGroups, readMany, readMe, readMetricAlertLog, readMyScopes, readMyWork, readNotificationCount, readNotificationSubscriptionStats, readOnlinePresence, readOwnerGroups, readPage, readPageWidgetData, readPdfTemplate, readPersistedQuery, readPipelineFlowMap, readPipelineReplay, readPipelineTemplate, readPipelineTemplates, readPipelineVersion, readPreflight, readQueue, readQueueCollectionStates, readQueueColumnPrefs, readQueueItems, readQueueTrends, readQueueWorkload, readReadiness, readRecordGraph, readRelationOptions, readReport, readReportAlertLog, readReportAlertsLog, readReportFilterOptions, readReportFiring, readReportSnapshot, readReportSubscription, readReportUsage, readReportWidgetData, readRequiredHelpVideos, readRevision, readRevisions, readRole, readRuntimeStats, readScopeDimensionCoverage, readSessionRecordingEvents, readSettings, readSingleton, readSlaStatusBatch, readStagedImport, readStagedImportStats, readStateOwnerGroups, readStateOwners, readStateOwnersBatch, readSyncJob, readTask, readTaskCounts, readTaskHistory, readThroughputReport, readTimeline, readTrace, readTrafficSnapshot, readTreeAncestors, readTreeChildren, readTreeConfig, readTreeDescendants, readTreeNested, readTreeNodes, readTwoFactorStatus, readUnreadNotificationCount, readUser, readUserActivity, readUserActivitySummary, readUserCard, readUserScopes, readUsers, readWorkflowBindings, readWorkflowInstance, readWorkflowInstances, readWorkspace, readWorkspaceUsage, rebuildTreePaths, recordHelpVideoProgress, registerHelpVideoPage, rehearseCreateItem, reindexSemanticSearch, rejectAddendum, rejectAiProposal, releaseItemLock, releaseQueueItem, rematerializeQueue, removeChatChannelMember, removeInstanceOwner, renderInternalWidget, renderPdfTemplate, reorderFieldGroups, reorderSubRows, reorderTreeSiblings, replaceSubRows, replayActivityEvent, replayFlow, reportClientError, requestRecordAccess, requeueStagedImport, rerecordHelpVideo, rerenderHelpVideo, resetReportCache, resolveReportAlert, restoreHelpVideoVersion, restoreImportDefinitionVersion, restoreLayoutVersion, restorePipelineVersion, restoreReportVersion, retryDeadLetter, retryErpSubmission, retryWebhookDelivery, revokeApiKey, revokeShareLink, revokeToken, revokeUserToken, rollbackRevision, rotateWidgetFeedToken, runAccessAudit, runActivityReport, runActivityReportCsv, runCronJob, runDataQuality, runRetentionPolicy, runScheduledReport, runSyncJob, saveHelpVideoDraft, saveMyScopeDefaults, saveReportFilterPreset, saveReportTemplate, saveReportWidgets, saveUserScope, searchChatMessages, semanticSearch, sendBulkNotification, sendChatMessage, sendTestMail, sessionRecordingEnabled, setHelpVideoContexts, setHelpVideoRequirements, setMyDelegate, setQueueDefaultView, setReportSubscription, setTranslations, setupTwoFactor, simulatePermissions, simulatePipeline, simulatePipelineImpact, startApproval, startMasquerade, startSessionRecording, startWorkflow, stopMasquerade, submitAddendum, submitFormItem, submitItemForReview, submitToErp, subscribeFieldWatch, subscribeMetricAlert, suggestImportValidation, suggestQueueLabels, switchWorkspace, testExternalApi, testFlow, testWebhook, toggleChatPin, toggleChatReaction, togglePinnedItem, toggleReportAlert, touchRecordView, transitionWorkflow, unpublishItem, unsubscribeFieldWatch, unsubscribeMetricAlert, updateAccessAudit, updateAddendum, updateAiSettings, updateAlertDefinition, updateAnomalyLogEntry, updateAnomalyRule, updateApiKey, updateApprovalChain, updateAtRiskRule, updateAttributeDefinition, updateAttributeValues, updateChatChannel, updateChatRoom, updateChatRoomType, updateCollectionLayout, updateComment, updateDataQualityRule, updateDraftPublishConfig, updateErpSubmissionStatus, updateExternalApi, updateExternalApiEndpoint, updateFieldConfig, updateFieldGroup, updateFieldWatch, updateFileMeta, updateHelpVideo, updateHierarchyConfig, updateImportDefinition, updateInternalWidget, updateIssue, updateItem, updateItemLockConfig, updateLayoutAssignments, updateLayoutUngroupedSort, updateMe, updateMetricAlertRule, updateMetricAlertSubscription, updateNotificationSubscription, updatePage, updatePdfTemplate, updatePersistedQuery, updateQueue, updateQueueSources, updateQueueView, updateRecordTemplate, updateReport, updateReportAlert, updateReportWidgetPreset, updateRetentionPolicy, updateRole, updateRolePolicy, updateRoleUiPermissions, updateRule, updateSavedView, updateScheduledReport, updateSettings, updateSingleton, updateSlaRule, updateSyncJob, updateTask, updateTreePermission, updateUser, updateVirtualCollection, updateWebhook, updateWidgetFeed, updateWorkflowBinding, updateWorkspace, validateVirtualCollectionSql, verifyTwoFactor };
8355
+ export { type AccessAudit, type AccessAuditFinding, type AccessAuditRun, type AccessAuditSubject, type AccessReason, type ActivityEntry, type ActivityQuery, type ActivityReportQuery, type ActivityReportRow, type ActivityReportSummary, type Addendum, type AddendumStatus, type AggregateQuery, type AggregateRow, type AiChatTraceEntry, type AiCollectionSettings, type AiColumnMapping, type AiDuplicateMatch, type AiQueryFilter, type AiQueryResult, type AiReviewFinding, type AiViolation, type AlertDefinition, type AlertLogEntry, type AlertSubscription, type AnomalyDefinition, type AnomalyRule, type ApiAnalyticsBucket, type ApiAnalyticsCollection, type ApiAnalyticsPath, type ApiAnalyticsSummary, type ApiErrorLog, type ApiKey, type ApiKeyScope, type ApprovalBrief, type ApprovalChain, type ApprovalChainStep, type ApprovalDecision, type ApprovalInstance, type ApprovalInstanceDetail, type ApprovalStatus, type ApprovalStepInput, type AtRiskCondition, type AtRiskOp, type AtRiskResult, type AtRiskRule, type AtRiskSummaryEntry, type AttributeDefinition, type AttributeValue, type BatchRead, type BatchReadResult, type BlackoutDate, type BoolFilterOps, type CMSCollection, type CascadeFilterRule, type ChangeOrder, type ChatChannel, type ChatChannelMember, type ChatDirectoryChannel, type ChatMessage, type ChatPin, type ChatReaction, type ChatRoomKind, type ChatRoomSummary, type ChatRoomType, type ChatSearchHit, type CollectionLayout, type CollectionLayoutType, type CollectionPresetSummary, type Command, type Comment, type CommentVersion, type ConfigSnapshot, type ConfigTableClassification, type ContentBundle, type ContentExportFormat, type ContentExportOptions, type CoverageGapItem, type CoverageGapOwner, type CoverageGapReport, type CpuProfileSummary, type CronJob, type CustomQuery, type CustomQueryCatalogEntry, type DataQualityRule, type DataQualityRuleResult, type DataQualityRuleType, type DataQualityRun, type DataQualitySeverity, type DeadLetter, type DmvResult, type DraftPublishConfig, type DraftStatus, type DryRunReport, type ErpSubmission, type ErpSubmissionStatus, type ExpensiveStatement, type ExtensionManifest, type ExternalApi, type ExternalApiEndpoint, type ExternalApiSchema, type ExternalApiSlotContext, type ExternalApiSpecImportResult, type ExternalApiTestResult, type FieldChangeEntry, type FieldCondition, type FieldConfig, type FieldDependencyConfig, type FieldFilter, type FieldGroup, type FieldTranslations, type FieldVisibilityRules, type FieldWatch, type FileRecord, type FileUploadResult, type FileUsageEntry, type Filter, type FlowReplayResult, type FlowRun, type FlowTestStep, type FormFieldDescriptor, type FormFieldRelation, type FormGroupDescriptor, type FormLockCondition, type FormSchema, type FormValidationRule, type FormVisibilityRule, GROUP_PATCH_KEYS, type GlobalSearchRecord, type GlobalSearchResults, type GraphQLResponse, type GroupPatch, type GroupRow, type HealthDetailed, type HelpVideo, type HelpVideoClick, type HelpVideoContext, type HelpVideoDownloadUrls, type HelpVideoFinalizedUpload, type HelpVideoProgress, type HelpVideoUploadSession, type HelpVideoVersion, type HelpVideoVisibility, type HelpVideoWalkStep, type HelpVideoWhatsNew, type HierarchyConfigDef, type HierarchyFlatNode, type HierarchyLevelDef, type HierarchyNestedNode, type IDFilterOps, type ISODate, type ImportDefinition, type ImportJob, type ImportParseResponse, type ImportPreview, type ImportPreviewDiff, type ImportTemplateSummary, type InstanceOwner, type IntegrationApiHealth, type InternalWidget, type Issue, type IssueSeverity, type IssueStatus, type IssueSummary, type ItemLock, type JobRegistryCron, type JobRun, LAYOUT_PATCH_KEYS, type LastTouch, type LayoutAssignment, type LayoutBundle, type LayoutGroup, type LayoutOp, type LayoutOverviewRow, type LayoutPatch, type LayoutPickReason, type LayoutRow, type LayoutVersion, type ListResponse, type ManagedUser, type MetricAlertRule, type MetricAlertSubscription, type MetricDefinition, type MyTask, type MyWorkOwnedEntry, type MyWorkSla, type MyWorkSummary, type NivaroClient, type NivaroClientOptions, type NivaroExtensionPlugin, type NivaroRealtime, type NivaroRuntime, type NotificationItem, type NotificationPage, type NotificationSubscription, type NumberFilterOps, type OmniSearchHit, type OnlinePresenceConfig, type OnlinePresenceUser, PLACEMENT_PATCH_KEYS, type Page, type PageLayout, type PageSlotKey, type PageWidget, type PdfTemplate, type PermissionSimulation, type PersistedQuery, type PickerExclusionStatus, type PipelineFlowEdge, type PipelineFlowState, type PipelineImpactResult, type PipelineOwnerGroup, type PipelineOwnerGroupUser, type PipelineSimulation, type PipelineState, type PipelineVersionEntry, type PlacementKey, type PlacementPatch, type PlacementRow, type PluginSlots, type Policy, type PoolStats, type PreflightCheck, type PreflightReport, type PreflightSeverity, type PresenceClient, type PresenceOptions, type PresenceSession, type PresenceSessionInfo, type PresenceViewer, type ProjectedPlacement, type PromotionApplyResult, type PromotionPreview, type Query, type Queue, type QueueColumnPrefs, type QueueCondition, type QueueDetail, type QueueDisplayConfig, type QueueItem, type QueueItemsResult, type QueueOwner, type QueueRowClickMode, type QueueScope, type QueueSource, type QueueSourceType, type QueueStats, type QueueTrendPoint, type QueueView, type QueueViewKind, type QueueWorkloadRow, READ_MANY_MAX, type ReadyReport, type RealtimeEvent, type RecordGraphEdge, type RecordGraphNode, type RecordLink, type RecordLinkType, type RecordTemplate, type RecordViewRecap, type RegisteredAction, type RelatedCommentEntry, type RelationFilter, type RelationOption, type ReportAlert, type ReportAlertCondition, type ReportAlertLogEntry, type ReportAnnotation, type ReportColumnFormat, type ReportDateRange, type ReportDef, type ReportEntityFilter, type ReportFilterPreset, type ReportQueryColumn, type ReportQueryWidgetConfig, type ReportSnapshotEntry, type ReportSubscription, type ReportTemplateEntry, type ReportVersionEntry, type ReportWidget, type ReportWidgetConfig, type ReportWidgetData, type ReportWidgetPreset, type ReportWidgetType, type RequestTrace, type ResolvedOwner, type RetentionPolicy, type RetentionRun, type RetentionRunResult, type Revision, type Role, type Rule, type RuntimeStats, type SavedView, type ScheduledChange, type ScheduledReport, type ScopeDimension, type ScopeDimensionInfo, type SemanticSearchMatch, type SessionRecording, type SessionReplayMasking, type ShareLink, type SlaBatchStatus, type SlaRule, type SlaStatus, type StagedImportRun, type StagedImportStats, type StringFilterOps, type SubRow, type SubRowTemplate, type SyncJob, type Task, type TaskDoneWhenRule, type TaskPriority, type TaskStatus, type TimelineEvent, type TraceSpan, type TrafficSnapshot, type TrafficSnapshotEntity, type TreeFlatNode, type TreeNestedNode, type TreeNodeConfig, type TreePermission, type TreePermissionAction, type UUID, type UserActivityEntry, type UserActivitySummary, type UserScopesInfo, type ViewSubscription, type VirtualCollection, type Webhook, type WebhookDelivery, type WidgetFeed, type WorkflowBinding, type WorkflowHistoryEntry, type WorkflowInstance, type WorkflowInstanceData, type WorkflowState, type WorkflowTransition, type Workspace, type WorkspaceQuotas, type WorkspaceTemplate, type WorkspaceUsage, _and, _contains, _ends_with, _eq, _gt, _gte, _in, _lt, _lte, _ncontains, _neq, _nin, _nnull, _none, _null, _or, _some, _starts_with, abandonHelpVideoUpload, acquireItemLock, activateLayout, addChatChannelMember, addInstanceOwner, addSubRow, aggregateItems, aiBrief, aiBuildReport, aiChat, aiCheckDuplicates, aiGenerate, aiMapColumns, aiQuery, aiReportFilters, aiReview, aiSummarize, aiValidate, appendSessionRecordingEvents, applyContentBundle, applyHelpVideoPackageImport, applyRecordTemplate, applySubRowTemplate, approveAddendum, approveAiProposal, archiveHelpVideo, asc, backupExportPath, batchPickerExclusionStatus, bulkPickerExclusion, callExternalApi, callExternalApiEndpoint, cancelScheduledChange, cancelStagedImport, captureCpuProfile, cascadeFieldDependencies, checkBlackoutDate, claimQueueItem, claimTask, clearTraces, cloneItem, cloneLayout, cloneReport, compareConfigSnapshot, completeTask, copyReportWidget, createAccessAudit, createAddendum, createAlertDefinition, createAlertSubscription, createAnomalyRule, createApiKey, createApprovalChain, createAtRiskRule, createAttributeDefinition, createBlackoutDate, createChatChannel, createChatRoomType, createCollectionLayout, createComment, createDataQualityRule, createExternalApi, createExternalApiEndpoint, createFieldGroup, createFieldWatch, createGroupDm, createHelpVideo, createHierarchyConfig, createImportDefinition, createImportJob, createImportJobFromUrl, createInternalWidget, createIssue, createItem, createMetricAlertRule, createNivaro, createNotification, createNotificationSubscription, createPage, createPdfTemplate, createPersistedQuery, createPresence, createQueue, createQueueView, createRealtime, createRecordLink, createRecordTemplate, createReport, createReportAlert, createReportAnnotation, createReportFromTemplate, createReportSnapshot, createReportWidgetPreset, createRetentionPolicy, createRole, createRolePolicy, createRule, createSavedView, createScheduledChange, createScheduledReport, createShareLink, createSlaRule, createSubRowTemplate, createSyncJob, createTask, createTreePermission, createUser, createViewSubscription, createVirtualCollection, createWebhook, createWidgetFeed, createWorkspace, createWorkspaceTemplate, decideApproval, deleteAccessAudit, deleteAddendum, deleteAlertDefinition, deleteAlertSubscription, deleteAnomalyRule, deleteApiKey, deleteApprovalChain, deleteAtRiskRule, deleteAttributeDefinition, deleteBlackoutDate, deleteChatMessage, deleteCollectionLayout, deleteComment, deleteDataQualityRule, deleteExternalApi, deleteExternalApiEndpoint, deleteExternalApiSchema, deleteFieldGroup, deleteFieldTranslations, deleteFieldWatch, deleteFile, deleteHierarchyConfig, deleteImportJob, deleteInternalWidget, deleteIssue, deleteItem, deleteMetricAlertRule, deleteNotification, deleteNotificationSubscription, deletePage, deletePdfTemplate, deletePersistedQuery, deleteQueue, deleteQueueView, deleteRecordLink, deleteRecordTemplate, deleteReport, deleteReportAlert, deleteReportAnnotation, deleteReportFilterPreset, deleteReportSnapshot, deleteReportTemplate, deleteReportWidgetPreset, deleteRetentionPolicy, deleteRole, deleteRolePolicy, deleteRule, deleteSavedView, deleteScheduledReport, deleteSessionRecording, deleteSlaRule, deleteSubRow, deleteSubRowTemplate, deleteSyncJob, deleteTask, deleteTreePermission, deleteUser, deleteViewSubscription, deleteVirtualCollection, deleteWebhook, deleteWidgetFeed, deleteWorkspace, deleteWorkspaceTemplate, deployImportProcedure, desc, diffLayoutVersion, disableTwoFactor, discardHelpVideoPackageImport, drillReportRow, editChatMessage, endSessionRecording, evaluateAlerts, evaluateAtRisk, evaluateFieldDefaults, evaluateFieldLock, evaluateFieldRules, evaluateFieldVisibility, excludeFromPicker, excludeFromPickers, executeBulkAction, executeCustomQuery, executeImportTemplate, executeItemAction, executeScheduledChange, explainLayout, explainRecordAccess, explainReportTrend, exportBlueprint, exportConfigSnapshot, exportContent, exportContentBundle, exportHelpVideoPackage, exportSchemaSnapshot, fetchFormSchema, fileDownloadPath, fileTransformPath, finalizeHelpVideoUpload, generateToken, generateUserToken, getAlertDefinition, getAttributeValues, getBrunoCollection, getCommentHistory, getExternalApi, getExternalApiEndpoint, getFieldTranslations, getFlowRun, getLocales, getOpenApi, getPickerExclusionStatus, getPostmanCollection, getPresence, getRetentionPolicy, getSlaRule, getSlaStatus, getTranslations, getTypes, getWebhook, globalSearch, heartbeatItemLock, helpVideosFor, importExternalApiSpec, importSchemaSnapshot, includeInPicker, includeInPickers, installBlueprint, installCollectionPreset, invokeInternalWidgetAction, isPageSlot, joinChatRoom, leaveChatRoom, listAccessAuditRuns, listAccessAudits, listActiveAtRiskRules, listActivePresence, listAddendums, listAlertDefinitions, listAlertSubscriptions, listAllNotificationSubscriptions, listAnomalyDefinitions, listAnomalyRules, listApiKeys, listApprovalChains, listApprovalInstances, listAtRiskRules, listAttributeDefinitions, listBlackoutDates, listBulkActions, listChangeOrders, listChatChannelMembers, listChatMessages, listChatPins, listChatRoles, listChatRoomTypes, listChatRooms, listCollectionPresets, listCollectionRecordTemplates, listComments, listCronJobs, listCustomQueries, listCustomQueryCatalog, listDataQualityRules, listDataQualityRuns, listDeadLetters, listExternalApiEndpoints, listExternalApiSchemas, listExternalApis, listFieldGroups, listFieldWatches, listFiles, listFlowRuns, listHelpVideoPages, listHelpVideoVersions, listHelpVideos, listHierarchyConfigs, listImportDefinitionVersions, listImportDefinitions, listImportJobs, listImportTemplates, listInternalWidgetPlacements, listInternalWidgets, listIssues, listItemActions, listItemScheduledChanges, listJobRuns, listLayoutVersions, listMetricAlertRules, listMetricAlertSubscriptions, listMetricDefinitions, listMyHelpVideoUploads, listMyTasks, listNotificationSubscriptions, listNotifications, listOrphanFiles, listPages, listPdfTemplates, listPersistedQueries, listPinnedItems, listPipelineVersions, listQueueViews, listQueues, listRecordLinks, listRecordTemplates, listRegisteredExtensions, listRegisteredFlowOperations, listRegisteredFlowTriggers, listRelatedComments, listReportAlerts, listReportAnnotations, listReportFilterPresets, listReportSnapshots, listReportTemplates, listReportVersions, listReportWidgetPresets, listReports, listRequestedTasks, listRetentionPolicies, listRetentionRuns, listRolePolicies, listRoleUsers, listRoles, listRules, listSavedViews, listScheduledChanges, listScheduledReports, listScopeDimensions, listSessionRecordings, listShareLinks, listSlaRules, listStagedImports, listSubRowTemplates, listSubRows, listSyncJobs, listTasks, listTeamTasks, listThroughputCollections, listTraces, listTreePermissions, listViewSubscriptions, listVirtualCollections, listWebhookDeliveries, listWebhooks, listWidgetFeeds, listWorkspaceTemplates, listWorkspaces, markAllNotificationsRead, markChatRoomRead, markNotificationRead, markNotificationsRead, moveTreeNode, nudgeTask, omniSearch, openHelpVideoPackageImport, openHelpVideoUpload, presignFileUpload, previewContentBundle, previewHelpVideoPackageImport, previewImportJob, previewReportWidget, projectFieldConfig, publishHelpVideo, publishItem, queryVirtualCollection, readAccessAuditFindings, readActiveLayout, readActivity, readActivityReportSummary, readAddendum, readAiSettings, readAlertLog, readAllStateOwners, readAnomalyLog, readApiAnalyticsErrors, readApiAnalyticsSummary, readApiAnalyticsTimeseries, readApiAnalyticsTopCollections, readApiAnalyticsTopPaths, readApiKey, readApprovalBrief, readApprovalChain, readAtRiskSummary, readBackupManifest, readChatConfig, readChatDirectory, readChatPeerRead, readCollection, readCollectionLayout, readCollectionLayouts, readCollections, readConfigInventory, readCoverageGaps, readDataQualityRun, readDbPool, readDetailLayout, readDistinctValues, readDraftPublishConfig, readErpSubmissionHistory, readExpensiveSql, readFieldChangeHistory, readFieldConfig, readFieldImpact, readFieldWatch, readFileMeta, readFileUsage, readFilesByIds, readHealthDetailed, readHelpVideo, readHelpVideoAnalytics, readHelpVideoDownloadLink, readHelpVideoDraft, readHelpVideoWalk, readHierarchyConfig, readHierarchyNodeAncestors, readHierarchyNodeChildren, readHierarchyNodes, readHierarchyTree, readImportJob, readImportProcedure, readInstanceOwners, readInstanceRoster, readIntegrationHealth, readInternalWidget, readIssue, readIssueSummary, readItem, readItemLock, readItemLockConfig, readItems, readJobRegistry, readLastTouch, readLayoutAssignments, readLayoutBundle, readLayoutDrift, readLayoutGroups, readLayoutOverview, readLayoutVersion, readMany, readMe, readMetricAlertLog, readMyScopes, readMyWork, readNotificationCount, readNotificationSubscriptionStats, readOnlinePresence, readOwnerGroups, readPage, readPageWidgetData, readPdfTemplate, readPersistedQuery, readPickerExclusion, readPickerExclusions, readPipelineFlowMap, readPipelineReplay, readPipelineTemplate, readPipelineTemplates, readPipelineVersion, readPreflight, readQueue, readQueueCollectionStates, readQueueColumnPrefs, readQueueItems, readQueueTrends, readQueueWorkload, readReadiness, readRecordGraph, readRelationOptions, readReport, readReportAlertLog, readReportAlertsLog, readReportFilterOptions, readReportFiring, readReportSnapshot, readReportSubscription, readReportUsage, readReportWidgetData, readRequiredHelpVideos, readRevision, readRevisions, readRole, readRuntimeStats, readScopeDimensionCoverage, readSessionRecordingEvents, readSettings, readSingleton, readSlaStatusBatch, readStagedImport, readStagedImportStats, readStateOwnerGroups, readStateOwners, readStateOwnersBatch, readSyncJob, readTask, readTaskCounts, readTaskHistory, readThroughputReport, readTimeline, readTrace, readTrafficSnapshot, readTreeAncestors, readTreeChildren, readTreeConfig, readTreeDescendants, readTreeNested, readTreeNodes, readTwoFactorStatus, readUnreadNotificationCount, readUser, readUserActivity, readUserActivitySummary, readUserCard, readUserScopes, readUsers, readWorkflowBindings, readWorkflowInstance, readWorkflowInstances, readWorkspace, readWorkspaceUsage, rebuildTreePaths, recordHelpVideoProgress, registerHelpVideoPage, rehearseCreateItem, reindexSemanticSearch, rejectAddendum, rejectAiProposal, releaseItemLock, releaseQueueItem, rematerializeQueue, removeChatChannelMember, removeInstanceOwner, renderInternalWidget, renderPdfTemplate, reorderFieldGroups, reorderSubRows, reorderTreeSiblings, replaceSubRows, replayActivityEvent, replayFlow, reportClientError, requestRecordAccess, requeueStagedImport, rerecordHelpVideo, rerenderHelpVideo, resetReportCache, resolveReportAlert, restoreHelpVideoVersion, restoreImportDefinitionVersion, restoreLayoutVersion, restorePipelineVersion, restoreReportVersion, retryDeadLetter, retryErpSubmission, retryWebhookDelivery, revokeApiKey, revokeShareLink, revokeToken, revokeUserToken, rollbackRevision, rotateWidgetFeedToken, runAccessAudit, runActivityReport, runActivityReportCsv, runCronJob, runDataQuality, runRetentionPolicy, runScheduledReport, runSyncJob, saveHelpVideoDraft, saveMyScopeDefaults, saveReportFilterPreset, saveReportTemplate, saveReportWidgets, saveUserScope, searchChatMessages, semanticSearch, sendBulkNotification, sendChatMessage, sendTestMail, sessionRecordingEnabled, setHelpVideoContexts, setHelpVideoRequirements, setMyDelegate, setQueueDefaultView, setReportSubscription, setTranslations, setupTwoFactor, simulatePermissions, simulatePipeline, simulatePipelineImpact, startApproval, startMasquerade, startSessionRecording, startWorkflow, stopMasquerade, submitAddendum, submitFormItem, submitItemForReview, submitLayoutOps, submitToErp, subscribeFieldWatch, subscribeMetricAlert, suggestImportValidation, suggestQueueLabels, switchWorkspace, testExternalApi, testFlow, testWebhook, toggleChatPin, toggleChatReaction, togglePinnedItem, toggleReportAlert, touchRecordView, transitionWorkflow, unpublishItem, unsubscribeFieldWatch, unsubscribeMetricAlert, updateAccessAudit, updateAddendum, updateAiSettings, updateAlertDefinition, updateAnomalyLogEntry, updateAnomalyRule, updateApiKey, updateApprovalChain, updateAtRiskRule, updateAttributeDefinition, updateAttributeValues, updateChatChannel, updateChatRoom, updateChatRoomType, updateCollectionLayout, updateComment, updateDataQualityRule, updateDraftPublishConfig, updateErpSubmissionStatus, updateExternalApi, updateExternalApiEndpoint, updateFieldConfig, updateFieldGroup, updateFieldWatch, updateFileMeta, updateHelpVideo, updateHierarchyConfig, updateImportDefinition, updateInternalWidget, updateIssue, updateItem, updateItemLockConfig, updateLayoutAssignments, updateLayoutUngroupedSort, updateMe, updateMetricAlertRule, updateMetricAlertSubscription, updateNotificationSubscription, updatePage, updatePdfTemplate, updatePersistedQuery, updateQueue, updateQueueSources, updateQueueView, updateRecordTemplate, updateReport, updateReportAlert, updateReportWidgetPreset, updateRetentionPolicy, updateRole, updateRolePolicy, updateRoleUiPermissions, updateRule, updateSavedView, updateScheduledReport, updateSettings, updateSingleton, updateSlaRule, updateSyncJob, updateTask, updateTreePermission, updateUser, updateVirtualCollection, updateWebhook, updateWidgetFeed, updateWorkflowBinding, updateWorkspace, validateVirtualCollectionSql, verifyTwoFactor };
package/dist/index.js CHANGED
@@ -907,8 +907,8 @@ function cancelScheduledChange(id) {
907
907
  function executeScheduledChange(id) {
908
908
  return cmd("POST", `/scheduled-changes/${id}/execute`);
909
909
  }
910
- function readFieldConfig(collection) {
911
- return cmd("GET", `/field-config/${collection}`);
910
+ function readFieldConfig(collection, opts) {
911
+ return cmd("GET", `/field-config/${collection}`, opts);
912
912
  }
913
913
  function updateFieldConfig(collection, field, body) {
914
914
  return cmd("PATCH", `/field-config/${collection}/${field}`, void 0, body);
@@ -1216,8 +1216,8 @@ function isPageSlot(assignment) {
1216
1216
  function readCollectionLayouts(collection) {
1217
1217
  return cmd("GET", "/collection-layouts", { collection });
1218
1218
  }
1219
- function readActiveLayout(collection) {
1220
- return cmd("GET", "/collection-layouts/active", { collection });
1219
+ function readActiveLayout(collection, opts) {
1220
+ return cmd("GET", "/collection-layouts/active", { collection, ...opts });
1221
1221
  }
1222
1222
  function readLayoutGroups(collection, layoutId) {
1223
1223
  return cmd("GET", `/field-groups/${collection}`, { layout_id: layoutId });
@@ -1228,11 +1228,11 @@ function readLayoutAssignments(layoutId) {
1228
1228
  function activateLayout(layoutId) {
1229
1229
  return cmd("POST", `/collection-layouts/${layoutId}/activate`);
1230
1230
  }
1231
- function cloneLayout(layoutId, name) {
1232
- return cmd("POST", `/collection-layouts/${layoutId}/clone`, void 0, { name });
1231
+ function cloneLayout(layoutId, name, opts) {
1232
+ return cmd("POST", `/collection-layouts/${layoutId}/clone`, void 0, { name, ...opts });
1233
1233
  }
1234
- function createCollectionLayout(collection, name) {
1235
- return cmd("POST", "/collection-layouts", void 0, { collection, name });
1234
+ function createCollectionLayout(collection, name, opts) {
1235
+ return cmd("POST", "/collection-layouts", void 0, { collection, name, ...opts });
1236
1236
  }
1237
1237
  function updateCollectionLayout(layoutId, patch) {
1238
1238
  return cmd("PATCH", `/collection-layouts/${layoutId}`, void 0, patch);
@@ -1640,6 +1640,133 @@ function listRetentionRuns(policyId) {
1640
1640
  return cmd("GET", `/retention/${policyId}/runs`);
1641
1641
  }
1642
1642
 
1643
+ // src/commands/layout-editor.ts
1644
+ var PLACEMENT_PATCH_KEYS = [
1645
+ "label_override",
1646
+ "is_visible",
1647
+ "default_expanded",
1648
+ "col_span",
1649
+ "overrides",
1650
+ "show_row_revisions",
1651
+ "allow_revision_restore",
1652
+ "lock_conditions",
1653
+ "input_bindings",
1654
+ "widget_id",
1655
+ "show_approval_chain"
1656
+ ];
1657
+ var GROUP_PATCH_KEYS = [
1658
+ "label",
1659
+ "type",
1660
+ "icon",
1661
+ "is_collapsed",
1662
+ "tab_mode",
1663
+ "hide_when_empty",
1664
+ "visibility_mode",
1665
+ "summary_fields",
1666
+ "summary_hide_empty",
1667
+ "swap_config",
1668
+ "skip_if_filled",
1669
+ "content",
1670
+ "content_tone",
1671
+ "visible_when",
1672
+ "hidden_for_roles",
1673
+ "locked_for_roles",
1674
+ "read_width"
1675
+ ];
1676
+ var LAYOUT_PATCH_KEYS = [
1677
+ "name",
1678
+ "slug",
1679
+ "create_label",
1680
+ "create_hidden",
1681
+ "sort",
1682
+ "is_active",
1683
+ "disable_comments",
1684
+ "disable_tasks",
1685
+ "tab_mode",
1686
+ "validate_before_next",
1687
+ "summary_enabled",
1688
+ "summary_hide_empty",
1689
+ "ai_enabled",
1690
+ "accordion_mode",
1691
+ "disable_revisions",
1692
+ "disable_clone",
1693
+ "disable_delete",
1694
+ "row_order_field",
1695
+ "pdf_theme",
1696
+ "pdf_template_id",
1697
+ "pdf_cover_enabled",
1698
+ "pdf_cover_title_field",
1699
+ "pdf_cover_subtitle",
1700
+ "pdf_show_logo",
1701
+ "pdf_page_size",
1702
+ "pdf_orientation",
1703
+ "pdf_button_label",
1704
+ "conditions",
1705
+ "allow_schedule",
1706
+ "allow_disable_pickers",
1707
+ "layout_type",
1708
+ "addendum_layout_id",
1709
+ "workflow_template_id",
1710
+ "single_active_addendum",
1711
+ "addendum_default_view",
1712
+ "record_conditions",
1713
+ "default_values",
1714
+ "display_mode",
1715
+ "parent_layout_id",
1716
+ "hide_integrity_banner",
1717
+ "hide_sla_banner",
1718
+ "changes_tray",
1719
+ "dossier_enabled",
1720
+ "dossier_label",
1721
+ "quick_picker",
1722
+ "sheet_width",
1723
+ "header_fields",
1724
+ "hide_empty"
1725
+ ];
1726
+ function readLayoutOverview(collection) {
1727
+ return cmd("GET", "/collection-layouts/overview", { collection });
1728
+ }
1729
+ function explainLayout(query) {
1730
+ return cmd("GET", "/collection-layouts/explain", query);
1731
+ }
1732
+ function readLayoutBundle(layoutId) {
1733
+ return cmd("GET", `/collection-layouts/${layoutId}/bundle`);
1734
+ }
1735
+ function submitLayoutOps(layoutId, body) {
1736
+ return cmd("POST", `/collection-layouts/${layoutId}/ops`, void 0, body);
1737
+ }
1738
+ function readLayoutVersion(layoutId, versionId) {
1739
+ return cmd("GET", `/collection-layouts/${layoutId}/versions/${versionId}`);
1740
+ }
1741
+ function diffLayoutVersion(layoutId, versionId, against) {
1742
+ return cmd(
1743
+ "GET",
1744
+ `/collection-layouts/${layoutId}/versions/${versionId}/diff`,
1745
+ against !== void 0 ? { against } : void 0
1746
+ );
1747
+ }
1748
+ function readLayoutDrift() {
1749
+ return cmd("GET", "/collection-layouts/drift");
1750
+ }
1751
+ function projectFieldConfig(collection, assignments) {
1752
+ return cmd("POST", `/field-config/${collection}/project`, void 0, { assignments });
1753
+ }
1754
+ function listInternalWidgetPlacements(widgetId) {
1755
+ return cmd("GET", `/widgets-internal/${widgetId}/placements`);
1756
+ }
1757
+ function readPickerExclusion(collection, itemId) {
1758
+ return cmd("GET", `/picker-exclusions/status/${collection}/${itemId}`);
1759
+ }
1760
+ function readPickerExclusions(collection, ids) {
1761
+ return cmd("POST", "/picker-exclusions/batch-status", void 0, { collection, ids });
1762
+ }
1763
+ function excludeFromPickers(body) {
1764
+ return cmd("POST", "/picker-exclusions", void 0, body);
1765
+ }
1766
+ function includeInPickers(body) {
1767
+ return cmd("DELETE", "/picker-exclusions", void 0, body);
1768
+ }
1769
+
1643
1770
  // src/commands/ops.ts
1644
1771
  function readReadiness() {
1645
1772
  return cmd("GET", "/ready");
@@ -2705,6 +2832,9 @@ function submitFormItem(collection, values, options) {
2705
2832
  return cmd("POST", `/items/${collection}`, void 0, values);
2706
2833
  }
2707
2834
  export {
2835
+ GROUP_PATCH_KEYS,
2836
+ LAYOUT_PATCH_KEYS,
2837
+ PLACEMENT_PATCH_KEYS,
2708
2838
  READ_MANY_MAX,
2709
2839
  _and,
2710
2840
  _contains,
@@ -2903,6 +3033,7 @@ export {
2903
3033
  deleteWorkspaceTemplate,
2904
3034
  deployImportProcedure,
2905
3035
  desc,
3036
+ diffLayoutVersion,
2906
3037
  disableTwoFactor,
2907
3038
  discardHelpVideoPackageImport,
2908
3039
  drillReportRow,
@@ -2915,11 +3046,13 @@ export {
2915
3046
  evaluateFieldRules,
2916
3047
  evaluateFieldVisibility,
2917
3048
  excludeFromPicker,
3049
+ excludeFromPickers,
2918
3050
  executeBulkAction,
2919
3051
  executeCustomQuery,
2920
3052
  executeImportTemplate,
2921
3053
  executeItemAction,
2922
3054
  executeScheduledChange,
3055
+ explainLayout,
2923
3056
  explainRecordAccess,
2924
3057
  explainReportTrend,
2925
3058
  exportBlueprint,
@@ -2959,6 +3092,7 @@ export {
2959
3092
  importExternalApiSpec,
2960
3093
  importSchemaSnapshot,
2961
3094
  includeInPicker,
3095
+ includeInPickers,
2962
3096
  installBlueprint,
2963
3097
  installCollectionPreset,
2964
3098
  invokeInternalWidgetAction,
@@ -3013,6 +3147,7 @@ export {
3013
3147
  listImportDefinitions,
3014
3148
  listImportJobs,
3015
3149
  listImportTemplates,
3150
+ listInternalWidgetPlacements,
3016
3151
  listInternalWidgets,
3017
3152
  listIssues,
3018
3153
  listItemActions,
@@ -3092,6 +3227,7 @@ export {
3092
3227
  previewHelpVideoPackageImport,
3093
3228
  previewImportJob,
3094
3229
  previewReportWidget,
3230
+ projectFieldConfig,
3095
3231
  publishHelpVideo,
3096
3232
  publishItem,
3097
3233
  queryVirtualCollection,
@@ -3163,7 +3299,11 @@ export {
3163
3299
  readJobRegistry,
3164
3300
  readLastTouch,
3165
3301
  readLayoutAssignments,
3302
+ readLayoutBundle,
3303
+ readLayoutDrift,
3166
3304
  readLayoutGroups,
3305
+ readLayoutOverview,
3306
+ readLayoutVersion,
3167
3307
  readMany,
3168
3308
  readMe,
3169
3309
  readMetricAlertLog,
@@ -3177,6 +3317,8 @@ export {
3177
3317
  readPageWidgetData,
3178
3318
  readPdfTemplate,
3179
3319
  readPersistedQuery,
3320
+ readPickerExclusion,
3321
+ readPickerExclusions,
3180
3322
  readPipelineFlowMap,
3181
3323
  readPipelineReplay,
3182
3324
  readPipelineTemplate,
@@ -3322,6 +3464,7 @@ export {
3322
3464
  submitAddendum,
3323
3465
  submitFormItem,
3324
3466
  submitItemForReview,
3467
+ submitLayoutOps,
3325
3468
  submitToErp,
3326
3469
  subscribeFieldWatch,
3327
3470
  subscribeMetricAlert,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nivaro/sdk",
3
- "version": "0.1.25",
3
+ "version": "0.1.26",
4
4
  "description": "TypeScript SDK for Nivaro CMS — typed REST client, GraphQL, realtime subscriptions, and presence.",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",