manila/api-ref/source/user-messages.inc
Alex Meade dd630c3929 User Messages
For quite some time, OpenStack services have wanted to be able to send
messages to API end users (by user I do not mean the operator, but the
user that is interacting with the client).

This patch implements basic user messages with the following APIs.
GET /messages
GET /messages/<message_id>
DELETE /messages/<message_id>

Implements the basic /messages resource and tempest tests
The patch is aligned with related cinder patch where possible:
I8a635a07ed6ff93ccb71df8c404c927d1ecef005

DocImpact
APIImpact

Needed-By: I5ffb840a271c518f62ee1accfd8e20a97f45594d
Needed-By: I9ce096eebda3249687268e361b7141dea4032b57
Needed-By: Ic7d25a144905a39c56ababe8bd666b01bc0d0aef

Partially-implements: blueprint user-messages
Co-Authored-By: Jan Provaznik <jprovazn@redhat.com>
Change-Id: Ia0cc524e0bfb2ca5e495e575e17e9911c746690b
2017-07-13 13:05:57 +02:00

120 lines
2.4 KiB
ReStructuredText

.. -*- rst -*-
==============================
User messages (since API 2.37)
==============================
Lists, shows and deletes user messages.
List user messages
==================
.. rest_method:: GET /v2/{tenant_id}/messages
Lists all user messages.
Normal response codes: 200
Error response codes: badRequest(400), unauthorized(401), forbidden(403)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
- limit: limit
- offset: offset
- sort_key: sort_key_messages
- sort_dir: sort_dir
- action_id: action_id
- detail_id: detail_id
- message_level: message_level
- project_id: project_id_messages
- request_id: request_id
- resource_id: resource_id
- resource_type: resource_type
Response parameters
-------------------
.. rest_parameters:: parameters.yaml
- action_id: action_id_body
- detail_id: detail_id_body
- message_level: message_level_body
- project_id: project_id_messages_body
- request_id: request_id_body
- resource_id: resource_id_body
- resource_type: resource_type_body
- message_members_links: message_members_links
Response example
----------------
.. literalinclude:: samples/user-messages-list-response.json
:language: javascript
Show user message details
=========================
.. rest_method:: GET /v2/{tenant_id}/messages/{message_id}
Shows details for a user message.
Normal response codes: 200
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
itemNotFound(404)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
- message_id: message_id
Response parameters
-------------------
.. rest_parameters:: parameters.yaml
- action_id: action_id_body
- detail_id: detail_id_body
- message_level: message_level_body
- project_id: project_id_messages_body
- request_id: request_id_body
- resource_id: resource_id_body
- resource_type: resource_type_body
- message_links: message_links
Response example
----------------
.. literalinclude:: samples/user-message-show-response.json
:language: javascript
Delete message
==============
.. rest_method:: DELETE /v2/{tenant_id}/messages/{message_id}
Deletes a user message.
Normal response codes: 202
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
itemNotFound(404)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
- message_id: message_id