Skip to content
Snippets Groups Projects
Commit c2f175f6 authored by dylan.peiry's avatar dylan.peiry
Browse files

feat(api): postman collection for jwt tokens

parent 7c6b0797
No related branches found
No related tags found
No related merge requests found
File changed. Contains only whitespace changes. Show whitespace changes.
File changed. Contains only whitespace changes. Show whitespace changes.
File changed. Contains only whitespace changes. Show whitespace changes.
File changed. Contains only whitespace changes. Show whitespace changes.
File changed. Contains only whitespace changes. Show whitespace changes.
File changed. Contains only whitespace changes. Show whitespace changes.
......@@ -34,4 +34,8 @@ Off by default, not secure.
#
# Authentication & Authorization
For the /teachers endpoints, implement authentication and authorization using Okta as IdP with access_tokens
First require code to : https://dev-80790093.okta.com/oauth2/default/v1/authorize
Then trade code for an access token that will give access to the API https://dev-80790093.okta.com/oauth2/default/v1/token
File changed. Contains only whitespace changes. Show whitespace changes.
{
"info": {
"_postman_id": "e88d6235-0e63-4028-9949-c7257bc76c29",
"name": "AppSec API",
"schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
},
"item": [
{
"name": "GET Authorize (code)",
"request": {
"auth": {
"type": "noauth"
},
"method": "GET",
"header": [
{
"key": "Authorization",
"value": "Basic foo:bar",
"type": "text",
"disabled": true
}
],
"url": {
"raw": "https://dev-80790093.okta.com/oauth2/default/v1/authorize?client_id=0oa2v2ujqfpqiAuEk5d7&response_type=code&scope=openid&redirect_uri=http://localhost/authorization-code/callback&state=100",
"protocol": "https",
"host": [
"dev-80790093",
"okta",
"com"
],
"path": [
"oauth2",
"default",
"v1",
"authorize"
],
"query": [
{
"key": "client_id",
"value": "0oa2v2ujqfpqiAuEk5d7"
},
{
"key": "response_type",
"value": "code"
},
{
"key": "scope",
"value": "openid"
},
{
"key": "redirect_uri",
"value": "http://localhost/authorization-code/callback"
},
{
"key": "state",
"value": "100"
}
]
}
},
"response": []
},
{
"name": "GET Token (access token)",
"request": {
"auth": {
"type": "noauth"
},
"method": "POST",
"header": [
{
"key": "Accept",
"value": "application/json",
"type": "text"
},
{
"key": "Content-Type",
"value": "application/x-www-form-urlencoded",
"type": "text"
},
{
"key": "Authorization",
"value": "Basic MG9hMnYydWpxZnBxaUF1RWs1ZDc6N3pyd0pibUlUNjBkcVFBSmlxUzBwdTBWUVQ3RkFWbzRsekRxRzJIaQ==",
"type": "text"
}
],
"url": {
"raw": "https://dev-80790093.okta.com/oauth2/default/v1/token?grant_type=authorization_code&redirect_uri=http://localhost/authorization-code/callback&code=GCqhSYKP0M9W5qYcNL0Y2oWrqG-s8WZAToGZvy8_nwc",
"protocol": "https",
"host": [
"dev-80790093",
"okta",
"com"
],
"path": [
"oauth2",
"default",
"v1",
"token"
],
"query": [
{
"key": "grant_type",
"value": "authorization_code"
},
{
"key": "redirect_uri",
"value": "http://localhost/authorization-code/callback"
},
{
"key": "code",
"value": "GCqhSYKP0M9W5qYcNL0Y2oWrqG-s8WZAToGZvy8_nwc"
},
{
"key": "client_id",
"value": "0oa2v2ujqfpqiAuEk5d7",
"disabled": true
}
]
}
},
"response": []
}
]
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment