mirror of
https://github.com/Kong/insomnia.git
synced 2026-10-25 08:09:06 -04:00
Populate refresh token from a client credentials OAuth2 call (#3794)
This commit is contained in:
1 parent
8b011d68cf
commit
b8cc881d36
2 files changed
+5
No files matched your search
@@ -23,6 +23,7 @@ describe('client_credentials', () => {
|
||||
bodyPath,
|
||||
JSON.stringify({
|
||||
access_token: 'token_123',
|
||||
refresh_token: 'token_456',
|
||||
token_type: 'token_type',
|
||||
scope: SCOPE,
|
||||
audience: AUDIENCE,
|
||||
@@ -100,6 +101,7 @@ describe('client_credentials', () => {
|
||||
expect(result).toEqual({
|
||||
access_token: 'token_123',
|
||||
id_token: null,
|
||||
refresh_token: 'token_456',
|
||||
expires_in: null,
|
||||
token_type: 'token_type',
|
||||
scope: SCOPE,
|
||||
@@ -118,6 +120,7 @@ describe('client_credentials', () => {
|
||||
bodyPath,
|
||||
JSON.stringify({
|
||||
access_token: 'token_123',
|
||||
refresh_token: 'token_456',
|
||||
token_type: 'token_type',
|
||||
scope: SCOPE,
|
||||
audience: AUDIENCE,
|
||||
@@ -199,6 +202,7 @@ describe('client_credentials', () => {
|
||||
expect(result).toEqual({
|
||||
access_token: 'token_123',
|
||||
id_token: null,
|
||||
refresh_token: 'token_456',
|
||||
expires_in: null,
|
||||
token_type: 'token_type',
|
||||
scope: SCOPE,
|
||||
|
||||
@@ -93,6 +93,7 @@ export default async function(
|
||||
const results = responseToObject(bodyBuffer.toString('utf8'), [
|
||||
c.P_ACCESS_TOKEN,
|
||||
c.P_ID_TOKEN,
|
||||
c.P_REFRESH_TOKEN,
|
||||
c.P_TOKEN_TYPE,
|
||||
c.P_EXPIRES_IN,
|
||||
c.P_SCOPE,
|
||||
|
||||
Reference in new issue
Block a user