Index: src/main/java/it/finki/tinki/controller/LoginController.java
===================================================================
--- src/main/java/it/finki/tinki/controller/LoginController.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
+++ src/main/java/it/finki/tinki/controller/LoginController.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -0,0 +1,39 @@
+package it.finki.tinki.controller;
+
+import it.finki.tinki.model.Users.Account;
+import it.finki.tinki.model.pojo.AccountLoginDataPojo;
+import it.finki.tinki.model.pojo.AuthResponseDataPojo;
+import it.finki.tinki.service.AccountService;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.server.ResponseStatusException;
+
+@RestController
+@CrossOrigin(origins = "http://localhost:3000")
+@RequestMapping("/api")
+public class LoginController {
+
+    AccountService accountService;
+
+    public LoginController(AccountService accountService) {
+        this.accountService = accountService;
+    }
+
+    @PostMapping(path = "/login")
+    public AuthResponseDataPojo testPage(@RequestBody AccountLoginDataPojo body) throws ResponseStatusException {
+
+        System.out.println(body);
+
+        Account a1 = accountService.findUser(body.getAccount(), body.getPassword(), body.getType());
+        AuthResponseDataPojo resp = new AuthResponseDataPojo();
+
+        if(a1!=null){
+            resp.setId(a1.getId());
+            resp.setEmail(a1.getEmail());
+            resp.setName(a1.getName());
+            resp.setType(a1.getAccountType());
+        }
+
+        return resp;
+    }
+
+}
Index: src/main/java/it/finki/tinki/controller/RegisterController.java
===================================================================
--- src/main/java/it/finki/tinki/controller/RegisterController.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
+++ src/main/java/it/finki/tinki/controller/RegisterController.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -0,0 +1,19 @@
+package it.finki.tinki.controller;
+
+import it.finki.tinki.repository.AddressRepository;
+import it.finki.tinki.repository.CompanyRepository;
+import it.finki.tinki.repository.TeamRepository;
+import it.finki.tinki.repository.UserRepository;
+import org.springframework.web.bind.annotation.CrossOrigin;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+
+@RestController
+@CrossOrigin(origins = "http://localhost:3000")
+@RequestMapping("/api/register")
+public class RegisterController {
+
+
+
+
+}
Index: src/main/java/it/finki/tinki/controller/TestController.java
===================================================================
--- src/main/java/it/finki/tinki/controller/TestController.java	(revision 3f5bf9e52a8d5a39df72f03e1a74347b96e88188)
+++ 	(revision )
@@ -1,39 +1,0 @@
-package it.finki.tinki.controller;
-
-import it.finki.tinki.model.Users.Account;
-import it.finki.tinki.model.pojo.AccountLoginDataPojo;
-import it.finki.tinki.model.pojo.AuthResponseDataPojo;
-import it.finki.tinki.service.AccountService;
-import org.springframework.web.bind.annotation.*;
-import org.springframework.web.server.ResponseStatusException;
-
-@RestController
-@CrossOrigin(origins = "http://localhost:3000")
-@RequestMapping("/api")
-public class TestController {
-
-    AccountService accountService;
-
-    public TestController(AccountService accountService) {
-        this.accountService = accountService;
-    }
-
-    @PostMapping(path = "/login")
-    public AuthResponseDataPojo testPage(@RequestBody AccountLoginDataPojo body) throws ResponseStatusException {
-
-        System.out.println(body);
-
-        Account a1 = accountService.findUser(body.getAccount(), body.getPassword(), body.getType());
-        AuthResponseDataPojo resp = new AuthResponseDataPojo();
-
-        if(a1!=null){
-            resp.setId(a1.getId());
-            resp.setEmail(a1.getEmail());
-            resp.setName(a1.getName());
-            resp.setType(a1.getAccountType());
-        }
-
-        return resp;
-    }
-
-}
Index: src/main/java/it/finki/tinki/model/exception/InvalidArgumentsException.java
===================================================================
--- src/main/java/it/finki/tinki/model/exception/InvalidArgumentsException.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
+++ src/main/java/it/finki/tinki/model/exception/InvalidArgumentsException.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -0,0 +1,7 @@
+package it.finki.tinki.model.exception;
+
+public class InvalidArgumentsException extends RuntimeException{
+    public InvalidArgumentsException(){
+        super("Invalid arguments entered!");
+    }
+}
Index: src/main/java/it/finki/tinki/model/exception/UserExistsException.java
===================================================================
--- src/main/java/it/finki/tinki/model/exception/UserExistsException.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
+++ src/main/java/it/finki/tinki/model/exception/UserExistsException.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -0,0 +1,7 @@
+package it.finki.tinki.model.exception;
+
+public class UserExistsException extends RuntimeException{
+    public UserExistsException(){
+        super("User with that email already exists!");
+    }
+}
Index: src/main/java/it/finki/tinki/repository/UserRepository.java
===================================================================
--- src/main/java/it/finki/tinki/repository/UserRepository.java	(revision 3f5bf9e52a8d5a39df72f03e1a74347b96e88188)
+++ src/main/java/it/finki/tinki/repository/UserRepository.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -5,6 +5,9 @@
 import org.springframework.stereotype.Repository;
 
+import java.util.Optional;
+
 @Repository
 public interface UserRepository extends JpaRepository<User, Long> {
     User findByEmailAndPassword(String email, String password);
+    Optional<User> findByEmail(String email);
 }
Index: src/main/java/it/finki/tinki/service/impl/AccountServiceImpl.java
===================================================================
--- src/main/java/it/finki/tinki/service/impl/AccountServiceImpl.java	(revision 3f5bf9e52a8d5a39df72f03e1a74347b96e88188)
+++ src/main/java/it/finki/tinki/service/impl/AccountServiceImpl.java	(revision 7edede91d3117ee5b1a25a53d07ebf2c12663955)
@@ -1,4 +1,6 @@
 package it.finki.tinki.service.impl;
 
+import it.finki.tinki.model.Address;
+import it.finki.tinki.model.Skill;
 import it.finki.tinki.model.Users.Account;
 import it.finki.tinki.model.Users.Company;
@@ -6,4 +8,7 @@
 import it.finki.tinki.model.Users.User;
 import it.finki.tinki.model.enumerator.AccountType;
+import it.finki.tinki.model.exception.InvalidArgumentsException;
+import it.finki.tinki.model.exception.UserExistsException;
+import it.finki.tinki.repository.AddressRepository;
 import it.finki.tinki.repository.CompanyRepository;
 import it.finki.tinki.repository.TeamRepository;
@@ -13,4 +18,5 @@
 
 import java.util.HashMap;
+import java.util.List;
 import java.util.Map;
 
@@ -18,9 +24,11 @@
 public class AccountServiceImpl implements AccountService {
 
+    AddressRepository addressRepository;
     UserRepository userRepository;
     TeamRepository teamRepository;
     CompanyRepository companyRepository;
 
-    public AccountServiceImpl(UserRepository userRepository, TeamRepository teamRepository, CompanyRepository companyRepository) {
+    public AccountServiceImpl(AddressRepository addressRepository, UserRepository userRepository, TeamRepository teamRepository, CompanyRepository companyRepository) {
+        this.addressRepository = addressRepository;
         this.userRepository = userRepository;
         this.teamRepository = teamRepository;
@@ -33,22 +41,29 @@
         if(type.equals(AccountType.USER)){
             User u1 = userRepository.findByEmailAndPassword(email, password);
-            if(u1!=null){
-                return u1;
-            }
+            return u1;
         }
         else if(type.equals(AccountType.TEAM)){
             Team t1 = teamRepository.findByEmailAndPassword(email, password);
-            if(t1!=null){
-                return t1;
-            }
+            return t1;
         }
         else if(type.equals(AccountType.COMPANY)){
             Company c1 = companyRepository.findByEmailAndPassword(email, password);
-            if(c1!=null){
-                return c1;
-            }
+            return c1;
         }
 
         return null;
     }
+
+    public Account registerUser(String email, String password, String name, String surname, List<Skill> retainedSkills, List<Skill> skillsToLearn){
+        if(email==null || email.isEmpty() || password==null || password.isEmpty() || name==null || name.isEmpty() || surname==null || surname.isEmpty()){
+            throw new InvalidArgumentsException();
+        }
+
+        if(this.userRepository.findByEmail(email).isPresent()){
+            throw new UserExistsException();
+        }
+
+        User u = new User(email, password, name, AccountType.USER, surname, retainedSkills, skillsToLearn);
+        return this.userRepository.save(u);
+    }
 }
