added basic auth and created relations