summaryrefslogtreecommitdiff
path: root/api-ref
diff options
context:
space:
mode:
authorTim Burke <tim.burke@gmail.com>2016-09-16 17:21:00 -0700
committerTim Burke <tim.burke@gmail.com>2016-09-19 15:47:20 -0700
commitd40ff7098b3dd13b5ea846b86b9e8461ac1875b1 (patch)
tree55e82bb7b1a4d75266c2d32d54636cd5686e4203 /api-ref
parent5126cc844aaed9adfc72d87dd5a4fed732571725 (diff)
downloadswift-d40ff7098b3dd13b5ea846b86b9e8461ac1875b1.tar.gz
Clean up api-ref examples
If we're going to talk about replacing an object, we should use the same object name as the previous example. Including a non-zero content-length on PUT but not providing a body will timeout. Not including the '-' in '-H' will make curl complain: Rebuilt URL to: H/ * Could not resolve host: H * Closing connection 1 201 Created responses have content-length of zero, not 116. Change-Id: Ifd878559ee4036e4893221c7968f53021f38e236
Diffstat (limited to 'api-ref')
-rw-r--r--api-ref/source/storage-object-services.inc14
1 files changed, 7 insertions, 7 deletions
diff --git a/api-ref/source/storage-object-services.inc b/api-ref/source/storage-object-services.inc
index 5db102016..1434842f0 100644
--- a/api-ref/source/storage-object-services.inc
+++ b/api-ref/source/storage-object-services.inc
@@ -178,7 +178,7 @@ Example requests and responses:
::
- curl -i $publicURL/janeausten/helloworld.txt -X PUT -H "Content-Length: 1" -H "Content-Type: text/html; charset=UTF-8" -H "X-Auth-Token: $token"
+ curl -i $publicURL/janeausten/helloworld.txt -X PUT -d "Hello" -H "Content-Type: text/html; charset=UTF-8" -H "X-Auth-Token: $token"
@@ -187,8 +187,8 @@ Example requests and responses:
HTTP/1.1 201 Created
Last-Modified: Fri, 17 Jan 2014 17:28:35 GMT
- Content-Length: 116
- Etag: d41d8cd98f00b204e9800998ecf8427e
+ Content-Length: 0
+ Etag: 8b1a9953c4611296a827abf8c47804d7
Content-Type: text/html; charset=UTF-8
X-Trans-Id: tx4d5e4f06d357462bb732f-0052d96843
Date: Fri, 17 Jan 2014 17:28:35 GMT
@@ -198,7 +198,7 @@ Example requests and responses:
::
- curl -i $publicURL/janeausten/helloworld -X PUT -H "Content-Length: 0" -H "X-Auth-Token: $token"
+ curl -i $publicURL/janeausten/helloworld.txt -X PUT -d "Hola" -H "X-Auth-Token: $token"
@@ -207,8 +207,8 @@ Example requests and responses:
HTTP/1.1 201 Created
Last-Modified: Fri, 17 Jan 2014 17:28:35 GMT
- Content-Length: 116
- Etag: d41d8cd98f00b204e9800998ecf8427e
+ Content-Length: 0
+ Etag: f688ae26e9cfa3ba6235477831d5122e
Content-Type: text/html; charset=UTF-8
X-Trans-Id: tx4d5e4f06d357462bb732f-0052d96843
Date: Fri, 17 Jan 2014 17:28:35 GMT
@@ -674,7 +674,7 @@ Example requests and responses:
::
- curl -i $publicURL/marktwain/goodbye -X POST -H "X-Auth-Token: $token" H "X-Object-Meta-Book: GoodbyeOldFriend"
+ curl -i $publicURL/marktwain/goodbye -X POST -H "X-Auth-Token: $token" -H "X-Object-Meta-Book: GoodbyeOldFriend"