Skip to content

Commit

Permalink
fix path param syntax in openapi example
Browse files Browse the repository at this point in the history
  • Loading branch information
tipsy committed May 3, 2024
1 parent d92d839 commit 84bc204
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public static void getAll(Context ctx) {
@OpenApi(
summary = "Get user by ID",
operationId = "getUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.GET,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand All @@ -65,7 +65,7 @@ public static void getOne(Context ctx) {
@OpenApi(
summary = "Update user by ID",
operationId = "updateUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.PATCH,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand All @@ -90,7 +90,7 @@ public static void update(Context ctx) {
@OpenApi(
summary = "Delete user by ID",
operationId = "deleteUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.DELETE,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public static void getAll(Context ctx) {
@OpenApi(
summary = "Get user by ID",
operationId = "getUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.GET,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand All @@ -65,7 +65,7 @@ public static void getOne(Context ctx) {
@OpenApi(
summary = "Update user by ID",
operationId = "updateUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.PATCH,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand All @@ -90,7 +90,7 @@ public static void update(Context ctx) {
@OpenApi(
summary = "Delete user by ID",
operationId = "deleteUserById",
path = "/users/:userId",
path = "/users/{userId}",
methods = HttpMethod.DELETE,
pathParams = {@OpenApiParam(name = "userId", type = Integer.class, description = "The user ID")},
tags = {"User"},
Expand Down

0 comments on commit 84bc204

Please sign in to comment.