Skip to content

Add vip auth CLI for credential minting#34

Draft
ian-flores wants to merge 1 commit intomainfrom
auth-cli
Draft

Add vip auth CLI for credential minting#34
ian-flores wants to merge 1 commit intomainfrom
auth-cli

Conversation

@ian-flores
Copy link
Collaborator

Summary

Part of #29 — adds a CLI entry point for minting Connect API keys via interactive browser auth. This enables ptd verify --interactive-auth to consume VIP's auth flow without reimplementing browser automation in Go.

Usage

vip auth mint-connect-key --url https://connect.example.com

Opens a browser window for OIDC login, mints a Connect API key via the UI, and outputs JSON:

{"api_key": "abc123...", "key_name": "_vip_interactive_1709747200"}

Integration

ptd verify calls this as a subprocess to get Connect credentials for the K8s Job. The key_name is stored alongside the key for later cleanup.

Files

  • src/vip/cli.py (new) — CLI entry point with argparse
  • pyproject.toml — added [project.scripts] entry

Adds a CLI entry point for minting Connect API keys via interactive browser auth. This enables `ptd verify --interactive-auth` to consume VIP's auth flow without reimplementing browser automation in Go.

The `vip auth mint-connect-key` command opens a browser window for OIDC login, mints a Connect API key via the UI, and outputs JSON with the key and key_name for later cleanup.
@github-actions
Copy link

github-actions bot commented Mar 6, 2026

PR Preview Action v1.8.1

QR code for preview link

🚀 View preview at
https://posit-dev.github.io/vip/pr-preview/pr-34/

Built to branch gh-pages at 2026-03-06 20:50 UTC.
Preview will be ready when the GitHub Pages deployment is complete.

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