Skip to content

Conversation

@michaelva
Copy link
Contributor

Summary

  • Add GitHub-style composite avatar for agent tokens showing the on-behalf-of user
  • Display side-by-side avatars: agent icon + user/API key avatar overlay
  • Show "Agent on behalf of [User]" in popover with full user details
  • Add useFetchApiKeyInfo hook for fetching API key information
  • Parse extended agent identifier format: agent:accountId:projectId:timestamp:user:userId
  • Backward compatible with legacy agent:agent:... format

UI Changes

  • AgentAvatar component: New component with composite avatar design
  • UserInfo parser: Extended to handle new agent identifier format with on-behalf-of info
  • Popover: Displays user name, email, avatar when agent acts on behalf of user
  • API key support: Shows API key name and ID when agent acts on behalf of API key

Test Plan

  • Agent with on-behalf-of user displays user avatar overlay
  • Agent with on-behalf-of API key displays API badge
  • Legacy format agent:agent:... parses correctly without crash
  • Agent without on-behalf-of displays as generic agent
  • Popover shows correct user information

Related

Part of agent token permission fixes - UI component for Part 1 (identifier format and display)

🤖 Generated with Claude Code
Co-Authored-By: Claude Sonnet 4.5 noreply@anthropic.com

@michaelva michaelva requested a review from a team as a code owner January 29, 2026 07:06
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.

3 participants