From 967be9e750221ab2ab783f95df79bb26d290a45e Mon Sep 17 00:00:00 2001 From: Martial Simon Date: Mon, 15 Sep 2025 01:07:58 +0200 Subject: add: added projects --- .../src/main/resources/application.properties | 7 ++ jws/endpoints/src/main/resources/openapi.yaml | 80 ++++++++++++++++++++++ 2 files changed, 87 insertions(+) create mode 100644 jws/endpoints/src/main/resources/application.properties create mode 100644 jws/endpoints/src/main/resources/openapi.yaml (limited to 'jws/endpoints/src/main/resources') diff --git a/jws/endpoints/src/main/resources/application.properties b/jws/endpoints/src/main/resources/application.properties new file mode 100644 index 0000000..b3b3d13 --- /dev/null +++ b/jws/endpoints/src/main/resources/application.properties @@ -0,0 +1,7 @@ +%dev.quarkus.http.port=8082 +%dev.quarkus.swagger-ui.enable=true + +quarkus.log.category."org.apache.kafka".level=WARN +quarkus.devservices.enabled=false + +quarkus.http.cors=true diff --git a/jws/endpoints/src/main/resources/openapi.yaml b/jws/endpoints/src/main/resources/openapi.yaml new file mode 100644 index 0000000..7e8ac48 --- /dev/null +++ b/jws/endpoints/src/main/resources/openapi.yaml @@ -0,0 +1,80 @@ +--- +openapi: 3.1.0 +tags: +- name: Greeting +- name: String Operations +servers: + - url: http://localhost:8082/ +components: + schemas: + HelloResponse: + type: object + properties: + content: + type: string + example: "hello test" + ReverseRequest: + type: object + properties: + content: + type: string + example: "hello\ntest" + ReverseResponse: + type: object + properties: + original: + type: string + example: "hello\ntest" + reversed: + type: string + example: "tset\nolleh" +paths: + /hello/{name}: + get: + summary: Greet by name + description: "Returns a greeting message in the format `hello {name}` using\ + \ the provided name." + tags: + - Greeting + parameters: + - name: name + in: path + required: true + schema: + type: string + responses: + "200": + description: Greeting message returned successfully. + content: + application/json: + schema: + $ref: "#/components/schemas/HelloResponse" + "400": + description: "Bad request: The name parameter is null or empty." + /reverse: + post: + summary: Reverse a string + description: "Accepts a JSON request containing a string, reverses the string,\ + \ and returns both the original and reversed versions." + tags: + - String Operations + requestBody: + description: JSON object containing the string to be reversed. + content: + application/json: + schema: + $ref: "#/components/schemas/ReverseRequest" + required: true + responses: + "200": + description: Reversed string returned successfully. + content: + application/json: + schema: + $ref: "#/components/schemas/ReverseResponse" + "400": + description: "Bad request: Request body is null or the string content is\ + \ null or empty." +info: + title: endpoints API + version: "1.0" -- cgit v1.2.3