You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Is there a way to pass in the credentials as environment variables? #196
Hello, I am attempting to build out some custom integrations, however I am unable to find an example of authentication where it does not require a human to input anything at runtime. The custom integration that will be using this module will be running in a container on kubernetes and having a documented way to provide the creds dynamically without requiring human interaction would be very helpful.
In Keeper Commander you can do this by passing in the creds and parsing it into KeeperParams, in this "SDK" correct me if I'm wrong, I'm not seeing offhand a similar class or method to do this which I thought was the whole point of the SDK being created so that it can be implemented in fully automated solutions vs having human inputs like Keeper Commander.
Hi @ciso-davidpham
You would need a config file to be loaded in the environment variable to be pulled in the Kubernetes container. This step is necessary to avoid the device verification step that is added as a security measure on unknown devices. The config can be populated with your login credentials and the account you are using should ideally be an account without MFA methods which require additional user interaction. The config structure can be checked in the README.md here.
To create a usable config, first login on a local machine with the account you want to use in the cloud script. Turn on persistent-login for the account. Note: To have uninterrupted persistent-login, do not use the same account on local machine again as this would break the session. You can upload the config on cloud environment to ensure automated script executions without interaction in login flow and as an additional check, the password field can be populated in the config
Hey @adeshmukh-ks I forgot to mention with Keeper Commander I convert the config file to base64 then pass it into the as environment variable, as it is much easier to store the base64 string in Keeper Secrets Manager and use a custom pydantic settings module to pull the secret into the client is there a similar method in keepersdk? I am attaching an example snippet of the code I wrote to allow this for Keeper Commander.
Hi @ciso-davidpham
We do not currently have a similar function which would directly decode the base64 for login flow.
This is something that we have in pipeline and it will be available soon.
Activity
adeshmukh-ks commentedon Jun 29, 2026
Hi @ciso-davidpham
You would need a config file to be loaded in the environment variable to be pulled in the Kubernetes container. This step is necessary to avoid the device verification step that is added as a security measure on unknown devices. The config can be populated with your login credentials and the account you are using should ideally be an account without MFA methods which require additional user interaction. The config structure can be checked in the README.md here.
To create a usable config, first login on a local machine with the account you want to use in the cloud script. Turn on persistent-login for the account. Note: To have uninterrupted persistent-login, do not use the same account on local machine again as this would break the session. You can upload the config on cloud environment to ensure automated script executions without interaction in login flow and as an additional check, the password field can be populated in the config
ciso-davidpham commentedon Jun 29, 2026
Hey @adeshmukh-ks I forgot to mention with Keeper Commander I convert the config file to base64 then pass it into the as environment variable, as it is much easier to store the base64 string in Keeper Secrets Manager and use a custom pydantic settings module to pull the secret into the client is there a similar method in keepersdk? I am attaching an example snippet of the code I wrote to allow this for Keeper Commander.
adeshmukh-ks commentedon Jun 30, 2026
Hi @ciso-davidpham
We do not currently have a similar function which would directly decode the base64 for login flow.
This is something that we have in pipeline and it will be available soon.
ciso-davidpham commentedon Jun 30, 2026
Hello @adeshmukh-ks, thank you, decoding the base64 would be very helpful, I'm currently using the following code to allow this in the meantime.