@ai-matrx/records 0.56.0 → 0.57.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.
package/dist/index.d.cts CHANGED
@@ -1,5 +1,5 @@
1
- import { p as Uuid, T as Timestamp, t as ReadRow, R as RecordDocument, aT as TableType, aR as TableDisplay, aL as StorageMode, aS as TableOrigin, S as StoredRecord, u as Field, ap as ParityFieldType, aG as RuleUse, aF as RuleNodeKind, C as RecordsError, U as UseCase, aD as RelationFlavor, al as OnDelete, aA as RelationBinding, aB as RelationCardinality, ai as MergeFieldSource, ah as MergeFieldSemanticType, ag as MergeFieldModifier, am as OverridePolicy, Z as Delivery, a9 as Freshness, K as Actor, D as PgError } from './types-RxnWzAWZ.cjs';
2
- export { H as ABSENCE_REASONS, I as ACTOR_VOCABULARY, J as AbsenceReason, L as COMPUTE_ON, M as CONTEXT_POLICIES, O as ComputeOn, Q as ContextPolicy, V as DECLARABLE_FIELD_KINDS, X as DELIVERIES, Y as DeclarableFieldKind, _ as ENTITY_TOKENS, $ as EntityToken, a0 as FIELD_SENSITIVITIES, a1 as FIELD_SOURCES, a2 as FRESHNESS, a3 as FieldBehavior, w as FieldPatch, z as FieldProposal, a4 as FieldRule, a5 as FieldSensitivity, a6 as FieldSource, a7 as FieldTypeWord, a8 as ForbiddenEnvelopeWord, aa as HiddenFieldNotice, ab as KERNEL_TABLES, ac as KernelTableName, ad as MERGE_FIELD_MODIFIERS, ae as MERGE_FIELD_SEMANTIC_TYPES, af as MERGE_FIELD_SOURCES, v as NewFieldDeclaration, aj as ON_DELETE, ak as OVERRIDE_POLICIES, an as PARITY_FIELD_TYPES, ao as PER_VALUE_ACCESS_WORDS, aq as ParityFieldTypeDescriptor, ar as PerValueAccessWord, G as PredictedRefusal, as as ProvenancePointer, at as RELATION_BINDINGS, au as RELATION_CARDINALITIES, av as RELATION_FLAVORS, aw as RETIRED_ACTOR_WORDS, ax as RULE_NODE_KINDS, ay as RULE_USES, y as ReadValue, r as RecordGraphWritten, s as RecordRead, x as RecordRevision, az as RecordsErrorCode, q as RecordsResult, aC as RelationDisplay, aE as RetiredActorWord, aH as STORAGE_MODES, aI as STORE_DOORS, aJ as STORE_KNOBS, aK as STORE_REFUSAL_CODES, E as StaleWriteDetail, aM as StoreDoorName, aN as StoreRefusalCode, aO as TABLE_DISPLAYS, aP as TABLE_ORIGINS, aQ as TABLE_TYPES, A as TableProposal, aU as VALUE_ALTERNATE_KEYS, aV as VALUE_ENVELOPE_KEYS, aW as ValueAlternate, aX as ValueAlternateKey, aY as ValueEnvelope, aZ as ValueEnvelopeKey, a_ as ValueSource, W as WriteConflict, a$ as err, b0 as isRecordsErr, b1 as ok } from './types-RxnWzAWZ.cjs';
1
+ import { p as Uuid, T as Timestamp, u as ReadRow, q as RecordDocument, aT as TableType, aR as TableDisplay, aL as StorageMode, aS as TableOrigin, S as StoredRecord, v as Field, aq as ParityFieldType, aG as RuleUse, aF as RuleNodeKind, D as RecordsError, U as UseCase, aD as RelationFlavor, am as OnDelete, aA as RelationBinding, aB as RelationCardinality, aj as MergeFieldSource, ai as MergeFieldSemanticType, ah as MergeFieldModifier, an as OverridePolicy, _ as Delivery, aa as Freshness, L as Actor, E as PgError } from './types-Bsamaf-a.cjs';
2
+ export { I as ABSENCE_REASONS, J as ACTOR_VOCABULARY, K as AbsenceReason, M as COMPUTE_ON, O as CONTEXT_POLICIES, Q as ComputeOn, V as ContextPolicy, X as DECLARABLE_FIELD_KINDS, Y as DELIVERIES, Z as DeclarableFieldKind, $ as ENTITY_TOKENS, a0 as EntityToken, a1 as FIELD_SENSITIVITIES, a2 as FIELD_SOURCES, a3 as FRESHNESS, a4 as FieldBehavior, x as FieldPatch, A as FieldProposal, a5 as FieldRule, a6 as FieldSensitivity, a7 as FieldSource, a8 as FieldTypeWord, a9 as ForbiddenEnvelopeWord, ab as HiddenFieldNotice, ac as KERNEL_TABLES, ad as KernelTableName, ae as MERGE_FIELD_MODIFIERS, af as MERGE_FIELD_SEMANTIC_TYPES, ag as MERGE_FIELD_SOURCES, w as NewFieldDeclaration, ak as ON_DELETE, al as OVERRIDE_POLICIES, ao as PARITY_FIELD_TYPES, ap as PER_VALUE_ACCESS_WORDS, ar as ParityFieldTypeDescriptor, as as PerValueAccessWord, H as PredictedRefusal, at as ProvenancePointer, au as RELATION_BINDINGS, av as RELATION_CARDINALITIES, aw as RELATION_FLAVORS, ax as RETIRED_ACTOR_WORDS, ay as RULE_NODE_KINDS, az as RULE_USES, z as ReadValue, s as RecordGraphWritten, t as RecordRead, y as RecordRevision, R as RecordsErrorCode, r as RecordsResult, aC as RelationDisplay, aE as RetiredActorWord, aH as STORAGE_MODES, aI as STORE_DOORS, aJ as STORE_KNOBS, aK as STORE_REFUSAL_CODES, G as StaleWriteDetail, aM as StoreDoorName, aN as StoreRefusalCode, aO as TABLE_DISPLAYS, aP as TABLE_ORIGINS, aQ as TABLE_TYPES, C as TableProposal, aU as VALUE_ALTERNATE_KEYS, aV as VALUE_ENVELOPE_KEYS, aW as ValueAlternate, aX as ValueAlternateKey, aY as ValueEnvelope, aZ as ValueEnvelopeKey, a_ as ValueSource, W as WriteConflict, a$ as allowsOtherValues, b0 as err, b1 as isRecordsErr, b2 as ok } from './types-Bsamaf-a.cjs';
3
3
 
4
4
  /**
5
5
  * THE TWO LANES THE ARCHIVED-ITEMS LAW NAMES (Arman, 2026-09-09) — the same
@@ -1521,7 +1521,7 @@ interface TableDecorations {
1521
1521
  type DecorationPath = ["color_by"] | ["rules"] | ["rows", Uuid] | ["columns", Uuid] | ["cells", Uuid, Uuid];
1522
1522
  type GridLayoutMode = "auto" | "fit" | "scroll";
1523
1523
  type GridRowHeight = "compact" | "normal" | "tall";
1524
- /** A saved view's own layout, kept at `definition.layout` (custom.view_declare judges it). */
1524
+ /** A saved view's own grid choices, kept at `definition.grid` (custom.view_declare judges them). `definition.layout` is the view's KIND (grid / kanban / calendar / gallery), never these. */
1525
1525
  interface ViewLayout {
1526
1526
  mode?: GridLayoutMode;
1527
1527
  row_height?: GridRowHeight;
@@ -1682,6 +1682,26 @@ interface IoExportPage {
1682
1682
  * (the Field's label); a key with no label is its own header.
1683
1683
  */
1684
1684
  declare function exportPageXlsx(page: IoExportPage, labels?: Record<string, string>, sheetLabel?: string): Promise<Uint8Array>;
1685
+ /** A record-store row event, as the activity spine carries it (and a schedule matches it). */
1686
+ type RecordChangeAction = RecordEvent;
1687
+ /**
1688
+ * THE SCHEDULE TRIGGER for "when a row of this record-store table changes, run …" — the same
1689
+ * `event` trigger the older store's tables use, pointed at this store's events:
1690
+ * `entity_type` `custom_record:<table id>`, actions `record.*`, `changed_fields` by column KEY.
1691
+ * `scheduler.sch_match_event` matches it against the event
1692
+ * `custom._record_events_to_activity` writes (GRID-PRIMITIVES G8), so one matcher serves both
1693
+ * stores. Omit `actions` to hear every change; omit `changedFields` to hear every column.
1694
+ */
1695
+ declare function recordChangeTrigger(tableId: Uuid, options?: {
1696
+ actions?: RecordChangeAction[];
1697
+ changedFields?: string[];
1698
+ }): {
1699
+ type: "event";
1700
+ entity_type: string;
1701
+ table_id: Uuid;
1702
+ actions?: RecordChangeAction[];
1703
+ changed_fields?: string[];
1704
+ };
1685
1705
 
1686
1706
  /** The seven shapes a block can take, exactly as `custom.dashboard_kinds()` answers. */
1687
1707
  type DashboardBlockKind = "number" | "bar" | "column" | "line" | "donut" | "table" | "stuck";
@@ -3522,4 +3542,4 @@ interface ConversationScopeContext {
3522
3542
  /** `About: Acme Industrial` — the chip a bound chat wears. */
3523
3543
  declare function scopeChip(scope: ConversationScope): string;
3524
3544
 
3525
- export { ARCHIVE_LANES, ARCHIVE_LANE_LABEL, ARCHIVE_LANE_MEANS, type ActionRefusal, type ActionRunResult, Actor, type AggregateBucket, type AggregateFilter, type AggregateMeasure, type AggregateOperation, type AggregateRow, type AggregateWindow, type AnonTokenBinding, type ArchiveLane, type ArchivedDoorRow, type ArchivedRow, type BookingAvailability, type BookingDeclared, type BookingSummary, type BookingWindow, type CaptureField, type CaptureFileRef, type CaptureOutcome, type CaptureQuestion, type CaptureQueue, type CaptureQueueCounts, type CaptureQueueOptions, type CaptureQueuePorts, type CaptureQueueStore, type CaptureSheetFace, type CaptureSheetSummary, type CaptureSyncReport, type ChecklistDeclared, type ChecklistRequirement, type ChecklistRequirementKind, type ChecklistRoleSpec, type ChecklistRunStarted, type ChecklistRunStep, type ChecklistRunSummary, type ChecklistSpec, type ChecklistStepCompleted, type ChecklistStepSpec, type ChecklistTemplateShape, type ChecklistTemplateSummary, type ChecklistTrigger, type ChecklistTriggerKind, type ChoiceOption, type ChoiceOptions, type CoerceOptions, type Coerced, type CoercedAnswers, type CoercibleField, type CommentThreadRead, type CommentWritten, type ConversationScope, type ConversationScopeContext, type CustomFieldTableType, DEFAULT_ARCHIVE_LANE, DEFAULT_PORTAL_ARCHIVE_FILTER, type DashboardBlock, type DashboardBlockKind, type DashboardBlockResult, type DashboardRunResult, type DashboardSummary, type DecorationColor, type DecorationPath, type DecorationRule, type DecorationRuleOp, type DecorationTarget, Delivery, type DigestPreview, type DocRenderRow, type DocSignatureCheck, type DocSignatureRow, type DocTemplateRow, type DocToken, type DocUnresolvedToken, type EnrichAlternate, type EnrichCell, type EnrichDeclared, type EnrichDueRow, type EnrichRun, type EnrichSource, type Enrichment, type EnrichmentSummary, type EntityFieldRights, type EntityFieldValue, type EntityRecordMatch, type EntityRecordRead, type EntityRecordsFound, type EntityTableFacts, type ExampleBuilt, type ExampleSpec, type ExternalPrincipalCard, FIELD_KINDS, Field, type FieldHistoryEntry, type FieldKind, type FormSummary, type FormulaParse, Freshness, type GridLayout, type GridLayoutMode, type GridRowHeight, type HistoryActor, type HistoryActorKind, type HistoryChange, type Home, type ImportBatchResult, type ImportColumnPlan, type ImportColumnsDeclared, type ImportFinished, type ImportOpened, type ImportOutcome, type ImportPlan, type ImportPolicy, type ImportProposal, type ImportReport, type ImportRun, type InboundAddress, type InboundDeclared, type IoExportPage, type KernelTargets, type MergeField, MergeFieldModifier, type MergeFieldProvenance, type MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, type MergeFieldTransform, type MissingBehavior, type MyLevel, type MySubscription, type NewEntityFieldDeclaration, OnDelete, OverridePolicy, PERMISSION_LEVELS, PIPELINE_RULE_KINDS, PORTAL_ARCHIVE_FILTERS, ParityFieldType, type PermissionLevel, PgError, type Pipeline, type PipelineColumn, type PipelineDeclared, type PipelineGate, type PipelineGatePreview, type PipelineMissingField, type PipelineMoveResult, type PipelineRule, type PipelineRuleKind, type PipelineSpec, type PipelineStage, type PipelineVerdict, type PortalArchiveAnswer, type PortalArchiveFilter, type PortalCard, type PortalInvitation, type PortalPreviewRow, type PortalPrincipal, type PortalRevocation, type PortalSummary, type PortalTableExposure, type PortalTableRef, type PublishBinding, type QueuedCapture, type QueuedCaptureFile, type QueuedCaptureState, type QuietHours, REFUSALS_WORTH_REPEATING, ReadRow, type RecordComment, RecordDocument, type RecordEvent, type RecordFilter, type RecordHistoryEntry, type RecordScopeComment, type RecordScopeContext, type RecordScopeField, type RecordScopeHistoryEntry, type RecordScopeRelation, type RecordScopeWithheld, type RecordsActor, type RecordsChangeSink, type RecordsConfig, type RecordsDataSource, RecordsError, type RecordsErrorSink, type RecordsFilter, type RecordsRealtimePort, type RecordsResolverPort, type RecordsResponse, type RecordsTableQuery, type RegisteredTable, type Relation, RelationBinding, RelationCardinality, type RelationCarries, type RelationCoordinate, type RelationDisplaySpec, RelationFlavor, type RelationProperties, type RelationStore, type RelationTarget, type RelationWordsManyArgs, type ResolutionTriple, type ResolvedPublishBinding, type RestorePreview, type RestoreResult, type RowAction, type RowActionStep, type Rule, type RuleAnswer, type RuleExpression, RuleNodeKind, RuleUse, STAGE_RULE_ENFORCEMENT, STAGE_RULE_ON_FAIL, type SavedViewRow, type SavedViewSpecIn, type StagePending, type StagePendingOnBoard, type StageRuleEnforcement, type StageRuleOnFail, type StageRuleWarning, StorageMode, StoredRecord, type StuckRow, type Subscription, type SubscriptionBlock, type SubscriptionCadence, type SubscriptionSpec, type Table, type TableArchiveProgress, type TableCapacity, type TableDecorations, TableDisplay, TableOrigin, TableType, type TableWebhook, type TableWebhookDeclared, Timestamp, Uuid, type ViewLayout, type WorkApprovalDecision, type WorkApprovalFiled, type WorkApprover, type WorkAssignment, type WorkAssignmentField, type WorkChange, type WorkDueState, type WorkGraph, type WorkInboxItem, type WorkInboxKind, type WorkInstantiation, type WorkListFlavour, type WorkListItem, type WorkOrigin, type WorkRecordState, type WorkSlotHold, type WorkState, type WorkTemplateNode, type WorkTemplateRelation, type WorkTurn, actionRefusals, archivedByLine, archivedWhen, asPermissionLevel, atLeast, bookingPath, choiceSlug, choiceValuesOf, choicesOf, coerceTypedAnswer, coerceTypedAnswers, coercionLabel, emptyArchiveLine, emptyPortalArchiveLine, exampleSpec, exportPageXlsx, fieldKindFor, forgetAllOps, highestLevel, holdsARetiredChoice, indexedDbStore, isArchiveLane, isDecided, isOwnOp, isPortalArchiveFilter, isTheChosen, looksLikeAnId, mayDrag, measureKey, memoryStore, mintClientKey, mintOpId, openCaptureQueue, optionKey, optionLabel, portalArchiveConsequence, portalConfirmLine, portalPath, portalTitleTypedBack, publicFormPath, rememberedOpCount, sameDocument, scopeChip, stableFilterKey };
3545
+ export { ARCHIVE_LANES, ARCHIVE_LANE_LABEL, ARCHIVE_LANE_MEANS, type ActionRefusal, type ActionRunResult, Actor, type AggregateBucket, type AggregateFilter, type AggregateMeasure, type AggregateOperation, type AggregateRow, type AggregateWindow, type AnonTokenBinding, type ArchiveLane, type ArchivedDoorRow, type ArchivedRow, type BookingAvailability, type BookingDeclared, type BookingSummary, type BookingWindow, type CaptureField, type CaptureFileRef, type CaptureOutcome, type CaptureQuestion, type CaptureQueue, type CaptureQueueCounts, type CaptureQueueOptions, type CaptureQueuePorts, type CaptureQueueStore, type CaptureSheetFace, type CaptureSheetSummary, type CaptureSyncReport, type ChecklistDeclared, type ChecklistRequirement, type ChecklistRequirementKind, type ChecklistRoleSpec, type ChecklistRunStarted, type ChecklistRunStep, type ChecklistRunSummary, type ChecklistSpec, type ChecklistStepCompleted, type ChecklistStepSpec, type ChecklistTemplateShape, type ChecklistTemplateSummary, type ChecklistTrigger, type ChecklistTriggerKind, type ChoiceOption, type ChoiceOptions, type CoerceOptions, type Coerced, type CoercedAnswers, type CoercibleField, type CommentThreadRead, type CommentWritten, type ConversationScope, type ConversationScopeContext, type CustomFieldTableType, DEFAULT_ARCHIVE_LANE, DEFAULT_PORTAL_ARCHIVE_FILTER, type DashboardBlock, type DashboardBlockKind, type DashboardBlockResult, type DashboardRunResult, type DashboardSummary, type DecorationColor, type DecorationPath, type DecorationRule, type DecorationRuleOp, type DecorationTarget, Delivery, type DigestPreview, type DocRenderRow, type DocSignatureCheck, type DocSignatureRow, type DocTemplateRow, type DocToken, type DocUnresolvedToken, type EnrichAlternate, type EnrichCell, type EnrichDeclared, type EnrichDueRow, type EnrichRun, type EnrichSource, type Enrichment, type EnrichmentSummary, type EntityFieldRights, type EntityFieldValue, type EntityRecordMatch, type EntityRecordRead, type EntityRecordsFound, type EntityTableFacts, type ExampleBuilt, type ExampleSpec, type ExternalPrincipalCard, FIELD_KINDS, Field, type FieldHistoryEntry, type FieldKind, type FormSummary, type FormulaParse, Freshness, type GridLayout, type GridLayoutMode, type GridRowHeight, type HistoryActor, type HistoryActorKind, type HistoryChange, type Home, type ImportBatchResult, type ImportColumnPlan, type ImportColumnsDeclared, type ImportFinished, type ImportOpened, type ImportOutcome, type ImportPlan, type ImportPolicy, type ImportProposal, type ImportReport, type ImportRun, type InboundAddress, type InboundDeclared, type IoExportPage, type KernelTargets, type MergeField, MergeFieldModifier, type MergeFieldProvenance, type MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, type MergeFieldTransform, type MissingBehavior, type MyLevel, type MySubscription, type NewEntityFieldDeclaration, OnDelete, OverridePolicy, PERMISSION_LEVELS, PIPELINE_RULE_KINDS, PORTAL_ARCHIVE_FILTERS, ParityFieldType, type PermissionLevel, PgError, type Pipeline, type PipelineColumn, type PipelineDeclared, type PipelineGate, type PipelineGatePreview, type PipelineMissingField, type PipelineMoveResult, type PipelineRule, type PipelineRuleKind, type PipelineSpec, type PipelineStage, type PipelineVerdict, type PortalArchiveAnswer, type PortalArchiveFilter, type PortalCard, type PortalInvitation, type PortalPreviewRow, type PortalPrincipal, type PortalRevocation, type PortalSummary, type PortalTableExposure, type PortalTableRef, type PublishBinding, type QueuedCapture, type QueuedCaptureFile, type QueuedCaptureState, type QuietHours, REFUSALS_WORTH_REPEATING, ReadRow, type RecordChangeAction, type RecordComment, RecordDocument, type RecordEvent, type RecordFilter, type RecordHistoryEntry, type RecordScopeComment, type RecordScopeContext, type RecordScopeField, type RecordScopeHistoryEntry, type RecordScopeRelation, type RecordScopeWithheld, type RecordsActor, type RecordsChangeSink, type RecordsConfig, type RecordsDataSource, RecordsError, type RecordsErrorSink, type RecordsFilter, type RecordsRealtimePort, type RecordsResolverPort, type RecordsResponse, type RecordsTableQuery, type RegisteredTable, type Relation, RelationBinding, RelationCardinality, type RelationCarries, type RelationCoordinate, type RelationDisplaySpec, RelationFlavor, type RelationProperties, type RelationStore, type RelationTarget, type RelationWordsManyArgs, type ResolutionTriple, type ResolvedPublishBinding, type RestorePreview, type RestoreResult, type RowAction, type RowActionStep, type Rule, type RuleAnswer, type RuleExpression, RuleNodeKind, RuleUse, STAGE_RULE_ENFORCEMENT, STAGE_RULE_ON_FAIL, type SavedViewRow, type SavedViewSpecIn, type StagePending, type StagePendingOnBoard, type StageRuleEnforcement, type StageRuleOnFail, type StageRuleWarning, StorageMode, StoredRecord, type StuckRow, type Subscription, type SubscriptionBlock, type SubscriptionCadence, type SubscriptionSpec, type Table, type TableArchiveProgress, type TableCapacity, type TableDecorations, TableDisplay, TableOrigin, TableType, type TableWebhook, type TableWebhookDeclared, Timestamp, Uuid, type ViewLayout, type WorkApprovalDecision, type WorkApprovalFiled, type WorkApprover, type WorkAssignment, type WorkAssignmentField, type WorkChange, type WorkDueState, type WorkGraph, type WorkInboxItem, type WorkInboxKind, type WorkInstantiation, type WorkListFlavour, type WorkListItem, type WorkOrigin, type WorkRecordState, type WorkSlotHold, type WorkState, type WorkTemplateNode, type WorkTemplateRelation, type WorkTurn, actionRefusals, archivedByLine, archivedWhen, asPermissionLevel, atLeast, bookingPath, choiceSlug, choiceValuesOf, choicesOf, coerceTypedAnswer, coerceTypedAnswers, coercionLabel, emptyArchiveLine, emptyPortalArchiveLine, exampleSpec, exportPageXlsx, fieldKindFor, forgetAllOps, highestLevel, holdsARetiredChoice, indexedDbStore, isArchiveLane, isDecided, isOwnOp, isPortalArchiveFilter, isTheChosen, looksLikeAnId, mayDrag, measureKey, memoryStore, mintClientKey, mintOpId, openCaptureQueue, optionKey, optionLabel, portalArchiveConsequence, portalConfirmLine, portalPath, portalTitleTypedBack, publicFormPath, recordChangeTrigger, rememberedOpCount, sameDocument, scopeChip, stableFilterKey };
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { p as Uuid, T as Timestamp, t as ReadRow, R as RecordDocument, aT as TableType, aR as TableDisplay, aL as StorageMode, aS as TableOrigin, S as StoredRecord, u as Field, ap as ParityFieldType, aG as RuleUse, aF as RuleNodeKind, C as RecordsError, U as UseCase, aD as RelationFlavor, al as OnDelete, aA as RelationBinding, aB as RelationCardinality, ai as MergeFieldSource, ah as MergeFieldSemanticType, ag as MergeFieldModifier, am as OverridePolicy, Z as Delivery, a9 as Freshness, K as Actor, D as PgError } from './types-RxnWzAWZ.js';
2
- export { H as ABSENCE_REASONS, I as ACTOR_VOCABULARY, J as AbsenceReason, L as COMPUTE_ON, M as CONTEXT_POLICIES, O as ComputeOn, Q as ContextPolicy, V as DECLARABLE_FIELD_KINDS, X as DELIVERIES, Y as DeclarableFieldKind, _ as ENTITY_TOKENS, $ as EntityToken, a0 as FIELD_SENSITIVITIES, a1 as FIELD_SOURCES, a2 as FRESHNESS, a3 as FieldBehavior, w as FieldPatch, z as FieldProposal, a4 as FieldRule, a5 as FieldSensitivity, a6 as FieldSource, a7 as FieldTypeWord, a8 as ForbiddenEnvelopeWord, aa as HiddenFieldNotice, ab as KERNEL_TABLES, ac as KernelTableName, ad as MERGE_FIELD_MODIFIERS, ae as MERGE_FIELD_SEMANTIC_TYPES, af as MERGE_FIELD_SOURCES, v as NewFieldDeclaration, aj as ON_DELETE, ak as OVERRIDE_POLICIES, an as PARITY_FIELD_TYPES, ao as PER_VALUE_ACCESS_WORDS, aq as ParityFieldTypeDescriptor, ar as PerValueAccessWord, G as PredictedRefusal, as as ProvenancePointer, at as RELATION_BINDINGS, au as RELATION_CARDINALITIES, av as RELATION_FLAVORS, aw as RETIRED_ACTOR_WORDS, ax as RULE_NODE_KINDS, ay as RULE_USES, y as ReadValue, r as RecordGraphWritten, s as RecordRead, x as RecordRevision, az as RecordsErrorCode, q as RecordsResult, aC as RelationDisplay, aE as RetiredActorWord, aH as STORAGE_MODES, aI as STORE_DOORS, aJ as STORE_KNOBS, aK as STORE_REFUSAL_CODES, E as StaleWriteDetail, aM as StoreDoorName, aN as StoreRefusalCode, aO as TABLE_DISPLAYS, aP as TABLE_ORIGINS, aQ as TABLE_TYPES, A as TableProposal, aU as VALUE_ALTERNATE_KEYS, aV as VALUE_ENVELOPE_KEYS, aW as ValueAlternate, aX as ValueAlternateKey, aY as ValueEnvelope, aZ as ValueEnvelopeKey, a_ as ValueSource, W as WriteConflict, a$ as err, b0 as isRecordsErr, b1 as ok } from './types-RxnWzAWZ.js';
1
+ import { p as Uuid, T as Timestamp, u as ReadRow, q as RecordDocument, aT as TableType, aR as TableDisplay, aL as StorageMode, aS as TableOrigin, S as StoredRecord, v as Field, aq as ParityFieldType, aG as RuleUse, aF as RuleNodeKind, D as RecordsError, U as UseCase, aD as RelationFlavor, am as OnDelete, aA as RelationBinding, aB as RelationCardinality, aj as MergeFieldSource, ai as MergeFieldSemanticType, ah as MergeFieldModifier, an as OverridePolicy, _ as Delivery, aa as Freshness, L as Actor, E as PgError } from './types-Bsamaf-a.js';
2
+ export { I as ABSENCE_REASONS, J as ACTOR_VOCABULARY, K as AbsenceReason, M as COMPUTE_ON, O as CONTEXT_POLICIES, Q as ComputeOn, V as ContextPolicy, X as DECLARABLE_FIELD_KINDS, Y as DELIVERIES, Z as DeclarableFieldKind, $ as ENTITY_TOKENS, a0 as EntityToken, a1 as FIELD_SENSITIVITIES, a2 as FIELD_SOURCES, a3 as FRESHNESS, a4 as FieldBehavior, x as FieldPatch, A as FieldProposal, a5 as FieldRule, a6 as FieldSensitivity, a7 as FieldSource, a8 as FieldTypeWord, a9 as ForbiddenEnvelopeWord, ab as HiddenFieldNotice, ac as KERNEL_TABLES, ad as KernelTableName, ae as MERGE_FIELD_MODIFIERS, af as MERGE_FIELD_SEMANTIC_TYPES, ag as MERGE_FIELD_SOURCES, w as NewFieldDeclaration, ak as ON_DELETE, al as OVERRIDE_POLICIES, ao as PARITY_FIELD_TYPES, ap as PER_VALUE_ACCESS_WORDS, ar as ParityFieldTypeDescriptor, as as PerValueAccessWord, H as PredictedRefusal, at as ProvenancePointer, au as RELATION_BINDINGS, av as RELATION_CARDINALITIES, aw as RELATION_FLAVORS, ax as RETIRED_ACTOR_WORDS, ay as RULE_NODE_KINDS, az as RULE_USES, z as ReadValue, s as RecordGraphWritten, t as RecordRead, y as RecordRevision, R as RecordsErrorCode, r as RecordsResult, aC as RelationDisplay, aE as RetiredActorWord, aH as STORAGE_MODES, aI as STORE_DOORS, aJ as STORE_KNOBS, aK as STORE_REFUSAL_CODES, G as StaleWriteDetail, aM as StoreDoorName, aN as StoreRefusalCode, aO as TABLE_DISPLAYS, aP as TABLE_ORIGINS, aQ as TABLE_TYPES, C as TableProposal, aU as VALUE_ALTERNATE_KEYS, aV as VALUE_ENVELOPE_KEYS, aW as ValueAlternate, aX as ValueAlternateKey, aY as ValueEnvelope, aZ as ValueEnvelopeKey, a_ as ValueSource, W as WriteConflict, a$ as allowsOtherValues, b0 as err, b1 as isRecordsErr, b2 as ok } from './types-Bsamaf-a.js';
3
3
 
4
4
  /**
5
5
  * THE TWO LANES THE ARCHIVED-ITEMS LAW NAMES (Arman, 2026-09-09) — the same
@@ -1521,7 +1521,7 @@ interface TableDecorations {
1521
1521
  type DecorationPath = ["color_by"] | ["rules"] | ["rows", Uuid] | ["columns", Uuid] | ["cells", Uuid, Uuid];
1522
1522
  type GridLayoutMode = "auto" | "fit" | "scroll";
1523
1523
  type GridRowHeight = "compact" | "normal" | "tall";
1524
- /** A saved view's own layout, kept at `definition.layout` (custom.view_declare judges it). */
1524
+ /** A saved view's own grid choices, kept at `definition.grid` (custom.view_declare judges them). `definition.layout` is the view's KIND (grid / kanban / calendar / gallery), never these. */
1525
1525
  interface ViewLayout {
1526
1526
  mode?: GridLayoutMode;
1527
1527
  row_height?: GridRowHeight;
@@ -1682,6 +1682,26 @@ interface IoExportPage {
1682
1682
  * (the Field's label); a key with no label is its own header.
1683
1683
  */
1684
1684
  declare function exportPageXlsx(page: IoExportPage, labels?: Record<string, string>, sheetLabel?: string): Promise<Uint8Array>;
1685
+ /** A record-store row event, as the activity spine carries it (and a schedule matches it). */
1686
+ type RecordChangeAction = RecordEvent;
1687
+ /**
1688
+ * THE SCHEDULE TRIGGER for "when a row of this record-store table changes, run …" — the same
1689
+ * `event` trigger the older store's tables use, pointed at this store's events:
1690
+ * `entity_type` `custom_record:<table id>`, actions `record.*`, `changed_fields` by column KEY.
1691
+ * `scheduler.sch_match_event` matches it against the event
1692
+ * `custom._record_events_to_activity` writes (GRID-PRIMITIVES G8), so one matcher serves both
1693
+ * stores. Omit `actions` to hear every change; omit `changedFields` to hear every column.
1694
+ */
1695
+ declare function recordChangeTrigger(tableId: Uuid, options?: {
1696
+ actions?: RecordChangeAction[];
1697
+ changedFields?: string[];
1698
+ }): {
1699
+ type: "event";
1700
+ entity_type: string;
1701
+ table_id: Uuid;
1702
+ actions?: RecordChangeAction[];
1703
+ changed_fields?: string[];
1704
+ };
1685
1705
 
1686
1706
  /** The seven shapes a block can take, exactly as `custom.dashboard_kinds()` answers. */
1687
1707
  type DashboardBlockKind = "number" | "bar" | "column" | "line" | "donut" | "table" | "stuck";
@@ -3522,4 +3542,4 @@ interface ConversationScopeContext {
3522
3542
  /** `About: Acme Industrial` — the chip a bound chat wears. */
3523
3543
  declare function scopeChip(scope: ConversationScope): string;
3524
3544
 
3525
- export { ARCHIVE_LANES, ARCHIVE_LANE_LABEL, ARCHIVE_LANE_MEANS, type ActionRefusal, type ActionRunResult, Actor, type AggregateBucket, type AggregateFilter, type AggregateMeasure, type AggregateOperation, type AggregateRow, type AggregateWindow, type AnonTokenBinding, type ArchiveLane, type ArchivedDoorRow, type ArchivedRow, type BookingAvailability, type BookingDeclared, type BookingSummary, type BookingWindow, type CaptureField, type CaptureFileRef, type CaptureOutcome, type CaptureQuestion, type CaptureQueue, type CaptureQueueCounts, type CaptureQueueOptions, type CaptureQueuePorts, type CaptureQueueStore, type CaptureSheetFace, type CaptureSheetSummary, type CaptureSyncReport, type ChecklistDeclared, type ChecklistRequirement, type ChecklistRequirementKind, type ChecklistRoleSpec, type ChecklistRunStarted, type ChecklistRunStep, type ChecklistRunSummary, type ChecklistSpec, type ChecklistStepCompleted, type ChecklistStepSpec, type ChecklistTemplateShape, type ChecklistTemplateSummary, type ChecklistTrigger, type ChecklistTriggerKind, type ChoiceOption, type ChoiceOptions, type CoerceOptions, type Coerced, type CoercedAnswers, type CoercibleField, type CommentThreadRead, type CommentWritten, type ConversationScope, type ConversationScopeContext, type CustomFieldTableType, DEFAULT_ARCHIVE_LANE, DEFAULT_PORTAL_ARCHIVE_FILTER, type DashboardBlock, type DashboardBlockKind, type DashboardBlockResult, type DashboardRunResult, type DashboardSummary, type DecorationColor, type DecorationPath, type DecorationRule, type DecorationRuleOp, type DecorationTarget, Delivery, type DigestPreview, type DocRenderRow, type DocSignatureCheck, type DocSignatureRow, type DocTemplateRow, type DocToken, type DocUnresolvedToken, type EnrichAlternate, type EnrichCell, type EnrichDeclared, type EnrichDueRow, type EnrichRun, type EnrichSource, type Enrichment, type EnrichmentSummary, type EntityFieldRights, type EntityFieldValue, type EntityRecordMatch, type EntityRecordRead, type EntityRecordsFound, type EntityTableFacts, type ExampleBuilt, type ExampleSpec, type ExternalPrincipalCard, FIELD_KINDS, Field, type FieldHistoryEntry, type FieldKind, type FormSummary, type FormulaParse, Freshness, type GridLayout, type GridLayoutMode, type GridRowHeight, type HistoryActor, type HistoryActorKind, type HistoryChange, type Home, type ImportBatchResult, type ImportColumnPlan, type ImportColumnsDeclared, type ImportFinished, type ImportOpened, type ImportOutcome, type ImportPlan, type ImportPolicy, type ImportProposal, type ImportReport, type ImportRun, type InboundAddress, type InboundDeclared, type IoExportPage, type KernelTargets, type MergeField, MergeFieldModifier, type MergeFieldProvenance, type MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, type MergeFieldTransform, type MissingBehavior, type MyLevel, type MySubscription, type NewEntityFieldDeclaration, OnDelete, OverridePolicy, PERMISSION_LEVELS, PIPELINE_RULE_KINDS, PORTAL_ARCHIVE_FILTERS, ParityFieldType, type PermissionLevel, PgError, type Pipeline, type PipelineColumn, type PipelineDeclared, type PipelineGate, type PipelineGatePreview, type PipelineMissingField, type PipelineMoveResult, type PipelineRule, type PipelineRuleKind, type PipelineSpec, type PipelineStage, type PipelineVerdict, type PortalArchiveAnswer, type PortalArchiveFilter, type PortalCard, type PortalInvitation, type PortalPreviewRow, type PortalPrincipal, type PortalRevocation, type PortalSummary, type PortalTableExposure, type PortalTableRef, type PublishBinding, type QueuedCapture, type QueuedCaptureFile, type QueuedCaptureState, type QuietHours, REFUSALS_WORTH_REPEATING, ReadRow, type RecordComment, RecordDocument, type RecordEvent, type RecordFilter, type RecordHistoryEntry, type RecordScopeComment, type RecordScopeContext, type RecordScopeField, type RecordScopeHistoryEntry, type RecordScopeRelation, type RecordScopeWithheld, type RecordsActor, type RecordsChangeSink, type RecordsConfig, type RecordsDataSource, RecordsError, type RecordsErrorSink, type RecordsFilter, type RecordsRealtimePort, type RecordsResolverPort, type RecordsResponse, type RecordsTableQuery, type RegisteredTable, type Relation, RelationBinding, RelationCardinality, type RelationCarries, type RelationCoordinate, type RelationDisplaySpec, RelationFlavor, type RelationProperties, type RelationStore, type RelationTarget, type RelationWordsManyArgs, type ResolutionTriple, type ResolvedPublishBinding, type RestorePreview, type RestoreResult, type RowAction, type RowActionStep, type Rule, type RuleAnswer, type RuleExpression, RuleNodeKind, RuleUse, STAGE_RULE_ENFORCEMENT, STAGE_RULE_ON_FAIL, type SavedViewRow, type SavedViewSpecIn, type StagePending, type StagePendingOnBoard, type StageRuleEnforcement, type StageRuleOnFail, type StageRuleWarning, StorageMode, StoredRecord, type StuckRow, type Subscription, type SubscriptionBlock, type SubscriptionCadence, type SubscriptionSpec, type Table, type TableArchiveProgress, type TableCapacity, type TableDecorations, TableDisplay, TableOrigin, TableType, type TableWebhook, type TableWebhookDeclared, Timestamp, Uuid, type ViewLayout, type WorkApprovalDecision, type WorkApprovalFiled, type WorkApprover, type WorkAssignment, type WorkAssignmentField, type WorkChange, type WorkDueState, type WorkGraph, type WorkInboxItem, type WorkInboxKind, type WorkInstantiation, type WorkListFlavour, type WorkListItem, type WorkOrigin, type WorkRecordState, type WorkSlotHold, type WorkState, type WorkTemplateNode, type WorkTemplateRelation, type WorkTurn, actionRefusals, archivedByLine, archivedWhen, asPermissionLevel, atLeast, bookingPath, choiceSlug, choiceValuesOf, choicesOf, coerceTypedAnswer, coerceTypedAnswers, coercionLabel, emptyArchiveLine, emptyPortalArchiveLine, exampleSpec, exportPageXlsx, fieldKindFor, forgetAllOps, highestLevel, holdsARetiredChoice, indexedDbStore, isArchiveLane, isDecided, isOwnOp, isPortalArchiveFilter, isTheChosen, looksLikeAnId, mayDrag, measureKey, memoryStore, mintClientKey, mintOpId, openCaptureQueue, optionKey, optionLabel, portalArchiveConsequence, portalConfirmLine, portalPath, portalTitleTypedBack, publicFormPath, rememberedOpCount, sameDocument, scopeChip, stableFilterKey };
3545
+ export { ARCHIVE_LANES, ARCHIVE_LANE_LABEL, ARCHIVE_LANE_MEANS, type ActionRefusal, type ActionRunResult, Actor, type AggregateBucket, type AggregateFilter, type AggregateMeasure, type AggregateOperation, type AggregateRow, type AggregateWindow, type AnonTokenBinding, type ArchiveLane, type ArchivedDoorRow, type ArchivedRow, type BookingAvailability, type BookingDeclared, type BookingSummary, type BookingWindow, type CaptureField, type CaptureFileRef, type CaptureOutcome, type CaptureQuestion, type CaptureQueue, type CaptureQueueCounts, type CaptureQueueOptions, type CaptureQueuePorts, type CaptureQueueStore, type CaptureSheetFace, type CaptureSheetSummary, type CaptureSyncReport, type ChecklistDeclared, type ChecklistRequirement, type ChecklistRequirementKind, type ChecklistRoleSpec, type ChecklistRunStarted, type ChecklistRunStep, type ChecklistRunSummary, type ChecklistSpec, type ChecklistStepCompleted, type ChecklistStepSpec, type ChecklistTemplateShape, type ChecklistTemplateSummary, type ChecklistTrigger, type ChecklistTriggerKind, type ChoiceOption, type ChoiceOptions, type CoerceOptions, type Coerced, type CoercedAnswers, type CoercibleField, type CommentThreadRead, type CommentWritten, type ConversationScope, type ConversationScopeContext, type CustomFieldTableType, DEFAULT_ARCHIVE_LANE, DEFAULT_PORTAL_ARCHIVE_FILTER, type DashboardBlock, type DashboardBlockKind, type DashboardBlockResult, type DashboardRunResult, type DashboardSummary, type DecorationColor, type DecorationPath, type DecorationRule, type DecorationRuleOp, type DecorationTarget, Delivery, type DigestPreview, type DocRenderRow, type DocSignatureCheck, type DocSignatureRow, type DocTemplateRow, type DocToken, type DocUnresolvedToken, type EnrichAlternate, type EnrichCell, type EnrichDeclared, type EnrichDueRow, type EnrichRun, type EnrichSource, type Enrichment, type EnrichmentSummary, type EntityFieldRights, type EntityFieldValue, type EntityRecordMatch, type EntityRecordRead, type EntityRecordsFound, type EntityTableFacts, type ExampleBuilt, type ExampleSpec, type ExternalPrincipalCard, FIELD_KINDS, Field, type FieldHistoryEntry, type FieldKind, type FormSummary, type FormulaParse, Freshness, type GridLayout, type GridLayoutMode, type GridRowHeight, type HistoryActor, type HistoryActorKind, type HistoryChange, type Home, type ImportBatchResult, type ImportColumnPlan, type ImportColumnsDeclared, type ImportFinished, type ImportOpened, type ImportOutcome, type ImportPlan, type ImportPolicy, type ImportProposal, type ImportReport, type ImportRun, type InboundAddress, type InboundDeclared, type IoExportPage, type KernelTargets, type MergeField, MergeFieldModifier, type MergeFieldProvenance, type MergeFieldResolution, MergeFieldSemanticType, MergeFieldSource, type MergeFieldTransform, type MissingBehavior, type MyLevel, type MySubscription, type NewEntityFieldDeclaration, OnDelete, OverridePolicy, PERMISSION_LEVELS, PIPELINE_RULE_KINDS, PORTAL_ARCHIVE_FILTERS, ParityFieldType, type PermissionLevel, PgError, type Pipeline, type PipelineColumn, type PipelineDeclared, type PipelineGate, type PipelineGatePreview, type PipelineMissingField, type PipelineMoveResult, type PipelineRule, type PipelineRuleKind, type PipelineSpec, type PipelineStage, type PipelineVerdict, type PortalArchiveAnswer, type PortalArchiveFilter, type PortalCard, type PortalInvitation, type PortalPreviewRow, type PortalPrincipal, type PortalRevocation, type PortalSummary, type PortalTableExposure, type PortalTableRef, type PublishBinding, type QueuedCapture, type QueuedCaptureFile, type QueuedCaptureState, type QuietHours, REFUSALS_WORTH_REPEATING, ReadRow, type RecordChangeAction, type RecordComment, RecordDocument, type RecordEvent, type RecordFilter, type RecordHistoryEntry, type RecordScopeComment, type RecordScopeContext, type RecordScopeField, type RecordScopeHistoryEntry, type RecordScopeRelation, type RecordScopeWithheld, type RecordsActor, type RecordsChangeSink, type RecordsConfig, type RecordsDataSource, RecordsError, type RecordsErrorSink, type RecordsFilter, type RecordsRealtimePort, type RecordsResolverPort, type RecordsResponse, type RecordsTableQuery, type RegisteredTable, type Relation, RelationBinding, RelationCardinality, type RelationCarries, type RelationCoordinate, type RelationDisplaySpec, RelationFlavor, type RelationProperties, type RelationStore, type RelationTarget, type RelationWordsManyArgs, type ResolutionTriple, type ResolvedPublishBinding, type RestorePreview, type RestoreResult, type RowAction, type RowActionStep, type Rule, type RuleAnswer, type RuleExpression, RuleNodeKind, RuleUse, STAGE_RULE_ENFORCEMENT, STAGE_RULE_ON_FAIL, type SavedViewRow, type SavedViewSpecIn, type StagePending, type StagePendingOnBoard, type StageRuleEnforcement, type StageRuleOnFail, type StageRuleWarning, StorageMode, StoredRecord, type StuckRow, type Subscription, type SubscriptionBlock, type SubscriptionCadence, type SubscriptionSpec, type Table, type TableArchiveProgress, type TableCapacity, type TableDecorations, TableDisplay, TableOrigin, TableType, type TableWebhook, type TableWebhookDeclared, Timestamp, Uuid, type ViewLayout, type WorkApprovalDecision, type WorkApprovalFiled, type WorkApprover, type WorkAssignment, type WorkAssignmentField, type WorkChange, type WorkDueState, type WorkGraph, type WorkInboxItem, type WorkInboxKind, type WorkInstantiation, type WorkListFlavour, type WorkListItem, type WorkOrigin, type WorkRecordState, type WorkSlotHold, type WorkState, type WorkTemplateNode, type WorkTemplateRelation, type WorkTurn, actionRefusals, archivedByLine, archivedWhen, asPermissionLevel, atLeast, bookingPath, choiceSlug, choiceValuesOf, choicesOf, coerceTypedAnswer, coerceTypedAnswers, coercionLabel, emptyArchiveLine, emptyPortalArchiveLine, exampleSpec, exportPageXlsx, fieldKindFor, forgetAllOps, highestLevel, holdsARetiredChoice, indexedDbStore, isArchiveLane, isDecided, isOwnOp, isPortalArchiveFilter, isTheChosen, looksLikeAnId, mayDrag, measureKey, memoryStore, mintClientKey, mintOpId, openCaptureQueue, optionKey, optionLabel, portalArchiveConsequence, portalConfirmLine, portalPath, portalTitleTypedBack, publicFormPath, recordChangeTrigger, rememberedOpCount, sameDocument, scopeChip, stableFilterKey };
package/dist/index.js CHANGED
@@ -121,6 +121,11 @@ function highestLevel(left, right) {
121
121
  return ORDINAL[left] >= ORDINAL[right] ? left : right;
122
122
  }
123
123
 
124
+ // src/field.ts
125
+ function allowsOtherValues(field) {
126
+ return field.type === "list" && field.config?.["allow_other"] === true;
127
+ }
128
+
124
129
  // src/choice.ts
125
130
  var UUID = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i;
126
131
  function optionKey(option) {
@@ -511,6 +516,15 @@ async function exportPageXlsx(page, labels = {}, sheetLabel = "Records") {
511
516
  }
512
517
  return XLSX.write(workbook, { type: "array", bookType: "xlsx", compression: true });
513
518
  }
519
+ function recordChangeTrigger(tableId, options = {}) {
520
+ return {
521
+ type: "event",
522
+ entity_type: `custom_record:${tableId}`,
523
+ table_id: tableId,
524
+ ...options.actions && options.actions.length > 0 ? { actions: options.actions } : {},
525
+ ...options.changedFields && options.changedFields.length > 0 ? { changed_fields: options.changedFields } : {}
526
+ };
527
+ }
514
528
 
515
529
  // src/capture-queue.ts
516
530
  var DB_NAME = "matrx-capture";
@@ -892,6 +906,48 @@ var RULE_NODE_KINDS = [
892
906
  { node: "div", evaluated_by: "W1-RULE" },
893
907
  { node: "eq", evaluated_by: "W1-RULE" },
894
908
  { node: "field", evaluated_by: "W1-RULE" },
909
+ { node: "fx.abs", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
910
+ { node: "fx.add", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
911
+ { node: "fx.and", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
912
+ { node: "fx.autonumber", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
913
+ { node: "fx.average", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
914
+ { node: "fx.blank", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
915
+ { node: "fx.concatenate", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
916
+ { node: "fx.contains", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
917
+ { node: "fx.created_time", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
918
+ { node: "fx.dateadd", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
919
+ { node: "fx.datediff", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
920
+ { node: "fx.day", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
921
+ { node: "fx.div", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
922
+ { node: "fx.eq", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
923
+ { node: "fx.gt", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
924
+ { node: "fx.gte", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
925
+ { node: "fx.if", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
926
+ { node: "fx.isblank", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
927
+ { node: "fx.left", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
928
+ { node: "fx.len", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
929
+ { node: "fx.lower", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
930
+ { node: "fx.lt", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
931
+ { node: "fx.lte", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
932
+ { node: "fx.max", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
933
+ { node: "fx.min", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
934
+ { node: "fx.mod", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
935
+ { node: "fx.modified_time", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
936
+ { node: "fx.month", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
937
+ { node: "fx.mul", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
938
+ { node: "fx.ne", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
939
+ { node: "fx.neg", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
940
+ { node: "fx.not", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
941
+ { node: "fx.now", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
942
+ { node: "fx.or", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
943
+ { node: "fx.right", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
944
+ { node: "fx.round", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
945
+ { node: "fx.sub", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
946
+ { node: "fx.sum", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
947
+ { node: "fx.today", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
948
+ { node: "fx.trim", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
949
+ { node: "fx.upper", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
950
+ { node: "fx.year", evaluated_by: "GRID-PRIMITIVES G3 (custom.formula_eval)" },
895
951
  { node: "gt", evaluated_by: "W1-RULE" },
896
952
  { node: "gte", evaluated_by: "W1-RULE" },
897
953
  { node: "length", evaluated_by: "W1-RULE" },
@@ -923,6 +979,8 @@ var KERNEL_TABLES = [
923
979
  ];
924
980
  var STORE_DOORS = [
925
981
  { name: "absence_reasons", args: "", returns: "text[]", security: "invoker" },
982
+ { name: "action_declare", args: "p_organization_id uuid, p_table_id uuid, p_actions jsonb", returns: "jsonb", security: "definer" },
983
+ { name: "action_run", args: "p_organization_id uuid, p_action_id uuid, p_record_ids uuid[]", returns: "jsonb", security: "definer" },
926
984
  { name: "actor_vocabulary", args: "", returns: "text[]", security: "invoker" },
927
985
  { name: "actor_word", args: "p_declared text", returns: "text", security: "invoker" },
928
986
  { name: "addressed_cap", args: "p_user_id uuid, p_type text, p_id uuid, p_organization_id uuid DEFAULT NULL::uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "permission_level", security: "definer" },
@@ -974,6 +1032,7 @@ var STORE_DOORS = [
974
1032
  { name: "assert_organization_admin", args: "p_organization_id uuid, p_door text, p_what text", returns: "void", security: "invoker" },
975
1033
  { name: "assert_organization_wall", args: "p_kind text, p_organization_id uuid, p_row jsonb", returns: "void", security: "invoker" },
976
1034
  { name: "assert_store_door", args: "p_organization_id uuid, p_door text", returns: "void", security: "invoker" },
1035
+ { name: "autonumber_backfill", args: "p_organization_id uuid, p_field_id uuid", returns: "jsonb", security: "definer" },
977
1036
  { 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" },
978
1037
  { name: "booking_confirm", args: "p_form_id uuid, p_hold_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(booking_ref text, record_id uuid, submission_id uuid, slot_key text, slot_at timestamp with time zone, state text, message text)", security: "definer" },
979
1038
  { name: "booking_declare", args: "p_organization_id uuid, p_table_id uuid, p_title text, p_questions jsonb, p_availability jsonb DEFAULT '{}'::jsonb, p_presentation jsonb DEFAULT '{}'::jsonb, p_submission_cap integer DEFAULT NULL::integer, p_quarantine_rule_id uuid DEFAULT NULL::uuid, p_notify_rule_id uuid DEFAULT NULL::uuid, p_form_id uuid DEFAULT NULL::uuid, p_slug text DEFAULT NULL::text, p_home_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
@@ -1046,6 +1105,8 @@ var STORE_DOORS = [
1046
1105
  { name: "dashboard_stuck", args: "p_organization_id uuid, p_table_id uuid, p_state_key text, p_days integer DEFAULT 14, p_filter jsonb DEFAULT '{}'::jsonb, p_limit integer DEFAULT 50, p_required text DEFAULT 'viewer'::text", returns: "TABLE(record_id uuid, title text, state text, last_changed_at timestamp with time zone, days_unchanged numeric, measured_from text)", security: "definer" },
1047
1106
  { name: "dashboard_window_sql", args: "p_key text, p_window jsonb", returns: "text", security: "invoker" },
1048
1107
  { name: "dashboards", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "TABLE(dashboard_id uuid, table_id uuid, name text, blocks jsonb, presentation jsonb, block_count integer, version integer, created_at timestamp with time zone, updated_at timestamp with time zone)", security: "definer" },
1108
+ { name: "decoration_colors", args: "", returns: "text[]", security: "invoker" },
1109
+ { name: "decoration_rule_ops", args: "", returns: "TABLE(op text, takes_value boolean, label text)", security: "invoker" },
1049
1110
  { name: "delete_cascade_closure", args: "p_organization_id uuid, p_record_id uuid", returns: "uuid[]", security: "invoker" },
1050
1111
  { name: "delete_preview", args: "p_organization_id uuid, p_record_id uuid", returns: "jsonb", security: "definer" },
1051
1112
  { name: "delete_rule", args: "p_organization_id uuid, p_record_id uuid, p_apply boolean DEFAULT true", returns: "jsonb", security: "definer" },
@@ -1055,6 +1116,7 @@ var STORE_DOORS = [
1055
1116
  { name: "derived_value", args: "p_organization_id uuid, p_record_id uuid, p_field_data jsonb, p_values jsonb DEFAULT NULL::jsonb", returns: "jsonb", security: "invoker" },
1056
1117
  { name: "derived_values", args: "p_organization_id uuid, p_record_id uuid", returns: "jsonb", security: "invoker" },
1057
1118
  { name: "derived_values_of", args: "v_rec custom.record", returns: "jsonb", security: "invoker" },
1119
+ { name: "display_format_ids", args: "", returns: "text[]", security: "invoker" },
1058
1120
  { name: "doc_content_hash", args: "p_body text", returns: "text", security: "invoker" },
1059
1121
  { name: "doc_format_value", args: "p_field_data jsonb, p_value jsonb", returns: "text", security: "invoker" },
1060
1122
  { name: "doc_letterhead", args: "p_organization_id uuid", returns: "jsonb", security: "definer" },
@@ -1133,8 +1195,13 @@ var STORE_DOORS = [
1133
1195
  { name: "form_slug", args: "p_organization_id uuid, p_title text, p_form_id uuid DEFAULT NULL::uuid", returns: "text", security: "invoker" },
1134
1196
  { 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" },
1135
1197
  { 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" },
1198
+ { name: "formula_eval", args: "p_organization_id uuid, p_expr jsonb, p_values jsonb, p_context jsonb DEFAULT '{}'::jsonb", returns: "jsonb", security: "invoker" },
1199
+ { name: "formula_node_kinds", args: "", returns: "TABLE(node text, min_args integer, max_args integer, result text, signature text, says text)", security: "invoker" },
1200
+ { name: "formula_parse", args: "p_organization_id uuid, p_table_id uuid, p_text text", returns: "jsonb", security: "definer" },
1136
1201
  { name: "formula_value", args: "p_organization_id uuid, p_record_id uuid, p_field_data jsonb, p_values jsonb DEFAULT NULL::jsonb", returns: "jsonb", security: "invoker" },
1137
1202
  { name: "freshness_verdict", args: "p_written_at timestamp with time zone, p_ceiling_seconds numeric", returns: "jsonb", security: "definer" },
1203
+ { name: "grid_layout", args: "p_organization_id uuid, p_table_id uuid, p_view_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
1204
+ { name: "grid_layout_check", args: "p_layout jsonb, p_scope text DEFAULT 'view'::text", returns: "jsonb", security: "invoker" },
1138
1205
  { name: "guard_refusals_are_complete", args: "", returns: "TABLE(guard text, said text)", security: "invoker" },
1139
1206
  { name: "has_visibility", args: "p_user_id uuid, p_type text, p_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level", returns: "boolean", security: "definer" },
1140
1207
  { name: "has_visibility_at", args: "p_user_id uuid, p_type text, p_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level, p_organization_id uuid DEFAULT NULL::uuid, p_min_version bigint DEFAULT NULL::bigint", returns: "boolean", security: "definer" },
@@ -1150,6 +1217,7 @@ var STORE_DOORS = [
1150
1217
  { name: "history_retention_set", args: "p_organization_id uuid, p_table_id uuid, p_days integer", returns: "integer", security: "definer" },
1151
1218
  { name: "home_add", args: "p_organization_id uuid, p_table_id uuid, p_home_record_id uuid", returns: "uuid", security: "definer" },
1152
1219
  { name: "home_relations", args: "", returns: "TABLE(table_id uuid, home_record_id uuid, organization_id uuid, relation_id uuid)", security: "invoker" },
1220
+ { name: "hub_changed_by", args: "p_organization_id uuid, p_kind text, p_ids uuid[]", returns: "TABLE(id uuid, at timestamp with time zone, who text)", security: "definer" },
1153
1221
  { name: "inbound_addresses", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "jsonb", security: "definer" },
1154
1222
  { name: "inbound_declare", args: "p_organization_id uuid, p_table_id uuid, p_label text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1155
1223
  { name: "inbound_domain", args: "p_organization_id uuid", returns: "text", security: "invoker" },
@@ -1218,6 +1286,7 @@ var STORE_DOORS = [
1218
1286
  { name: "migrate_promote", args: "p_organization_id uuid, p_table_id uuid, p_note text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1219
1287
  { name: "migrate_purge", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_dry_run boolean DEFAULT true", returns: "jsonb", security: "definer" },
1220
1288
  { name: "migrate_purge_hard", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_compliance_reason text DEFAULT NULL::text, p_chunk integer DEFAULT 200, p_dry_run boolean DEFAULT true", returns: "jsonb", security: "definer" },
1289
+ { name: "migrate_purge_hard_request", args: "p_organization_id uuid, p_table_id uuid, p_compliance_reason text", returns: "void", security: "definer" },
1221
1290
  { name: "migrate_reclass", args: "p_organization_id uuid, p_id uuid, p_to text DEFAULT 'field'::text, p_note text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1222
1291
  { name: "migrate_rename", args: "p_organization_id uuid, p_id uuid, p_to text, p_note text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1223
1292
  { name: "migrate_reparent", args: "p_organization_id uuid, p_id uuid, p_parent_id uuid, p_note text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
@@ -1253,6 +1322,7 @@ var STORE_DOORS = [
1253
1322
  { name: "pipeline_pending", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1254
1323
  { name: "pipeline_read", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1255
1324
  { name: "pipeline_transition_refusal", args: "p_organization_id uuid, p_record_id uuid, p_to text", returns: "jsonb", security: "definer" },
1325
+ { name: "pipelines", args: "p_organization_id uuid", returns: "TABLE(table_id uuid, table_name text, stage_field text, stage_label text, stages integer, rules integer, broken text, updated_at timestamp with time zone, updated_by uuid)", security: "definer" },
1256
1326
  { name: "portal_admits", args: "p_organization_id uuid, p_user_id uuid DEFAULT NULL::uuid", returns: "boolean", security: "definer" },
1257
1327
  { name: "portal_archive", args: "p_organization_id uuid, p_portal_id uuid, p_confirm_title text, p_reason text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1258
1328
  { name: "portal_card", args: "p_organization_id uuid, p_portal_id uuid", returns: "jsonb", security: "definer" },
@@ -1350,12 +1420,16 @@ var STORE_DOORS = [
1350
1420
  { name: "refusals_claiming_a_level_never_asked", args: "", returns: "TABLE(function_name text, identity_args text, why text)", security: "invoker" },
1351
1421
  { name: "relation_carry", args: "p_organization_id uuid, p_container_id uuid, p_item_id uuid", returns: "uuid", security: "definer" },
1352
1422
  { name: "relation_edges_withdraw", args: "p_organization_id uuid, p_field_ids uuid[], p_why text", returns: "integer", security: "definer" },
1423
+ { name: "relation_halves_disagreements", args: "p_organization_id uuid DEFAULT NULL::uuid, p_record_id uuid DEFAULT NULL::uuid", returns: "TABLE(organization_id uuid, record_id uuid, field_key text, field_id uuid, target_id uuid, direction text, remedy text, why text)", security: "definer" },
1424
+ { name: "relation_halves_repair", args: "p_organization_id uuid, p_record_id uuid", returns: "jsonb", security: "definer" },
1425
+ { name: "relation_kernel_record", args: "p_organization_id uuid, p_kernel_table_id uuid, p_id uuid", returns: "uuid", security: "definer" },
1353
1426
  { name: "relation_own", args: "p_organization_id uuid, p_owner_id uuid, p_target_id uuid", returns: "uuid", security: "definer" },
1354
1427
  { name: "relation_target_card", args: "p_organization_id uuid, p_record_id uuid, p_via_key text DEFAULT NULL::text", returns: "TABLE(target_id uuid, target_organization_id uuid, is_foreign boolean, masked boolean, reader_level permission_level, card jsonb, why text)", security: "definer" },
1355
1428
  { name: "relation_target_external", args: "p_connection_token text, p_external_table text, p_external_key text", returns: "jsonb", security: "definer" },
1356
1429
  { name: "relation_target_ours", args: "p_entity_token text, p_row_id uuid", returns: "jsonb", security: "definer" },
1357
1430
  { name: "relation_targets", args: "p_organization_id uuid, p_record_id uuid, p_via_key text", returns: "SETOF uuid", security: "definer" },
1358
1431
  { name: "relation_uncarry", args: "p_organization_id uuid, p_container_id uuid, p_item_id uuid", returns: "integer", security: "definer" },
1432
+ { name: "relation_value_target_ok", args: "p_organization_id uuid, p_field_id uuid, p_field_data jsonb, p_target_id uuid", returns: "boolean", security: "invoker" },
1359
1433
  { name: "relation_words", args: "p_organization_id uuid, p_field_id uuid, p_value text", returns: "text", security: "definer" },
1360
1434
  { name: "relation_words_many", args: "p_organization_id uuid, p_field_id uuid, p_record_ids uuid[]", returns: "TABLE(record_id uuid, words text)", security: "definer" },
1361
1435
  { name: "reopen_declared_doors", args: "", returns: "TABLE(reopened text)", security: "definer" },
@@ -1364,6 +1438,7 @@ var STORE_DOORS = [
1364
1438
  { name: "resolve_id", args: "p_organization_id uuid, p_id uuid", returns: "uuid", security: "invoker" },
1365
1439
  { name: "retired_actor_words", args: "", returns: "jsonb", security: "invoker" },
1366
1440
  { name: "rollup_value", args: "p_organization_id uuid, p_record_id uuid, p_field_data jsonb", returns: "jsonb", security: "invoker" },
1441
+ { name: "row_actions", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1367
1442
  { name: "rule_applies", args: "p_organization_id uuid, p_rule_id uuid, p_record_id uuid", returns: "jsonb", security: "invoker" },
1368
1443
  { name: "rule_context", args: "p_organization_id uuid, p_record_id uuid", returns: "jsonb", security: "invoker" },
1369
1444
  { name: "rule_declare", args: "p_organization_id uuid, p_spec jsonb, p_rule_id uuid DEFAULT NULL::uuid", returns: "uuid", security: "definer" },
@@ -1389,6 +1464,7 @@ var STORE_DOORS = [
1389
1464
  { name: "share_revoke", args: "p_organization_id uuid, p_subject_id uuid, p_principal_kind text, p_principal_id uuid", returns: "jsonb", security: "definer" },
1390
1465
  { name: "share_subject_name", args: "p_organization_id uuid, p_type text, p_id uuid", returns: "text", security: "definer" },
1391
1466
  { name: "shared_only_disagreements", args: "p_pretend text DEFAULT NULL::text", returns: "TABLE(organization_id uuid, organization_name text, member_id uuid, record_id uuid, table_id uuid, ladder boolean, read_door boolean, rls_mirror boolean, why text)", security: "invoker" },
1467
+ { name: "shares_outside", args: "p_organization_id uuid", returns: "TABLE(invitation_id uuid, table_id uuid, table_name text, email text, level text, level_label text, status text, joined boolean, expired boolean, invited_at timestamp with time zone, expires_at timestamp with time zone, say text)", security: "definer" },
1392
1468
  { name: "sign_request_cancel", args: "p_organization_id uuid, p_request_id uuid, p_reason text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1393
1469
  { name: "sign_request_create", args: "p_organization_id uuid, p_render_id uuid, p_field_key text, p_signer_email text, p_signer_name text, p_expires_in interval DEFAULT '14 days'::interval", returns: "jsonb", security: "definer" },
1394
1470
  { name: "sign_request_decline", args: "p_token text, p_reason text DEFAULT NULL::text, p_ip text DEFAULT NULL::text, p_user_agent text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
@@ -1422,6 +1498,9 @@ var STORE_DOORS = [
1422
1498
  { name: "table_column_source", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "invoker" },
1423
1499
  { name: "table_contents", args: "p_organization_id uuid, p_table_id uuid", returns: "TABLE(record_id uuid, kind text, goes_at integer)", security: "invoker" },
1424
1500
  { name: "table_declare", args: "p_organization_id uuid, p_spec jsonb", returns: "uuid", security: "definer" },
1501
+ { name: "table_decorate", args: "p_organization_id uuid, p_table_id uuid, p_path text[], p_value jsonb DEFAULT NULL::jsonb", returns: "jsonb", security: "definer" },
1502
+ { name: "table_decorations", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
1503
+ { name: "table_from_example", args: "p_organization_id uuid, p_home_id uuid, p_example jsonb", returns: "jsonb", security: "definer" },
1425
1504
  { name: "table_has_a_visible_record", args: "p_user uuid, p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "definer" },
1426
1505
  { name: "table_is_live", args: "p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "invoker" },
1427
1506
  { name: "table_is_options_table", args: "p_organization_id uuid, p_table_id uuid", returns: "boolean", security: "invoker" },
@@ -1439,9 +1518,13 @@ var STORE_DOORS = [
1439
1518
  { name: "table_storage", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "invoker" },
1440
1519
  { name: "table_type_field", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "definer" },
1441
1520
  { name: "table_unique_rule_fields", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "invoker" },
1521
+ { name: "table_webhook_archive", args: "p_organization_id uuid, p_webhook_id uuid", returns: "boolean", security: "definer" },
1522
+ { name: "table_webhook_declare", args: "p_organization_id uuid, p_table_id uuid, p_target_url text, p_events text[] DEFAULT NULL::text[], p_description text DEFAULT NULL::text", returns: "jsonb", security: "definer" },
1523
+ { name: "table_webhooks", args: "p_organization_id uuid, p_table_id uuid", returns: "TABLE(webhook_id uuid, target_url text, description text, events text[], is_active boolean, last_attempt_at timestamp with time zone, last_success_at timestamp with time zone, consecutive_failures integer, owner_id uuid, created_at timestamp with time zone)", security: "definer" },
1442
1524
  { name: "table_work_kind", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "invoker" },
1443
1525
  { name: "tables_at_home", args: "p_organization_id uuid, p_home_ids uuid[]", returns: "TABLE(table_id uuid, home_record_id uuid, kind text)", security: "definer" },
1444
1526
  { name: "tables_described_without_asking", args: "", returns: "TABLE(function_name text, identity_args text, why text)", security: "invoker" },
1527
+ { name: "tables_shared_with_me", args: "", returns: "TABLE(table_id uuid, organization_id uuid, organization text, table_name text, level text, level_label text, shared_at timestamp with time zone, opens boolean, say text)", security: "definer" },
1445
1528
  { name: "trg_associations_bump_visibility", args: "", returns: "trigger", security: "definer" },
1446
1529
  { name: "undeclared_keys", args: "p_organization_id uuid, p_table_id uuid, p_data jsonb", returns: "text[]", security: "invoker" },
1447
1530
  { name: "validate_custom_fields", args: "p_token text, p_organization_id uuid, p_values jsonb", returns: "void", security: "invoker" },
@@ -1503,9 +1586,10 @@ var STORE_DOORS = [
1503
1586
  ];
1504
1587
  var STORE_KNOBS = [
1505
1588
  { key: "accessible_entity_ids_guard", value: "true", type: "boolean" },
1589
+ { key: "action_run_records_max", value: "5000", type: "integer" },
1506
1590
  { key: "agent_schema_changes", value: '"ask"', type: "string" },
1507
1591
  { key: "associations_guard", value: "true", type: "boolean" },
1508
- { key: "code_paths_enabled", value: "false", type: "boolean" },
1592
+ { key: "code_paths_enabled", value: "true", type: "boolean" },
1509
1593
  { key: "consumer_chat_seeding_enabled", value: "false", type: "boolean" },
1510
1594
  { key: "consumer_checkout_enabled", value: "false", type: "boolean" },
1511
1595
  { key: "consumer_context_enabled", value: "false", type: "boolean" },
@@ -1517,6 +1601,8 @@ var STORE_KNOBS = [
1517
1601
  { key: "consumer_scopes_enabled", value: "false", type: "boolean" },
1518
1602
  { key: "containment_depth_ceiling", value: "16", type: "integer" },
1519
1603
  { key: "cross_organization_links", value: "false", type: "boolean" },
1604
+ { key: "decoration_rules_max", value: "50", type: "integer" },
1605
+ { key: "decorations_max_bytes", value: "262144", type: "integer" },
1520
1606
  { key: "document_letterhead", value: "{}", type: "json" },
1521
1607
  { key: "document_max_bytes", value: "1048576", type: "integer" },
1522
1608
  { key: "emergency_door_guard", value: "false", type: "boolean" },
@@ -1528,10 +1614,12 @@ var STORE_KNOBS = [
1528
1614
  { key: "enrichment_sensitivity_ceiling", value: '"internal"', type: "string" },
1529
1615
  { key: "entity_custom_fields_guard", value: "false", type: "boolean" },
1530
1616
  { key: "entity_types_guard", value: "false", type: "boolean" },
1617
+ { key: "example_rows_max", value: "500", type: "integer" },
1531
1618
  { key: "export_rows_ceiling", value: "100000", type: "integer" },
1532
1619
  { key: "external_principal_enabled", value: "false", type: "boolean" },
1533
1620
  { key: "field_index_guard", value: "false", type: "boolean" },
1534
1621
  { key: "field_sensitivity_levels", value: '{"edit": {"public": "editor", "internal": "editor", "restricted": "admin", "confidential": "admin"}, "read": {"public": "viewer", "internal": "viewer", "restricted": "admin", "confidential": "editor"}}', type: "json" },
1622
+ { key: "grid_layout", value: '{"mode": "auto", "wrap": false, "row_height": "normal", "fit_max_columns": 8, "freeze_first_column": false}', type: "json" },
1535
1623
  { key: "inbound_domain", value: '"inbound.matrxserver.com"', type: "string" },
1536
1624
  { key: "member_default_level", value: '"viewer"', type: "enum" },
1537
1625
  { key: "member_default_visibility", value: '"all_records"', type: "enum" },
@@ -1539,6 +1627,8 @@ var STORE_KNOBS = [
1539
1627
  { key: "page_size_ceiling", value: "1000", type: "integer" },
1540
1628
  { key: "provenance_retention_days", value: "30", type: "number" },
1541
1629
  { key: "records_tool_default", value: "true", type: "boolean" },
1630
+ { key: "row_action_steps_max", value: "60", type: "integer" },
1631
+ { key: "row_actions_max", value: "24", type: "integer" },
1542
1632
  { key: "row_versions_guard", value: "false", type: "boolean" },
1543
1633
  { key: "sandbox_expanded_frame_height_px", value: "20000", type: "integer" },
1544
1634
  { key: "sandbox_frame_height_px", value: "4000", type: "integer" },
@@ -1546,27 +1636,30 @@ var STORE_KNOBS = [
1546
1636
  { key: "sandbox_org_components", value: "true", type: "boolean" },
1547
1637
  { key: "signup_provisioning_guard", value: "false", type: "boolean" },
1548
1638
  { key: "stage_rule_enforcement", value: '"refuse"', type: "enum" },
1549
- { key: "system_enabled", value: "false", type: "boolean" },
1639
+ { key: "system_enabled", value: "true", type: "boolean" },
1550
1640
  { key: "table_record_ceiling", value: "150000", type: "integer" },
1641
+ { key: "table_webhooks_max", value: "10", type: "integer" },
1551
1642
  { key: "value_max_bytes", value: "100000", type: "integer" },
1552
1643
  { key: "world_publish_enabled", value: "false", type: "boolean" }
1553
1644
  ];
1554
1645
  var STORE_REFUSAL_CODES = [
1555
- { code: "02000", raised_by: "_checklist_instantiate,_portal_invite_payload,_share_write_person,_table_share_invite_payload,checklist_declare,checklist_run,checklist_step_complete,checklist_step_refusal,checklist_template_shape,conversation_scope_bind,dashboard_delete,dashboard_run,doc_letterhead,doc_render_body,doc_render_document,doc_render_read,doc_sign,doc_signature_intact,doc_signature_read,doc_template_delete,doc_template_read,doc_template_save,enrich_pin,entity_field_retire,entity_field_update,entity_record_read,entity_value_write,external_history_event,external_rows,external_stub_upsert,external_writes_set,io_restore,migrate_delete,migrate_extract_parent,migrate_merge,migrate_reclass,migrate_rename,migrate_reparent,migrate_retype,migrate_split,migrate_undo,organization_clear,portal_archive,portal_card,portal_declare,portal_invite,portal_invite_accept,portal_preview,portal_principal_bind,portal_restore,portal_revoke,read_record,record_delete,record_restore,record_restore_preview,record_table,record_update,relation_uncarry,share_access,share_grant,share_lane_set,share_people,share_revoke,sign_request_cancel,sign_request_create,sign_request_remind,sign_request_unchanged,table_archive,table_share_outside_accept,table_share_outside_invite,table_share_outside_resend,table_share_outside_revoke,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_assign,work_record_states,work_set_state" },
1646
+ { code: "02000", raised_by: "_checklist_instantiate,_portal_invite_payload,_share_write_person,_table_share_invite_payload,checklist_declare,checklist_run,checklist_step_complete,checklist_step_refusal,checklist_template_shape,conversation_scope_bind,dashboard_delete,dashboard_run,doc_letterhead,doc_render_body,doc_render_document,doc_render_read,doc_sign,doc_signature_intact,doc_signature_read,doc_template_delete,doc_template_read,doc_template_save,enrich_pin,entity_field_retire,entity_field_update,entity_record_read,entity_value_write,external_history_event,external_rows,external_stub_upsert,external_writes_set,io_restore,migrate_delete,migrate_extract_parent,migrate_merge,migrate_reclass,migrate_rename,migrate_reparent,migrate_retype,migrate_split,migrate_undo,organization_clear,portal_archive,portal_card,portal_declare,portal_invite,portal_invite_accept,portal_preview,portal_principal_bind,portal_restore,portal_revoke,read_record,record_delete,record_restore,record_restore_preview,record_table,record_update,relation_halves_repair,relation_uncarry,share_access,share_grant,share_lane_set,share_people,share_revoke,sign_request_cancel,sign_request_create,sign_request_remind,sign_request_unchanged,table_archive,table_share_outside_accept,table_share_outside_invite,table_share_outside_resend,table_share_outside_revoke,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_assign,work_record_states,work_set_state" },
1556
1647
  { code: "0A000", raised_by: "checklist_step_complete,external_rows,external_source_declare,external_write_through,promote_field,promoted_index_expr,promoted_query_sql,promoted_read,rule_eval,work_assign" },
1557
1648
  { code: "22003", raised_by: "context_resolve" },
1558
- { code: "22004", raised_by: "_entity_custom_fields_guard,_share_write_person,_value_envelope,actor_word,agg_assert_key,agg_sql,anon_capture,anon_token_issue,anon_write,assert_client_may_reach,booking_declare,capture_submit,checklist_declare,context_resolve,dashboard_block_normalize,dashboard_declare,dashboard_window_sql,doc_render_write,doc_sign,doc_signature_write,doc_template_save,enrich_land,enrich_normalize,external_history_event,external_rows,external_source_declare,external_stub_upsert,external_write_through,external_writes_set,field_history,form_declare,form_submit,home_add,io_comment_write,io_import_begin,io_infer_column,io_outbox_drain,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_invite,portal_principal_bind,provenance_retention_days,provenance_write,query_across_homes,query_by_coordinates,query_rollup,record_delete,record_reparent,record_resolve,record_restore,record_update,record_write,record_write_graph,record_write_many,relation_carry,relation_own,rule_declare,share_grant,sign_request_create,sign_request_sign,subscription_declare,table_archive,table_declare,table_share_outside_invite,value_restore,view_declare,work_approval_decide,work_approval_request,work_template_declare" },
1649
+ { code: "22004", raised_by: "_entity_custom_fields_guard,_share_write_person,_value_envelope,actor_word,agg_assert_key,agg_sql,anon_capture,anon_token_issue,anon_write,assert_client_may_reach,booking_declare,capture_submit,checklist_declare,context_resolve,dashboard_block_normalize,dashboard_declare,dashboard_window_sql,doc_render_write,doc_sign,doc_signature_write,doc_template_save,enrich_land,enrich_normalize,external_history_event,external_rows,external_source_declare,external_stub_upsert,external_write_through,external_writes_set,field_history,form_declare,form_submit,home_add,io_comment_write,io_import_begin,io_infer_column,io_outbox_drain,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_invite,portal_principal_bind,provenance_retention_days,provenance_write,query_across_homes,query_by_coordinates,query_rollup,record_delete,record_reparent,record_resolve,record_restore,record_update,record_write,record_write_graph,record_write_many,relation_carry,relation_halves_repair,relation_own,rule_declare,share_grant,sign_request_create,sign_request_sign,subscription_declare,table_archive,table_declare,table_share_outside_invite,value_restore,view_declare,work_approval_decide,work_approval_request,work_template_declare" },
1559
1650
  { code: "22007", raised_by: "dashboard_window_sql" },
1560
- { code: "22012", raised_by: "rule_eval" },
1561
- { code: "22023", raised_by: "_booking_availability,_entity_custom_fields_guard,_take_op_id,_value_envelope,_work_shape_guard,actor_word,agg_assert_key,agg_sql,anon_token_issue,booking_declare,containment_parent,dashboard_block_normalize,dashboard_window_sql,doc_render_body,doc_render_write,doc_signature_write,enrich_declare,enrich_land,enrich_normalize,enrich_pin,entity_value_write,external_history_event,external_source_declare,external_stub_upsert,external_write_through,field_history,field_update,io_export,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,list_portals,migrate_merge,migrate_reclass,my_levels,organization_clear,page_size,pin_agent_cells,pipeline_move,portal_declare,provenance_write,query_by_coordinates,query_rollup,read_records_archived,record_update,record_write_graph,record_write_many,relation_carry,rule_eval,rule_members,share_grant,share_lane_set,sign_request_create,sign_request_sign,subscription_declare,table_rules,visibility_as_of,work_approval_request,work_list,work_slot_hold" },
1562
- { code: "23503", raised_by: "_booking_availability,_checklist_instantiate,_containment_guard,_display_spec_for,_field_document_for,_field_type_parity_guard,_pipeline_stage_key,_record_rule_uses,agg_digest_assemble,anon_publish,anon_rate_take,anon_token_issue,anon_write,assert_organization_wall,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_submit,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,pipeline_board,pipeline_declare,pipeline_move,pipeline_read,pipeline_transition_refusal,promote_field,promote_table,record_applicability,record_reparent,relation_carry,relation_own,resolve_first_match,rule_applies,rule_declare,rule_eval,rule_members,rule_run,sign_request_create,subscription_mute,subscription_preview,view_declare,work_set_state,work_take_assignment,work_template_instantiate" },
1651
+ { code: "22012", raised_by: "formula_eval,rule_eval" },
1652
+ { code: "22023", raised_by: "_action_check,_booking_availability,_decorations_check,_entity_custom_fields_guard,_fx_date,_fx_num,_fx_unit,_fxp_level,_fxp_resolve,_fxp_tokens,_take_op_id,_value_envelope,_work_shape_guard,action_run,actor_word,agg_assert_key,agg_sql,anon_token_issue,booking_declare,containment_parent,dashboard_block_normalize,dashboard_window_sql,doc_render_body,doc_render_write,doc_signature_write,enrich_declare,enrich_land,enrich_normalize,enrich_pin,entity_value_write,external_history_event,external_source_declare,external_stub_upsert,external_write_through,field_history,field_update,formula_eval,formula_parse,grid_layout_check,hub_changed_by,io_export,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,list_portals,migrate_merge,migrate_reclass,my_levels,organization_clear,page_size,pin_agent_cells,pipeline_move,portal_declare,provenance_write,query_by_coordinates,query_rollup,read_records_archived,record_update,record_write_graph,record_write_many,relation_carry,rule_eval,rule_members,share_grant,share_lane_set,sign_request_create,sign_request_sign,subscription_declare,table_from_example,table_rules,table_webhook_declare,visibility_as_of,work_approval_request,work_list,work_slot_hold" },
1653
+ { code: "23503", raised_by: "_action_check,_booking_availability,_checklist_instantiate,_containment_guard,_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_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,pipeline_board,pipeline_declare,pipeline_move,pipeline_read,pipeline_transition_refusal,promote_field,promote_table,record_applicability,record_reparent,relation_carry,relation_own,resolve_first_match,rule_applies,rule_declare,rule_eval,rule_members,rule_run,sign_request_create,subscription_mute,subscription_preview,table_decorate,table_from_example,table_webhook_archive,table_webhook_declare,view_declare,work_set_state,work_take_assignment,work_template_instantiate" },
1563
1654
  { code: "23505", raised_by: "_share_write_person,_unique_rule_holds,doc_sign,doc_signature_write,entity_field_declare,field_declare,home_add,inbound_declare,io_proposal_accept,relation_carry,relation_own,sign_request_cancel,sign_request_create,table_share_outside_resend,work_approval_decide,work_slot_hold" },
1564
- { code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_dated_values_guard,_derived_fields,_display_spec_for,_entity_custom_fields_guard,_field_class_guard,_field_document_for,_field_shape_guard,_field_type_parity_guard,_merge_field_shape_guard,_merge_field_temporal_guard,_promoted_field_cap_guard,_record_rule_uses,_relation_halves_agree,_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,assert_columns_are_defined,assert_entity_is_organization_scoped,booking_declare,capture_publish,capture_sheet_declare,checklist_declare,checklist_step_complete,doc_sign,doc_signature_write,doc_template_save,entity_field_declare,entity_field_retire,entity_field_update,entity_records_find,entity_table,field_declare,field_retire,field_update,home_add,io_comment_write,io_import_rows,migrate_merge,migrate_purge_hard,portal_archive,portal_restore,record_write_graph,relation_carry,relation_own,sign_request_create,sign_request_sign,table_declare,validate_value_envelope,validate_values,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
1655
+ { code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_dated_values_guard,_derived_fields,_display_format_check,_display_spec_for,_entity_custom_fields_guard,_field_class_guard,_field_document_for,_field_shape_guard,_field_type_parity_guard,_merge_field_shape_guard,_merge_field_temporal_guard,_promoted_field_cap_guard,_record_rule_uses,_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,doc_sign,doc_signature_write,doc_template_save,entity_field_declare,entity_field_retire,entity_field_update,entity_records_find,entity_table,field_declare,field_retire,field_update,home_add,io_comment_write,io_import_rows,migrate_merge,migrate_purge_hard,portal_archive,portal_restore,record_write_graph,relation_carry,relation_halves_repair,relation_own,sign_request_create,sign_request_sign,table_declare,table_from_example,validate_value_envelope,validate_values,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
1565
1656
  { code: "40001", raised_by: "has_visibility_at" },
1566
- { code: "42501", raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,agent_table_claim,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_open,assert_client_may_reach,assert_may_know_table,assert_organization_admin,assert_store_door,booking_confirm,booking_declare,booking_hold,capture_submit,checklist_run,comment_write,conversation_scope_bind,conversation_scope_unbind,doc_sign,enrich_declare,enrich_due,enrich_land,enrich_normalize,entity_field_declare,entity_field_retire,entity_field_update,entity_value_write,external_write_through,form_declare,form_submit,inbound_mail_land,io_comment_resolve,io_comment_write,io_import_begin,io_import_finish,io_restore,migrate_purge,migrate_purge_hard,migrate_reclass,my_levels,organization_clear,portal_declare,portal_invitation,portal_invite,portal_invite_accept,portal_principal_bind,promote_table,query_visibility_parity,read_record,read_records,read_records_archived,read_records_by_ids,read_records_matching,record_table,record_write_graph,share_grant,subscription_mute,subscription_preview,table_share_outside_accept,table_share_outside_invite,table_share_outside_resend,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_person" },
1657
+ { code: "42501", raised_by: "_doc_render_immutable,_doc_signature_immutable,_field_definition_write,_field_write_door,_rule_definition_write,_store_door,agent_table_claim,anon_capture,anon_inbound_land,anon_publish,anon_token_issue,anon_token_verify,anon_write,assert_client_may_change,assert_client_may_open,assert_client_may_reach,assert_may_know_table,assert_organization_admin,assert_store_door,booking_confirm,booking_declare,booking_hold,capture_submit,checklist_run,comment_write,conversation_scope_bind,conversation_scope_unbind,doc_sign,enrich_declare,enrich_due,enrich_land,enrich_normalize,entity_field_declare,entity_field_retire,entity_field_update,entity_value_write,external_write_through,form_declare,form_submit,inbound_mail_land,io_comment_resolve,io_comment_write,io_import_begin,io_import_finish,io_restore,migrate_purge,migrate_purge_hard,migrate_purge_hard_request,migrate_reclass,my_levels,organization_clear,portal_declare,portal_invitation,portal_invite,portal_invite_accept,portal_principal_bind,promote_table,query_visibility_parity,read_record,read_records,read_records_archived,read_records_by_ids,read_records_matching,record_table,record_write_graph,relation_halves_disagreements,relation_halves_repair,share_grant,subscription_mute,subscription_preview,table_share_outside_accept,table_share_outside_invite,table_share_outside_resend,table_webhook_declare,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_person" },
1567
1658
  { code: "42703", raised_by: "entity_table,portal_declare" },
1568
1659
  { code: "53400", raised_by: "anon_rate_take,delete_cascade_closure,enrich_due,enrich_land,promote_field" },
1660
+ { code: "54000", raised_by: "action_run,hub_changed_by,table_decorate,table_from_example,table_webhook_declare" },
1569
1661
  { code: "54001", raised_by: "record_delete" },
1662
+ { code: "P0001", raised_by: "action_run" },
1570
1663
  { code: "PT409", raised_by: "record_update" },
1571
1664
  { code: "PT428", raised_by: "_record_rule_uses" }
1572
1665
  ];
@@ -1597,6 +1690,7 @@ var ENTITY_TOKENS = [
1597
1690
  "agent_shortcut",
1598
1691
  "agent_surface_binding",
1599
1692
  "agent_template",
1693
+ "agent_term_list",
1600
1694
  "agent_usage",
1601
1695
  "agent_user_kv",
1602
1696
  "ai_api",
@@ -2649,6 +2743,7 @@ export {
2649
2743
  VALUE_ALTERNATE_KEYS,
2650
2744
  VALUE_ENVELOPE_KEYS,
2651
2745
  actionRefusals,
2746
+ allowsOtherValues,
2652
2747
  archivedByLine,
2653
2748
  archivedWhen,
2654
2749
  asPermissionLevel,
@@ -2691,6 +2786,7 @@ export {
2691
2786
  portalPath,
2692
2787
  portalTitleTypedBack,
2693
2788
  publicFormPath,
2789
+ recordChangeTrigger,
2694
2790
  rememberedOpCount,
2695
2791
  sameDocument,
2696
2792
  scopeChip,