diff options
Diffstat (limited to 'tutorial/quickstart/index.html')
| -rw-r--r-- | tutorial/quickstart/index.html | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/tutorial/quickstart/index.html b/tutorial/quickstart/index.html index f291901c..204942b0 100644 --- a/tutorial/quickstart/index.html +++ b/tutorial/quickstart/index.html @@ -406,6 +406,7 @@ pip install djangorestframework django-admin.py startproject tutorial . cd tutorial django-admin.py startapp quickstart +cd .. </code></pre> <p>Now sync your database for the first time:</p> <pre><code>python manage.py migrate @@ -518,6 +519,31 @@ REST_FRAMEWORK = { ] } </code></pre> +<p>Or using the <a href="https://github.com/jakubroztocil/httpie#installation">httpie</a>, command line tool...</p> +<pre><code>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" + } + ] +} +</code></pre> <p>Or directly through the browser...</p> <p><img alt="Quick start image" src="../../../img/quickstart.png" /></p> <p>If you're working through the browser, make sure to login using the control in the top right corner.</p> |
