Skip to content

Commit

Permalink
[SELC-5651] feat: added external-pnpg tag on getUserInfo API (#191)
Browse files Browse the repository at this point in the history
  • Loading branch information
empassaro authored Sep 25, 2024
1 parent 3b033d3 commit 70d46c7
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 7 deletions.
6 changes: 4 additions & 2 deletions apps/user-ms/src/main/docs/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@
"name" : "Institution"
}, {
"name" : "User"
}, {
"name" : "external-pnpg"
}, {
"name" : "external-v2"
}, {
Expand Down Expand Up @@ -160,7 +162,7 @@
} ]
}
},
"/institutions/{institutionId}/products/{productId}/createdAt" : {
"/institutions/{institutionId}/products/{productId}/created-at" : {
"put" : {
"tags" : [ "Institution" ],
"summary" : "Update user's onboarded product creation date",
Expand Down Expand Up @@ -693,7 +695,7 @@
},
"/users/{id}" : {
"get" : {
"tags" : [ "User", "external-v2", "support", "support-pnpg" ],
"tags" : [ "User", "external-v2", "support", "support-pnpg", "external-pnpg" ],
"summary" : "Retrieve user information by userId and optional ProductId",
"description" : "Retrieves user given userId and optional ProductId",
"operationId" : "getUserInfoUsingGET",
Expand Down
4 changes: 3 additions & 1 deletion apps/user-ms/src/main/docs/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ tags:
- name: Events
- name: Institution
- name: User
- name: external-pnpg
- name: external-v2
- name: internal-v1
- name: support
Expand Down Expand Up @@ -116,7 +117,7 @@ paths:
description: Not Allowed
security:
- SecurityScheme: []
/institutions/{institutionId}/products/{productId}/createdAt:
/institutions/{institutionId}/products/{productId}/created-at:
put:
tags:
- Institution
Expand Down Expand Up @@ -501,6 +502,7 @@ paths:
- external-v2
- support
- support-pnpg
- external-pnpg
summary: Retrieve user information by userId and optional ProductId
description: Retrieves user given userId and optional ProductId
operationId: getUserInfoUsingGET
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ public Multi<UserInstitutionResponse> retrieveUsers(@PathParam(value = "institut
description = "Updates the `createdAt` timestamp for a user's onboarded product based on the provided institutionId, productId, and list of userIds. This is useful for tracking when a user was onboarded to a specific product within an institution."
)
@PUT
@Path(value = "/{institutionId}/products/{productId}/createdAt")
@Path(value = "/{institutionId}/products/{productId}/created-at")
@Produces(MediaType.APPLICATION_JSON)
public Uni<Response> updateUserProductCreatedAt(@PathParam(value = "institutionId") String institutionId,
@PathParam(value = "productId") String productId,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ public Uni<List<String>> getUsersEmailByInstitutionAndProduct(@NotNull @QueryPar
@Tag(name = "external-v2")
@Tag(name = "support")
@Tag(name = "support-pnpg")
@Tag(name = "external-pnpg")
public Uni<UserResponse> getUserInfo(@PathParam(value = "id") String userId,
@QueryParam(value = "institutionId") String institutionId,
@QueryParam(value = "productId") String productId) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ void updateUserProductCreatedAt() {
.contentType(ContentType.JSON)
.pathParam("institutionId", institutionId)
.pathParam("productId", productId)
.put("/{institutionId}/products/{productId}/createdAt?userIds=userId&createdAt=" + now)
.put("/{institutionId}/products/{productId}/created-at?userIds=userId&createdAt=" + now)
.then()
.statusCode(204);
}
Expand All @@ -137,7 +137,7 @@ void updateUserProductCreatedAt_NotAuthorized() {
.contentType(ContentType.JSON)
.pathParam("institutionId", institutionId)
.pathParam("productId", productId)
.put("/{institutionId}/products/{productId}/createdAt?createdAt=" + now)
.put("/{institutionId}/products/{productId}/created-at?createdAt=" + now)
.then()
.statusCode(401);
}
Expand All @@ -160,7 +160,7 @@ void updateUserProductCreatedAt_UserNotFound() {
.contentType(ContentType.JSON)
.pathParam("institutionId", institutionId)
.pathParam("productId", productId)
.put("/{institutionId}/products/{productId}/createdAt?userIds=" + userId + "&createdAt=" + now)
.put("/{institutionId}/products/{productId}/created-at?userIds=" + userId + "&createdAt=" + now)
.then()
.statusCode(404);
}
Expand Down

0 comments on commit 70d46c7

Please sign in to comment.