From 24a5a27977ce8b574aa097d90927c2dee832339a Mon Sep 17 00:00:00 2001 From: steve-chavez Date: Thu, 3 Jan 2019 12:17:53 -0500 Subject: [PATCH] Fix #183, change immediate revocation request to PATCH --- tutorials/tut1.rst | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/tutorials/tut1.rst b/tutorials/tut1.rst index 6abe84698..bcef5e632 100644 --- a/tutorials/tut1.rst +++ b/tutorials/tut1.rst @@ -230,13 +230,17 @@ Restart PostgREST for the change to take effect. Next try making a request with # this request still works - curl http://localhost:3000/todos \ - -H "Authorization: Bearer $TOKEN" + curl http://localhost:3000/todos -X PATCH \ + -H "Authorization: Bearer $TOKEN" \ + -H "Content-Type: application/json" \ + -d '{"done": true}' # this one is rejected - curl http://localhost:3000/todos \ - -H "Authorization: Bearer $WAYWARD_TOKEN" + curl http://localhost:3000/todos -X PATCH \ + -H "Authorization: Bearer $WAYWARD_TOKEN" \ + -H "Content-Type: application/json" \ + -d '{"task": "AAAHHHH!", "done": false}' The server responds with 403 Forbidden: