The 1Password Python SDK offers programmatic read access to your secrets in 1Password in an interface native to Python.
Actively maintained. Last release 6 weeks ago, commits in 7 of the last 26 weeks. A safe choice.
pip install onepassword-sdk1Password Python SDK
Build integrations that programmatically interact with 1Password.
Requirements
The 1Password Python SDK is compatible with:
python3.9 or laterlibssl3glibc2.32 or later
If you're running a Linux distribution that still uses libssl version 1.1.1, such as Debian 11 or Ubuntu 20.04, you'll need to update to a later version of Linux or install the required dependencies.
🚀 Get started
You can choose between two authentication methods for the 1Password Python SDK: local authorization prompts from the 1Password desktop app or automated authentication with a 1Password Service Account.
This project is licensed under MIT. Use of the 1Password APIs and services accessed through these tools is governed by the 1Password API Terms of Service.
Option 1: 1Password desktop app
1Password desktop app authentication is best for local integrations that require minimal setup from end users and sensitive workflows that require human-in-the-loop approval. To set up the SDK to authenticate with the 1Password app:
-
Install the 1Password desktop app and sign in to your account in the app.
-
Select your account or collection at the top of the sidebar, then navigate to Settings > .