From 941bd74be7da56bacad1b59cf4ec02f44c4f0104 Mon Sep 17 00:00:00 2001 From: Jude Cross Date: Mon, 30 Apr 2018 17:21:32 -0700 Subject: [PATCH] Update docs to properly describe delete with pop This patch updates the documentation for the Zaqar API to properly describe when a delete is invoked with the pop query parameter. Change-Id: Id586797eb4707f5db9d751c80035ba07270627c3 Closes-Bug: 1768157 --- api-ref/source/messages.inc | 13 +++++++++++-- .../samples/messages-delete-bypop-response.json | 16 ++++++++++++++++ 2 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 api-ref/source/samples/messages-delete-bypop-response.json diff --git a/api-ref/source/messages.inc b/api-ref/source/messages.inc index fd727ae22..b84d3c895 100644 --- a/api-ref/source/messages.inc +++ b/api-ref/source/messages.inc @@ -249,6 +249,7 @@ Response codes .. rest_status_code:: success status.yaml + - 200 - 204 @@ -263,6 +264,8 @@ Response codes Request Parameters ------------------ +This operation does not accept a request body. + .. rest_parameters:: parameters.yaml - queue_name: queue_name @@ -270,8 +273,14 @@ Request Parameters - pop: pop -This operation does not accept a request body and does not return a response -body. +Response Example +---------------- + +This operation only returns a response body when the ``pop`` query parameter +is used. + +.. literalinclude:: samples/messages-delete-bypop-response.json + :language: javascript Get A Specific Message diff --git a/api-ref/source/samples/messages-delete-bypop-response.json b/api-ref/source/samples/messages-delete-bypop-response.json new file mode 100644 index 000000000..9c922f17e --- /dev/null +++ b/api-ref/source/samples/messages-delete-bypop-response.json @@ -0,0 +1,16 @@ +{ + "messages": [ + { + "body": { + "current_bytes": "0", + "event": "BackupProgress", + "total_bytes": "99614720" + }, + "age": 443, + "claim_count": 1, + "claim_id": "51db7067821e727dc24df754", + "id": "578f0055508f153f256f717f", + "ttl": 3600 + } + ] +} \ No newline at end of file