@ai-matrx/records 0.76.19 → 0.77.2

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.
Files changed (70) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/app-table/index.cjs +84 -2
  3. package/dist/app-table/index.cjs.map +1 -1
  4. package/dist/app-table/index.d.cts +7 -7
  5. package/dist/app-table/index.d.ts +7 -7
  6. package/dist/app-table/index.js +84 -2
  7. package/dist/app-table/index.js.map +1 -1
  8. package/dist/{client-EaE4ta6p.d.cts → client-DZ3UcU4_.d.cts} +53 -5
  9. package/dist/{client-C8G7zUMQ.d.ts → client-ZIxyAOdh.d.ts} +53 -5
  10. package/dist/core/index.cjs +97 -8
  11. package/dist/core/index.cjs.map +1 -1
  12. package/dist/core/index.d.cts +21 -11
  13. package/dist/core/index.d.ts +21 -11
  14. package/dist/core/index.js +97 -8
  15. package/dist/core/index.js.map +1 -1
  16. package/dist/data/index.cjs +85 -3
  17. package/dist/data/index.cjs.map +1 -1
  18. package/dist/data/index.d.cts +6 -6
  19. package/dist/data/index.d.ts +6 -6
  20. package/dist/data/index.js +85 -3
  21. package/dist/data/index.js.map +1 -1
  22. package/dist/{declareTable-aoFu32Ca.d.cts → declareTable-BYZdFrt5.d.cts} +4 -4
  23. package/dist/{declareTable-3yW8GrJE.d.ts → declareTable-DGSJMqGx.d.ts} +4 -4
  24. package/dist/{field-DkB6Nods.d.cts → field-BTW7h7Wh.d.cts} +1 -1
  25. package/dist/{field-cWRPTM3U.d.ts → field-D7I9yck6.d.ts} +1 -1
  26. package/dist/index.cjs +30 -8
  27. package/dist/index.cjs.map +1 -1
  28. package/dist/index.d.cts +7 -7
  29. package/dist/index.d.ts +7 -7
  30. package/dist/index.js +30 -8
  31. package/dist/index.js.map +1 -1
  32. package/dist/memory/index.cjs +31 -0
  33. package/dist/memory/index.cjs.map +1 -1
  34. package/dist/memory/index.d.cts +6 -6
  35. package/dist/memory/index.d.ts +6 -6
  36. package/dist/memory/index.js +31 -0
  37. package/dist/memory/index.js.map +1 -1
  38. package/dist/{ports-C2_pOWrL.d.ts → ports-CaYEF1dG.d.ts} +1 -1
  39. package/dist/{ports-C83nhjoM.d.cts → ports-PpvsH1cQ.d.cts} +1 -1
  40. package/dist/react/index.cjs +98 -9
  41. package/dist/react/index.cjs.map +1 -1
  42. package/dist/react/index.d.cts +324 -15
  43. package/dist/react/index.d.ts +324 -15
  44. package/dist/react/index.js +98 -9
  45. package/dist/react/index.js.map +1 -1
  46. package/dist/realtime/index.d.cts +2 -2
  47. package/dist/realtime/index.d.ts +2 -2
  48. package/dist/{record-DVtXK-6L.d.cts → record-B7iwye2k.d.cts} +75 -13
  49. package/dist/{record-DVtXK-6L.d.ts → record-B7iwye2k.d.ts} +75 -13
  50. package/dist/{subscription-DxtZgyFR.d.ts → subscription-BWaRPLyo.d.ts} +60 -2
  51. package/dist/{subscription-vpnl6GxJ.d.cts → subscription-Br30ZwIt.d.cts} +60 -2
  52. package/dist/{table-kind-BtguhnRV.d.cts → table-kind-Da21ZLdJ.d.ts} +146 -5
  53. package/dist/{table-kind-DzyRtFNa.d.ts → table-kind-HAQ6WNxZ.d.cts} +146 -5
  54. package/dist/templates/index.cjs +14 -0
  55. package/dist/templates/index.cjs.map +1 -1
  56. package/dist/templates/index.d.cts +9 -9
  57. package/dist/templates/index.d.ts +9 -9
  58. package/dist/templates/index.js +14 -0
  59. package/dist/templates/index.js.map +1 -1
  60. package/dist/{types-y8GX3-QC.d.ts → types-DWZ5_3by.d.ts} +2 -2
  61. package/dist/{types-DWoJFBbr.d.cts → types-DYoWzHwJ.d.cts} +2 -2
  62. package/dist/{types-DqCWKOYh.d.ts → types-DrJLOqVi.d.ts} +2 -2
  63. package/dist/{types-X9P-cQd0.d.cts → types-LvxsZ6Zv.d.cts} +2 -2
  64. package/dist/use-cases/index.cjs.map +1 -1
  65. package/dist/use-cases/index.d.cts +5 -5
  66. package/dist/use-cases/index.d.ts +5 -5
  67. package/dist/use-cases/index.js.map +1 -1
  68. package/dist/{validate-CEE0ts9g.d.cts → validate-CRdXE73G.d.cts} +1 -1
  69. package/dist/{validate-d9QMYjBm.d.ts → validate-j0WQoC3C.d.ts} +1 -1
  70. package/package.json +3 -3
@@ -707,14 +707,16 @@ function moveConsequence(home, to) {
707
707
  var PERMISSION_LEVELS = [
708
708
  "viewer",
709
709
  "commenter",
710
+ "edit_content",
710
711
  "editor",
711
712
  "admin"
712
713
  ];
713
714
  var ORDINAL = {
714
715
  viewer: 1,
715
716
  commenter: 2,
716
- editor: 3,
717
- admin: 4
717
+ edit_content: 3,
718
+ editor: 4,
719
+ admin: 5
718
720
  };
719
721
  function atLeast(held, needed) {
720
722
  if (!held) return false;
@@ -1093,6 +1095,12 @@ var STORE_DOORS = [
1093
1095
  { name: "assert_public_reader_names_a_public_table", args: "p_organization_id uuid, p_table_id uuid, p_door text", returns: "void", security: "definer" },
1094
1096
  { name: "assert_scope_door", args: "p_organization_id uuid, p_door text", returns: "void", security: "definer" },
1095
1097
  { name: "assert_store_door", args: "p_organization_id uuid, p_door text", returns: "void", security: "invoker" },
1098
+ { name: "automation_archive", args: "p_organization_id uuid, p_automation_id uuid", returns: "jsonb", security: "definer" },
1099
+ { name: "automation_declare", args: "p_organization_id uuid, p_table_id uuid, p_spec jsonb, p_automation_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
1100
+ { name: "automation_restore", args: "p_organization_id uuid, p_automation_id uuid", returns: "jsonb", security: "definer" },
1101
+ { name: "automation_runs", args: "p_automation_id uuid, p_limit integer DEFAULT 50, p_cursor timestamp with time zone DEFAULT NULL::timestamp with time zone, p_organization_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
1102
+ { name: "automation_set_enabled", args: "p_organization_id uuid, p_automation_id uuid, p_enabled boolean", returns: "jsonb", security: "definer" },
1103
+ { name: "automations", args: "p_table_id uuid, p_organization_id uuid DEFAULT NULL::uuid, p_include_archived boolean DEFAULT false", returns: "jsonb", security: "definer" },
1096
1104
  { name: "autonumber_backfill", args: "p_organization_id uuid, p_field_id uuid", returns: "jsonb", security: "definer" },
1097
1105
  { name: "barcode_symbologies", args: "", returns: "text[]", security: "invoker" },
1098
1106
  { name: "booking_cancel", args: "p_booking_ref text, p_origin text DEFAULT NULL::text", returns: "TABLE(booking_ref text, record_id uuid, slot_key text, state text, message text)", security: "definer" },
@@ -1339,13 +1347,18 @@ var STORE_DOORS = [
1339
1347
  { name: "form_look_options", args: "p_organization_id uuid, p_presentation jsonb DEFAULT '{}'::jsonb", returns: "jsonb", security: "definer" },
1340
1348
  { name: "form_notify", args: "p_organization_id uuid, p_form_id uuid, p_record_id uuid, p_submission_id uuid", returns: "uuid", security: "invoker" },
1341
1349
  { name: "form_preview_asks", args: "p_organization_id uuid, p_table_id uuid, p_questions jsonb, p_values jsonb", returns: "TABLE(field_key text, asked boolean, decided boolean, said text)", security: "definer" },
1350
+ { name: "form_preview_route", args: "p_organization_id uuid, p_table_id uuid, p_questions jsonb, p_endings jsonb, p_values jsonb", returns: "jsonb", security: "definer" },
1342
1351
  { name: "form_public", args: "p_form_id uuid", returns: "TABLE(form_id uuid, organization_id uuid, table_id uuid, title text, presentation jsonb, fields jsonb, honeypot_key text, state text, message text)", security: "definer" },
1343
1352
  { name: "form_public_asks", args: "p_form_id uuid, p_values jsonb, p_secret text DEFAULT NULL::text, p_origin text DEFAULT NULL::text", returns: "TABLE(field_key text, asked boolean, decided boolean, said text)", security: "definer" },
1353
+ { name: "form_public_route", args: "p_form_id uuid, p_values jsonb", returns: "jsonb", security: "definer" },
1344
1354
  { name: "form_redirect_domains", args: "p_organization_id uuid", returns: "text[]", security: "invoker" },
1345
1355
  { name: "form_redirect_refusal", args: "p_organization_id uuid, p_url text", returns: "text", security: "invoker" },
1346
1356
  { name: "form_restore", args: "p_organization_id uuid, p_form_id uuid", returns: "jsonb", security: "definer" },
1357
+ { name: "form_results", args: "p_organization_id uuid, p_form_id uuid", returns: "jsonb", security: "definer" },
1347
1358
  { name: "form_slug", args: "p_organization_id uuid, p_title text, p_form_id uuid DEFAULT NULL::uuid", returns: "text", security: "invoker" },
1348
1359
  { name: "form_submit", args: "p_form_id uuid, p_origin text, p_payload jsonb, p_bucket text, p_honeypot text DEFAULT NULL::text, p_client_key text DEFAULT NULL::text", returns: "TABLE(submission_id uuid, record_id uuid, state text, message text)", security: "definer" },
1360
+ { name: "form_theme_options", args: "", returns: "jsonb", security: "invoker" },
1361
+ { name: "form_visit", args: "p_form_id uuid, p_visit text, p_event text, p_field text DEFAULT NULL::text", returns: "text", security: "definer" },
1349
1362
  { name: "forms", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "TABLE(form_id uuid, table_id uuid, title text, slug text, published_at timestamp with time zone, closed_at timestamp with time zone, submission_cap integer, responses bigint, in_table bigint, held bigint, rejected bigint, state text, quarantine_rule_id uuid, notify_rule_id uuid, presentation jsonb)", security: "definer" },
1350
1363
  { name: "forms_archived", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_limit integer DEFAULT 100", returns: "TABLE(form_id uuid, table_id uuid, table_name text, kind text, title text, slug text, archived_at timestamp with time zone, archived_by uuid, table_archived boolean, can_restore boolean)", security: "definer" },
1351
1364
  { name: "formula_compile_sql", args: "p_organization_id uuid, p_expr jsonb, p_values_sql text", returns: "text", security: "invoker" },
@@ -1676,6 +1689,7 @@ var STORE_DOORS = [
1676
1689
  { name: "rollup_value", args: "p_organization_id uuid, p_record_id uuid, p_field_data jsonb", returns: "jsonb", security: "invoker" },
1677
1690
  { name: "row_actions", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1678
1691
  { name: "row_sits_in_a_personal_table", args: "p_type text, p_organization_id uuid, p_id uuid", returns: "boolean", security: "invoker" },
1692
+ { name: "row_template_bodies", args: "p_organization_id uuid, p_table_id uuid", returns: "TABLE(template_id uuid, body jsonb)", security: "definer" },
1679
1693
  { name: "row_template_declare", args: "p_organization_id uuid, p_table_id uuid, p_spec jsonb", returns: "uuid", security: "definer" },
1680
1694
  { name: "row_templates", args: "p_organization_id uuid, p_table_id uuid", returns: 'TABLE(template_id uuid, name text, table_id uuid, "values" jsonb, created_at timestamp with time zone, updated_at timestamp with time zone)', security: "definer" },
1681
1695
  { name: "rule_applies", args: "p_organization_id uuid, p_rule_id uuid, p_record_id uuid", returns: "jsonb", security: "invoker" },
@@ -1802,6 +1816,8 @@ var STORE_DOORS = [
1802
1816
  { name: "table_stage_field", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "definer" },
1803
1817
  { name: "table_storage", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "invoker" },
1804
1818
  { name: "table_sync", args: "p_organization_id uuid, p_home_id uuid, p_spec jsonb", returns: "jsonb", security: "definer" },
1819
+ { name: "table_template_declare", args: "p_org_id uuid, p_name text, p_description text, p_fields jsonb", returns: "uuid", security: "invoker" },
1820
+ { name: "table_templates", args: "p_org_id uuid", returns: "jsonb", security: "definer" },
1805
1821
  { name: "table_transfer_owner", args: "p_table_id uuid, p_to_person uuid, p_reason text", returns: "jsonb", security: "definer" },
1806
1822
  { name: "table_type_field", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "definer" },
1807
1823
  { name: "table_unique_rule_fields", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "invoker" },
@@ -1968,8 +1984,6 @@ var STORE_KNOBS = [
1968
1984
  { key: "provenance_retention_days", value: "30", type: "number" },
1969
1985
  { key: "row_action_steps_max", value: "60", type: "integer" },
1970
1986
  { key: "row_actions_max", value: "24", type: "integer" },
1971
- { key: "sandbox_expanded_frame_height_px", value: "20000", type: "integer" },
1972
- { key: "sandbox_frame_height_px", value: "4000", type: "integer" },
1973
1987
  { key: "sandbox_message_bytes", value: "65536", type: "integer" },
1974
1988
  { key: "sandbox_org_components", value: "true", type: "boolean" },
1975
1989
  { key: "scope_members_admitted", value: "true", type: "boolean" },
@@ -1992,12 +2006,12 @@ var STORE_REFUSAL_CODES = [
1992
2006
  { code: "22004", raised_by: "_entity_change_file,_entity_custom_fields_guard,_io_outbox_claim,_portal_config_judge,_share_write_person,_value_envelope,actor_word,agg_assert_key,agg_compare_windows,agg_sql,anon_capture,anon_token_issue,anon_write,assert_client_may_reach,assert_scope_door,booking_declare,capture_submit,checklist_declare,context_resolve,context_template_define,context_type_write,dashboard_block_normalize,dashboard_declare,dashboard_window_sql,doc_render_write,doc_sign,doc_signature_write,doc_template_save,enrich_land,enrich_normalize,entity_field_protect_arman_explicitly_approved,entity_row_propose,entity_row_write,external_history_event,external_rows,external_source_declare,external_stub_upsert,external_write_through,external_writes_set,field_history,form_declare,form_look_options,form_submit,home_add,inbox_snooze,io_comment_write,io_import_begin,io_infer_column,io_outbox_drain,io_outbox_release_claimed,io_outbox_subscribe,io_restore,migrate_choice_keys,migrate_purge,migrate_purge_hard,migrate_reclass,migrate_split,migrate_undo,organization_clear,organization_contents,pipeline_declare,pipeline_gate_preview,portal_declare,portal_form_submit,portal_invite,portal_principal_bind,provenance_retention_days,provenance_write,query_across_homes,query_by_coordinates,query_rollup,record_aggregate_as_of,record_delete,record_reparent,record_resolve,record_restore,record_update,record_upsert,record_write,record_write_graph,record_write_graph_superseding,record_write_many,relation_carry,relation_halves_repair,relation_own,row_template_declare,rule_declare,set_table_confidential_arman_explicitly_approved,share_grant,sign_request_create,sign_request_sign,subscription_declare,table_archive,table_archive_deliberately,table_declare,table_duplicate,table_move,table_restore,table_share_outside_grant,table_share_outside_invite,template_declare,value_restore,view_declare,view_designate,view_look_read,view_look_set,whole_value_complete,work_approval_decide,work_approval_request,work_template_declare" },
1993
2007
  { code: "22007", raised_by: "_template_date,agg_parse_moment,dashboard_window_sql" },
1994
2008
  { code: "22012", raised_by: "formula_eval,rule_eval,rule_sql_op" },
1995
- { code: "22023", raised_by: "_action_check,_booking_availability,_ctx_dataset_field_holds,_ctx_reference_value_holds,_ctx_store_scope,_ctx_tree_part,_decorations_check,_entity_change_file,_entity_custom_fields_guard,_form_look_judge,_fx_date,_fx_num,_fx_regex,_fx_unit,_fxp_level,_fxp_resolve,_fxp_tokens,_portal_config_judge,_rule_eval_seated,_table_dimensions_check,_take_op_id,_template_bind,_value_envelope,_view_field_key,_view_key_value,_work_shape_guard,_write_via_mark,action_run,actor_word,agent_change_trust,agg_assert_key,agg_calendar,agg_compare_windows,agg_sql,anon_token_issue,booking_declare,containment_parent,context_scope_write,context_scopes,context_template_define,context_type_write,context_values,count_records_archived,dashboard_block_normalize,dashboard_run,dashboard_target_field_assert,dashboard_window_sql,data_home,data_home_changed_by,doc_render_body,doc_render_write,doc_signature_write,drill_resolve,enrich_declare,enrich_land,enrich_normalize,enrich_pin,entity_back_links,entity_fields_across,entity_read_mask,entity_reference_rows,entity_reference_search,entity_reference_words,entity_row_write,entity_value_write,external_history_event,external_source_declare,external_stub_upsert,external_write_through,field_access,field_history,field_update,form_declare,form_draft_save,formula_eval,formula_parse,grid_layout_check,hub_changed_by,inbound_domain,inbox_snooze,io_export,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,list_portals,listed_predicate_sql,member_records_take_over,migrate_merge,migrate_reclass,my_levels,organization_clear,page_size,pick_list_create,pin_agent_cells,pipeline_move,pipeline_move_many,portal_declare,portal_form_submit,provenance_write,publish_bind,query_by_coordinates,query_rollup,query_rollup_sum,read_records_archived,read_records_in_view_order,read_records_keyset,read_records_page,record_aggregate_as_of,record_change_many,record_filter_sql,record_row_controls_set,record_search_sql,record_update,record_upsert,record_write_graph,record_write_graph_superseding,record_write_many,records_search,relation_carry,relation_names_match,row_template_declare,rule_eval,rule_filter_node_sql,rule_members,rule_members_visible,rule_sql_op,scope_table_provision,share_grant,share_lane_set,sign_request_create,sign_request_sign,subscription_declare,table_archive_deliberately,table_ensure,table_find,table_from_example,table_move,table_row_defaults_set,table_rules,table_share_outside_grant,table_sync,table_transfer_owner,table_webhook_declare,template_declare,template_from_tables,template_install_claim,template_install_note,template_upgrade,templates,view_declare,view_keys_check,view_look_set,view_record_order_set,visibility_as_of,where_lists_live,where_tables_live,work_approval_request,work_decide_many,work_inbox,work_list,work_slot_hold" },
1996
- { code: "23503", raised_by: "_action_check,_booking_availability,_checklist_instantiate,_containment_guard,_ctx_store_value,_decorations_check,_display_spec_for,_field_document_for,_field_type_parity_guard,_pipeline_stage_key,_record_rule_uses,action_declare,action_run,agg_digest_assemble,anon_publish,anon_rate_take,anon_token_issue,anon_write,assert_organization_wall,autonumber_backfill,booking_cancel,booking_confirm,booking_declare,booking_hold,booking_reschedule,capture_publish,checklist_declare,checklist_steps_table,comment_write,dashboard_declare,delete_rule,doc_sign,doc_template_save,enrich_declare,enrich_due,enrich_land,form_declare,form_draft_save,form_submit,grid_layout,home_add,inbound_declare,inbound_mail_land,inbound_set,io_comment_write,io_import_begin,io_import_finish,io_import_report,io_import_rows,io_proposal_accept,migrate_demote,migrate_promote,migrate_purge_hard,pipeline_board,pipeline_declare,pipeline_move,pipeline_read,pipeline_transition_refusal,promote_field,promote_table,read_records_in_view_order,read_records_page,record_applicability,record_reparent,record_write_graph_superseding,relation_carry,relation_own,resolve_first_match,row_template_declare,rule_applies,rule_declare,rule_eval,rule_filter_node_sql,rule_members,rule_members_visible,rule_run,sign_request_create,subscription_mute,subscription_preview,table_decorate,table_dimensions_set,table_from_example,table_webhook_archive,table_webhook_declare,view_declare,view_designate,view_look_set,view_record_order_set,whole_value_complete,work_set_state,work_take_assignment,work_template_instantiate" },
2009
+ { code: "22023", raised_by: "_action_check,_automation_fire,_booking_availability,_ctx_reference_value_holds,_ctx_store_scope,_ctx_table_template_field_holds,_ctx_tree_part,_decorations_check,_entity_change_file,_entity_custom_fields_guard,_form_flow_judge,_form_look_judge,_fx_date,_fx_num,_fx_regex,_fx_unit,_fxp_level,_fxp_resolve,_fxp_tokens,_portal_config_judge,_rule_eval_seated,_table_dimensions_check,_take_op_id,_template_bind,_value_envelope,_view_field_key,_view_key_value,_work_shape_guard,_write_via_mark,action_run,actor_word,agent_change_trust,agg_assert_key,agg_calendar,agg_compare_windows,agg_sql,anon_token_issue,booking_declare,containment_parent,context_scope_write,context_scopes,context_template_define,context_type_write,context_values,count_records_archived,dashboard_block_normalize,dashboard_run,dashboard_target_field_assert,dashboard_window_sql,data_home,data_home_changed_by,doc_render_body,doc_render_write,doc_signature_write,drill_resolve,enrich_declare,enrich_land,enrich_normalize,enrich_pin,entity_back_links,entity_fields_across,entity_read_mask,entity_reference_rows,entity_reference_search,entity_reference_words,entity_row_write,entity_value_write,external_history_event,external_source_declare,external_stub_upsert,external_write_through,field_access,field_history,field_update,form_declare,form_draft_save,form_visit,formula_eval,formula_parse,grid_layout_check,hub_changed_by,inbound_domain,inbox_snooze,io_export,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,list_portals,listed_predicate_sql,member_records_take_over,migrate_merge,migrate_reclass,my_levels,organization_clear,page_size,pick_list_create,pin_agent_cells,pipeline_move,pipeline_move_many,portal_declare,portal_form_submit,provenance_write,publish_bind,query_by_coordinates,query_rollup,query_rollup_sum,read_records_archived,read_records_in_view_order,read_records_keyset,read_records_page,record_aggregate_as_of,record_change_many,record_filter_sql,record_row_controls_set,record_search_sql,record_update,record_upsert,record_write_graph,record_write_graph_superseding,record_write_many,records_search,relation_carry,relation_names_match,row_template_declare,rule_eval,rule_filter_node_sql,rule_members,rule_members_visible,rule_sql_op,scope_table_provision,share_grant,share_lane_set,sign_request_create,sign_request_sign,subscription_declare,table_archive_deliberately,table_ensure,table_find,table_from_example,table_move,table_row_defaults_set,table_rules,table_share_outside_grant,table_sync,table_template_declare,table_transfer_owner,table_webhook_declare,template_declare,template_from_tables,template_install_claim,template_install_note,template_upgrade,templates,view_declare,view_keys_check,view_look_set,view_record_order_set,visibility_as_of,where_lists_live,where_tables_live,work_approval_request,work_decide_many,work_inbox,work_list,work_slot_hold" },
2010
+ { code: "23503", raised_by: "_action_check,_automation_fire,_automation_flip,_booking_availability,_checklist_instantiate,_containment_guard,_ctx_store_value,_decorations_check,_display_spec_for,_field_document_for,_field_type_parity_guard,_form_flow_judge,_pipeline_stage_key,_record_rule_uses,action_declare,action_run,agg_digest_assemble,anon_publish,anon_rate_take,anon_token_issue,anon_write,assert_organization_wall,automation_declare,automation_runs,automations,autonumber_backfill,booking_cancel,booking_confirm,booking_declare,booking_hold,booking_reschedule,capture_publish,checklist_declare,checklist_steps_table,comment_write,dashboard_declare,delete_rule,doc_sign,doc_template_save,enrich_declare,enrich_due,enrich_land,form_declare,form_draft_save,form_results,form_submit,grid_layout,home_add,inbound_declare,inbound_mail_land,inbound_set,io_comment_write,io_import_begin,io_import_finish,io_import_report,io_import_rows,io_proposal_accept,migrate_demote,migrate_promote,migrate_purge_hard,pipeline_board,pipeline_declare,pipeline_move,pipeline_read,pipeline_transition_refusal,promote_field,promote_table,read_records_in_view_order,read_records_page,record_applicability,record_reparent,record_write_graph_superseding,relation_carry,relation_own,resolve_first_match,row_template_declare,rule_applies,rule_declare,rule_eval,rule_filter_node_sql,rule_members,rule_members_visible,rule_run,sign_request_create,subscription_mute,subscription_preview,table_decorate,table_dimensions_set,table_from_example,table_webhook_archive,table_webhook_declare,view_declare,view_designate,view_look_set,view_record_order_set,whole_value_complete,work_set_state,work_take_assignment,work_template_instantiate" },
1997
2011
  { code: "23505", raised_by: "_ctx_store_item,_ctx_store_scope,_ctx_store_type,_portal_config_judge,_share_write_person,_unique_rule_holds,doc_sign,doc_signature_write,entity_field_declare,field_declare,field_restore,field_update,form_restore,home_add,inbound_declare,io_proposal_accept,relation_carry,relation_own,relation_restore,sign_request_cancel,sign_request_create,table_share_outside_resend,work_approval_decide,work_slot_hold" },
1998
- { code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_ctx_dataset_field_holds,_ctx_scope_parent_holds,_ctx_store_item,_ctx_value_fits_its_scope,_dated_values_guard,_derived_fields,_display_format_check,_display_spec_for,_entity_choice_keys,_entity_custom_fields_guard,_field_choices_save,_field_class_guard,_field_default_fitted,_field_document_for,_field_kind_shape_ok,_field_shape_guard,_field_type_parity_guard,_kind_value_ok,_merge_field_shape_guard,_merge_field_temporal_guard,_promoted_field_cap_guard,_record_rule_uses,_record_source_key_is_record,_relation_halves_agree,_relation_kernel_targets,_resolve_choice_words,_rule_shape_guard,_rule_topology_guard,_store_relation_edge_names_its_field,_table_columns_word_guard,_table_shape_guard,_undeclared_key_guard,_value_envelope,_with_display,_work_shape_guard,_workdoors_approval_guard,action_run,assert_columns_are_defined,assert_entity_is_organization_scoped,booking_declare,capture_publish,capture_sheet_declare,checklist_declare,checklist_step_complete,dashboard_restore,doc_sign,doc_signature_write,doc_template_restore,doc_template_save,entity_field_protect_arman_explicitly_approved,entity_field_retire,entity_field_update,entity_records_find,entity_table,entity_value_write,field_declare,field_restore,field_retire,field_update,field_update_rehoming_choices,form_restore,home_add,io_comment_write,io_import_rows,migrate_merge,migrate_purge_hard,portal_archive,portal_restore,record_restore,record_update_adding_choices,record_upsert,record_write_graph,record_write_graph_superseding,relation_carry,relation_halves_repair,relation_own,relation_restore,rollup_value,row_template_declare,rule_restore,sign_request_create,sign_request_sign,status_groups_keyed,status_groups_of,table_from_example,table_restore,template_upgrade,validate_value_envelope,validate_values,whole_value_complete,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
2012
+ { code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_ctx_scope_parent_holds,_ctx_store_item,_ctx_table_template_field_holds,_ctx_value_fits_its_scope,_dated_values_guard,_derived_fields,_display_format_check,_display_spec_for,_entity_choice_keys,_entity_custom_fields_guard,_field_choices_save,_field_class_guard,_field_default_fitted,_field_document_for,_field_kind_shape_ok,_field_shape_guard,_field_type_parity_guard,_kind_value_ok,_merge_field_shape_guard,_merge_field_temporal_guard,_promoted_field_cap_guard,_record_rule_uses,_record_source_key_is_record,_relation_halves_agree,_relation_kernel_targets,_resolve_choice_words,_rule_shape_guard,_rule_topology_guard,_store_relation_edge_names_its_field,_table_columns_word_guard,_table_shape_guard,_undeclared_key_guard,_value_envelope,_with_display,_work_shape_guard,_workdoors_approval_guard,action_run,assert_columns_are_defined,assert_entity_is_organization_scoped,booking_declare,capture_publish,capture_sheet_declare,checklist_declare,checklist_step_complete,dashboard_restore,doc_sign,doc_signature_write,doc_template_restore,doc_template_save,entity_field_protect_arman_explicitly_approved,entity_field_retire,entity_field_update,entity_records_find,entity_table,entity_value_write,field_declare,field_restore,field_retire,field_update,field_update_rehoming_choices,form_restore,home_add,io_comment_write,io_import_rows,migrate_merge,migrate_purge_hard,portal_archive,portal_restore,record_restore,record_update_adding_choices,record_upsert,record_write_graph,record_write_graph_superseding,relation_carry,relation_halves_repair,relation_own,relation_restore,rollup_value,row_template_declare,rule_restore,sign_request_create,sign_request_sign,status_groups_keyed,status_groups_of,table_from_example,table_restore,template_upgrade,validate_value_envelope,validate_values,whole_value_complete,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
1999
2013
  { code: "40001", raised_by: "has_visibility_at,table_move,whole_value_complete" },
2000
- { code: "42501", raised_by: "_agent_change_gate,_context_copy_fence,_copy_evaluation_note,_copy_evaluation_reimage,_copy_in_progress_guard,_doc_render_immutable,_doc_signature_immutable,_entity_change_file,_entity_custom_fields_guard,_field_definition_write,_field_write_door,_io_outbox_server_only,_not_a_member_refusal,_portal_config_judge,_portal_principal_here,_read_record_with,_rule_definition_write,_share_write_person,_store_door,_table_dimensions_infer,_table_duplicate_step,_table_shape_guard,_template_call,_value_envelope,_workdoors_approval_guard,agent_change_trust,agent_table_claim,agg_fields_readable_assert,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_open,assert_may_know_table,assert_organization_admin,assert_scope_door,assert_store_door,booking_confirm,booking_declare,booking_hold,capture_submit,checklist_run,comment_write,context_item_archive,context_item_restore,context_item_write,context_resolve,context_scope_archive,context_scope_restore,context_scope_write,context_tags_set,context_type_archive,context_type_restore,context_type_write,conversation_scope_bind,conversation_scope_unbind,count_records_archived,dashboard_target_field_assert,doc_sign,enrich_declare,enrich_due,enrich_land,enrich_normalize,entity_field_declare,entity_field_retire,entity_field_update,entity_row_propose,entity_row_write,entity_value_write,external_write_through,field_restore,form_declare,form_draft_save,form_public_asks,form_submit,inbound_mail_land,inbox_clear,inbox_snooze,inbox_unclear,inbox_unsnooze,io_comment_resolve,io_comment_write,io_import_begin,io_import_finish,io_restore,member_personal_tables,migrate_purge,migrate_purge_hard,migrate_purge_hard_request,migrate_reclass,my_levels,organization_clear,organization_contents,portal_declare,portal_form,portal_form_submit,portal_invitation,portal_invite,portal_invite_accept,portal_principal_bind,promote_table,protected_matches,query_visibility_parity,read_record,read_records,read_records_archived,read_records_by_ids,read_records_keyset,read_records_matching,read_records_page,record_delete,record_row_controls,record_table,record_write_graph,relation_halves_disagreements,relation_halves_repair,resolve_context,reverse_links_many,scope_table_provision,share_grant,subscription_mute,subscription_preview,table_archive_deliberately,table_copies_in_progress,table_duplicate,table_duplicate_continue,table_kind_facts,table_move,table_row_defaults_apply,table_row_defaults_set,table_share_outside_accept,table_share_outside_grant,table_share_outside_invite,table_share_outside_resend,table_sync,table_transfer_owner,table_webhook_declare,template_declare,template_install,template_upgrade,templates,view_declare,view_look_set,view_record_order_set,visibility_as_of,where_lists_live,where_tables_live,whole_value_complete,work_approval_decide,work_approval_read,work_approval_request,work_person" },
2014
+ { code: "42501", raised_by: "_agent_change_gate,_context_copy_fence,_copy_evaluation_note,_copy_evaluation_reimage,_copy_in_progress_guard,_doc_render_immutable,_doc_signature_immutable,_entity_change_file,_entity_custom_fields_guard,_field_definition_write,_field_write_door,_io_outbox_server_only,_not_a_member_refusal,_portal_config_judge,_portal_principal_here,_read_record_with,_rule_definition_write,_share_write_person,_store_door,_table_dimensions_infer,_table_duplicate_step,_table_shape_guard,_template_call,_value_envelope,_workdoors_approval_guard,agent_change_trust,agent_table_claim,agg_fields_readable_assert,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_open,assert_may_know_table,assert_organization_admin,assert_scope_door,assert_store_door,booking_confirm,booking_declare,booking_hold,capture_submit,checklist_run,comment_write,context_item_archive,context_item_restore,context_item_write,context_resolve,context_scope_archive,context_scope_restore,context_scope_write,context_tags_set,context_type_archive,context_type_restore,context_type_write,conversation_scope_bind,conversation_scope_unbind,count_records_archived,dashboard_target_field_assert,doc_sign,enrich_declare,enrich_due,enrich_land,enrich_normalize,entity_field_declare,entity_field_retire,entity_field_update,entity_row_propose,entity_row_write,entity_value_write,external_write_through,field_restore,form_declare,form_draft_save,form_public_asks,form_submit,inbound_mail_land,inbox_clear,inbox_snooze,inbox_unclear,inbox_unsnooze,io_comment_resolve,io_comment_write,io_import_begin,io_import_finish,io_restore,member_personal_tables,migrate_purge,migrate_purge_hard,migrate_purge_hard_request,migrate_reclass,my_levels,organization_clear,organization_contents,portal_declare,portal_form,portal_form_submit,portal_invitation,portal_invite,portal_invite_accept,portal_principal_bind,promote_table,protected_matches,query_visibility_parity,read_record,read_records,read_records_archived,read_records_by_ids,read_records_keyset,read_records_matching,read_records_page,record_delete,record_row_controls,record_table,record_write_graph,relation_halves_disagreements,relation_halves_repair,resolve_context,reverse_links_many,scope_table_provision,share_grant,subscription_mute,subscription_preview,table_archive_deliberately,table_copies_in_progress,table_duplicate,table_duplicate_continue,table_kind_facts,table_move,table_row_defaults_apply,table_row_defaults_set,table_share_outside_accept,table_share_outside_grant,table_share_outside_invite,table_share_outside_resend,table_sync,table_templates,table_transfer_owner,table_webhook_declare,template_declare,template_install,template_upgrade,templates,view_declare,view_look_set,view_record_order_set,visibility_as_of,where_lists_live,where_tables_live,whole_value_complete,work_approval_decide,work_approval_read,work_approval_request,work_person" },
2001
2015
  { code: "42703", raised_by: "entity_table,portal_declare" },
2002
2016
  { code: "42883", raised_by: "_template_call" },
2003
2017
  { code: "42P17", raised_by: "_field_reads_what_it_reads,far_value" },
@@ -2018,6 +2032,7 @@ var ENTITY_TOKENS = [
2018
2032
  "access_delta_run",
2019
2033
  "access_request",
2020
2034
  "account_addon",
2035
+ "account_closure",
2021
2036
  "acquisition_block",
2022
2037
  "activity",
2023
2038
  "admin_audit_log",
@@ -2057,6 +2072,7 @@ var ENTITY_TOKENS = [
2057
2072
  "ai_usage_hourly_watermark",
2058
2073
  "analysis_result",
2059
2074
  "anon_form",
2075
+ "anon_form_visit",
2060
2076
  "anon_function_birth_grandfather",
2061
2077
  "anon_hit",
2062
2078
  "anon_inbound",
@@ -2659,6 +2675,7 @@ var ENTITY_TOKENS = [
2659
2675
  "oauth_handoff_claim",
2660
2676
  "opinion_clusters",
2661
2677
  "opinions",
2678
+ "ops_auth_lock_watchdog_log",
2662
2679
  "ops_check_item",
2663
2680
  "ops_check_run",
2664
2681
  "ops_db_host_sample",
@@ -2701,6 +2718,7 @@ var ENTITY_TOKENS = [
2701
2718
  "pdf_redaction_audit",
2702
2719
  "pdf_redaction_key_escrow",
2703
2720
  "permission_grant",
2721
+ "personal_data_column",
2704
2722
  "plan_cms_fill_item",
2705
2723
  "plan_cms_fill_job",
2706
2724
  "plan_entity",
@@ -2766,6 +2784,10 @@ var ENTITY_TOKENS = [
2766
2784
  "provision_spec_grandfather",
2767
2785
  "provision_vocabulary",
2768
2786
  "provlock_recall_visits_all8u5",
2787
+ "public_compat_wrapper",
2788
+ "public_placement_baseline",
2789
+ "public_placement_domain",
2790
+ "public_restore_permit",
2769
2791
  "purpose",
2770
2792
  "quiz_session",
2771
2793
  "rag_ingest_run",
@@ -3465,6 +3487,10 @@ var DOORS = {
3465
3487
  * organization wall and the caller's own rung on the Table — never `rule_eval` from a browser.
3466
3488
  */
3467
3489
  formPreviewAsks: "form_preview_asks",
3490
+ /** TYPEFORM-DUP: the owner's preview of the whole route — jumps, ending, score (`custom._form_route`). */
3491
+ formPreviewRoute: "form_preview_route",
3492
+ /** TYPEFORM-DUP: views, starts, completions, drop-off and answers per question. */
3493
+ formResults: "form_results",
3468
3494
  formLookOptions: "form_look_options",
3469
3495
  // PRODUCTS row 14 — "let clients book a 30-minute consult". A booking page IS an
3470
3496
  // `anon_form`, so it is opened and closed by `anonPublish` like any other; this is
@@ -3782,6 +3808,13 @@ var DOORS = {
3782
3808
  actionDeclare: "action_declare",
3783
3809
  rowActions: "row_actions",
3784
3810
  actionRun: "action_run",
3811
+ // AUTOMATION-DOOR (2026-10-07) — automations on a table. See ../automation.ts.
3812
+ automationDeclare: "automation_declare",
3813
+ automations: "automations",
3814
+ automationArchive: "automation_archive",
3815
+ automationRestore: "automation_restore",
3816
+ automationSetEnabled: "automation_set_enabled",
3817
+ automationRuns: "automation_runs",
3785
3818
  tableWebhookDeclare: "table_webhook_declare",
3786
3819
  tableWebhooks: "table_webhooks",
3787
3820
  tableWebhookArchive: "table_webhook_archive",
@@ -5385,6 +5418,20 @@ function createRecordsClient(given) {
5385
5418
  "formPreviewAsks"
5386
5419
  );
5387
5420
  },
5421
+ async formPreviewRoute({ table_id, questions, endings, values }) {
5422
+ return callDoor(
5423
+ DOORS.formPreviewRoute,
5424
+ { p_organization_id: org, p_table_id: table_id, p_questions: questions, p_endings: endings ?? [], p_values: values },
5425
+ "formPreviewRoute"
5426
+ );
5427
+ },
5428
+ async formResults({ form_id }) {
5429
+ return callDoor(
5430
+ DOORS.formResults,
5431
+ { p_organization_id: org, p_form_id: form_id },
5432
+ "formResults"
5433
+ );
5434
+ },
5388
5435
  async formLookOptions(args) {
5389
5436
  return callDoor(
5390
5437
  DOORS.formLookOptions,
@@ -7061,6 +7108,48 @@ function createRecordsClient(given) {
7061
7108
  }
7062
7109
  return result;
7063
7110
  },
7111
+ async automationDeclare({ table_id, spec, automation_id }) {
7112
+ return callDoor(
7113
+ DOORS.automationDeclare,
7114
+ { p_organization_id: org, p_table_id: table_id, p_spec: spec, p_automation_id: automation_id ?? null },
7115
+ "automationDeclare"
7116
+ );
7117
+ },
7118
+ async automations({ table_id, include_archived }) {
7119
+ return callDoor(
7120
+ DOORS.automations,
7121
+ { p_table_id: table_id, p_organization_id: org, p_include_archived: include_archived ?? false },
7122
+ "automations"
7123
+ );
7124
+ },
7125
+ async automationArchive({ automation_id }) {
7126
+ return callDoor(
7127
+ DOORS.automationArchive,
7128
+ { p_organization_id: org, p_automation_id: automation_id },
7129
+ "automationArchive"
7130
+ );
7131
+ },
7132
+ async automationRestore({ automation_id }) {
7133
+ return callDoor(
7134
+ DOORS.automationRestore,
7135
+ { p_organization_id: org, p_automation_id: automation_id },
7136
+ "automationRestore"
7137
+ );
7138
+ },
7139
+ async automationSetEnabled({ automation_id, enabled }) {
7140
+ return callDoor(
7141
+ DOORS.automationSetEnabled,
7142
+ { p_organization_id: org, p_automation_id: automation_id, p_enabled: enabled },
7143
+ "automationSetEnabled"
7144
+ );
7145
+ },
7146
+ async automationRuns({ automation_id, limit, cursor }) {
7147
+ return callDoor(
7148
+ DOORS.automationRuns,
7149
+ { p_automation_id: automation_id, p_limit: limit ?? 50, p_cursor: cursor ?? null, p_organization_id: org },
7150
+ "automationRuns"
7151
+ );
7152
+ },
7064
7153
  async tableWebhookDeclare({ table_id, target_url, events, description }) {
7065
7154
  return callDoor(
7066
7155
  DOORS.tableWebhookDeclare,
@@ -9763,7 +9852,7 @@ function createTableDataPort({ client, aliases }) {
9763
9852
  const levels = await seat(binding).myLevels({ ids: [binding.tableId] });
9764
9853
  level = levels.ok ? levels.data[0]?.level ?? null : null;
9765
9854
  }
9766
- const may = atLeast(level, "editor");
9855
+ const may = atLeast(level, "edit_content");
9767
9856
  out.push({ alias, label: binding.label ?? table.data?.name ?? alias, kind: "table", canCreate: may, canUpdate: may });
9768
9857
  }
9769
9858
  return { ok: true, data: out };