Skip to content

Commit

Permalink
[#IOPID-1771] Remove getSession
Browse files Browse the repository at this point in the history
  • Loading branch information
BurnedMarshal committed Jul 30, 2024
1 parent 0964122 commit ee10e3c
Show file tree
Hide file tree
Showing 11 changed files with 8 additions and 581 deletions.
52 changes: 0 additions & 52 deletions api_backend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -712,31 +712,6 @@ paths:
description: There was an error in registering the device to the Notification Hub.
schema:
$ref: "#/definitions/ProblemJson"
"/session":
x-swagger-router-controller: AuthenticationController
get:
operationId: getSessionState
summary: Get the user current session
description: Return the session state for the current authenticated user.
responses:
"200":
description: Found.
schema:
$ref: "#/definitions/PublicSession"
examples:
application/json:
spidLevel: "https://www.spid.gov.it/SpidL2"
walletToken: "c77de47586c841adbd1a1caeb90dce25dcecebed620488a4f932a6280b10ee99a77b6c494a8a6e6884ccbeb6d3fe736b"
"400":
description: Bad request
schema:
$ref: "#/definitions/ProblemJson"
"401":
description: Bearer token null or expired.
"500":
description: Internal server error
schema:
$ref: "#/definitions/ProblemJson"
"/sessions":
x-swagger-router-controller: AuthenticationController
get:
Expand Down Expand Up @@ -779,7 +754,6 @@ paths:
description: Unavailable service
schema:
$ref: "#/definitions/ProblemJson"

"/payment-requests/{rptId}":
x-swagger-router-controller: PagoPAProxyController
parameters:
Expand Down Expand Up @@ -1353,32 +1327,6 @@ definitions:
required:
- version
- metadata
PublicSession:
type: object
title: User session data
description: Describe the current session of an authenticated user.
properties:
spidLevel:
$ref: '#/definitions/SpidLevel'
lollipopAssertionRef:
$ref: "#/definitions/AssertionRef"
walletToken:
type: string
myPortalToken:
type: string
bpdToken:
type: string
zendeskToken:
type: string
fimsToken:
type: string
required:
- spidLevel
- walletToken
- myPortalToken
- bpdToken
- zendeskToken
- fimsToken
SessionInfo:
type: object
title: Session info of a user
Expand Down
51 changes: 0 additions & 51 deletions openapi/api_backend.template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -646,31 +646,6 @@ paths:
description: There was an error in registering the device to the Notification Hub.
schema:
$ref: "#/definitions/ProblemJson"
"/session":
x-swagger-router-controller: AuthenticationController
get:
operationId: getSessionState
summary: Get the user current session
description: Return the session state for the current authenticated user.
responses:
"200":
description: Found.
schema:
$ref: "#/definitions/PublicSession"
examples:
application/json:
spidLevel: "https://www.spid.gov.it/SpidL2"
walletToken: "c77de47586c841adbd1a1caeb90dce25dcecebed620488a4f932a6280b10ee99a77b6c494a8a6e6884ccbeb6d3fe736b"
"400":
description: Bad request
schema:
$ref: "#/definitions/ProblemJson"
"401":
description: Bearer token null or expired.
"500":
description: Internal server error
schema:
$ref: "#/definitions/ProblemJson"
"/sessions":
x-swagger-router-controller: AuthenticationController
get:
Expand Down Expand Up @@ -1278,32 +1253,6 @@ definitions:
required:
- version
- metadata
PublicSession:
type: object
title: User session data
description: Describe the current session of an authenticated user.
properties:
spidLevel:
$ref: '#/definitions/SpidLevel'
lollipopAssertionRef:
$ref: "#/definitions/AssertionRef"
walletToken:
type: string
myPortalToken:
type: string
bpdToken:
type: string
zendeskToken:
type: string
fimsToken:
type: string
required:
- spidLevel
- walletToken
- myPortalToken
- bpdToken
- zendeskToken
- fimsToken
SessionInfo:
type: object
title: Session info of a user
Expand Down
52 changes: 0 additions & 52 deletions openapi/generated/api_backend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -669,32 +669,6 @@ paths:
Hub.
schema:
$ref: '#/definitions/ProblemJson'
/session:
x-swagger-router-controller: AuthenticationController
get:
operationId: getSessionState
summary: Get the user current session
description: Return the session state for the current authenticated user.
responses:
'200':
description: Found.
schema:
$ref: '#/definitions/PublicSession'
examples:
application/json:
spidLevel: https://www.spid.gov.it/SpidL2
walletToken: >-
c77de47586c841adbd1a1caeb90dce25dcecebed620488a4f932a6280b10ee99a77b6c494a8a6e6884ccbeb6d3fe736b
'400':
description: Bad request
schema:
$ref: '#/definitions/ProblemJson'
'401':
description: Bearer token null or expired.
'500':
description: Internal server error
schema:
$ref: '#/definitions/ProblemJson'
/sessions:
x-swagger-router-controller: AuthenticationController
get:
Expand Down Expand Up @@ -2757,32 +2731,6 @@ definitions:
required:
- version
- metadata
PublicSession:
type: object
title: User session data
description: Describe the current session of an authenticated user.
properties:
spidLevel:
$ref: '#/definitions/SpidLevel'
lollipopAssertionRef:
$ref: '#/definitions/AssertionRef'
walletToken:
type: string
myPortalToken:
type: string
bpdToken:
type: string
zendeskToken:
type: string
fimsToken:
type: string
required:
- spidLevel
- walletToken
- myPortalToken
- bpdToken
- zendeskToken
- fimsToken
SessionInfo:
type: object
title: Session info of a user
Expand Down
10 changes: 1 addition & 9 deletions src/app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -790,9 +790,7 @@ function registerAPIRoutes(
});

const sessionController: SessionController = new SessionController(
sessionStorage,
tokenService,
profileService
sessionStorage
);

const pagoPAProxyController: PagoPAProxyController =
Expand Down Expand Up @@ -969,12 +967,6 @@ function registerAPIRoutes(
);
}

app.get(
`${basePath}/session`,
bearerSessionTokenAuth,
toExpressHandler(sessionController.getSessionState, sessionController)
);

app.get(
`${basePath}/sessions`,
bearerSessionTokenAuth,
Expand Down
Loading

0 comments on commit ee10e3c

Please sign in to comment.