Last active
March 22, 2017 10:50
-
-
Save sapiens-sapide/d311bbea5372a9cbcd22cb0c0e1043e0 to your computer and use it in GitHub Desktop.
prism test on caliopen's swagger -> route authentication
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"x-stoplight": { | |
"beforeScript": null, | |
"afterScript": null, | |
"mock": { | |
"enabled": true, | |
"dynamic": false, | |
"statusCode": 200 | |
} | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"responses": { | |
"200": { | |
"description": "Successful authentication", | |
"schema": { | |
"type": "object", | |
"properties": { | |
"username": { | |
"type": "string", | |
"pattern": "stansab" | |
}, | |
"user_id": { | |
"type": "string", | |
"description": "the user_id makes the 'username' for basicAuth" | |
}, | |
"tokens": { | |
"type": "object", | |
"properties": { | |
"access_token": { | |
"type": "string", | |
"description": "the access_token makes the 'password' for basicAuth", | |
"pattern": "this is a mocked access_token" | |
}, | |
"expires_in": { | |
"type": "integer", | |
"format": "int32" | |
}, | |
"expires_at": { | |
"type": "string" | |
}, | |
"refresh_token": { | |
"type": "string" | |
} | |
} | |
} | |
}, | |
"additionalProperties": false, | |
"required": ["username", "user_id", "tokens"] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment