robotrock 1.3.1 → 1.3.3

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.
Files changed (59) hide show
  1. package/dist/agent-admin.d.ts +2 -1
  2. package/dist/agent-admin.js +44 -0
  3. package/dist/agent-admin.js.map +1 -1
  4. package/dist/ai/index.d.ts +6 -6
  5. package/dist/ai/index.js +34 -2
  6. package/dist/ai/index.js.map +1 -1
  7. package/dist/ai/trigger.d.ts +4 -4
  8. package/dist/ai/trigger.js +34 -2
  9. package/dist/ai/trigger.js.map +1 -1
  10. package/dist/ai/workflow.d.ts +4 -4
  11. package/dist/ai/workflow.js +34 -2
  12. package/dist/ai/workflow.js.map +1 -1
  13. package/dist/{auth-headers-qL-ZeEtd.d.ts → chat-correlation-BsHD-tOQ.d.ts} +6 -1
  14. package/dist/{client-YO9Y1rkH.d.ts → client-CZ5eWH5v.d.ts} +6 -1
  15. package/dist/eve/agent/index.d.ts +69 -6
  16. package/dist/eve/agent/index.js +165 -238
  17. package/dist/eve/agent/index.js.map +1 -1
  18. package/dist/eve/index.d.ts +3 -3
  19. package/dist/eve/index.js +1 -26
  20. package/dist/eve/index.js.map +1 -1
  21. package/dist/eve/tools/admin/assign-tasks.js +44 -0
  22. package/dist/eve/tools/admin/assign-tasks.js.map +1 -1
  23. package/dist/eve/tools/admin/manage-groups.js +44 -0
  24. package/dist/eve/tools/admin/manage-groups.js.map +1 -1
  25. package/dist/eve/tools/admin/manage-team-members.js +44 -0
  26. package/dist/eve/tools/admin/manage-team-members.js.map +1 -1
  27. package/dist/eve/tools/admin/query-tasks.js +44 -0
  28. package/dist/eve/tools/admin/query-tasks.js.map +1 -1
  29. package/dist/eve/tools/identity/index.d.ts +1 -1
  30. package/dist/eve/tools/identity/index.js +2 -0
  31. package/dist/eve/tools/identity/index.js.map +1 -1
  32. package/dist/eve/tools/identity/my-access.js +2 -0
  33. package/dist/eve/tools/identity/my-access.js.map +1 -1
  34. package/dist/eve/tools/identity/whoami.d.ts +1 -1
  35. package/dist/eve/tools/identity/whoami.js +2 -0
  36. package/dist/eve/tools/identity/whoami.js.map +1 -1
  37. package/dist/eve/tools/inbox/create-task.d.ts +1 -1
  38. package/dist/eve/tools/inbox/create-task.js +56 -31
  39. package/dist/eve/tools/inbox/create-task.js.map +1 -1
  40. package/dist/eve/tools/inbox/index.d.ts +1 -1
  41. package/dist/eve/tools/inbox/index.js +56 -31
  42. package/dist/eve/tools/inbox/index.js.map +1 -1
  43. package/dist/eve/tools/index.d.ts +1 -1
  44. package/dist/eve/tools/index.js +68 -31
  45. package/dist/eve/tools/index.js.map +1 -1
  46. package/dist/{index-DoQN48Bm.d.ts → index-DePyAbTI.d.ts} +6 -3
  47. package/dist/index.d.ts +4 -4
  48. package/dist/index.js +26 -2
  49. package/dist/index.js.map +1 -1
  50. package/dist/{tenant-5YKDrdC-.d.ts → tenant-DmN0MMyC.d.ts} +1 -0
  51. package/dist/{tool-approval-bridge-aMA79Z1B.d.ts → tool-approval-bridge-DnGaRES4.d.ts} +1 -1
  52. package/dist/trigger/index.d.ts +2 -2
  53. package/dist/trigger/index.js +26 -2
  54. package/dist/trigger/index.js.map +1 -1
  55. package/dist/{trigger-CXrbKVCL.d.ts → trigger--qTIK0s6.d.ts} +2 -2
  56. package/dist/workflow/index.d.ts +2 -2
  57. package/dist/workflow/index.js +26 -2
  58. package/dist/workflow/index.js.map +1 -1
  59. package/package.json +1 -1
@@ -10,4 +10,9 @@ type RobotRockAuthConfig = {
10
10
  actingUserId?: string;
11
11
  };
12
12
 
13
- export type { RobotRockAuthConfig as R };
13
+ type ChatCorrelation = {
14
+ chatId?: string;
15
+ eveSessionId?: string;
16
+ };
17
+
18
+ export type { ChatCorrelation as C, RobotRockAuthConfig as R };
@@ -1,7 +1,7 @@
1
1
  import { TaskContextInput, AssignToInput, TaskPriority, ThreadUpdateStatus, TaskResponse, Task, ThreadUpdate, TaskContextFormatVersion, DiscriminatedApprovalResult } from './schemas/index.js';
2
2
  import { AgentChatSeedMessage, AgentChatStageHitlBody, AgentChatAuditInputBody, AgentChatAuditToolBody, AgentChatLinkTaskBody, listTasksQuerySchema, AgentAdminTaskSummary } from '@robotrock/core';
3
3
  import { z } from 'zod';
4
- import { R as RobotRockAuthConfig } from './auth-headers-qL-ZeEtd.js';
4
+ import { R as RobotRockAuthConfig, C as ChatCorrelation } from './chat-correlation-BsHD-tOQ.js';
5
5
 
6
6
  /** A chat created via {@link ChatsApi.create}. */
7
7
  type CreatedChat = {
@@ -66,6 +66,7 @@ declare function createChatsApi(config: {
66
66
  baseUrl: string;
67
67
  auth: RobotRockAuthConfig;
68
68
  app?: string;
69
+ chatCorrelation?: ChatCorrelation;
69
70
  }): ChatsApi;
70
71
 
71
72
  type RobotRockWebhookConfig = {
@@ -88,6 +89,8 @@ type RobotRockAdvancedConfig = {
88
89
  contextVersion?: TaskContextFormatVersion;
89
90
  };
90
91
  type RobotRockClientBaseConfig = {
92
+ /** Optional chat correlation headers for audit logging from agent sessions. */
93
+ chatCorrelation?: ChatCorrelation;
91
94
  /** Optional override for API key. Falls back to ROBOTROCK_API_KEY when agentService is unset. */
92
95
  apiKey?: string;
93
96
  /** Hosted-agent service auth (mutually exclusive with apiKey). */
@@ -95,6 +98,7 @@ type RobotRockClientBaseConfig = {
95
98
  token: string;
96
99
  tenantSlug: string;
97
100
  connectionId: string;
101
+ actingUserId?: string;
98
102
  };
99
103
  /**
100
104
  * Base URL for the RobotRock API
@@ -214,6 +218,7 @@ interface TasksApi {
214
218
  */
215
219
  declare class RobotRock {
216
220
  private readonly auth;
221
+ private readonly chatCorrelation?;
217
222
  private readonly baseUrl;
218
223
  private readonly app?;
219
224
  private readonly agentVersion?;
@@ -1,17 +1,17 @@
1
- export { a as TenantCaller, T as TenantRole, i as isAdminCaller, r as requireAdminCaller, b as requireTenantCaller, t as tryResolveTenantCaller } from '../../tenant-5YKDrdC-.js';
1
+ export { a as TenantCaller, T as TenantRole, i as isAdminCaller, r as requireAdminCaller, b as requireTenantCaller, t as tryResolveTenantCaller } from '../../tenant-DmN0MMyC.js';
2
2
  import { AuthFn, vercelOidc } from 'eve/channels/auth';
3
3
  import * as eve_channels_eve from 'eve/channels/eve';
4
- import { R as RobotRock, q as StagedChatHitlRequest, a as SendToHumanInput, S as SendToHumanActionInput, e as CreateChatResult } from '../../client-YO9Y1rkH.js';
4
+ import { R as RobotRock, q as StagedChatHitlRequest, a as SendToHumanInput, S as SendToHumanActionInput, e as CreateChatResult } from '../../client-CZ5eWH5v.js';
5
5
  import { SessionContext } from 'eve/context';
6
6
  import { TaskPriority } from '../../schemas/index.js';
7
7
  import { HookDefinition } from 'eve/hooks';
8
8
  export { AgentAdminApi, createAgentAdminApi, createBoundAgentAdminClient, requireBoundAgentAdminClient } from '../../agent-admin.js';
9
9
  export { ROBOTROCK_PLATFORM_USER_CONTEXT_PUBLIC_KEY_URL } from '@robotrock/core/eve/platform-user-context-public-key';
10
- export { R as ROBOTROCK_READY_HOOK_SLUG } from '../../index-DoQN48Bm.js';
10
+ export { R as ROBOTROCK_READY_HOOK_SLUG } from '../../index-DePyAbTI.js';
11
11
  export { ROBOTROCK_USER_CONTEXT_AUDIENCE, ROBOTROCK_USER_CONTEXT_ISSUER } from '@robotrock/core/eve/user-context-jwt';
12
12
  import '@robotrock/core';
13
13
  import 'zod';
14
- import '../../auth-headers-qL-ZeEtd.js';
14
+ import '../../chat-correlation-BsHD-tOQ.js';
15
15
  import '@robotrock/core/schemas';
16
16
  import '../../tool-reply-guidance-C3qrT1In.js';
17
17
 
@@ -33,9 +33,72 @@ declare function robotrockUserContextAuth(options?: RobotrockUserContextAuthOpti
33
33
  * (`GET /eve/v1/info` during verify and tenant connect).
34
34
  */
35
35
  declare function robotrockAgentServiceAuth(): AuthFn<Request>;
36
- /** Bearer token used by the RobotRock webhook resume self-call. */
36
+ /**
37
+ * Bearer token for RobotRock platform reachability and dashboard proxy calls.
38
+ *
39
+ * When a workspace admin connects a protected single-tenant deployment, they
40
+ * enter a Bearer token in **Settings → Agents**. RobotRock stores it in
41
+ * WorkOS Vault and sends `Authorization: Bearer <token>` on:
42
+ *
43
+ * - `GET /eve/v1/info` and `GET /eve/v1/health` (connect / re-sync)
44
+ * - `POST /eve/v1/session` and `POST /eve/v1/session/:sessionId` (chat + resume)
45
+ * - `GET /eve/v1/session/:sessionId/stream` (chat streaming)
46
+ * - optional icon paths (`/favicon.ico`, `/icon.svg`, `/icon.png`)
47
+ *
48
+ * Set `EVE_SELF_AUTH_TOKEN` on the agent to the same value. Use
49
+ * `robotrockEveChannel()` so this authenticator is registered on the Eve channel.
50
+ */
37
51
  declare function eveSelfServiceAuth(): AuthFn<Request>;
38
52
 
53
+ /**
54
+ * Eve HTTP routes RobotRock reaches when connecting, re-syncing, or proxying
55
+ * dashboard chat. Use these paths when smoke-testing a protected deployment.
56
+ *
57
+ * Self-hosted agents that require deployment access: set `EVE_SELF_AUTH_TOKEN` on
58
+ * the agent to the same value the workspace admin enters under **Settings →
59
+ * Agents → Deployment access → Bearer token**. RobotRock stores that token in
60
+ * WorkOS Vault and sends it as `Authorization: Bearer <token>` on every call
61
+ * below (plus `X-RobotRock-User-Token` during inbox chat).
62
+ */
63
+ /** Routes RobotRock calls directly from the dashboard backend (connect / re-sync). */
64
+ declare const ROBOTROCK_EVE_CONNECT_ROUTES: {
65
+ /** Agent manifest + `robotrock-ready` hook detection. */
66
+ readonly info: {
67
+ readonly method: "GET";
68
+ readonly path: "/eve/v1/info";
69
+ };
70
+ /** Optional health probe (same auth as `/info` when the channel is protected). */
71
+ readonly health: {
72
+ readonly method: "GET";
73
+ readonly path: "/eve/v1/health";
74
+ };
75
+ };
76
+ /** Static assets RobotRock may HEAD/GET for the agent avatar in Settings. */
77
+ declare const ROBOTROCK_EVE_ICON_PATHS: readonly ["/favicon.ico", "/icon.svg", "/icon.png"];
78
+ /**
79
+ * Routes proxied through `/{tenant}/api/eve/{connectionId}/…` during inbox chat
80
+ * and task-handled resume. The Eve client issues these against the proxy host;
81
+ * the proxy forwards them to the deployment with vault credentials attached.
82
+ */
83
+ declare const ROBOTROCK_EVE_CHAT_ROUTES: {
84
+ readonly createSession: {
85
+ readonly method: "POST";
86
+ readonly path: "/eve/v1/session";
87
+ };
88
+ readonly continueSession: {
89
+ readonly method: "POST";
90
+ readonly path: "/eve/v1/session/:sessionId";
91
+ };
92
+ readonly messageStream: {
93
+ readonly method: "GET";
94
+ readonly path: "/eve/v1/session/:sessionId/stream";
95
+ };
96
+ };
97
+ /** Env var on the Eve agent that must match the dashboard Bearer token. */
98
+ declare const EVE_SELF_AUTH_TOKEN_ENV_VAR = "EVE_SELF_AUTH_TOKEN";
99
+ /** All Eve route paths that should accept the dashboard Bearer token on protected deployments. */
100
+ declare const ROBOTROCK_EVE_BEARER_PROTECTED_PATHS: readonly ["/eve/v1/info", "/eve/v1/health", "/eve/v1/session", "/eve/v1/session/:sessionId", "/eve/v1/session/:sessionId/stream", "/favicon.ico", "/icon.svg", "/icon.png"];
101
+
39
102
  /** Resolve the platform RS256 public key used to verify dashboard user-context JWTs. */
40
103
  declare function resolvePlatformUserContextPublicKeyPem(): Promise<string | null>;
41
104
 
@@ -161,4 +224,4 @@ declare const robotrockChatAuditHook: HookDefinition;
161
224
  /** Alias for agents that prefer a factory name. */
162
225
  declare function defineRobotRockChatAuditHook(): HookDefinition;
163
226
 
164
- export { type CreateRobotRockCronChatInput, type CreateRobotRockTaskInput, ROBOTROCK_USER_CONTEXT_HEADER, type RobotRockChatAuditPayload, type RobotRockTaskActionInput, type RobotRockTaskAssignToInput, type RobotRockTaskContextInput, type RobotRockTaskToolInput, type RobotrockEveChannelOptions, type RobotrockUserContextAuthOptions, buildRobotRockTaskPayload, createRobotRockCronChat, createRobotRockTask, defineRobotRockChatAuditHook, defineRobotRockReadyHook, eveSelfServiceAuth, fetchRobotRockStagedHitl, postRobotRockChatInputAudit, postRobotRockLinkChatTask, postRobotRockStageHitl, resetBoundClientAuthWarning, resetChatAuditWarnings, resetRobotrockChatAuditIdempotencyKeys, resolvePlatformUserContextPublicKeyPem, resolveTaskHandledWebhookUrl, robotrockAgentServiceAuth, robotrockChatAuditHook, robotrockEveChannel, robotrockReadyHook, robotrockUserContextAuth, tryCreateBoundRobotRockClient };
227
+ export { type CreateRobotRockCronChatInput, type CreateRobotRockTaskInput, EVE_SELF_AUTH_TOKEN_ENV_VAR, ROBOTROCK_EVE_BEARER_PROTECTED_PATHS, ROBOTROCK_EVE_CHAT_ROUTES, ROBOTROCK_EVE_CONNECT_ROUTES, ROBOTROCK_EVE_ICON_PATHS, ROBOTROCK_USER_CONTEXT_HEADER, type RobotRockChatAuditPayload, type RobotRockTaskActionInput, type RobotRockTaskAssignToInput, type RobotRockTaskContextInput, type RobotRockTaskToolInput, type RobotrockEveChannelOptions, type RobotrockUserContextAuthOptions, buildRobotRockTaskPayload, createRobotRockCronChat, createRobotRockTask, defineRobotRockChatAuditHook, defineRobotRockReadyHook, eveSelfServiceAuth, fetchRobotRockStagedHitl, postRobotRockChatInputAudit, postRobotRockLinkChatTask, postRobotRockStageHitl, resetBoundClientAuthWarning, resetChatAuditWarnings, resetRobotrockChatAuditIdempotencyKeys, resolvePlatformUserContextPublicKeyPem, resolveTaskHandledWebhookUrl, robotrockAgentServiceAuth, robotrockChatAuditHook, robotrockEveChannel, robotrockReadyHook, robotrockUserContextAuth, tryCreateBoundRobotRockClient };