@vellumai/assistant 0.4.37 → 0.4.41
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/ARCHITECTURE.md +3 -3
- package/README.md +13 -13
- package/bun.lock +80 -24
- package/docs/architecture/integrations.md +126 -128
- package/docs/runbook-trusted-contacts.md +1 -1
- package/docs/trusted-contact-access.md +12 -12
- package/package.json +3 -1
- package/src/__tests__/__snapshots__/ipc-snapshot.test.ts.snap +0 -14
- package/src/__tests__/app-bundler.test.ts +209 -0
- package/src/__tests__/app-compiler.test.ts +279 -0
- package/src/__tests__/app-executors.test.ts +293 -483
- package/src/__tests__/app-migration.test.ts +148 -0
- package/src/__tests__/app-routes-csp.test.ts +202 -0
- package/src/__tests__/avatar-e2e.test.ts +452 -0
- package/src/__tests__/avatar-generator.test.ts +193 -0
- package/src/__tests__/avatar-router.test.ts +186 -0
- package/src/__tests__/browser-download-timeout.test.ts +28 -0
- package/src/__tests__/bundled-skill-retrieval-guard.test.ts +9 -9
- package/src/__tests__/call-domain.test.ts +3 -7
- package/src/__tests__/credential-security-e2e.test.ts +19 -12
- package/src/__tests__/credentials-cli.test.ts +30 -4
- package/src/__tests__/guardian-verify-setup-skill-regression.test.ts +1 -1
- package/src/__tests__/handlers-slack-config.test.ts +0 -72
- package/src/__tests__/handlers-telegram-config.test.ts +19 -12
- package/src/__tests__/handlers-twitter-config.test.ts +105 -48
- package/src/__tests__/inbound-invite-redemption.test.ts +4 -4
- package/src/__tests__/integration-status.test.ts +15 -5
- package/src/__tests__/integrations-cli.test.ts +1 -1
- package/src/__tests__/invite-redemption-service.test.ts +62 -7
- package/src/__tests__/ipc-snapshot.test.ts +0 -8
- package/src/__tests__/managed-avatar-client.test.ts +280 -0
- package/src/__tests__/mcp-cli.test.ts +3 -3
- package/src/__tests__/oauth-cli.test.ts +203 -0
- package/src/__tests__/relay-server.test.ts +3 -3
- package/src/__tests__/secret-onetime-send.test.ts +19 -12
- package/src/__tests__/secure-keys.test.ts +78 -0
- package/src/__tests__/session-messaging-secret-redirect.test.ts +3 -0
- package/src/__tests__/slack-channel-config.test.ts +23 -16
- package/src/__tests__/slack-share-routes.test.ts +263 -0
- package/src/__tests__/sms-messaging-provider.test.ts +3 -1
- package/src/__tests__/trusted-contact-lifecycle-notifications.test.ts +7 -7
- package/src/__tests__/trusted-contact-multichannel.test.ts +3 -3
- package/src/__tests__/trusted-contact-verification.test.ts +10 -10
- package/src/__tests__/twilio-config.test.ts +15 -36
- package/src/__tests__/twilio-provider.test.ts +4 -0
- package/src/__tests__/twitter-auth-handler.test.ts +27 -14
- package/src/__tests__/twitter-cli-error-shaping.test.ts +1 -1
- package/src/__tests__/twitter-cli-routing.test.ts +38 -53
- package/src/__tests__/twitter-oauth-client.test.ts +18 -47
- package/src/__tests__/voice-invite-redemption.test.ts +27 -3
- package/src/amazon/cart.ts +1 -1
- package/src/amazon/client.ts +89 -7
- package/src/approvals/guardian-request-resolvers.ts +2 -2
- package/src/bundler/app-bundler.ts +77 -32
- package/src/bundler/app-compiler.ts +195 -0
- package/src/bundler/manifest.ts +1 -1
- package/src/bundler/package-resolver.ts +185 -0
- package/src/calls/call-domain.ts +4 -14
- package/src/calls/relay-server.ts +2 -2
- package/src/calls/twilio-config.ts +5 -24
- package/src/calls/twilio-rest.ts +19 -5
- package/src/cli/amazon.ts +74 -249
- package/src/cli/audit.ts +2 -2
- package/src/cli/autonomy.ts +9 -9
- package/src/cli/channels.ts +5 -5
- package/src/cli/completions.ts +27 -27
- package/src/cli/config.ts +14 -14
- package/src/cli/contacts.ts +27 -27
- package/src/cli/credentials.ts +28 -28
- package/src/cli/dev.ts +2 -2
- package/src/cli/doctor.ts +2 -2
- package/src/cli/email.ts +82 -82
- package/src/cli/influencer.ts +13 -13
- package/src/cli/integrations.ts +19 -144
- package/src/cli/keys.ts +10 -10
- package/src/cli/map.ts +4 -4
- package/src/cli/mcp.ts +17 -17
- package/src/cli/memory.ts +18 -18
- package/src/cli/notifications.ts +13 -13
- package/src/cli/oauth.ts +77 -0
- package/src/cli/program.ts +2 -0
- package/src/cli/sequence.ts +27 -27
- package/src/cli/sessions.ts +12 -12
- package/src/cli/trust.ts +8 -8
- package/src/cli/twitter.ts +124 -70
- package/src/config/bundled-skills/_shared/CLI_RETRIEVAL_PATTERN.md +1 -1
- package/src/config/bundled-skills/agentmail/SKILL.md +34 -34
- package/src/config/bundled-skills/amazon/SKILL.md +54 -54
- package/src/config/bundled-skills/app-builder/SKILL.md +137 -3
- package/src/config/bundled-skills/app-builder/tools/app-create.ts +10 -4
- package/src/config/bundled-skills/configure-settings/SKILL.md +18 -18
- package/src/config/bundled-skills/contacts/SKILL.md +12 -12
- package/src/config/bundled-skills/doordash/lib/client.ts +7 -9
- package/src/config/bundled-skills/email-setup/SKILL.md +4 -4
- package/src/config/bundled-skills/frontend-design/icon.svg +16 -0
- package/src/config/bundled-skills/google-oauth-setup/SKILL.md +143 -162
- package/src/config/bundled-skills/guardian-verify-setup/SKILL.md +4 -4
- package/src/config/bundled-skills/influencer/SKILL.md +13 -13
- package/src/config/bundled-skills/mcp-setup/SKILL.md +11 -11
- package/src/config/bundled-skills/phone-calls/SKILL.md +48 -54
- package/src/config/bundled-skills/public-ingress/SKILL.md +6 -6
- package/src/config/bundled-skills/slack-app-setup/SKILL.md +1 -1
- package/src/config/bundled-skills/sms-setup/SKILL.md +3 -3
- package/src/config/bundled-skills/telegram-setup/SKILL.md +2 -2
- package/src/config/bundled-skills/twilio-setup/SKILL.md +136 -225
- package/src/config/bundled-skills/twitter/SKILL.md +68 -44
- package/src/config/bundled-skills/voice-setup/SKILL.md +2 -2
- package/src/config/core-schema.ts +26 -0
- package/src/config/env.ts +4 -0
- package/src/config/feature-flag-registry.json +9 -1
- package/src/config/schema.ts +8 -0
- package/src/config/system-prompt.ts +6 -3
- package/src/config/templates/BOOTSTRAP.md +7 -5
- package/src/contacts/contacts-write.ts +5 -1
- package/src/daemon/handlers/apps.ts +31 -4
- package/src/daemon/handlers/config-ingress.ts +3 -3
- package/src/daemon/handlers/config-integrations.ts +120 -49
- package/src/daemon/handlers/config-slack-channel.ts +26 -7
- package/src/daemon/handlers/config-slack.ts +1 -54
- package/src/daemon/handlers/config-telegram.ts +28 -10
- package/src/daemon/handlers/config.ts +1 -4
- package/src/daemon/handlers/twitter-auth.ts +11 -4
- package/src/daemon/ipc-contract/apps.ts +0 -13
- package/src/daemon/ipc-contract-inventory.json +0 -2
- package/src/daemon/lifecycle.ts +8 -1
- package/src/daemon/session-messaging.ts +2 -2
- package/src/daemon/tool-side-effects.ts +30 -0
- package/src/email/providers/agentmail.ts +1 -1
- package/src/email/providers/index.ts +1 -1
- package/src/email/service.ts +1 -1
- package/src/gallery/default-gallery.ts +538 -0
- package/src/gallery/gallery-manifest.ts +5 -1
- package/src/influencer/client.ts +8 -6
- package/src/mcp/client.ts +1 -1
- package/src/media/avatar-router.ts +99 -0
- package/src/media/avatar-types.ts +60 -0
- package/src/media/managed-avatar-client.ts +189 -0
- package/src/memory/app-migration.ts +114 -0
- package/src/memory/app-store.ts +11 -0
- package/src/memory/qdrant-client.ts +1 -1
- package/src/messaging/providers/slack/client.ts +12 -2
- package/src/messaging/providers/sms/adapter.ts +6 -10
- package/src/migrations/data-layout.ts +8 -1
- package/src/oauth/token-persistence.ts +9 -6
- package/src/runtime/assistant-scope.ts +5 -0
- package/src/runtime/auth/route-policy.ts +4 -0
- package/src/runtime/channel-readiness-service.ts +9 -4
- package/src/runtime/gateway-internal-client.ts +11 -3
- package/src/runtime/http-server.ts +2 -0
- package/src/runtime/invite-redemption-service.ts +23 -13
- package/src/runtime/middleware/twilio-validation.ts +2 -2
- package/src/runtime/routes/app-routes.ts +131 -3
- package/src/runtime/routes/inbound-stages/verification-intercept.ts +3 -3
- package/src/runtime/routes/integration-routes.ts +2 -2
- package/src/runtime/routes/slack-share-routes.ts +235 -0
- package/src/runtime/routes/twilio-routes.ts +47 -34
- package/src/schedule/integration-status.ts +2 -3
- package/src/security/token-manager.ts +11 -3
- package/src/tools/apps/executors.ts +116 -8
- package/src/tools/browser/browser-manager.ts +30 -2
- package/src/tools/browser/chrome-cdp.ts +31 -3
- package/src/tools/credentials/vault.ts +9 -7
- package/src/tools/executor.ts +4 -0
- package/src/tools/system/avatar-generator.ts +55 -34
- package/src/twitter/client.ts +1 -1
- package/src/twitter/oauth-client.ts +31 -43
- package/src/twitter/router.ts +25 -23
- package/src/util/platform.ts +5 -0
- package/src/slack/slack-webhook.ts +0 -66
package/src/cli/sequence.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* CLI command group: `
|
|
2
|
+
* CLI command group: `assistant sequence`
|
|
3
3
|
*
|
|
4
4
|
* Manage email sequences — list, inspect, pause, resume, and view stats.
|
|
5
5
|
*/
|
|
@@ -81,10 +81,10 @@ Guardrails enforce rate limits, daily send caps, cooldown periods, and
|
|
|
81
81
|
duplicate enrollment checks to prevent abuse.
|
|
82
82
|
|
|
83
83
|
Examples:
|
|
84
|
-
$
|
|
85
|
-
$
|
|
86
|
-
$
|
|
87
|
-
$
|
|
84
|
+
$ assistant sequence list --status active
|
|
85
|
+
$ assistant sequence get seq_abc123
|
|
86
|
+
$ assistant sequence pause seq_abc123
|
|
87
|
+
$ assistant sequence stats`,
|
|
88
88
|
);
|
|
89
89
|
|
|
90
90
|
// ── list ──────────────────────────────────────────────────────────
|
|
@@ -102,9 +102,9 @@ and active enrollment count.
|
|
|
102
102
|
If omitted, returns all sequences regardless of status.
|
|
103
103
|
|
|
104
104
|
Examples:
|
|
105
|
-
$
|
|
106
|
-
$
|
|
107
|
-
$
|
|
105
|
+
$ assistant sequence list
|
|
106
|
+
$ assistant sequence list --status active
|
|
107
|
+
$ assistant sequence list --status paused --json`,
|
|
108
108
|
)
|
|
109
109
|
.action((opts: { status?: string }, cmd: Command) => {
|
|
110
110
|
initializeDb();
|
|
@@ -149,8 +149,8 @@ setting, all steps with delay and approval configuration, and enrollment
|
|
|
149
149
|
breakdown by status (active, paused, completed, replied, cancelled, failed).
|
|
150
150
|
|
|
151
151
|
Examples:
|
|
152
|
-
$
|
|
153
|
-
$
|
|
152
|
+
$ assistant sequence get seq_abc123
|
|
153
|
+
$ assistant sequence get seq_abc123 --json`,
|
|
154
154
|
)
|
|
155
155
|
.action((id: string, _opts: Record<string, unknown>, cmd: Command) => {
|
|
156
156
|
initializeDb();
|
|
@@ -222,8 +222,8 @@ enrollments remain in their current state but no new steps will be sent
|
|
|
222
222
|
until the sequence is resumed. No-op if the sequence is already paused.
|
|
223
223
|
|
|
224
224
|
Examples:
|
|
225
|
-
$
|
|
226
|
-
$
|
|
225
|
+
$ assistant sequence pause seq_abc123
|
|
226
|
+
$ assistant sequence pause seq_abc123 --json`,
|
|
227
227
|
)
|
|
228
228
|
.action((id: string, _opts: Record<string, unknown>, cmd: Command) => {
|
|
229
229
|
initializeDb();
|
|
@@ -252,8 +252,8 @@ Resumes a paused sequence, re-enabling scheduled step deliveries for all
|
|
|
252
252
|
active enrollments. No-op if the sequence is already active.
|
|
253
253
|
|
|
254
254
|
Examples:
|
|
255
|
-
$
|
|
256
|
-
$
|
|
255
|
+
$ assistant sequence resume seq_abc123
|
|
256
|
+
$ assistant sequence resume seq_abc123 --json`,
|
|
257
257
|
)
|
|
258
258
|
.action((id: string, _opts: Record<string, unknown>, cmd: Command) => {
|
|
259
259
|
initializeDb();
|
|
@@ -284,8 +284,8 @@ changes to "cancelled". This does not affect the sequence itself or
|
|
|
284
284
|
other enrollments.
|
|
285
285
|
|
|
286
286
|
Examples:
|
|
287
|
-
$
|
|
288
|
-
$
|
|
287
|
+
$ assistant sequence cancel-enrollment enr_xyz789
|
|
288
|
+
$ assistant sequence cancel-enrollment enr_xyz789 --json`,
|
|
289
289
|
)
|
|
290
290
|
.action(
|
|
291
291
|
(enrollmentId: string, _opts: Record<string, unknown>, cmd: Command) => {
|
|
@@ -310,8 +310,8 @@ Returns aggregate statistics across all sequences: total and active
|
|
|
310
310
|
sequence counts, total and active enrollment counts.
|
|
311
311
|
|
|
312
312
|
Examples:
|
|
313
|
-
$
|
|
314
|
-
$
|
|
313
|
+
$ assistant sequence stats
|
|
314
|
+
$ assistant sequence stats --json`,
|
|
315
315
|
)
|
|
316
316
|
.action((_opts: Record<string, unknown>, cmd: Command) => {
|
|
317
317
|
initializeDb();
|
|
@@ -358,9 +358,9 @@ hourly rate limits, minimum delays between steps, maximum concurrent active
|
|
|
358
358
|
enrollments, duplicate enrollment prevention, and cooldown periods.
|
|
359
359
|
|
|
360
360
|
Examples:
|
|
361
|
-
$
|
|
362
|
-
$
|
|
363
|
-
$
|
|
361
|
+
$ assistant sequence guardrails show
|
|
362
|
+
$ assistant sequence guardrails set dailySendCap 200
|
|
363
|
+
$ assistant sequence guardrails set cooldown_days 7`,
|
|
364
364
|
);
|
|
365
365
|
|
|
366
366
|
guardrailsCmd
|
|
@@ -379,8 +379,8 @@ Displays the current guardrail configuration with all safety limits:
|
|
|
379
379
|
Cooldown period Time before a contact can be re-enrolled after completion
|
|
380
380
|
|
|
381
381
|
Examples:
|
|
382
|
-
$
|
|
383
|
-
$
|
|
382
|
+
$ assistant sequence guardrails show
|
|
383
|
+
$ assistant sequence guardrails show --json`,
|
|
384
384
|
)
|
|
385
385
|
.action((_opts: Record<string, unknown>, cmd: Command) => {
|
|
386
386
|
const json = getJson(cmd);
|
|
@@ -428,10 +428,10 @@ Valid keys:
|
|
|
428
428
|
cooldown_days Cooldown period in days (converted to ms internally) (numeric)
|
|
429
429
|
|
|
430
430
|
Examples:
|
|
431
|
-
$
|
|
432
|
-
$
|
|
433
|
-
$
|
|
434
|
-
$
|
|
431
|
+
$ assistant sequence guardrails set dailySendCap 200
|
|
432
|
+
$ assistant sequence guardrails set hourly_rate 50
|
|
433
|
+
$ assistant sequence guardrails set duplicate_check true
|
|
434
|
+
$ assistant sequence guardrails set cooldown_days 7`,
|
|
435
435
|
)
|
|
436
436
|
.action(
|
|
437
437
|
(
|
package/src/cli/sessions.ts
CHANGED
|
@@ -31,10 +31,10 @@ communicate via IPC), while "export" and "clear" operate on the local SQLite
|
|
|
31
31
|
database directly.
|
|
32
32
|
|
|
33
33
|
Examples:
|
|
34
|
-
$
|
|
35
|
-
$
|
|
36
|
-
$
|
|
37
|
-
$
|
|
34
|
+
$ assistant sessions list
|
|
35
|
+
$ assistant sessions new "Project planning"
|
|
36
|
+
$ assistant sessions export
|
|
37
|
+
$ assistant sessions clear`,
|
|
38
38
|
);
|
|
39
39
|
|
|
40
40
|
sessions
|
|
@@ -50,7 +50,7 @@ Requires the assistant to be running — communicates via IPC. If auto-start is
|
|
|
50
50
|
enabled, the assistant will be started automatically.
|
|
51
51
|
|
|
52
52
|
Examples:
|
|
53
|
-
$
|
|
53
|
+
$ assistant sessions list`,
|
|
54
54
|
)
|
|
55
55
|
.action(async () => {
|
|
56
56
|
if (shouldAutoStartDaemon()) await ensureDaemonRunning();
|
|
@@ -82,9 +82,9 @@ Creates a new conversation session and prints its title and ID. Requires the
|
|
|
82
82
|
assistant to be running — communicates via IPC.
|
|
83
83
|
|
|
84
84
|
Examples:
|
|
85
|
-
$
|
|
86
|
-
$
|
|
87
|
-
$
|
|
85
|
+
$ assistant sessions new
|
|
86
|
+
$ assistant sessions new "Project planning"
|
|
87
|
+
$ assistant sessions new "Bug triage 2026-03-05"`,
|
|
88
88
|
)
|
|
89
89
|
.action(async (title?: string) => {
|
|
90
90
|
if (shouldAutoStartDaemon()) await ensureDaemonRunning();
|
|
@@ -121,9 +121,9 @@ Two output formats are available:
|
|
|
121
121
|
Operates on the local SQLite database directly — does not require the assistant.
|
|
122
122
|
|
|
123
123
|
Examples:
|
|
124
|
-
$
|
|
125
|
-
$
|
|
126
|
-
$
|
|
124
|
+
$ assistant sessions export
|
|
125
|
+
$ assistant sessions export --format json -o conversation.json
|
|
126
|
+
$ assistant sessions export abc123 --format md`,
|
|
127
127
|
)
|
|
128
128
|
.action(
|
|
129
129
|
async (
|
|
@@ -204,7 +204,7 @@ the assistant, but will notify it if running.
|
|
|
204
204
|
Intended for development use. This action cannot be undone.
|
|
205
205
|
|
|
206
206
|
Examples:
|
|
207
|
-
$
|
|
207
|
+
$ assistant sessions clear`,
|
|
208
208
|
)
|
|
209
209
|
.action(async () => {
|
|
210
210
|
log.info(
|
package/src/cli/trust.ts
CHANGED
|
@@ -24,9 +24,9 @@ a scope, a decision (allow or deny), and a priority. Rules are stored in
|
|
|
24
24
|
assistant invokes a tool.
|
|
25
25
|
|
|
26
26
|
Examples:
|
|
27
|
-
$
|
|
28
|
-
$
|
|
29
|
-
$
|
|
27
|
+
$ assistant trust list
|
|
28
|
+
$ assistant trust remove abc123
|
|
29
|
+
$ assistant trust clear`,
|
|
30
30
|
);
|
|
31
31
|
|
|
32
32
|
trust
|
|
@@ -49,7 +49,7 @@ IDs are shown truncated to 8 characters. Use the full ID or any unique
|
|
|
49
49
|
prefix with "trust remove".
|
|
50
50
|
|
|
51
51
|
Examples:
|
|
52
|
-
$
|
|
52
|
+
$ assistant trust list`,
|
|
53
53
|
)
|
|
54
54
|
.action(() => {
|
|
55
55
|
const rules = getAllRules();
|
|
@@ -104,9 +104,9 @@ no rule matches, exits with an error. Use "trust list" to see rule IDs
|
|
|
104
104
|
(shown truncated to 8 chars).
|
|
105
105
|
|
|
106
106
|
Examples:
|
|
107
|
-
$
|
|
108
|
-
$
|
|
109
|
-
$
|
|
107
|
+
$ assistant trust remove abc12345
|
|
108
|
+
$ assistant trust remove abc1
|
|
109
|
+
$ assistant trust remove a1b2c3d4-e5f6-7890-abcd-ef1234567890`,
|
|
110
110
|
)
|
|
111
111
|
.action((id: string) => {
|
|
112
112
|
const rules = getAllRules();
|
|
@@ -148,7 +148,7 @@ confirmation before proceeding (y/N). This action is irreversible — all
|
|
|
148
148
|
rules must be re-created manually after clearing.
|
|
149
149
|
|
|
150
150
|
Examples:
|
|
151
|
-
$
|
|
151
|
+
$ assistant trust clear`,
|
|
152
152
|
)
|
|
153
153
|
.action(async () => {
|
|
154
154
|
const rules = getAllRules();
|
package/src/cli/twitter.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* CLI command group: `
|
|
2
|
+
* CLI command group: `assistant twitter`
|
|
3
3
|
*
|
|
4
4
|
* Post tweets and manage Twitter sessions via the command line.
|
|
5
5
|
* All commands output JSON to stdout. Use --json for machine-readable output.
|
|
@@ -24,6 +24,7 @@ import {
|
|
|
24
24
|
searchTweets,
|
|
25
25
|
SessionExpiredError,
|
|
26
26
|
} from "../twitter/client.js";
|
|
27
|
+
import type { TwitterStrategy } from "../twitter/router.js";
|
|
27
28
|
import { routedPostTweet } from "../twitter/router.js";
|
|
28
29
|
import {
|
|
29
30
|
clearSession,
|
|
@@ -58,7 +59,7 @@ function getJson(cmd: Command): boolean {
|
|
|
58
59
|
|
|
59
60
|
const SESSION_EXPIRED_MSG =
|
|
60
61
|
"Your Twitter session has expired. Please sign in to Twitter in Chrome — " +
|
|
61
|
-
"run `
|
|
62
|
+
"run `assistant twitter refresh` to capture your session automatically.";
|
|
62
63
|
|
|
63
64
|
async function run(cmd: Command, fn: () => Promise<unknown>): Promise<void> {
|
|
64
65
|
try {
|
|
@@ -142,11 +143,11 @@ Session management:
|
|
|
142
143
|
- "logout" clears the saved browser session cookies
|
|
143
144
|
|
|
144
145
|
Examples:
|
|
145
|
-
$
|
|
146
|
-
$
|
|
147
|
-
$
|
|
148
|
-
$
|
|
149
|
-
$
|
|
146
|
+
$ assistant x status
|
|
147
|
+
$ assistant x post "Hello world"
|
|
148
|
+
$ assistant x timeline elonmusk --count 10
|
|
149
|
+
$ assistant x search "from:vaborsh AI agents" --product Latest
|
|
150
|
+
$ assistant x strategy set oauth`,
|
|
150
151
|
);
|
|
151
152
|
|
|
152
153
|
// =========================================================================
|
|
@@ -166,8 +167,8 @@ After import, all browser-path commands (timeline, search, bookmarks, etc.)
|
|
|
166
167
|
will use these cookies for authentication.
|
|
167
168
|
|
|
168
169
|
Examples:
|
|
169
|
-
$
|
|
170
|
-
$
|
|
170
|
+
$ assistant x login --recording /tmp/ride-shotgun/recording-abc123.json
|
|
171
|
+
$ assistant x login --recording ~/recordings/twitter-session.json`,
|
|
171
172
|
)
|
|
172
173
|
.action(async (opts: { recording: string }, cmd: Command) => {
|
|
173
174
|
await run(cmd, async () => {
|
|
@@ -193,7 +194,7 @@ will fail until a new session is imported via "login" or captured via "refresh".
|
|
|
193
194
|
OAuth credentials are not affected.
|
|
194
195
|
|
|
195
196
|
Examples:
|
|
196
|
-
$
|
|
197
|
+
$ assistant x logout`,
|
|
197
198
|
)
|
|
198
199
|
.action((_opts: unknown, cmd: Command) => {
|
|
199
200
|
clearSession();
|
|
@@ -224,9 +225,9 @@ cookies are imported automatically and Chrome is minimized.
|
|
|
224
225
|
Requires the assistant to be running (Ride Shotgun runs via the assistant).
|
|
225
226
|
|
|
226
227
|
Examples:
|
|
227
|
-
$
|
|
228
|
-
$
|
|
229
|
-
$
|
|
228
|
+
$ assistant x refresh
|
|
229
|
+
$ assistant x refresh --duration 120
|
|
230
|
+
$ assistant x refresh --duration 300`,
|
|
230
231
|
)
|
|
231
232
|
.action(async (opts: { duration: string }, cmd: Command) => {
|
|
232
233
|
const json = getJson(cmd);
|
|
@@ -287,8 +288,8 @@ Shows the current state of both authentication paths:
|
|
|
287
288
|
If the assistant is not running, OAuth fields will be reported as undefined.
|
|
288
289
|
|
|
289
290
|
Examples:
|
|
290
|
-
$
|
|
291
|
-
$
|
|
291
|
+
$ assistant x status
|
|
292
|
+
$ assistant x status --json`,
|
|
292
293
|
)
|
|
293
294
|
.action(async (_opts: unknown, cmd: Command) => {
|
|
294
295
|
const session = loadSession();
|
|
@@ -363,9 +364,9 @@ support both OAuth and browser session:
|
|
|
363
364
|
Run without a subcommand to display the current strategy. Use "set" to change it.
|
|
364
365
|
|
|
365
366
|
Examples:
|
|
366
|
-
$
|
|
367
|
-
$
|
|
368
|
-
$
|
|
367
|
+
$ assistant x strategy
|
|
368
|
+
$ assistant x strategy set oauth
|
|
369
|
+
$ assistant x strategy set auto`,
|
|
369
370
|
)
|
|
370
371
|
.action(async (_opts: unknown, cmd: Command) => {
|
|
371
372
|
const json = getJson(cmd);
|
|
@@ -399,9 +400,9 @@ routing. The setting is persisted by the assistant and applies to all subsequent
|
|
|
399
400
|
operations until changed.
|
|
400
401
|
|
|
401
402
|
Examples:
|
|
402
|
-
$
|
|
403
|
-
$
|
|
404
|
-
$
|
|
403
|
+
$ assistant x strategy set oauth
|
|
404
|
+
$ assistant x strategy set browser
|
|
405
|
+
$ assistant x strategy set auto`,
|
|
405
406
|
)
|
|
406
407
|
.action(async (value: string, _opts: unknown, cmd: Command) => {
|
|
407
408
|
const json = getJson(cmd);
|
|
@@ -435,31 +436,59 @@ Examples:
|
|
|
435
436
|
tw.command("post")
|
|
436
437
|
.description("Post a tweet")
|
|
437
438
|
.argument("<text>", "Tweet text")
|
|
439
|
+
.requiredOption(
|
|
440
|
+
"--strategy <strategy>",
|
|
441
|
+
"Operation strategy: oauth, browser, or auto",
|
|
442
|
+
)
|
|
443
|
+
.option(
|
|
444
|
+
"--oauth-token <token>",
|
|
445
|
+
"OAuth access token (required when strategy is oauth or auto)",
|
|
446
|
+
)
|
|
438
447
|
.addHelpText(
|
|
439
448
|
"after",
|
|
440
449
|
`
|
|
441
450
|
Arguments:
|
|
442
451
|
text The tweet text to post (max 280 characters)
|
|
443
452
|
|
|
444
|
-
Posts a new tweet using the routed dual-path system. The
|
|
445
|
-
|
|
446
|
-
|
|
453
|
+
Posts a new tweet using the routed dual-path system. The --strategy flag
|
|
454
|
+
controls which path is used. The response includes the tweet ID, URL, and
|
|
455
|
+
which path was used.
|
|
447
456
|
|
|
448
457
|
Examples:
|
|
449
|
-
$
|
|
450
|
-
$
|
|
458
|
+
$ assistant x post "Hello world" --strategy browser
|
|
459
|
+
$ assistant x post "Hello world" --strategy oauth --oauth-token "$TOKEN"
|
|
460
|
+
$ assistant x post "Hello world" --strategy auto --oauth-token "$TOKEN"`,
|
|
451
461
|
)
|
|
452
|
-
.action(
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
462
|
+
.action(
|
|
463
|
+
async (
|
|
464
|
+
text: string,
|
|
465
|
+
opts: { strategy: string; oauthToken?: string },
|
|
466
|
+
cmd: Command,
|
|
467
|
+
) => {
|
|
468
|
+
await run(cmd, async () => {
|
|
469
|
+
const strategy = opts.strategy as TwitterStrategy;
|
|
470
|
+
if (
|
|
471
|
+
strategy !== "oauth" &&
|
|
472
|
+
strategy !== "browser" &&
|
|
473
|
+
strategy !== "auto"
|
|
474
|
+
) {
|
|
475
|
+
throw new Error(
|
|
476
|
+
`Invalid strategy "${opts.strategy}". Must be oauth, browser, or auto.`,
|
|
477
|
+
);
|
|
478
|
+
}
|
|
479
|
+
const { result, pathUsed } = await routedPostTweet(text, {
|
|
480
|
+
strategy,
|
|
481
|
+
oauthToken: opts.oauthToken,
|
|
482
|
+
});
|
|
483
|
+
return {
|
|
484
|
+
tweetId: result.tweetId,
|
|
485
|
+
text: result.text,
|
|
486
|
+
url: result.url,
|
|
487
|
+
pathUsed,
|
|
488
|
+
};
|
|
489
|
+
});
|
|
490
|
+
},
|
|
491
|
+
);
|
|
463
492
|
|
|
464
493
|
// =========================================================================
|
|
465
494
|
// reply — reply to a tweet
|
|
@@ -468,6 +497,14 @@ Examples:
|
|
|
468
497
|
.description("Reply to a tweet")
|
|
469
498
|
.argument("<tweetUrl>", "Tweet URL or tweet ID")
|
|
470
499
|
.argument("<text>", "Reply text")
|
|
500
|
+
.requiredOption(
|
|
501
|
+
"--strategy <strategy>",
|
|
502
|
+
"Operation strategy: oauth, browser, or auto",
|
|
503
|
+
)
|
|
504
|
+
.option(
|
|
505
|
+
"--oauth-token <token>",
|
|
506
|
+
"OAuth access token (required when strategy is oauth or auto)",
|
|
507
|
+
)
|
|
471
508
|
.addHelpText(
|
|
472
509
|
"after",
|
|
473
510
|
`
|
|
@@ -477,15 +514,30 @@ Arguments:
|
|
|
477
514
|
|
|
478
515
|
Posts a reply to the specified tweet. Accepts either a full tweet URL or a bare
|
|
479
516
|
numeric tweet ID. The tweet ID is extracted from the last numeric segment of the
|
|
480
|
-
URL.
|
|
517
|
+
URL. The --strategy flag controls which path is used.
|
|
481
518
|
|
|
482
519
|
Examples:
|
|
483
|
-
$
|
|
484
|
-
$
|
|
520
|
+
$ assistant x reply https://x.com/elonmusk/status/1234567890 "Great point!" --strategy browser
|
|
521
|
+
$ assistant x reply 1234567890 "Interesting thread" --strategy oauth --oauth-token "$TOKEN"`,
|
|
485
522
|
)
|
|
486
523
|
.action(
|
|
487
|
-
async (
|
|
524
|
+
async (
|
|
525
|
+
tweetUrl: string,
|
|
526
|
+
text: string,
|
|
527
|
+
opts: { strategy: string; oauthToken?: string },
|
|
528
|
+
cmd: Command,
|
|
529
|
+
) => {
|
|
488
530
|
await run(cmd, async () => {
|
|
531
|
+
const strategy = opts.strategy as TwitterStrategy;
|
|
532
|
+
if (
|
|
533
|
+
strategy !== "oauth" &&
|
|
534
|
+
strategy !== "browser" &&
|
|
535
|
+
strategy !== "auto"
|
|
536
|
+
) {
|
|
537
|
+
throw new Error(
|
|
538
|
+
`Invalid strategy "${opts.strategy}". Must be oauth, browser, or auto.`,
|
|
539
|
+
);
|
|
540
|
+
}
|
|
489
541
|
// Extract tweet ID: either a bare numeric ID or the last numeric segment of a URL
|
|
490
542
|
const idMatch = tweetUrl.match(/(\d+)\s*$/);
|
|
491
543
|
if (!idMatch) {
|
|
@@ -494,6 +546,8 @@ Examples:
|
|
|
494
546
|
const inReplyToTweetId = idMatch[1];
|
|
495
547
|
const { result, pathUsed } = await routedPostTweet(text, {
|
|
496
548
|
inReplyToTweetId,
|
|
549
|
+
strategy,
|
|
550
|
+
oauthToken: opts.oauthToken,
|
|
497
551
|
});
|
|
498
552
|
return {
|
|
499
553
|
tweetId: result.tweetId,
|
|
@@ -523,9 +577,9 @@ to a user ID first, then retrieves their tweet timeline. The --count flag contro
|
|
|
523
577
|
how many tweets to return (default: 20).
|
|
524
578
|
|
|
525
579
|
Examples:
|
|
526
|
-
$
|
|
527
|
-
$
|
|
528
|
-
$
|
|
580
|
+
$ assistant x timeline elonmusk
|
|
581
|
+
$ assistant x timeline vaborsh --count 50
|
|
582
|
+
$ assistant x timeline openai --count 10 --json`,
|
|
529
583
|
)
|
|
530
584
|
.action(
|
|
531
585
|
async (screenName: string, opts: { count: string }, cmd: Command) => {
|
|
@@ -558,9 +612,9 @@ ID is extracted from the last numeric segment of the input. Returns an array of
|
|
|
558
612
|
tweets representing the conversation thread.
|
|
559
613
|
|
|
560
614
|
Examples:
|
|
561
|
-
$
|
|
562
|
-
$
|
|
563
|
-
$
|
|
615
|
+
$ assistant x tweet 1234567890
|
|
616
|
+
$ assistant x tweet https://x.com/elonmusk/status/1234567890
|
|
617
|
+
$ assistant x tweet https://x.com/openai/status/9876543210 --json`,
|
|
564
618
|
)
|
|
565
619
|
.action(async (tweetIdOrUrl: string, _opts: unknown, cmd: Command) => {
|
|
566
620
|
await run(cmd, async () => {
|
|
@@ -595,9 +649,9 @@ The --product flag selects the search result type:
|
|
|
595
649
|
Uses the browser session path. Requires an active browser session.
|
|
596
650
|
|
|
597
651
|
Examples:
|
|
598
|
-
$
|
|
599
|
-
$
|
|
600
|
-
$
|
|
652
|
+
$ assistant x search "AI agents"
|
|
653
|
+
$ assistant x search "from:elonmusk SpaceX" --product Latest
|
|
654
|
+
$ assistant x search "machine learning" --product Media --json`,
|
|
601
655
|
)
|
|
602
656
|
.action(async (query: string, opts: { product: string }, cmd: Command) => {
|
|
603
657
|
await run(cmd, async () => {
|
|
@@ -625,9 +679,9 @@ Requires an active browser session. Bookmarks are private and only available
|
|
|
625
679
|
for the logged-in account.
|
|
626
680
|
|
|
627
681
|
Examples:
|
|
628
|
-
$
|
|
629
|
-
$
|
|
630
|
-
$
|
|
682
|
+
$ assistant x bookmarks
|
|
683
|
+
$ assistant x bookmarks --count 50
|
|
684
|
+
$ assistant x bookmarks --json`,
|
|
631
685
|
)
|
|
632
686
|
.action(async (opts: { count: string }, cmd: Command) => {
|
|
633
687
|
await run(cmd, async () => {
|
|
@@ -651,9 +705,9 @@ browser session. The --count flag controls how many tweets to return (default: 2
|
|
|
651
705
|
Requires an active browser session.
|
|
652
706
|
|
|
653
707
|
Examples:
|
|
654
|
-
$
|
|
655
|
-
$
|
|
656
|
-
$
|
|
708
|
+
$ assistant x home
|
|
709
|
+
$ assistant x home --count 50
|
|
710
|
+
$ assistant x home --json`,
|
|
657
711
|
)
|
|
658
712
|
.action(async (opts: { count: string }, cmd: Command) => {
|
|
659
713
|
await run(cmd, async () => {
|
|
@@ -678,9 +732,9 @@ how many notifications to return (default: 20).
|
|
|
678
732
|
Requires an active browser session.
|
|
679
733
|
|
|
680
734
|
Examples:
|
|
681
|
-
$
|
|
682
|
-
$
|
|
683
|
-
$
|
|
735
|
+
$ assistant x notifications
|
|
736
|
+
$ assistant x notifications --count 50
|
|
737
|
+
$ assistant x notifications --json`,
|
|
684
738
|
)
|
|
685
739
|
.action(async (opts: { count: string }, cmd: Command) => {
|
|
686
740
|
await run(cmd, async () => {
|
|
@@ -707,9 +761,9 @@ screen name to a user ID first. The --count flag controls how many liked tweets
|
|
|
707
761
|
to return (default: 20).
|
|
708
762
|
|
|
709
763
|
Examples:
|
|
710
|
-
$
|
|
711
|
-
$
|
|
712
|
-
$
|
|
764
|
+
$ assistant x likes elonmusk
|
|
765
|
+
$ assistant x likes vaborsh --count 50
|
|
766
|
+
$ assistant x likes openai --json`,
|
|
713
767
|
)
|
|
714
768
|
.action(
|
|
715
769
|
async (screenName: string, opts: { count: string }, cmd: Command) => {
|
|
@@ -737,8 +791,8 @@ Fetches the list of accounts following the specified user via the browser sessio
|
|
|
737
791
|
Resolves the screen name to a user ID first.
|
|
738
792
|
|
|
739
793
|
Examples:
|
|
740
|
-
$
|
|
741
|
-
$
|
|
794
|
+
$ assistant x followers elonmusk
|
|
795
|
+
$ assistant x followers vaborsh --json`,
|
|
742
796
|
)
|
|
743
797
|
.action(async (screenName: string, _opts: unknown, cmd: Command) => {
|
|
744
798
|
await run(cmd, async () => {
|
|
@@ -767,9 +821,9 @@ Resolves the screen name to a user ID first. The --count flag controls how many
|
|
|
767
821
|
results to return (default: 20).
|
|
768
822
|
|
|
769
823
|
Examples:
|
|
770
|
-
$
|
|
771
|
-
$
|
|
772
|
-
$
|
|
824
|
+
$ assistant x following elonmusk
|
|
825
|
+
$ assistant x following vaborsh --count 100
|
|
826
|
+
$ assistant x following openai --json`,
|
|
773
827
|
)
|
|
774
828
|
.action(
|
|
775
829
|
async (screenName: string, opts: { count: string }, cmd: Command) => {
|
|
@@ -802,9 +856,9 @@ session. Resolves the screen name to a user ID first. The --count flag controls
|
|
|
802
856
|
how many media tweets to return (default: 20).
|
|
803
857
|
|
|
804
858
|
Examples:
|
|
805
|
-
$
|
|
806
|
-
$
|
|
807
|
-
$
|
|
859
|
+
$ assistant x media elonmusk
|
|
860
|
+
$ assistant x media nasa --count 50
|
|
861
|
+
$ assistant x media openai --json`,
|
|
808
862
|
)
|
|
809
863
|
.action(
|
|
810
864
|
async (screenName: string, opts: { count: string }, cmd: Command) => {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Use this pattern for setup/status reads in bundled skills:
|
|
4
4
|
|
|
5
5
|
1. Run Vellum CLI reads through `bash` (not `host_bash`).
|
|
6
|
-
2. Use domain commands (for example `
|
|
6
|
+
2. Use domain commands (for example `assistant integrations twilio config`) instead of direct gateway `curl`.
|
|
7
7
|
3. Let the CLI handle gateway auth internally; do not instruct manual bearer headers for read paths.
|
|
8
8
|
|
|
9
9
|
When a skill needs outbound API calls with a stored credential (outside of Vellum CLI reads), use proxied bash:
|