added container endpoint for creating token in vault
This commit is contained in:
parent
6e37b7c4fe
commit
ebee1178ef
@ -3,7 +3,7 @@ info:
|
||||
title: Integraion layer APIs for token storage for ABT
|
||||
description: >-
|
||||
APIs that give business processes access to the security and authorization state of a token within the scope of HTM. In the backend this is connected to a container which handles the accessToken en refreshToken management.
|
||||
version: "2.0"
|
||||
version: "1.0"
|
||||
servers:
|
||||
- url: https://services.acc.api.htm.nl/abt/containertokens/1.0
|
||||
tags:
|
||||
@ -37,9 +37,107 @@ paths:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/TokenStatusResponse"
|
||||
examples:
|
||||
Not secured, not authorized :
|
||||
summary: Not secured, not authorized
|
||||
value:
|
||||
{
|
||||
"isAuthorized": false,
|
||||
"isSecured": false
|
||||
}
|
||||
Secured, not authorized :
|
||||
summary: Secured, not authorized
|
||||
value:
|
||||
{
|
||||
"isAuthorized": true,
|
||||
"isSecured": false
|
||||
}
|
||||
Secured and authorized :
|
||||
summary: Secured and authorized
|
||||
value:
|
||||
{
|
||||
"isAuthorized": true,
|
||||
"isSecured": true
|
||||
}
|
||||
"400":
|
||||
description: Bad Request
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/ErrorResponse"
|
||||
examples:
|
||||
Missing Parameters:
|
||||
value:
|
||||
status: 400
|
||||
title: Missing Mandatory Parameter
|
||||
detail: Required parameter {0} is missing.
|
||||
Invalid Parameters:
|
||||
value:
|
||||
status: 400
|
||||
title: Invalid Parameter
|
||||
detail: Required parameter {0} is invalid.
|
||||
"401":
|
||||
description: Unauthorized
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/ErrorResponse"
|
||||
examples:
|
||||
Unauthorized:
|
||||
value:
|
||||
status: 401
|
||||
title: Unauthorized
|
||||
detail: Invalid Access Token
|
||||
"404":
|
||||
description: Not found
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/ErrorResponse"
|
||||
examples:
|
||||
TAT not found:
|
||||
value:
|
||||
status: 404
|
||||
title: Not Found
|
||||
detail: TAT Account Not Found
|
||||
"500":
|
||||
description: Internal server error
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/ErrorResponse"
|
||||
example:
|
||||
isApproved: false
|
||||
isSecured: false
|
||||
error: An unknown error has occurred
|
||||
/tokens:
|
||||
parameters:
|
||||
post:
|
||||
tags:
|
||||
- tokens
|
||||
summary: Create a new token entry in the vault, if the customerProfileId has been supplied create in the customerToken DB otherwise in the AnonymousToken DB
|
||||
description: Create a new token entry in the vault, if the customerProfileId has been supplied create in the customerToken DB otherwise in the AnonymousToken DB
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/CreateTokenBody"
|
||||
examples:
|
||||
token:
|
||||
value:
|
||||
{
|
||||
"xTAT": "cf694905-7f76-4799-b0bc-490716921323",
|
||||
"otpKey": "123456789123456789123456789abcde"
|
||||
}
|
||||
responses:
|
||||
"201":
|
||||
description: Created
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: "#/components/schemas/unavailable"
|
||||
example:
|
||||
{
|
||||
"Ok"
|
||||
}
|
||||
"400":
|
||||
description: Bad Request
|
||||
content:
|
||||
@ -93,25 +191,7 @@ components:
|
||||
schemas:
|
||||
unavailable:
|
||||
type: object
|
||||
GenerateTatOutput:
|
||||
type: object
|
||||
properties:
|
||||
uid:
|
||||
type: string
|
||||
description: >-
|
||||
An uid IS A unique identifier THAT is associated with the
|
||||
user.
|
||||
recipient:
|
||||
type: string
|
||||
description: >-
|
||||
A recipient IS A unique identifier THAT is associated with the
|
||||
TAT owner.
|
||||
key:
|
||||
type: string
|
||||
description: >-
|
||||
A key IS a 32 character string THAT uniquely identifies the
|
||||
OTP session.
|
||||
ErrorResponse:
|
||||
ErrorResponse:
|
||||
description: Default response when an invalid request has been sent
|
||||
type: object
|
||||
properties:
|
||||
@ -127,8 +207,24 @@ components:
|
||||
detail:
|
||||
type: string
|
||||
description: A detail IS A string that provides more details about the error.
|
||||
CreateTokenBody:
|
||||
description: Body for when the a new token entry is created
|
||||
type: object
|
||||
required:
|
||||
- xTAT
|
||||
properties:
|
||||
xTAT:
|
||||
type : string
|
||||
description: >-
|
||||
Unique identifier for the GBO transit account
|
||||
example: 03071794-482a-4168-b60f-84669a9e6a76
|
||||
otpKey:
|
||||
type : string
|
||||
description: >-
|
||||
Key used to validate the OTP at GBO
|
||||
example: 123456789123456789123456789abcde
|
||||
TokenStatusResponse:
|
||||
description: Default response when an invalid request has been sent
|
||||
description: Response for when the status of a token is requested
|
||||
type: object
|
||||
properties:
|
||||
isSecured:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user