skillfed

osc-lib

OpenStackClient Library

osc-lib v4.7.0 868.2K downloads/30d#4,852 on PyPI
Permissive license Apache-2.0 Active released

What it is and what it does

osc-lib is a library extracted from OpenStackClient that provides reusable components for building OpenStack command-line tools and plugins. It bundles common modules for authentication, command handling, API interaction, logging, and CLI utilities that were previously embedded in the main OpenStackClient codebase.

Developers use osc-lib to write OSC plugins or standalone CLI tools that need to interact with OpenStack APIs. It abstracts away authentication (via keystoneauth1), session management, command framework scaffolding (via cliff), and common utilities, so plugin authors can focus on their specific command logic rather than reinventing OpenStack integration plumbing.

Use it for:

  • Writing custom OpenStackClient plugins that extend the base OSC command set for domain-specific operations
  • Building standalone command-line tools that need OpenStack API authentication and session handling without reimplementing it
  • Migrating code from the main OpenStackClient repository to a shared plugin architecture using osc-lib's common modules
  • Implementing CLI commands that leverage osc-lib's command framework and argument parsing utilities

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

osc-lib provides a shared library of common modules and utilities for building OpenStackClient (OSC) plugins and command-line tools that interact with OpenStack APIs.

Yes, if you are building OpenStackClient plugins or CLI tools for OpenStack. The library is actively maintained, has no known vulnerabilities, and low install friction. It is not a general-purpose package—install it only as a dependency for OSC plugin development or when explicitly required by OpenStack tooling.

Install

osc-lib on PyPI

pip

pip install osc-lib

uv

uv add osc-lib

poetry

poetry add osc-lib

Installing osc-lib

Before you install

Low install friction with a pure-Python wheel distribution. Actively maintained with a release 35 days ago. Requires Python 3.11 or later and depends on established OpenStack libraries (keystoneauth1, openstacksdk) and common utilities (cliff, stevedore, oslo packages).

License in practice

Licensed under Apache 2.0 (permissive), allowing use in commercial and proprietary projects with minimal restrictions beyond attribution and license inclusion.

Quickstart

pip install osc-lib

from osc_lib.command import command
from osc_lib.utils import columns

class MyCommand(command.Command):
    pass

Requires Python 3.11 or later; designed for building OSC plugins rather than standalone CLI use.

Verify before relying

  • Whether osc-lib is suitable for direct end-user CLI use or primarily intended as a plugin/framework dependency for OpenStackClient extensions

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (>=3.11)
Install friction low — pure-Python wheel
Runtime dependencies 8 — cliff, keystoneauth1, openstacksdk, oslo.i18n, oslo.utils, pbr, requests, stevedore
Maintenance actively maintained — 35 days since the last release
First released
Downloads 868,244/month — #4,852 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: osc_lib-4.7.0-py3-none-any.whl

Development Status :: 5 - Production/StableEnvironment :: OpenStackIntended Audience :: DevelopersOperating System :: POSIX :: LinuxProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Typing :: Typed

Tags

openstack client libraryosc plugin frameworkopenstack cli utilitiescommand-line openstack toolsopenstack api client base
openstackcli-frameworkplugin-development

More Application Frameworks packages

fastapi

FastAPI is a Python web framework for building…

permissive · top 100 on PyPI

annotated-doc

Provides a way to document function parameters,…

permissive · top 100 on PyPI

textual

Textual is a Python framework for building…

permissive · top 100 on PyPI

typer

Typer builds command-line applications from…

permissive · top 1,000 on PyPI

mcp

Build and connect to Model Context Protocol…

permissive · top 1,000 on PyPI

Werkzeug

Werkzeug is a WSGI utility library providing…

permissive · top 1,000 on PyPI

osc-placement

Provides a command-line interface to the…

permissive · top 15,000 on PyPI

python-openstackclient

A unified command-line client for OpenStack…

permissive · top 5,000 on PyPI

python-swiftclient

Python client library for OpenStack Object…

permissive · top 15,000 on PyPI

python-octaviaclient

python-octaviaclient is an OpenStack Client…

permissive · top 15,000 on PyPI

python-zaqarclient

Python client library for the OpenStack Zaqar…

permissive · top 15,000 on PyPI

os-client-config

Collects and manages OpenStack cloud client…

permissive · top 15,000 on PyPI

python-troveclient

Python client library and command-line tool for…

permissive · top 15,000 on PyPI

python-heatclient

Python client library and command-line tool for…

permissive · top 15,000 on PyPI

python-neutronclient

Python bindings and client library for the…

permissive · top 15,000 on PyPI

python-glanceclient

Python client library and command-line tool for…

permissive · top 15,000 on PyPI