heat/api-ref/source/v1/stack-templates.inc
tengqm 654b3344b5 Fix problems left in api-ref
This patch fixes the known problems in api-ref docs:

- the patch update stack api is now documented;
- the patch update preview api is now documented;
- the unused parameters in 'parameters.yaml' are all removed;
- some incorrect references of parameters are fixed.

Change-Id: I89457c98f542304df788636e4ad3ace5d2e7deb5
2016-08-23 04:16:03 -04:00

154 lines
2.6 KiB
ReStructuredText

.. -*- rst -*-
=========
Templates
=========
List template versions
======================
.. rest_method:: GET /v1/{tenant_id}/template_versions
Lists all available template versions.
Response Codes
--------------
.. rest_status_code:: success status.yaml
- 200
.. rest_status_code:: error status.yaml
- 400
- 401
- 404
- 500
Request Parameters
------------------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id
Response Parameters
-------------------
.. rest_parameters:: parameters.yaml
- X-Openstack-Request_id: request_id
- template_versions: template_versions
- alias: template_version_alias
- type: template_type
- version: template_version
Response Example
----------------
.. literalinclude:: samples/template-versions-response.json
:language: javascript
List template functions
=======================
.. rest_method:: GET /v1/{tenant_id}/template_versions/{template_version}/functions
Lists all available functions for a template version.
Response Codes
--------------
.. rest_status_code:: success status.yaml
- 200
.. rest_status_code:: error status.yaml
- 400
- 401
- 404
- 500
Request Parameters
------------------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id
- template_version: template_version_url
Reponse Parameters
------------------
.. rest_parameters:: parameters.yaml
- X-Openstack-Request-Id: request_id
- template_functions: template_functions
- description: function_description
- functions: functions
Response Example
----------------
.. literalinclude:: samples/template-functions-list-response.json
:language: javascript
Validate template
=================
.. rest_method:: POST /v1/{tenant_id}/validate
Validates a template.
Response Codes
--------------
.. rest_status_code:: success status.yaml
- 200
.. rest_status_code:: error status.yaml
- 400
- 500
Request Parameters
------------------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id
- environment: environment
- environment_files: environment_files
- files: files
- ignore_errors: ignore_errors
- show_nested: show_nested
- template: template
- template_url: template_url
Request Example
---------------
.. literalinclude:: samples/template-validate-request.json
:language: javascript
Response Parameters
-------------------
.. rest_parameters:: parameters.yaml
- X-Openstack-Request-Id: request_id
- Description: Description
- ParameterGroups: ParameterGroups
- Parameters: Parameters
Response Example
----------------
.. literalinclude:: samples/template-validate-response.json
:language: javascript