@opencxh/domain 1.172.1 → 1.172.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/entities/activity/blocks.d.ts +30 -30
- package/dist/entities/activity/catalog.d.ts +63 -86
- package/dist/entities/activity/descriptor.d.ts +31 -32
- package/dist/entities/activity/index.d.ts +2 -2
- package/dist/entities/activity/preview.d.ts +7 -7
- package/dist/entities/activity/resolve.d.ts +37 -38
- package/dist/entities/activity/types.d.ts +34 -34
- package/dist/entities/ai-account/types.d.ts +3 -3
- package/dist/entities/ai-account/vendors.d.ts +25 -32
- package/dist/entities/ai-budget/types.d.ts +5 -5
- package/dist/entities/ai-conversation/types.d.ts +12 -12
- package/dist/entities/ai-profile/types.d.ts +14 -21
- package/dist/entities/ai-settings/types.d.ts +12 -13
- package/dist/entities/analytics/index.d.ts +4 -4
- package/dist/entities/analytics/source.d.ts +1 -1
- package/dist/entities/analytics/usage.d.ts +23 -28
- package/dist/entities/artifact/blocks.d.ts +54 -69
- package/dist/entities/artifact/markdown.d.ts +2 -3
- package/dist/entities/artifact/types.d.ts +46 -54
- package/dist/entities/assignment/types.d.ts +74 -88
- package/dist/entities/channel/index.d.ts +1 -1
- package/dist/entities/channel/signature.d.ts +8 -9
- package/dist/entities/communication/index.d.ts +1 -1
- package/dist/entities/contact/index.d.ts +1 -1
- package/dist/entities/custom-field-def/types.d.ts +14 -14
- package/dist/entities/external-identity/types.d.ts +45 -50
- package/dist/entities/interaction/index.d.ts +1 -1
- package/dist/entities/interaction/types.d.ts +44 -47
- package/dist/entities/live-lens/types.d.ts +39 -44
- package/dist/entities/mcp/types.d.ts +53 -57
- package/dist/entities/memory/alias.d.ts +7 -7
- package/dist/entities/memory/browse.d.ts +21 -21
- package/dist/entities/memory/ingest.d.ts +24 -28
- package/dist/entities/memory/item.d.ts +53 -58
- package/dist/entities/memory/kind.d.ts +25 -25
- package/dist/entities/memory/query.d.ts +49 -51
- package/dist/entities/playbook/actor.d.ts +17 -17
- package/dist/entities/playbook/assignment.d.ts +54 -63
- package/dist/entities/playbook/index.d.ts +2 -2
- package/dist/entities/playbook/labels.d.ts +4 -4
- package/dist/entities/playbook/trigger-vars.d.ts +14 -15
- package/dist/entities/playbook/types.d.ts +172 -302
- package/dist/entities/resource-reminder/types.d.ts +8 -9
- package/dist/entities/time-entry/duration.d.ts +11 -11
- package/dist/entities/time-entry/types.d.ts +59 -59
- package/dist/entities/time-entry/work-type.d.ts +21 -24
- package/dist/entities/topic/examples.d.ts +26 -27
- package/dist/entities/topic/scope.d.ts +11 -12
- package/dist/entities/topic/types.d.ts +26 -28
- package/dist/entities/user/types.d.ts +24 -28
- package/dist/entities/webhook/types.d.ts +6 -6
- package/dist/entities/work/keys.d.ts +25 -26
- package/dist/entities/work/ladder.d.ts +48 -52
- package/dist/entities/work/types.d.ts +108 -114
- package/dist/index.cjs +6 -6
- package/dist/index.d.ts +29 -28
- package/dist/index.js +1377 -1242
- package/dist/platform/account.d.ts +34 -38
- package/dist/platform/ai-tools.d.ts +48 -52
- package/dist/platform/api.d.ts +9 -10
- package/dist/platform/author.d.ts +7 -9
- package/dist/platform/capabilities.d.ts +3 -3
- package/dist/platform/communication.d.ts +163 -204
- package/dist/platform/context.d.ts +8 -8
- package/dist/platform/identity.d.ts +16 -19
- package/dist/platform/kernel.d.ts +1 -1
- package/dist/platform/manifest.d.ts +2 -2
- package/dist/platform/media.d.ts +13 -15
- package/dist/platform/permission.d.ts +39 -0
- package/dist/platform/permission.test.d.ts +1 -0
- package/dist/platform/presence.d.ts +30 -30
- package/dist/platform/provider.d.ts +14 -15
- package/dist/platform/resource-source.d.ts +43 -45
- package/dist/platform/resource.d.ts +17 -23
- package/dist/platform/scope.d.ts +35 -61
- package/dist/platform/services.d.ts +4 -4
- package/dist/platform/storage.d.ts +1 -1
- package/dist/platform/sync-source.d.ts +196 -216
- package/dist/platform/transcript-cadence.d.ts +37 -41
- package/dist/platform/ui.d.ts +6 -6
- package/dist/text/endpoint.d.ts +11 -27
- package/package.json +3 -2
|
@@ -1,39 +1,33 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
2
|
+
* What something is **about**: a reference to a resource, independent of which app owns it.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* exporteert hem door, zodat geen enkele bestaande importeur verandert.
|
|
4
|
+
* The platform-wide key shape is `"<kind>:<id>"`: what `authorizeScope` accepts, what
|
|
5
|
+
* `ScopeAuthorizeRequest.scopeKey` carries, and what the file keys are made of. {@link refKey} is
|
|
6
|
+
* the bridge there.
|
|
8
7
|
*
|
|
9
|
-
*
|
|
10
|
-
* `
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* Let op de veldnaam: `type`, terwijl de rest van de codebase `kind` gebruikt voor een
|
|
14
|
-
* discriminant (`OwnerScope.kind`, `ActingIdentity.kind`, `Decider.kind`, `splitScopeKey().kind`).
|
|
15
|
-
* Dat is een inconsistentie van vóór dit type, en hem hier omdopen zou read-state en de
|
|
16
|
-
* resource-reminders meesleuren — een eigen opruiming, niet deze.
|
|
8
|
+
* Mind the field name: `type`, while the rest of the codebase uses `kind` for a discriminant
|
|
9
|
+
* (`OwnerScope.kind`, `ActingIdentity.kind`, `Decider.kind`, `splitScopeKey().kind`). That
|
|
10
|
+
* inconsistency predates this type, and renaming it here would drag read-state and the resource
|
|
11
|
+
* reminders along — a cleanup of its own, not this one.
|
|
17
12
|
*/
|
|
18
13
|
export interface ResourceRef {
|
|
19
|
-
/** `"interaction"`, `"task"`, … —
|
|
14
|
+
/** `"interaction"`, `"task"`, … — the same kinds a scope provider declares. */
|
|
20
15
|
type: string;
|
|
21
16
|
id: string;
|
|
22
17
|
}
|
|
23
|
-
/**
|
|
18
|
+
/** The key shape `authorizeScope` and the file keys use. */
|
|
24
19
|
export declare function refKey(ref: ResourceRef): string;
|
|
25
20
|
/**
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
21
|
+
* The kind comms owns, and the only one the engine knows something extra about: on an interaction
|
|
22
|
+
* you can wait for a reply and put a line in the timeline. Other kinds cannot, and that is not an
|
|
23
|
+
* omission but the difference between a conversation and a task.
|
|
29
24
|
*/
|
|
30
25
|
export declare const INTERACTION_KIND = "interaction";
|
|
31
26
|
/**
|
|
32
|
-
*
|
|
27
|
+
* The interaction id, when this subject is a conversation.
|
|
33
28
|
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
* stilzwijgend een id dat naar het verkeerde soort wijst.
|
|
29
|
+
* Exists so the two things that really need a conversation (`wait-for-reply` and the lifecycle
|
|
30
|
+
* marker) can ask for it without spelling out `type === "interaction"` everywhere — and so a run
|
|
31
|
+
* about a task gets a clean `undefined` instead of silently an id pointing at the wrong kind.
|
|
38
32
|
*/
|
|
39
33
|
export declare function interactionIdOf(subject: ResourceRef | undefined): string | undefined;
|
package/dist/platform/scope.d.ts
CHANGED
|
@@ -6,63 +6,38 @@ export interface ScopeAuth {
|
|
|
6
6
|
shared?: boolean;
|
|
7
7
|
audience?: string[];
|
|
8
8
|
/**
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* Eerste consument is de geheugenlaag: een org-brede geheugensoort wordt bij het schrijven
|
|
19
|
-
* versmald naar `audience` als het bronsubject persoonlijk is, zodat een gesprek uit iemands
|
|
20
|
-
* eigen mailbox niet in de cross-klant-zoekresultaten van een collega opduikt. Afwezig =
|
|
21
|
-
* onbekend, en dat wordt daar als "versmallen" gelezen: de veilige kant.
|
|
9
|
+
* Who owns this resource as the owner app sees it: a personal mailbox, a
|
|
10
|
+
* team inbox, or the organization. Distinct from `shared` (whether an AI
|
|
11
|
+
* conversation on this scope is team-shared) and `audience` (current member
|
|
12
|
+
* list for SSE): this is **ownership** — what a consumer needs to decide
|
|
13
|
+
* whether derived knowledge may travel wider than the resource itself.
|
|
14
|
+
* First consumer is the memory layer: an org-wide memory kind is narrowed
|
|
15
|
+
* to `audience` at write time when the source subject is personal. Absent =
|
|
16
|
+
* unknown, read there as "narrow": the safe side.
|
|
22
17
|
*/
|
|
23
18
|
ownerScope?: OwnerScope;
|
|
24
19
|
/**
|
|
25
|
-
*
|
|
26
|
-
* apps
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
* vastgelegde `contact:<id>` / `company:<id>` / `interaction:<id>`. Twee rollen, één
|
|
37
|
-
* vorm — *identiteit* ("dit ben ik", `Contact.keys`) en *verwijzing* ("hier hoor ik bij",
|
|
38
|
-
* `partyKeys`).
|
|
39
|
-
*
|
|
40
|
-
* **Klein houden.** Dit is de set van de rij zelf, niet zijn hele omgeving: een company
|
|
41
|
-
* geeft zijn eigen sleutels en domeinen, níet die van tweehonderd medewerkers. Die
|
|
42
|
-
* fan-out hoort bij een expliciete zoekvraag (`keySetForCompany`), niet bij elke
|
|
43
|
-
* autorisatie — deze call zit op het hete pad van elke geheugen-schrijfactie.
|
|
44
|
-
*
|
|
45
|
-
* Afwezig = onbekend, en dat wordt gelezen als "alleen het subject zelf": minder
|
|
46
|
-
* vindbaar, nooit ruimer. Dezelfde richting als {@link ScopeAuth.ownerScope}.
|
|
20
|
+
* The **dossier keys** this resource falls under: the canonical keys other
|
|
21
|
+
* apps use to find it in one indexed `$in`. The platform's one convention for
|
|
22
|
+
* relationships — the datastore cannot join or traverse, so each
|
|
23
|
+
* context-bearing row carries its own keys, flattened at **write time**
|
|
24
|
+
* (`Interaction.partyKeys`, `Contact.keys`, `MemoryItem.keys` via this
|
|
25
|
+
* field). Vocabulary is `endpointKey` (`mailto:`, `tel:`, `domain:`) plus
|
|
26
|
+
* `contact:<id>` / `company:<id>` / `interaction:<id>`. Keep it small: the
|
|
27
|
+
* row's own keys, not its whole neighborhood — fan-out belongs to an explicit
|
|
28
|
+
* search (`keySetForCompany`), and this call sits on the hot path of every
|
|
29
|
+
* memory write. Absent = unknown, read as "only the subject itself": less
|
|
30
|
+
* findable, never wider. Same direction as {@link ScopeAuth.ownerScope}.
|
|
47
31
|
*/
|
|
48
32
|
keys?: string[];
|
|
49
33
|
/**
|
|
50
|
-
*
|
|
51
|
-
*
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
*
|
|
58
|
-
* Eerste consument is `apps/work`: werk dat de assistent uit een gesprek aanmaakt hoort
|
|
59
|
-
* bij de behandelaar van dat gesprek te landen, niet op naam van de agent die het
|
|
60
|
-
* aanmaakte. Comms leidde dat vroeger in-process af (`resolveInteractionOwnership`);
|
|
61
|
-
* cross-app is dit hetzelfde antwoord zonder een tweede endpoint, want de aanroeper heeft
|
|
62
|
-
* de interactie en de inbox hier toch al gelezen.
|
|
63
|
-
*
|
|
64
|
-
* Afwezig = onbekend, en dat leest een consument als "val terug op je eigen regels" —
|
|
65
|
-
* nooit als "niemand".
|
|
34
|
+
* Who *handles* this resource, if the owner app knows: the assigned
|
|
35
|
+
* handler's userId. Distinct from {@link ScopeAuth.ownerScope} (ownership) —
|
|
36
|
+
* a team-inbox conversation has `ownerScope.kind === "team"` *and* a
|
|
37
|
+
* concrete handler. First consumer is `apps/work`: work the assistant
|
|
38
|
+
* creates from a conversation must land with that conversation's handler,
|
|
39
|
+
* not under the creating agent's name. Absent = unknown, read by consumers
|
|
40
|
+
* as "fall back to your own rules" — never as "nobody".
|
|
66
41
|
*/
|
|
67
42
|
ownerUserId?: string;
|
|
68
43
|
}
|
|
@@ -70,22 +45,21 @@ export interface ScopeAuth {
|
|
|
70
45
|
export interface ScopeDescribe {
|
|
71
46
|
kinds: string[];
|
|
72
47
|
/**
|
|
73
|
-
*
|
|
74
|
-
*
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
* `
|
|
78
|
-
*
|
|
79
|
-
* weigert daarom een `team`-actor zolang de eigenaar `"team"` niet declareert.
|
|
48
|
+
* Which acting-identity kinds this provider actually evaluates. Absent =
|
|
49
|
+
* only the classic `userId` contract. A fail-closed switch, not
|
|
50
|
+
* documentation: a provider that ignores `actor` sees an empty `userId` for
|
|
51
|
+
* a team actor and would read that as "trusted system caller" — full access.
|
|
52
|
+
* `authorizeIdentity` therefore refuses a `team` actor until the owner
|
|
53
|
+
* declares `"team"`.
|
|
80
54
|
*/
|
|
81
55
|
actorKinds?: ActingIdentity["kind"][];
|
|
82
56
|
}
|
|
83
57
|
/**
|
|
84
58
|
* POST /provider/scope/authorize body.
|
|
85
59
|
*
|
|
86
|
-
* `userId`
|
|
87
|
-
*
|
|
88
|
-
*
|
|
60
|
+
* `userId` stays for back-compat: existing providers read only that field, and
|
|
61
|
+
* a `user` actor fills it so they keep working unchanged. Absent `userId` =
|
|
62
|
+
* trusted system caller (broad!) — see the warning at
|
|
89
63
|
* {@link ScopeDescribe.actorKinds}.
|
|
90
64
|
*/
|
|
91
65
|
export interface ScopeAuthorizeRequest {
|
|
@@ -7,21 +7,21 @@ export type ServiceMap = {
|
|
|
7
7
|
[key: string]: ServiceDefinition;
|
|
8
8
|
};
|
|
9
9
|
export interface GlobalServices extends ServiceMap {
|
|
10
|
-
|
|
10
|
+
"platform:router:push": {
|
|
11
11
|
params: {
|
|
12
12
|
path: string;
|
|
13
13
|
options?: any;
|
|
14
14
|
};
|
|
15
15
|
response: void;
|
|
16
16
|
};
|
|
17
|
-
|
|
17
|
+
"platform:auth:expired": {
|
|
18
18
|
params: {};
|
|
19
19
|
response: void;
|
|
20
20
|
};
|
|
21
|
-
|
|
21
|
+
"platform:ui:toast": {
|
|
22
22
|
params: {
|
|
23
23
|
message: string;
|
|
24
|
-
type:
|
|
24
|
+
type: "success" | "error";
|
|
25
25
|
};
|
|
26
26
|
response: void;
|
|
27
27
|
};
|