@ai-matrx/records 0.24.0 → 0.27.0
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/CHANGELOG.md +97 -0
- package/dist/core/index.cjs +491 -8
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +110 -3
- package/dist/core/index.d.ts +110 -3
- package/dist/core/index.js +491 -8
- package/dist/core/index.js.map +1 -1
- package/dist/index.cjs +350 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +737 -15
- package/dist/index.d.ts +737 -15
- package/dist/index.js +350 -8
- package/dist/index.js.map +1 -1
- package/dist/react/index.cjs +491 -8
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.cts +831 -15
- package/dist/react/index.d.ts +831 -15
- package/dist/react/index.js +491 -8
- package/dist/react/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -38,6 +38,8 @@ __export(src_exports, {
|
|
|
38
38
|
PARITY_FIELD_TYPES: () => PARITY_FIELD_TYPES,
|
|
39
39
|
PERMISSION_LEVELS: () => PERMISSION_LEVELS,
|
|
40
40
|
PER_VALUE_ACCESS_WORDS: () => PER_VALUE_ACCESS_WORDS,
|
|
41
|
+
PIPELINE_RULE_KINDS: () => PIPELINE_RULE_KINDS,
|
|
42
|
+
REFUSALS_WORTH_REPEATING: () => REFUSALS_WORTH_REPEATING,
|
|
41
43
|
RELATION_BINDINGS: () => RELATION_BINDINGS,
|
|
42
44
|
RELATION_CARDINALITIES: () => RELATION_CARDINALITIES,
|
|
43
45
|
RELATION_FLAVORS: () => RELATION_FLAVORS,
|
|
@@ -61,11 +63,17 @@ __export(src_exports, {
|
|
|
61
63
|
err: () => err,
|
|
62
64
|
highestLevel: () => highestLevel,
|
|
63
65
|
holdsARetiredChoice: () => holdsARetiredChoice,
|
|
66
|
+
indexedDbStore: () => indexedDbStore,
|
|
67
|
+
isDecided: () => isDecided,
|
|
64
68
|
isRecordsErr: () => isRecordsErr,
|
|
65
69
|
isTheChosen: () => isTheChosen,
|
|
66
70
|
looksLikeAnId: () => looksLikeAnId,
|
|
71
|
+
mayDrag: () => mayDrag,
|
|
67
72
|
measureKey: () => measureKey,
|
|
73
|
+
memoryStore: () => memoryStore,
|
|
74
|
+
mintClientKey: () => mintClientKey,
|
|
68
75
|
ok: () => ok,
|
|
76
|
+
openCaptureQueue: () => openCaptureQueue,
|
|
69
77
|
optionKey: () => optionKey,
|
|
70
78
|
optionLabel: () => optionLabel,
|
|
71
79
|
portalPath: () => portalPath,
|
|
@@ -200,6 +208,12 @@ function looksLikeAnId(value) {
|
|
|
200
208
|
return typeof value === "string" && UUID.test(value);
|
|
201
209
|
}
|
|
202
210
|
|
|
211
|
+
// src/pipeline.ts
|
|
212
|
+
var PIPELINE_RULE_KINDS = ["moves", "requires", "who", "limit", "entry"];
|
|
213
|
+
function mayDrag(level) {
|
|
214
|
+
return level === "editor" || level === "admin" || level === "owner";
|
|
215
|
+
}
|
|
216
|
+
|
|
203
217
|
// src/rule.ts
|
|
204
218
|
function publicFormPath(formId) {
|
|
205
219
|
return `/f/${formId}`;
|
|
@@ -215,6 +229,285 @@ function measureKey(measure) {
|
|
|
215
229
|
return measure.op === "count" ? "count" : `${measure.op}_${measure.key ?? ""}`;
|
|
216
230
|
}
|
|
217
231
|
|
|
232
|
+
// src/capture-queue.ts
|
|
233
|
+
var DB_NAME = "matrx-capture";
|
|
234
|
+
var DB_VERSION = 1;
|
|
235
|
+
var ITEMS = "captures";
|
|
236
|
+
var META = "meta";
|
|
237
|
+
var REFUSALS_WORTH_REPEATING = /* @__PURE__ */ new Set([
|
|
238
|
+
"stale_read",
|
|
239
|
+
"timed_out",
|
|
240
|
+
"store_limit"
|
|
241
|
+
]);
|
|
242
|
+
var SQLSTATES_WORTH_REPEATING = /* @__PURE__ */ new Set(["40001", "57014", "53400"]);
|
|
243
|
+
function isDecided(error) {
|
|
244
|
+
if (!error) return false;
|
|
245
|
+
const { code, sqlstate } = error;
|
|
246
|
+
if (code && REFUSALS_WORTH_REPEATING.has(code)) return false;
|
|
247
|
+
if (sqlstate && SQLSTATES_WORTH_REPEATING.has(sqlstate)) return false;
|
|
248
|
+
return !!(code || sqlstate);
|
|
249
|
+
}
|
|
250
|
+
function mintClientKey() {
|
|
251
|
+
const c = typeof crypto !== "undefined" ? crypto : void 0;
|
|
252
|
+
if (c && typeof c.randomUUID === "function") return `cap-${c.randomUUID()}`;
|
|
253
|
+
if (c && typeof c.getRandomValues === "function") {
|
|
254
|
+
const b = c.getRandomValues(new Uint8Array(16));
|
|
255
|
+
return `cap-${Array.from(b, (x) => x.toString(16).padStart(2, "0")).join("")}`;
|
|
256
|
+
}
|
|
257
|
+
return `cap-${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 12)}`;
|
|
258
|
+
}
|
|
259
|
+
function indexedDbStore(name = DB_NAME) {
|
|
260
|
+
const idb = typeof globalThis !== "undefined" ? globalThis.indexedDB : void 0;
|
|
261
|
+
if (!idb) return null;
|
|
262
|
+
const open = () => new Promise((resolve, reject) => {
|
|
263
|
+
const req = idb.open(name, DB_VERSION);
|
|
264
|
+
req.onupgradeneeded = () => {
|
|
265
|
+
const db = req.result;
|
|
266
|
+
if (!db.objectStoreNames.contains(ITEMS)) db.createObjectStore(ITEMS, { keyPath: "client_key" });
|
|
267
|
+
if (!db.objectStoreNames.contains(META)) db.createObjectStore(META);
|
|
268
|
+
};
|
|
269
|
+
req.onsuccess = () => resolve(req.result);
|
|
270
|
+
req.onerror = () => reject(req.error);
|
|
271
|
+
});
|
|
272
|
+
const run = (store, mode, fn) => open().then(
|
|
273
|
+
(db) => new Promise((resolve, reject) => {
|
|
274
|
+
const tx = db.transaction(store, mode);
|
|
275
|
+
const req = fn(tx.objectStore(store));
|
|
276
|
+
req.onsuccess = () => resolve(req.result);
|
|
277
|
+
req.onerror = () => reject(req.error);
|
|
278
|
+
tx.oncomplete = () => db.close();
|
|
279
|
+
})
|
|
280
|
+
);
|
|
281
|
+
return {
|
|
282
|
+
all: () => run(ITEMS, "readonly", (s) => s.getAll()),
|
|
283
|
+
put: (item) => run(ITEMS, "readwrite", (s) => s.put(item)).then(() => void 0),
|
|
284
|
+
remove: (key) => run(ITEMS, "readwrite", (s) => s.delete(key)).then(() => void 0),
|
|
285
|
+
meta: (key) => run(META, "readonly", (s) => s.get(key)).then((v) => v ?? null),
|
|
286
|
+
setMeta: (key, value) => run(META, "readwrite", (s) => s.put(value, key)).then(() => void 0)
|
|
287
|
+
};
|
|
288
|
+
}
|
|
289
|
+
function memoryStore() {
|
|
290
|
+
const rows = /* @__PURE__ */ new Map();
|
|
291
|
+
const meta = /* @__PURE__ */ new Map();
|
|
292
|
+
return {
|
|
293
|
+
all: async () => Array.from(rows.values()),
|
|
294
|
+
put: async (item) => void rows.set(item.client_key, item),
|
|
295
|
+
remove: async (key) => void rows.delete(key),
|
|
296
|
+
meta: async (key) => meta.get(key) ?? null,
|
|
297
|
+
setMeta: async (key, value) => void meta.set(key, value)
|
|
298
|
+
};
|
|
299
|
+
}
|
|
300
|
+
function countOf(items) {
|
|
301
|
+
const c = { waiting: 0, sending: 0, refused: 0, landed: 0 };
|
|
302
|
+
for (const i of items) c[i.state] += 1;
|
|
303
|
+
return c;
|
|
304
|
+
}
|
|
305
|
+
function openCaptureQueue(opts) {
|
|
306
|
+
const now = opts.now ?? (() => /* @__PURE__ */ new Date());
|
|
307
|
+
const store = opts.store ?? indexedDbStore() ?? memoryStore();
|
|
308
|
+
let syncing = null;
|
|
309
|
+
let disposed = false;
|
|
310
|
+
const online = () => {
|
|
311
|
+
const nav = typeof navigator !== "undefined" ? navigator : void 0;
|
|
312
|
+
return nav ? nav.onLine !== false : true;
|
|
313
|
+
};
|
|
314
|
+
const announce = async () => {
|
|
315
|
+
if (!opts.onChange) return;
|
|
316
|
+
const items = await store.all();
|
|
317
|
+
opts.onChange(countOf(items), items);
|
|
318
|
+
};
|
|
319
|
+
const oldestFirst = (items) => items.slice().sort((a, b) => a.captured_at.localeCompare(b.captured_at));
|
|
320
|
+
const queue = {
|
|
321
|
+
async enqueue(input) {
|
|
322
|
+
const key = input.client_key ?? mintClientKey();
|
|
323
|
+
const item = {
|
|
324
|
+
client_key: key,
|
|
325
|
+
organization_id: input.organization_id,
|
|
326
|
+
sheet_id: input.sheet_id,
|
|
327
|
+
sheet_title: input.sheet_title,
|
|
328
|
+
answers: input.answers ?? {},
|
|
329
|
+
files: (input.files ?? []).map((f) => ({ ...f, uploaded: null })),
|
|
330
|
+
device: input.device ?? null,
|
|
331
|
+
captured_at: input.captured_at ?? now().toISOString(),
|
|
332
|
+
location: input.location ?? null,
|
|
333
|
+
state: "waiting",
|
|
334
|
+
attempts: 0,
|
|
335
|
+
last_error: null,
|
|
336
|
+
record_id: null,
|
|
337
|
+
replayed: false,
|
|
338
|
+
queued_at: now().toISOString(),
|
|
339
|
+
landed_at: null
|
|
340
|
+
};
|
|
341
|
+
await store.put(item);
|
|
342
|
+
await announce();
|
|
343
|
+
return key;
|
|
344
|
+
},
|
|
345
|
+
list: () => store.all().then(oldestFirst),
|
|
346
|
+
counts: () => store.all().then(countOf),
|
|
347
|
+
async sync() {
|
|
348
|
+
if (syncing) return syncing;
|
|
349
|
+
syncing = (async () => {
|
|
350
|
+
const report = {
|
|
351
|
+
attempted: 0,
|
|
352
|
+
landed: 0,
|
|
353
|
+
replayed: 0,
|
|
354
|
+
refused: 0,
|
|
355
|
+
deferred: 0,
|
|
356
|
+
outcomes: []
|
|
357
|
+
};
|
|
358
|
+
const pending = oldestFirst(await store.all()).filter((i) => i.state === "waiting" || i.state === "sending");
|
|
359
|
+
if (!online()) {
|
|
360
|
+
report.deferred = pending.length;
|
|
361
|
+
report.stopped_because = "There is no signal, so nothing was sent. Everything is still here.";
|
|
362
|
+
return report;
|
|
363
|
+
}
|
|
364
|
+
for (const item of pending) {
|
|
365
|
+
report.attempted += 1;
|
|
366
|
+
item.state = "sending";
|
|
367
|
+
item.attempts += 1;
|
|
368
|
+
await store.put(item);
|
|
369
|
+
await announce();
|
|
370
|
+
try {
|
|
371
|
+
for (const f of item.files) {
|
|
372
|
+
if (f.uploaded) continue;
|
|
373
|
+
f.uploaded = await opts.ports.uploadFile(f, item);
|
|
374
|
+
f.blob = null;
|
|
375
|
+
await store.put(item);
|
|
376
|
+
}
|
|
377
|
+
const refs = item.files.map((f) => ({
|
|
378
|
+
field: f.field,
|
|
379
|
+
name: f.name,
|
|
380
|
+
mime_type: f.mime_type,
|
|
381
|
+
size_bytes: f.size_bytes,
|
|
382
|
+
duration_ms: f.duration_ms ?? null,
|
|
383
|
+
file_id: f.uploaded?.file_id ?? null,
|
|
384
|
+
url: f.uploaded?.url ?? null
|
|
385
|
+
}));
|
|
386
|
+
const res = await opts.ports.submit({
|
|
387
|
+
sheet_id: item.sheet_id,
|
|
388
|
+
client_key: item.client_key,
|
|
389
|
+
answers: item.answers,
|
|
390
|
+
files: refs,
|
|
391
|
+
device: item.device,
|
|
392
|
+
captured_at: item.captured_at,
|
|
393
|
+
location: item.location
|
|
394
|
+
});
|
|
395
|
+
if (res.ok && res.data && res.data.record_id) {
|
|
396
|
+
item.state = "landed";
|
|
397
|
+
item.record_id = res.data.record_id;
|
|
398
|
+
item.replayed = !!res.data.replay;
|
|
399
|
+
item.landed_at = now().toISOString();
|
|
400
|
+
item.last_error = null;
|
|
401
|
+
report.landed += 1;
|
|
402
|
+
if (item.replayed) report.replayed += 1;
|
|
403
|
+
report.outcomes.push({
|
|
404
|
+
client_key: item.client_key,
|
|
405
|
+
state: item.state,
|
|
406
|
+
record_id: item.record_id,
|
|
407
|
+
replay: item.replayed,
|
|
408
|
+
says: res.data.message ?? null
|
|
409
|
+
});
|
|
410
|
+
} else if (res.ok && res.data && !res.data.record_id) {
|
|
411
|
+
item.state = "refused";
|
|
412
|
+
item.last_error = res.data.message ?? `This sheet is ${res.data.state}.`;
|
|
413
|
+
report.refused += 1;
|
|
414
|
+
report.outcomes.push({
|
|
415
|
+
client_key: item.client_key,
|
|
416
|
+
state: item.state,
|
|
417
|
+
record_id: null,
|
|
418
|
+
replay: false,
|
|
419
|
+
says: item.last_error
|
|
420
|
+
});
|
|
421
|
+
} else if (isDecided(res.error)) {
|
|
422
|
+
item.state = "refused";
|
|
423
|
+
item.last_error = res.error?.message ?? "The store refused this capture.";
|
|
424
|
+
report.refused += 1;
|
|
425
|
+
report.outcomes.push({
|
|
426
|
+
client_key: item.client_key,
|
|
427
|
+
state: item.state,
|
|
428
|
+
record_id: null,
|
|
429
|
+
replay: false,
|
|
430
|
+
says: item.last_error
|
|
431
|
+
});
|
|
432
|
+
} else {
|
|
433
|
+
item.state = "waiting";
|
|
434
|
+
item.last_error = res.error?.message ?? "It could not be sent just now.";
|
|
435
|
+
report.deferred += 1;
|
|
436
|
+
report.outcomes.push({
|
|
437
|
+
client_key: item.client_key,
|
|
438
|
+
state: item.state,
|
|
439
|
+
record_id: null,
|
|
440
|
+
replay: false,
|
|
441
|
+
says: item.last_error
|
|
442
|
+
});
|
|
443
|
+
}
|
|
444
|
+
} catch (err2) {
|
|
445
|
+
item.state = "waiting";
|
|
446
|
+
item.last_error = err2 instanceof Error ? err2.message : "It could not be sent just now.";
|
|
447
|
+
report.deferred += 1;
|
|
448
|
+
report.outcomes.push({
|
|
449
|
+
client_key: item.client_key,
|
|
450
|
+
state: item.state,
|
|
451
|
+
record_id: null,
|
|
452
|
+
replay: false,
|
|
453
|
+
says: item.last_error
|
|
454
|
+
});
|
|
455
|
+
}
|
|
456
|
+
await store.put(item);
|
|
457
|
+
await announce();
|
|
458
|
+
if (!online()) {
|
|
459
|
+
report.stopped_because = "The signal went away again. Everything still on the phone is still here.";
|
|
460
|
+
break;
|
|
461
|
+
}
|
|
462
|
+
}
|
|
463
|
+
await store.setMeta("last_synced_at", now().toISOString());
|
|
464
|
+
return report;
|
|
465
|
+
})();
|
|
466
|
+
try {
|
|
467
|
+
return await syncing;
|
|
468
|
+
} finally {
|
|
469
|
+
syncing = null;
|
|
470
|
+
}
|
|
471
|
+
},
|
|
472
|
+
async retry(clientKey, patch) {
|
|
473
|
+
const items = await store.all();
|
|
474
|
+
const item = items.find((i) => i.client_key === clientKey);
|
|
475
|
+
if (!item) return;
|
|
476
|
+
if (patch?.answers) item.answers = { ...item.answers, ...patch.answers };
|
|
477
|
+
item.state = "waiting";
|
|
478
|
+
item.last_error = null;
|
|
479
|
+
await store.put(item);
|
|
480
|
+
await announce();
|
|
481
|
+
},
|
|
482
|
+
async discard(clientKey) {
|
|
483
|
+
await store.remove(clientKey);
|
|
484
|
+
await announce();
|
|
485
|
+
},
|
|
486
|
+
async clearLanded() {
|
|
487
|
+
const items = await store.all();
|
|
488
|
+
const landed = items.filter((i) => i.state === "landed");
|
|
489
|
+
for (const i of landed) await store.remove(i.client_key);
|
|
490
|
+
await announce();
|
|
491
|
+
return landed.length;
|
|
492
|
+
},
|
|
493
|
+
lastSyncedAt: () => store.meta("last_synced_at"),
|
|
494
|
+
isOnline: online,
|
|
495
|
+
dispose() {
|
|
496
|
+
disposed = true;
|
|
497
|
+
if (typeof window !== "undefined" && handler) window.removeEventListener("online", handler);
|
|
498
|
+
}
|
|
499
|
+
};
|
|
500
|
+
let handler = null;
|
|
501
|
+
const auto = opts.autoSync ?? typeof window !== "undefined";
|
|
502
|
+
if (auto && typeof window !== "undefined") {
|
|
503
|
+
handler = () => {
|
|
504
|
+
if (!disposed) void queue.sync();
|
|
505
|
+
};
|
|
506
|
+
window.addEventListener("online", handler);
|
|
507
|
+
}
|
|
508
|
+
return queue;
|
|
509
|
+
}
|
|
510
|
+
|
|
218
511
|
// src/results.ts
|
|
219
512
|
function isRecordsErr(result) {
|
|
220
513
|
return result.ok === false;
|
|
@@ -247,6 +540,7 @@ var PARITY_FIELD_TYPES = [
|
|
|
247
540
|
{ parity_type: "url", behavior: "text", made_of: "text whose format is url, with the pattern Rule that makes the format enforceable" }
|
|
248
541
|
];
|
|
249
542
|
var RULE_NODE_KINDS = [
|
|
543
|
+
{ node: "actor_at_least", evaluated_by: "PIPELINES" },
|
|
250
544
|
{ node: "add", evaluated_by: "W1-RULE" },
|
|
251
545
|
{ node: "and", evaluated_by: "W1-RULE" },
|
|
252
546
|
{ node: "concat", evaluated_by: "W1-RULE" },
|
|
@@ -267,6 +561,8 @@ var RULE_NODE_KINDS = [
|
|
|
267
561
|
{ node: "or", evaluated_by: "W1-RULE" },
|
|
268
562
|
{ node: "parent_field", evaluated_by: "W1-RULE-APPLY" },
|
|
269
563
|
{ node: "present", evaluated_by: "W1-RULE" },
|
|
564
|
+
{ node: "previous", evaluated_by: "PIPELINES" },
|
|
565
|
+
{ node: "stage_count", evaluated_by: "PIPELINES" },
|
|
270
566
|
{ node: "sub", evaluated_by: "W1-RULE" }
|
|
271
567
|
];
|
|
272
568
|
var KERNEL_TABLES = [
|
|
@@ -289,16 +585,27 @@ var STORE_DOORS = [
|
|
|
289
585
|
{ name: "agent_table_claim", args: "p_organization uuid, p_table uuid, p_conversation uuid DEFAULT NULL::uuid", returns: "void", security: "definer" },
|
|
290
586
|
{ name: "agg_assert_key", args: "p_key text", returns: "text", security: "invoker" },
|
|
291
587
|
{ name: "agg_buckets", args: "", returns: "text[]", security: "invoker" },
|
|
292
|
-
{ name: "
|
|
588
|
+
{ name: "agg_cadence_normalize", args: "p_cadence text", returns: "text", security: "invoker" },
|
|
589
|
+
{ name: "agg_deliver", args: "p_organization_id uuid, p_rule_id uuid, p_record_id uuid, p_channel text, p_recipient_user_id uuid, p_event_key text, p_subject text, p_body text, p_payload jsonb DEFAULT '{}'::jsonb, p_dedupe_suffix text DEFAULT NULL::text", returns: "uuid", security: "invoker" },
|
|
590
|
+
{ name: "agg_deliver_quietly", args: "p_organization_id uuid, p_rule_id uuid, p_subject_id uuid, p_channel text, p_recipient_user_id uuid, p_event_key text, p_subject text, p_body text, p_payload jsonb, p_quiet_hours jsonb, p_link text, p_dedupe_suffix text DEFAULT NULL::text", returns: "uuid", security: "invoker" },
|
|
591
|
+
{ name: "agg_digest_assemble", args: "p_organization_id uuid, p_rule_id uuid, p_since timestamp with time zone DEFAULT NULL::timestamp with time zone, p_until timestamp with time zone DEFAULT NULL::timestamp with time zone", returns: "jsonb", security: "invoker" },
|
|
592
|
+
{ name: "agg_digest_due_at", args: "p_cadence text, p_schedule text, p_quiet jsonb, p_after timestamp with time zone", returns: "timestamp with time zone", security: "invoker" },
|
|
293
593
|
{ name: "agg_digest_run", args: "p_organization_id uuid, p_rule_id uuid DEFAULT NULL::uuid, p_since timestamp with time zone DEFAULT NULL::timestamp with time zone", returns: "integer", security: "invoker" },
|
|
594
|
+
{ name: "agg_digest_tick", args: "", returns: "integer", security: "invoker" },
|
|
294
595
|
{ name: "agg_explain", args: "p_organization_id uuid, p_table_id uuid, p_group_by jsonb DEFAULT '[]'::jsonb, p_measures jsonb DEFAULT '[]'::jsonb, p_bucket jsonb DEFAULT NULL::jsonb, p_filter jsonb DEFAULT '{}'::jsonb, p_required text DEFAULT 'viewer'::text", returns: "jsonb", security: "definer" },
|
|
596
|
+
{ name: "agg_last_digest_at", args: "p_organization_id uuid, p_rule_id uuid", returns: "timestamp with time zone", security: "invoker" },
|
|
295
597
|
{ name: "agg_operations", args: "", returns: "text[]", security: "invoker" },
|
|
598
|
+
{ name: "agg_quiet_until", args: "p_quiet jsonb, p_at timestamp with time zone", returns: "timestamp with time zone", security: "invoker" },
|
|
599
|
+
{ name: "agg_record_name", args: "p_organization_id uuid, p_record_id uuid, p_state jsonb DEFAULT NULL::jsonb", returns: "text", security: "invoker" },
|
|
296
600
|
{ name: "agg_sql", args: "p_organization_id uuid, p_table_id uuid, p_group_by jsonb DEFAULT '[]'::jsonb, p_measures jsonb DEFAULT '[]'::jsonb, p_bucket jsonb DEFAULT NULL::jsonb, p_filter jsonb DEFAULT '{}'::jsonb, p_limit integer DEFAULT 200, p_required text DEFAULT 'viewer'::text", returns: "text", security: "invoker" },
|
|
297
601
|
{ name: "agg_subscription_cadences", args: "", returns: "text[]", security: "invoker" },
|
|
298
602
|
{ name: "agg_subscription_fire", args: "p_organization_id uuid, p_record_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_changed_field_ids jsonb DEFAULT '[]'::jsonb", returns: "integer", security: "invoker" },
|
|
299
|
-
{ name: "
|
|
603
|
+
{ name: "agg_subscription_fire_entered", args: "p_organization_id uuid, p_record_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_since timestamp with time zone DEFAULT NULL::timestamp with time zone", returns: "integer", security: "invoker" },
|
|
604
|
+
{ name: "agg_subscription_tick", args: "p_window interval DEFAULT '00:15:00'::interval", returns: "integer", security: "invoker" },
|
|
605
|
+
{ name: "agg_subscriptions", args: "p_organization_id uuid, p_saved_view_id uuid DEFAULT NULL::uuid, p_cadence text DEFAULT NULL::text", returns: "TABLE(rule_id uuid, saved_view_id uuid, table_id uuid, cadence text, schedule text, quiet_hours jsonb, channel text, recipient_user_id uuid, event_key text, name text)", security: "invoker" },
|
|
300
606
|
{ name: "agg_value_sql", args: "p_key text", returns: "text", security: "invoker" },
|
|
301
607
|
{ name: "agg_view_admits", args: "p_organization_id uuid, p_saved_view_id uuid, p_record_id uuid", returns: "boolean", security: "invoker" },
|
|
608
|
+
{ name: "agg_view_admits_state", args: "p_definition jsonb, p_state jsonb", returns: "boolean", security: "invoker" },
|
|
302
609
|
{ name: "anon_capture", args: "p_organization_id uuid, p_client_key text, p_table_id uuid, p_payload jsonb, p_device text DEFAULT NULL::text, p_captured_at timestamp with time zone DEFAULT NULL::timestamp with time zone", returns: "uuid", security: "definer" },
|
|
303
610
|
{ name: "anon_clear", args: "p_organization_id uuid, p_submission_id uuid", returns: "uuid", security: "definer" },
|
|
304
611
|
{ name: "anon_inbound_land", args: "p_address text, p_secret text, p_payload jsonb, p_raw_payload jsonb DEFAULT '{}'::jsonb, p_client_key text DEFAULT NULL::text", returns: "uuid", security: "definer" },
|
|
@@ -319,9 +626,23 @@ var STORE_DOORS = [
|
|
|
319
626
|
{ name: "assert_organization_admin", args: "p_organization_id uuid, p_door text, p_what text", returns: "void", security: "invoker" },
|
|
320
627
|
{ name: "assert_organization_wall", args: "p_kind text, p_organization_id uuid, p_row jsonb", returns: "void", security: "invoker" },
|
|
321
628
|
{ name: "assert_store_door", args: "p_organization_id uuid, p_door text", returns: "void", security: "invoker" },
|
|
629
|
+
{ 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" },
|
|
630
|
+
{ 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" },
|
|
631
|
+
{ 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" },
|
|
632
|
+
{ name: "booking_hold", args: "p_form_id uuid, p_slot_key text, p_origin text, p_bucket text, p_client_key text DEFAULT NULL::text", returns: "TABLE(hold_id uuid, slot_key text, expires_at timestamp with time zone, member_user_id uuid, state text, message text)", security: "definer" },
|
|
633
|
+
{ name: "booking_manage", args: "p_booking_ref text, p_days integer DEFAULT NULL::integer", returns: "TABLE(booking_ref text, form_id uuid, title text, slot_key text, slot_at timestamp with time zone, status text, slots jsonb, availability jsonb, state text, message text)", security: "definer" },
|
|
634
|
+
{ name: "booking_notify", args: "p_organization_id uuid, p_form_id uuid, p_record_id uuid, p_submission_id uuid, p_event text, p_when text", returns: "uuid", security: "invoker" },
|
|
635
|
+
{ name: "booking_public", args: "p_form_id uuid, p_days integer DEFAULT NULL::integer", returns: "TABLE(form_id uuid, organization_id uuid, table_id uuid, title text, presentation jsonb, fields jsonb, honeypot_key text, availability jsonb, slots jsonb, state text, message text)", security: "definer" },
|
|
636
|
+
{ name: "booking_reschedule", args: "p_booking_ref text, p_slot_key text, p_origin text, p_bucket text DEFAULT NULL::text", returns: "TABLE(booking_ref text, record_id uuid, slot_key text, slot_at timestamp with time zone, state text, message text)", security: "definer" },
|
|
637
|
+
{ name: "bookings", 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, slot_minutes integer, timezone text, slot_table_id uuid, booked bigint, cancelled bigint, upcoming bigint, held bigint, next_at timestamp with time zone, state text)", security: "definer" },
|
|
322
638
|
{ name: "bump_epoch", args: "p_entity_type text, p_entity_id uuid, p_organization_id uuid DEFAULT NULL::uuid", returns: "bigint", security: "definer" },
|
|
323
639
|
{ name: "cache_lookup", args: "p_container_type text, p_container_id uuid, p_item_type text, p_item_id uuid", returns: "permission_level", security: "definer" },
|
|
324
640
|
{ name: "caller_role", args: "", returns: "name", security: "invoker" },
|
|
641
|
+
{ name: "capture_open", args: "p_organization_id uuid, p_sheet_id uuid", returns: "TABLE(sheet_id uuid, organization_id uuid, table_id uuid, title text, presentation jsonb, fields jsonb, state text, may_capture boolean, message text)", security: "definer" },
|
|
642
|
+
{ name: "capture_publish", args: "p_organization_id uuid, p_sheet_id uuid, p_open boolean DEFAULT true", returns: "timestamp with time zone", security: "definer" },
|
|
643
|
+
{ name: "capture_sheet_declare", args: "p_organization_id uuid, p_table_id uuid, p_title text, p_questions jsonb, p_presentation jsonb DEFAULT '{}'::jsonb, p_sheet_id uuid DEFAULT NULL::uuid, p_notify_rule_id uuid DEFAULT NULL::uuid", returns: "uuid", security: "definer" },
|
|
644
|
+
{ name: "capture_sheets", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "TABLE(sheet_id uuid, table_id uuid, title text, slug text, state text, opened_at timestamp with time zone, captures bigint, replays bigint, last_capture_at timestamp with time zone, presentation jsonb)", security: "definer" },
|
|
645
|
+
{ name: "capture_submit", args: "p_organization_id uuid, p_sheet_id uuid, p_client_key text, p_payload jsonb, p_files jsonb DEFAULT '[]'::jsonb, p_device text DEFAULT NULL::text, p_captured_at timestamp with time zone DEFAULT NULL::timestamp with time zone, p_location jsonb DEFAULT NULL::jsonb", returns: "TABLE(record_id uuid, state text, message text, replay boolean, file_ids uuid[])", security: "definer" },
|
|
325
646
|
{ name: "carry_unchanged_value_stamps", args: "p_old jsonb, p_new jsonb", returns: "jsonb", security: "invoker" },
|
|
326
647
|
{ name: "carrying_edges_in", args: "p_organization_id uuid", returns: "TABLE(container_type text, container_id uuid, item_type text, item_id uuid, conveys_max permission_level)", security: "definer" },
|
|
327
648
|
{ name: "carrying_edges_of", args: "p_item_type text, p_item_id uuid", returns: "TABLE(container_type text, container_id uuid, conveys_max permission_level)", security: "definer" },
|
|
@@ -432,6 +753,7 @@ var STORE_DOORS = [
|
|
|
432
753
|
{ name: "entity_records_find", args: "p_organization_id uuid, p_token text, p_key text, p_value jsonb DEFAULT NULL::jsonb, p_limit integer DEFAULT 50, p_offset integer DEFAULT 0", returns: "jsonb", security: "invoker" },
|
|
433
754
|
{ name: "entity_table", args: "p_token text", returns: "TABLE(token text, schema_name text, table_name text, type text, title_column text, label text, has_organization boolean, has_deleted_at boolean)", security: "invoker" },
|
|
434
755
|
{ name: "entity_value_write", args: "p_organization_id uuid, p_token text, p_record_id uuid, p_patch jsonb", returns: "jsonb", security: "invoker" },
|
|
756
|
+
{ name: "export_ceiling", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "integer", security: "definer" },
|
|
435
757
|
{ 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" },
|
|
436
758
|
{ name: "external_foreign_table_findings", args: "", returns: "SETOF text", security: "definer" },
|
|
437
759
|
{ name: "external_history_event", args: "p_organization_id uuid, p_link_id uuid, p_operation text", returns: "bigint", security: "definer" },
|
|
@@ -459,6 +781,7 @@ var STORE_DOORS = [
|
|
|
459
781
|
{ 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" },
|
|
460
782
|
{ 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" },
|
|
461
783
|
{ 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" },
|
|
784
|
+
{ name: "freshness_verdict", args: "p_written_at timestamp with time zone, p_ceiling_seconds numeric", returns: "jsonb", security: "definer" },
|
|
462
785
|
{ name: "guard_refusals_are_complete", args: "", returns: "TABLE(guard text, said text)", security: "invoker" },
|
|
463
786
|
{ 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" },
|
|
464
787
|
{ 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" },
|
|
@@ -548,12 +871,20 @@ var STORE_DOORS = [
|
|
|
548
871
|
{ 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" },
|
|
549
872
|
{ name: "owning_table", args: "p_organization_id uuid, p_record_id uuid", returns: "uuid", security: "invoker" },
|
|
550
873
|
{ name: "owning_table_gone", args: "p_organization_id uuid, p_record_id uuid", returns: "boolean", security: "invoker" },
|
|
874
|
+
{ name: "page_ceiling", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "integer", security: "definer" },
|
|
875
|
+
{ name: "page_contract", args: "p_organization_id uuid", returns: "jsonb", security: "definer" },
|
|
876
|
+
{ name: "page_size", args: "p_organization_id uuid, p_door text, p_limit integer, p_default integer DEFAULT NULL::integer, p_ceiling integer DEFAULT NULL::integer", returns: "integer", security: "definer" },
|
|
551
877
|
{ name: "parity_field_types", args: "", returns: "TABLE(parity_type text, behavior text, made_of text)", security: "invoker" },
|
|
552
878
|
{ name: "parity_type", args: "p_field_data jsonb", returns: "text", security: "invoker" },
|
|
553
879
|
{ 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" },
|
|
554
880
|
{ name: "per_value_access_words", args: "", returns: "text[]", security: "invoker" },
|
|
555
881
|
{ name: "person_kernel_id", args: "", returns: "uuid", security: "invoker" },
|
|
556
882
|
{ name: "pin_agent_cells", args: "p_new jsonb, p_old jsonb, p_agent_keys text[]", returns: "jsonb", security: "invoker" },
|
|
883
|
+
{ name: "pipeline_board", args: "p_organization_id uuid, p_table_id uuid, p_measure text DEFAULT NULL::text", returns: "TABLE(stage_key text, stage_label text, stage_position integer, cards bigint, total numeric, wip_limit integer, over_limit boolean)", security: "definer" },
|
|
884
|
+
{ name: "pipeline_declare", args: "p_organization_id uuid, p_table_id uuid, p_spec jsonb", returns: "jsonb", security: "definer" },
|
|
885
|
+
{ name: "pipeline_move", args: "p_organization_id uuid, p_record_id uuid, p_to text, p_also jsonb DEFAULT '{}'::jsonb, p_expected_version integer DEFAULT NULL::integer", returns: "jsonb", security: "definer" },
|
|
886
|
+
{ name: "pipeline_read", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
|
|
887
|
+
{ name: "pipeline_transition_refusal", args: "p_organization_id uuid, p_record_id uuid, p_to text", returns: "jsonb", security: "definer" },
|
|
557
888
|
{ name: "portal_admits", args: "p_organization_id uuid, p_user_id uuid DEFAULT NULL::uuid", returns: "boolean", security: "definer" },
|
|
558
889
|
{ name: "portal_card", args: "p_organization_id uuid, p_portal_id uuid", returns: "jsonb", security: "definer" },
|
|
559
890
|
{ name: "portal_declare", args: "p_organization_id uuid, p_title text, p_client_table_id uuid, p_tables jsonb, p_portal_id uuid DEFAULT NULL::uuid, p_slug text DEFAULT NULL::text, p_sign_in_method text DEFAULT 'magic_link'::text", returns: "uuid", security: "definer" },
|
|
@@ -581,6 +912,9 @@ var STORE_DOORS = [
|
|
|
581
912
|
{ name: "promoted_read", args: "p_organization_id uuid, p_table_id uuid, p_field_key text, p_value text", returns: "SETOF uuid", security: "invoker" },
|
|
582
913
|
{ name: "promoted_value_path", args: "p_field_data jsonb", returns: "text", security: "invoker" },
|
|
583
914
|
{ name: "promotion_inline_ceiling", args: "", returns: "integer", security: "invoker" },
|
|
915
|
+
{ name: "provenance_prune", args: "p_organization_id uuid DEFAULT NULL::uuid, p_dry_run boolean DEFAULT true, p_limit integer DEFAULT 200000", returns: "jsonb", security: "definer" },
|
|
916
|
+
{ name: "provenance_retention_days", args: "p_organization_id uuid", returns: "integer", security: "definer" },
|
|
917
|
+
{ name: "provenance_write", args: "p_organization_id uuid, p_conversation_id uuid, p_turn_id text, p_rows jsonb", returns: "integer", security: "definer" },
|
|
584
918
|
{ name: "query_access_ids", args: "p_organization_id uuid, p_required text DEFAULT 'viewer'::text", returns: "uuid[]", security: "invoker" },
|
|
585
919
|
{ name: "query_across_homes", args: "p_organization_id uuid, p_table_id uuid, p_limit integer DEFAULT 50, p_offset integer DEFAULT 0, p_required text DEFAULT 'viewer'::text", returns: "TABLE(record_id uuid, home_record_id uuid, data jsonb, created_at timestamp with time zone)", security: "definer" },
|
|
586
920
|
{ name: "query_by_coordinates", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid, p_coordinates jsonb DEFAULT '[]'::jsonb, p_limit integer DEFAULT 50, p_offset integer DEFAULT 0, p_required text DEFAULT 'viewer'::text", returns: "TABLE(record_id uuid, table_id uuid, data jsonb, coordinates_matched integer)", security: "definer" },
|
|
@@ -681,6 +1015,7 @@ var STORE_DOORS = [
|
|
|
681
1015
|
{ name: "sign_requests", args: "p_organization_id uuid, p_record_id uuid", returns: "TABLE(request_id uuid, render_id uuid, record_id uuid, field_key text, document_title text, signer_name text, signer_email text, signer_has_account boolean, state text, sentence text, document_version integer, document_hash text, sent_at timestamp with time zone, expires_at timestamp with time zone, viewed_at timestamp with time zone, signed_at timestamp with time zone, declined_at timestamp with time zone, invalidated_at timestamp with time zone, signature_id uuid, signature_mark text, reminder_count integer)", security: "definer" },
|
|
682
1016
|
{ name: "sign_token_decode", args: "p_token text", returns: "bytea", security: "invoker" },
|
|
683
1017
|
{ name: "sign_token_encode", args: "p_bytes bytea", returns: "text", security: "invoker" },
|
|
1018
|
+
{ name: "silent_page_doors", args: "", returns: "TABLE(door text, why text)", security: "definer" },
|
|
684
1019
|
{ name: "size_refusal", args: "p_organization_id uuid, p_data jsonb", returns: "text", security: "invoker" },
|
|
685
1020
|
{ name: "source_next_pointer", args: "p_sources jsonb", returns: "text", security: "invoker" },
|
|
686
1021
|
{ name: "source_pointer", args: "p_sources jsonb, p_source jsonb", returns: "text", security: "invoker" },
|
|
@@ -688,8 +1023,10 @@ var STORE_DOORS = [
|
|
|
688
1023
|
{ name: "storage_modes", args: "", returns: "text[]", security: "invoker" },
|
|
689
1024
|
{ name: "store_is_open", args: "p_organization_id uuid DEFAULT NULL::uuid", returns: "boolean", security: "invoker" },
|
|
690
1025
|
{ name: "subscription_cadences", args: "p_organization_id uuid", returns: "text[]", security: "definer" },
|
|
1026
|
+
{ name: "subscription_declare", args: "p_organization_id uuid, p_table_id uuid, p_spec jsonb", returns: "uuid", security: "definer" },
|
|
691
1027
|
{ name: "subscription_mute", args: "p_organization_id uuid, p_rule_id uuid, p_muted boolean DEFAULT true", returns: "boolean", security: "definer" },
|
|
692
|
-
{ name: "
|
|
1028
|
+
{ name: "subscription_preview", args: "p_organization_id uuid, p_rule_id uuid", returns: "jsonb", security: "definer" },
|
|
1029
|
+
{ name: "subscriptions", args: "p_organization_id uuid, p_table_id uuid DEFAULT NULL::uuid", returns: "TABLE(rule_id uuid, name text, table_id uuid, saved_view_id uuid, cadence text, schedule text, quiet_hours jsonb, channel text, recipient_user_id uuid, event_key text, muted boolean, mine boolean, i_may_mute boolean, last_sent_at timestamp with time zone, next_digest_at timestamp with time zone)", security: "definer" },
|
|
693
1030
|
{ name: "table_capacity", args: "p_organization_id uuid, p_table_id uuid", returns: "jsonb", security: "definer" },
|
|
694
1031
|
{ name: "table_carries_its_rows", args: "p_user_id uuid, p_table_id uuid, p_required permission_level DEFAULT 'viewer'::permission_level", returns: "boolean", security: "definer" },
|
|
695
1032
|
{ name: "table_contents", args: "p_organization_id uuid, p_table_id uuid", returns: "TABLE(record_id uuid, kind text, goes_at integer)", security: "invoker" },
|
|
@@ -700,6 +1037,7 @@ var STORE_DOORS = [
|
|
|
700
1037
|
{ name: "table_record_ceiling", args: "", returns: "integer", security: "invoker" },
|
|
701
1038
|
{ name: "table_record_ceiling", args: "p_organization_id uuid", returns: "integer", security: "invoker" },
|
|
702
1039
|
{ name: "table_rules", args: "p_organization_id uuid, p_table_id uuid, p_use text, p_record_type text DEFAULT NULL::text", returns: "SETOF custom.record", security: "invoker" },
|
|
1040
|
+
{ name: "table_stage_field", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "definer" },
|
|
703
1041
|
{ name: "table_storage", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "invoker" },
|
|
704
1042
|
{ name: "table_type_field", args: "p_organization_id uuid, p_table_id uuid", returns: "text", security: "definer" },
|
|
705
1043
|
{ 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" },
|
|
@@ -787,12 +1125,15 @@ var STORE_KNOBS = [
|
|
|
787
1125
|
{ key: "enrichment_sensitivity_ceiling", value: '"internal"', type: "string" },
|
|
788
1126
|
{ key: "entity_custom_fields_guard", value: "false", type: "boolean" },
|
|
789
1127
|
{ key: "entity_types_guard", value: "false", type: "boolean" },
|
|
1128
|
+
{ key: "export_rows_ceiling", value: "100000", type: "integer" },
|
|
790
1129
|
{ key: "external_principal_enabled", value: "false", type: "boolean" },
|
|
791
1130
|
{ key: "field_index_guard", value: "false", type: "boolean" },
|
|
792
1131
|
{ 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" },
|
|
793
1132
|
{ key: "inbound_domain", value: '"inbound.matrxserver.com"', type: "string" },
|
|
794
1133
|
{ key: "member_default_level", value: '"viewer"', type: "enum" },
|
|
795
1134
|
{ key: "member_default_visibility", value: '"all_records"', type: "enum" },
|
|
1135
|
+
{ key: "page_size_ceiling", value: "1000", type: "integer" },
|
|
1136
|
+
{ key: "provenance_retention_days", value: "30", type: "number" },
|
|
796
1137
|
{ key: "records_tool_default", value: "true", type: "boolean" },
|
|
797
1138
|
{ key: "row_versions_guard", value: "false", type: "boolean" },
|
|
798
1139
|
{ key: "sandbox_expanded_frame_height_px", value: "20000", type: "integer" },
|
|
@@ -809,15 +1150,15 @@ var STORE_REFUSAL_CODES = [
|
|
|
809
1150
|
{ code: "02000", raised_by: "_checklist_instantiate,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_card,portal_declare,portal_invite,portal_preview,portal_principal_bind,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,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_assign,work_record_states,work_set_state" },
|
|
810
1151
|
{ 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" },
|
|
811
1152
|
{ code: "22003", raised_by: "context_resolve" },
|
|
812
|
-
{ code: "22004", raised_by: "_entity_custom_fields_guard,_value_envelope,actor_word,agg_assert_key,agg_sql,anon_capture,anon_token_issue,anon_write,assert_client_may_reach,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_reclass,migrate_split,migrate_undo,organization_clear,organization_contents,portal_declare,portal_invite,portal_principal_bind,query_across_homes,query_by_coordinates,query_rollup,record_delete,record_reparent,record_resolve,record_restore,record_update,record_write,relation_carry,relation_own,rule_declare,share_grant,sign_request_create,sign_request_sign,table_declare,value_restore,work_approval_decide,work_approval_request,work_template_declare" },
|
|
1153
|
+
{ code: "22004", raised_by: "_entity_custom_fields_guard,_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_reclass,migrate_split,migrate_undo,organization_clear,organization_contents,pipeline_declare,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,relation_carry,relation_own,rule_declare,share_grant,sign_request_create,sign_request_sign,subscription_declare,table_declare,value_restore,work_approval_decide,work_approval_request,work_template_declare" },
|
|
813
1154
|
{ code: "22007", raised_by: "dashboard_window_sql" },
|
|
814
1155
|
{ code: "22012", raised_by: "rule_eval" },
|
|
815
|
-
{ code: "22023", raised_by: "_entity_custom_fields_guard,_value_envelope,_work_shape_guard,actor_word,agg_assert_key,agg_sql,anon_token_issue,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,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,migrate_merge,migrate_reclass,my_levels,organization_clear,pin_agent_cells,portal_declare,query_by_coordinates,query_rollup,record_update,relation_carry,rule_eval,rule_members,share_grant,share_lane_set,sign_request_create,sign_request_sign,table_rules,visibility_as_of,work_approval_request,work_list,work_slot_hold" },
|
|
816
|
-
{ code: "23503", raised_by: "_checklist_instantiate,_containment_guard,_field_document_for,_record_rule_uses,anon_publish,anon_rate_take,anon_token_issue,anon_write,assert_organization_wall,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,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,work_set_state,work_take_assignment,work_template_instantiate" },
|
|
1156
|
+
{ code: "22023", raised_by: "_booking_availability,_entity_custom_fields_guard,_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,io_import_begin,io_import_finish,io_import_plan,io_import_report,io_proposal_accept,migrate_merge,migrate_reclass,my_levels,organization_clear,page_size,pin_agent_cells,pipeline_move,portal_declare,provenance_write,query_by_coordinates,query_rollup,record_update,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" },
|
|
1157
|
+
{ code: "23503", raised_by: "_booking_availability,_checklist_instantiate,_containment_guard,_field_document_for,_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,work_set_state,work_take_assignment,work_template_instantiate" },
|
|
817
1158
|
{ code: "23505", raised_by: "_unique_rule_holds,doc_sign,doc_signature_write,entity_field_declare,field_declare,home_add,inbound_declare,io_proposal_accept,relation_carry,relation_own,share_grant,sign_request_cancel,sign_request_create,work_approval_decide,work_slot_hold" },
|
|
818
|
-
{ code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_dated_values_guard,_derived_fields,_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,_resolve_choice_words,_rule_shape_guard,_rule_topology_guard,_store_relation_edge_names_its_field,_table_shape_guard,_value_envelope,_work_shape_guard,_workdoors_approval_guard,assert_entity_is_organization_scoped,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_import_rows,migrate_merge,relation_carry,relation_own,sign_request_create,sign_request_sign,validate_value_envelope,validate_values,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
|
|
1159
|
+
{ code: "23514", raised_by: "_checklist_instantiate,_checklist_step_guard,_containment_guard,_dated_values_guard,_derived_fields,_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,_resolve_choice_words,_rule_shape_guard,_rule_topology_guard,_store_relation_edge_names_its_field,_table_shape_guard,_value_envelope,_work_shape_guard,_workdoors_approval_guard,assert_entity_is_organization_scoped,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_import_rows,migrate_merge,relation_carry,relation_own,sign_request_create,sign_request_sign,validate_value_envelope,validate_values,work_set_state,work_slots_declare,work_take_assignment,work_template_instantiate" },
|
|
819
1160
|
{ code: "40001", raised_by: "has_visibility_at" },
|
|
820
|
-
{ 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_open,assert_client_may_reach,assert_may_know_table,assert_organization_admin,assert_store_door,checklist_run,comment_write,conversation_scope_bind,conversation_scope_unbind,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_reclass,my_levels,organization_clear,portal_declare,portal_invitation,portal_invite,portal_principal_bind,promote_table,query_visibility_parity,read_record,read_records,record_table,share_grant,subscription_mute,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_person" },
|
|
1161
|
+
{ 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_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,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_reclass,my_levels,organization_clear,portal_declare,portal_invitation,portal_invite,portal_principal_bind,promote_table,query_visibility_parity,read_record,read_records,record_table,share_grant,subscription_mute,subscription_preview,visibility_as_of,work_approval_decide,work_approval_read,work_approval_request,work_person" },
|
|
821
1162
|
{ code: "42703", raised_by: "entity_table,portal_declare" },
|
|
822
1163
|
{ code: "53400", raised_by: "anon_rate_take,delete_cascade_closure,enrich_due,enrich_land,promote_field" },
|
|
823
1164
|
{ code: "54001", raised_by: "record_delete" },
|
|
@@ -1434,6 +1775,7 @@ var ENTITY_TOKENS = [
|
|
|
1434
1775
|
"notification_event_override",
|
|
1435
1776
|
"notification_event_type",
|
|
1436
1777
|
"notification_preference",
|
|
1778
|
+
"notification_submission",
|
|
1437
1779
|
"notify_outsider_door_baseline",
|
|
1438
1780
|
"oauth_handoff_claim",
|
|
1439
1781
|
"opinion_clusters",
|