Skip to content

Commit

Permalink
API Ref: update server_id params
Browse files Browse the repository at this point in the history
- Update server_id params to be of type path.
- Cleaned up os-getConsoleOutput action string.
- Made empty response body description more consistent.
  Review and change as needed.

Implements: bp/api-ref-in-rst-ocata

Change-Id: Ie1e299d2b93188240b18138eba9f5b908a1078a4
  • Loading branch information
kbhawkey committed Nov 11, 2016
1 parent f21ba22 commit 168a500
Show file tree
Hide file tree
Showing 13 changed files with 168 additions and 182 deletions.
3 changes: 1 addition & 2 deletions api-ref/source/diagnostics.inc
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path

Response
--------
Expand Down
9 changes: 4 additions & 5 deletions api-ref/source/ips.inc
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Request

.. rest_parameters:: parameters.yaml

- server_id: server_id
- server_id: server_id_path

Response
--------
Expand All @@ -39,7 +39,7 @@ Response
- addr: ip_address
- version: version_ip

**Example List Ips: JSON response**
**Example List Ips**

.. literalinclude:: ../../doc/api_samples/server-ips/server-ips-resp.json
:language: javascript
Expand All @@ -64,7 +64,7 @@ Request

.. rest_parameters:: parameters.yaml

- server_id: server_id
- server_id: server_id_path
- network_label: network_label

Response
Expand All @@ -76,8 +76,7 @@ Response
- addr: ip_address
- version: version_ip

**Example Show Ip Details: JSON response**
**Example Show Ip Details**

.. literalinclude:: ../../doc/api_samples/server-ips/server-ips-network-resp.json
:language: javascript

30 changes: 15 additions & 15 deletions api-ref/source/metadata.inc
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path

Response
--------
Expand All @@ -38,7 +38,7 @@ Response

- metadata: metadata_object

**Example List All Metadata:**
**Example List All Metadata**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-all-resp.json
:language: javascript
Expand All @@ -65,10 +65,10 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- metadata: metadata_object

**Example Update Metadata Items:**
**Example Update Metadata Items**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-all-req.json
:language: javascript
Expand All @@ -80,7 +80,7 @@ Response

- metadata: metadata_object

**Example Update Metadata Items:**
**Example Update Metadata Items**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-all-resp.json
:language: javascript
Expand All @@ -107,10 +107,10 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- metadata: metadata_object

**Example Create Or Replace Metadata Items:**
**Example Create Or Replace Metadata Items**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-all-req.json
:language: javascript
Expand All @@ -122,7 +122,7 @@ Response

- metadata: metadata_object

**Example Create Or Replace Metadata Items:**
**Example Create Or Replace Metadata Items**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-all-resp.json
:language: javascript
Expand All @@ -146,7 +146,7 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- key: key

Response
Expand All @@ -156,7 +156,7 @@ Response

- meta: metadata_object

**Example Show Metadata Item Details:**
**Example Show Metadata Item Details**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-resp.json
:language: javascript
Expand All @@ -183,10 +183,10 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- key: key

**Example Create Or Update Metadata Item:**
**Example Create Or Update Metadata Item**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-req.json
:language: javascript
Expand All @@ -198,7 +198,7 @@ Response

- meta: metadata_object

**Example Create Or Update Metadata Item:**
**Example Create Or Update Metadata Item**

.. literalinclude:: ../../doc/api_samples/server-metadata/server-metadata-resp.json
:language: javascript
Expand All @@ -222,10 +222,10 @@ Request
.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- key: key

Response
--------

There is no body content for the response of a successful DELETE action.
If successful, this method does not return content in the response body.
20 changes: 7 additions & 13 deletions api-ref/source/os-consoles.inc
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id

- server_id: server_id_path

Response
--------
Expand Down Expand Up @@ -60,14 +58,12 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id

- server_id: server_id_path

Response
--------

No body content is returned on a successful POST.
If successful, this method does not return a response body.


Show Console Details
Expand All @@ -86,11 +82,9 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- console_id: console_id


Response
--------

Expand Down Expand Up @@ -128,14 +122,14 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- console_id: console_id


Response
--------

There is no body content for the response of a successful DELETE query
If successful, this method does not return a response body.


Show Console Connection Information
Expand Down
10 changes: 4 additions & 6 deletions api-ref/source/os-server-password.inc
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,7 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path

Response
--------
Expand All @@ -45,7 +44,7 @@ Response

- password: password

**Example Show Server Password: JSON response**
**Example Show Server Password**

.. literalinclude:: ../../doc/api_samples/os-server-password/get-password-resp.json
:language: javascript
Expand Down Expand Up @@ -73,10 +72,9 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path

Response
--------

There is no body content for the response of a successful DELETE action.
If successful, this method does not return content in the response body.
7 changes: 3 additions & 4 deletions api-ref/source/os-services.inc
Original file line number Diff line number Diff line change
Expand Up @@ -221,8 +221,8 @@ Delete Compute Service

.. rest_method:: DELETE /os-services/{service_id}

Deletes a Compute service. If it's a nova-compute service, then corresponding host will
removed from all the host aggregates as well.
Deletes a Compute service. If it's a nova-compute service, then the
corresponding host will be removed from all the host aggregates as well.

Normal response codes: 204

Expand All @@ -233,10 +233,9 @@ Request

.. rest_parameters:: parameters.yaml


- service_id: service_id_path

Response
--------

There is no body content for the response of a successful DELETE query
If successful, this method does not return content in the response body.
4 changes: 2 additions & 2 deletions api-ref/source/server-security-groups.inc
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Request

.. rest_parameters:: parameters.yaml

- server_id: server_id
- server_id: server_id_path

Response
--------
Expand All @@ -37,7 +37,7 @@ Response
- tenant_id: tenant_id_body


**Example List security groups by server: JSON response**
**Example List security groups by server**

.. literalinclude:: ../../doc/api_samples/os-security-groups/server-security-groups-list-resp.json
:language: javascript
17 changes: 9 additions & 8 deletions api-ref/source/servers-action-console-output.inc
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
.. -*- rst -*-
Show Console Output (Os-Getconsoleoutput Action)
Show Console Output (os-getConsoleOutput Action)
================================================

.. rest_method:: POST /servers/{server_id}/action

Shows console output for a server instance.

This returns the text of the console since boot in a REST
response. The console content may be large, you can limit it with the
optional ``length`` parameter.
This API returns the text of the console since boot.
The content returned may be large. Limit the lines of console
text, beginning at the tail of the content, by setting
the optional ``length`` parameter in the request body.

Normal response codes: 200

Expand All @@ -21,14 +22,14 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id_path
- os-getConsoleOutput: os-getConsoleOutput
- length: length

**Example Get console output**
**Example Show Console Output (os-getConsoleOutput Action)**

This requests the last 50 lines of the server in question.
This example requests the last 50 lines of console content
from the specified server.

.. literalinclude:: ../../doc/api_samples/os-console-output/console-output-post-req.json
:language: javascript
Expand All @@ -40,7 +41,7 @@ Response

- output: console_output

**Example Get console output: JSON response**
**Example Show Console Output (os-getConsoleOutput Action)**

.. literalinclude:: ../../doc/api_samples/os-console-output/console-output-post-resp.json
:language: javascript
7 changes: 3 additions & 4 deletions api-ref/source/servers-action-evacuate.inc
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ Request

.. rest_parameters:: parameters.yaml


- server_id: server_id
- server_id: server_id_path
- evacuate: evacuate
- host: host
- adminPass: adminPass_evacuate_rebuild_request
Expand All @@ -31,7 +30,7 @@ Request

|
**Example Evacuate Server (evacuate Action):**
**Example Evacuate Server (evacuate Action)**

.. literalinclude:: ../../doc/api_samples/os-evacuate/server-evacuate-req.json
:language: javascript
Expand All @@ -46,7 +45,7 @@ Response

|
**Example Evacuate Server (evacuate Action):**
**Example Evacuate Server (evacuate Action)**

.. literalinclude:: ../../doc/api_samples/os-evacuate/server-evacuate-resp.json
:language: javascript
Loading

0 comments on commit 168a500

Please sign in to comment.