Skip to content
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

feat: Wire up API keys via env var for Phoenix clients and experiments #4617

Merged
merged 5 commits into from
Sep 17, 2024

Conversation

anticorrelator
Copy link
Contributor

resolves #4613

  • ensures that PHOENIX_API_KEY is properly propagated to the Client and Experiment modules

@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Sep 13, 2024
@dosubot dosubot bot added size:M This PR changes 30-99 lines, ignoring generated files. and removed size:S This PR changes 10-29 lines, ignoring generated files. labels Sep 13, 2024
self.headers.update(env_headers)
if "authorization" not in [k.lower() for k in self.headers]:
if api_key := get_env_phoenix_api_key():
self.headers["authorization"] = f"Bearer {api_key}"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
self.headers["authorization"] = f"Bearer {api_key}"
self.headers["Authorization"] = f"Bearer {api_key}"

@dosubot dosubot bot added size:S This PR changes 10-29 lines, ignoring generated files. and removed size:M This PR changes 30-99 lines, ignoring generated files. labels Sep 17, 2024
@anticorrelator anticorrelator merged commit c0b917a into auth Sep 17, 2024
16 checks passed
@anticorrelator anticorrelator deleted the dustin/wire-up-api-keys branch September 17, 2024 21:26
RogerHYang pushed a commit that referenced this pull request Sep 21, 2024
#4617)

* feat: Wire up API keys via env var for Phoenix clients and experiments

* Unify header management

* Capitalize `authorization` header key

* Capitalization shouldn't matter

* Recapitalize b/c REST
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size:S This PR changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants