Skip to content

Amber feedback API returns auth error (token expired/invalid) during active session #1499

@ambient-code

Description

@ambient-code

Category: bug

Summary

When Amber (the interview/feedback workflow) attempts to submit feedback to the platform via the feedback API, the request fails with an auth error even though the session is still active.

Steps to Reproduce

  1. Start an Amber interview session
  2. Complete the interview flow
  3. Choose "Platform feedback" as the destination
  4. Amber POSTs to /api/projects/{project}/agentic-sessions/{session}/agui/feedback with the AGUI_TOKEN from the session environment
  5. Result: API returns {"error": "Token expired or invalid"}

Expected Behavior

Feedback should be submitted successfully to the platform while the session is running.

Actual Behavior

  • Backend returns {"error": "Token expired or invalid"} when using AGUI_TOKEN as the Bearer token
  • Local AGUI server (port 8001) returns {"detail": "Unauthorized"} for the same token
  • Feedback cannot be submitted; must fall back to saving as a local file artifact

Environment

  • AGUI_TOKEN is set in session environment at startup
  • Token appears to expire before or during the session, making platform feedback submission impossible
  • Session was active and running at time of failure

Impact

Platform feedback destination is effectively broken for Amber workflow — users cannot submit feedback to the Ambient team from within a session.

Possible Causes

  • AGUI_TOKEN has a short TTL and expires during long sessions
  • The feedback endpoint requires a different token type (user browser token vs. agent token)
  • Token is not refreshed automatically when it expires

Discovered during Amber Interview session — filed via Amber Interview

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions