aboutsummaryrefslogtreecommitdiffstats
path: root/docs/tutorial/quickstart.md
diff options
context:
space:
mode:
authorTom Christie2014-12-08 15:51:19 +0000
committerTom Christie2014-12-08 15:51:19 +0000
commit302ec59a5c8b97b5d6be1e50e16a33df51508a81 (patch)
treee838d159f8b04f45a28b106907fdb4fee31d38b6 /docs/tutorial/quickstart.md
parentfd02d8266b3df2a5ed41f599eae6765631643da2 (diff)
parentf3ebac061e7b5a67afe1d9440876afa804d3995d (diff)
downloaddjango-rest-framework-302ec59a5c8b97b5d6be1e50e16a33df51508a81.tar.bz2
Merge pull request #2165 from phalt/httpie-examples
Use httpie for tutorials
Diffstat (limited to 'docs/tutorial/quickstart.md')
-rw-r--r--docs/tutorial/quickstart.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/docs/tutorial/quickstart.md b/docs/tutorial/quickstart.md
index d0703381..d6989d56 100644
--- a/docs/tutorial/quickstart.md
+++ b/docs/tutorial/quickstart.md
@@ -158,6 +158,33 @@ We can now access our API, both from the command-line, using tools like `curl`..
]
}
+Or using the [httpie][httpie], command line tool...
+
+ bash: http -a username:password http://127.0.0.1:8000/users/
+
+ HTTP/1.1 200 OK
+ ...
+ {
+ "count": 2,
+ "next": null,
+ "previous": null,
+ "results": [
+ {
+ "email": "admin@example.com",
+ "groups": [],
+ "url": "http://localhost:8000/users/1/",
+ "username": "paul"
+ },
+ {
+ "email": "tom@example.com",
+ "groups": [ ],
+ "url": "http://127.0.0.1:8000/users/2/",
+ "username": "tom"
+ }
+ ]
+ }
+
+
Or directly through the browser...
![Quick start image][image]
@@ -172,3 +199,4 @@ If you want to get a more in depth understanding of how REST framework fits toge
[image]: ../img/quickstart.png
[tutorial]: 1-serialization.md
[guide]: ../#api-guide
+[httpie]: https://github.com/jakubroztocil/httpie#installation