@rox-one/sdk 0.0.0-stage → 0.7.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/CALLS.md +82 -0
- package/README.md +1259 -2
- package/dist/chunk-AOHK5YXC.js +5585 -0
- package/dist/chunk-CATFKTFD.js +80 -0
- package/dist/chunk-FQGPXWPJ.js +1491 -0
- package/dist/chunk-G43PLP2U.js +1087 -0
- package/dist/chunk-LMJW65ML.js +836 -0
- package/dist/chunk-MCSQNZ4E.js +836 -0
- package/dist/chunk-NSJ3GKUC.js +1552 -0
- package/dist/chunk-OGFKJOK7.js +2068 -0
- package/dist/chunk-RDEJZJBZ.js +1351 -0
- package/dist/chunk-TMTYN2UK.js +1128 -0
- package/dist/chunk-V45LUJDI.js +838 -0
- package/dist/chunk-YRUXFEZM.js +1044 -0
- package/dist/chunk-ZYBAKW25.js +994 -0
- package/dist/generated/agent-fold/index.d.ts +4520 -0
- package/dist/generated/agent-fold/index.js +0 -0
- package/dist/generated/agent-harness/client/client.gen.d.ts +2 -0
- package/dist/generated/agent-harness/client/index.d.ts +10 -0
- package/dist/generated/agent-harness/client/types.gen.d.ts +120 -0
- package/dist/generated/agent-harness/client/utils.gen.d.ts +37 -0
- package/dist/generated/agent-harness/client.gen.d.ts +12 -0
- package/dist/generated/agent-harness/core/auth.gen.d.ts +25 -0
- package/dist/generated/agent-harness/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/agent-harness/core/params.gen.d.ts +43 -0
- package/dist/generated/agent-harness/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/agent-harness/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/agent-harness/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/agent-harness/core/types.gen.d.ts +83 -0
- package/dist/generated/agent-harness/core/utils.gen.d.ts +19 -0
- package/dist/generated/agent-harness/index.d.ts +2 -0
- package/dist/generated/agent-harness/index.js +6 -0
- package/dist/generated/agent-harness/sdk.gen.d.ts +375 -0
- package/dist/generated/agent-harness/types.gen.d.ts +4725 -0
- package/dist/generated/agent-reviews/index.d.ts +895 -0
- package/dist/generated/agent-reviews/index.js +0 -0
- package/dist/generated/auth/client/client.gen.d.ts +2 -0
- package/dist/generated/auth/client/index.d.ts +10 -0
- package/dist/generated/auth/client/types.gen.d.ts +120 -0
- package/dist/generated/auth/client/utils.gen.d.ts +37 -0
- package/dist/generated/auth/client.gen.d.ts +12 -0
- package/dist/generated/auth/core/auth.gen.d.ts +25 -0
- package/dist/generated/auth/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/auth/core/params.gen.d.ts +43 -0
- package/dist/generated/auth/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/auth/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/auth/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/auth/core/types.gen.d.ts +83 -0
- package/dist/generated/auth/core/utils.gen.d.ts +19 -0
- package/dist/generated/auth/index.d.ts +2 -0
- package/dist/generated/auth/index.js +6 -0
- package/dist/generated/auth/sdk.gen.d.ts +674 -0
- package/dist/generated/auth/types.gen.d.ts +5233 -0
- package/dist/generated/calendar/client/client.gen.d.ts +2 -0
- package/dist/generated/calendar/client/index.d.ts +10 -0
- package/dist/generated/calendar/client/types.gen.d.ts +120 -0
- package/dist/generated/calendar/client/utils.gen.d.ts +37 -0
- package/dist/generated/calendar/client.gen.d.ts +12 -0
- package/dist/generated/calendar/core/auth.gen.d.ts +25 -0
- package/dist/generated/calendar/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/calendar/core/params.gen.d.ts +43 -0
- package/dist/generated/calendar/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/calendar/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/calendar/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/calendar/core/types.gen.d.ts +83 -0
- package/dist/generated/calendar/core/utils.gen.d.ts +19 -0
- package/dist/generated/calendar/index.d.ts +2 -0
- package/dist/generated/calendar/index.js +6 -0
- package/dist/generated/calendar/sdk.gen.d.ts +157 -0
- package/dist/generated/calendar/types.gen.d.ts +2333 -0
- package/dist/generated/cognition/client/client.gen.d.ts +2 -0
- package/dist/generated/cognition/client/index.d.ts +10 -0
- package/dist/generated/cognition/client/types.gen.d.ts +120 -0
- package/dist/generated/cognition/client/utils.gen.d.ts +37 -0
- package/dist/generated/cognition/client.gen.d.ts +12 -0
- package/dist/generated/cognition/core/auth.gen.d.ts +25 -0
- package/dist/generated/cognition/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/cognition/core/params.gen.d.ts +43 -0
- package/dist/generated/cognition/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/cognition/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/cognition/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/cognition/core/types.gen.d.ts +83 -0
- package/dist/generated/cognition/core/utils.gen.d.ts +19 -0
- package/dist/generated/cognition/index.d.ts +2 -0
- package/dist/generated/cognition/index.js +6 -0
- package/dist/generated/cognition/sdk.gen.d.ts +348 -0
- package/dist/generated/cognition/types.gen.d.ts +4228 -0
- package/dist/generated/connection/client/client.gen.d.ts +2 -0
- package/dist/generated/connection/client/index.d.ts +10 -0
- package/dist/generated/connection/client/types.gen.d.ts +120 -0
- package/dist/generated/connection/client/utils.gen.d.ts +37 -0
- package/dist/generated/connection/client.gen.d.ts +12 -0
- package/dist/generated/connection/core/auth.gen.d.ts +25 -0
- package/dist/generated/connection/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/connection/core/params.gen.d.ts +43 -0
- package/dist/generated/connection/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/connection/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/connection/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/connection/core/types.gen.d.ts +83 -0
- package/dist/generated/connection/core/utils.gen.d.ts +19 -0
- package/dist/generated/connection/index.d.ts +2 -0
- package/dist/generated/connection/index.js +854 -0
- package/dist/generated/connection/sdk.gen.d.ts +43 -0
- package/dist/generated/connection/types.gen.d.ts +252 -0
- package/dist/generated/contacts/client/client.gen.d.ts +2 -0
- package/dist/generated/contacts/client/index.d.ts +10 -0
- package/dist/generated/contacts/client/types.gen.d.ts +120 -0
- package/dist/generated/contacts/client/utils.gen.d.ts +37 -0
- package/dist/generated/contacts/client.gen.d.ts +12 -0
- package/dist/generated/contacts/core/auth.gen.d.ts +25 -0
- package/dist/generated/contacts/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/contacts/core/params.gen.d.ts +43 -0
- package/dist/generated/contacts/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/contacts/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/contacts/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/contacts/core/types.gen.d.ts +83 -0
- package/dist/generated/contacts/core/utils.gen.d.ts +19 -0
- package/dist/generated/contacts/index.d.ts +2 -0
- package/dist/generated/contacts/index.js +6 -0
- package/dist/generated/contacts/sdk.gen.d.ts +47 -0
- package/dist/generated/contacts/types.gen.d.ts +108 -0
- package/dist/generated/email/client/client.gen.d.ts +2 -0
- package/dist/generated/email/client/index.d.ts +10 -0
- package/dist/generated/email/client/types.gen.d.ts +120 -0
- package/dist/generated/email/client/utils.gen.d.ts +37 -0
- package/dist/generated/email/client.gen.d.ts +12 -0
- package/dist/generated/email/core/auth.gen.d.ts +25 -0
- package/dist/generated/email/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/email/core/params.gen.d.ts +43 -0
- package/dist/generated/email/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/email/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/email/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/email/core/types.gen.d.ts +83 -0
- package/dist/generated/email/core/utils.gen.d.ts +19 -0
- package/dist/generated/email/index.d.ts +2 -0
- package/dist/generated/email/index.js +6 -0
- package/dist/generated/email/sdk.gen.d.ts +301 -0
- package/dist/generated/email/types.gen.d.ts +3262 -0
- package/dist/generated/notification/client/client.gen.d.ts +2 -0
- package/dist/generated/notification/client/index.d.ts +10 -0
- package/dist/generated/notification/client/types.gen.d.ts +120 -0
- package/dist/generated/notification/client/utils.gen.d.ts +37 -0
- package/dist/generated/notification/client.gen.d.ts +12 -0
- package/dist/generated/notification/core/auth.gen.d.ts +25 -0
- package/dist/generated/notification/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/notification/core/params.gen.d.ts +43 -0
- package/dist/generated/notification/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/notification/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/notification/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/notification/core/types.gen.d.ts +83 -0
- package/dist/generated/notification/core/utils.gen.d.ts +19 -0
- package/dist/generated/notification/index.d.ts +2 -0
- package/dist/generated/notification/index.js +6 -0
- package/dist/generated/notification/sdk.gen.d.ts +127 -0
- package/dist/generated/notification/types.gen.d.ts +2084 -0
- package/dist/generated/properties/client/client.gen.d.ts +2 -0
- package/dist/generated/properties/client/index.d.ts +10 -0
- package/dist/generated/properties/client/types.gen.d.ts +120 -0
- package/dist/generated/properties/client/utils.gen.d.ts +37 -0
- package/dist/generated/properties/client.gen.d.ts +12 -0
- package/dist/generated/properties/core/auth.gen.d.ts +25 -0
- package/dist/generated/properties/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/properties/core/params.gen.d.ts +43 -0
- package/dist/generated/properties/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/properties/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/properties/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/properties/core/types.gen.d.ts +83 -0
- package/dist/generated/properties/core/utils.gen.d.ts +19 -0
- package/dist/generated/properties/index.d.ts +2 -0
- package/dist/generated/properties/index.js +6 -0
- package/dist/generated/properties/sdk.gen.d.ts +158 -0
- package/dist/generated/properties/types.gen.d.ts +1311 -0
- package/dist/generated/scheduled-action/client/client.gen.d.ts +2 -0
- package/dist/generated/scheduled-action/client/index.d.ts +10 -0
- package/dist/generated/scheduled-action/client/types.gen.d.ts +120 -0
- package/dist/generated/scheduled-action/client/utils.gen.d.ts +37 -0
- package/dist/generated/scheduled-action/client.gen.d.ts +12 -0
- package/dist/generated/scheduled-action/core/auth.gen.d.ts +25 -0
- package/dist/generated/scheduled-action/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/scheduled-action/core/params.gen.d.ts +43 -0
- package/dist/generated/scheduled-action/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/scheduled-action/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/scheduled-action/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/scheduled-action/core/types.gen.d.ts +83 -0
- package/dist/generated/scheduled-action/core/utils.gen.d.ts +19 -0
- package/dist/generated/scheduled-action/index.d.ts +2 -0
- package/dist/generated/scheduled-action/index.js +6 -0
- package/dist/generated/scheduled-action/sdk.gen.d.ts +156 -0
- package/dist/generated/scheduled-action/types.gen.d.ts +3099 -0
- package/dist/generated/search/client/client.gen.d.ts +2 -0
- package/dist/generated/search/client/index.d.ts +10 -0
- package/dist/generated/search/client/types.gen.d.ts +120 -0
- package/dist/generated/search/client/utils.gen.d.ts +37 -0
- package/dist/generated/search/client.gen.d.ts +12 -0
- package/dist/generated/search/core/auth.gen.d.ts +25 -0
- package/dist/generated/search/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/search/core/params.gen.d.ts +43 -0
- package/dist/generated/search/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/search/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/search/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/search/core/types.gen.d.ts +83 -0
- package/dist/generated/search/core/utils.gen.d.ts +19 -0
- package/dist/generated/search/index.d.ts +2 -0
- package/dist/generated/search/index.js +6 -0
- package/dist/generated/search/sdk.gen.d.ts +44 -0
- package/dist/generated/search/types.gen.d.ts +2532 -0
- package/dist/generated/static-files/client/client.gen.d.ts +2 -0
- package/dist/generated/static-files/client/index.d.ts +10 -0
- package/dist/generated/static-files/client/types.gen.d.ts +120 -0
- package/dist/generated/static-files/client/utils.gen.d.ts +37 -0
- package/dist/generated/static-files/client.gen.d.ts +12 -0
- package/dist/generated/static-files/core/auth.gen.d.ts +25 -0
- package/dist/generated/static-files/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/static-files/core/params.gen.d.ts +43 -0
- package/dist/generated/static-files/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/static-files/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/static-files/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/static-files/core/types.gen.d.ts +83 -0
- package/dist/generated/static-files/core/utils.gen.d.ts +19 -0
- package/dist/generated/static-files/index.d.ts +2 -0
- package/dist/generated/static-files/index.js +842 -0
- package/dist/generated/static-files/sdk.gen.d.ts +43 -0
- package/dist/generated/static-files/types.gen.d.ts +220 -0
- package/dist/generated/storage/client/client.gen.d.ts +2 -0
- package/dist/generated/storage/client/index.d.ts +10 -0
- package/dist/generated/storage/client/types.gen.d.ts +120 -0
- package/dist/generated/storage/client/utils.gen.d.ts +37 -0
- package/dist/generated/storage/client.gen.d.ts +12 -0
- package/dist/generated/storage/core/auth.gen.d.ts +25 -0
- package/dist/generated/storage/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/storage/core/params.gen.d.ts +43 -0
- package/dist/generated/storage/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/storage/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/storage/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/storage/core/types.gen.d.ts +83 -0
- package/dist/generated/storage/core/utils.gen.d.ts +19 -0
- package/dist/generated/storage/index.d.ts +2 -0
- package/dist/generated/storage/index.js +6 -0
- package/dist/generated/storage/sdk.gen.d.ts +2285 -0
- package/dist/generated/storage/types.gen.d.ts +34546 -0
- package/dist/generated/unfurl/client/client.gen.d.ts +2 -0
- package/dist/generated/unfurl/client/index.d.ts +10 -0
- package/dist/generated/unfurl/client/types.gen.d.ts +120 -0
- package/dist/generated/unfurl/client/utils.gen.d.ts +37 -0
- package/dist/generated/unfurl/client.gen.d.ts +12 -0
- package/dist/generated/unfurl/core/auth.gen.d.ts +25 -0
- package/dist/generated/unfurl/core/bodySerializer.gen.d.ts +25 -0
- package/dist/generated/unfurl/core/params.gen.d.ts +43 -0
- package/dist/generated/unfurl/core/pathSerializer.gen.d.ts +33 -0
- package/dist/generated/unfurl/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/generated/unfurl/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/generated/unfurl/core/types.gen.d.ts +83 -0
- package/dist/generated/unfurl/core/utils.gen.d.ts +19 -0
- package/dist/generated/unfurl/index.d.ts +2 -0
- package/dist/generated/unfurl/index.js +6 -0
- package/dist/generated/unfurl/sdk.gen.d.ts +47 -0
- package/dist/generated/unfurl/types.gen.d.ts +145 -0
- package/dist/src/calls/browser.d.ts +14 -0
- package/dist/src/calls/browser.js +102 -0
- package/dist/src/calls/common.d.ts +18 -0
- package/dist/src/calls/node.d.ts +24 -0
- package/dist/src/calls/node.js +145 -0
- package/dist/src/calls/telemetry.d.ts +5 -0
- package/dist/src/config.d.ts +71 -0
- package/dist/src/entities/account-managers/grant.d.ts +62 -0
- package/dist/src/entities/account-managers/namespace.d.ts +29 -0
- package/dist/src/entities/activity/entity.d.ts +7 -0
- package/dist/src/entities/activity/namespace.d.ts +58 -0
- package/dist/src/entities/activity/namespace.test.d.ts +1 -0
- package/dist/src/entities/agent-sessions/activity.d.ts +48 -0
- package/dist/src/entities/agent-sessions/agent-session.d.ts +518 -0
- package/dist/src/entities/agent-sessions/code-execution.d.ts +60 -0
- package/dist/src/entities/agent-sessions/conversation.d.ts +91 -0
- package/dist/src/entities/agent-sessions/namespace.d.ts +142 -0
- package/dist/src/entities/agent-sessions/origin.d.ts +94 -0
- package/dist/src/entities/agent-sessions/queued-action.d.ts +60 -0
- package/dist/src/entities/agent-sessions/review.d.ts +114 -0
- package/dist/src/entities/agent-sessions/tool-approval.d.ts +25 -0
- package/dist/src/entities/agent-sessions/view.d.ts +11 -0
- package/dist/src/entities/agents/agent.d.ts +142 -0
- package/dist/src/entities/agents/namespace.d.ts +66 -0
- package/dist/src/entities/ai/namespace.d.ts +36 -0
- package/dist/src/entities/api-keys/api-key.d.ts +22 -0
- package/dist/src/entities/api-keys/namespace.d.ts +37 -0
- package/dist/src/entities/bots/bot.d.ts +143 -0
- package/dist/src/entities/bots/namespace.d.ts +50 -0
- package/dist/src/entities/bots/token.d.ts +39 -0
- package/dist/src/entities/calendar/booking-link.d.ts +55 -0
- package/dist/src/entities/calendar/booking-namespace.d.ts +143 -0
- package/dist/src/entities/calendar/booking-namespace.test.d.ts +1 -0
- package/dist/src/entities/calendar/booking.d.ts +97 -0
- package/dist/src/entities/calendar/calendar.d.ts +49 -0
- package/dist/src/entities/calendar/create-confirmed.test.d.ts +1 -0
- package/dist/src/entities/calendar/event.d.ts +283 -0
- package/dist/src/entities/calendar/event.test.d.ts +1 -0
- package/dist/src/entities/calendar/namespace.d.ts +334 -0
- package/dist/src/entities/calendar/namespace.test.d.ts +1 -0
- package/dist/src/entities/calendar/replacement.d.ts +31 -0
- package/dist/src/entities/calls/call-record.d.ts +231 -0
- package/dist/src/entities/calls/connection.d.ts +59 -0
- package/dist/src/entities/calls/errors.d.ts +15 -0
- package/dist/src/entities/calls/message.d.ts +55 -0
- package/dist/src/entities/calls/namespace.d.ts +41 -0
- package/dist/src/entities/calls/participant.d.ts +22 -0
- package/dist/src/entities/canvases/canvas.d.ts +329 -0
- package/dist/src/entities/channels/access-request.d.ts +42 -0
- package/dist/src/entities/channels/activity.d.ts +40 -0
- package/dist/src/entities/channels/channel.d.ts +302 -0
- package/dist/src/entities/channels/labels.d.ts +73 -0
- package/dist/src/entities/channels/message.d.ts +153 -0
- package/dist/src/entities/channels/message.test.d.ts +1 -0
- package/dist/src/entities/channels/namespace.d.ts +82 -0
- package/dist/src/entities/channels/namespace.test.d.ts +1 -0
- package/dist/src/entities/channels/picture.d.ts +11 -0
- package/dist/src/entities/channels/post.d.ts +37 -0
- package/dist/src/entities/channels/post.test.d.ts +1 -0
- package/dist/src/entities/channels/share.d.ts +9 -0
- package/dist/src/entities/channels/share.test.d.ts +1 -0
- package/dist/src/entities/channels/thread.d.ts +64 -0
- package/dist/src/entities/chats/chat.d.ts +121 -0
- package/dist/src/entities/chats/generation.d.ts +55 -0
- package/dist/src/entities/chats/namespace.d.ts +35 -0
- package/dist/src/entities/connected-apps/connected-app.d.ts +121 -0
- package/dist/src/entities/connected-apps/connector.d.ts +59 -0
- package/dist/src/entities/connected-apps/namespace.d.ts +92 -0
- package/dist/src/entities/crm/company.d.ts +154 -0
- package/dist/src/entities/crm/contact.d.ts +168 -0
- package/dist/src/entities/crm/namespace.d.ts +163 -0
- package/dist/src/entities/crm/pipeline-entry.d.ts +109 -0
- package/dist/src/entities/crm/pipeline.d.ts +426 -0
- package/dist/src/entities/crm/pipelines.d.ts +79 -0
- package/dist/src/entities/crm-email-privacy/email-privacy.d.ts +238 -0
- package/dist/src/entities/crm-email-privacy/email-rule-preview.d.ts +55 -0
- package/dist/src/entities/crm-email-privacy/email-rule-revision.d.ts +27 -0
- package/dist/src/entities/crm-email-privacy/email-rules.d.ts +32 -0
- package/dist/src/entities/databases/column.d.ts +122 -0
- package/dist/src/entities/databases/database.d.ts +431 -0
- package/dist/src/entities/databases/namespace.d.ts +109 -0
- package/dist/src/entities/databases/query.d.ts +86 -0
- package/dist/src/entities/databases/row.d.ts +29 -0
- package/dist/src/entities/databases/saved-query.d.ts +151 -0
- package/dist/src/entities/databases/table.d.ts +124 -0
- package/dist/src/entities/databases/view.d.ts +72 -0
- package/dist/src/entities/databases/webhook.d.ts +39 -0
- package/dist/src/entities/documents/ai-edit.d.ts +54 -0
- package/dist/src/entities/documents/anchor.d.ts +39 -0
- package/dist/src/entities/documents/comment.d.ts +68 -0
- package/dist/src/entities/documents/create.test.d.ts +1 -0
- package/dist/src/entities/documents/document.d.ts +675 -0
- package/dist/src/entities/documents/markdown.d.ts +25 -0
- package/dist/src/entities/documents/namespace.d.ts +291 -0
- package/dist/src/entities/documents/office-files.d.ts +47 -0
- package/dist/src/entities/documents/skills.test.d.ts +1 -0
- package/dist/src/entities/documents/system-skill.d.ts +36 -0
- package/dist/src/entities/documents/text-comment.d.ts +41 -0
- package/dist/src/entities/documents/text-comment.test.d.ts +1 -0
- package/dist/src/entities/documents/version.d.ts +26 -0
- package/dist/src/entities/email/attachment.d.ts +39 -0
- package/dist/src/entities/email/draft.d.ts +160 -0
- package/dist/src/entities/email/filter.d.ts +44 -0
- package/dist/src/entities/email/label.d.ts +37 -0
- package/dist/src/entities/email/link.d.ts +35 -0
- package/dist/src/entities/email/message.d.ts +223 -0
- package/dist/src/entities/email/namespace.d.ts +235 -0
- package/dist/src/entities/email/namespace.test.d.ts +1 -0
- package/dist/src/entities/email/thread.d.ts +268 -0
- package/dist/src/entities/entity-mentions/mention.d.ts +21 -0
- package/dist/src/entities/entity-mentions/namespace.d.ts +20 -0
- package/dist/src/entities/entity.d.ts +167 -0
- package/dist/src/entities/external-chat/chat.d.ts +173 -0
- package/dist/src/entities/external-chat/message.d.ts +54 -0
- package/dist/src/entities/external-chat/namespace.d.ts +22 -0
- package/dist/src/entities/external-chat/participant.d.ts +28 -0
- package/dist/src/entities/external-chat/send.d.ts +40 -0
- package/dist/src/entities/external-chat/upload.d.ts +25 -0
- package/dist/src/entities/favorites/namespace.d.ts +52 -0
- package/dist/src/entities/foreign/foreign-entity.d.ts +36 -0
- package/dist/src/entities/foreign/namespace.d.ts +54 -0
- package/dist/src/entities/forms/form.d.ts +319 -0
- package/dist/src/entities/forms/namespace.d.ts +30 -0
- package/dist/src/entities/forms/question.d.ts +65 -0
- package/dist/src/entities/forms/response.d.ts +52 -0
- package/dist/src/entities/forms/section.d.ts +31 -0
- package/dist/src/entities/github-pull-requests/namespace.d.ts +20 -0
- package/dist/src/entities/github-pull-requests/pull-request.d.ts +64 -0
- package/dist/src/entities/harnesses/harness.d.ts +76 -0
- package/dist/src/entities/harnesses/namespace.d.ts +83 -0
- package/dist/src/entities/harnesses/pairing.d.ts +50 -0
- package/dist/src/entities/images/image.d.ts +88 -0
- package/dist/src/entities/images/namespace.d.ts +55 -0
- package/dist/src/entities/images/namespace.test.d.ts +1 -0
- package/dist/src/entities/imports/entry.d.ts +65 -0
- package/dist/src/entities/imports/namespace.d.ts +103 -0
- package/dist/src/entities/imports/namespace.test.d.ts +1 -0
- package/dist/src/entities/initiatives/initiative.d.ts +185 -0
- package/dist/src/entities/initiatives/initiative.test.d.ts +1 -0
- package/dist/src/entities/initiatives/namespace.d.ts +90 -0
- package/dist/src/entities/me/namespace.d.ts +68 -0
- package/dist/src/entities/meetings/meeting.d.ts +81 -0
- package/dist/src/entities/meetings/namespace.d.ts +38 -0
- package/dist/src/entities/memory/namespace.d.ts +49 -0
- package/dist/src/entities/memory/namespace.test.d.ts +1 -0
- package/dist/src/entities/messages/discussion.d.ts +84 -0
- package/dist/src/entities/messages/thread.d.ts +115 -0
- package/dist/src/entities/notifications/namespace.d.ts +66 -0
- package/dist/src/entities/notifications/notification.d.ts +78 -0
- package/dist/src/entities/notifications/notification.test.d.ts +1 -0
- package/dist/src/entities/passwords/item.d.ts +118 -0
- package/dist/src/entities/passwords/namespace.d.ts +45 -0
- package/dist/src/entities/pins/namespace.d.ts +42 -0
- package/dist/src/entities/projects/namespace.d.ts +45 -0
- package/dist/src/entities/projects/project.d.ts +108 -0
- package/dist/src/entities/properties/namespace.d.ts +105 -0
- package/dist/src/entities/properties/namespace.test.d.ts +1 -0
- package/dist/src/entities/properties/property-definition.d.ts +70 -0
- package/dist/src/entities/properties/property-option.d.ts +44 -0
- package/dist/src/entities/reference.d.ts +82 -0
- package/dist/src/entities/referrals/namespace.d.ts +40 -0
- package/dist/src/entities/routines/namespace.d.ts +239 -0
- package/dist/src/entities/routines/routine.d.ts +341 -0
- package/dist/src/entities/routines/suggestion.d.ts +38 -0
- package/dist/src/entities/saved-views/namespace.d.ts +58 -0
- package/dist/src/entities/saved-views/saved-view.d.ts +78 -0
- package/dist/src/entities/search/exclusions.d.ts +6 -0
- package/dist/src/entities/search/namespace.d.ts +71 -0
- package/dist/src/entities/search/options.d.ts +30 -0
- package/dist/src/entities/search/types.d.ts +90 -0
- package/dist/src/entities/sharing/access.d.ts +120 -0
- package/dist/src/entities/sharing/permissions.d.ts +13 -0
- package/dist/src/entities/spreadsheets/spreadsheet.d.ts +201 -0
- package/dist/src/entities/suggestions/namespace.d.ts +118 -0
- package/dist/src/entities/suggestions/suggestion.d.ts +172 -0
- package/dist/src/entities/suggestions/suggestion.test.d.ts +1 -0
- package/dist/src/entities/tasks/namespace.d.ts +77 -0
- package/dist/src/entities/tasks/task.d.ts +99 -0
- package/dist/src/entities/teams/invite.d.ts +33 -0
- package/dist/src/entities/teams/namespace.d.ts +23 -0
- package/dist/src/entities/teams/team.d.ts +129 -0
- package/dist/src/entities/ui/app-link.d.ts +24 -0
- package/dist/src/entities/ui/namespace.d.ts +75 -0
- package/dist/src/entities/unfurls/namespace.d.ts +24 -0
- package/dist/src/entities/users/namespace.d.ts +41 -0
- package/dist/src/entities/users/profile-picture.d.ts +29 -0
- package/dist/src/entities/users/profile-picture.test.d.ts +1 -0
- package/dist/src/entities/users/user.d.ts +102 -0
- package/dist/src/entities/web/namespace.d.ts +67 -0
- package/dist/src/entities/web/namespace.test.d.ts +1 -0
- package/dist/src/entities/webhooks/namespace.d.ts +38 -0
- package/dist/src/entities/webhooks/webhook.d.ts +130 -0
- package/dist/src/entities/whatsapp/account.d.ts +24 -0
- package/dist/src/entities/whatsapp/chat.d.ts +62 -0
- package/dist/src/entities/whatsapp/namespace.d.ts +29 -0
- package/dist/src/entities/workspace/items.d.ts +14 -0
- package/dist/src/entities/workspace/namespace.d.ts +96 -0
- package/dist/src/entities/workspace/query.d.ts +39 -0
- package/dist/src/entities/workspace/query.test.d.ts +1 -0
- package/dist/src/entities/workspace/types.d.ts +99 -0
- package/dist/src/events/hydrate/agentSession.d.ts +192 -0
- package/dist/src/events/hydrate/call.d.ts +101 -0
- package/dist/src/events/hydrate/channel.d.ts +55 -0
- package/dist/src/events/hydrate/document.d.ts +59 -0
- package/dist/src/events/hydrate/message.d.ts +70 -0
- package/dist/src/events/hydrate/user.d.ts +14 -0
- package/dist/src/events/receiver.d.ts +91 -0
- package/dist/src/events/types.d.ts +44 -0
- package/dist/src/events/verify.d.ts +13 -0
- package/dist/src/local-portmap.d.ts +8 -0
- package/dist/src/mentions.d.ts +42 -0
- package/dist/src/raw.d.ts +12 -0
- package/dist/src/rox.d.ts +267 -0
- package/dist/src/rox.js +23217 -0
- package/dist/src/utils/activity.d.ts +34 -0
- package/dist/src/utils/activity.test.d.ts +1 -0
- package/dist/src/utils/client.d.ts +62 -0
- package/dist/src/utils/concurrency.d.ts +5 -0
- package/dist/src/utils/index.d.ts +5 -0
- package/dist/src/utils/lazy.d.ts +37 -0
- package/dist/src/utils/options.d.ts +7 -0
- package/dist/src/utils/pagination.d.ts +28 -0
- package/dist/src/utils/unwrap.d.ts +48 -0
- package/dist/src/utils/verbs.d.ts +3 -0
- package/package.json +82 -4
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import type { AgentConversationDto, AgentConversationTurnDto } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import { Agent } from '../agents/agent';
|
|
4
|
+
import type { Channel } from '../channels/channel';
|
|
5
|
+
import { Message } from '../channels/message';
|
|
6
|
+
import { AgentSession } from './agent-session';
|
|
7
|
+
/**
|
|
8
|
+
* An agent's conversation in one channel.
|
|
9
|
+
*
|
|
10
|
+
* @mcp-exclude Built from a listing record; no id-only reference an MCP call can pass.
|
|
11
|
+
*/
|
|
12
|
+
export declare class AgentConversation {
|
|
13
|
+
private readonly client;
|
|
14
|
+
/** Parent channel. */
|
|
15
|
+
readonly channel: Channel;
|
|
16
|
+
private readonly record;
|
|
17
|
+
constructor(client: RoxClient,
|
|
18
|
+
/** Parent channel. */
|
|
19
|
+
channel: Channel, record: AgentConversationDto);
|
|
20
|
+
/**
|
|
21
|
+
* The agent taking part.
|
|
22
|
+
*
|
|
23
|
+
* @readonly
|
|
24
|
+
*/
|
|
25
|
+
agent(): Agent;
|
|
26
|
+
/**
|
|
27
|
+
* Conversation sessions with their current flag.
|
|
28
|
+
*
|
|
29
|
+
* @readonly
|
|
30
|
+
*/
|
|
31
|
+
sessions(): {
|
|
32
|
+
session: AgentSession;
|
|
33
|
+
isCurrent: boolean;
|
|
34
|
+
createdAt: string;
|
|
35
|
+
}[];
|
|
36
|
+
/**
|
|
37
|
+
* Recorded conversation turns.
|
|
38
|
+
*
|
|
39
|
+
* @readonly
|
|
40
|
+
*/
|
|
41
|
+
turns(): ConversationTurn[];
|
|
42
|
+
/**
|
|
43
|
+
* Start a fresh conversation from one of its sessions.
|
|
44
|
+
*
|
|
45
|
+
* @write
|
|
46
|
+
*/
|
|
47
|
+
startFresh(session: AgentSession): Promise<void>;
|
|
48
|
+
/** Serialize scoped identity. */
|
|
49
|
+
toJSON(): {
|
|
50
|
+
channelId: string;
|
|
51
|
+
agentId: string;
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* One agent conversation turn, identified by its source message.
|
|
56
|
+
*
|
|
57
|
+
* @mcp-exclude Built from a listing record; no id-only reference an MCP call can pass.
|
|
58
|
+
*/
|
|
59
|
+
export declare class ConversationTurn {
|
|
60
|
+
private readonly client;
|
|
61
|
+
/** Parent conversation. */
|
|
62
|
+
readonly conversation: AgentConversation;
|
|
63
|
+
private readonly record;
|
|
64
|
+
constructor(client: RoxClient,
|
|
65
|
+
/** Parent conversation. */
|
|
66
|
+
conversation: AgentConversation, record: AgentConversationTurnDto);
|
|
67
|
+
/**
|
|
68
|
+
* Originating message.
|
|
69
|
+
*
|
|
70
|
+
* @readonly
|
|
71
|
+
*/
|
|
72
|
+
source(): Message;
|
|
73
|
+
/**
|
|
74
|
+
* Session that handled this turn.
|
|
75
|
+
*
|
|
76
|
+
* @readonly
|
|
77
|
+
*/
|
|
78
|
+
session(): AgentSession;
|
|
79
|
+
/**
|
|
80
|
+
* Retry with a caller persisted action nonce. Never retries automatically.
|
|
81
|
+
*
|
|
82
|
+
* @write
|
|
83
|
+
* @idempotent
|
|
84
|
+
*/
|
|
85
|
+
retry(actionId: string): Promise<void>;
|
|
86
|
+
/** Serialize scoped identity. */
|
|
87
|
+
toJSON(): {
|
|
88
|
+
channelId: string;
|
|
89
|
+
sourceMessageId: string;
|
|
90
|
+
};
|
|
91
|
+
}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
import type { AgentMode, AutoArchivePreferencesBody, CodingPreferencesBody, SandboxSize } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import { AgentSession, type AgentSessionUpdates, type CreateManagedSessionOptions, type RegisteredWork, type SelectableRepository } from './agent-session';
|
|
4
|
+
/**
|
|
5
|
+
* Entry point for coding-agent sessions.
|
|
6
|
+
*
|
|
7
|
+
* @routing Use when work happens in a code repository or with a coding agent: writing code, fixing a bug, opening or changing a pull request, or reading an agent session's history; not changes to Rox databases or documents.
|
|
8
|
+
*
|
|
9
|
+
* @agent
|
|
10
|
+
* ## Starting agent sessions
|
|
11
|
+
*
|
|
12
|
+
* Do repository and coding work yourself when you can. Start another agent session only when the user asks for one, or the work needs a repository runtime you do not have.
|
|
13
|
+
*
|
|
14
|
+
* Start sessions from ExecuteCode. For coding work, macro.agents.coding() lists the coding personas the user can start right now, built-in ones such as Cursor included; for a chat agent, macro.agents.list() lists the user's configurable agents. Choose by name, description and instructions, preferring an agent the user named, and pass its `agent` handle to macro.agentSessions.createManaged. Never invent an agent or construct one by id. To use Macro's default persona instead, omit `agent`. Read AgentSessionNamespace.createManaged with ReadCodeDocs before the first call.
|
|
15
|
+
*
|
|
16
|
+
* ```javascript
|
|
17
|
+
* export async function main({macro}) {
|
|
18
|
+
* const coding = await macro.agents.coding();
|
|
19
|
+
* const chosen = coding.find((option) => option.name === 'Cursor');
|
|
20
|
+
* if (!chosen) return {data: {error: 'Cursor is not connected', available: coding.map((option) => option.name)}};
|
|
21
|
+
* const session = await macro.agentSessions.createManaged({
|
|
22
|
+
* agent: chosen.agent,
|
|
23
|
+
* repoUrl: 'https://github.com/acme/web',
|
|
24
|
+
* prompt: 'Fix the login redirect loop in acme/web. ...',
|
|
25
|
+
* });
|
|
26
|
+
* return {data: {sessionId: session.id}};
|
|
27
|
+
* }
|
|
28
|
+
* ```
|
|
29
|
+
*
|
|
30
|
+
* The prompt must be self-contained: the task, repository, relevant findings and links, constraints, and expected outcome. The new session does not receive this conversation. When the outcome is a pull request, require it to be ready for review, not a draft, with CI passing before the agent finishes. Create once per task and do not retry automatically after an uncertain failure. Link the session in your reply with its id. To check on it later, create a routine; never wait or poll inside an execution.
|
|
31
|
+
*
|
|
32
|
+
* ## Sessions waiting for the user
|
|
33
|
+
*
|
|
34
|
+
* macro.agentSessions.updates() lists the user's sessions waiting on them (permission requests, questions, held tool approvals) or stalled. The user answers them only on cards: in ExecuteCode, whenever it returns items, present them with execution.views.present({widgets: [{type: "agentUpdates", items: updates.items}]}). A session's held tool calls come from session.pendingApprovals(); approve or deny one only when the user said so for that call. session.linkTask(task) links a session the user owns to its Macro task, and the session's pull request with it.
|
|
35
|
+
*/
|
|
36
|
+
export declare class AgentSessionNamespace {
|
|
37
|
+
private readonly client;
|
|
38
|
+
constructor(client: RoxClient);
|
|
39
|
+
/** A handle to an agent session by id. Details load on first access. */
|
|
40
|
+
byId(id: string): AgentSession;
|
|
41
|
+
/**
|
|
42
|
+
* Create a managed session as `agent` when one is named, otherwise the
|
|
43
|
+
* deployment's default persona. Take `agent` from
|
|
44
|
+
* {@link AgentNamespace.coding} (coding personas, Cursor included) or
|
|
45
|
+
* {@link AgentNamespace.list} (configurable agents); never construct one
|
|
46
|
+
* from an id. Unknown or inaccessible personas fail. `model` and `instructions`
|
|
47
|
+
* outrank the persona's. `repoUrl` is honored for Cursor; omit `agent`
|
|
48
|
+
* and it starts as Cursor.
|
|
49
|
+
*
|
|
50
|
+
* @write
|
|
51
|
+
* @openworld
|
|
52
|
+
*/
|
|
53
|
+
createManaged(opts?: CreateManagedSessionOptions): Promise<AgentSession>;
|
|
54
|
+
/**
|
|
55
|
+
* The sessions the caller registered as its work with
|
|
56
|
+
* {@link AgentSession.registerAsWork} and can still view, newest first.
|
|
57
|
+
* Ended registrations and archived sessions are left out.
|
|
58
|
+
*
|
|
59
|
+
* @readonly
|
|
60
|
+
*/
|
|
61
|
+
registeredWork(): Promise<RegisteredWork[]>;
|
|
62
|
+
/**
|
|
63
|
+
* Whether `prompt` needs a chat agent (`'chat'`) or a coding agent
|
|
64
|
+
* (`'code'`), as the app's Auto mode decides before starting a session.
|
|
65
|
+
*
|
|
66
|
+
* @write
|
|
67
|
+
*/
|
|
68
|
+
chooseMode(prompt: string): Promise<AgentMode>;
|
|
69
|
+
/**
|
|
70
|
+
* The GitHub repositories the caller can hand a managed session, with the
|
|
71
|
+
* branch each one's sessions start on by default.
|
|
72
|
+
*
|
|
73
|
+
* @readonly
|
|
74
|
+
* @openworld
|
|
75
|
+
*/
|
|
76
|
+
repositories(): Promise<SelectableRepository[]>;
|
|
77
|
+
/**
|
|
78
|
+
* Branch names on one repository the caller can start a managed session
|
|
79
|
+
* from. `repoUrl` is one of the URLs {@link AgentSessionNamespace.repositories}
|
|
80
|
+
* lists.
|
|
81
|
+
*
|
|
82
|
+
* @readonly
|
|
83
|
+
* @openworld
|
|
84
|
+
*/
|
|
85
|
+
repositoryBranches(repoUrl: string): Promise<string[]>;
|
|
86
|
+
/**
|
|
87
|
+
* List coding sessions awaiting the caller or stalled over 20 minutes.
|
|
88
|
+
*
|
|
89
|
+
* Includes permission requests, questions and held tool approvals to
|
|
90
|
+
* answer, and stalled sessions, newest activity first. Read a session's held approvals
|
|
91
|
+
* with {@link AgentSession.pendingApprovals}.
|
|
92
|
+
*
|
|
93
|
+
* @readonly
|
|
94
|
+
*/
|
|
95
|
+
updates(): Promise<AgentSessionUpdates>;
|
|
96
|
+
/**
|
|
97
|
+
* The sessions linked to the GitHub pull request at `url` that the caller
|
|
98
|
+
* can view.
|
|
99
|
+
*
|
|
100
|
+
* @readonly
|
|
101
|
+
*/
|
|
102
|
+
forPullRequest(url: string): Promise<AgentSession[]>;
|
|
103
|
+
/**
|
|
104
|
+
* The caller's default sandbox size for new `@coder` sessions.
|
|
105
|
+
*
|
|
106
|
+
* @readonly
|
|
107
|
+
*/
|
|
108
|
+
defaultSandboxSize(): Promise<SandboxSize>;
|
|
109
|
+
/**
|
|
110
|
+
* Set the caller's default sandbox size for the next `@coder` mention.
|
|
111
|
+
*
|
|
112
|
+
* @write
|
|
113
|
+
* @idempotent
|
|
114
|
+
*/
|
|
115
|
+
setDefaultSandboxSize(size: SandboxSize): Promise<SandboxSize>;
|
|
116
|
+
/**
|
|
117
|
+
* What the caller's new coding sessions are told to do beyond their assignment.
|
|
118
|
+
*
|
|
119
|
+
* @readonly
|
|
120
|
+
*/
|
|
121
|
+
codingPreferences(): Promise<CodingPreferencesBody>;
|
|
122
|
+
/**
|
|
123
|
+
* Which triggers archive the caller's sessions by default; each is off unless chosen.
|
|
124
|
+
*
|
|
125
|
+
* @readonly
|
|
126
|
+
*/
|
|
127
|
+
autoArchivePreferences(): Promise<AutoArchivePreferencesBody>;
|
|
128
|
+
/**
|
|
129
|
+
* Replace which triggers archive the caller's sessions by default.
|
|
130
|
+
*
|
|
131
|
+
* @write
|
|
132
|
+
* @idempotent
|
|
133
|
+
*/
|
|
134
|
+
setAutoArchivePreferences(preferences: AutoArchivePreferencesBody): Promise<AutoArchivePreferencesBody>;
|
|
135
|
+
/**
|
|
136
|
+
* Replace the caller's coding preferences.
|
|
137
|
+
*
|
|
138
|
+
* @write
|
|
139
|
+
* @idempotent
|
|
140
|
+
*/
|
|
141
|
+
setCodingPreferences(preferences: CodingPreferencesBody): Promise<CodingPreferencesBody>;
|
|
142
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import type { TriggerOrigin } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import { Agent } from '../agents/agent';
|
|
4
|
+
import { Message } from '../channels/message';
|
|
5
|
+
import { Initiative } from '../initiatives/initiative';
|
|
6
|
+
import { Routine } from '../routines/routine';
|
|
7
|
+
import { Task } from '../tasks/task';
|
|
8
|
+
import { User } from '../users/user';
|
|
9
|
+
import { AgentSession } from './agent-session';
|
|
10
|
+
/** The first non-agent cause of an agent's work. */
|
|
11
|
+
export type SessionOriginRoot = {
|
|
12
|
+
type: 'person';
|
|
13
|
+
user: User;
|
|
14
|
+
} | {
|
|
15
|
+
type: 'routine';
|
|
16
|
+
routine: Routine;
|
|
17
|
+
};
|
|
18
|
+
/** Where an acting agent's own work came from. */
|
|
19
|
+
export type SessionOriginLineage = {
|
|
20
|
+
type: 'session';
|
|
21
|
+
/** The session the agent acted from. */
|
|
22
|
+
session: AgentSession;
|
|
23
|
+
/** Where the chain of agents started. */
|
|
24
|
+
root: SessionOriginRoot;
|
|
25
|
+
}
|
|
26
|
+
/** An agent acted, but its session was not captured. */
|
|
27
|
+
| {
|
|
28
|
+
type: 'unattributed';
|
|
29
|
+
};
|
|
30
|
+
/** Who did something that opened a session. */
|
|
31
|
+
export type SessionOriginCaller = {
|
|
32
|
+
type: 'person';
|
|
33
|
+
user: User;
|
|
34
|
+
} | {
|
|
35
|
+
type: 'agent';
|
|
36
|
+
/** The agent that acted. */
|
|
37
|
+
agent: Agent;
|
|
38
|
+
/** The person it acted for. */
|
|
39
|
+
onBehalfOf: User;
|
|
40
|
+
/** Where the agent's own work came from. */
|
|
41
|
+
lineage: SessionOriginLineage;
|
|
42
|
+
};
|
|
43
|
+
/** What opened a session. */
|
|
44
|
+
export type SessionOrigin =
|
|
45
|
+
/** A message mentioned the agent. `message` is set for channel messages. */
|
|
46
|
+
{
|
|
47
|
+
kind: 'mentioned';
|
|
48
|
+
by: SessionOriginCaller;
|
|
49
|
+
message?: Message;
|
|
50
|
+
}
|
|
51
|
+
/** A person wrote in their private conversation with the agent. */
|
|
52
|
+
| {
|
|
53
|
+
kind: 'conversation';
|
|
54
|
+
by: User;
|
|
55
|
+
message?: Message;
|
|
56
|
+
}
|
|
57
|
+
/** The agent was added to a task's assignees. */
|
|
58
|
+
| {
|
|
59
|
+
kind: 'task_assigned';
|
|
60
|
+
by: SessionOriginCaller;
|
|
61
|
+
task: Task;
|
|
62
|
+
}
|
|
63
|
+
/** The task joined a project, and inherited the project's agents. */
|
|
64
|
+
| {
|
|
65
|
+
kind: 'project_inherited';
|
|
66
|
+
by: SessionOriginCaller;
|
|
67
|
+
task: Task;
|
|
68
|
+
project: Initiative;
|
|
69
|
+
}
|
|
70
|
+
/** A person opened the session directly: from the composer, or by asking for a routine draft. */
|
|
71
|
+
| {
|
|
72
|
+
kind: 'requested';
|
|
73
|
+
by: User;
|
|
74
|
+
}
|
|
75
|
+
/** A tool handed the agent work, under this user's authority. */
|
|
76
|
+
| {
|
|
77
|
+
kind: 'dispatched';
|
|
78
|
+
onBehalfOf: User;
|
|
79
|
+
}
|
|
80
|
+
/** A routine fired. */
|
|
81
|
+
| {
|
|
82
|
+
kind: 'routine';
|
|
83
|
+
routine: Routine;
|
|
84
|
+
firing: 'scheduled' | 'manual' | 'event';
|
|
85
|
+
}
|
|
86
|
+
/** Nothing recorded it: an older session, or an unclaimed warm one. */
|
|
87
|
+
| {
|
|
88
|
+
kind: 'unknown';
|
|
89
|
+
};
|
|
90
|
+
/**
|
|
91
|
+
* A session's origin as handles. A message handle needs its channel, which is
|
|
92
|
+
* the session's own thread channel; other parents leave `message` unset.
|
|
93
|
+
*/
|
|
94
|
+
export declare function sessionOrigin(client: RoxClient, origin: TriggerOrigin, channelId: string | undefined): SessionOrigin;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import type { PromptAttachment, QueuedActionDto } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
/**
|
|
4
|
+
* One action waiting in an agent session's server-side queue: a prompt or a
|
|
5
|
+
* compact accepted while a turn was running, dispatching when that turn
|
|
6
|
+
* ends. Until then it can be edited (prompts only), steered, or removed; once
|
|
7
|
+
* it has dispatched, these actions answer 404 — there is no un-sending.
|
|
8
|
+
*
|
|
9
|
+
* List-sourced only - there is no per-action GET, only the queue snapshot -
|
|
10
|
+
* so this wraps whatever DTO the caller already has, the same shape
|
|
11
|
+
* `DiscussionComment` wraps a list-sourced record, rather than `RoxEntity`'s
|
|
12
|
+
* lazy-fetch-by-id.
|
|
13
|
+
*
|
|
14
|
+
* @mcp-exclude Built from a listing record; no id-only reference an MCP call can pass.
|
|
15
|
+
*/
|
|
16
|
+
export declare class QueuedAction {
|
|
17
|
+
private readonly client;
|
|
18
|
+
private readonly sessionId;
|
|
19
|
+
private dto;
|
|
20
|
+
private constructor();
|
|
21
|
+
/** Wrap a queue entry already in hand (e.g. from `AgentSession.queue()`). */
|
|
22
|
+
static from(client: RoxClient, sessionId: string, dto: QueuedActionDto): QueuedAction;
|
|
23
|
+
/**
|
|
24
|
+
* The id the action was accepted under. Once it dispatches, this equals
|
|
25
|
+
* `requestId` on the folded message the action derives.
|
|
26
|
+
*/
|
|
27
|
+
get actionId(): string;
|
|
28
|
+
/** `prompt` or `compact`; only turn-occupying actions are ever queued. */
|
|
29
|
+
get kind(): string;
|
|
30
|
+
/** The prompt's raw text, present for prompts only. What an edit replaces. */
|
|
31
|
+
get prompt(): string | undefined;
|
|
32
|
+
/** Files the prompt refers to; empty for a compact. Kept through an edit. */
|
|
33
|
+
get attachments(): PromptAttachment[];
|
|
34
|
+
/** The user who queued it, absent when a bot acted on nobody's behalf. */
|
|
35
|
+
get actorUserId(): string | undefined;
|
|
36
|
+
/** When the action was accepted, as an RFC 3339 timestamp. */
|
|
37
|
+
get createdAt(): string;
|
|
38
|
+
/**
|
|
39
|
+
* Replace this queued prompt's text before it dispatches. Returns this
|
|
40
|
+
* handle for chaining; the edit endpoint answers 204, so `prompt` is
|
|
41
|
+
* applied locally rather than reread from a response body.
|
|
42
|
+
*
|
|
43
|
+
* @write
|
|
44
|
+
* @idempotent
|
|
45
|
+
*/
|
|
46
|
+
edit(prompt: string): Promise<this>;
|
|
47
|
+
/**
|
|
48
|
+
* Move this action to the front and interrupt the current turn to run it next.
|
|
49
|
+
*
|
|
50
|
+
* @destructive
|
|
51
|
+
*/
|
|
52
|
+
steer(): Promise<void>;
|
|
53
|
+
/**
|
|
54
|
+
* Remove this action from the queue before it dispatches.
|
|
55
|
+
*
|
|
56
|
+
* @destructive
|
|
57
|
+
* @idempotent
|
|
58
|
+
*/
|
|
59
|
+
remove(): Promise<void>;
|
|
60
|
+
}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import type { CreateCalendarEvent_Deserialize, ReviewDraft_Deserialize, ReviewDrafts_Deserialize, ReviewRecord_Serialize, ReviewTitle, SendEmail } from '../../../generated/agent-reviews';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import { RoxEntity } from '../entity';
|
|
4
|
+
import type { AgentSession } from './agent-session';
|
|
5
|
+
import type { CodeExecution } from './code-execution';
|
|
6
|
+
type ReviewRecord = ReviewRecord_Serialize;
|
|
7
|
+
/** A persistent review remains actionable after the code execution ends. */
|
|
8
|
+
export declare class SessionReview extends RoxEntity<ReviewRecord> {
|
|
9
|
+
private readonly parent;
|
|
10
|
+
private constructor();
|
|
11
|
+
static byId(client: RoxClient, session: AgentSession, id: string): SessionReview;
|
|
12
|
+
static fromRecord(client: RoxClient, session: AgentSession, record: ReviewRecord): SessionReview;
|
|
13
|
+
static create(client: RoxClient, execution: CodeExecution, input: CreateReviewOptions): Promise<SessionReview>;
|
|
14
|
+
/** Present a review in a session without requiring a code execution. */
|
|
15
|
+
static createForSession(client: RoxClient, session: AgentSession, input: CreateReviewOptions, execution?: CodeExecution): Promise<SessionReview>;
|
|
16
|
+
static list(client: RoxClient, execution: CodeExecution): Promise<SessionReview[]>;
|
|
17
|
+
protected fetch(): Promise<ReviewRecord>;
|
|
18
|
+
readonly title: () => Promise<string>;
|
|
19
|
+
readonly kind: () => Promise<"calendar" | "email" | "import">;
|
|
20
|
+
/**
|
|
21
|
+
* The session this review belongs to.
|
|
22
|
+
*
|
|
23
|
+
* @readonly
|
|
24
|
+
*/
|
|
25
|
+
session(): AgentSession;
|
|
26
|
+
/**
|
|
27
|
+
* Compact reference for main()'s returned reviews array.
|
|
28
|
+
*
|
|
29
|
+
* @readonly
|
|
30
|
+
*/
|
|
31
|
+
reference(): Promise<{
|
|
32
|
+
kind: ReviewRecord['kind'];
|
|
33
|
+
id: string;
|
|
34
|
+
}>;
|
|
35
|
+
/**
|
|
36
|
+
* The review's items, each with its draft, status and result.
|
|
37
|
+
*
|
|
38
|
+
* @readonly
|
|
39
|
+
*/
|
|
40
|
+
items(): Promise<ReviewItem[]>;
|
|
41
|
+
/**
|
|
42
|
+
* Reload the saved review, for example after a decision or a conflict.
|
|
43
|
+
*
|
|
44
|
+
* @readonly
|
|
45
|
+
*/
|
|
46
|
+
refresh(): Promise<this>;
|
|
47
|
+
/**
|
|
48
|
+
* Submit the saved pending drafts. Never retries a conflict or ambiguous send.
|
|
49
|
+
*
|
|
50
|
+
* @destructive
|
|
51
|
+
* @openworld
|
|
52
|
+
*/
|
|
53
|
+
submitAll(): Promise<void>;
|
|
54
|
+
/**
|
|
55
|
+
* Dismiss every pending draft without sending it.
|
|
56
|
+
*
|
|
57
|
+
* @destructive
|
|
58
|
+
* @idempotent
|
|
59
|
+
*/
|
|
60
|
+
dismissAll(): Promise<void>;
|
|
61
|
+
/** @internal Handles attach the cached revision; callers must refresh after a conflict. */
|
|
62
|
+
private decide;
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* An item handle scopes edits and decisions to its persisted review.
|
|
66
|
+
*
|
|
67
|
+
* @mcp-exclude Built from a listing record; no id-only reference an MCP call can pass.
|
|
68
|
+
*/
|
|
69
|
+
export declare class ReviewItem {
|
|
70
|
+
private readonly snapshot;
|
|
71
|
+
private readonly actions;
|
|
72
|
+
constructor(snapshot: ReviewRecord['items'][number], actions: {
|
|
73
|
+
edit: (draft: ReviewDraft) => Promise<void>;
|
|
74
|
+
submit: () => Promise<void>;
|
|
75
|
+
dismiss: () => Promise<void>;
|
|
76
|
+
});
|
|
77
|
+
get id(): string;
|
|
78
|
+
get status(): ReviewRecord['items'][number]['status'];
|
|
79
|
+
get draft(): ReviewRecord['items'][number]['draft'];
|
|
80
|
+
/** The action's confirmed response, `null` until it completes. */
|
|
81
|
+
get result(): ReviewRecord['items'][number]['result'];
|
|
82
|
+
/**
|
|
83
|
+
* Replace this pending draft; `kind` must match the review's.
|
|
84
|
+
*
|
|
85
|
+
* @write
|
|
86
|
+
* @idempotent
|
|
87
|
+
*/
|
|
88
|
+
edit(draft: ReviewDraft): Promise<void>;
|
|
89
|
+
/**
|
|
90
|
+
* Submit this pending draft, sending the email or creating the event it holds.
|
|
91
|
+
*
|
|
92
|
+
* @destructive
|
|
93
|
+
* @openworld
|
|
94
|
+
*/
|
|
95
|
+
submit(): Promise<void>;
|
|
96
|
+
/**
|
|
97
|
+
* Dismiss this pending draft without sending it.
|
|
98
|
+
*
|
|
99
|
+
* @destructive
|
|
100
|
+
* @idempotent
|
|
101
|
+
*/
|
|
102
|
+
dismiss(): Promise<void>;
|
|
103
|
+
}
|
|
104
|
+
/** A replacement draft keyed by its review's kind. */
|
|
105
|
+
export type ReviewDraft = ReviewDraft_Deserialize;
|
|
106
|
+
/** Markdown is rendered by the ordinary email action; the UI can edit each draft. */
|
|
107
|
+
export type ReviewEmailDraft = SendEmail;
|
|
108
|
+
/** Calendar drafts use the existing calendar composer and creation action. */
|
|
109
|
+
export type ReviewCalendarDraft = CreateCalendarEvent_Deserialize;
|
|
110
|
+
/** A review's kind and its drafts; the execution is attached by the handle. */
|
|
111
|
+
export type CreateReviewOptions = {
|
|
112
|
+
title: ReviewTitle;
|
|
113
|
+
} & ReviewDrafts_Deserialize;
|
|
114
|
+
export {};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import type { AnswerToolApprovalRequest } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import type { AgentSession } from './agent-session';
|
|
4
|
+
/** A permission request scoped to its originating agent session. */
|
|
5
|
+
export declare class ToolApproval {
|
|
6
|
+
private readonly client;
|
|
7
|
+
/** Owning session. */
|
|
8
|
+
readonly session: AgentSession;
|
|
9
|
+
/** Approval identity. */
|
|
10
|
+
readonly id: string;
|
|
11
|
+
private constructor();
|
|
12
|
+
/** Construct a scoped approval handle. */
|
|
13
|
+
static byId(client: RoxClient, session: AgentSession, id: string): ToolApproval;
|
|
14
|
+
/**
|
|
15
|
+
* Answer the approval using the generated discriminated answer contract.
|
|
16
|
+
*
|
|
17
|
+
* @write
|
|
18
|
+
*/
|
|
19
|
+
answer(answer: AnswerToolApprovalRequest['answer']): Promise<import("../../../generated/agent-harness").AnswerToolApprovalResponse>;
|
|
20
|
+
/** Serialize scoped identity only. */
|
|
21
|
+
toJSON(): {
|
|
22
|
+
id: string;
|
|
23
|
+
sessionId: string;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { PresentView } from '../../../generated/agent-harness/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import type { AgentSession } from './agent-session';
|
|
4
|
+
import type { CodeExecution } from './code-execution';
|
|
5
|
+
/** A dynamic-UI view, in the format of the PresentView schema in ExecuteCode's description. */
|
|
6
|
+
export type SessionView = PresentView['view'];
|
|
7
|
+
/**
|
|
8
|
+
* Present a view in a session: a review with nothing saved. The view is
|
|
9
|
+
* checked and drawn at once; one that does not match throws with what to fix.
|
|
10
|
+
*/
|
|
11
|
+
export declare function presentView(client: RoxClient, session: AgentSession, view: SessionView, execution?: CodeExecution): Promise<void>;
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
import type { Agent as AgentRecord, CreateAgentRequest } from '../../../generated/storage/types.gen';
|
|
2
|
+
import type { RoxClient } from '../../utils/client';
|
|
3
|
+
import { Channel } from '../channels/channel';
|
|
4
|
+
import { RoxEntity } from '../entity';
|
|
5
|
+
import { Harness } from '../harnesses/harness';
|
|
6
|
+
import type { Team } from '../teams/team';
|
|
7
|
+
/**
|
|
8
|
+
* The settings {@link Agent.update} changes; each one left out keeps its
|
|
9
|
+
* current value.
|
|
10
|
+
*/
|
|
11
|
+
export type AgentPatch = {
|
|
12
|
+
/** New instructions, whole. */
|
|
13
|
+
instructions?: string;
|
|
14
|
+
/**
|
|
15
|
+
* New runtime: `in-memory`, `cursor`, or `roxd` with the registered
|
|
16
|
+
* `host` that serves it. The current model may not exist on the new
|
|
17
|
+
* runtime, so usually pass `defaultModel` with it.
|
|
18
|
+
*/
|
|
19
|
+
runtime?: {
|
|
20
|
+
harness: string;
|
|
21
|
+
host?: Harness;
|
|
22
|
+
};
|
|
23
|
+
/** New default model, as the runtime names it. */
|
|
24
|
+
defaultModel?: string;
|
|
25
|
+
/** Mentionable in every channel, or only in `channels`. */
|
|
26
|
+
channels?: {
|
|
27
|
+
scope: 'all';
|
|
28
|
+
} | {
|
|
29
|
+
scope: 'selected';
|
|
30
|
+
channels: Channel[];
|
|
31
|
+
};
|
|
32
|
+
/** The connected apps its sessions are handed. */
|
|
33
|
+
apps?: AgentApps;
|
|
34
|
+
/** Approve tool permission requests without asking, where the runtime allows it. */
|
|
35
|
+
autoAcceptPermissions?: boolean;
|
|
36
|
+
/** A coding agent (`true`) or a chat agent (`false`). */
|
|
37
|
+
isCoding?: boolean;
|
|
38
|
+
};
|
|
39
|
+
/** Agent creation and replacement settings. */
|
|
40
|
+
export type AgentOptions = Omit<CreateAgentRequest, 'channel_ids' | 'team_id' | 'harness_id' | 'auto_accept_permissions' | 'avatar_url' | 'channel_scope' | 'default_model' | 'is_coding'> & {
|
|
41
|
+
/** Channels the agent can access. */
|
|
42
|
+
channels?: Channel[];
|
|
43
|
+
/** Owning team. */
|
|
44
|
+
team?: Team;
|
|
45
|
+
/** Host running the agent. */
|
|
46
|
+
host?: Harness;
|
|
47
|
+
/** Whether tool permissions are automatically accepted. */
|
|
48
|
+
autoAcceptPermissions?: boolean;
|
|
49
|
+
/** Avatar URL. */
|
|
50
|
+
avatarUrl?: string;
|
|
51
|
+
/** Channel visibility policy. */
|
|
52
|
+
channelScope: CreateAgentRequest['channel_scope'];
|
|
53
|
+
/** Default model. */
|
|
54
|
+
defaultModel: string;
|
|
55
|
+
/** Whether this is a coding agent. */
|
|
56
|
+
isCoding: boolean;
|
|
57
|
+
};
|
|
58
|
+
/** The connected apps an agent's sessions are handed. */
|
|
59
|
+
export type AgentApps = {
|
|
60
|
+
/** Whatever apps the person running the session has connected. */
|
|
61
|
+
scope: 'owner_connections';
|
|
62
|
+
} | {
|
|
63
|
+
/** Exactly `servers`. */
|
|
64
|
+
scope: 'selected';
|
|
65
|
+
/** The apps, in the order the agent's author picked them. */
|
|
66
|
+
servers: {
|
|
67
|
+
/** Pipedream app slug, e.g. `linear`. */
|
|
68
|
+
appSlug: string;
|
|
69
|
+
/** Display name, e.g. `Linear`. */
|
|
70
|
+
name: string;
|
|
71
|
+
}[];
|
|
72
|
+
};
|
|
73
|
+
/**
|
|
74
|
+
* An agent persona backed by a bot identity. Its settings load from
|
|
75
|
+
* {@link AgentNamespace.list}, so they exist only for configurable agents;
|
|
76
|
+
* built-in personas such as Cursor have none, and are listed with
|
|
77
|
+
* {@link AgentNamespace.coding}.
|
|
78
|
+
*/
|
|
79
|
+
export declare class Agent extends RoxEntity<AgentRecord> {
|
|
80
|
+
/** Construct a lazy agent handle. */
|
|
81
|
+
static byId(client: RoxClient, id: string): Agent;
|
|
82
|
+
/** Seed from a listed or created agent. */
|
|
83
|
+
static from(client: RoxClient, record: AgentRecord): Agent;
|
|
84
|
+
protected fetch(): Promise<AgentRecord>;
|
|
85
|
+
/** Display name. */
|
|
86
|
+
readonly name: () => Promise<string>;
|
|
87
|
+
/** Handle people `@` mention it by. */
|
|
88
|
+
readonly handle: () => Promise<string>;
|
|
89
|
+
/** What the agent is for, when its author said. */
|
|
90
|
+
readonly description: () => Promise<string | undefined>;
|
|
91
|
+
/**
|
|
92
|
+
* Runtime its sessions run on: `in-memory` (Macro), `cursor`,
|
|
93
|
+
* `codex-cloud`, or `roxd` (a registered machine, named by
|
|
94
|
+
* {@link Agent.host}).
|
|
95
|
+
*/
|
|
96
|
+
readonly harness: () => Promise<string>;
|
|
97
|
+
/**
|
|
98
|
+
* Whether it is a coding agent, which works in a repository and answers a
|
|
99
|
+
* mention with a live session, rather than a chat agent replying in the
|
|
100
|
+
* thread.
|
|
101
|
+
*/
|
|
102
|
+
readonly isCoding: () => Promise<boolean>;
|
|
103
|
+
/**
|
|
104
|
+
* Whether its sessions approve tool permission requests without asking,
|
|
105
|
+
* where the runtime allows it.
|
|
106
|
+
*/
|
|
107
|
+
readonly autoAcceptPermissions: () => Promise<NonNullable<boolean | null | undefined>>;
|
|
108
|
+
/** `all`: mentionable everywhere; `selected`: only in {@link Agent.channels}. */
|
|
109
|
+
readonly channelScope: () => Promise<import("../../../generated/storage").AgentChannelScope>;
|
|
110
|
+
/** The connected apps its sessions are handed. */
|
|
111
|
+
readonly apps: () => Promise<AgentApps>;
|
|
112
|
+
/** Agent instructions. */
|
|
113
|
+
readonly instructions: () => Promise<string>;
|
|
114
|
+
/** Default model. */
|
|
115
|
+
readonly defaultModel: () => Promise<string>;
|
|
116
|
+
/** Visible channels. */
|
|
117
|
+
readonly channels: () => Promise<Channel[]>;
|
|
118
|
+
/** Host running this agent. */
|
|
119
|
+
readonly host: () => Promise<Harness | undefined>;
|
|
120
|
+
/**
|
|
121
|
+
* Change only the settings in `patch`; every setting left out keeps its
|
|
122
|
+
* current value. Instructions, channel and app lists are replaced whole:
|
|
123
|
+
* to edit one, apply your change to the current value and pass the result.
|
|
124
|
+
* Changes apply to sessions opened afterwards. Built-in personas cannot be
|
|
125
|
+
* updated.
|
|
126
|
+
*
|
|
127
|
+
* @write
|
|
128
|
+
* @idempotent
|
|
129
|
+
*/
|
|
130
|
+
update(patch: AgentPatch): Promise<void>;
|
|
131
|
+
/**
|
|
132
|
+
* Replace every setting, including the name, handle and owning team:
|
|
133
|
+
* fields left out of `options` return to their defaults. Use
|
|
134
|
+
* {@link Agent.update} to change some settings and keep the rest.
|
|
135
|
+
*
|
|
136
|
+
* @destructive
|
|
137
|
+
* @idempotent
|
|
138
|
+
*/
|
|
139
|
+
replace(options: AgentOptions): Promise<void>;
|
|
140
|
+
}
|
|
141
|
+
/** Convert entity references into the generated agent request. */
|
|
142
|
+
export declare function agentBody(options: AgentOptions): CreateAgentRequest;
|