Skip to content

Teach agents to reuse stored HEY authentication - #366

Merged
robzolkos merged 1 commit into
mainfrom
fix/skill-unattended-auth
Aug 31, 2026
Merged

Teach agents to reuse stored HEY authentication#366
robzolkos merged 1 commit into
mainfrom
fix/skill-unattended-auth

Conversation

@robzolkos

@robzolkos robzolkos commented Aug 31, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • direct agents to reuse stored HEY credentials instead of starting browser OAuth before data commands
  • reserve hey auth status --json for explicit checks and hey auth login for interactive recovery
  • document HEY_NONINTERACTIVE=1 as the no-prompt guarantee for unattended PTY sessions
  • cover the embedded guidance and non-interactive prompt behavior with regression tests

Validation

  • GOWORK=off make check
  • GOWORK=off make build
  • fresh isolated Pi agent with available credentials ran the requested data command directly, without a status preflight or login
  • fresh isolated Pi agent receiving an exit-code-3 auth error reported the task blocked without attempting login
  • fresh isolated Pi agent asked explicitly for authentication status ran only hey auth status --json

Fixes #147


Summary by cubic

Agents now reuse stored HEY credentials instead of running a browser OAuth preflight before data commands, so unattended runs no longer trigger unnecessary login prompts.

  • hey auth status --json is reserved for explicit checks; the skill no longer directs agents to run it as a preflight.
  • HEY_NONINTERACTIVE=1 is now documented as the no-prompt guarantee for unattended PTY sessions.
  • Added regression tests for the embedded skill guidance and non-interactive prompt behavior.

Fixes #147.

Written for commit 13b2677. Summary will update on new commits.

Review in cubic

Copilot AI balanced review requested due to automatic review settings August 31, 2026 02:04
@robzolkos
robzolkos requested a review from a team as a code owner August 31, 2026 02:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates embedded agent guidance to reuse stored credentials and avoid unattended OAuth prompts.

Changes:

  • Directs agents to run data commands without authentication preflights.
  • Documents HEY_NONINTERACTIVE=1 for unattended PTY sessions.
  • Adds regression coverage for guidance and prompt suppression.

Tip

If you aren't ready for review, convert to a draft PR.
Click "Convert to draft" or run gh pr ready --undo.
Click "Ready for review" or run gh pr ready to reengage.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
skills/hey/SKILL.md Revises authentication guidance and examples.
skills/embed_test.go Verifies embedded authentication guidance.
internal/cmd/root_test.go Tests non-interactive prompt suppression.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@robzolkos
robzolkos merged commit 423d3fb into main Aug 31, 2026
24 checks passed
@robzolkos
robzolkos deleted the fix/skill-unattended-auth branch August 31, 2026 02:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

HEY skill should reuse stored authentication for unattended agents

2 participants