summaryrefslogtreecommitdiffhomepage
path: root/response.h
blob: c47a980dab7ee0e7e5959a0d455567627fa9dddd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#pragma once

#include "server.h"

#include <boost/beast/http.hpp>

#include <exception>
#include <string>

namespace beast = boost::beast;         // from <boost/beast.hpp>
namespace http = beast::http;           // from <boost/beast/http.hpp>

typedef http::request<http::string_body> request_type;
typedef http::response<http::string_body> response_type;

std::string extend_index_html(std::string path);
std::string generate_response(request_type& req, response_type& res, Server& server);