zrhoffman commented on a change in pull request #4464: Rework riak/bucket/:bucket/key/:key/value URL: https://github.com/apache/trafficcontrol/pull/4464#discussion_r387821562
########## File path: docs/source/api/v1/riak_bucket_bucket_key_key_value.rst ########## @@ -0,0 +1,92 @@ +.. +.. +.. Licensed under the Apache License, Version 2.0 (the "License"); +.. you may not use this file except in compliance with the License. +.. You may obtain a copy of the License at +.. +.. http://www.apache.org/licenses/LICENSE-2.0 +.. +.. Unless required by applicable law or agreed to in writing, software +.. distributed under the License is distributed on an "AS IS" BASIS, +.. WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +.. See the License for the specific language governing permissions and +.. limitations under the License. +.. + +.. _to-api-riak-bucket-bucket-key-key-values: + +********************************************* +``riak/bucket/{{bucket}}/key/{{key}}/values`` +********************************************* +Retrieves the `object <https://docs.riak.com/riak/kv/latest/learn/concepts/keys-and-objects/index.html#objects>`_ stored under a given `key <https://docs.riak.com/riak/kv/latest/learn/concepts/keys-and-objects/index.html#keys>`_ from a given `bucket <https://docs.riak.com/riak/kv/latest/learn/concepts/buckets/index.html>`_ in :ref:`tv-overview`. + +.. deprecated:: ATCv4 + Use the ``GET`` method of :ref:`to-api-vault-bucket-bucket-key-key-value` instead. + +``GET`` +======= +:Auth. Required: Yes +:Roles Required: "admin" +:Response Type: Object + +Request Structure +----------------- +.. table:: Request Path Parameters + + +--------+------------------------------------------+ + | Name | Description | + +========+==========================================+ + | bucket | The bucket that the key is stored under | + +--------+------------------------------------------+ + | key | The key that the object is stored under | + +--------+------------------------------------------+ + +.. code-block:: http + :caption: Request Example + + GET /api/2.0/riak/bucket/ssl/key/demo1-latest/values HTTP/1.1 + User-Agent: python-requests/2.22.0 + Accept-Encoding: gzip, deflate + Accept: */* + Connection: keep-alive + Cookie: mojolicious=... + +Response Structure +------------------ +The response structure varies according to what is stored. Top-level keys will always be ``String`` type, but the values can be any type. + +.. code-block:: http + :caption: Response Example + + HTTP/1.1 200 OK + Access-Control-Allow-Credentials: true + Access-Control-Allow-Headers: Origin, X-Requested-With, Content-Type, Accept, Set-Cookie, Cookie + Access-Control-Allow-Methods: POST,GET,OPTIONS,PUT,DELETE + Access-Control-Allow-Origin: * + Content-Encoding: gzip + Content-Type: application/json + Set-Cookie: mojolicious=...; Path=/; Expires=Sun, 23 Feb 2020 23:29:27 GMT; Max-Age=3600; HttpOnly + Whole-Content-Sha512: LUq4+MUCgIqxBWqbuA/Pbsdq5Qfs7vPUcZ0Cu2FcOUyP0X8xXit3BJrdOLA+dSSJ3tSQ7Qij1+0ahzuouuLT7Q== + X-Server-Name: traffic_ops_golang/ + Date: Sun, 23 Feb 2020 22:29:27 GMT + Transfer-Encoding: chunked + + { + "alerts": [ + { + "text": "This endpoint is deprecated, please use GET /vault/bucket/:bucket/key/:key/value instead", Review comment: Should be values, not value ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
