<#390 API Key detection/use> Pull request opened b...
# flyte-github
a
#390 API Key detection/use Pull request opened by wild-endeavor Update the
flyte
CLI to automatically understand the
FLYTE_API_KEY
environment variable but only adding it there. It will only work if no config file has been specified and no config file has been automatically detected. The reason for this is that this is really for headless use. For normal human use we want users to use the normal config file/pkce auth patterns. • Added a new init function called
init_from_api_key
. It requires the endpoint and if
api_key
is missing, will also read from the environment variable. We want to enforce this because api keys in the future might not encode the endpoint like they do today. Also the naming of this function is explicit enough that we can rely on the env var. • Also make fmt. flyteorg/flyte-sdk