-
Notifications
You must be signed in to change notification settings - Fork 15
feat(toolbox-langchain): Add client headers to Toolbox #264
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: Should we also add/update e2e tests for this?
This is used to connect to deployed instances of toolbox that require auth. However, in the current e2e tests, we run a local toolbox instance within our cloud build env. So, we cannot test this feature with the current e2e test setup. We might want to create a workflow to create a new toolbox instance and deploy to cloud run to test this out in the future. Right now, we'll be running unit and manual tests. |
|
||
### How it works | ||
|
||
The `ToolboxClient` (and `ToolboxSyncClient`) allows you to specify functions (or coroutines for the async client) that dynamically generate HTTP headers for every request sent to the Toolbox server. The most common use case is to add an Authorization header with a bearer token (e.g., a Google ID token). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ToolboxSyncClient
is not applicable in this package.
Wrapper for adding client_headers feature. Core implemented in #178