#pragma once

#include <httplib.h>
#include <nlohmann/json.hpp>

#include <filesystem>
#include <string>

namespace lm {

class HttpUtil
{
public:
  static std::string contentTypeForPath(const std::filesystem::path& p);
  static void jsonError(httplib::Response& res, int status, const std::string& msg);
  static void addCors(httplib::Response& res);
};

}  // namespace lm
