aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorAdrián Oliva <adrian.oliva@cimat.mx>2023-05-24 15:33:21 -0600
committerAdrián Oliva <adrian.oliva@cimat.mx>2023-05-24 15:33:21 -0600
commit233f75c561d119cf4103343bd5df4faef81ac5a1 (patch)
tree75c8b1397772ade63b049a536eaa7a103b61662f /src/main/java
parent4230248be8e8772fc9cd1304bd69dcb3c11373c9 (diff)
downloadToDo-App-BE-233f75c561d119cf4103343bd5df4faef81ac5a1.tar.gz
ToDo-App-BE-233f75c561d119cf4103343bd5df4faef81ac5a1.zip
First simple Get Request.
Returns a string with a "GET" request and on the page "/greet".
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/com/encora/Main.java19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/main/java/com/encora/Main.java b/src/main/java/com/encora/Main.java
new file mode 100644
index 0000000..7591eed
--- /dev/null
+++ b/src/main/java/com/encora/Main.java
@@ -0,0 +1,19 @@
+package com.encora;
+
+import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+@SpringBootApplication
+@RestController
+public class Main {
+ public static void main(String[] args) {
+ SpringApplication.run(Main.class, args);
+ }
+
+ @GetMapping("/greet")
+ public String greet() {
+ return "Hello world!";
+ }
+}