OpenKeel: the sovereign French Cloud solution of the inherent group, with a European reach Discover inherent

Reverse-spec · Clients

python-openstackclient — Interactions

Interactions — python-openstackclient — branch stable/2026.2

Branch stable/2026.2 @ 8bb083b83829 — repository https://opendev.org/openstack/python-openstackclient — analysed on 2026-11-01

Database, RabbitMQ and cache: none. All exchanges are outbound HTTP through keystoneauth1, plus local files and stdin. The complete list of operations, per service, is [_rewrite/api-surface_stable-2026.2.md](_rewrite/api-surface_stable-2026.2.md).

1. The three client stacks

StackUsed byCreated atNotes
openstacksdk Proxycompute, network, image, volume, most of identityosc-lib:osc_lib/clientmanager.py:197negotiates microversions; carries most of the behaviour
python-keystoneclientIdentity v2, OAuth1, EC2 credentials, endpoint groups, some lookupsopenstackclient/identity/client.py:44being replaced by the SDK
project HTTP codeobject store; some compute and volume callsopenstackclient/api/object_store_v1.py:35, openstackclient/api/compute_v2.py:29, openstackclient/api/volume_v3.py:29no negotiation; openstackclient/api/api.py:53 wraps the session

All share one keystoneauth session, and therefore one token (osc-lib:osc_lib/clientmanager.py:195). The user agent is python-openstackclient (openstackclient/common/clientmanager.py:40).

2. Keystone

StepRequest [observed]When
DiscoveryGET {auth_url}before authenticating
AuthenticationPOST /v3/auth/tokens, with the password method by defaultbefore the first command needing auth
ResultX-Subject-Token and a body with catalog, expires_at, user, project, roles

The stub shows what the CLI needs from that token: a catalog with public, internal and admin interfaces and a region (openstackclient/shell.py:84, and the stub in the probe). The default interface is public, set with --os-interface (osc-lib:osc_lib/shell.py:274).

Each run authenticates once. The token is not reused between invocations unless a token plugin or a cache is configured [inferred]. A loop of 100 commands therefore costs 100 POST /v3/auth/tokens.

Sample frame

POST /identity/v3/auth/tokens HTTP/1.1
Content-Type: application/json
User-Agent: openstacksdk/… keystoneauth1/5.17.0 python-requests/…

{"auth": {"identity": {"methods": ["password"], "password": {"user": {"name": "admin", "domain": {"name": "Default"}, "password": "***"}}},
          "scope": {"project": {"name": "admin", "domain": {"name": "Default"}}}}}

[Body shape inferred from the keystoneauth plugin; the route is observed.]

3. Service discovery

The SDK reads each service's version document before its first call [observed], and the catalog decides the endpoint.

Service typeDocument readFields required
computeGET /compute/v2.1 or the rootversion, min_version, links, status
block-storage (aliases volume, volumev3, volumev2, block-store)GET /volume/v3same (openstackclient/common/clientmanager.py:171)
networkGET /networkversions[].id, links
imageGET /image (300 accepted)versions[].id, links
identityGET /identity (300 accepted)versions.values[]
object-storenone; the endpoint comes from the catalog (openstackclient/object/client.py:32)

4. Microversions

Requests carry OpenStack-API-Version: <service> <version> [observed].

CaseSent [observed]
no optionthe highest version known by the SDK for that resource, capped by the service: compute 2.100 on servers, 2.88 on hypervisors, 2.81 on aggregates, 2.61 on flavors; volume 3.71, 3.64, 3.55…
--os-compute-api-version 2.1compute 2.1 on every call
legacy callspinned: compute 2.1 on os-agents, os-security-groups, os-networks (openstackclient/api/compute_v2.py:68)
Neutron, Glance, Swift, Keystoneno header
version above the service maximumno request; error before sending (see 02)

Values gated in the code: compute 2.2 to 2.104 (55 values), volume 3.1 to 3.66 (29 values). The list per command is in [_rewrite/client-contract_stable-2026.2.json](_rewrite/client-contract_stable-2026.2.json).

Sample frame [observed]

GET /compute/v2.1/servers/detail?deleted=False HTTP/1.1
OpenStack-API-Version: compute 2.100
X-Auth-Token: stub-token

5. Outbound REST summary

Discovered from the Keystone catalog for every service. Authentication is X-Auth-Token.

Target serviceOperations (observed + static)Example [observed]Timeout / retryErrors handled
Nova (compute)136POST /servers/{id}/actionapi_timeout unset by default (openstacksdk:openstack/config/cloud_region.py:997); connect_retries and status_code_retries per service (openstacksdk:openstack/config/cloud_region.py:775)404 on the first lookup leads to the fallback list; the rest is printed
Neutron (network)293GET /networks?name=xsamesame
Keystone (identity)150GET /users/{id}samesame
Cinder (block-storage)151GET /volumes/detail?name=xsamesame
Glance (image)68GET /images/{id}samesame
Swift (object-store)13HEAD /{container}same; the wrapper has no retry of its own (openstackclient/api/api.py:53)printed

6. Object store detail

OperationRequestSource
create or update a containerPUT /{container}, with X-Container-* headersopenstackclient/api/object_store_v1.py:64
container metadataPOST /{container}openstackclient/api/object_store_v1.py:174
show a containerHEAD /{container}openstackclient/api/object_store_v1.py:185
uploadPUT /{container}/{object} streamed from a fileopenstackclient/api/object_store_v1.py:254
downloadGET with stream=True, 64 KiB chunksopenstackclient/api/object_store_v1.py:378
show an objectHEAD /{container}/{object}openstackclient/api/object_store_v1.py:454
accountHEAD /, POST /openstackclient/api/object_store_v1.py:501, openstackclient/api/object_store_v1.py:494

The account shown is the last part of the endpoint path, not an answer from the service (openstackclient/api/object_store_v1.py:532). A Swift replacement must therefore keep AUTH_<id> at the end of the catalog URL.

7. Other local interactions

InteractionDirectionSource
clouds.yaml, secure.yamlreadosc-lib:osc_lib/shell.py:450
stdin for image dataread when stdin is not a terminalopenstackclient/image/v2/image.py:181
terminal password promptreadopenstackclient/identity/v3/user.py:771, openstackclient/common/project_cleanup.py:33
local files (--file, --rules, object create)readopenstackclient/identity/v3/mapping.py:50, openstackclient/api/object_store_v1.py:253
image save, object savewrite to a file or stdoutopenstackclient/image/v2/image.py:1141, openstackclient/api/object_store_v1.py:386
ssh binaryserver ssh runs it through os.system [not run]openstackclient/compute/v2/server.py:5206
PluginsPython import through stevedoreopenstackclient/common/clientmanager.py:231

Source: reverse-spec-python-openstackclient/03-interactions_stable-2026.2.md. The _rewrite/ and _inventory/ files are not published on the site.