public HttpResponseMessage get()
 {
     if (checkToken(Request))
     {
         try {
             return(response(HttpStatusCode.OK, true, "ready", ConfigTrafficLightDomain.fetch()));
         } catch (Exception e) {
             return(response(HttpStatusCode.InternalServerError, false, e));
         }
     }
     else
     {
         return(response(HttpStatusCode.Unauthorized, false, "invalid token"));
     }
 }
 public HttpResponseMessage update(ConfigTrafficLight configTrafficLight)
 {
     if (checkToken(Request))
     {
         try {
             ConfigTrafficLightDomain.update(configTrafficLight.id, configTrafficLight.green, configTrafficLight.yellow, configTrafficLight.red);
             return(response(HttpStatusCode.OK, true, "ready"));
         } catch (Exception e) {
             return(response(HttpStatusCode.InternalServerError, false, e));
         }
     }
     else
     {
         return(response(HttpStatusCode.Unauthorized, false, "invalid token"));
     }
 }