@coasys/ad4m 0.13.1-staging.2 → 0.13.1-staging.4
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/lib/index.cjs +610 -208
- package/lib/index.js +607 -209
- package/lib/src/Ad4mClient.d.ts +7 -0
- package/lib/src/Ad4mClient.js +9 -0
- package/lib/src/agent/AgentClient.d.ts +16 -1
- package/lib/src/agent/AgentClient.js +21 -2
- package/lib/src/ai/AITypes.d.ts +6 -2
- package/lib/src/apiClient.d.ts +13 -0
- package/lib/src/apiClient.js +67 -12
- package/lib/src/generated/api/Apps.d.ts +4 -0
- package/lib/src/generated/api/AuthInfo.d.ts +4 -0
- package/lib/src/generated/api/Events.d.ts +10 -12
- package/lib/src/generated/api/FlowStateChangedEvent.d.ts +3 -2
- package/lib/src/generated/api/Model.d.ts +4 -0
- package/lib/src/generated/api/ModelApi.d.ts +5 -1
- package/lib/src/generated/api/ModelApiInput.d.ts +7 -1
- package/lib/src/generated/api/Notification.d.ts +5 -1
- package/lib/src/generated/api/NotificationInput.d.ts +4 -0
- package/lib/src/generated/api/PerspectiveEvent.d.ts +8 -0
- package/lib/src/generated/api/{PerspectiveLinkWithOwner.d.ts → PerspectiveLinkEvent.d.ts} +4 -2
- package/lib/src/generated/api/{PerspectiveLinkUpdatedWithOwner.d.ts → PerspectiveLinkUpdatedEvent.d.ts} +4 -2
- package/lib/src/generated/api/PerspectiveRemovedEvent.d.ts +7 -0
- package/lib/src/generated/api/RequestCapabilityRequest.d.ts +1 -0
- package/lib/src/generated/api/RpcMethods.d.ts +10 -1
- package/lib/src/generated/api/RuntimeInfo.d.ts +5 -0
- package/lib/src/generated/api/RuntimeUpdateNotificationParams.d.ts +6 -1
- package/lib/src/generated/api/UsersRevokeAllSessionsParams.d.ts +7 -0
- package/{src/generated/api/PerspectiveRemovedWithOwner.ts → lib/src/generated/api/UsersRevokeAllSessionsParams.js} +1 -2
- package/lib/src/index.d.ts +1 -0
- package/lib/src/index.js +1 -0
- package/lib/src/model/Ad4mModel.js +45 -18
- package/lib/src/model/ModelQueryBuilder.d.ts +7 -3
- package/lib/src/model/ModelQueryBuilder.js +9 -4
- package/lib/src/model/query-common.js +7 -1
- package/lib/src/model/types.d.ts +45 -2
- package/lib/src/model/types.js +8 -0
- package/lib/src/perspectives/Container.d.ts +41 -0
- package/lib/src/perspectives/Container.js +62 -0
- package/lib/src/perspectives/PerspectiveProxy.d.ts +6 -3
- package/lib/src/perspectives/PerspectiveProxy.js +10 -4
- package/lib/src/perspectives/WakerSubscriptionManager.d.ts +94 -12
- package/lib/src/perspectives/WakerSubscriptionManager.js +276 -75
- package/lib/src/runtime/RuntimeClient.d.ts +6 -3
- package/lib/src/runtime/RuntimeClient.js +2 -0
- package/lib/src/runtime/RuntimeTypes.d.ts +7 -1
- package/package.json +2 -2
- package/src/Ad4mClient.test.ts +54 -19
- package/src/Ad4mClient.ts +10 -0
- package/src/agent/AgentClient.ts +26 -2
- package/src/ai/AITypes.ts +6 -2
- package/src/apiClient.test.ts +128 -3
- package/src/apiClient.ts +64 -11
- package/src/generated/api/Apps.ts +6 -1
- package/src/generated/api/AuthInfo.ts +6 -1
- package/src/generated/api/Events.ts +10 -12
- package/src/generated/api/FlowStateChangedEvent.ts +3 -2
- package/src/generated/api/Model.ts +4 -0
- package/src/generated/api/ModelApi.ts +5 -1
- package/src/generated/api/ModelApiInput.ts +8 -1
- package/src/generated/api/Notification.ts +5 -1
- package/src/generated/api/NotificationInput.ts +6 -1
- package/src/generated/api/PerspectiveEvent.ts +7 -0
- package/src/generated/api/{PerspectiveLinkUpdatedWithOwner.ts → PerspectiveLinkEvent.ts} +4 -1
- package/src/generated/api/PerspectiveLinkUpdatedEvent.ts +7 -0
- package/src/generated/api/PerspectiveRemovedEvent.ts +6 -0
- package/src/generated/api/RequestCapabilityRequest.ts +1 -1
- package/src/generated/api/RpcMethods.ts +4 -1
- package/src/generated/api/RuntimeInfo.ts +6 -1
- package/src/generated/api/RuntimeUpdateNotificationParams.ts +7 -1
- package/src/generated/api/UsersRevokeAllSessionsParams.ts +8 -0
- package/src/index.ts +1 -0
- package/src/model/Ad4mModel.ts +51 -19
- package/src/model/ModelQueryBuilder.ts +9 -6
- package/src/model/containment-scope.test.ts +104 -0
- package/src/model/query-common.ts +10 -1
- package/src/model/types.ts +56 -2
- package/src/perspectives/Container.test.ts +65 -0
- package/src/perspectives/Container.ts +46 -0
- package/src/perspectives/PerspectiveProxy.test.ts +11 -0
- package/src/perspectives/PerspectiveProxy.ts +10 -4
- package/src/perspectives/WakerSubscriptionManager.test.ts +400 -82
- package/src/perspectives/WakerSubscriptionManager.ts +321 -85
- package/src/perspectives/link-updated-type.test.ts +2 -2
- package/src/perspectives/listener-leaks.test.ts +3 -3
- package/src/runtime/RuntimeClient.ts +6 -3
- package/src/runtime/RuntimeTypes.ts +10 -1
- package/lib/src/generated/api/MessageReceivedEvent.d.ts +0 -7
- package/lib/src/generated/api/PerspectiveRemovedWithOwner.d.ts +0 -5
- package/lib/src/generated/api/PerspectiveWithOwner.d.ts +0 -6
- package/lib/src/generated/api/PerspectiveWithOwner.js +0 -1
- package/src/generated/api/MessageReceivedEvent.ts +0 -7
- package/src/generated/api/PerspectiveLinkWithOwner.ts +0 -4
- package/src/generated/api/PerspectiveWithOwner.ts +0 -4
- /package/lib/src/generated/api/{MessageReceivedEvent.js → PerspectiveEvent.js} +0 -0
- /package/lib/src/generated/api/{PerspectiveLinkUpdatedWithOwner.js → PerspectiveLinkEvent.js} +0 -0
- /package/lib/src/generated/api/{PerspectiveLinkWithOwner.js → PerspectiveLinkUpdatedEvent.js} +0 -0
- /package/lib/src/generated/api/{PerspectiveRemovedWithOwner.js → PerspectiveRemovedEvent.js} +0 -0
|
@@ -8,6 +8,8 @@ export class SentMessage {
|
|
|
8
8
|
|
|
9
9
|
export class RuntimeInfo {
|
|
10
10
|
ad4mExecutorVersion: string;
|
|
11
|
+
/** The commit the executor was built from, or null when the build could not tell. */
|
|
12
|
+
ad4mExecutorCommit: string | null;
|
|
11
13
|
isInitialized: Boolean;
|
|
12
14
|
isUnlocked: Boolean;
|
|
13
15
|
}
|
|
@@ -41,6 +43,11 @@ export class NotificationInput {
|
|
|
41
43
|
webhookAuth: string;
|
|
42
44
|
}
|
|
43
45
|
|
|
46
|
+
// What `updateNotification` takes. Without `webhookAuth` the executor keeps the stored
|
|
47
|
+
// credential, and refuses the update if `webhookUrl` changes too: the credential goes only
|
|
48
|
+
// to the webhook it was set for. An empty `webhookAuth` clears it.
|
|
49
|
+
export type NotificationUpdate = Omit<NotificationInput, 'webhookAuth'> & { webhookAuth?: string };
|
|
50
|
+
|
|
44
51
|
export class Notification {
|
|
45
52
|
id: string;
|
|
46
53
|
granted: boolean;
|
|
@@ -51,7 +58,9 @@ export class Notification {
|
|
|
51
58
|
trigger: string;
|
|
52
59
|
perspectiveIds: string[];
|
|
53
60
|
webhookUrl: string;
|
|
54
|
-
|
|
61
|
+
// Whether a webhook credential is set. The executor never returns the credential.
|
|
62
|
+
hasWebhookAuth: boolean;
|
|
63
|
+
ownerDid: string;
|
|
55
64
|
}
|
|
56
65
|
|
|
57
66
|
export class TriggeredNotification {
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
-
import type { PerspectiveExpression } from "./PerspectiveExpression";
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* `message-received`: `{ message }`.
|
|
6
|
-
*/
|
|
7
|
-
export type MessageReceivedEvent = { message: PerspectiveExpression, };
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
-
import type { DecoratedLinkExpression } from "./DecoratedLinkExpression";
|
|
3
|
-
|
|
4
|
-
export type PerspectiveLinkWithOwner = { perspectiveUuid: string, link: DecoratedLinkExpression, owner: string, };
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
|
2
|
-
import type { PerspectiveHandle } from "./PerspectiveHandle";
|
|
3
|
-
|
|
4
|
-
export type PerspectiveWithOwner = { perspectiveUuid: string, perspective: PerspectiveHandle, owner: string, };
|
|
File without changes
|
/package/lib/src/generated/api/{PerspectiveLinkUpdatedWithOwner.js → PerspectiveLinkEvent.js}
RENAMED
|
File without changes
|
/package/lib/src/generated/api/{PerspectiveLinkWithOwner.js → PerspectiveLinkUpdatedEvent.js}
RENAMED
|
File without changes
|
/package/lib/src/generated/api/{PerspectiveRemovedWithOwner.js → PerspectiveRemovedEvent.js}
RENAMED
|
File without changes
|