oci
Oracle Cloud Infrastructure Python SDK
What it is and what it does
The oci package is Oracle's official Python SDK for Oracle Cloud Infrastructure (OCI). It provides a programmatic interface to OCI services through typed service clients, allowing you to manage cloud resources, query identity and access control, and interact with storage, compute, and other OCI offerings from Python code. The SDK handles authentication via OCI configuration files, manages HTTP communication with cryptographic security, and abstracts the underlying REST API into Python objects and method calls.
You install it via pip into a virtual environment and configure it with OCI credentials. The typical workflow is to load a configuration file, instantiate a service client for the OCI service you need (such as IdentityClient, ComputeClient, or ObjectStorageClient), and call methods on that client to perform operations. The SDK manages request signing, retries via circuitbreaker, and response parsing automatically.
Use it for:
- Automate provisioning and management of OCI compute instances, networks, and storage from Python scripts or applications.
- Query OCI identity and access control to audit users, groups, and permissions programmatically.
- Build monitoring or cost-analysis tools that pull data from OCI services via the SDK.
- Integrate OCI resource management into CI/CD pipelines or infrastructure-as-code workflows.
- Develop multi-cloud or hybrid-cloud applications that interact with OCI alongside other cloud providers.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Python SDK for Oracle Cloud Infrastructure that provides programmatic access to OCI services through service clients and configuration management.
Yes. The SDK is production-stable, actively maintained (released 3 days ago), has low install friction, and carries no known vulnerabilities. It is the canonical way to interact with OCI from Python. Install it if you need to programmatically manage OCI resources or integrate OCI services into Python applications. The dual permissive license poses no restriction.
Install
oci on PyPI
pip
pip install ociuv
uv add ocipoetry
poetry add ociInstalling oci
Before you install
Low install friction with a pure-wheel distribution. Actively maintained with a release 3 days old. Depends on 10 well-established runtime libraries including cryptography, urllib3, and PyJWT for secure communication and authentication.
License in practice
Dual-licensed under UPL 1.0 or Apache 2.0, both permissive. You may choose either license, giving flexibility for commercial or open-source projects without copyleft obligations.
Quickstart
pip install oci
import oci
config = oci.config.from_file('~/.oci/config', 'DEFAULT')
identity = oci.identity.IdentityClient(config)
user = identity.get_user(config['user']).data
Requires a valid OCI configuration file at ~/.oci/config with credentials and tenancy information; see Oracle's installation guide for setup.
Verify before relying
- Whether the SDK supports all current OCI service offerings or if some services require separate/newer versions.
- Performance characteristics and rate-limiting behavior when making many concurrent API calls.
- Whether circuitbreaker dependency is used for automatic retry/backoff or if manual error handling is required.
Package facts
| License | Universal Permissive License 1.0 or Apache License 2.0 (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 10 — certifi, cryptography, pyOpenSSL, python-dateutil, pytz, configparser, urllib3, PyJWT, circuitbreaker, crc32c |
| Maintenance | actively maintained — 3 days since the last release |
| First released | |
| Downloads | 12,485,129/month — #1,317 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: oci-2.184.1-py3-none-any.whl
Tags
More Internet packages
Botocore provides low-level, data-driven access…
permissive · top 100 on PyPI
aiobotocoreProvides an async client for AWS services using…
permissive · top 100 on PyPI
pydanticPydantic validates Python data structures…
permissive · top 100 on PyPI
filelockProvides a platform-independent file locking…
permissive · top 100 on PyPI
fastapiFastAPI is a Python web framework for building…
permissive · top 100 on PyPI
googleapis-common-protosProvides common Protocol Buffer message…
permissive · top 100 on PyPI
borneoPython SDK for connecting to Oracle NoSQL…
unclear · top 15,000 on PyPI
oci-cliCommand-line interface for managing Oracle…
permissive · top 5,000 on PyPI
oci-openaiProvides OpenAI-compatible Python clients for…
unclear · top 15,000 on PyPI
ocifsProvides a fsspec-compatible filesystem…
unclear · top 15,000 on PyPI
stackit-iaasProvides Python bindings to create and modify…
permissive · top 15,000 on PyPI
coherePython SDK for accessing Cohere's language…
permissive · top 1,000 on PyPI
cx-Oraclecx_Oracle provides a Python interface to Oracle…
permissive · top 5,000 on PyPI
orasORAS Python is an SDK that lets you push OCI…
permissive · top 5,000 on PyPI
langchain-ociIntegrates LangChain with Oracle Cloud…
unclear · top 15,000 on PyPI
evergreen.pyA Python client library for the Evergreen API…
permissive · top 5,000 on PyPI