Skip to content

feat(grok): add opt-in --web flow for grok ask#193

Open
KasumiChen wants to merge 1 commit intojackwener:mainfrom
KasumiChen:feat/grok-web-flag
Open

feat(grok): add opt-in --web flow for grok ask#193
KasumiChen wants to merge 1 commit intojackwener:mainfrom
KasumiChen:feat/grok-web-flag

Conversation

@KasumiChen
Copy link
Contributor

Summary

  • preserve the existing default opencli grok ask behavior
  • add an explicit --web flag for the hardened browser-backed consumer web flow
  • update Grok docs/examples to make the default vs opt-in web path clear

Compatibility

  • default opencli grok ask --prompt ... remains the existing/default implementation
  • only opencli grok ask --prompt ... --web activates the newer grok.com consumer web path
  • existing main args and default response shape stay intact by default

Notes

  • the --web flow requires an already-authenticated grok.com browser session
  • this is still consumer-web automation and may be brittle around auth/session/challenge or DOM changes

Validation

  • npx tsc --noEmit
  • npx vitest run src/clis/grok/ask.test.ts
  • npm run build
  • npx tsx src/main.ts grok ask --prompt "Reply with exactly OK and nothing else." --web -f json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant