Skip to content

Instantly share code, notes, and snippets.

@rihenperry
Created November 24, 2018 08:37
Show Gist options
  • Save rihenperry/995f919b477e0a3c270395f70164c5b7 to your computer and use it in GitHub Desktop.
Save rihenperry/995f919b477e0a3c270395f70164c5b7 to your computer and use it in GitHub Desktop.
Oauth 2.0 - password grant
POST /oauth2.0/token
Host: api.server.io
User-agent: postman/v1.0.0
Accept: */*
Content-type: application/x-www-url-encoded
Content-length: 54
username=rihan&password=password&granttype=password
http/1.1 200 OK
Content-type: application/json
Cache-control
{
"access_token: "x5cfvt7u5q3Sd0Gb8...",
"refresh_token": "e8vFi9uReA39Bmx7N..."
}
old pair
=============
access_token: "x5cfvt7u5q3Sd0Gb8..."
refresh_token: "e8vFi9uReA39Bmx7N..."
new pair
=============
access_token: "yZ77G89Hj4K1LaC3w2v...."
refresh_token: m5G0q1T3L7v6sDO4c5..."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment