lamindb.setup.login¶
- lamindb.setup.login(user=None, *, api_key=None, **kwargs)¶
Log into LaminHub.
login()
prompts for your API key unless you set it via theLAMIN_API_KEY
environment variable or pass it as an argument.You can create your API key in your account settings on LaminHub (top right corner).
- Parameters:
user (
str
|None
, default:None
) – User handle.api_key (
str
|None
, default:None
) – API key.
- Return type:
See also
Login via the CLI command
lamin login
, see here.Examples
Logging in the first time:
import lamindb as ln ln.setup.login() # prompts for API key
After authenticating multiple users, you can switch between user profiles:
ln.setup.login("myhandle") # pass your user handle