{"id":18454319,"url":"https://github.com/1password/connect-sdk-python","last_synced_at":"2025-05-15T04:02:41.381Z","repository":{"id":38308431,"uuid":"317335892","full_name":"1Password/connect-sdk-python","owner":"1Password","description":"Python SDK for 1Password Connect","archived":false,"fork":false,"pushed_at":"2024-12-20T09:02:02.000Z","size":278,"stargazers_count":205,"open_issues_count":23,"forks_count":33,"subscribers_count":19,"default_branch":"main","last_synced_at":"2025-04-14T22:14:37.999Z","etag":null,"topics":["1password","1password-connect","connect-sdk","python","secrets-management"],"latest_commit_sha":null,"homepage":"https://developer.1password.com/docs/connect","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/1Password.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-11-30T20:18:30.000Z","updated_at":"2025-04-04T02:26:53.000Z","dependencies_parsed_at":"2023-02-16T23:46:18.449Z","dependency_job_id":"c3f9a973-b703-429c-a6f2-d0f7eb36a695","html_url":"https://github.com/1Password/connect-sdk-python","commit_stats":{"total_commits":136,"total_committers":24,"mean_commits":5.666666666666667,"dds":0.8014705882352942,"last_synced_commit":"b7531412d488cf95dee4f28256cfc0804d6bdef4"},"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1Password%2Fconnect-sdk-python","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1Password%2Fconnect-sdk-python/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1Password%2Fconnect-sdk-python/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1Password%2Fconnect-sdk-python/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/1Password","download_url":"https://codeload.github.com/1Password/connect-sdk-python/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248968917,"owners_count":21191162,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["1password","1password-connect","connect-sdk","python","secrets-management"],"created_at":"2024-11-06T08:03:46.614Z","updated_at":"2025-04-14T22:14:45.505Z","avatar_url":"https://github.com/1Password.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003c!-- Image sourced from https://blog.1password.com/introducing-secrets-automation/ --\u003e\n\u003cimg alt=\"\" role=\"img\" src=\"https://blog.1password.com/posts/2021/secrets-automation-launch/header.svg\"/\u003e\n\n\u003cdiv align=\"center\"\u003e\n  \u003ch1\u003e1Password Connect SDK for Python\u003c/h1\u003e\n  \u003cp\u003eAccess your 1Password items in your Python applications through your self-hosted \u003ca href=\"https://developer.1password.com/docs/connect\"\u003e1Password Connect server\u003c/a\u003e.\u003c/p\u003e\n  \u003ca href=\"#-get-started\"\u003e\n    \u003cimg alt=\"Get started\" src=\"https://user-images.githubusercontent.com/45081667/226940040-16d3684b-60f4-4d95-adb2-5757a8f1bc15.png\" height=\"37\"/\u003e\n  \u003c/a\u003e\n\u003c/div\u003e\n\n---\n\nThe 1Password Connect SDK provides access to 1Password via [1Password Connect](https://developer.1password.com/docs/connect) hosted in your infrastructure. The library is intended to be used by Python applications to simplify accessing items in 1Password vaults.\n\n## 🪄 See it in action\n\nCheck the [Python Connect SDK Example](example/README.md) to see an example of item manipulation using the SDK that you can execute on your machine.\n\n## ✨ Get started\n\n1. Install the 1Password Connect Python SDK:\n\n   ```sh\n   pip install onepasswordconnectsdk\n   ```\n\n2. Export the `OP_CONNECT_HOST` and `OP_CONNECT_TOKEN` environment variables:\n\n   ```sh\n   export OP_CONNECT_HOST=\u003cyour-connect-host\u003e \u0026\u0026 \\\n   export OP_CONNECT_TOKEN=\u003cyour-connect-token\u003e\n   ```\n\n   2.1 If you need a higher timeout on the client requests you can export `OP_CONNECT_CLIENT_REQ_TIMEOUT` environment variable:\n\n   ```sh\n   # set the timeout to 90 seconds\n   export OP_CONNECT_CLIENT_REQ_TIMEOUT=90\n   ```\n\n3. Use the SDK:\n\n   - Read a secret:\n\n     ```python\n     from onepasswordconnectsdk.client import (\n         Client,\n         new_client_from_environment,\n     )\n\n     connect_client: Client = new_client_from_environment()\n\n     client.get_item(\"{item_id}\", \"{vault_id}\")\n     ```\n\n   - Write a secret:\n\n     ```python\n     from onepasswordconnectsdk.client import (\n         Client,\n         new_client_from_environment,\n     }\n\n     from onepasswordconnectsdk.models import (\n         Item,\n         ItemVault,\n         Field\n     )\n\n     connect_client: Client = new_client_from_environment()\n\n     # Example item creation. Create an item with your desired arguments.\n     item = Item(\n         vault=ItemVault(id=op_vault),\n         id=\"custom_id\",\n         title=\"newtitle\",\n         category=\"LOGIN\",\n         tags=[\"1password-connect\"],\n         fields=[Field(value=\"new_user\", purpose=\"USERNAME\")],\n     )\n\n     new_item = connect_client.create_item(op_vault, item)\n     ```\n\nFor more examples of how to use the SDK, check out [USAGE.md](USAGE.md).\n\n## 💙 Community \u0026 Support\n\n- File an [issue](https://github.com/1Password/connect-sdk-python/issues) for bugs and feature requests.\n- Join the [Developer Slack workspace](https://join.slack.com/t/1password-devs/shared_invite/zt-1halo11ps-6o9pEv96xZ3LtX_VE0fJQA).\n- Subscribe to the [Developer Newsletter](https://1password.com/dev-subscribe/).\n\n## 🔐 Security\n\n1Password requests you practice responsible disclosure if you discover a vulnerability.\n\nPlease file requests by sending an email to bugbounty@agilebits.com.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1password%2Fconnect-sdk-python","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F1password%2Fconnect-sdk-python","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1password%2Fconnect-sdk-python/lists"}