@ai-matrx/records 0.3.0 → 0.4.1

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.
@@ -297,6 +297,11 @@ declare const STORE_DOORS: readonly [{
297
297
  readonly args: "p_organization_id uuid, p_table_id uuid, p_record_type text DEFAULT NULL::text";
298
298
  readonly returns: "SETOF custom.record";
299
299
  readonly security: "definer";
300
+ }, {
301
+ readonly name: "assert_client_may_change";
302
+ readonly args: "p_organization_id uuid, p_subject_id uuid, p_door text, p_required permission_level DEFAULT 'editor'::permission_level, p_subject_word text DEFAULT 'record'::text";
303
+ readonly returns: "void";
304
+ readonly security: "invoker";
300
305
  }, {
301
306
  readonly name: "assert_client_may_reach";
302
307
  readonly args: "p_organization_id uuid, p_door text";
@@ -452,6 +457,16 @@ declare const STORE_DOORS: readonly [{
452
457
  readonly args: "p_organization_id uuid, p_table_id uuid, p_body text";
453
458
  readonly returns: "TABLE(raw text, field_id uuid, why text)";
454
459
  readonly security: "invoker";
460
+ }, {
461
+ readonly name: "doors_not_deciding_the_caller";
462
+ readonly args: "";
463
+ readonly returns: "TABLE(function_name text, identity_args text)";
464
+ readonly security: "invoker";
465
+ }, {
466
+ readonly name: "doors_not_deciding_the_record";
467
+ readonly args: "";
468
+ readonly returns: "TABLE(function_name text, identity_args text, why text)";
469
+ readonly security: "invoker";
455
470
  }, {
456
471
  readonly name: "export_records";
457
472
  readonly args: "p_organization_id uuid, p_table_id uuid, p_limit integer DEFAULT 1000";
@@ -732,6 +747,11 @@ declare const STORE_DOORS: readonly [{
732
747
  readonly args: "p_organization_id uuid, p_record_id uuid, p_moved_keys text[], p_note text DEFAULT NULL::text";
733
748
  readonly returns: "jsonb";
734
749
  readonly security: "invoker";
750
+ }, {
751
+ readonly name: "organization_kernel_id";
752
+ readonly args: "";
753
+ readonly returns: "uuid";
754
+ readonly security: "invoker";
735
755
  }, {
736
756
  readonly name: "organization_references";
737
757
  readonly args: "p_kind text, p_organization_id uuid, p_row jsonb";
@@ -762,6 +782,11 @@ declare const STORE_DOORS: readonly [{
762
782
  readonly args: "";
763
783
  readonly returns: "uuid";
764
784
  readonly security: "invoker";
785
+ }, {
786
+ readonly name: "presentation_kernel_id";
787
+ readonly args: "";
788
+ readonly returns: "uuid";
789
+ readonly security: "invoker";
765
790
  }, {
766
791
  readonly name: "promote_field";
767
792
  readonly args: "p_organization_id uuid, p_table_id uuid, p_field_id uuid";
@@ -1237,6 +1262,11 @@ declare const STORE_DOORS: readonly [{
1237
1262
  readonly args: "p_user_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level";
1238
1263
  readonly returns: "TABLE(id uuid)";
1239
1264
  readonly security: "definer";
1265
+ }, {
1266
+ readonly name: "widget_kernel_id";
1267
+ readonly args: "";
1268
+ readonly returns: "uuid";
1269
+ readonly security: "invoker";
1240
1270
  }, {
1241
1271
  readonly name: "work_assignment_fields";
1242
1272
  readonly args: "p_options_table_id uuid DEFAULT NULL::uuid";
@@ -1333,6 +1363,10 @@ declare const STORE_KNOBS: readonly [{
1333
1363
  readonly key: "accessible_entity_ids_guard";
1334
1364
  readonly value: "false";
1335
1365
  readonly type: "boolean";
1366
+ }, {
1367
+ readonly key: "agent_schema_changes";
1368
+ readonly value: "\"propose\"";
1369
+ readonly type: "string";
1336
1370
  }, {
1337
1371
  readonly key: "associations_guard";
1338
1372
  readonly value: "false";
@@ -1341,6 +1375,38 @@ declare const STORE_KNOBS: readonly [{
1341
1375
  readonly key: "code_paths_enabled";
1342
1376
  readonly value: "false";
1343
1377
  readonly type: "boolean";
1378
+ }, {
1379
+ readonly key: "consumer_chat_seeding_enabled";
1380
+ readonly value: "false";
1381
+ readonly type: "boolean";
1382
+ }, {
1383
+ readonly key: "consumer_checkout_enabled";
1384
+ readonly value: "false";
1385
+ readonly type: "boolean";
1386
+ }, {
1387
+ readonly key: "consumer_education_enabled";
1388
+ readonly value: "false";
1389
+ readonly type: "boolean";
1390
+ }, {
1391
+ readonly key: "consumer_extension_enabled";
1392
+ readonly value: "false";
1393
+ readonly type: "boolean";
1394
+ }, {
1395
+ readonly key: "consumer_grid_enabled";
1396
+ readonly value: "false";
1397
+ readonly type: "boolean";
1398
+ }, {
1399
+ readonly key: "consumer_retirement_enabled";
1400
+ readonly value: "false";
1401
+ readonly type: "boolean";
1402
+ }, {
1403
+ readonly key: "consumer_saved_ai_outputs_enabled";
1404
+ readonly value: "false";
1405
+ readonly type: "boolean";
1406
+ }, {
1407
+ readonly key: "consumer_scopes_enabled";
1408
+ readonly value: "false";
1409
+ readonly type: "boolean";
1344
1410
  }, {
1345
1411
  readonly key: "containment_depth_ceiling";
1346
1412
  readonly value: "16";
@@ -1457,7 +1523,7 @@ declare const STORE_REFUSAL_CODES: readonly [{
1457
1523
  readonly raised_by: "has_visibility_at";
1458
1524
  }, {
1459
1525
  readonly code: "42501";
1460
- readonly raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records";
1526
+ readonly raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records";
1461
1527
  }, {
1462
1528
  readonly code: "53400";
1463
1529
  readonly raised_by: "anon_rate_take,promote_field";
@@ -297,6 +297,11 @@ declare const STORE_DOORS: readonly [{
297
297
  readonly args: "p_organization_id uuid, p_table_id uuid, p_record_type text DEFAULT NULL::text";
298
298
  readonly returns: "SETOF custom.record";
299
299
  readonly security: "definer";
300
+ }, {
301
+ readonly name: "assert_client_may_change";
302
+ readonly args: "p_organization_id uuid, p_subject_id uuid, p_door text, p_required permission_level DEFAULT 'editor'::permission_level, p_subject_word text DEFAULT 'record'::text";
303
+ readonly returns: "void";
304
+ readonly security: "invoker";
300
305
  }, {
301
306
  readonly name: "assert_client_may_reach";
302
307
  readonly args: "p_organization_id uuid, p_door text";
@@ -452,6 +457,16 @@ declare const STORE_DOORS: readonly [{
452
457
  readonly args: "p_organization_id uuid, p_table_id uuid, p_body text";
453
458
  readonly returns: "TABLE(raw text, field_id uuid, why text)";
454
459
  readonly security: "invoker";
460
+ }, {
461
+ readonly name: "doors_not_deciding_the_caller";
462
+ readonly args: "";
463
+ readonly returns: "TABLE(function_name text, identity_args text)";
464
+ readonly security: "invoker";
465
+ }, {
466
+ readonly name: "doors_not_deciding_the_record";
467
+ readonly args: "";
468
+ readonly returns: "TABLE(function_name text, identity_args text, why text)";
469
+ readonly security: "invoker";
455
470
  }, {
456
471
  readonly name: "export_records";
457
472
  readonly args: "p_organization_id uuid, p_table_id uuid, p_limit integer DEFAULT 1000";
@@ -732,6 +747,11 @@ declare const STORE_DOORS: readonly [{
732
747
  readonly args: "p_organization_id uuid, p_record_id uuid, p_moved_keys text[], p_note text DEFAULT NULL::text";
733
748
  readonly returns: "jsonb";
734
749
  readonly security: "invoker";
750
+ }, {
751
+ readonly name: "organization_kernel_id";
752
+ readonly args: "";
753
+ readonly returns: "uuid";
754
+ readonly security: "invoker";
735
755
  }, {
736
756
  readonly name: "organization_references";
737
757
  readonly args: "p_kind text, p_organization_id uuid, p_row jsonb";
@@ -762,6 +782,11 @@ declare const STORE_DOORS: readonly [{
762
782
  readonly args: "";
763
783
  readonly returns: "uuid";
764
784
  readonly security: "invoker";
785
+ }, {
786
+ readonly name: "presentation_kernel_id";
787
+ readonly args: "";
788
+ readonly returns: "uuid";
789
+ readonly security: "invoker";
765
790
  }, {
766
791
  readonly name: "promote_field";
767
792
  readonly args: "p_organization_id uuid, p_table_id uuid, p_field_id uuid";
@@ -1237,6 +1262,11 @@ declare const STORE_DOORS: readonly [{
1237
1262
  readonly args: "p_user_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level";
1238
1263
  readonly returns: "TABLE(id uuid)";
1239
1264
  readonly security: "definer";
1265
+ }, {
1266
+ readonly name: "widget_kernel_id";
1267
+ readonly args: "";
1268
+ readonly returns: "uuid";
1269
+ readonly security: "invoker";
1240
1270
  }, {
1241
1271
  readonly name: "work_assignment_fields";
1242
1272
  readonly args: "p_options_table_id uuid DEFAULT NULL::uuid";
@@ -1333,6 +1363,10 @@ declare const STORE_KNOBS: readonly [{
1333
1363
  readonly key: "accessible_entity_ids_guard";
1334
1364
  readonly value: "false";
1335
1365
  readonly type: "boolean";
1366
+ }, {
1367
+ readonly key: "agent_schema_changes";
1368
+ readonly value: "\"propose\"";
1369
+ readonly type: "string";
1336
1370
  }, {
1337
1371
  readonly key: "associations_guard";
1338
1372
  readonly value: "false";
@@ -1341,6 +1375,38 @@ declare const STORE_KNOBS: readonly [{
1341
1375
  readonly key: "code_paths_enabled";
1342
1376
  readonly value: "false";
1343
1377
  readonly type: "boolean";
1378
+ }, {
1379
+ readonly key: "consumer_chat_seeding_enabled";
1380
+ readonly value: "false";
1381
+ readonly type: "boolean";
1382
+ }, {
1383
+ readonly key: "consumer_checkout_enabled";
1384
+ readonly value: "false";
1385
+ readonly type: "boolean";
1386
+ }, {
1387
+ readonly key: "consumer_education_enabled";
1388
+ readonly value: "false";
1389
+ readonly type: "boolean";
1390
+ }, {
1391
+ readonly key: "consumer_extension_enabled";
1392
+ readonly value: "false";
1393
+ readonly type: "boolean";
1394
+ }, {
1395
+ readonly key: "consumer_grid_enabled";
1396
+ readonly value: "false";
1397
+ readonly type: "boolean";
1398
+ }, {
1399
+ readonly key: "consumer_retirement_enabled";
1400
+ readonly value: "false";
1401
+ readonly type: "boolean";
1402
+ }, {
1403
+ readonly key: "consumer_saved_ai_outputs_enabled";
1404
+ readonly value: "false";
1405
+ readonly type: "boolean";
1406
+ }, {
1407
+ readonly key: "consumer_scopes_enabled";
1408
+ readonly value: "false";
1409
+ readonly type: "boolean";
1344
1410
  }, {
1345
1411
  readonly key: "containment_depth_ceiling";
1346
1412
  readonly value: "16";
@@ -1457,7 +1523,7 @@ declare const STORE_REFUSAL_CODES: readonly [{
1457
1523
  readonly raised_by: "has_visibility_at";
1458
1524
  }, {
1459
1525
  readonly code: "42501";
1460
- readonly raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records";
1526
+ readonly raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records";
1461
1527
  }, {
1462
1528
  readonly code: "53400";
1463
1529
  readonly raised_by: "anon_rate_take,promote_field";
@@ -101,6 +101,7 @@ var STORE_DOORS = [
101
101
  { name: "anon_token_verify", args: "p_secret text, p_origin text, p_required_mode text", returns: "TABLE(token_id uuid, organization_id uuid, form_id uuid, saved_view_id uuid, record_id uuid, mode text)", security: "definer" },
102
102
  { name: "anon_write", args: "p_secret text, p_origin text, p_payload jsonb, p_client_key text DEFAULT NULL::text, p_raw_payload jsonb DEFAULT '{}'::jsonb", returns: "uuid", security: "definer" },
103
103
  { name: "applicable_fields", args: "p_organization_id uuid, p_table_id uuid, p_record_type text DEFAULT NULL::text", returns: "SETOF custom.record", security: "definer" },
104
+ { name: "assert_client_may_change", args: "p_organization_id uuid, p_subject_id uuid, p_door text, p_required permission_level DEFAULT 'editor'::permission_level, p_subject_word text DEFAULT 'record'::text", returns: "void", security: "invoker" },
104
105
  { name: "assert_client_may_reach", args: "p_organization_id uuid, p_door text", returns: "void", security: "invoker" },
105
106
  { name: "assert_organization_wall", args: "p_kind text, p_organization_id uuid, p_row jsonb", returns: "void", security: "invoker" },
106
107
  { name: "assert_store_door", args: "p_organization_id uuid, p_door text", returns: "void", security: "invoker" },
@@ -132,6 +133,8 @@ var STORE_DOORS = [
132
133
  { name: "doc_token_pattern", args: "", returns: "text", security: "invoker" },
133
134
  { name: "doc_tokens", args: "p_body text", returns: "TABLE(ordinal integer, raw text, field_id uuid)", security: "invoker" },
134
135
  { name: "doc_unresolved_tokens", args: "p_organization_id uuid, p_table_id uuid, p_body text", returns: "TABLE(raw text, field_id uuid, why text)", security: "invoker" },
136
+ { name: "doors_not_deciding_the_caller", args: "", returns: "TABLE(function_name text, identity_args text)", security: "invoker" },
137
+ { name: "doors_not_deciding_the_record", args: "", returns: "TABLE(function_name text, identity_args text, why text)", security: "invoker" },
135
138
  { name: "export_records", args: "p_organization_id uuid, p_table_id uuid, p_limit integer DEFAULT 1000", returns: "TABLE(id uuid, document jsonb)", security: "invoker" },
136
139
  { name: "external_foreign_table_findings", args: "", returns: "SETOF text", security: "definer" },
137
140
  { name: "external_history_event", args: "p_organization_id uuid, p_link_id uuid, p_operation text", returns: "bigint", security: "definer" },
@@ -188,12 +191,14 @@ var STORE_DOORS = [
188
191
  { name: "migrate_reparent", args: "p_organization_id uuid, p_id uuid, p_parent_id uuid, p_note text DEFAULT NULL::text", returns: "jsonb", security: "invoker" },
189
192
  { name: "migrate_retype", args: "p_organization_id uuid, p_id uuid, p_to text, p_note text DEFAULT NULL::text", returns: "jsonb", security: "invoker" },
190
193
  { name: "migrate_split", args: "p_organization_id uuid, p_record_id uuid, p_moved_keys text[], p_note text DEFAULT NULL::text", returns: "jsonb", security: "invoker" },
194
+ { name: "organization_kernel_id", args: "", returns: "uuid", security: "invoker" },
191
195
  { name: "organization_references", args: "p_kind text, p_organization_id uuid, p_row jsonb", returns: "TABLE(site text, what text, ref_id uuid, openable boolean)", security: "invoker" },
192
196
  { name: "parity_field_types", args: "", returns: "TABLE(parity_type text, behavior text, made_of text)", security: "invoker" },
193
197
  { name: "parity_type", args: "p_field_data jsonb", returns: "text", security: "invoker" },
194
198
  { name: "parity_values", args: "p_organization_id uuid, p_record_id uuid", returns: "TABLE(field_key text, field_id uuid, parity_type text, behavior text, unit text, format text, value jsonb, value_version integer, actor text, written_at timestamp with time zone)", security: "invoker" },
195
199
  { name: "per_value_access_words", args: "", returns: "text[]", security: "invoker" },
196
200
  { name: "person_kernel_id", args: "", returns: "uuid", security: "invoker" },
201
+ { name: "presentation_kernel_id", args: "", returns: "uuid", security: "invoker" },
197
202
  { name: "promote_field", args: "p_organization_id uuid, p_table_id uuid, p_field_id uuid", returns: "jsonb", security: "invoker" },
198
203
  { name: "promote_table", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
199
204
  { name: "promoted_field_cap", args: "", returns: "integer", security: "invoker" },
@@ -289,6 +294,7 @@ var STORE_DOORS = [
289
294
  { name: "visibility_parity", args: "", returns: "TABLE(side text, container_type text, container_id uuid, item_type text, item_id uuid, stored_level permission_level, derived_level permission_level, reason text)", security: "definer" },
290
295
  { name: "visibility_warm", args: "p_container_type text, p_container_id uuid", returns: "integer", security: "definer" },
291
296
  { name: "visible_record_ids", args: "p_user_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level", returns: "TABLE(id uuid)", security: "definer" },
297
+ { name: "widget_kernel_id", args: "", returns: "uuid", security: "invoker" },
292
298
  { name: "work_assignment_fields", args: "p_options_table_id uuid DEFAULT NULL::uuid", returns: "TABLE(key text, label text, spec jsonb)", security: "invoker" },
293
299
  { name: "work_has_assignment", args: "p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "invoker" },
294
300
  { name: "work_instantiation_shape", args: "p_organization_id uuid, p_instantiation_id uuid", returns: "jsonb", security: "invoker" },
@@ -310,8 +316,17 @@ var STORE_DOORS = [
310
316
  ];
311
317
  var STORE_KNOBS = [
312
318
  { key: "accessible_entity_ids_guard", value: "false", type: "boolean" },
319
+ { key: "agent_schema_changes", value: '"propose"', type: "string" },
313
320
  { key: "associations_guard", value: "false", type: "boolean" },
314
321
  { key: "code_paths_enabled", value: "false", type: "boolean" },
322
+ { key: "consumer_chat_seeding_enabled", value: "false", type: "boolean" },
323
+ { key: "consumer_checkout_enabled", value: "false", type: "boolean" },
324
+ { key: "consumer_education_enabled", value: "false", type: "boolean" },
325
+ { key: "consumer_extension_enabled", value: "false", type: "boolean" },
326
+ { key: "consumer_grid_enabled", value: "false", type: "boolean" },
327
+ { key: "consumer_retirement_enabled", value: "false", type: "boolean" },
328
+ { key: "consumer_saved_ai_outputs_enabled", value: "false", type: "boolean" },
329
+ { key: "consumer_scopes_enabled", value: "false", type: "boolean" },
315
330
  { key: "containment_depth_ceiling", value: "16", type: "integer" },
316
331
  { key: "document_max_bytes", value: "1048576", type: "integer" },
317
332
  { key: "emergency_door_guard", value: "false", type: "boolean" },
@@ -343,7 +358,7 @@ var STORE_REFUSAL_CODES = [
343
358
  { code: "23505", raised_by: "doc_sign,doc_signature_write,home_add,io_proposal_accept,work_slot_hold" },
344
359
  { code: "23514", raised_by: "_containment_guard,_dated_values_guard,_derived_fields,_field_shape_guard,_field_type_parity_guard,_merge_field_shape_guard,_merge_field_temporal_guard,_promoted_field_cap_guard,_record_rule_uses,_rule_shape_guard,_rule_topology_guard,_table_shape_guard,_value_envelope,_work_shape_guard,doc_sign,doc_signature_write,doc_template_save,home_add,validate_value_envelope,validate_values,work_slots_declare,work_take_assignment,work_template_instantiate" },
345
360
  { code: "40001", raised_by: "has_visibility_at" },
346
- { code: "42501", raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records" },
361
+ { code: "42501", raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_reach,assert_store_door,external_write_through,io_comment_resolve,io_comment_write,io_restore,migrate_purge,promote_table,read_record,read_records" },
347
362
  { code: "53400", raised_by: "anon_rate_take,promote_field" },
348
363
  { code: "PT409", raised_by: "record_update" }
349
364
  ];