Skip to content

JavaHamster/BackendSpring

Repository files navigation

Backend Spring

This is the API Background where our frontend framework (= VueJS) sends request to.

Installation guide for developer (not using docker) to edit program

You can apply some changes in settings.properties, but be careful! You might need to reinstall your database!

The commands

  • vor();
  • linksUm();
  • nimm();
  • gib();
  • vornFrei();
  • kornDa();
  • maulLeer();

Rest Services

Standard user to log in with admin rights:
username: admin
password: admin

Should be changed when publishing it!

Objects

  1. user:
    {
     username: (String),
     password: (String),
     email: (String)
    }
  2. hamster:
    {
     programName: (String),
     program: (String),
     terrainName: (String),
     laenge: (int),
     breite: (int),
     x: (int),
     y: (int),
     cornAnzahl: (int[])
     corn: (int[][])  wall: (int[][])
    }

Services

All Services starts with /api!

  1. /user services - available from DEV This are all Services which involves user data beginning with /user (services in brackets are coming soon!)
  • /users (GET, POST, PUT, DELETE)
  • /logout (GET)
  • /roles (POST, DELETE)
  1. /hamster services - for all registered user available: All services which handles requests containing hamstercode beginning with /hamster
  • /defaultTerrain (POST)
  • /existingTerrain (POST)
  • /newTerrain (POST)
  1. Teacher services - available from TEACHER Services which are available for teachers to take control over their students begin with /teacher
  • /students (GET)
  • /course (GET, POST, DELETE)
  • /course/students (GET, POST, DELETE)
  • /course/teachers (GET)
  • /exercises (GET, DELETE, POST, PUT)
  • (/rateExercises)
  1. /login service
    The login service; request sent as json => {"username": "username", "password": "password"}
  2. /register service
    The register service; request sent as json => {"username": "username", "password": "password", "email": "email"}

Test

To check if you installed everything correctly, I provided you with JUnit tests, which you can find in src/test/java/io/github/Hattinger04/

About

The API for the hamster website project

Topics

Resources

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •  

Languages