func NewServer(logger golog.Logger, cfg *config.Config,
	db *sqlx.DB) http.Server {
	router := mux.NewRouter()
	routesLogger := logger.GetChild("call-routes")
	healthHandler := handlers.NewHealthHandler()
	router.Handle("/healthz", healthHandler)
	callLogger := routesLogger.GetChild("call")
	callHandler := NewCallsHandler(callLogger, cfg, db)
	router.Handle("/call", callHandler).Methods("POST")
	inputLogger := routesLogger.GetChild("input")
	inputHandler := NewTestInputHandler(inputLogger, cfg, db)
	router.Handle("/input/challenge/{challenge_id}", inputHandler).
		Methods("POST")
	audioClipLogger := routesLogger.GetChild("audio-clips")
	audioClipHandler := NewAudioClipsHandler(audioClipLogger)
	router.Handle("/audio-clips/{file}.mp3", audioClipHandler)
	return http.Server{
		Addr:    fmt.Sprintf(":%s", cfg.CallsHTTPPort),
		Handler: router,
	}
}
NewServer creates a http.Server which handles twilio call requests
package calls
import (
	"fmt"
	"net/http"
	"github.com/Noah-Huppert/human-call-filter/config"
	"github.com/Noah-Huppert/human-call-filter/handlers"
	"github.com/Noah-Huppert/golog"
	"github.com/gorilla/mux"
	"github.com/jmoiron/sqlx"
)