How to perform custom authentication + session initialization + post-response logging in ADK API Server?** #3466
Unanswered
sivakumar-d3v
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I am exposing my ADK agent using the API Server interface (e.g.,
/run,/sessions, etc.).I need to add a custom workflow around each session:
When the user connects (or calls
/run), I want to:During the session, the agent should run normally using these injected values as part of the prompt/context.
After the agent finishes responding, I need to perform a post-run operation such as:
What is the recommended ADK pattern to do this?
Specifically, I want to know:
Where should I hook custom authentication logic?
How can I inject authenticated claim data into the Agent prompt after authentication?
Is there a post-run hook for cleanly running custom logic after the final agent response?
Additional Context
Thanks in advance — looking for the best ADK-aligned design pattern rather than a workaround.
Beta Was this translation helpful? Give feedback.
All reactions