Skip to main content
The Python binding for the Domino API is available in PyPI:
If you want to use the Python binding in a Domino workbook session include dominodatalab in your project’s requirements.txt file. This makes the Python binding available for each new workbook session (or batch run) started within the project.
Full documentation for this API is forthcoming. For more information now, see Domino’s public Python bindings project.
In existing deployments After installation, you can instantiate a library either with your API Key or Auth Token File. Token File: To use Token File to instantiate Python Domino, pass the path to this token file, either through class constructor (domino_token_file=<Path to Token file>) or through an environment variable.
If you are using Python package in code that is already running in Domino, the DOMINO_TOKEN_FILE is set automatically to be the token file for the user who started the run. API Key: You must get your API key from your account page. To get your API Key, log into Domino and click your name in the menu. Click Account Settings and select API Key. Copy the API key to your clipboard. The Python library reads this key from environment variables, so set it as follows in your shell:
If you are using the Python package in code that is already running in Domino, the DOMINO_API_USER_KEY variable is set automatically to be the key for the user who started the run.
  • If both the API Key and Token files are present, default preference is given to the Token file. To use the API Key file instead, clear the DOMINO_TOKEN_FILE environment variable.
  • See the Domino Platform API Reference for more detail.
The following is an example of usage:
In new deployments Domino updated the Python library to work with the API Proxy inside the execution. If the library is instantiated without any authentication arguments, it detects the API Proxy (see the DOMINO_API_PROXY environment variable) and routes the calls through it automatically. If you explicitly specify other means of authentication (domino_token, domino_token_file, api_key), it works exactly like it did previously. See Use API Proxy to Authenticate Calls to the Domino API.
Last modified on July 16, 2026