Querying a List of Application Template Versions
Function
This API is used to query a list of application template versions.
URI
GET /v2/{project_id}/edgemgr/apps/{app_id}/versions?{limit=xxx,offset=xxx}
Parameter |
Mandatory |
Description |
---|---|---|
project_id |
Yes |
Project ID. For details about how to obtain a project ID, see Obtaining a Project ID. |
app_id |
Yes |
Application template ID. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
limit |
No |
String |
Number of records displayed on each page. The value range is 1–1000. The default value is 1000. |
offset |
No |
String |
Start position for a query. The value is a non-negative integer. The default value is 0. |
- If no query parameter is specified, all application versions of an account are returned.
- If multiple query parameters are specified, the application versions that meet all the specified query parameters are returned.
Request
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
Content-Type |
Yes |
String |
Message body type (format). The default value application/json is recommended. |
X-Auth-Token |
Yes |
String |
User token. The token can be obtained by calling the IAM API used to obtain a user token. The value of X-Subject-Token in the response header is the user token. |
Response
Response parameters
Parameter |
Type |
Description |
---|---|---|
versions |
Array of Table 17 objects |
Application version details. |
count |
Integer |
Number of application versions that meet the conditions. |
Example response
{ "count": 1, "versions": [ { "envs": [], "created_at": "2018-07-26T07:31:29+08:00", "updated_at": null, "version": "v1", "image_url": "busybox:latest", "volumes": [], "npu_type": "", "readiness_probe": null, "configs": { "host_network": true, "restart_policy": "Always", "privileged": false }, "project_id": "{project_id}", "liveness_probe": null, "id": "bc35aaff-bdd8-49e8-ace0-a25be2b09380", "resources": { "requests": { "cpu": 0.25, "memory": 512 }, "limits": { "cpu": 1, "memory": 512 } } } ] }
Error Codes
For details, see Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot