@valon-technologies/gestalt 0.0.1-alpha.20 → 0.0.1-alpha.21

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.
@@ -113,14 +113,6 @@ const AUTHORIZATION_RELAY_TOKEN_HEADER = "x-gestalt-host-service-relay-token";
113
113
 
114
114
  /** Subject type used for canonical Gestalt subject ids in managed grants. */
115
115
  export const AUTHORIZATION_SUBJECT_TYPE_SUBJECT = "subject";
116
- /** Managed authorization resource type for agent sessions. */
117
- export const AGENT_SESSION_RESOURCE_TYPE = "agent_session";
118
- /** Relation that grants view and edit access to an agent session. */
119
- export const AGENT_SESSION_RELATION_EDITOR = "editor";
120
- /** Action checked when reading a shared agent session. */
121
- export const AGENT_SESSION_ACTION_VIEW = "view";
122
- /** Action checked when creating turns or resolving interactions in a session. */
123
- export const AGENT_SESSION_ACTION_EDIT = "edit";
124
116
 
125
117
  export interface AuthorizationSubject {
126
118
  type: string;
@@ -508,20 +500,6 @@ export class AuthorizationClient {
508
500
  await this.client.writeRelationships(authorizationWriteRelationshipsInputToProto(request));
509
501
  }
510
502
 
511
- /**
512
- * Grants a canonical Gestalt subject id editor access to an agent session.
513
- *
514
- * This writes the host-managed `agent_session` relationship through the SDK.
515
- */
516
- async grantAgentSessionEditor(
517
- subjectId: string,
518
- sessionId: string,
519
- ): Promise<void> {
520
- await this.writeRelationships(
521
- agentSessionEditorWriteRequest(subjectId, sessionId),
522
- );
523
- }
524
-
525
503
  async getMetadata(): Promise<AuthorizationMetadata> {
526
504
  return authorizationMetadataFromProto(await this.client.getMetadata({}));
527
505
  }
@@ -920,13 +898,6 @@ export function authorizationSubjectSetTarget(
920
898
  };
921
899
  }
922
900
 
923
- /** Creates the managed authorization resource for an agent session. */
924
- export function agentSessionAuthorizationResource(
925
- sessionId: string,
926
- ): AuthorizationResource {
927
- return authorizationResource(AGENT_SESSION_RESOURCE_TYPE, sessionId);
928
- }
929
-
930
901
  /** Creates an authorization action reference. */
931
902
  export function authorizationAction(
932
903
  name: string,
@@ -959,40 +930,6 @@ export function authorizationRelationshipWithTarget(
959
930
  : { target, relation, resource, properties };
960
931
  }
961
932
 
962
- /**
963
- * Creates the relationship that shares an agent session with a canonical
964
- * Gestalt subject id such as `user:123`.
965
- *
966
- * The returned relationship mirrors the subject into both the legacy `subject`
967
- * field and the generalized `target.subject` field so it remains compatible
968
- * with mixed host/provider versions.
969
- */
970
- export function agentSessionEditorRelationship(
971
- subjectId: string,
972
- sessionId: string,
973
- ): AuthorizationRelationship {
974
- const subject = authorizationSubject(
975
- AUTHORIZATION_SUBJECT_TYPE_SUBJECT,
976
- subjectId,
977
- );
978
- return {
979
- subject,
980
- target: authorizationSubjectTarget(subject),
981
- relation: AGENT_SESSION_RELATION_EDITOR,
982
- resource: agentSessionAuthorizationResource(sessionId),
983
- };
984
- }
985
-
986
- /** Creates a relationship-write request that shares an agent session. */
987
- export function agentSessionEditorWriteRequest(
988
- subjectId: string,
989
- sessionId: string,
990
- ): AuthorizationWriteRelationshipsInput {
991
- return {
992
- writes: [agentSessionEditorRelationship(subjectId, sessionId)],
993
- };
994
- }
995
-
996
933
  /** Creates a relationship key for authorization deletes. */
997
934
  export function authorizationRelationshipKey(
998
935
  subject: AuthorizationSubject,
package/src/index.ts CHANGED
@@ -29,19 +29,12 @@
29
29
  * ```
30
30
  */
31
31
  export {
32
- AGENT_SESSION_ACTION_EDIT,
33
- AGENT_SESSION_ACTION_VIEW,
34
- AGENT_SESSION_RELATION_EDITOR,
35
- AGENT_SESSION_RESOURCE_TYPE,
36
32
  Authorization,
37
33
  AuthorizationClient,
38
34
  AuthorizationProvider,
39
35
  AUTHORIZATION_SUBJECT_TYPE_SUBJECT,
40
36
  ENV_AUTHORIZATION_SOCKET,
41
37
  ENV_AUTHORIZATION_SOCKET_TOKEN,
42
- agentSessionAuthorizationResource,
43
- agentSessionEditorRelationship,
44
- agentSessionEditorWriteRequest,
45
38
  authorizationAction,
46
39
  createAuthorizationProviderService,
47
40
  defineAuthorizationProvider,
@@ -157,17 +150,17 @@ export {
157
150
  ENV_AGENT_MANAGER_SOCKET,
158
151
  ENV_AGENT_MANAGER_SOCKET_TOKEN,
159
152
  AgentManager,
160
- type AgentManagerCancelTurnInput,
161
- type AgentManagerCreateSessionInput,
162
- type AgentManagerCreateTurnInput,
163
- type AgentManagerGetSessionInput,
164
- type AgentManagerGetTurnInput,
165
- type AgentManagerListInteractionsInput,
166
- type AgentManagerListSessionsInput,
167
- type AgentManagerListTurnEventsInput,
168
- type AgentManagerListTurnsInput,
169
- type AgentManagerResolveInteractionInput,
170
- type AgentManagerUpdateSessionInput,
153
+ type AgentManagerCancelTurn,
154
+ type AgentManagerCreateSession,
155
+ type AgentManagerCreateTurn,
156
+ type AgentManagerGetSession,
157
+ type AgentManagerGetTurn,
158
+ type AgentManagerListInteractions,
159
+ type AgentManagerListSessions,
160
+ type AgentManagerListTurnEvents,
161
+ type AgentManagerListTurns,
162
+ type AgentManagerResolveInteraction,
163
+ type AgentManagerUpdateSession,
171
164
  type AgentManagerWorkspace,
172
165
  type AgentManagerWorkspaceGitCheckout,
173
166
  } from "./agent-manager.ts";
@@ -175,26 +168,26 @@ export {
175
168
  ENV_WORKFLOW_MANAGER_SOCKET,
176
169
  ENV_WORKFLOW_MANAGER_SOCKET_TOKEN,
177
170
  WorkflowManager,
178
- type WorkflowManagerCreateDefinitionInput,
179
- type WorkflowManagerCreateTriggerInput,
180
- type WorkflowManagerCreateScheduleInput,
181
- type WorkflowManagerDeleteDefinitionInput,
182
- type WorkflowManagerDeleteTriggerInput,
183
- type WorkflowManagerDeleteScheduleInput,
184
- type WorkflowManagerGetDefinitionInput,
185
- type WorkflowManagerGetTriggerInput,
186
- type WorkflowManagerGetScheduleInput,
187
- type WorkflowManagerPauseTriggerInput,
188
- type WorkflowManagerPauseScheduleInput,
189
- type WorkflowManagerPublishEventInput,
190
- type WorkflowManagerResumeTriggerInput,
191
- type WorkflowManagerResumeScheduleInput,
192
- type WorkflowManagerSignalOrStartRunInput,
193
- type WorkflowManagerSignalRunInput,
194
- type WorkflowManagerStartRunInput,
195
- type WorkflowManagerUpdateDefinitionInput,
196
- type WorkflowManagerUpdateTriggerInput,
197
- type WorkflowManagerUpdateScheduleInput,
171
+ type WorkflowManagerCreateDefinition,
172
+ type WorkflowManagerCreateTrigger,
173
+ type WorkflowManagerCreateSchedule,
174
+ type WorkflowManagerDeleteDefinition,
175
+ type WorkflowManagerDeleteTrigger,
176
+ type WorkflowManagerDeleteSchedule,
177
+ type WorkflowManagerGetDefinition,
178
+ type WorkflowManagerGetTrigger,
179
+ type WorkflowManagerGetSchedule,
180
+ type WorkflowManagerPauseTrigger,
181
+ type WorkflowManagerPauseSchedule,
182
+ type WorkflowManagerPublishEvent,
183
+ type WorkflowManagerResumeTrigger,
184
+ type WorkflowManagerResumeSchedule,
185
+ type WorkflowManagerSignalOrStartRun,
186
+ type WorkflowManagerSignalRun,
187
+ type WorkflowManagerStartRun,
188
+ type WorkflowManagerUpdateDefinition,
189
+ type WorkflowManagerUpdateTrigger,
190
+ type WorkflowManagerUpdateSchedule,
198
191
  } from "./workflow-manager.ts";
199
192
  export {
200
193
  ENV_RUNTIME_LOG_HOST_SOCKET,
@@ -240,8 +233,6 @@ export {
240
233
  export {
241
234
  type ConnectedToken,
242
235
  PluginProvider,
243
- connectionModeToProtoValue,
244
- connectionParamToProto,
245
236
  definePlugin,
246
237
  isPluginProvider,
247
238
  operation,
@@ -347,11 +338,17 @@ export {
347
338
  NotFoundError,
348
339
  AlreadyExistsError,
349
340
  TransactionError,
341
+ IndexedDBCursorSnapshot,
350
342
  ColumnType,
343
+ compareIndexedDBValues,
344
+ indexedDBRangeBounds,
351
345
  indexedDBSocketEnv,
352
346
  indexedDBSocketTokenEnv,
347
+ newIndexedDBCursorSnapshot,
353
348
  type Record,
354
349
  type KeyRange,
350
+ type IndexedDBCursorSnapshotEntry,
351
+ type IndexedDBOpenCursorRequest,
355
352
  type TransactionMode,
356
353
  type TransactionDurabilityHint,
357
354
  type TransactionOptions,
@@ -423,7 +420,6 @@ export {
423
420
  type AgentSessionStartConfig,
424
421
  type AgentSessionStartHook,
425
422
  type AgentSessionStartHookOutput,
426
- type AgentSubjectContext,
427
423
  type AgentToolAnnotations,
428
424
  type AgentToolRef,
429
425
  type AgentTurn,
@@ -493,6 +489,14 @@ export {
493
489
  workflowExecutionReference,
494
490
  workflowExecutionReferenceFromReference,
495
491
  workflowExecutionReferenceInputFromReference,
492
+ workflowAgentStep,
493
+ workflowAgentStepFromProto,
494
+ workflowAgentStepInputFromStep,
495
+ workflowAgentStepToProto,
496
+ workflowAgentStepWhen,
497
+ workflowAgentStepWhenFromProto,
498
+ workflowAgentStepWhenInputFromWhen,
499
+ workflowAgentStepWhenToProto,
496
500
  workflowOutputBinding,
497
501
  workflowOutputBindingInputFromBinding,
498
502
  workflowOutputDelivery,
@@ -509,17 +513,11 @@ export {
509
513
  workflowSignalFromSignal,
510
514
  workflowSignalInputFromSignal,
511
515
  type BoundWorkflowAgentTarget,
512
- type BoundWorkflowAgentTargetInput,
513
516
  type BoundWorkflowEventTrigger,
514
- type BoundWorkflowEventTriggerInput,
515
517
  type BoundWorkflowPluginTarget,
516
- type BoundWorkflowPluginTargetInput,
517
518
  type BoundWorkflowRun,
518
- type BoundWorkflowRunInput,
519
519
  type BoundWorkflowSchedule,
520
- type BoundWorkflowScheduleInput,
521
520
  type BoundWorkflowTarget,
522
- type BoundWorkflowTargetInput,
523
521
  type CancelWorkflowProviderRunRequest,
524
522
  type DeleteWorkflowProviderEventTriggerRequest,
525
523
  type DeleteWorkflowProviderScheduleRequest,
@@ -551,31 +549,21 @@ export {
551
549
  type UpsertWorkflowProviderEventTriggerRequest,
552
550
  type UpsertWorkflowProviderScheduleRequest,
553
551
  type WorkflowAccessPermission,
554
- type WorkflowAccessPermissionInput,
555
552
  type WorkflowActor,
556
- type WorkflowActorInput,
557
553
  type WorkflowEvent,
558
- type WorkflowEventInput,
559
554
  type WorkflowEventMatch,
560
- type WorkflowEventMatchInput,
561
- type WorkflowEventTriggerInvocationInput,
555
+ type WorkflowEventTriggerInvocation,
562
556
  type WorkflowExecutionReference,
563
- type WorkflowExecutionReferenceInput,
557
+ type WorkflowAgentStep,
558
+ type WorkflowAgentStepWhen,
564
559
  type WorkflowOutputBinding,
565
- type WorkflowOutputBindingInput,
566
560
  type WorkflowOutputDelivery,
567
- type WorkflowOutputDeliveryInput,
568
561
  type WorkflowOutputValueSource,
569
- type WorkflowOutputValueSourceInput,
570
562
  type WorkflowProviderOptions,
571
563
  type WorkflowRunAsSubject,
572
- type WorkflowRunAsSubjectInput,
573
- type WorkflowRunTriggerInput,
574
564
  type WorkflowRunTrigger,
575
565
  type WorkflowScheduleTrigger,
576
- type WorkflowScheduleTriggerInput,
577
566
  type WorkflowSignal,
578
- type WorkflowSignalInput,
579
567
  } from "./workflow.ts";
580
568
  export {
581
569
  GENAI_OPERATION_CHAT,