Querying Images (Discarded)
Function
This API is used to query all images.
This API has been discarded. Use the API described in Querying Images (Native OpenStack API).
URI
GET /v2.1/{project_id}/images?name={name}&status={status}&changes-since={changes-since}&minRam={minRam}&minDisk={inDisk}
| Parameter | Mandatory | Description |
|---|---|---|
| project_id | Yes | Specifies the project ID. For details about how to obtain the ID, see Obtaining a Project ID. |
Parameters in the following table can be used as URI parameters to filter query results. Usage: /v2/{project_id}/images? name ={name}&status={status}
Table 2 describes the query parameters.
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| name | No | String | Specifies the image name. |
| status | No | String | Specifies the image status. You cannot query images when the value is set to deleted. The value depends on the status in Glance. Table 3 shows the mapping relationship of image status in Nova and Glance. |
| changes-since | No | String | Specifies the images modified after the changes-since time point. The parameter is in ISO 8601 time format, for example, 2013-06-09T06:42:18Z. |
| minRam | No | Integer | Specifies the minimum memory size in MiB required by the image. |
| minDisk | No | Integer | Specifies the minimum disk size in GiB required by the image. |
| Image Status in Glance | Image Status in Nova |
|---|---|
| queued | saving |
| saving | saving |
| active | active |
| deleted | deleted |
Request
None
Response
Table 4 describes the response parameters.
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| id | Yes | String | Specifies the image ID in UUID format. |
| links | Yes | Array of objects | Specifies the shortcut link of the image. |
| name | Yes | String | Specifies the image name. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| href | Yes | String | Specifies the URL of the next page when you query images in pages. |
| rel | Yes | String | Specifies the query direction when you query images in pages. |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| href | Yes | String | Specifies the link of the corresponding resource. |
| rel | Yes | String | The value can be:
|
| type | No | String | The type attribute provides a hint as to the type of representation to expect when following the link. |
Example Request
GET https://{endpoint}/v2.1/9c53a566cb3443ab910cf0daebca90c4/images Example Response
{
"images": [
{
"id": "ee10f19c-503c-44af-af2f-73d5e42f7a17",
"links": [
{
"href": "http://xxx/v2/d9ebe43510414ef590a4aa158605329e/images/ee10f19c-503c-44af-af2f-73d5e42f7a17",
"rel": "self"
},
{
"href": "http://xxx/d9ebe43510414ef590a4aa158605329e/images/ee10f19c-503c-44af-af2f-73d5e42f7a17",
"rel": "bookmark"
},
{
"href": "http://xxx/d9ebe43510414ef590a4aa158605329e/images/ee10f19c-503c-44af-af2f-73d5e42f7a17",
"rel": "alternate",
"type": "application/vnd.openstack.image"
}
],
"name": "image1"
}
]
} Returned Values
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.
