2016-04-12 09:03:46 -04:00
|
|
|
.. -*- rst -*-
|
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
==============
|
|
|
|
API Versions
|
|
|
|
==============
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
In order to bring new features to users over time, the Nova API
|
|
|
|
supports versioning. There are two kinds of versions in Nova.
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
- ''major versions'', which have dedicated urls
|
|
|
|
- ''microversions'', which can be requested through the use of the
|
2016-11-29 12:31:46 -05:00
|
|
|
``X-OpenStack-Nova-API-Version`` header, or since microversion 2.27
|
2016-03-31 17:16:51 +01:00
|
|
|
the ``OpenStack-API-Version`` header may also be used.
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-11-29 12:31:46 -05:00
|
|
|
For more details about Microversions, please reference:
|
2016-04-21 10:52:04 +08:00
|
|
|
`Microversions
|
2019-07-22 18:08:40 +02:00
|
|
|
<https://docs.openstack.org/api-guide/compute/microversions.html>`_
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-11-11 15:05:09 +08:00
|
|
|
.. note:: The maximum microversion supported by each release varies.
|
|
|
|
Please reference:
|
|
|
|
`API Microversion History
|
2017-09-06 22:01:01 +02:00
|
|
|
<https://docs.openstack.org/nova/latest/reference/api-microversion-history.html>`__
|
2016-11-11 15:05:09 +08:00
|
|
|
for API microversion history details.
|
|
|
|
|
2016-06-02 08:50:03 -04:00
|
|
|
The Version APIs work differently from other APIs as they *do not*
|
|
|
|
require authentication.
|
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
List All Major Versions
|
|
|
|
=======================
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. rest_method:: GET /
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
This fetches all the information about all known major API versions in
|
|
|
|
the deployment. Links to more specific information will be provided
|
|
|
|
for each API version, as well as information about supported min and
|
|
|
|
max microversions.
|
|
|
|
|
2016-04-21 10:52:04 +08:00
|
|
|
Normal Response Codes: 200
|
2016-04-12 09:03:46 -04:00
|
|
|
|
|
|
|
Response
|
2016-04-14 13:10:59 -04:00
|
|
|
--------
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- versions: versions
|
|
|
|
- id: version_id
|
|
|
|
- links: links
|
|
|
|
- min_version: version_min
|
2017-06-19 13:13:09 +09:00
|
|
|
- status: version_status
|
|
|
|
- updated: updated_version
|
|
|
|
- version: version_max
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
|
|
|
|
Response Example
|
|
|
|
----------------
|
|
|
|
|
|
|
|
This demonstrates the expected response from a bleeding edge server
|
|
|
|
that supports up to the current microversion. When querying OpenStack
|
|
|
|
environments you will typically find the current microversion on the
|
|
|
|
v2.1 API is lower than listed below.
|
|
|
|
|
|
|
|
.. literalinclude:: /../../doc/api_samples/versions/versions-get-resp.json
|
2016-04-12 09:03:46 -04:00
|
|
|
:language: javascript
|
|
|
|
|
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
Show Details of Specific API Version
|
|
|
|
====================================
|
|
|
|
|
2018-11-08 16:00:12 +08:00
|
|
|
.. rest_method:: GET /{api_version}/
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-12-21 21:50:55 +08:00
|
|
|
This gets the details of a specific API at its root. Nearly all this
|
2016-04-14 14:44:13 -04:00
|
|
|
information exists at the API root, so this is mostly a redundant
|
|
|
|
operation.
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. TODO(sdague) we should probably deprecate this call as everything
|
|
|
|
that's needed is really in the root now
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
Normal Response Codes: 200
|
2016-04-12 09:03:46 -04:00
|
|
|
|
|
|
|
Request
|
2016-04-14 13:10:59 -04:00
|
|
|
-------
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. rest_parameters:: parameters.yaml
|
|
|
|
|
|
|
|
- api_version: api_version
|
|
|
|
|
2016-04-12 09:03:46 -04:00
|
|
|
Response
|
2016-04-14 13:10:59 -04:00
|
|
|
--------
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. rest_parameters:: parameters.yaml
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
- version: version
|
|
|
|
- id: version_id
|
|
|
|
- links: links
|
2017-06-19 13:13:09 +09:00
|
|
|
- media-types: media_types
|
2016-04-14 14:44:13 -04:00
|
|
|
- min_version: version_min
|
2017-06-19 13:13:09 +09:00
|
|
|
- status: version_status
|
|
|
|
- updated: updated_version
|
|
|
|
- version: version_max
|
2016-04-12 09:03:46 -04:00
|
|
|
|
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
Response Example
|
|
|
|
----------------
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2018-11-08 16:00:12 +08:00
|
|
|
This is an example of a ``GET /v2.1/`` on a relatively current server.
|
2016-04-12 09:03:46 -04:00
|
|
|
|
2016-04-14 14:44:13 -04:00
|
|
|
.. literalinclude:: /../../doc/api_samples/versions/v21-version-get-resp.json
|
2016-04-12 09:03:46 -04:00
|
|
|
:language: javascript
|