From aba60dadec3509bdf26ba4569550e959610d4bbe Mon Sep 17 00:00:00 2001
From: Dmitry Frank <mail@dmitryfrank.com>
Date: Sat, 3 Feb 2018 00:28:37 +0200
Subject: [PATCH] Add mg_ prefix to mongoose sources

CL: none

PUBLISHED_FROM=d6ebe5fa88c61ae3b8569897d9b09d54610bec73
---
 docs/c-api/coap.h/intro.md                    |  26 ---
 docs/c-api/coap.h/mg_coap_add_option.md       |  14 --
 docs/c-api/coap.h/mg_coap_compose.md          |  12 --
 docs/c-api/coap.h/mg_coap_free_options.md     |  11 --
 docs/c-api/coap.h/mg_coap_parse.md            |  22 ---
 docs/c-api/coap.h/mg_coap_send_ack.md         |  12 --
 docs/c-api/coap.h/mg_coap_send_message.md     |  19 --
 docs/c-api/coap.h/mg_set_protocol_coap.md     |  10 --
 docs/c-api/coap.h/struct_mg_coap_message.md   |  20 ---
 docs/c-api/coap.h/struct_mg_coap_option.md    |  16 --
 docs/c-api/dns.h/intro.md                     |  20 ---
 docs/c-api/dns.h/mg_dns_copy_questions.md     |  15 --
 docs/c-api/dns.h/mg_dns_encode_name.md        |  10 --
 docs/c-api/dns.h/mg_dns_encode_record.md      |  25 ---
 docs/c-api/dns.h/mg_dns_insert_header.md      |  13 --
 docs/c-api/dns.h/mg_dns_parse_record_data.md  |  20 ---
 docs/c-api/dns.h/mg_dns_uncompress_name.md    |  21 ---
 docs/c-api/dns.h/mg_parse_dns.md              |  10 --
 docs/c-api/dns.h/mg_send_dns_query.md         |  11 --
 docs/c-api/dns.h/mg_set_protocol_dns.md       |  19 --
 docs/c-api/dns.h/struct_mg_dns_message.md     |  18 --
 .../dns.h/struct_mg_dns_resource_record.md    |  17 --
 docs/c-api/dns_server.h/intro.md              |  12 --
 .../c-api/dns_server.h/mg_dns_create_reply.md |  36 ----
 .../c-api/dns_server.h/mg_dns_reply_record.md |  18 --
 docs/c-api/dns_server.h/mg_dns_send_reply.md  |  19 --
 docs/c-api/http.h/intro.md                    |  26 ---
 docs/c-api/http.h/mg_connect_ws.md            |  29 ---
 docs/c-api/http.h/mg_connect_ws_opt.md        |  14 --
 docs/c-api/http.h/mg_http_is_authorized.md    |  16 --
 .../mg_http_send_digest_auth_request.md       |  11 --
 .../c-api/http.h/mg_printf_websocket_frame.md |  14 --
 docs/c-api/http.h/mg_send_websocket_frame.md  |  26 ---
 docs/c-api/http.h/mg_send_websocket_framev.md |  12 --
 .../http.h/mg_send_websocket_handshake.md     |  22 ---
 .../http.h/mg_send_websocket_handshake2.md    |  19 --
 .../http.h/mg_send_websocket_handshake3.md    |  13 --
 .../http.h/mg_send_websocket_handshake3v.md   |  17 --
 .../http.h/mg_set_protocol_http_websocket.md  |  59 -------
 docs/c-api/http.h/mg_url_decode.md            |  19 --
 docs/c-api/http.h/struct_http_message.md      |  36 ----
 .../http.h/struct_mg_http_multipart_part.md   |  16 --
 docs/c-api/http.h/struct_mg_ssi_call_ctx.md   |  14 --
 docs/c-api/http.h/struct_websocket_message.md |  14 --
 docs/c-api/http_client.h/intro.md             |  12 --
 docs/c-api/http_client.h/mg_connect_http.md   |  33 ----
 .../http_client.h/mg_connect_http_opt.md      |  15 --
 .../mg_http_create_digest_auth_header.md      |  13 --
 docs/c-api/http_server.h/intro.md             |  32 ----
 .../http_server.h/mg_check_digest_auth.md     |  17 --
 .../http_server.h/mg_file_upload_handler.md   |  41 -----
 docs/c-api/http_server.h/mg_fu_fname_fn.md    |  11 --
 .../http_server.h/mg_get_http_basic_auth.md   |  14 --
 .../c-api/http_server.h/mg_get_http_header.md |  13 --
 docs/c-api/http_server.h/mg_get_http_var.md   |  17 --
 .../mg_http_check_digest_auth.md              |  12 --
 .../http_server.h/mg_http_parse_header.md     |  23 ---
 .../http_server.h/mg_http_reverse_proxy.md    |  19 --
 .../c-api/http_server.h/mg_http_send_error.md |  11 --
 .../http_server.h/mg_http_send_redirect.md    |  20 ---
 .../c-api/http_server.h/mg_http_serve_file.md |  28 ---
 docs/c-api/http_server.h/mg_parse_http.md     |  15 --
 .../http_server.h/mg_parse_http_basic_auth.md |  13 --
 .../c-api/http_server.h/mg_parse_multipart.md |  46 -----
 .../http_server.h/mg_printf_html_escape.md    |  10 --
 .../http_server.h/mg_printf_http_chunk.md     |  11 --
 .../mg_register_http_endpoint.md              |  36 ----
 docs/c-api/http_server.h/mg_send_head.md      |  22 ---
 .../c-api/http_server.h/mg_send_http_chunk.md |  25 ---
 .../http_server.h/mg_send_response_line.md    |  21 ---
 docs/c-api/http_server.h/mg_serve_http.md     |  28 ---
 .../struct_mg_serve_http_opts.md              | 165 ------------------
 docs/c-api/intro.md                           |  16 --
 docs/c-api/mbuf.h/intro.md                    |  20 ---
 docs/c-api/mbuf.h/mbuf_append.md              |  12 --
 docs/c-api/mbuf.h/mbuf_free.md                |  10 --
 docs/c-api/mbuf.h/mbuf_init.md                |  11 --
 docs/c-api/mbuf.h/mbuf_insert.md              |  14 --
 docs/c-api/mbuf.h/mbuf_remove.md              |  10 --
 docs/c-api/mbuf.h/mbuf_resize.md              |  13 --
 docs/c-api/mbuf.h/mbuf_trim.md                |  10 --
 docs/c-api/mbuf.h/struct_mbuf.md              |  14 --
 docs/c-api/mqtt.h/intro.md                    |  29 ---
 docs/c-api/mqtt.h/mg_mqtt_connack.md          |  10 --
 docs/c-api/mqtt.h/mg_mqtt_disconnect.md       |  10 --
 .../mqtt.h/mg_mqtt_match_topic_expression.md  |  12 --
 .../mqtt.h/mg_mqtt_next_subscribe_topic.md    |  15 --
 docs/c-api/mqtt.h/mg_mqtt_ping.md             |  10 --
 docs/c-api/mqtt.h/mg_mqtt_pong.md             |  10 --
 docs/c-api/mqtt.h/mg_mqtt_puback.md           |  10 --
 docs/c-api/mqtt.h/mg_mqtt_pubcomp.md          |  10 --
 docs/c-api/mqtt.h/mg_mqtt_publish.md          |  12 --
 docs/c-api/mqtt.h/mg_mqtt_pubrec.md           |  10 --
 docs/c-api/mqtt.h/mg_mqtt_pubrel.md           |  10 --
 docs/c-api/mqtt.h/mg_mqtt_suback.md           |  12 --
 docs/c-api/mqtt.h/mg_mqtt_subscribe.md        |  12 --
 docs/c-api/mqtt.h/mg_mqtt_unsuback.md         |  10 --
 docs/c-api/mqtt.h/mg_mqtt_unsubscribe.md      |  11 --
 .../mqtt.h/mg_mqtt_vmatch_topic_expression.md |  11 --
 docs/c-api/mqtt.h/mg_send_mqtt_handshake.md   |  10 --
 .../mqtt.h/mg_send_mqtt_handshake_opt.md      |  11 --
 docs/c-api/mqtt.h/mg_set_protocol_mqtt.md     |  20 ---
 .../c-api/mqtt.h/struct_mg_mqtt_proto_data.md |  13 --
 docs/c-api/mqtt_server.h/LIST_ENTRY.md        |  10 --
 docs/c-api/mqtt_server.h/intro.md             |  12 --
 .../mqtt_server.h/struct_mg_mqtt_broker.md    |  13 --
 .../mqtt_server.h/struct_mg_mqtt_session.md   |  17 --
 docs/c-api/net.h/intro.md                     |  41 -----
 docs/c-api/net.h/mg_add_sock.md               |  15 --
 docs/c-api/net.h/mg_add_sock_opt.md           |  15 --
 docs/c-api/net.h/mg_bind.md                   |  14 --
 docs/c-api/net.h/mg_bind_opt.md               |  27 ---
 docs/c-api/net.h/mg_broadcast.md              |  20 ---
 docs/c-api/net.h/mg_check_ip_acl.md           |  27 ---
 docs/c-api/net.h/mg_connect.md                |  14 --
 docs/c-api/net.h/mg_connect_opt.md            |  57 ------
 docs/c-api/net.h/mg_event_handler_t.md        |  12 --
 docs/c-api/net.h/mg_mgr_free.md               |  12 --
 docs/c-api/net.h/mg_mgr_init.md               |  15 --
 docs/c-api/net.h/mg_mgr_init_opt.md           |  14 --
 docs/c-api/net.h/mg_mgr_poll.md               |  15 --
 docs/c-api/net.h/mg_next.md                   |  20 ---
 docs/c-api/net.h/mg_printf.md                 |  12 --
 docs/c-api/net.h/mg_resolve.md                |  17 --
 docs/c-api/net.h/mg_send.md                   |  14 --
 docs/c-api/net.h/mg_set_ssl.md                |  22 ---
 docs/c-api/net.h/mg_set_timer.md              |  31 ----
 docs/c-api/net.h/mg_socketpair.md             |  12 --
 docs/c-api/net.h/mg_time.md                   |  10 --
 docs/c-api/net.h/mg_vprintf.md                |  10 --
 docs/c-api/net.h/struct_mg_add_sock_opts.md   |  18 --
 docs/c-api/net.h/struct_mg_bind_opts.md       |  44 -----
 docs/c-api/net.h/struct_mg_connect_opts.md    |  62 -------
 docs/c-api/net.h/struct_mg_connection.md      |  67 -------
 docs/c-api/net.h/struct_mg_mgr.md             |  22 ---
 docs/c-api/net.h/struct_mg_mgr_init_opts.md   |  27 ---
 docs/c-api/resolv.h/intro.md                  |  14 --
 docs/c-api/resolv.h/mg_resolve_async.md       |  11 --
 docs/c-api/resolv.h/mg_resolve_async_opt.md   |  30 ----
 .../resolv.h/mg_resolve_from_hosts_file.md    |  12 --
 docs/c-api/resolv.h/mg_set_nameserver.md      |  10 --
 .../resolv.h/struct_mg_resolve_async_opts.md  |  17 --
 docs/c-api/uri.h/intro.md                     |  11 --
 docs/c-api/uri.h/mg_assemble_uri.md           |  20 ---
 docs/c-api/uri.h/mg_parse_uri.md              |  33 ----
 docs/c-api/util.h/intro.md                    |  29 ---
 docs/c-api/util.h/mg_base64_decode.md         |  17 --
 docs/c-api/util.h/mg_base64_encode.md         |  12 --
 docs/c-api/util.h/mg_basic_auth_header.md     |  13 --
 docs/c-api/util.h/mg_conn_addr_to_str.md      |  22 ---
 docs/c-api/util.h/mg_fopen.md                 |  14 --
 docs/c-api/util.h/mg_fread.md                 |  12 --
 docs/c-api/util.h/mg_fwrite.md                |  12 --
 docs/c-api/util.h/mg_hexdump.md               |  15 --
 docs/c-api/util.h/mg_hexdump_connection.md    |  15 --
 docs/c-api/util.h/mg_hexdumpf.md              |  10 --
 docs/c-api/util.h/mg_is_big_endian.md         |  10 --
 docs/c-api/util.h/mg_mbuf_append_base64.md    |  10 --
 .../util.h/mg_mbuf_append_base64_putc.md      |  10 --
 docs/c-api/util.h/mg_open.md                  |  14 --
 docs/c-api/util.h/mg_skip.md                  |  17 --
 docs/c-api/util.h/mg_sock_addr_to_str.md      |  13 --
 docs/c-api/util.h/mg_sock_to_str.md           |  10 --
 docs/c-api/util.h/mg_start_thread.md          |  13 --
 docs/c-api/util.h/mg_stat.md                  |  14 --
 docs/c-api/util.h/mg_url_encode.md            |  13 --
 mongoose.c                                    | 120 ++++++-------
 mongoose.h                                    |  58 +++---
 src/{coap.c => mg_coap.c}                     |   4 +-
 src/{coap.h => mg_coap.h}                     |   0
 src/{common.h => mg_common.h}                 |   0
 src/{dns.c => mg_dns.c}                       |   4 +-
 src/{dns.h => mg_dns.h}                       |   2 +-
 src/{dns_server.c => mg_dns_server.c}         |   2 +-
 src/{dns_server.h => mg_dns_server.h}         |   2 +-
 src/{features.h => mg_features.h}             |   0
 src/{http.c => mg_http.c}                     |   4 +-
 src/{http.h => mg_http.h}                     |   2 +-
 src/{http_cgi.c => mg_http_cgi.c}             |   0
 src/{http_client.h => mg_http_client.h}       |   0
 src/{http_server.h => mg_http_server.h}       |   0
 src/{http_ssi.c => mg_http_ssi.c}             |   0
 src/{http_webdav.c => mg_http_webdav.c}       |   0
 src/{http_websocket.c => mg_http_websocket.c} |   0
 src/{internal.h => mg_internal.h}             |   4 +-
 src/{modules.mk => mg_modules.mk}             |  82 ++++-----
 src/{mqtt.c => mg_mqtt.c}                     |   4 +-
 src/{mqtt.h => mg_mqtt.h}                     |   2 +-
 src/{mqtt_client.h => mg_mqtt_client.h}       |   0
 src/{mqtt_server.c => mg_mqtt_server.c}       |   4 +-
 src/{mqtt_server.h => mg_mqtt_server.h}       |   2 +-
 src/{net.c => mg_net.c}                       |   8 +-
 src/{net.h => mg_net.h}                       |   4 +-
 src/{net_if.c => mg_net_if.c}                 |   6 +-
 src/{net_if.h => mg_net_if.h}                 |   0
 src/{net_if_socket.c => mg_net_if_socket.c}   |   6 +-
 src/{net_if_socket.h => mg_net_if_socket.h}   |   2 +-
 src/{net_if_socks.c => mg_net_if_socks.c}     |   0
 src/{net_if_socks.h => mg_net_if_socks.h}     |   2 +-
 src/{resolv.c => mg_resolv.c}                 |   4 +-
 src/{resolv.h => mg_resolv.h}                 |   2 +-
 src/{sntp.c => mg_sntp.c}                     |   6 +-
 src/{sntp.h => mg_sntp.h}                     |   0
 src/{socks.c => mg_socks.c}                   |   4 +-
 src/{socks.h => mg_socks.h}                   |   0
 src/{ssl_if.h => mg_ssl_if.h}                 |   0
 src/{ssl_if_mbedtls.c => mg_ssl_if_mbedtls.c} |   0
 src/{ssl_if_openssl.c => mg_ssl_if_openssl.c} |   0
 src/{uri.c => mg_uri.c}                       |   4 +-
 src/{uri.h => mg_uri.h}                       |   2 +-
 src/{util.c => mg_util.c}                     |   4 +-
 src/{util.h => mg_util.h}                     |   4 +-
 test/Makefile                                 |   2 +-
 test/unit_test.c                              |   2 +-
 214 files changed, 179 insertions(+), 3304 deletions(-)
 delete mode 100644 docs/c-api/coap.h/intro.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_add_option.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_compose.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_free_options.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_parse.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_send_ack.md
 delete mode 100644 docs/c-api/coap.h/mg_coap_send_message.md
 delete mode 100644 docs/c-api/coap.h/mg_set_protocol_coap.md
 delete mode 100644 docs/c-api/coap.h/struct_mg_coap_message.md
 delete mode 100644 docs/c-api/coap.h/struct_mg_coap_option.md
 delete mode 100644 docs/c-api/dns.h/intro.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_copy_questions.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_encode_name.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_encode_record.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_insert_header.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_parse_record_data.md
 delete mode 100644 docs/c-api/dns.h/mg_dns_uncompress_name.md
 delete mode 100644 docs/c-api/dns.h/mg_parse_dns.md
 delete mode 100644 docs/c-api/dns.h/mg_send_dns_query.md
 delete mode 100644 docs/c-api/dns.h/mg_set_protocol_dns.md
 delete mode 100644 docs/c-api/dns.h/struct_mg_dns_message.md
 delete mode 100644 docs/c-api/dns.h/struct_mg_dns_resource_record.md
 delete mode 100644 docs/c-api/dns_server.h/intro.md
 delete mode 100644 docs/c-api/dns_server.h/mg_dns_create_reply.md
 delete mode 100644 docs/c-api/dns_server.h/mg_dns_reply_record.md
 delete mode 100644 docs/c-api/dns_server.h/mg_dns_send_reply.md
 delete mode 100644 docs/c-api/http.h/intro.md
 delete mode 100644 docs/c-api/http.h/mg_connect_ws.md
 delete mode 100644 docs/c-api/http.h/mg_connect_ws_opt.md
 delete mode 100644 docs/c-api/http.h/mg_http_is_authorized.md
 delete mode 100644 docs/c-api/http.h/mg_http_send_digest_auth_request.md
 delete mode 100644 docs/c-api/http.h/mg_printf_websocket_frame.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_frame.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_framev.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_handshake.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_handshake2.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_handshake3.md
 delete mode 100644 docs/c-api/http.h/mg_send_websocket_handshake3v.md
 delete mode 100644 docs/c-api/http.h/mg_set_protocol_http_websocket.md
 delete mode 100644 docs/c-api/http.h/mg_url_decode.md
 delete mode 100644 docs/c-api/http.h/struct_http_message.md
 delete mode 100644 docs/c-api/http.h/struct_mg_http_multipart_part.md
 delete mode 100644 docs/c-api/http.h/struct_mg_ssi_call_ctx.md
 delete mode 100644 docs/c-api/http.h/struct_websocket_message.md
 delete mode 100644 docs/c-api/http_client.h/intro.md
 delete mode 100644 docs/c-api/http_client.h/mg_connect_http.md
 delete mode 100644 docs/c-api/http_client.h/mg_connect_http_opt.md
 delete mode 100644 docs/c-api/http_client.h/mg_http_create_digest_auth_header.md
 delete mode 100644 docs/c-api/http_server.h/intro.md
 delete mode 100644 docs/c-api/http_server.h/mg_check_digest_auth.md
 delete mode 100644 docs/c-api/http_server.h/mg_file_upload_handler.md
 delete mode 100644 docs/c-api/http_server.h/mg_fu_fname_fn.md
 delete mode 100644 docs/c-api/http_server.h/mg_get_http_basic_auth.md
 delete mode 100644 docs/c-api/http_server.h/mg_get_http_header.md
 delete mode 100644 docs/c-api/http_server.h/mg_get_http_var.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_check_digest_auth.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_parse_header.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_reverse_proxy.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_send_error.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_send_redirect.md
 delete mode 100644 docs/c-api/http_server.h/mg_http_serve_file.md
 delete mode 100644 docs/c-api/http_server.h/mg_parse_http.md
 delete mode 100644 docs/c-api/http_server.h/mg_parse_http_basic_auth.md
 delete mode 100644 docs/c-api/http_server.h/mg_parse_multipart.md
 delete mode 100644 docs/c-api/http_server.h/mg_printf_html_escape.md
 delete mode 100644 docs/c-api/http_server.h/mg_printf_http_chunk.md
 delete mode 100644 docs/c-api/http_server.h/mg_register_http_endpoint.md
 delete mode 100644 docs/c-api/http_server.h/mg_send_head.md
 delete mode 100644 docs/c-api/http_server.h/mg_send_http_chunk.md
 delete mode 100644 docs/c-api/http_server.h/mg_send_response_line.md
 delete mode 100644 docs/c-api/http_server.h/mg_serve_http.md
 delete mode 100644 docs/c-api/http_server.h/struct_mg_serve_http_opts.md
 delete mode 100644 docs/c-api/intro.md
 delete mode 100644 docs/c-api/mbuf.h/intro.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_append.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_free.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_init.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_insert.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_remove.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_resize.md
 delete mode 100644 docs/c-api/mbuf.h/mbuf_trim.md
 delete mode 100644 docs/c-api/mbuf.h/struct_mbuf.md
 delete mode 100644 docs/c-api/mqtt.h/intro.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_connack.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_disconnect.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_match_topic_expression.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_next_subscribe_topic.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_ping.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_pong.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_puback.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_pubcomp.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_publish.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_pubrec.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_pubrel.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_suback.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_subscribe.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_unsuback.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_unsubscribe.md
 delete mode 100644 docs/c-api/mqtt.h/mg_mqtt_vmatch_topic_expression.md
 delete mode 100644 docs/c-api/mqtt.h/mg_send_mqtt_handshake.md
 delete mode 100644 docs/c-api/mqtt.h/mg_send_mqtt_handshake_opt.md
 delete mode 100644 docs/c-api/mqtt.h/mg_set_protocol_mqtt.md
 delete mode 100644 docs/c-api/mqtt.h/struct_mg_mqtt_proto_data.md
 delete mode 100644 docs/c-api/mqtt_server.h/LIST_ENTRY.md
 delete mode 100644 docs/c-api/mqtt_server.h/intro.md
 delete mode 100644 docs/c-api/mqtt_server.h/struct_mg_mqtt_broker.md
 delete mode 100644 docs/c-api/mqtt_server.h/struct_mg_mqtt_session.md
 delete mode 100644 docs/c-api/net.h/intro.md
 delete mode 100644 docs/c-api/net.h/mg_add_sock.md
 delete mode 100644 docs/c-api/net.h/mg_add_sock_opt.md
 delete mode 100644 docs/c-api/net.h/mg_bind.md
 delete mode 100644 docs/c-api/net.h/mg_bind_opt.md
 delete mode 100644 docs/c-api/net.h/mg_broadcast.md
 delete mode 100644 docs/c-api/net.h/mg_check_ip_acl.md
 delete mode 100644 docs/c-api/net.h/mg_connect.md
 delete mode 100644 docs/c-api/net.h/mg_connect_opt.md
 delete mode 100644 docs/c-api/net.h/mg_event_handler_t.md
 delete mode 100644 docs/c-api/net.h/mg_mgr_free.md
 delete mode 100644 docs/c-api/net.h/mg_mgr_init.md
 delete mode 100644 docs/c-api/net.h/mg_mgr_init_opt.md
 delete mode 100644 docs/c-api/net.h/mg_mgr_poll.md
 delete mode 100644 docs/c-api/net.h/mg_next.md
 delete mode 100644 docs/c-api/net.h/mg_printf.md
 delete mode 100644 docs/c-api/net.h/mg_resolve.md
 delete mode 100644 docs/c-api/net.h/mg_send.md
 delete mode 100644 docs/c-api/net.h/mg_set_ssl.md
 delete mode 100644 docs/c-api/net.h/mg_set_timer.md
 delete mode 100644 docs/c-api/net.h/mg_socketpair.md
 delete mode 100644 docs/c-api/net.h/mg_time.md
 delete mode 100644 docs/c-api/net.h/mg_vprintf.md
 delete mode 100644 docs/c-api/net.h/struct_mg_add_sock_opts.md
 delete mode 100644 docs/c-api/net.h/struct_mg_bind_opts.md
 delete mode 100644 docs/c-api/net.h/struct_mg_connect_opts.md
 delete mode 100644 docs/c-api/net.h/struct_mg_connection.md
 delete mode 100644 docs/c-api/net.h/struct_mg_mgr.md
 delete mode 100644 docs/c-api/net.h/struct_mg_mgr_init_opts.md
 delete mode 100644 docs/c-api/resolv.h/intro.md
 delete mode 100644 docs/c-api/resolv.h/mg_resolve_async.md
 delete mode 100644 docs/c-api/resolv.h/mg_resolve_async_opt.md
 delete mode 100644 docs/c-api/resolv.h/mg_resolve_from_hosts_file.md
 delete mode 100644 docs/c-api/resolv.h/mg_set_nameserver.md
 delete mode 100644 docs/c-api/resolv.h/struct_mg_resolve_async_opts.md
 delete mode 100644 docs/c-api/uri.h/intro.md
 delete mode 100644 docs/c-api/uri.h/mg_assemble_uri.md
 delete mode 100644 docs/c-api/uri.h/mg_parse_uri.md
 delete mode 100644 docs/c-api/util.h/intro.md
 delete mode 100644 docs/c-api/util.h/mg_base64_decode.md
 delete mode 100644 docs/c-api/util.h/mg_base64_encode.md
 delete mode 100644 docs/c-api/util.h/mg_basic_auth_header.md
 delete mode 100644 docs/c-api/util.h/mg_conn_addr_to_str.md
 delete mode 100644 docs/c-api/util.h/mg_fopen.md
 delete mode 100644 docs/c-api/util.h/mg_fread.md
 delete mode 100644 docs/c-api/util.h/mg_fwrite.md
 delete mode 100644 docs/c-api/util.h/mg_hexdump.md
 delete mode 100644 docs/c-api/util.h/mg_hexdump_connection.md
 delete mode 100644 docs/c-api/util.h/mg_hexdumpf.md
 delete mode 100644 docs/c-api/util.h/mg_is_big_endian.md
 delete mode 100644 docs/c-api/util.h/mg_mbuf_append_base64.md
 delete mode 100644 docs/c-api/util.h/mg_mbuf_append_base64_putc.md
 delete mode 100644 docs/c-api/util.h/mg_open.md
 delete mode 100644 docs/c-api/util.h/mg_skip.md
 delete mode 100644 docs/c-api/util.h/mg_sock_addr_to_str.md
 delete mode 100644 docs/c-api/util.h/mg_sock_to_str.md
 delete mode 100644 docs/c-api/util.h/mg_start_thread.md
 delete mode 100644 docs/c-api/util.h/mg_stat.md
 delete mode 100644 docs/c-api/util.h/mg_url_encode.md
 rename src/{coap.c => mg_coap.c} (99%)
 rename src/{coap.h => mg_coap.h} (100%)
 rename src/{common.h => mg_common.h} (100%)
 rename src/{dns.c => mg_dns.c} (99%)
 rename src/{dns.h => mg_dns.h} (99%)
 rename src/{dns_server.c => mg_dns_server.c} (97%)
 rename src/{dns_server.h => mg_dns_server.h} (98%)
 rename src/{features.h => mg_features.h} (100%)
 rename src/{http.c => mg_http.c} (99%)
 rename src/{http.h => mg_http.h} (99%)
 rename src/{http_cgi.c => mg_http_cgi.c} (100%)
 rename src/{http_client.h => mg_http_client.h} (100%)
 rename src/{http_server.h => mg_http_server.h} (100%)
 rename src/{http_ssi.c => mg_http_ssi.c} (100%)
 rename src/{http_webdav.c => mg_http_webdav.c} (100%)
 rename src/{http_websocket.c => mg_http_websocket.c} (100%)
 rename src/{internal.h => mg_internal.h} (98%)
 rename src/{modules.mk => mg_modules.mk} (72%)
 rename src/{mqtt.c => mg_mqtt.c} (99%)
 rename src/{mqtt.h => mg_mqtt.h} (99%)
 rename src/{mqtt_client.h => mg_mqtt_client.h} (100%)
 rename src/{mqtt_server.c => mg_mqtt_server.c} (98%)
 rename src/{mqtt_server.h => mg_mqtt_server.h} (98%)
 rename src/{net.c => mg_net.c} (99%)
 rename src/{net.h => mg_net.h} (99%)
 rename src/{net_if.c => mg_net_if.c} (89%)
 rename src/{net_if.h => mg_net_if.h} (100%)
 rename src/{net_if_socket.c => mg_net_if_socket.c} (99%)
 rename src/{net_if_socket.h => mg_net_if_socket.h} (93%)
 rename src/{net_if_socks.c => mg_net_if_socks.c} (100%)
 rename src/{net_if_socks.h => mg_net_if_socks.h} (92%)
 rename src/{resolv.c => mg_resolv.c} (99%)
 rename src/{resolv.h => mg_resolv.h} (98%)
 rename src/{sntp.c => mg_sntp.c} (98%)
 rename src/{sntp.h => mg_sntp.h} (100%)
 rename src/{socks.c => mg_socks.c} (98%)
 rename src/{socks.h => mg_socks.h} (100%)
 rename src/{ssl_if.h => mg_ssl_if.h} (100%)
 rename src/{ssl_if_mbedtls.c => mg_ssl_if_mbedtls.c} (100%)
 rename src/{ssl_if_openssl.c => mg_ssl_if_openssl.c} (100%)
 rename src/{uri.c => mg_uri.c} (98%)
 rename src/{uri.h => mg_uri.h} (98%)
 rename src/{util.c => mg_util.c} (99%)
 rename src/{util.h => mg_util.h} (98%)

diff --git a/docs/c-api/coap.h/intro.md b/docs/c-api/coap.h/intro.md
deleted file mode 100644
index 2e3b8a448..000000000
--- a/docs/c-api/coap.h/intro.md
+++ /dev/null
@@ -1,26 +0,0 @@
----
-title: "CoAP API reference"
-symbol_kind: "intro"
-decl_name: "coap.h"
-items:
-  - { name: mg_coap_add_option.md }
-  - { name: mg_coap_compose.md }
-  - { name: mg_coap_free_options.md }
-  - { name: mg_coap_parse.md }
-  - { name: mg_coap_send_ack.md }
-  - { name: mg_coap_send_message.md }
-  - { name: mg_set_protocol_coap.md }
-  - { name: struct_mg_coap_message.md }
-  - { name: struct_mg_coap_option.md }
----
-
-CoAP message format:
-
-```
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
-|Ver| T | TKL | Code | Message ID | Token (if any, TKL bytes) ...
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
-| Options (if any) ...            |1 1 1 1 1 1 1 1| Payload (if any) ...
-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
-```
-
diff --git a/docs/c-api/coap.h/mg_coap_add_option.md b/docs/c-api/coap.h/mg_coap_add_option.md
deleted file mode 100644
index 83e91d5f3..000000000
--- a/docs/c-api/coap.h/mg_coap_add_option.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_coap_add_option()"
-decl_name: "mg_coap_add_option"
-symbol_kind: "func"
-signature: |
-  struct mg_coap_option *mg_coap_add_option(struct mg_coap_message *cm,
-                                            uint32_t number, char *value,
-                                            size_t len);
----
-
-Adds a new option to mg_coap_message structure.
-Returns pointer to the newly created option.
-Note: options must be freed by using mg_coap_free_options 
-
diff --git a/docs/c-api/coap.h/mg_coap_compose.md b/docs/c-api/coap.h/mg_coap_compose.md
deleted file mode 100644
index 844c1b61b..000000000
--- a/docs/c-api/coap.h/mg_coap_compose.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_coap_compose()"
-decl_name: "mg_coap_compose"
-symbol_kind: "func"
-signature: |
-  uint32_t mg_coap_compose(struct mg_coap_message *cm, struct mbuf *io);
----
-
-Composes CoAP message from mg_coap_message structure.
-This is a helper function.
-Return value: see `mg_coap_send_message()` 
-
diff --git a/docs/c-api/coap.h/mg_coap_free_options.md b/docs/c-api/coap.h/mg_coap_free_options.md
deleted file mode 100644
index d429cf49e..000000000
--- a/docs/c-api/coap.h/mg_coap_free_options.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_coap_free_options()"
-decl_name: "mg_coap_free_options"
-symbol_kind: "func"
-signature: |
-  void mg_coap_free_options(struct mg_coap_message *cm);
----
-
-Frees the memory allocated for options.
-If the cm parameter doesn't contain any option it does nothing. 
-
diff --git a/docs/c-api/coap.h/mg_coap_parse.md b/docs/c-api/coap.h/mg_coap_parse.md
deleted file mode 100644
index 86885229d..000000000
--- a/docs/c-api/coap.h/mg_coap_parse.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "mg_coap_parse()"
-decl_name: "mg_coap_parse"
-symbol_kind: "func"
-signature: |
-  uint32_t mg_coap_parse(struct mbuf *io, struct mg_coap_message *cm);
----
-
-Parses CoAP message and fills mg_coap_message and returns cm->flags.
-This is a helper function.
-
-NOTE: usually CoAP works over UDP, so lack of data means format error.
-But, in theory, it is possible to use CoAP over TCP (according to RFC)
-
-The caller has to check results and treat COAP_NOT_ENOUGH_DATA according to
-underlying protocol:
-
-- in case of UDP COAP_NOT_ENOUGH_DATA means COAP_FORMAT_ERROR,
-- in case of TCP client can try to receive more data
-
-Return value: see `mg_coap_send_message()` 
-
diff --git a/docs/c-api/coap.h/mg_coap_send_ack.md b/docs/c-api/coap.h/mg_coap_send_ack.md
deleted file mode 100644
index 1475a9c58..000000000
--- a/docs/c-api/coap.h/mg_coap_send_ack.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_coap_send_ack()"
-decl_name: "mg_coap_send_ack"
-symbol_kind: "func"
-signature: |
-  uint32_t mg_coap_send_ack(struct mg_connection *nc, uint16_t msg_id);
----
-
-Composes CoAP acknowledgement from `mg_coap_message`
-and sends it into `nc` connection.
-Return value: see `mg_coap_send_message()` 
-
diff --git a/docs/c-api/coap.h/mg_coap_send_message.md b/docs/c-api/coap.h/mg_coap_send_message.md
deleted file mode 100644
index a1acc01e5..000000000
--- a/docs/c-api/coap.h/mg_coap_send_message.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_coap_send_message()"
-decl_name: "mg_coap_send_message"
-symbol_kind: "func"
-signature: |
-  uint32_t mg_coap_send_message(struct mg_connection *nc,
-                                struct mg_coap_message *cm);
----
-
-Composes a CoAP message from `mg_coap_message`
-and sends it into `nc` connection.
-Returns 0 on success. On error, it is a bitmask:
-
-- `#define MG_COAP_ERROR 0x10000`
-- `#define MG_COAP_FORMAT_ERROR (MG_COAP_ERROR | 0x20000)`
-- `#define MG_COAP_IGNORE (MG_COAP_ERROR | 0x40000)`
-- `#define MG_COAP_NOT_ENOUGH_DATA (MG_COAP_ERROR | 0x80000)`
-- `#define MG_COAP_NETWORK_ERROR (MG_COAP_ERROR | 0x100000)` 
-
diff --git a/docs/c-api/coap.h/mg_set_protocol_coap.md b/docs/c-api/coap.h/mg_set_protocol_coap.md
deleted file mode 100644
index 523ae7cb4..000000000
--- a/docs/c-api/coap.h/mg_set_protocol_coap.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_set_protocol_coap()"
-decl_name: "mg_set_protocol_coap"
-symbol_kind: "func"
-signature: |
-  int mg_set_protocol_coap(struct mg_connection *nc);
----
-
-Sets CoAP protocol handler - triggers CoAP specific events. 
-
diff --git a/docs/c-api/coap.h/struct_mg_coap_message.md b/docs/c-api/coap.h/struct_mg_coap_message.md
deleted file mode 100644
index 0ea618a90..000000000
--- a/docs/c-api/coap.h/struct_mg_coap_message.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "struct mg_coap_message"
-decl_name: "struct mg_coap_message"
-symbol_kind: "struct"
-signature: |
-  struct mg_coap_message {
-    uint32_t flags;
-    uint8_t msg_type;
-    uint8_t code_class;
-    uint8_t code_detail;
-    uint16_t msg_id;
-    struct mg_str token;
-    struct mg_coap_option *options;
-    struct mg_str payload;
-    struct mg_coap_option *optiomg_tail;
-  };
----
-
-CoAP message. See RFC 7252 for details. 
-
diff --git a/docs/c-api/coap.h/struct_mg_coap_option.md b/docs/c-api/coap.h/struct_mg_coap_option.md
deleted file mode 100644
index b5eeb15fa..000000000
--- a/docs/c-api/coap.h/struct_mg_coap_option.md
+++ /dev/null
@@ -1,16 +0,0 @@
----
-title: "struct mg_coap_option"
-decl_name: "struct mg_coap_option"
-symbol_kind: "struct"
-signature: |
-  struct mg_coap_option {
-    struct mg_coap_option *next;
-    uint32_t number;
-    struct mg_str value;
-  };
----
-
-CoAP options.
-Use mg_coap_add_option and mg_coap_free_options
-for creation and destruction. 
-
diff --git a/docs/c-api/dns.h/intro.md b/docs/c-api/dns.h/intro.md
deleted file mode 100644
index 0604def0b..000000000
--- a/docs/c-api/dns.h/intro.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "DNS API reference"
-symbol_kind: "intro"
-decl_name: "dns.h"
-items:
-  - { name: mg_dns_copy_questions.md }
-  - { name: mg_dns_encode_name.md }
-  - { name: mg_dns_encode_record.md }
-  - { name: mg_dns_insert_header.md }
-  - { name: mg_dns_parse_record_data.md }
-  - { name: mg_dns_uncompress_name.md }
-  - { name: mg_parse_dns.md }
-  - { name: mg_send_dns_query.md }
-  - { name: mg_set_protocol_dns.md }
-  - { name: struct_mg_dns_message.md }
-  - { name: struct_mg_dns_resource_record.md }
----
-
-
-
diff --git a/docs/c-api/dns.h/mg_dns_copy_questions.md b/docs/c-api/dns.h/mg_dns_copy_questions.md
deleted file mode 100644
index f6f7dcb76..000000000
--- a/docs/c-api/dns.h/mg_dns_copy_questions.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_dns_copy_questions()"
-decl_name: "mg_dns_copy_questions"
-symbol_kind: "func"
-signature: |
-  int mg_dns_copy_questions(struct mbuf *io, struct mg_dns_message *msg);
----
-
-Appends already encoded questions from an existing message.
-
-This is useful when generating a DNS reply message which includes
-all question records.
-
-Returns the number of appended bytes. 
-
diff --git a/docs/c-api/dns.h/mg_dns_encode_name.md b/docs/c-api/dns.h/mg_dns_encode_name.md
deleted file mode 100644
index 1b0e2a781..000000000
--- a/docs/c-api/dns.h/mg_dns_encode_name.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_dns_encode_name()"
-decl_name: "mg_dns_encode_name"
-symbol_kind: "func"
-signature: |
-  int mg_dns_encode_name(struct mbuf *io, const char *name, size_t len);
----
-
-Encodes a DNS name. 
-
diff --git a/docs/c-api/dns.h/mg_dns_encode_record.md b/docs/c-api/dns.h/mg_dns_encode_record.md
deleted file mode 100644
index 7c9f2cf2b..000000000
--- a/docs/c-api/dns.h/mg_dns_encode_record.md
+++ /dev/null
@@ -1,25 +0,0 @@
----
-title: "mg_dns_encode_record()"
-decl_name: "mg_dns_encode_record"
-symbol_kind: "func"
-signature: |
-  int mg_dns_encode_record(struct mbuf *io, struct mg_dns_resource_record *rr,
-                           const char *name, size_t nlen, const void *rdata,
-                           size_t rlen);
----
-
-Encodes and appends a DNS resource record to an IO buffer.
-
-The record metadata is taken from the `rr` parameter, while the name and data
-are taken from the parameters, encoded in the appropriate format depending on
-record type and stored in the IO buffer. The encoded values might contain
-offsets within the IO buffer. It's thus important that the IO buffer doesn't
-get trimmed while a sequence of records are encoded while preparing a DNS
-reply.
-
-This function doesn't update the `name` and `rdata` pointers in the `rr`
-struct because they might be invalidated as soon as the IO buffer grows
-again.
-
-Returns the number of bytes appended or -1 in case of error. 
-
diff --git a/docs/c-api/dns.h/mg_dns_insert_header.md b/docs/c-api/dns.h/mg_dns_insert_header.md
deleted file mode 100644
index 52b2ac3ef..000000000
--- a/docs/c-api/dns.h/mg_dns_insert_header.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_dns_insert_header()"
-decl_name: "mg_dns_insert_header"
-symbol_kind: "func"
-signature: |
-  int mg_dns_insert_header(struct mbuf *io, size_t pos,
-                           struct mg_dns_message *msg);
----
-
-Inserts a DNS header to an IO buffer.
-
-Returns the number of bytes inserted. 
-
diff --git a/docs/c-api/dns.h/mg_dns_parse_record_data.md b/docs/c-api/dns.h/mg_dns_parse_record_data.md
deleted file mode 100644
index efe56ef4a..000000000
--- a/docs/c-api/dns.h/mg_dns_parse_record_data.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_dns_parse_record_data()"
-decl_name: "mg_dns_parse_record_data"
-symbol_kind: "func"
-signature: |
-  int mg_dns_parse_record_data(struct mg_dns_message *msg,
-                               struct mg_dns_resource_record *rr, void *data,
-                               size_t data_len);
----
-
-Parses the record data from a DNS resource record.
-
- - A:     struct in_addr *ina
- - AAAA:  struct in6_addr *ina
- - CNAME: char buffer
-
-Returns -1 on error.
-
-TODO(mkm): MX 
-
diff --git a/docs/c-api/dns.h/mg_dns_uncompress_name.md b/docs/c-api/dns.h/mg_dns_uncompress_name.md
deleted file mode 100644
index 5e5fa53b0..000000000
--- a/docs/c-api/dns.h/mg_dns_uncompress_name.md
+++ /dev/null
@@ -1,21 +0,0 @@
----
-title: "mg_dns_uncompress_name()"
-decl_name: "mg_dns_uncompress_name"
-symbol_kind: "func"
-signature: |
-  size_t mg_dns_uncompress_name(struct mg_dns_message *msg, struct mg_str *name,
-                                char *dst, int dst_len);
----
-
-Uncompresses a DNS compressed name.
-
-The containing DNS message is required because of the compressed encoding
-and reference suffixes present elsewhere in the packet.
-
-If the name is less than `dst_len` characters long, the remainder
-of `dst` is terminated with `\0` characters. Otherwise, `dst` is not
-terminated.
-
-If `dst_len` is 0 `dst` can be NULL.
-Returns the uncompressed name length. 
-
diff --git a/docs/c-api/dns.h/mg_parse_dns.md b/docs/c-api/dns.h/mg_parse_dns.md
deleted file mode 100644
index 3e28efeed..000000000
--- a/docs/c-api/dns.h/mg_parse_dns.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_parse_dns()"
-decl_name: "mg_parse_dns"
-symbol_kind: "func"
-signature: |
-  int mg_parse_dns(const char *buf, int len, struct mg_dns_message *msg);
----
-
-Low-level: parses a DNS response. 
-
diff --git a/docs/c-api/dns.h/mg_send_dns_query.md b/docs/c-api/dns.h/mg_send_dns_query.md
deleted file mode 100644
index a6b15da96..000000000
--- a/docs/c-api/dns.h/mg_send_dns_query.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_send_dns_query()"
-decl_name: "mg_send_dns_query"
-symbol_kind: "func"
-signature: |
-  void mg_send_dns_query(struct mg_connection *nc, const char *name,
-                         int query_type);
----
-
-Sends a DNS query to the remote end. 
-
diff --git a/docs/c-api/dns.h/mg_set_protocol_dns.md b/docs/c-api/dns.h/mg_set_protocol_dns.md
deleted file mode 100644
index fdf5ab59e..000000000
--- a/docs/c-api/dns.h/mg_set_protocol_dns.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_set_protocol_dns()"
-decl_name: "mg_set_protocol_dns"
-symbol_kind: "func"
-signature: |
-  void mg_set_protocol_dns(struct mg_connection *nc);
----
-
-Attaches a built-in DNS event handler to the given listening connection.
-
-The DNS event handler parses the incoming UDP packets, treating them as DNS
-requests. If an incoming packet gets successfully parsed by the DNS event
-handler, a user event handler will receive an `MG_DNS_REQUEST` event, with
-`ev_data` pointing to the parsed `struct mg_dns_message`.
-
-See
-[captive_dns_server](https://github.com/cesanta/mongoose/tree/master/examples/captive_dns_server)
-example on how to handle DNS request and send DNS reply. 
-
diff --git a/docs/c-api/dns.h/struct_mg_dns_message.md b/docs/c-api/dns.h/struct_mg_dns_message.md
deleted file mode 100644
index 9838bec9c..000000000
--- a/docs/c-api/dns.h/struct_mg_dns_message.md
+++ /dev/null
@@ -1,18 +0,0 @@
----
-title: "struct mg_dns_message"
-decl_name: "struct mg_dns_message"
-symbol_kind: "struct"
-signature: |
-  struct mg_dns_message {
-    struct mg_str pkt; /* packet body */
-    uint16_t flags;
-    uint16_t transaction_id;
-    int num_questions;
-    int num_answers;
-    struct mg_dns_resource_record questions[MG_MAX_DNS_QUESTIONS];
-    struct mg_dns_resource_record answers[MG_MAX_DNS_ANSWERS];
-  };
----
-
-DNS message (request and response). 
-
diff --git a/docs/c-api/dns.h/struct_mg_dns_resource_record.md b/docs/c-api/dns.h/struct_mg_dns_resource_record.md
deleted file mode 100644
index 8ff7af403..000000000
--- a/docs/c-api/dns.h/struct_mg_dns_resource_record.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "struct mg_dns_resource_record"
-decl_name: "struct mg_dns_resource_record"
-symbol_kind: "struct"
-signature: |
-  struct mg_dns_resource_record {
-    struct mg_str name; /* buffer with compressed name */
-    int rtype;
-    int rclass;
-    int ttl;
-    enum mg_dns_resource_record_kind kind;
-    struct mg_str rdata; /* protocol data (can be a compressed name) */
-  };
----
-
-DNS resource record. 
-
diff --git a/docs/c-api/dns_server.h/intro.md b/docs/c-api/dns_server.h/intro.md
deleted file mode 100644
index 16ba0fc90..000000000
--- a/docs/c-api/dns_server.h/intro.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "DNS server API reference"
-symbol_kind: "intro"
-decl_name: "dns_server.h"
-items:
-  - { name: mg_dns_create_reply.md }
-  - { name: mg_dns_reply_record.md }
-  - { name: mg_dns_send_reply.md }
----
-
-Disabled by default; enable with `-DMG_ENABLE_DNS_SERVER`.
-
diff --git a/docs/c-api/dns_server.h/mg_dns_create_reply.md b/docs/c-api/dns_server.h/mg_dns_create_reply.md
deleted file mode 100644
index 40c6f225d..000000000
--- a/docs/c-api/dns_server.h/mg_dns_create_reply.md
+++ /dev/null
@@ -1,36 +0,0 @@
----
-title: "mg_dns_create_reply()"
-decl_name: "mg_dns_create_reply"
-symbol_kind: "func"
-signature: |
-  struct mg_dns_reply mg_dns_create_reply(struct mbuf *io,
-                                          struct mg_dns_message *msg);
----
-
-Creates a DNS reply.
-
-The reply will be based on an existing query message `msg`.
-The query body will be appended to the output buffer.
-"reply + recursion allowed" will be added to the message flags and the
-message's num_answers will be set to 0.
-
-Answer records can be appended with `mg_dns_send_reply` or by lower
-level function defined in the DNS API.
-
-In order to send a reply use `mg_dns_send_reply`.
-It's possible to use a connection's send buffer as reply buffer,
-and it will work for both UDP and TCP connections.
-
-Example:
-
-```c
-reply = mg_dns_create_reply(&nc->send_mbuf, msg);
-for (i = 0; i < msg->num_questions; i++) {
-  rr = &msg->questions[i];
-  if (rr->rtype == MG_DNS_A_RECORD) {
-    mg_dns_reply_record(&reply, rr, 3600, &dummy_ip_addr, 4);
-  }
-}
-mg_dns_send_reply(nc, &reply);
-``` 
-
diff --git a/docs/c-api/dns_server.h/mg_dns_reply_record.md b/docs/c-api/dns_server.h/mg_dns_reply_record.md
deleted file mode 100644
index 408f705f0..000000000
--- a/docs/c-api/dns_server.h/mg_dns_reply_record.md
+++ /dev/null
@@ -1,18 +0,0 @@
----
-title: "mg_dns_reply_record()"
-decl_name: "mg_dns_reply_record"
-symbol_kind: "func"
-signature: |
-  int mg_dns_reply_record(struct mg_dns_reply *reply,
-                          struct mg_dns_resource_record *question,
-                          const char *name, int rtype, int ttl, const void *rdata,
-                          size_t rdata_len);
----
-
-Appends a DNS reply record to the IO buffer and to the DNS message.
-
-The message's num_answers field will be incremented. It's the caller's duty
-to ensure num_answers is properly initialised.
-
-Returns -1 on error. 
-
diff --git a/docs/c-api/dns_server.h/mg_dns_send_reply.md b/docs/c-api/dns_server.h/mg_dns_send_reply.md
deleted file mode 100644
index 0460e7310..000000000
--- a/docs/c-api/dns_server.h/mg_dns_send_reply.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_dns_send_reply()"
-decl_name: "mg_dns_send_reply"
-symbol_kind: "func"
-signature: |
-  void mg_dns_send_reply(struct mg_connection *nc, struct mg_dns_reply *r);
----
-
-Sends a DNS reply through a connection.
-
-The DNS data is stored in an IO buffer pointed by reply structure in `r`.
-This function mutates the content of that buffer in order to ensure that
-the DNS header reflects the size and flags of the message, that might have
-been updated either with `mg_dns_reply_record` or by direct manipulation of
-`r->message`.
-
-Once sent, the IO buffer will be trimmed unless the reply IO buffer
-is the connection's send buffer and the connection is not in UDP mode. 
-
diff --git a/docs/c-api/http.h/intro.md b/docs/c-api/http.h/intro.md
deleted file mode 100644
index 283ba7a19..000000000
--- a/docs/c-api/http.h/intro.md
+++ /dev/null
@@ -1,26 +0,0 @@
----
-title: "Common API reference"
-symbol_kind: "intro"
-decl_name: "http.h"
-items:
-  - { name: mg_connect_ws.md }
-  - { name: mg_connect_ws_opt.md }
-  - { name: mg_http_is_authorized.md }
-  - { name: mg_http_send_digest_auth_request.md }
-  - { name: mg_printf_websocket_frame.md }
-  - { name: mg_send_websocket_frame.md }
-  - { name: mg_send_websocket_framev.md }
-  - { name: mg_send_websocket_handshake.md }
-  - { name: mg_send_websocket_handshake2.md }
-  - { name: mg_send_websocket_handshake3.md }
-  - { name: mg_send_websocket_handshake3v.md }
-  - { name: mg_set_protocol_http_websocket.md }
-  - { name: mg_url_decode.md }
-  - { name: struct_http_message.md }
-  - { name: struct_mg_http_multipart_part.md }
-  - { name: struct_mg_ssi_call_ctx.md }
-  - { name: struct_websocket_message.md }
----
-
-
-
diff --git a/docs/c-api/http.h/mg_connect_ws.md b/docs/c-api/http.h/mg_connect_ws.md
deleted file mode 100644
index 7a5b517d3..000000000
--- a/docs/c-api/http.h/mg_connect_ws.md
+++ /dev/null
@@ -1,29 +0,0 @@
----
-title: "mg_connect_ws()"
-decl_name: "mg_connect_ws"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect_ws(struct mg_mgr *mgr,
-                                      MG_CB(mg_event_handler_t event_handler,
-                                            void *user_data);
----
-
-Helper function that creates an outbound WebSocket connection.
-
-`url` is a URL to connect to. It must be properly URL-encoded, e.g. have
-no spaces, etc. By default, `mg_connect_ws()` sends Connection and
-Host headers. `extra_headers` is an extra HTTP header to send, e.g.
-`"User-Agent: my-app\r\n"`.
-If `protocol` is not NULL, then a `Sec-WebSocket-Protocol` header is sent.
-
-Examples:
-
-```c
-  nc1 = mg_connect_ws(mgr, ev_handler_1, "ws://echo.websocket.org", NULL,
-                      NULL);
-  nc2 = mg_connect_ws(mgr, ev_handler_1, "wss://echo.websocket.org", NULL,
-                      NULL);
-  nc3 = mg_connect_ws(mgr, ev_handler_1, "ws://api.cesanta.com",
-                      "clubby.cesanta.com", NULL);
-``` 
-
diff --git a/docs/c-api/http.h/mg_connect_ws_opt.md b/docs/c-api/http.h/mg_connect_ws_opt.md
deleted file mode 100644
index e2203cff6..000000000
--- a/docs/c-api/http.h/mg_connect_ws_opt.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_connect_ws_opt()"
-decl_name: "mg_connect_ws_opt"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect_ws_opt(
-      struct mg_mgr *mgr, MG_CB(mg_event_handler_t ev_handler, void *user_data);
----
-
-Helper function that creates an outbound WebSocket connection
-
-Mostly identical to `mg_connect_ws`, but allows to provide extra parameters
-(for example, SSL parameters) 
-
diff --git a/docs/c-api/http.h/mg_http_is_authorized.md b/docs/c-api/http.h/mg_http_is_authorized.md
deleted file mode 100644
index 97f029ab0..000000000
--- a/docs/c-api/http.h/mg_http_is_authorized.md
+++ /dev/null
@@ -1,16 +0,0 @@
----
-title: "mg_http_is_authorized()"
-decl_name: "mg_http_is_authorized"
-symbol_kind: "func"
-signature: |
-  int mg_http_is_authorized(struct http_message *hm, struct mg_str path,
-                            const char *domain, const char *passwords_file,
-                            int flags);
----
-
-Checks whether an http request is authorized. `domain` is the authentication
-realm, `passwords_file` is a htdigest file (can be created e.g. with
-`htdigest` utility). If either `domain` or `passwords_file` is NULL, this
-function always returns 1; otherwise checks the authentication in the
-http request and returns 1 only if there is a match; 0 otherwise. 
-
diff --git a/docs/c-api/http.h/mg_http_send_digest_auth_request.md b/docs/c-api/http.h/mg_http_send_digest_auth_request.md
deleted file mode 100644
index 77b7f0514..000000000
--- a/docs/c-api/http.h/mg_http_send_digest_auth_request.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_http_send_digest_auth_request()"
-decl_name: "mg_http_send_digest_auth_request"
-symbol_kind: "func"
-signature: |
-  void mg_http_send_digest_auth_request(struct mg_connection *c,
-                                        const char *domain);
----
-
-Sends 401 Unauthorized response. 
-
diff --git a/docs/c-api/http.h/mg_printf_websocket_frame.md b/docs/c-api/http.h/mg_printf_websocket_frame.md
deleted file mode 100644
index a7e8944bb..000000000
--- a/docs/c-api/http.h/mg_printf_websocket_frame.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_printf_websocket_frame()"
-decl_name: "mg_printf_websocket_frame"
-symbol_kind: "func"
-signature: |
-  void mg_printf_websocket_frame(struct mg_connection *nc, int op_and_flags,
-                                 const char *fmt, ...);
----
-
-Sends WebSocket frame to the remote end.
-
-Like `mg_send_websocket_frame()`, but allows to create formatted messages
-with `printf()`-like semantics. 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_frame.md b/docs/c-api/http.h/mg_send_websocket_frame.md
deleted file mode 100644
index 8a407a68a..000000000
--- a/docs/c-api/http.h/mg_send_websocket_frame.md
+++ /dev/null
@@ -1,26 +0,0 @@
----
-title: "mg_send_websocket_frame()"
-decl_name: "mg_send_websocket_frame"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_frame(struct mg_connection *nc, int op_and_flags,
-                               const void *data, size_t data_len);
----
-
-Send WebSocket frame to the remote end.
-
-`op_and_flags` specifies the frame's type. It's one of:
-
-- WEBSOCKET_OP_CONTINUE
-- WEBSOCKET_OP_TEXT
-- WEBSOCKET_OP_BINARY
-- WEBSOCKET_OP_CLOSE
-- WEBSOCKET_OP_PING
-- WEBSOCKET_OP_PONG
-
-Orred with one of the flags:
-
-- WEBSOCKET_DONT_FIN: Don't set the FIN flag on the frame to be sent.
-
-`data` and `data_len` contain frame data. 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_framev.md b/docs/c-api/http.h/mg_send_websocket_framev.md
deleted file mode 100644
index ae7da3805..000000000
--- a/docs/c-api/http.h/mg_send_websocket_framev.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_send_websocket_framev()"
-decl_name: "mg_send_websocket_framev"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_framev(struct mg_connection *nc, int op_and_flags,
-                                const struct mg_str *strings, int num_strings);
----
-
-Like `mg_send_websocket_frame()`, but composes a single frame from multiple
-buffers. 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_handshake.md b/docs/c-api/http.h/mg_send_websocket_handshake.md
deleted file mode 100644
index 20ee7017b..000000000
--- a/docs/c-api/http.h/mg_send_websocket_handshake.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "mg_send_websocket_handshake()"
-decl_name: "mg_send_websocket_handshake"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_handshake(struct mg_connection *nc, const char *uri,
-                                   const char *extra_headers);
----
-
-Send websocket handshake to the server.
-
-`nc` must be a valid connection, connected to a server. `uri` is an URI
-to fetch, extra_headers` is extra HTTP headers to send or `NULL`.
-
-This function is intended to be used by websocket client.
-
-Note that the Host header is mandatory in HTTP/1.1 and must be
-included in `extra_headers`. `mg_send_websocket_handshake2` offers
-a better API for that.
-
-Deprecated in favour of `mg_send_websocket_handshake2` 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_handshake2.md b/docs/c-api/http.h/mg_send_websocket_handshake2.md
deleted file mode 100644
index 27c5c3b82..000000000
--- a/docs/c-api/http.h/mg_send_websocket_handshake2.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_send_websocket_handshake2()"
-decl_name: "mg_send_websocket_handshake2"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_handshake2(struct mg_connection *nc, const char *path,
-                                    const char *host, const char *protocol,
-                                    const char *extra_headers);
----
-
-Send websocket handshake to the server.
-
-`nc` must be a valid connection, connected to a server. `uri` is an URI
-to fetch, `host` goes into the `Host` header, `protocol` goes into the
-`Sec-WebSocket-Proto` header (NULL to omit), extra_headers` is extra HTTP
-headers to send or `NULL`.
-
-This function is intended to be used by websocket client. 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_handshake3.md b/docs/c-api/http.h/mg_send_websocket_handshake3.md
deleted file mode 100644
index 57abb6203..000000000
--- a/docs/c-api/http.h/mg_send_websocket_handshake3.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_send_websocket_handshake3()"
-decl_name: "mg_send_websocket_handshake3"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_handshake3(struct mg_connection *nc, const char *path,
-                                    const char *host, const char *protocol,
-                                    const char *extra_headers, const char *user,
-                                    const char *pass);
----
-
-Like mg_send_websocket_handshake2 but also passes basic auth header 
-
diff --git a/docs/c-api/http.h/mg_send_websocket_handshake3v.md b/docs/c-api/http.h/mg_send_websocket_handshake3v.md
deleted file mode 100644
index acf8c1e67..000000000
--- a/docs/c-api/http.h/mg_send_websocket_handshake3v.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_send_websocket_handshake3v()"
-decl_name: "mg_send_websocket_handshake3v"
-symbol_kind: "func"
-signature: |
-  void mg_send_websocket_handshake3v(struct mg_connection *nc,
-                                     const struct mg_str path,
-                                     const struct mg_str host,
-                                     const struct mg_str protocol,
-                                     const struct mg_str extra_headers,
-                                     const struct mg_str user,
-                                     const struct mg_str pass);
----
-
-Same as mg_send_websocket_handshake3 but with strings not necessarily
-NUL-temrinated 
-
diff --git a/docs/c-api/http.h/mg_set_protocol_http_websocket.md b/docs/c-api/http.h/mg_set_protocol_http_websocket.md
deleted file mode 100644
index a78ff3584..000000000
--- a/docs/c-api/http.h/mg_set_protocol_http_websocket.md
+++ /dev/null
@@ -1,59 +0,0 @@
----
-title: "mg_set_protocol_http_websocket()"
-decl_name: "mg_set_protocol_http_websocket"
-symbol_kind: "func"
-signature: |
-  void mg_set_protocol_http_websocket(struct mg_connection *nc);
----
-
-Attaches a built-in HTTP event handler to the given connection.
-The user-defined event handler will receive following extra events:
-
-- MG_EV_HTTP_REQUEST: HTTP request has arrived. Parsed HTTP request
- is passed as
-  `struct http_message` through the handler's `void *ev_data` pointer.
-- MG_EV_HTTP_REPLY: The HTTP reply has arrived. The parsed HTTP reply is
-  passed as `struct http_message` through the handler's `void *ev_data`
-  pointer.
-- MG_EV_HTTP_CHUNK: The HTTP chunked-encoding chunk has arrived.
-  The parsed HTTP reply is passed as `struct http_message` through the
-  handler's `void *ev_data` pointer. `http_message::body` would contain
-  incomplete, reassembled HTTP body.
-  It will grow with every new chunk that arrives, and it can
-  potentially consume a lot of memory. An event handler may process
-  the body as chunks are coming, and signal Mongoose to delete processed
-  body by setting `MG_F_DELETE_CHUNK` in `mg_connection::flags`. When
-  the last zero chunk is received,
-  Mongoose sends `MG_EV_HTTP_REPLY` event with
-  full reassembled body (if handler did not signal to delete chunks) or
-  with empty body (if handler did signal to delete chunks).
-- MG_EV_WEBSOCKET_HANDSHAKE_REQUEST: server has received the WebSocket
-  handshake request. `ev_data` contains parsed HTTP request.
-- MG_EV_WEBSOCKET_HANDSHAKE_DONE: server has completed the WebSocket
-  handshake. `ev_data` is `NULL`.
-- MG_EV_WEBSOCKET_FRAME: new WebSocket frame has arrived. `ev_data` is
-  `struct websocket_message *`
-
-When compiled with MG_ENABLE_HTTP_STREAMING_MULTIPART, Mongoose parses
-multipart requests and splits them into separate events:
-- MG_EV_HTTP_MULTIPART_REQUEST: Start of the request.
-  This event is sent before body is parsed. After this, the user
-  should expect a sequence of PART_BEGIN/DATA/END requests.
-  This is also the last time when headers and other request fields are
-  accessible.
-- MG_EV_HTTP_PART_BEGIN: Start of a part of a multipart message.
-  Argument: mg_http_multipart_part with var_name and file_name set
-  (if present). No data is passed in this message.
-- MG_EV_HTTP_PART_DATA: new portion of data from the multipart message.
-  Argument: mg_http_multipart_part. var_name and file_name are preserved,
-  data is available in mg_http_multipart_part.data.
-- MG_EV_HTTP_PART_END: End of the current part. var_name, file_name are
-  the same, no data in the message. If status is 0, then the part is
-  properly terminated with a boundary, status < 0 means that connection
-  was terminated.
-- MG_EV_HTTP_MULTIPART_REQUEST_END: End of the multipart request.
-  Argument: mg_http_multipart_part, var_name and file_name are NULL,
-  status = 0 means request was properly closed, < 0 means connection
-  was terminated (note: in this case both PART_END and REQUEST_END are
-  delivered). 
-
diff --git a/docs/c-api/http.h/mg_url_decode.md b/docs/c-api/http.h/mg_url_decode.md
deleted file mode 100644
index 454acd03c..000000000
--- a/docs/c-api/http.h/mg_url_decode.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_url_decode()"
-decl_name: "mg_url_decode"
-symbol_kind: "func"
-signature: |
-  int mg_url_decode(const char *src, int src_len, char *dst, int dst_len,
-                    int is_form_url_encoded);
----
-
-Decodes a URL-encoded string.
-
-Source string is specified by (`src`, `src_len`), and destination is
-(`dst`, `dst_len`). If `is_form_url_encoded` is non-zero, then
-`+` character is decoded as a blank space character. This function
-guarantees to NUL-terminate the destination. If destination is too small,
-then the source string is partially decoded and `-1` is returned.
-*Otherwise,
-a length of the decoded string is returned, not counting final NUL. 
-
diff --git a/docs/c-api/http.h/struct_http_message.md b/docs/c-api/http.h/struct_http_message.md
deleted file mode 100644
index 9380496d4..000000000
--- a/docs/c-api/http.h/struct_http_message.md
+++ /dev/null
@@ -1,36 +0,0 @@
----
-title: "struct http_message"
-decl_name: "struct http_message"
-symbol_kind: "struct"
-signature: |
-  struct http_message {
-    struct mg_str message; /* Whole message: request line + headers + body */
-    struct mg_str body;    /* Message body. 0-length for requests with no body */
-  
-    /* HTTP Request line (or HTTP response line) */
-    struct mg_str method; /* "GET" */
-    struct mg_str uri;    /* "/my_file.html" */
-    struct mg_str proto;  /* "HTTP/1.1" -- for both request and response */
-  
-    /* For responses, code and response status message are set */
-    int resp_code;
-    struct mg_str resp_status_msg;
-  
-    /*
-     * Query-string part of the URI. For example, for HTTP request
-     *    GET /foo/bar?param1=val1&param2=val2
-     *    |    uri    |     query_string     |
-     *
-     * Note that question mark character doesn't belong neither to the uri,
-     * nor to the query_string
-     */
-    struct mg_str query_string;
-  
-    /* Headers */
-    struct mg_str header_names[MG_MAX_HTTP_HEADERS];
-    struct mg_str header_values[MG_MAX_HTTP_HEADERS];
-  };
----
-
-HTTP message 
-
diff --git a/docs/c-api/http.h/struct_mg_http_multipart_part.md b/docs/c-api/http.h/struct_mg_http_multipart_part.md
deleted file mode 100644
index cd2d0c2e4..000000000
--- a/docs/c-api/http.h/struct_mg_http_multipart_part.md
+++ /dev/null
@@ -1,16 +0,0 @@
----
-title: "struct mg_http_multipart_part"
-decl_name: "struct mg_http_multipart_part"
-symbol_kind: "struct"
-signature: |
-  struct mg_http_multipart_part {
-    const char *file_name;
-    const char *var_name;
-    struct mg_str data;
-    int status; /* <0 on error */
-    void *user_data;
-  };
----
-
-HTTP multipart part 
-
diff --git a/docs/c-api/http.h/struct_mg_ssi_call_ctx.md b/docs/c-api/http.h/struct_mg_ssi_call_ctx.md
deleted file mode 100644
index 2b430fd11..000000000
--- a/docs/c-api/http.h/struct_mg_ssi_call_ctx.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "struct mg_ssi_call_ctx"
-decl_name: "struct mg_ssi_call_ctx"
-symbol_kind: "struct"
-signature: |
-  struct mg_ssi_call_ctx {
-    struct http_message *req; /* The request being processed. */
-    struct mg_str file;       /* Filesystem path of the file being processed. */
-    struct mg_str arg; /* The argument passed to the tag: <!-- call arg -->. */
-  };
----
-
-SSI call context 
-
diff --git a/docs/c-api/http.h/struct_websocket_message.md b/docs/c-api/http.h/struct_websocket_message.md
deleted file mode 100644
index 37b7912a5..000000000
--- a/docs/c-api/http.h/struct_websocket_message.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "struct websocket_message"
-decl_name: "struct websocket_message"
-symbol_kind: "struct"
-signature: |
-  struct websocket_message {
-    unsigned char *data;
-    size_t size;
-    unsigned char flags;
-  };
----
-
-WebSocket message 
-
diff --git a/docs/c-api/http_client.h/intro.md b/docs/c-api/http_client.h/intro.md
deleted file mode 100644
index d3bc1d6a5..000000000
--- a/docs/c-api/http_client.h/intro.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "Client API reference"
-symbol_kind: "intro"
-decl_name: "http_client.h"
-items:
-  - { name: mg_connect_http.md }
-  - { name: mg_connect_http_opt.md }
-  - { name: mg_http_create_digest_auth_header.md }
----
-
-
-
diff --git a/docs/c-api/http_client.h/mg_connect_http.md b/docs/c-api/http_client.h/mg_connect_http.md
deleted file mode 100644
index 4664fcd90..000000000
--- a/docs/c-api/http_client.h/mg_connect_http.md
+++ /dev/null
@@ -1,33 +0,0 @@
----
-title: "mg_connect_http()"
-decl_name: "mg_connect_http"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect_http(
-      struct mg_mgr *mgr,
-      MG_CB(mg_event_handler_t event_handler, void *user_data);
----
-
-Helper function that creates an outbound HTTP connection.
-
-`url` is the URL to fetch. It must be properly URL-encoded, e.g. have
-no spaces, etc. By default, `mg_connect_http()` sends the Connection and
-Host headers. `extra_headers` is an extra HTTP header to send, e.g.
-`"User-Agent: my-app\r\n"`.
-If `post_data` is NULL, then a GET request is created. Otherwise, a POST
-request is created with the specified POST data. Note that if the data being
-posted is a form submission, the `Content-Type` header should be set
-accordingly (see example below).
-
-Examples:
-
-```c
-  nc1 = mg_connect_http(mgr, ev_handler_1, "http://www.google.com", NULL,
-                        NULL);
-  nc2 = mg_connect_http(mgr, ev_handler_1, "https://github.com", NULL, NULL);
-  nc3 = mg_connect_http(
-      mgr, ev_handler_1, "my_server:8000/form_submit/",
-      "Content-Type: application/x-www-form-urlencoded\r\n",
-      "var_1=value_1&var_2=value_2");
-``` 
-
diff --git a/docs/c-api/http_client.h/mg_connect_http_opt.md b/docs/c-api/http_client.h/mg_connect_http_opt.md
deleted file mode 100644
index 29df1d753..000000000
--- a/docs/c-api/http_client.h/mg_connect_http_opt.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_connect_http_opt()"
-decl_name: "mg_connect_http_opt"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect_http_opt(
-      struct mg_mgr *mgr, MG_CB(mg_event_handler_t ev_handler, void *user_data);
----
-
-Helper function that creates an outbound HTTP connection.
-
-Mostly identical to mg_connect_http, but allows you to provide extra
-*parameters
-(for example, SSL parameters) 
-
diff --git a/docs/c-api/http_client.h/mg_http_create_digest_auth_header.md b/docs/c-api/http_client.h/mg_http_create_digest_auth_header.md
deleted file mode 100644
index 1842ea370..000000000
--- a/docs/c-api/http_client.h/mg_http_create_digest_auth_header.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_http_create_digest_auth_header()"
-decl_name: "mg_http_create_digest_auth_header"
-symbol_kind: "func"
-signature: |
-  int mg_http_create_digest_auth_header(char *buf, size_t buf_len,
-                                        const char *method, const char *uri,
-                                        const char *auth_domain, const char *user,
-                                        const char *passwd, const char *nonce);
----
-
-Creates digest authentication header for a client request. 
-
diff --git a/docs/c-api/http_server.h/intro.md b/docs/c-api/http_server.h/intro.md
deleted file mode 100644
index 0fc609dbc..000000000
--- a/docs/c-api/http_server.h/intro.md
+++ /dev/null
@@ -1,32 +0,0 @@
----
-title: "Server API reference"
-symbol_kind: "intro"
-decl_name: "http_server.h"
-items:
-  - { name: mg_check_digest_auth.md }
-  - { name: mg_file_upload_handler.md }
-  - { name: mg_get_http_basic_auth.md }
-  - { name: mg_get_http_header.md }
-  - { name: mg_get_http_var.md }
-  - { name: mg_http_check_digest_auth.md }
-  - { name: mg_http_parse_header.md }
-  - { name: mg_http_reverse_proxy.md }
-  - { name: mg_http_send_error.md }
-  - { name: mg_http_send_redirect.md }
-  - { name: mg_http_serve_file.md }
-  - { name: mg_parse_http.md }
-  - { name: mg_parse_http_basic_auth.md }
-  - { name: mg_parse_multipart.md }
-  - { name: mg_printf_html_escape.md }
-  - { name: mg_printf_http_chunk.md }
-  - { name: mg_register_http_endpoint.md }
-  - { name: mg_send_head.md }
-  - { name: mg_send_http_chunk.md }
-  - { name: mg_send_response_line.md }
-  - { name: mg_serve_http.md }
-  - { name: mg_fu_fname_fn.md }
-  - { name: struct_mg_serve_http_opts.md }
----
-
-
-
diff --git a/docs/c-api/http_server.h/mg_check_digest_auth.md b/docs/c-api/http_server.h/mg_check_digest_auth.md
deleted file mode 100644
index 189f0c4a9..000000000
--- a/docs/c-api/http_server.h/mg_check_digest_auth.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_check_digest_auth()"
-decl_name: "mg_check_digest_auth"
-symbol_kind: "func"
-signature: |
-  int mg_check_digest_auth(struct mg_str method, struct mg_str uri,
-                           struct mg_str username, struct mg_str cnonce,
-                           struct mg_str response, struct mg_str qop,
-                           struct mg_str nc, struct mg_str nonce,
-                           struct mg_str auth_domain, FILE *fp);
----
-
-Authenticates given response params against an opened password file.
-Returns 1 if authenticated, 0 otherwise.
-
-It's used by mg_http_check_digest_auth(). 
-
diff --git a/docs/c-api/http_server.h/mg_file_upload_handler.md b/docs/c-api/http_server.h/mg_file_upload_handler.md
deleted file mode 100644
index a2c9e016f..000000000
--- a/docs/c-api/http_server.h/mg_file_upload_handler.md
+++ /dev/null
@@ -1,41 +0,0 @@
----
-title: "mg_file_upload_handler()"
-decl_name: "mg_file_upload_handler"
-symbol_kind: "func"
-signature: |
-  void mg_file_upload_handler(struct mg_connection *nc, int ev, void *ev_data,
-                              mg_fu_fname_fn local_name_fn
-                                  MG_UD_ARG(void *user_data);
----
-
-File upload handler.
-This handler can be used to implement file uploads with minimum code.
-This handler will process MG_EV_HTTP_PART_* events and store file data into
-a local file.
-`local_name_fn` will be invoked with whatever name was provided by the client
-and will expect the name of the local file to open. A return value of NULL
-will abort file upload (client will get a "403 Forbidden" response). If
-non-null, the returned string must be heap-allocated and will be freed by
-the caller.
-Exception: it is ok to return the same string verbatim.
-
-Example:
-
-```c
-struct mg_str upload_fname(struct mg_connection *nc, struct mg_str fname) {
-  // Just return the same filename. Do not actually do this except in test!
-  // fname is user-controlled and needs to be sanitized.
-  return fname;
-}
-void ev_handler(struct mg_connection *nc, int ev, void *ev_data) {
-  switch (ev) {
-    ...
-    case MG_EV_HTTP_PART_BEGIN:
-    case MG_EV_HTTP_PART_DATA:
-    case MG_EV_HTTP_PART_END:
-      mg_file_upload_handler(nc, ev, ev_data, upload_fname);
-      break;
-  }
-}
-``` 
-
diff --git a/docs/c-api/http_server.h/mg_fu_fname_fn.md b/docs/c-api/http_server.h/mg_fu_fname_fn.md
deleted file mode 100644
index 78aa7c8bd..000000000
--- a/docs/c-api/http_server.h/mg_fu_fname_fn.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_fu_fname_fn"
-decl_name: "mg_fu_fname_fn"
-symbol_kind: "typedef"
-signature: |
-  typedef struct mg_str (*mg_fu_fname_fn)(struct mg_connection *nc,
-                                          struct mg_str fname);
----
-
-Callback prototype for `mg_file_upload_handler()`. 
-
diff --git a/docs/c-api/http_server.h/mg_get_http_basic_auth.md b/docs/c-api/http_server.h/mg_get_http_basic_auth.md
deleted file mode 100644
index 103d042fa..000000000
--- a/docs/c-api/http_server.h/mg_get_http_basic_auth.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_get_http_basic_auth()"
-decl_name: "mg_get_http_basic_auth"
-symbol_kind: "func"
-signature: |
-  int mg_get_http_basic_auth(struct http_message *hm, char *user, size_t user_len,
-                             char *pass, size_t pass_len);
----
-
-Gets and parses the Authorization: Basic header
-Returns -1 if no Authorization header is found, or if
-mg_parse_http_basic_auth
-fails parsing the resulting header. 
-
diff --git a/docs/c-api/http_server.h/mg_get_http_header.md b/docs/c-api/http_server.h/mg_get_http_header.md
deleted file mode 100644
index b33e91f48..000000000
--- a/docs/c-api/http_server.h/mg_get_http_header.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_get_http_header()"
-decl_name: "mg_get_http_header"
-symbol_kind: "func"
-signature: |
-  struct mg_str *mg_get_http_header(struct http_message *hm, const char *name);
----
-
-Searches and returns the header `name` in parsed HTTP message `hm`.
-If header is not found, NULL is returned. Example:
-
-    struct mg_str *host_hdr = mg_get_http_header(hm, "Host"); 
-
diff --git a/docs/c-api/http_server.h/mg_get_http_var.md b/docs/c-api/http_server.h/mg_get_http_var.md
deleted file mode 100644
index 8ca1d915d..000000000
--- a/docs/c-api/http_server.h/mg_get_http_var.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_get_http_var()"
-decl_name: "mg_get_http_var"
-symbol_kind: "func"
-signature: |
-  int mg_get_http_var(const struct mg_str *buf, const char *name, char *dst,
-                      size_t dst_len);
----
-
-Fetches a HTTP form variable.
-
-Fetches a variable `name` from a `buf` into a buffer specified by `dst`,
-`dst_len`. The destination is always zero-terminated. Returns the length of
-a fetched variable. If not found, 0 is returned. `buf` must be valid
-url-encoded buffer. If destination is too small or an error occured,
-negative number is returned. 
-
diff --git a/docs/c-api/http_server.h/mg_http_check_digest_auth.md b/docs/c-api/http_server.h/mg_http_check_digest_auth.md
deleted file mode 100644
index 3494eb261..000000000
--- a/docs/c-api/http_server.h/mg_http_check_digest_auth.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_http_check_digest_auth()"
-decl_name: "mg_http_check_digest_auth"
-symbol_kind: "func"
-signature: |
-  int mg_http_check_digest_auth(struct http_message *hm, const char *auth_domain,
-                                FILE *fp);
----
-
-Authenticates a HTTP request against an opened password file.
-Returns 1 if authenticated, 0 otherwise. 
-
diff --git a/docs/c-api/http_server.h/mg_http_parse_header.md b/docs/c-api/http_server.h/mg_http_parse_header.md
deleted file mode 100644
index f86564536..000000000
--- a/docs/c-api/http_server.h/mg_http_parse_header.md
+++ /dev/null
@@ -1,23 +0,0 @@
----
-title: "mg_http_parse_header()"
-decl_name: "mg_http_parse_header"
-symbol_kind: "func"
-signature: |
-  int mg_http_parse_header(struct mg_str *hdr, const char *var_name, char *buf,
-                           size_t buf_size);
----
-
-Parses the HTTP header `hdr`. Finds variable `var_name` and stores its value
-in the buffer `buf`, `buf_size`. Returns 0 if variable not found, non-zero
-otherwise.
-
-This function is supposed to parse cookies, authentication headers, etc.
-Example (error handling omitted):
-
-    char user[20];
-    struct mg_str *hdr = mg_get_http_header(hm, "Authorization");
-    mg_http_parse_header(hdr, "username", user, sizeof(user));
-
-Returns the length of the variable's value. If buffer is not large enough,
-or variable not found, 0 is returned. 
-
diff --git a/docs/c-api/http_server.h/mg_http_reverse_proxy.md b/docs/c-api/http_server.h/mg_http_reverse_proxy.md
deleted file mode 100644
index c0c838358..000000000
--- a/docs/c-api/http_server.h/mg_http_reverse_proxy.md
+++ /dev/null
@@ -1,19 +0,0 @@
----
-title: "mg_http_reverse_proxy()"
-decl_name: "mg_http_reverse_proxy"
-symbol_kind: "func"
-signature: |
-  void mg_http_reverse_proxy(struct mg_connection *nc,
-                             const struct http_message *hm, struct mg_str mount,
-                             struct mg_str upstream);
----
-
-Proxies a given request to a given upstream http server. The path prefix
-in `mount` will be stripped of the path requested to the upstream server,
-e.g. if mount is /api and upstream is http://localhost:8001/foo
-then an incoming request to /api/bar will cause a request to
-http://localhost:8001/foo/bar
-
-EXPERIMENTAL API. Please use http_serve_http + url_rewrites if a static
-mapping is good enough. 
-
diff --git a/docs/c-api/http_server.h/mg_http_send_error.md b/docs/c-api/http_server.h/mg_http_send_error.md
deleted file mode 100644
index d74aafc14..000000000
--- a/docs/c-api/http_server.h/mg_http_send_error.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_http_send_error()"
-decl_name: "mg_http_send_error"
-symbol_kind: "func"
-signature: |
-  void mg_http_send_error(struct mg_connection *nc, int code, const char *reason);
----
-
-Sends an error response. If reason is NULL, the message will be inferred
-from the error code (if supported). 
-
diff --git a/docs/c-api/http_server.h/mg_http_send_redirect.md b/docs/c-api/http_server.h/mg_http_send_redirect.md
deleted file mode 100644
index 00d704e0e..000000000
--- a/docs/c-api/http_server.h/mg_http_send_redirect.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_http_send_redirect()"
-decl_name: "mg_http_send_redirect"
-symbol_kind: "func"
-signature: |
-  void mg_http_send_redirect(struct mg_connection *nc, int status_code,
-                             const struct mg_str location,
-                             const struct mg_str extra_headers);
----
-
-Sends a redirect response.
-`status_code` should be either 301 or 302 and `location` point to the
-new location.
-If `extra_headers` is not empty, then `extra_headers` are also sent
-after the response line. `extra_headers` must NOT end end with new line.
-
-Example:
-
-     mg_http_send_redirect(nc, 302, mg_mk_str("/login"), mg_mk_str(NULL)); 
-
diff --git a/docs/c-api/http_server.h/mg_http_serve_file.md b/docs/c-api/http_server.h/mg_http_serve_file.md
deleted file mode 100644
index 440d39e5f..000000000
--- a/docs/c-api/http_server.h/mg_http_serve_file.md
+++ /dev/null
@@ -1,28 +0,0 @@
----
-title: "mg_http_serve_file()"
-decl_name: "mg_http_serve_file"
-symbol_kind: "func"
-signature: |
-  void mg_http_serve_file(struct mg_connection *nc, struct http_message *hm,
-                          const char *path, const struct mg_str mime_type,
-                          const struct mg_str extra_headers);
----
-
-Serves a specific file with a given MIME type and optional extra headers.
-
-Example code snippet:
-
-```c
-static void ev_handler(struct mg_connection *nc, int ev, void *ev_data) {
-  switch (ev) {
-    case MG_EV_HTTP_REQUEST: {
-      struct http_message *hm = (struct http_message *) ev_data;
-      mg_http_serve_file(nc, hm, "file.txt",
-                         mg_mk_str("text/plain"), mg_mk_str(""));
-      break;
-    }
-    ...
-  }
-}
-``` 
-
diff --git a/docs/c-api/http_server.h/mg_parse_http.md b/docs/c-api/http_server.h/mg_parse_http.md
deleted file mode 100644
index fdd5c638f..000000000
--- a/docs/c-api/http_server.h/mg_parse_http.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_parse_http()"
-decl_name: "mg_parse_http"
-symbol_kind: "func"
-signature: |
-  int mg_parse_http(const char *s, int n, struct http_message *hm, int is_req);
----
-
-Parses a HTTP message.
-
-`is_req` should be set to 1 if parsing a request, 0 if reply.
-
-Returns the number of bytes parsed. If HTTP message is
-incomplete `0` is returned. On parse error, a negative number is returned. 
-
diff --git a/docs/c-api/http_server.h/mg_parse_http_basic_auth.md b/docs/c-api/http_server.h/mg_parse_http_basic_auth.md
deleted file mode 100644
index 7e3c2118f..000000000
--- a/docs/c-api/http_server.h/mg_parse_http_basic_auth.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_parse_http_basic_auth()"
-decl_name: "mg_parse_http_basic_auth"
-symbol_kind: "func"
-signature: |
-  int mg_parse_http_basic_auth(struct mg_str *hdr, char *user, size_t user_len,
-                               char *pass, size_t pass_len);
----
-
-Parses the Authorization: Basic header
-Returns -1 iif the authorization type is not "Basic" or any other error such
-as incorrectly encoded base64 user password pair. 
-
diff --git a/docs/c-api/http_server.h/mg_parse_multipart.md b/docs/c-api/http_server.h/mg_parse_multipart.md
deleted file mode 100644
index f98d48fad..000000000
--- a/docs/c-api/http_server.h/mg_parse_multipart.md
+++ /dev/null
@@ -1,46 +0,0 @@
----
-title: "mg_parse_multipart()"
-decl_name: "mg_parse_multipart"
-symbol_kind: "func"
-signature: |
-  size_t mg_parse_multipart(const char *buf, size_t buf_len, char *var_name,
-                            size_t var_name_len, char *file_name,
-                            size_t file_name_len, const char **chunk,
-                            size_t *chunk_len);
----
-
-Parses the buffer `buf`, `buf_len` that contains multipart form data chunks.
-Stores the chunk name in a `var_name`, `var_name_len` buffer.
-If a chunk is an uploaded file, then `file_name`, `file_name_len` is
-filled with an uploaded file name. `chunk`, `chunk_len`
-points to the chunk data.
-
-Return: number of bytes to skip to the next chunk or 0 if there are
-        no more chunks.
-
-Usage example:
-
-```c
-   static void ev_handler(struct mg_connection *nc, int ev, void *ev_data) {
-     switch(ev) {
-       case MG_EV_HTTP_REQUEST: {
-         struct http_message *hm = (struct http_message *) ev_data;
-         char var_name[100], file_name[100];
-         const char *chunk;
-         size_t chunk_len, n1, n2;
-
-         n1 = n2 = 0;
-         while ((n2 = mg_parse_multipart(hm->body.p + n1,
-                                         hm->body.len - n1,
-                                         var_name, sizeof(var_name),
-                                         file_name, sizeof(file_name),
-                                         &chunk, &chunk_len)) > 0) {
-           printf("var: %s, file_name: %s, size: %d, chunk: [%.*s]\n",
-                  var_name, file_name, (int) chunk_len,
-                  (int) chunk_len, chunk);
-           n1 += n2;
-         }
-       }
-       break;
-``` 
-
diff --git a/docs/c-api/http_server.h/mg_printf_html_escape.md b/docs/c-api/http_server.h/mg_printf_html_escape.md
deleted file mode 100644
index 6238e28d1..000000000
--- a/docs/c-api/http_server.h/mg_printf_html_escape.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_printf_html_escape()"
-decl_name: "mg_printf_html_escape"
-symbol_kind: "func"
-signature: |
-  void mg_printf_html_escape(struct mg_connection *nc, const char *fmt, ...);
----
-
-Sends a printf-formatted HTTP chunk, escaping HTML tags. 
-
diff --git a/docs/c-api/http_server.h/mg_printf_http_chunk.md b/docs/c-api/http_server.h/mg_printf_http_chunk.md
deleted file mode 100644
index f99324b23..000000000
--- a/docs/c-api/http_server.h/mg_printf_http_chunk.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_printf_http_chunk()"
-decl_name: "mg_printf_http_chunk"
-symbol_kind: "func"
-signature: |
-  void mg_printf_http_chunk(struct mg_connection *nc, const char *fmt, ...);
----
-
-Sends a printf-formatted HTTP chunk.
-Functionality is similar to `mg_send_http_chunk()`. 
-
diff --git a/docs/c-api/http_server.h/mg_register_http_endpoint.md b/docs/c-api/http_server.h/mg_register_http_endpoint.md
deleted file mode 100644
index 394bbb51e..000000000
--- a/docs/c-api/http_server.h/mg_register_http_endpoint.md
+++ /dev/null
@@ -1,36 +0,0 @@
----
-title: "mg_register_http_endpoint()"
-decl_name: "mg_register_http_endpoint"
-symbol_kind: "func"
-signature: |
-  void mg_register_http_endpoint(struct mg_connection *nc, const char *uri_path,
-                                 MG_CB(mg_event_handler_t handler,
-                                       void *user_data);
----
-
-Registers a callback for a specified http endpoint
-Note: if callback is registered it is called instead of the
-callback provided in mg_bind
-
-Example code snippet:
-
-```c
-static void handle_hello1(struct mg_connection *nc, int ev, void *ev_data) {
-  (void) ev; (void) ev_data;
-  mg_printf(nc, "HTTP/1.0 200 OK\r\n\r\n[I am Hello1]");
- nc->flags |= MG_F_SEND_AND_CLOSE;
-}
-
-static void handle_hello2(struct mg_connection *nc, int ev, void *ev_data) {
- (void) ev; (void) ev_data;
-  mg_printf(nc, "HTTP/1.0 200 OK\r\n\r\n[I am Hello2]");
- nc->flags |= MG_F_SEND_AND_CLOSE;
-}
-
-void init() {
-  nc = mg_bind(&mgr, local_addr, cb1);
-  mg_register_http_endpoint(nc, "/hello1", handle_hello1);
-  mg_register_http_endpoint(nc, "/hello1/hello2", handle_hello2);
-}
-``` 
-
diff --git a/docs/c-api/http_server.h/mg_send_head.md b/docs/c-api/http_server.h/mg_send_head.md
deleted file mode 100644
index cd3348668..000000000
--- a/docs/c-api/http_server.h/mg_send_head.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "mg_send_head()"
-decl_name: "mg_send_head"
-symbol_kind: "func"
-signature: |
-  void mg_send_head(struct mg_connection *n, int status_code,
-                    int64_t content_length, const char *extra_headers);
----
-
-Sends the response line and headers.
-This function sends the response line with the `status_code`, and
-automatically
-sends one header: either "Content-Length" or "Transfer-Encoding".
-If `content_length` is negative, then "Transfer-Encoding: chunked" header
-is sent, otherwise, "Content-Length" header is sent.
-
-NOTE: If `Transfer-Encoding` is `chunked`, then message body must be sent
-using `mg_send_http_chunk()` or `mg_printf_http_chunk()` functions.
-Otherwise, `mg_send()` or `mg_printf()` must be used.
-Extra headers could be set through `extra_headers`. Note `extra_headers`
-must NOT be terminated by a new line. 
-
diff --git a/docs/c-api/http_server.h/mg_send_http_chunk.md b/docs/c-api/http_server.h/mg_send_http_chunk.md
deleted file mode 100644
index 6a2a4d838..000000000
--- a/docs/c-api/http_server.h/mg_send_http_chunk.md
+++ /dev/null
@@ -1,25 +0,0 @@
----
-title: "mg_send_http_chunk()"
-decl_name: "mg_send_http_chunk"
-symbol_kind: "func"
-signature: |
-  void mg_send_http_chunk(struct mg_connection *nc, const char *buf, size_t len);
----
-
-Sends buffer `buf` of size `len` to the client using chunked HTTP encoding.
-This function sends the buffer size as hex number + newline first, then
-the buffer itself, then the newline. For example,
-`mg_send_http_chunk(nc, "foo", 3)` will append the `3\r\nfoo\r\n` string
-to the `nc->send_mbuf` output IO buffer.
-
-NOTE: The HTTP header "Transfer-Encoding: chunked" should be sent prior to
-using this function.
-
-NOTE: do not forget to send an empty chunk at the end of the response,
-to tell the client that everything was sent. Example:
-
-```
-  mg_printf_http_chunk(nc, "%s", "my response!");
-  mg_send_http_chunk(nc, "", 0); // Tell the client we're finished
-``` 
-
diff --git a/docs/c-api/http_server.h/mg_send_response_line.md b/docs/c-api/http_server.h/mg_send_response_line.md
deleted file mode 100644
index 5daa74fe8..000000000
--- a/docs/c-api/http_server.h/mg_send_response_line.md
+++ /dev/null
@@ -1,21 +0,0 @@
----
-title: "mg_send_response_line()"
-decl_name: "mg_send_response_line"
-symbol_kind: "func"
-signature: |
-  void mg_send_response_line(struct mg_connection *nc, int status_code,
-                             const char *extra_headers);
----
-
-Sends the response status line.
-If `extra_headers` is not NULL, then `extra_headers` are also sent
-after the response line. `extra_headers` must NOT end end with new line.
-Example:
-
-     mg_send_response_line(nc, 200, "Access-Control-Allow-Origin: *");
-
-Will result in:
-
-     HTTP/1.1 200 OK\r\n
-     Access-Control-Allow-Origin: *\r\n 
-
diff --git a/docs/c-api/http_server.h/mg_serve_http.md b/docs/c-api/http_server.h/mg_serve_http.md
deleted file mode 100644
index 980695036..000000000
--- a/docs/c-api/http_server.h/mg_serve_http.md
+++ /dev/null
@@ -1,28 +0,0 @@
----
-title: "mg_serve_http()"
-decl_name: "mg_serve_http"
-symbol_kind: "func"
-signature: |
-  void mg_serve_http(struct mg_connection *nc, struct http_message *hm,
-                     struct mg_serve_http_opts opts);
----
-
-Serves given HTTP request according to the `options`.
-
-Example code snippet:
-
-```c
-static void ev_handler(struct mg_connection *nc, int ev, void *ev_data) {
-  struct http_message *hm = (struct http_message *) ev_data;
-  struct mg_serve_http_opts opts = { .document_root = "/var/www" };  // C99
-
-  switch (ev) {
-    case MG_EV_HTTP_REQUEST:
-      mg_serve_http(nc, hm, opts);
-      break;
-    default:
-      break;
-  }
-}
-``` 
-
diff --git a/docs/c-api/http_server.h/struct_mg_serve_http_opts.md b/docs/c-api/http_server.h/struct_mg_serve_http_opts.md
deleted file mode 100644
index ae594dba6..000000000
--- a/docs/c-api/http_server.h/struct_mg_serve_http_opts.md
+++ /dev/null
@@ -1,165 +0,0 @@
----
-title: "struct mg_serve_http_opts"
-decl_name: "struct mg_serve_http_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_serve_http_opts {
-    /* Path to web root directory */
-    const char *document_root;
-  
-    /* List of index files. Default is "" */
-    const char *index_files;
-  
-    /*
-     * Leave as NULL to disable authentication.
-     * To enable directory protection with authentication, set this to ".htpasswd"
-     * Then, creating ".htpasswd" file in any directory automatically protects
-     * it with digest authentication.
-     * Use `mongoose` web server binary, or `htdigest` Apache utility to
-     * create/manipulate passwords file.
-     * Make sure `auth_domain` is set to a valid domain name.
-     */
-    const char *per_directory_auth_file;
-  
-    /* Authorization domain (domain name of this web server) */
-    const char *auth_domain;
-  
-    /*
-     * Leave as NULL to disable authentication.
-     * Normally, only selected directories in the document root are protected.
-     * If absolutely every access to the web server needs to be authenticated,
-     * regardless of the URI, set this option to the path to the passwords file.
-     * Format of that file is the same as ".htpasswd" file. Make sure that file
-     * is located outside document root to prevent people fetching it.
-     */
-    const char *global_auth_file;
-  
-    /* Set to "no" to disable directory listing. Enabled by default. */
-    const char *enable_directory_listing;
-  
-    /*
-     * SSI files pattern. If not set, "**.shtml$|**.shtm$" is used.
-     *
-     * All files that match ssi_pattern are treated as SSI.
-     *
-     * Server Side Includes (SSI) is a simple interpreted server-side scripting
-     * language which is most commonly used to include the contents of a file
-     * into a web page. It can be useful when it is desirable to include a common
-     * piece of code throughout a website, for example, headers and footers.
-     *
-     * In order for a webpage to recognize an SSI-enabled HTML file, the
-     * filename should end with a special extension, by default the extension
-     * should be either .shtml or .shtm
-     *
-     * Unknown SSI directives are silently ignored by Mongoose. Currently,
-     * the following SSI directives are supported:
-     *    &lt;!--#include FILE_TO_INCLUDE --&gt;
-     *    &lt;!--#exec "COMMAND_TO_EXECUTE" --&gt;
-     *    &lt;!--#call COMMAND --&gt;
-     *
-     * Note that &lt;!--#include ...> directive supports three path
-     *specifications:
-     *
-     * &lt;!--#include virtual="path" --&gt;  Path is relative to web server root
-     * &lt;!--#include abspath="path" --&gt;  Path is absolute or relative to the
-     *                                  web server working dir
-     * &lt;!--#include file="path" --&gt;,    Path is relative to current document
-     * &lt;!--#include "path" --&gt;
-     *
-     * The include directive may be used to include the contents of a file or
-     * the result of running a CGI script.
-     *
-     * The exec directive is used to execute
-     * a command on a server, and show command's output. Example:
-     *
-     * &lt;!--#exec "ls -l" --&gt;
-     *
-     * The call directive is a way to invoke a C handler from the HTML page.
-     * On each occurence of &lt;!--#call COMMAND OPTIONAL_PARAMS> directive,
-     * Mongoose calls a registered event handler with MG_EV_SSI_CALL event,
-     * and event parameter will point to the COMMAND OPTIONAL_PARAMS string.
-     * An event handler can output any text, for example by calling
-     * `mg_printf()`. This is a flexible way of generating a web page on
-     * server side by calling a C event handler. Example:
-     *
-     * &lt;!--#call foo --&gt; ... &lt;!--#call bar --&gt;
-     *
-     * In the event handler:
-     *    case MG_EV_SSI_CALL: {
-     *      const char *param = (const char *) ev_data;
-     *      if (strcmp(param, "foo") == 0) {
-     *        mg_printf(c, "hello from foo");
-     *      } else if (strcmp(param, "bar") == 0) {
-     *        mg_printf(c, "hello from bar");
-     *      }
-     *      break;
-     *    }
-     */
-    const char *ssi_pattern;
-  
-    /* IP ACL. By default, NULL, meaning all IPs are allowed to connect */
-    const char *ip_acl;
-  
-  #if MG_ENABLE_HTTP_URL_REWRITES
-    /* URL rewrites.
-     *
-     * Comma-separated list of `uri_pattern=url_file_or_directory_path` rewrites.
-     * When HTTP request is received, Mongoose constructs a file name from the
-     * requested URI by combining `document_root` and the URI. However, if the
-     * rewrite option is used and `uri_pattern` matches requested URI, then
-     * `document_root` is ignored. Instead, `url_file_or_directory_path` is used,
-     * which should be a full path name or a path relative to the web server's
-     * current working directory. It can also be an URI (http:// or https://)
-     * in which case mongoose will behave as a reverse proxy for that destination.
-     *
-     * Note that `uri_pattern`, as all Mongoose patterns, is a prefix pattern.
-     *
-     * If uri_pattern starts with `@` symbol, then Mongoose compares it with the
-     * HOST header of the request. If they are equal, Mongoose sets document root
-     * to `file_or_directory_path`, implementing virtual hosts support.
-     * Example: `@foo.com=/document/root/for/foo.com`
-     *
-     * If `uri_pattern` starts with `%` symbol, then Mongoose compares it with
-     * the listening port. If they match, then Mongoose issues a 301 redirect.
-     * For example, to redirect all HTTP requests to the
-     * HTTPS port, do `%80=https://my.site.com`. Note that the request URI is
-     * automatically appended to the redirect location.
-     */
-    const char *url_rewrites;
-  #endif
-  
-    /* DAV document root. If NULL, DAV requests are going to fail. */
-    const char *dav_document_root;
-  
-    /*
-     * DAV passwords file. If NULL, DAV requests are going to fail.
-     * If passwords file is set to "-", then DAV auth is disabled.
-     */
-    const char *dav_auth_file;
-  
-    /* Glob pattern for the files to hide. */
-    const char *hidden_file_pattern;
-  
-    /* Set to non-NULL to enable CGI, e.g. **.cgi$|**.php$" */
-    const char *cgi_file_pattern;
-  
-    /* If not NULL, ignore CGI script hashbang and use this interpreter */
-    const char *cgi_interpreter;
-  
-    /*
-     * Comma-separated list of Content-Type overrides for path suffixes, e.g.
-     * ".txt=text/plain; charset=utf-8,.c=text/plain"
-     */
-    const char *custom_mime_types;
-  
-    /*
-     * Extra HTTP headers to add to each server response.
-     * Example: to enable CORS, set this to "Access-Control-Allow-Origin: *".
-     */
-    const char *extra_headers;
-  };
----
-
-This structure defines how `mg_serve_http()` works.
-Best practice is to set only required settings, and leave the rest as NULL. 
-
diff --git a/docs/c-api/intro.md b/docs/c-api/intro.md
deleted file mode 100644
index 34f361022..000000000
--- a/docs/c-api/intro.md
+++ /dev/null
@@ -1,16 +0,0 @@
----
-items:
-  - { name: mbuf.h }
-  - { name: net.h }
-  - { name: http.h }
-  - { name: http_server.h }
-  - { name: http_client.h }
-  - { name: dns.h }
-  - { name: dns_server.h }
-  - { name: resolv.h }
-  - { name: mqtt.h }
-  - { name: mqtt_server.h }
-  - { name: coap.h }
-  - { name: util.h }
-  - { name: uri.h }
----
diff --git a/docs/c-api/mbuf.h/intro.md b/docs/c-api/mbuf.h/intro.md
deleted file mode 100644
index 475c65104..000000000
--- a/docs/c-api/mbuf.h/intro.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "Memory Buffers"
-symbol_kind: "intro"
-decl_name: "mbuf.h"
-items:
-  - { name: mbuf_append.md }
-  - { name: mbuf_free.md }
-  - { name: mbuf_init.md }
-  - { name: mbuf_insert.md }
-  - { name: mbuf_remove.md }
-  - { name: mbuf_resize.md }
-  - { name: mbuf_trim.md }
-  - { name: struct_mbuf.md }
----
-
-Mbufs are mutable/growing memory buffers, like C++ strings.
-Mbuf can append data to the end of a buffer or insert data into arbitrary
-position in the middle of a buffer. The buffer grows automatically when
-needed.
-
diff --git a/docs/c-api/mbuf.h/mbuf_append.md b/docs/c-api/mbuf.h/mbuf_append.md
deleted file mode 100644
index af0de26eb..000000000
--- a/docs/c-api/mbuf.h/mbuf_append.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mbuf_append()"
-decl_name: "mbuf_append"
-symbol_kind: "func"
-signature: |
-  size_t mbuf_append(struct mbuf *, const void *data, size_t data_size);
----
-
-Appends data to the Mbuf.
-
-Returns the number of bytes appended or 0 if out of memory. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_free.md b/docs/c-api/mbuf.h/mbuf_free.md
deleted file mode 100644
index 6b5e455bf..000000000
--- a/docs/c-api/mbuf.h/mbuf_free.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mbuf_free()"
-decl_name: "mbuf_free"
-symbol_kind: "func"
-signature: |
-  void mbuf_free(struct mbuf *);
----
-
-Frees the space allocated for the mbuffer and resets the mbuf structure. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_init.md b/docs/c-api/mbuf.h/mbuf_init.md
deleted file mode 100644
index bc61ca0e2..000000000
--- a/docs/c-api/mbuf.h/mbuf_init.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mbuf_init()"
-decl_name: "mbuf_init"
-symbol_kind: "func"
-signature: |
-  void mbuf_init(struct mbuf *, size_t initial_capacity);
----
-
-Initialises an Mbuf.
-`initial_capacity` specifies the initial capacity of the mbuf. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_insert.md b/docs/c-api/mbuf.h/mbuf_insert.md
deleted file mode 100644
index a38137a93..000000000
--- a/docs/c-api/mbuf.h/mbuf_insert.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mbuf_insert()"
-decl_name: "mbuf_insert"
-symbol_kind: "func"
-signature: |
-  size_t mbuf_insert(struct mbuf *, size_t, const void *, size_t);
----
-
-Inserts data at a specified offset in the Mbuf.
-
-Existing data will be shifted forwards and the buffer will
-be grown if necessary.
-Returns the number of bytes inserted. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_remove.md b/docs/c-api/mbuf.h/mbuf_remove.md
deleted file mode 100644
index cf3e502d4..000000000
--- a/docs/c-api/mbuf.h/mbuf_remove.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mbuf_remove()"
-decl_name: "mbuf_remove"
-symbol_kind: "func"
-signature: |
-  void mbuf_remove(struct mbuf *, size_t data_size);
----
-
-Removes `data_size` bytes from the beginning of the buffer. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_resize.md b/docs/c-api/mbuf.h/mbuf_resize.md
deleted file mode 100644
index 0814383fa..000000000
--- a/docs/c-api/mbuf.h/mbuf_resize.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mbuf_resize()"
-decl_name: "mbuf_resize"
-symbol_kind: "func"
-signature: |
-  void mbuf_resize(struct mbuf *, size_t new_size);
----
-
-Resizes an Mbuf.
-
-If `new_size` is smaller than buffer's `len`, the
-resize is not performed. 
-
diff --git a/docs/c-api/mbuf.h/mbuf_trim.md b/docs/c-api/mbuf.h/mbuf_trim.md
deleted file mode 100644
index 743b25f90..000000000
--- a/docs/c-api/mbuf.h/mbuf_trim.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mbuf_trim()"
-decl_name: "mbuf_trim"
-symbol_kind: "func"
-signature: |
-  void mbuf_trim(struct mbuf *);
----
-
-Shrinks an Mbuf by resizing its `size` to `len`. 
-
diff --git a/docs/c-api/mbuf.h/struct_mbuf.md b/docs/c-api/mbuf.h/struct_mbuf.md
deleted file mode 100644
index 98dcdc33b..000000000
--- a/docs/c-api/mbuf.h/struct_mbuf.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "struct mbuf"
-decl_name: "struct mbuf"
-symbol_kind: "struct"
-signature: |
-  struct mbuf {
-    char *buf;   /* Buffer pointer */
-    size_t len;  /* Data length. Data is located between offset 0 and len. */
-    size_t size; /* Buffer size allocated by realloc(1). Must be >= len */
-  };
----
-
-Memory buffer descriptor 
-
diff --git a/docs/c-api/mqtt.h/intro.md b/docs/c-api/mqtt.h/intro.md
deleted file mode 100644
index bb5d31b43..000000000
--- a/docs/c-api/mqtt.h/intro.md
+++ /dev/null
@@ -1,29 +0,0 @@
----
-title: "MQTT API reference"
-symbol_kind: "intro"
-decl_name: "mqtt.h"
-items:
-  - { name: mg_mqtt_connack.md }
-  - { name: mg_mqtt_disconnect.md }
-  - { name: mg_mqtt_match_topic_expression.md }
-  - { name: mg_mqtt_next_subscribe_topic.md }
-  - { name: mg_mqtt_ping.md }
-  - { name: mg_mqtt_pong.md }
-  - { name: mg_mqtt_puback.md }
-  - { name: mg_mqtt_pubcomp.md }
-  - { name: mg_mqtt_publish.md }
-  - { name: mg_mqtt_pubrec.md }
-  - { name: mg_mqtt_pubrel.md }
-  - { name: mg_mqtt_suback.md }
-  - { name: mg_mqtt_subscribe.md }
-  - { name: mg_mqtt_unsuback.md }
-  - { name: mg_mqtt_unsubscribe.md }
-  - { name: mg_mqtt_vmatch_topic_expression.md }
-  - { name: mg_send_mqtt_handshake.md }
-  - { name: mg_send_mqtt_handshake_opt.md }
-  - { name: mg_set_protocol_mqtt.md }
-  - { name: struct_mg_mqtt_proto_data.md }
----
-
-
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_connack.md b/docs/c-api/mqtt.h/mg_mqtt_connack.md
deleted file mode 100644
index 7daaf5b42..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_connack.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_connack()"
-decl_name: "mg_mqtt_connack"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_connack(struct mg_connection *nc, uint8_t return_code);
----
-
-Sends a CONNACK command with a given `return_code`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_disconnect.md b/docs/c-api/mqtt.h/mg_mqtt_disconnect.md
deleted file mode 100644
index c727cad06..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_disconnect.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_disconnect()"
-decl_name: "mg_mqtt_disconnect"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_disconnect(struct mg_connection *nc);
----
-
-Sends a DISCONNECT command. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_match_topic_expression.md b/docs/c-api/mqtt.h/mg_mqtt_match_topic_expression.md
deleted file mode 100644
index 81575b47f..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_match_topic_expression.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_mqtt_match_topic_expression()"
-decl_name: "mg_mqtt_match_topic_expression"
-symbol_kind: "func"
-signature: |
-  int mg_mqtt_match_topic_expression(struct mg_str exp, struct mg_str topic);
----
-
-Matches a topic against a topic expression
-
-Returns 1 if it matches; 0 otherwise. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_next_subscribe_topic.md b/docs/c-api/mqtt.h/mg_mqtt_next_subscribe_topic.md
deleted file mode 100644
index ccb96e620..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_next_subscribe_topic.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_mqtt_next_subscribe_topic()"
-decl_name: "mg_mqtt_next_subscribe_topic"
-symbol_kind: "func"
-signature: |
-  int mg_mqtt_next_subscribe_topic(struct mg_mqtt_message *msg,
-                                   struct mg_str *topic, uint8_t *qos, int pos);
----
-
-Extracts the next topic expression from a SUBSCRIBE command payload.
-
-The topic expression name will point to a string in the payload buffer.
-Returns the pos of the next topic expression or -1 when the list
-of topics is exhausted. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_ping.md b/docs/c-api/mqtt.h/mg_mqtt_ping.md
deleted file mode 100644
index 757a825ee..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_ping.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_ping()"
-decl_name: "mg_mqtt_ping"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_ping(struct mg_connection *nc);
----
-
-Sends a PINGREQ command. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_pong.md b/docs/c-api/mqtt.h/mg_mqtt_pong.md
deleted file mode 100644
index c79253e3e..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_pong.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_pong()"
-decl_name: "mg_mqtt_pong"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_pong(struct mg_connection *nc);
----
-
-Sends a PINGRESP command. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_puback.md b/docs/c-api/mqtt.h/mg_mqtt_puback.md
deleted file mode 100644
index a29a352d2..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_puback.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_puback()"
-decl_name: "mg_mqtt_puback"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_puback(struct mg_connection *nc, uint16_t message_id);
----
-
-Sends a PUBACK command with a given `message_id`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_pubcomp.md b/docs/c-api/mqtt.h/mg_mqtt_pubcomp.md
deleted file mode 100644
index bc3228ca9..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_pubcomp.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_pubcomp()"
-decl_name: "mg_mqtt_pubcomp"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_pubcomp(struct mg_connection *nc, uint16_t message_id);
----
-
-Sends a PUBCOMP command with a given `message_id`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_publish.md b/docs/c-api/mqtt.h/mg_mqtt_publish.md
deleted file mode 100644
index b2a7b013b..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_publish.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_mqtt_publish()"
-decl_name: "mg_mqtt_publish"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_publish(struct mg_connection *nc, const char *topic,
-                       uint16_t message_id, int flags, const void *data,
-                       size_t len);
----
-
-Publishes a message to a given topic. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_pubrec.md b/docs/c-api/mqtt.h/mg_mqtt_pubrec.md
deleted file mode 100644
index 16cdc7d0d..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_pubrec.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_pubrec()"
-decl_name: "mg_mqtt_pubrec"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_pubrec(struct mg_connection *nc, uint16_t message_id);
----
-
-Sends a PUBREC command with a given `message_id`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_pubrel.md b/docs/c-api/mqtt.h/mg_mqtt_pubrel.md
deleted file mode 100644
index 18a6c5813..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_pubrel.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_pubrel()"
-decl_name: "mg_mqtt_pubrel"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_pubrel(struct mg_connection *nc, uint16_t message_id);
----
-
-Sends a PUBREL command with a given `message_id`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_suback.md b/docs/c-api/mqtt.h/mg_mqtt_suback.md
deleted file mode 100644
index 55cf5e3a2..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_suback.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_mqtt_suback()"
-decl_name: "mg_mqtt_suback"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_suback(struct mg_connection *nc, uint8_t *qoss, size_t qoss_len,
-                      uint16_t message_id);
----
-
-Sends a SUBACK command with a given `message_id`
-and a sequence of granted QoSs. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_subscribe.md b/docs/c-api/mqtt.h/mg_mqtt_subscribe.md
deleted file mode 100644
index 0168db410..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_subscribe.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_mqtt_subscribe()"
-decl_name: "mg_mqtt_subscribe"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_subscribe(struct mg_connection *nc,
-                         const struct mg_mqtt_topic_expression *topics,
-                         size_t topics_len, uint16_t message_id);
----
-
-Subscribes to a bunch of topics. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_unsuback.md b/docs/c-api/mqtt.h/mg_mqtt_unsuback.md
deleted file mode 100644
index a86fffc51..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_unsuback.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mqtt_unsuback()"
-decl_name: "mg_mqtt_unsuback"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_unsuback(struct mg_connection *nc, uint16_t message_id);
----
-
-Sends a UNSUBACK command with a given `message_id`. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_unsubscribe.md b/docs/c-api/mqtt.h/mg_mqtt_unsubscribe.md
deleted file mode 100644
index b4c1f783b..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_unsubscribe.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_mqtt_unsubscribe()"
-decl_name: "mg_mqtt_unsubscribe"
-symbol_kind: "func"
-signature: |
-  void mg_mqtt_unsubscribe(struct mg_connection *nc, char **topics,
-                           size_t topics_len, uint16_t message_id);
----
-
-Unsubscribes from a bunch of topics. 
-
diff --git a/docs/c-api/mqtt.h/mg_mqtt_vmatch_topic_expression.md b/docs/c-api/mqtt.h/mg_mqtt_vmatch_topic_expression.md
deleted file mode 100644
index 4b0a42315..000000000
--- a/docs/c-api/mqtt.h/mg_mqtt_vmatch_topic_expression.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_mqtt_vmatch_topic_expression()"
-decl_name: "mg_mqtt_vmatch_topic_expression"
-symbol_kind: "func"
-signature: |
-  int mg_mqtt_vmatch_topic_expression(const char *exp, struct mg_str topic);
----
-
-Same as `mg_mqtt_match_topic_expression()`, but takes `exp` as a
-NULL-terminated string. 
-
diff --git a/docs/c-api/mqtt.h/mg_send_mqtt_handshake.md b/docs/c-api/mqtt.h/mg_send_mqtt_handshake.md
deleted file mode 100644
index 0e75c4e31..000000000
--- a/docs/c-api/mqtt.h/mg_send_mqtt_handshake.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_send_mqtt_handshake()"
-decl_name: "mg_send_mqtt_handshake"
-symbol_kind: "func"
-signature: |
-  void mg_send_mqtt_handshake(struct mg_connection *nc, const char *client_id);
----
-
-Sends an MQTT handshake. 
-
diff --git a/docs/c-api/mqtt.h/mg_send_mqtt_handshake_opt.md b/docs/c-api/mqtt.h/mg_send_mqtt_handshake_opt.md
deleted file mode 100644
index 2c7a93ca6..000000000
--- a/docs/c-api/mqtt.h/mg_send_mqtt_handshake_opt.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_send_mqtt_handshake_opt()"
-decl_name: "mg_send_mqtt_handshake_opt"
-symbol_kind: "func"
-signature: |
-  void mg_send_mqtt_handshake_opt(struct mg_connection *nc, const char *client_id,
-                                  struct mg_send_mqtt_handshake_opts);
----
-
-Sends an MQTT handshake with optional parameters. 
-
diff --git a/docs/c-api/mqtt.h/mg_set_protocol_mqtt.md b/docs/c-api/mqtt.h/mg_set_protocol_mqtt.md
deleted file mode 100644
index 8c65d385a..000000000
--- a/docs/c-api/mqtt.h/mg_set_protocol_mqtt.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_set_protocol_mqtt()"
-decl_name: "mg_set_protocol_mqtt"
-symbol_kind: "func"
-signature: |
-  void mg_set_protocol_mqtt(struct mg_connection *nc);
----
-
-Attaches a built-in MQTT event handler to the given connection.
-
-The user-defined event handler will receive following extra events:
-
-- MG_EV_MQTT_CONNACK
-- MG_EV_MQTT_PUBLISH
-- MG_EV_MQTT_PUBACK
-- MG_EV_MQTT_PUBREC
-- MG_EV_MQTT_PUBREL
-- MG_EV_MQTT_PUBCOMP
-- MG_EV_MQTT_SUBACK 
-
diff --git a/docs/c-api/mqtt.h/struct_mg_mqtt_proto_data.md b/docs/c-api/mqtt.h/struct_mg_mqtt_proto_data.md
deleted file mode 100644
index f095589d2..000000000
--- a/docs/c-api/mqtt.h/struct_mg_mqtt_proto_data.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "struct mg_mqtt_proto_data"
-decl_name: "struct mg_mqtt_proto_data"
-symbol_kind: "struct"
-signature: |
-  struct mg_mqtt_proto_data {
-    uint16_t keep_alive;
-    double last_control_time;
-  };
----
-
-mg_mqtt_proto_data should be in header to allow external access to it 
-
diff --git a/docs/c-api/mqtt_server.h/LIST_ENTRY.md b/docs/c-api/mqtt_server.h/LIST_ENTRY.md
deleted file mode 100644
index 3d30ddd31..000000000
--- a/docs/c-api/mqtt_server.h/LIST_ENTRY.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "LIST_ENTRY()"
-decl_name: "LIST_ENTRY"
-symbol_kind: "func"
-signature: |
-    LIST_ENTRY(mg_mqtt_session);
----
-
-Broker 
-
diff --git a/docs/c-api/mqtt_server.h/intro.md b/docs/c-api/mqtt_server.h/intro.md
deleted file mode 100644
index de92327e2..000000000
--- a/docs/c-api/mqtt_server.h/intro.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "MQTT Server API reference"
-symbol_kind: "intro"
-decl_name: "mqtt_server.h"
-items:
-  - { name: LIST_ENTRY.md }
-  - { name: struct_mg_mqtt_broker.md }
-  - { name: struct_mg_mqtt_session.md }
----
-
-
-
diff --git a/docs/c-api/mqtt_server.h/struct_mg_mqtt_broker.md b/docs/c-api/mqtt_server.h/struct_mg_mqtt_broker.md
deleted file mode 100644
index eaaa637f7..000000000
--- a/docs/c-api/mqtt_server.h/struct_mg_mqtt_broker.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "struct mg_mqtt_broker"
-decl_name: "struct mg_mqtt_broker"
-symbol_kind: "struct"
-signature: |
-  struct mg_mqtt_broker {
-    LIST_HEAD(_mg_sesshead, mg_mqtt_session) sessions; /* Session list */
-    void *user_data;                                   /* User data */
-  };
----
-
-MQTT broker. 
-
diff --git a/docs/c-api/mqtt_server.h/struct_mg_mqtt_session.md b/docs/c-api/mqtt_server.h/struct_mg_mqtt_session.md
deleted file mode 100644
index e38a4dfad..000000000
--- a/docs/c-api/mqtt_server.h/struct_mg_mqtt_session.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "struct mg_mqtt_session"
-decl_name: "struct mg_mqtt_session"
-symbol_kind: "struct"
-signature: |
-  struct mg_mqtt_session {
-    struct mg_mqtt_broker *brk;       /* Broker */
-    LIST_ENTRY(mg_mqtt_session) link; /* mg_mqtt_broker::sessions linkage */
-    struct mg_connection *nc;         /* Connection with the client */
-    size_t num_subscriptions;         /* Size of `subscriptions` array */
-    void *user_data;                  /* User data */
-    struct mg_mqtt_topic_expression *subscriptions;
-  };
----
-
-MQTT session (Broker side). 
-
diff --git a/docs/c-api/net.h/intro.md b/docs/c-api/net.h/intro.md
deleted file mode 100644
index 1534ceb03..000000000
--- a/docs/c-api/net.h/intro.md
+++ /dev/null
@@ -1,41 +0,0 @@
----
-title: "Core API: TCP/UDP/SSL"
-symbol_kind: "intro"
-decl_name: "net.h"
-items:
-  - { name: mg_add_sock.md }
-  - { name: mg_add_sock_opt.md }
-  - { name: mg_bind.md }
-  - { name: mg_bind_opt.md }
-  - { name: mg_broadcast.md }
-  - { name: mg_check_ip_acl.md }
-  - { name: mg_connect.md }
-  - { name: mg_connect_opt.md }
-  - { name: mg_mgr_free.md }
-  - { name: mg_mgr_init.md }
-  - { name: mg_mgr_init_opt.md }
-  - { name: mg_mgr_poll.md }
-  - { name: mg_next.md }
-  - { name: mg_printf.md }
-  - { name: mg_resolve.md }
-  - { name: mg_send.md }
-  - { name: mg_set_ssl.md }
-  - { name: mg_set_timer.md }
-  - { name: mg_socketpair.md }
-  - { name: mg_time.md }
-  - { name: mg_vprintf.md }
-  - { name: mg_event_handler_t.md }
-  - { name: struct_mg_add_sock_opts.md }
-  - { name: struct_mg_bind_opts.md }
-  - { name: struct_mg_connect_opts.md }
-  - { name: struct_mg_connection.md }
-  - { name: struct_mg_mgr.md }
-  - { name: struct_mg_mgr_init_opts.md }
----
-
-NOTE: Mongoose manager is single threaded. It does not protect
-its data structures by mutexes, therefore all functions that are dealing
-with a particular event manager should be called from the same thread,
-with exception of the `mg_broadcast()` function. It is fine to have different
-event managers handled by different threads.
-
diff --git a/docs/c-api/net.h/mg_add_sock.md b/docs/c-api/net.h/mg_add_sock.md
deleted file mode 100644
index e63ce2e48..000000000
--- a/docs/c-api/net.h/mg_add_sock.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_add_sock()"
-decl_name: "mg_add_sock"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_add_sock(struct mg_mgr *mgr, sock_t sock,
-                                    MG_CB(mg_event_handler_t handler,
-                                          void *user_data);
----
-
-Creates a connection, associates it with the given socket and event handler
-and adds it to the manager.
-
-For more options see the `mg_add_sock_opt` variant. 
-
diff --git a/docs/c-api/net.h/mg_add_sock_opt.md b/docs/c-api/net.h/mg_add_sock_opt.md
deleted file mode 100644
index de2a22e9f..000000000
--- a/docs/c-api/net.h/mg_add_sock_opt.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_add_sock_opt()"
-decl_name: "mg_add_sock_opt"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_add_sock_opt(struct mg_mgr *mgr, sock_t sock,
-                                        MG_CB(mg_event_handler_t handler,
-                                              void *user_data);
----
-
-Creates a connection, associates it with the given socket and event handler
-and adds to the manager.
-
-See the `mg_add_sock_opts` structure for a description of the options. 
-
diff --git a/docs/c-api/net.h/mg_bind.md b/docs/c-api/net.h/mg_bind.md
deleted file mode 100644
index 9507d51c5..000000000
--- a/docs/c-api/net.h/mg_bind.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_bind()"
-decl_name: "mg_bind"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_bind(struct mg_mgr *mgr, const char *address,
-                                MG_CB(mg_event_handler_t handler,
-                                      void *user_data);
----
-
-Creates a listening connection.
-
-See `mg_bind_opt` for full documentation. 
-
diff --git a/docs/c-api/net.h/mg_bind_opt.md b/docs/c-api/net.h/mg_bind_opt.md
deleted file mode 100644
index 823dd0c0a..000000000
--- a/docs/c-api/net.h/mg_bind_opt.md
+++ /dev/null
@@ -1,27 +0,0 @@
----
-title: "mg_bind_opt()"
-decl_name: "mg_bind_opt"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_bind_opt(struct mg_mgr *mgr, const char *address,
-                                    MG_CB(mg_event_handler_t handler,
-                                          void *user_data);
----
-
-Creates a listening connection.
-
-The `address` parameter specifies which address to bind to. It's format is
-the same as for the `mg_connect()` call, where `HOST` part is optional.
-`address` can be just a port number, e.g. `:8000`. To bind to a specific
-interface, an IP address can be specified, e.g. `1.2.3.4:8000`. By default,
-a TCP connection is created. To create UDP connection, prepend `udp://`
-prefix, e.g. `udp://:8000`. To summarize, `address` parameter has following
-format: `[PROTO://][IP_ADDRESS]:PORT`, where `PROTO` could be `tcp` or
-`udp`.
-
-See the `mg_bind_opts` structure for a description of the optional
-parameters.
-
-Returns a new listening connection or `NULL` on error.
-NOTE: The connection remains owned by the manager, do not free(). 
-
diff --git a/docs/c-api/net.h/mg_broadcast.md b/docs/c-api/net.h/mg_broadcast.md
deleted file mode 100644
index cef0b379c..000000000
--- a/docs/c-api/net.h/mg_broadcast.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_broadcast()"
-decl_name: "mg_broadcast"
-symbol_kind: "func"
-signature: |
-  void mg_broadcast(struct mg_mgr *mgr, mg_event_handler_t cb, void *data,
-                    size_t len);
----
-
-Passes a message of a given length to all connections.
-
-Must be called from a thread that does NOT call `mg_mgr_poll()`.
-Note that `mg_broadcast()` is the only function
-that can be, and must be, called from a different (non-IO) thread.
-
-`func` callback function will be called by the IO thread for each
-connection. When called, the event will be `MG_EV_POLL`, and a message will
-be passed as the `ev_data` pointer. Maximum message size is capped
-by `MG_CTL_MSG_MESSAGE_SIZE` which is set to 8192 bytes. 
-
diff --git a/docs/c-api/net.h/mg_check_ip_acl.md b/docs/c-api/net.h/mg_check_ip_acl.md
deleted file mode 100644
index 83c2c7ba2..000000000
--- a/docs/c-api/net.h/mg_check_ip_acl.md
+++ /dev/null
@@ -1,27 +0,0 @@
----
-title: "mg_check_ip_acl()"
-decl_name: "mg_check_ip_acl"
-symbol_kind: "func"
-signature: |
-  int mg_check_ip_acl(const char *acl, uint32_t remote_ip);
----
-
-Verify given IP address against the ACL.
-
-`remote_ip` - an IPv4 address to check, in host byte order
-`acl` - a comma separated list of IP subnets: `x.x.x.x/x` or `x.x.x.x`.
-Each subnet is
-prepended by either a - or a + sign. A plus sign means allow, where a
-minus sign means deny. If a subnet mask is omitted, such as `-1.2.3.4`,
-it means that only that single IP address is denied.
-Subnet masks may vary from 0 to 32, inclusive. The default setting
-is to allow all access. On each request the full list is traversed,
-and the last match wins. Example:
-
-`-0.0.0.0/0,+192.168/16` - deny all accesses, only allow 192.168/16 subnet
-
-To learn more about subnet masks, see this
-link:https://en.wikipedia.org/wiki/Subnetwork[Wikipedia page on Subnetwork].
-
-Returns -1 if ACL is malformed, 0 if address is disallowed, 1 if allowed. 
-
diff --git a/docs/c-api/net.h/mg_connect.md b/docs/c-api/net.h/mg_connect.md
deleted file mode 100644
index 788be84e6..000000000
--- a/docs/c-api/net.h/mg_connect.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_connect()"
-decl_name: "mg_connect"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect(struct mg_mgr *mgr, const char *address,
-                                   MG_CB(mg_event_handler_t handler,
-                                         void *user_data);
----
-
-Connects to a remote host.
-
-See `mg_connect_opt()` for full documentation. 
-
diff --git a/docs/c-api/net.h/mg_connect_opt.md b/docs/c-api/net.h/mg_connect_opt.md
deleted file mode 100644
index 3ae818a44..000000000
--- a/docs/c-api/net.h/mg_connect_opt.md
+++ /dev/null
@@ -1,57 +0,0 @@
----
-title: "mg_connect_opt()"
-decl_name: "mg_connect_opt"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_connect_opt(struct mg_mgr *mgr, const char *address,
-                                       MG_CB(mg_event_handler_t handler,
-                                             void *user_data);
----
-
-Connects to a remote host.
-
-The `address` format is `[PROTO://]HOST:PORT`. `PROTO` could be `tcp` or
-`udp`. `HOST` could be an IP address,
-IPv6 address (if Mongoose is compiled with `-DMG_ENABLE_IPV6`) or a host
-name. If `HOST` is a name, Mongoose will resolve it asynchronously. Examples
-of valid addresses: `google.com:80`, `udp://1.2.3.4:53`, `10.0.0.1:443`,
-`[::1]:80`
-
-See the `mg_connect_opts` structure for a description of the optional
-parameters.
-
-Returns a new outbound connection or `NULL` on error.
-
-NOTE: The connection remains owned by the manager, do not free().
-
-NOTE: To enable IPv6 addresses `-DMG_ENABLE_IPV6` should be specified
-in the compilation flags.
-
-NOTE: The new connection will receive `MG_EV_CONNECT` as its first event
-which will report the connect success status.
-If the asynchronous resolution fails or the `connect()` syscall fails for
-whatever reason (e.g. with `ECONNREFUSED` or `ENETUNREACH`), then
-`MG_EV_CONNECT` event will report failure. Code example below:
-
-```c
-static void ev_handler(struct mg_connection *nc, int ev, void *ev_data) {
-  int connect_status;
-
-  switch (ev) {
-    case MG_EV_CONNECT:
-      connect_status = * (int *) ev_data;
-      if (connect_status == 0) {
-        // Success
-      } else  {
-        // Error
-        printf("connect() error: %s\n", strerror(connect_status));
-      }
-      break;
-    ...
-  }
-}
-
-  ...
-  mg_connect(mgr, "my_site.com:80", ev_handler);
-``` 
-
diff --git a/docs/c-api/net.h/mg_event_handler_t.md b/docs/c-api/net.h/mg_event_handler_t.md
deleted file mode 100644
index 5a4822246..000000000
--- a/docs/c-api/net.h/mg_event_handler_t.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_event_handler_t"
-decl_name: "mg_event_handler_t"
-symbol_kind: "typedef"
-signature: |
-  typedef void (*mg_event_handler_t)(struct mg_connection *nc, int ev,
-                                     void *ev_data MG_UD_ARG(void *user_data));
----
-
-Callback function (event handler) prototype. Must be defined by the user.
-Mongoose calls the event handler, passing the events defined below. 
-
diff --git a/docs/c-api/net.h/mg_mgr_free.md b/docs/c-api/net.h/mg_mgr_free.md
deleted file mode 100644
index d2df34e4c..000000000
--- a/docs/c-api/net.h/mg_mgr_free.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_mgr_free()"
-decl_name: "mg_mgr_free"
-symbol_kind: "func"
-signature: |
-  void mg_mgr_free(struct mg_mgr *);
----
-
-De-initialises Mongoose manager.
-
-Closes and deallocates all active connections. 
-
diff --git a/docs/c-api/net.h/mg_mgr_init.md b/docs/c-api/net.h/mg_mgr_init.md
deleted file mode 100644
index 1e44bf502..000000000
--- a/docs/c-api/net.h/mg_mgr_init.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_mgr_init()"
-decl_name: "mg_mgr_init"
-symbol_kind: "func"
-signature: |
-  void mg_mgr_init(struct mg_mgr *mgr, void *user_data);
----
-
-Initialise Mongoose manager. Side effect: ignores SIGPIPE signal.
-`mgr->user_data` field will be initialised with a `user_data` parameter.
-That is an arbitrary pointer, where the user code can associate some data
-with the particular Mongoose manager. For example, a C++ wrapper class
-could be written in which case `user_data` can hold a pointer to the
-class instance. 
-
diff --git a/docs/c-api/net.h/mg_mgr_init_opt.md b/docs/c-api/net.h/mg_mgr_init_opt.md
deleted file mode 100644
index 767fed2c2..000000000
--- a/docs/c-api/net.h/mg_mgr_init_opt.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_mgr_init_opt()"
-decl_name: "mg_mgr_init_opt"
-symbol_kind: "func"
-signature: |
-  void mg_mgr_init_opt(struct mg_mgr *mgr, void *user_data,
-                       struct mg_mgr_init_opts opts);
----
-
-Like `mg_mgr_init` but with more options.
-
-Notably, this allows you to create a manger and choose
-dynamically which networking interface implementation to use. 
-
diff --git a/docs/c-api/net.h/mg_mgr_poll.md b/docs/c-api/net.h/mg_mgr_poll.md
deleted file mode 100644
index b70c31b6d..000000000
--- a/docs/c-api/net.h/mg_mgr_poll.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_mgr_poll()"
-decl_name: "mg_mgr_poll"
-symbol_kind: "func"
-signature: |
-  time_t mg_mgr_poll(struct mg_mgr *, int milli);
----
-
-This function performs the actual IO and must be called in a loop
-(an event loop). It returns the current timestamp.
-`milli` is the maximum number of milliseconds to sleep.
-`mg_mgr_poll()` checks all connections for IO readiness. If at least one
-of the connections is IO-ready, `mg_mgr_poll()` triggers the respective
-event handlers and returns. 
-
diff --git a/docs/c-api/net.h/mg_next.md b/docs/c-api/net.h/mg_next.md
deleted file mode 100644
index 423af6fdb..000000000
--- a/docs/c-api/net.h/mg_next.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_next()"
-decl_name: "mg_next"
-symbol_kind: "func"
-signature: |
-  struct mg_connection *mg_next(struct mg_mgr *mgr, struct mg_connection *c);
----
-
-Iterates over all active connections.
-
-Returns the next connection from the list
-of active connections or `NULL` if there are no more connections. Below
-is the iteration idiom:
-
-```c
-for (c = mg_next(srv, NULL); c != NULL; c = mg_next(srv, c)) {
-  // Do something with connection `c`
-}
-``` 
-
diff --git a/docs/c-api/net.h/mg_printf.md b/docs/c-api/net.h/mg_printf.md
deleted file mode 100644
index 2448235f7..000000000
--- a/docs/c-api/net.h/mg_printf.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_printf()"
-decl_name: "mg_printf"
-symbol_kind: "func"
-signature: |
-  int mg_printf(struct mg_connection *, const char *fmt, ...);
----
-
-Sends `printf`-style formatted data to the connection.
-
-See `mg_send` for more details on send semantics. 
-
diff --git a/docs/c-api/net.h/mg_resolve.md b/docs/c-api/net.h/mg_resolve.md
deleted file mode 100644
index 9861e182b..000000000
--- a/docs/c-api/net.h/mg_resolve.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_resolve()"
-decl_name: "mg_resolve"
-symbol_kind: "func"
-signature: |
-  int mg_resolve(const char *domain_name, char *ip_addr_buf, size_t buf_len);
----
-
-Convert domain name into IP address.
-
-This is a utility function. If compilation flags have
-`-DMG_ENABLE_GETADDRINFO`, then `getaddrinfo()` call is used for name
-resolution. Otherwise, `gethostbyname()` is used.
-
-CAUTION: this function can block.
-Return 1 on success, 0 on failure. 
-
diff --git a/docs/c-api/net.h/mg_send.md b/docs/c-api/net.h/mg_send.md
deleted file mode 100644
index c6963a0d6..000000000
--- a/docs/c-api/net.h/mg_send.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_send()"
-decl_name: "mg_send"
-symbol_kind: "func"
-signature: |
-  void mg_send(struct mg_connection *, const void *buf, int len);
----
-
-Sends data to the connection.
-
-Note that sending functions do not actually push data to the socket.
-They just append data to the output buffer. MG_EV_SEND will be delivered when
-the data has actually been pushed out. 
-
diff --git a/docs/c-api/net.h/mg_set_ssl.md b/docs/c-api/net.h/mg_set_ssl.md
deleted file mode 100644
index 35d12d399..000000000
--- a/docs/c-api/net.h/mg_set_ssl.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "mg_set_ssl()"
-decl_name: "mg_set_ssl"
-symbol_kind: "func"
-signature: |
-  const char *mg_set_ssl(struct mg_connection *nc, const char *cert,
-                         const char *ca_cert);
----
-
-Note: This function is deprecated. Please, use SSL options in
-mg_connect_opt.
-
-Enables SSL for a given connection.
-`cert` is a server certificate file name for a listening connection
-or a client certificate file name for an outgoing connection.
-The certificate files must be in PEM format. The server certificate file
-must contain a certificate, concatenated with a private key, optionally
-concatenated with DH parameters.
-`ca_cert` is a CA certificate or NULL if peer verification is not
-required.
-Return: NULL on success or error message on error. 
-
diff --git a/docs/c-api/net.h/mg_set_timer.md b/docs/c-api/net.h/mg_set_timer.md
deleted file mode 100644
index 0b0892065..000000000
--- a/docs/c-api/net.h/mg_set_timer.md
+++ /dev/null
@@ -1,31 +0,0 @@
----
-title: "mg_set_timer()"
-decl_name: "mg_set_timer"
-symbol_kind: "func"
-signature: |
-  double mg_set_timer(struct mg_connection *c, double timestamp);
----
-
-Schedules an MG_EV_TIMER event to be delivered at `timestamp` time.
-`timestamp` is UNIX time (the number of seconds since Epoch). It is
-`double` instead of `time_t` to allow for sub-second precision.
-Returns the old timer value.
-
-Example: set the connect timeout to 1.5 seconds:
-
-```
- c = mg_connect(&mgr, "cesanta.com", ev_handler);
- mg_set_timer(c, mg_time() + 1.5);
- ...
-
- void ev_handler(struct mg_connection *c, int ev, void *ev_data) {
- switch (ev) {
-   case MG_EV_CONNECT:
-     mg_set_timer(c, 0);  // Clear connect timer
-     break;
-   case MG_EV_TIMER:
-     log("Connect timeout");
-     c->flags |= MG_F_CLOSE_IMMEDIATELY;
-     break;
-``` 
-
diff --git a/docs/c-api/net.h/mg_socketpair.md b/docs/c-api/net.h/mg_socketpair.md
deleted file mode 100644
index bd36cbce7..000000000
--- a/docs/c-api/net.h/mg_socketpair.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_socketpair()"
-decl_name: "mg_socketpair"
-symbol_kind: "func"
-signature: |
-  int mg_socketpair(sock_t[2], int sock_type);
----
-
-Creates a socket pair.
-`sock_type` can be either `SOCK_STREAM` or `SOCK_DGRAM`.
-Returns 0 on failure and 1 on success. 
-
diff --git a/docs/c-api/net.h/mg_time.md b/docs/c-api/net.h/mg_time.md
deleted file mode 100644
index ec93b8972..000000000
--- a/docs/c-api/net.h/mg_time.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_time()"
-decl_name: "mg_time"
-symbol_kind: "func"
-signature: |
-  double mg_time(void);
----
-
-A sub-second precision version of time(). 
-
diff --git a/docs/c-api/net.h/mg_vprintf.md b/docs/c-api/net.h/mg_vprintf.md
deleted file mode 100644
index ff66e264f..000000000
--- a/docs/c-api/net.h/mg_vprintf.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_vprintf()"
-decl_name: "mg_vprintf"
-symbol_kind: "func"
-signature: |
-  int mg_vprintf(struct mg_connection *, const char *fmt, va_list ap);
----
-
-Same as `mg_printf()`, but takes `va_list ap` as an argument. 
-
diff --git a/docs/c-api/net.h/struct_mg_add_sock_opts.md b/docs/c-api/net.h/struct_mg_add_sock_opts.md
deleted file mode 100644
index b4b1737bc..000000000
--- a/docs/c-api/net.h/struct_mg_add_sock_opts.md
+++ /dev/null
@@ -1,18 +0,0 @@
----
-title: "struct mg_add_sock_opts"
-decl_name: "struct mg_add_sock_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_add_sock_opts {
-    void *user_data;           /* Initial value for connection's user_data */
-    unsigned int flags;        /* Initial connection flags */
-    const char **error_string; /* Placeholder for the error string */
-    struct mg_iface *iface;    /* Interface instance */
-  };
----
-
-Optional parameters to `mg_add_sock_opt()`.
-
-`flags` is an initial `struct mg_connection::flags` bitmask to set,
-see `MG_F_*` flags definitions. 
-
diff --git a/docs/c-api/net.h/struct_mg_bind_opts.md b/docs/c-api/net.h/struct_mg_bind_opts.md
deleted file mode 100644
index 13217ec79..000000000
--- a/docs/c-api/net.h/struct_mg_bind_opts.md
+++ /dev/null
@@ -1,44 +0,0 @@
----
-title: "struct mg_bind_opts"
-decl_name: "struct mg_bind_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_bind_opts {
-    void *user_data;           /* Initial value for connection's user_data */
-    unsigned int flags;        /* Extra connection flags */
-    const char **error_string; /* Placeholder for the error string */
-    struct mg_iface *iface;    /* Interface instance */
-  #if MG_ENABLE_SSL
-    /*
-     * SSL settings.
-     *
-     * Server certificate to present to clients or client certificate to
-     * present to tunnel dispatcher (for tunneled connections).
-     */
-    const char *ssl_cert;
-    /* Private key corresponding to the certificate. If ssl_cert is set but
-     * ssl_key is not, ssl_cert is used. */
-    const char *ssl_key;
-    /* CA bundle used to verify client certificates or tunnel dispatchers. */
-    const char *ssl_ca_cert;
-    /* Colon-delimited list of acceptable cipher suites.
-     * Names depend on the library used, for example:
-     *
-     * ECDH-ECDSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256 (OpenSSL)
-     * TLS-ECDH-ECDSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256
-     *   (mbedTLS)
-     *
-     * For OpenSSL the list can be obtained by running "openssl ciphers".
-     * For mbedTLS, names can be found in library/ssl_ciphersuites.c
-     * If NULL, a reasonable default is used.
-     */
-    const char *ssl_cipher_suites;
-  #endif
-  };
----
-
-Optional parameters to `mg_bind_opt()`.
-
-`flags` is an initial `struct mg_connection::flags` bitmask to set,
-see `MG_F_*` flags definitions. 
-
diff --git a/docs/c-api/net.h/struct_mg_connect_opts.md b/docs/c-api/net.h/struct_mg_connect_opts.md
deleted file mode 100644
index f05bf25f4..000000000
--- a/docs/c-api/net.h/struct_mg_connect_opts.md
+++ /dev/null
@@ -1,62 +0,0 @@
----
-title: "struct mg_connect_opts"
-decl_name: "struct mg_connect_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_connect_opts {
-    void *user_data;           /* Initial value for connection's user_data */
-    unsigned int flags;        /* Extra connection flags */
-    const char **error_string; /* Placeholder for the error string */
-    struct mg_iface *iface;    /* Interface instance */
-    const char *nameserver;    /* DNS server to use, NULL for default */
-  #if MG_ENABLE_SSL
-    /*
-     * SSL settings.
-     * Client certificate to present to the server.
-     */
-    const char *ssl_cert;
-    /*
-     * Private key corresponding to the certificate.
-     * If ssl_cert is set but ssl_key is not, ssl_cert is used.
-     */
-    const char *ssl_key;
-    /*
-     * Verify server certificate using this CA bundle. If set to "*", then SSL
-     * is enabled but no cert verification is performed.
-     */
-    const char *ssl_ca_cert;
-    /* Colon-delimited list of acceptable cipher suites.
-     * Names depend on the library used, for example:
-     *
-     * ECDH-ECDSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256 (OpenSSL)
-     * TLS-ECDH-ECDSA-WITH-AES-128-GCM-SHA256:TLS-DHE-RSA-WITH-AES-128-GCM-SHA256
-     *   (mbedTLS)
-     *
-     * For OpenSSL the list can be obtained by running "openssl ciphers".
-     * For mbedTLS, names can be found in library/ssl_ciphersuites.c
-     * If NULL, a reasonable default is used.
-     */
-    const char *ssl_cipher_suites;
-    /*
-     * Server name verification. If ssl_ca_cert is set and the certificate has
-     * passed verification, its subject will be verified against this string.
-     * By default (if ssl_server_name is NULL) hostname part of the address will
-     * be used. Wildcard matching is supported. A special value of "*" disables
-     * name verification.
-     */
-    const char *ssl_server_name;
-    /*
-     * PSK identity and key. Identity is a NUL-terminated string and key is a hex
-     * string. Key must be either 16 or 32 bytes (32 or 64 hex digits) for AES-128
-     * or AES-256 respectively.
-     * Note: Default list of cipher suites does not include PSK suites, if you
-     * want to use PSK you will need to set ssl_cipher_suites as well.
-     */
-    const char *ssl_psk_identity;
-    const char *ssl_psk_key;
-  #endif
-  };
----
-
-Optional parameters to `mg_connect_opt()` 
-
diff --git a/docs/c-api/net.h/struct_mg_connection.md b/docs/c-api/net.h/struct_mg_connection.md
deleted file mode 100644
index be69d16fd..000000000
--- a/docs/c-api/net.h/struct_mg_connection.md
+++ /dev/null
@@ -1,67 +0,0 @@
----
-title: "struct mg_connection"
-decl_name: "struct mg_connection"
-symbol_kind: "struct"
-signature: |
-  struct mg_connection {
-    struct mg_connection *next, *prev; /* mg_mgr::active_connections linkage */
-    struct mg_connection *listener;    /* Set only for accept()-ed connections */
-    struct mg_mgr *mgr;                /* Pointer to containing manager */
-  
-    sock_t sock; /* Socket to the remote peer */
-    int err;
-    union socket_address sa; /* Remote peer address */
-    size_t recv_mbuf_limit;  /* Max size of recv buffer */
-    struct mbuf recv_mbuf;   /* Received data */
-    struct mbuf send_mbuf;   /* Data scheduled for sending */
-    time_t last_io_time;     /* Timestamp of the last socket IO */
-    double ev_timer_time;    /* Timestamp of the future MG_EV_TIMER */
-  #if MG_ENABLE_SSL
-    void *ssl_if_data; /* SSL library data. */
-  #endif
-    mg_event_handler_t proto_handler; /* Protocol-specific event handler */
-    void *proto_data;                 /* Protocol-specific data */
-    void (*proto_data_destructor)(void *proto_data);
-    mg_event_handler_t handler; /* Event handler function */
-    void *user_data;            /* User-specific data */
-    union {
-      void *v;
-      /*
-       * the C standard is fussy about fitting function pointers into
-       * void pointers, since some archs might have fat pointers for functions.
-       */
-      mg_event_handler_t f;
-    } priv_1;
-    void *priv_2;
-    void *mgr_data; /* Implementation-specific event manager's data. */
-    struct mg_iface *iface;
-    unsigned long flags;
-  /* Flags set by Mongoose */
-  #define MG_F_LISTENING (1 << 0)          /* This connection is listening */
-  #define MG_F_UDP (1 << 1)                /* This connection is UDP */
-  #define MG_F_RESOLVING (1 << 2)          /* Waiting for async resolver */
-  #define MG_F_CONNECTING (1 << 3)         /* connect() call in progress */
-  #define MG_F_SSL (1 << 4)                /* SSL is enabled on the connection */
-  #define MG_F_SSL_HANDSHAKE_DONE (1 << 5) /* SSL hanshake has completed */
-  #define MG_F_WANT_READ (1 << 6)          /* SSL specific */
-  #define MG_F_WANT_WRITE (1 << 7)         /* SSL specific */
-  #define MG_F_IS_WEBSOCKET (1 << 8)       /* Websocket specific */
-  
-  /* Flags that are settable by user */
-  #define MG_F_SEND_AND_CLOSE (1 << 10)      /* Push remaining data and close  */
-  #define MG_F_CLOSE_IMMEDIATELY (1 << 11)   /* Disconnect */
-  #define MG_F_WEBSOCKET_NO_DEFRAG (1 << 12) /* Websocket specific */
-  #define MG_F_DELETE_CHUNK (1 << 13)        /* HTTP specific */
-  #define MG_F_ENABLE_BROADCAST (1 << 14)    /* Allow broadcast address usage */
-  
-  #define MG_F_USER_1 (1 << 20) /* Flags left for application */
-  #define MG_F_USER_2 (1 << 21)
-  #define MG_F_USER_3 (1 << 22)
-  #define MG_F_USER_4 (1 << 23)
-  #define MG_F_USER_5 (1 << 24)
-  #define MG_F_USER_6 (1 << 25)
-  };
----
-
-Mongoose connection. 
-
diff --git a/docs/c-api/net.h/struct_mg_mgr.md b/docs/c-api/net.h/struct_mg_mgr.md
deleted file mode 100644
index d33727c38..000000000
--- a/docs/c-api/net.h/struct_mg_mgr.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "struct mg_mgr"
-decl_name: "struct mg_mgr"
-symbol_kind: "struct"
-signature: |
-  struct mg_mgr {
-    struct mg_connection *active_connections;
-  #if MG_ENABLE_HEXDUMP
-    const char *hexdump_file; /* Debug hexdump file path */
-  #endif
-  #if MG_ENABLE_BROADCAST
-    sock_t ctl[2]; /* Socketpair for mg_broadcast() */
-  #endif
-    void *user_data; /* User data */
-    int num_ifaces;
-    struct mg_iface **ifaces; /* network interfaces */
-    const char *nameserver;   /* DNS server to use */
-  };
----
-
-Mongoose event manager. 
-
diff --git a/docs/c-api/net.h/struct_mg_mgr_init_opts.md b/docs/c-api/net.h/struct_mg_mgr_init_opts.md
deleted file mode 100644
index 7db23de5b..000000000
--- a/docs/c-api/net.h/struct_mg_mgr_init_opts.md
+++ /dev/null
@@ -1,27 +0,0 @@
----
-title: "struct mg_mgr_init_opts"
-decl_name: "struct mg_mgr_init_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_mgr_init_opts {
-    const struct mg_iface_vtable *main_iface;
-    int num_ifaces;
-    const struct mg_iface_vtable **ifaces;
-    const char *nameserver;
-  };
----
-
-Optional parameters to `mg_mgr_init_opt()`.
-
-If `main_iface` is not NULL, it will be used as the main interface in the
-default interface set. The pointer will be free'd by `mg_mgr_free`.
-Otherwise, the main interface will be autodetected based on the current
-platform.
-
-If `num_ifaces` is 0 and `ifaces` is NULL, the default interface set will be
-used.
-This is an advanced option, as it requires you to construct a full interface
-set, including special networking interfaces required by some optional
-features such as TCP tunneling. Memory backing `ifaces` and each of the
-`num_ifaces` pointers it contains will be reclaimed by `mg_mgr_free`. 
-
diff --git a/docs/c-api/resolv.h/intro.md b/docs/c-api/resolv.h/intro.md
deleted file mode 100644
index f77184f9e..000000000
--- a/docs/c-api/resolv.h/intro.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "API reference"
-symbol_kind: "intro"
-decl_name: "resolv.h"
-items:
-  - { name: mg_resolve_async.md }
-  - { name: mg_resolve_async_opt.md }
-  - { name: mg_resolve_from_hosts_file.md }
-  - { name: mg_set_nameserver.md }
-  - { name: struct_mg_resolve_async_opts.md }
----
-
-
-
diff --git a/docs/c-api/resolv.h/mg_resolve_async.md b/docs/c-api/resolv.h/mg_resolve_async.md
deleted file mode 100644
index e4dc5d5d0..000000000
--- a/docs/c-api/resolv.h/mg_resolve_async.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "mg_resolve_async()"
-decl_name: "mg_resolve_async"
-symbol_kind: "func"
-signature: |
-  int mg_resolve_async(struct mg_mgr *mgr, const char *name, int query,
-                       mg_resolve_callback_t cb, void *data);
----
-
-See `mg_resolve_async_opt()` 
-
diff --git a/docs/c-api/resolv.h/mg_resolve_async_opt.md b/docs/c-api/resolv.h/mg_resolve_async_opt.md
deleted file mode 100644
index 56f209a74..000000000
--- a/docs/c-api/resolv.h/mg_resolve_async_opt.md
+++ /dev/null
@@ -1,30 +0,0 @@
----
-title: "mg_resolve_async_opt()"
-decl_name: "mg_resolve_async_opt"
-symbol_kind: "func"
-signature: |
-  int mg_resolve_async_opt(struct mg_mgr *mgr, const char *name, int query,
-                           mg_resolve_callback_t cb, void *data,
-                           struct mg_resolve_async_opts opts);
----
-
-Resolved a DNS name asynchronously.
-
-Upon successful resolution, the user callback will be invoked
-with the full DNS response message and a pointer to the user's
-context `data`.
-
-In case of timeout while performing the resolution the callback
-will receive a NULL `msg`.
-
-The DNS answers can be extracted with `mg_next_record` and
-`mg_dns_parse_record_data`:
-
-[source,c]
-----
-struct in_addr ina;
-struct mg_dns_resource_record *rr = mg_next_record(msg, MG_DNS_A_RECORD,
-  NULL);
-mg_dns_parse_record_data(msg, rr, &ina, sizeof(ina));
----- 
-
diff --git a/docs/c-api/resolv.h/mg_resolve_from_hosts_file.md b/docs/c-api/resolv.h/mg_resolve_from_hosts_file.md
deleted file mode 100644
index 42aa1e67c..000000000
--- a/docs/c-api/resolv.h/mg_resolve_from_hosts_file.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_resolve_from_hosts_file()"
-decl_name: "mg_resolve_from_hosts_file"
-symbol_kind: "func"
-signature: |
-  int mg_resolve_from_hosts_file(const char *host, union socket_address *usa);
----
-
-Resolve a name from `/etc/hosts`.
-
-Returns 0 on success, -1 on failure. 
-
diff --git a/docs/c-api/resolv.h/mg_set_nameserver.md b/docs/c-api/resolv.h/mg_set_nameserver.md
deleted file mode 100644
index 2e33c629c..000000000
--- a/docs/c-api/resolv.h/mg_set_nameserver.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_set_nameserver()"
-decl_name: "mg_set_nameserver"
-symbol_kind: "func"
-signature: |
-  void mg_set_nameserver(struct mg_mgr *mgr, const char *nameserver);
----
-
-Set default DNS server 
-
diff --git a/docs/c-api/resolv.h/struct_mg_resolve_async_opts.md b/docs/c-api/resolv.h/struct_mg_resolve_async_opts.md
deleted file mode 100644
index 8a836b9a0..000000000
--- a/docs/c-api/resolv.h/struct_mg_resolve_async_opts.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "struct mg_resolve_async_opts"
-decl_name: "struct mg_resolve_async_opts"
-symbol_kind: "struct"
-signature: |
-  struct mg_resolve_async_opts {
-    const char *nameserver;
-    int max_retries;    /* defaults to 2 if zero */
-    int timeout;        /* in seconds; defaults to 5 if zero */
-    int accept_literal; /* pseudo-resolve literal ipv4 and ipv6 addrs */
-    int only_literal;   /* only resolves literal addrs; sync cb invocation */
-    struct mg_connection **dns_conn; /* return DNS connection */
-  };
----
-
-Options for `mg_resolve_async_opt`. 
-
diff --git a/docs/c-api/uri.h/intro.md b/docs/c-api/uri.h/intro.md
deleted file mode 100644
index f266b27ec..000000000
--- a/docs/c-api/uri.h/intro.md
+++ /dev/null
@@ -1,11 +0,0 @@
----
-title: "URI"
-symbol_kind: "intro"
-decl_name: "uri.h"
-items:
-  - { name: mg_assemble_uri.md }
-  - { name: mg_parse_uri.md }
----
-
-
-
diff --git a/docs/c-api/uri.h/mg_assemble_uri.md b/docs/c-api/uri.h/mg_assemble_uri.md
deleted file mode 100644
index 200651483..000000000
--- a/docs/c-api/uri.h/mg_assemble_uri.md
+++ /dev/null
@@ -1,20 +0,0 @@
----
-title: "mg_assemble_uri()"
-decl_name: "mg_assemble_uri"
-symbol_kind: "func"
-signature: |
-  int mg_assemble_uri(const struct mg_str *scheme, const struct mg_str *user_info,
-                      const struct mg_str *host, unsigned int port,
-                      const struct mg_str *path, const struct mg_str *query,
-                      const struct mg_str *fragment, int normalize_path,
-                      struct mg_str *uri);
----
-
-Assemble URI from parts. Any of the inputs can be NULL or zero-length mg_str.
-
-If normalize_path is true, path is normalized by resolving relative refs.
-
-Result is a heap-allocated string (uri->p must be free()d after use).
-
-Returns 0 on success, -1 on error. 
-
diff --git a/docs/c-api/uri.h/mg_parse_uri.md b/docs/c-api/uri.h/mg_parse_uri.md
deleted file mode 100644
index 2d330f18e..000000000
--- a/docs/c-api/uri.h/mg_parse_uri.md
+++ /dev/null
@@ -1,33 +0,0 @@
----
-title: "mg_parse_uri()"
-decl_name: "mg_parse_uri"
-symbol_kind: "func"
-signature: |
-  int mg_parse_uri(const struct mg_str uri, struct mg_str *scheme,
-                   struct mg_str *user_info, struct mg_str *host,
-                   unsigned int *port, struct mg_str *path, struct mg_str *query,
-                   struct mg_str *fragment);
----
-
-Parses an URI and fills string chunks with locations of the respective
-uri components within the input uri string. NULL pointers will be
-ignored.
-
-General syntax:
-
-    [scheme://[user_info@]]host[:port][/path][?query][#fragment]
-
-Example:
-
-    foo.com:80
-    tcp://foo.com:1234
-    http://foo.com:80/bar?baz=1
-    https://user:pw@foo.com:443/blah
-
-`path` will include the leading slash. `query` won't include the leading `?`.
-`host` can contain embedded colons if surrounded by square brackets in order
-to support IPv6 literal addresses.
-
-
-Returns 0 on success, -1 on error. 
-
diff --git a/docs/c-api/util.h/intro.md b/docs/c-api/util.h/intro.md
deleted file mode 100644
index 73c4f7922..000000000
--- a/docs/c-api/util.h/intro.md
+++ /dev/null
@@ -1,29 +0,0 @@
----
-title: "Utility API"
-symbol_kind: "intro"
-decl_name: "util.h"
-items:
-  - { name: mg_base64_decode.md }
-  - { name: mg_base64_encode.md }
-  - { name: mg_basic_auth_header.md }
-  - { name: mg_conn_addr_to_str.md }
-  - { name: mg_fopen.md }
-  - { name: mg_fread.md }
-  - { name: mg_fwrite.md }
-  - { name: mg_hexdump.md }
-  - { name: mg_hexdump_connection.md }
-  - { name: mg_hexdumpf.md }
-  - { name: mg_is_big_endian.md }
-  - { name: mg_mbuf_append_base64.md }
-  - { name: mg_mbuf_append_base64_putc.md }
-  - { name: mg_open.md }
-  - { name: mg_skip.md }
-  - { name: mg_sock_addr_to_str.md }
-  - { name: mg_sock_to_str.md }
-  - { name: mg_start_thread.md }
-  - { name: mg_stat.md }
-  - { name: mg_url_encode.md }
----
-
-
-
diff --git a/docs/c-api/util.h/mg_base64_decode.md b/docs/c-api/util.h/mg_base64_decode.md
deleted file mode 100644
index 92f7c10bf..000000000
--- a/docs/c-api/util.h/mg_base64_decode.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_base64_decode()"
-decl_name: "mg_base64_decode"
-symbol_kind: "func"
-signature: |
-  int mg_base64_decode(const unsigned char *s, int len, char *dst);
----
-
-Decodes base64-encoded string `s`, `len` into the destination `dst`.
-The destination has to have enough space to hold the decoded buffer.
-Decoding stops either when all strings have been decoded or invalid an
-character appeared.
-Destination is '\0'-terminated.
-Returns the number of decoded characters. On success, that should be equal
-to `len`. On error (invalid character) the return value is smaller then
-`len`. 
-
diff --git a/docs/c-api/util.h/mg_base64_encode.md b/docs/c-api/util.h/mg_base64_encode.md
deleted file mode 100644
index c3b5c05e2..000000000
--- a/docs/c-api/util.h/mg_base64_encode.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_base64_encode()"
-decl_name: "mg_base64_encode"
-symbol_kind: "func"
-signature: |
-  void mg_base64_encode(const unsigned char *src, int src_len, char *dst);
----
-
-Base64-encode chunk of memory `src`, `src_len` into the destination `dst`.
-Destination has to have enough space to hold encoded buffer.
-Destination is '\0'-terminated. 
-
diff --git a/docs/c-api/util.h/mg_basic_auth_header.md b/docs/c-api/util.h/mg_basic_auth_header.md
deleted file mode 100644
index 724ec0539..000000000
--- a/docs/c-api/util.h/mg_basic_auth_header.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_basic_auth_header()"
-decl_name: "mg_basic_auth_header"
-symbol_kind: "func"
-signature: |
-  void mg_basic_auth_header(const struct mg_str user, const struct mg_str pass,
-                            struct mbuf *buf);
----
-
-Generate a Basic Auth header and appends it to buf.
-If pass is NULL, then user is expected to contain the credentials pair
-already encoded as `user:pass`. 
-
diff --git a/docs/c-api/util.h/mg_conn_addr_to_str.md b/docs/c-api/util.h/mg_conn_addr_to_str.md
deleted file mode 100644
index b7603fb29..000000000
--- a/docs/c-api/util.h/mg_conn_addr_to_str.md
+++ /dev/null
@@ -1,22 +0,0 @@
----
-title: "mg_conn_addr_to_str()"
-decl_name: "mg_conn_addr_to_str"
-symbol_kind: "func"
-signature: |
-  int mg_conn_addr_to_str(struct mg_connection *c, char *buf, size_t len,
-                          int flags);
----
-
-Converts a connection's local or remote address into string.
-
-The `flags` parameter is a bit mask that controls the behaviour,
-see `MG_SOCK_STRINGIFY_*` definitions.
-
-- MG_SOCK_STRINGIFY_IP - print IP address
-- MG_SOCK_STRINGIFY_PORT - print port number
-- MG_SOCK_STRINGIFY_REMOTE - print remote peer's IP/port, not local address
-
-If both port number and IP address are printed, they are separated by `:`.
-If compiled with `-DMG_ENABLE_IPV6`, IPv6 addresses are supported.
-Return length of the stringified address. 
-
diff --git a/docs/c-api/util.h/mg_fopen.md b/docs/c-api/util.h/mg_fopen.md
deleted file mode 100644
index 3cb8568a0..000000000
--- a/docs/c-api/util.h/mg_fopen.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_fopen()"
-decl_name: "mg_fopen"
-symbol_kind: "func"
-signature: |
-  FILE *mg_fopen(const char *path, const char *mode);
----
-
-Opens the given file and returns a file stream.
-
-`path` and `mode` should be UTF8 encoded.
-
-Return value is the same as for the `fopen()` call. 
-
diff --git a/docs/c-api/util.h/mg_fread.md b/docs/c-api/util.h/mg_fread.md
deleted file mode 100644
index 0ff4994ad..000000000
--- a/docs/c-api/util.h/mg_fread.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_fread()"
-decl_name: "mg_fread"
-symbol_kind: "func"
-signature: |
-  size_t mg_fread(void *ptr, size_t size, size_t count, FILE *f);
----
-
-Reads data from the given file stream.
-
-Return value is a number of bytes readen. 
-
diff --git a/docs/c-api/util.h/mg_fwrite.md b/docs/c-api/util.h/mg_fwrite.md
deleted file mode 100644
index 5ddbbbcea..000000000
--- a/docs/c-api/util.h/mg_fwrite.md
+++ /dev/null
@@ -1,12 +0,0 @@
----
-title: "mg_fwrite()"
-decl_name: "mg_fwrite"
-symbol_kind: "func"
-signature: |
-  size_t mg_fwrite(const void *ptr, size_t size, size_t count, FILE *f);
----
-
-Writes data to the given file stream.
-
-Return value is a number of bytes wtitten. 
-
diff --git a/docs/c-api/util.h/mg_hexdump.md b/docs/c-api/util.h/mg_hexdump.md
deleted file mode 100644
index c8376bf62..000000000
--- a/docs/c-api/util.h/mg_hexdump.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_hexdump()"
-decl_name: "mg_hexdump"
-symbol_kind: "func"
-signature: |
-  int mg_hexdump(const void *buf, int len, char *dst, int dst_len);
----
-
-Generates a human-readable hexdump of memory chunk.
-
-Takes a memory buffer `buf` of length `len` and creates a hex dump of that
-buffer in `dst`. The generated output is a-la hexdump(1).
-Returns the length of generated string, excluding terminating `\0`. If
-returned length is bigger than `dst_len`, the overflow bytes are discarded. 
-
diff --git a/docs/c-api/util.h/mg_hexdump_connection.md b/docs/c-api/util.h/mg_hexdump_connection.md
deleted file mode 100644
index 03d8a6b2d..000000000
--- a/docs/c-api/util.h/mg_hexdump_connection.md
+++ /dev/null
@@ -1,15 +0,0 @@
----
-title: "mg_hexdump_connection()"
-decl_name: "mg_hexdump_connection"
-symbol_kind: "func"
-signature: |
-  void mg_hexdump_connection(struct mg_connection *nc, const char *path,
-                             const void *buf, int num_bytes, int ev);
----
-
-Generates human-readable hexdump of the data sent or received by the
-connection. `path` is a file name where hexdump should be written.
-`num_bytes` is a number of bytes sent/received. `ev` is one of the `MG_*`
-events sent to an event handler. This function is supposed to be called from
-the event handler. 
-
diff --git a/docs/c-api/util.h/mg_hexdumpf.md b/docs/c-api/util.h/mg_hexdumpf.md
deleted file mode 100644
index dcb14ece7..000000000
--- a/docs/c-api/util.h/mg_hexdumpf.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_hexdumpf()"
-decl_name: "mg_hexdumpf"
-symbol_kind: "func"
-signature: |
-  void mg_hexdumpf(FILE *fp, const void *buf, int len);
----
-
-Same as mg_hexdump, but with output going to file instead of a buffer. 
-
diff --git a/docs/c-api/util.h/mg_is_big_endian.md b/docs/c-api/util.h/mg_is_big_endian.md
deleted file mode 100644
index 4cd54da7e..000000000
--- a/docs/c-api/util.h/mg_is_big_endian.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_is_big_endian()"
-decl_name: "mg_is_big_endian"
-symbol_kind: "func"
-signature: |
-  int mg_is_big_endian(void);
----
-
-Returns true if target platform is big endian. 
-
diff --git a/docs/c-api/util.h/mg_mbuf_append_base64.md b/docs/c-api/util.h/mg_mbuf_append_base64.md
deleted file mode 100644
index d0617fcf2..000000000
--- a/docs/c-api/util.h/mg_mbuf_append_base64.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mbuf_append_base64()"
-decl_name: "mg_mbuf_append_base64"
-symbol_kind: "func"
-signature: |
-  void mg_mbuf_append_base64(struct mbuf *mbuf, const void *data, size_t len);
----
-
-Encode `len` bytes starting at `data` as base64 and append them to an mbuf. 
-
diff --git a/docs/c-api/util.h/mg_mbuf_append_base64_putc.md b/docs/c-api/util.h/mg_mbuf_append_base64_putc.md
deleted file mode 100644
index a4d2b4285..000000000
--- a/docs/c-api/util.h/mg_mbuf_append_base64_putc.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_mbuf_append_base64_putc()"
-decl_name: "mg_mbuf_append_base64_putc"
-symbol_kind: "func"
-signature: |
-  void mg_mbuf_append_base64_putc(char ch, void *user_data);
----
-
-Use with cs_base64_init/update/finish in order to write out base64 in chunks. 
-
diff --git a/docs/c-api/util.h/mg_open.md b/docs/c-api/util.h/mg_open.md
deleted file mode 100644
index aaa8e56ea..000000000
--- a/docs/c-api/util.h/mg_open.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_open()"
-decl_name: "mg_open"
-symbol_kind: "func"
-signature: |
-  int mg_open(const char *path, int flag, int mode);
----
-
-Opens the given file and returns a file stream.
-
-`path` should be UTF8 encoded.
-
-Return value is the same as for the `open()` syscall. 
-
diff --git a/docs/c-api/util.h/mg_skip.md b/docs/c-api/util.h/mg_skip.md
deleted file mode 100644
index cc7b2fd14..000000000
--- a/docs/c-api/util.h/mg_skip.md
+++ /dev/null
@@ -1,17 +0,0 @@
----
-title: "mg_skip()"
-decl_name: "mg_skip"
-symbol_kind: "func"
-signature: |
-  const char *mg_skip(const char *s, const char *end_string,
-                      const char *delimiters, struct mg_str *v);
----
-
-Fetches substring from input string `s`, `end` into `v`.
-Skips initial delimiter characters. Records first non-delimiter character
-at the beginning of substring `v`. Then scans the rest of the string
-until a delimiter character or end-of-string is found.
-`delimiters` is a 0-terminated string containing delimiter characters.
-Either one of `delimiters` or `end_string` terminates the search.
-Returns an `s` pointer, advanced forward where parsing has stopped. 
-
diff --git a/docs/c-api/util.h/mg_sock_addr_to_str.md b/docs/c-api/util.h/mg_sock_addr_to_str.md
deleted file mode 100644
index b5cb6fddd..000000000
--- a/docs/c-api/util.h/mg_sock_addr_to_str.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_sock_addr_to_str()"
-decl_name: "mg_sock_addr_to_str"
-symbol_kind: "func"
-signature: |
-  int mg_sock_addr_to_str(const union socket_address *sa, char *buf, size_t len,
-                          int flags);
----
-
-Convert the socket's address into string.
-
-`flags` is MG_SOCK_STRINGIFY_IP and/or MG_SOCK_STRINGIFY_PORT. 
-
diff --git a/docs/c-api/util.h/mg_sock_to_str.md b/docs/c-api/util.h/mg_sock_to_str.md
deleted file mode 100644
index fb233b560..000000000
--- a/docs/c-api/util.h/mg_sock_to_str.md
+++ /dev/null
@@ -1,10 +0,0 @@
----
-title: "mg_sock_to_str()"
-decl_name: "mg_sock_to_str"
-symbol_kind: "func"
-signature: |
-  void mg_sock_to_str(sock_t sock, char *buf, size_t len, int flags);
----
-
-Legacy interface. 
-
diff --git a/docs/c-api/util.h/mg_start_thread.md b/docs/c-api/util.h/mg_start_thread.md
deleted file mode 100644
index 4a3c809f9..000000000
--- a/docs/c-api/util.h/mg_start_thread.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_start_thread()"
-decl_name: "mg_start_thread"
-symbol_kind: "func"
-signature: |
-  void *mg_start_thread(void *(*thread_func);
----
-
-Starts a new detached thread.
-Arguments and semantics are the same as pthead's `pthread_create()`.
-`thread_func` is a thread function, `thread_func_param` is a parameter
-that is passed to the thread function. 
-
diff --git a/docs/c-api/util.h/mg_stat.md b/docs/c-api/util.h/mg_stat.md
deleted file mode 100644
index 5bd3b0eb4..000000000
--- a/docs/c-api/util.h/mg_stat.md
+++ /dev/null
@@ -1,14 +0,0 @@
----
-title: "mg_stat()"
-decl_name: "mg_stat"
-symbol_kind: "func"
-signature: |
-  int mg_stat(const char *path, cs_stat_t *st);
----
-
-Performs a 64-bit `stat()` call against a given file.
-
-`path` should be UTF8 encoded.
-
-Return value is the same as for `stat()` syscall. 
-
diff --git a/docs/c-api/util.h/mg_url_encode.md b/docs/c-api/util.h/mg_url_encode.md
deleted file mode 100644
index 105ce9473..000000000
--- a/docs/c-api/util.h/mg_url_encode.md
+++ /dev/null
@@ -1,13 +0,0 @@
----
-title: "mg_url_encode()"
-decl_name: "mg_url_encode"
-symbol_kind: "func"
-signature: |
-  struct mg_str mg_url_encode(const struct mg_str src);
----
-
-URL-escape the specified string.
-All non-printable characters are escaped, plus `._-$,;~()/`.
-Input need not be NUL-terminated, but the returned string is.
-Returned string is heap-allocated and must be free()'d. 
-
diff --git a/mongoose.c b/mongoose.c
index 5dbb9b3f7..247f5ba8d 100644
--- a/mongoose.c
+++ b/mongoose.c
@@ -1,6 +1,6 @@
 #include "mongoose.h"
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/internal.h"
+#line 1 "mongoose/src/mg_internal.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -35,8 +35,8 @@
 #endif
 
 /* Amalgamated: #include "common/cs_dbg.h" */
-/* Amalgamated: #include "mongoose/src/http.h" */
-/* Amalgamated: #include "mongoose/src/net.h" */
+/* Amalgamated: #include "mongoose/src/mg_http.h" */
+/* Amalgamated: #include "mongoose/src/mg_net.h" */
 
 #define MG_CTL_MSG_MESSAGE_SIZE 8192
 
@@ -2146,7 +2146,7 @@ size_t mg_match_prefix(const char *pattern, int pattern_len, const char *str) {
 
 #endif /* EXCLUDE_COMMON */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net.c"
+#line 1 "mongoose/src/mg_net.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -2167,10 +2167,10 @@ size_t mg_match_prefix(const char *pattern, int pattern_len, const char *str) {
  */
 
 /* Amalgamated: #include "common/cs_time.h" */
-/* Amalgamated: #include "mongoose/src/dns.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/resolv.h" */
-/* Amalgamated: #include "mongoose/src/util.h" */
+/* Amalgamated: #include "mongoose/src/mg_dns.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_resolv.h" */
+/* Amalgamated: #include "mongoose/src/mg_util.h" */
 
 #define MG_MAX_HOST_LEN 200
 
@@ -3157,7 +3157,7 @@ double mg_time(void) {
   return cs_time();
 }
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if_socket.h"
+#line 1 "mongoose/src/mg_net_if_socket.h"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -3167,7 +3167,7 @@ double mg_time(void) {
 #ifndef CS_MONGOOSE_SRC_NET_IF_SOCKET_H_
 #define CS_MONGOOSE_SRC_NET_IF_SOCKET_H_
 
-/* Amalgamated: #include "mongoose/src/net_if.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -3185,7 +3185,7 @@ extern const struct mg_iface_vtable mg_socket_iface_vtable;
 
 #endif /* CS_MONGOOSE_SRC_NET_IF_SOCKET_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if_socks.h"
+#line 1 "mongoose/src/mg_net_if_socks.h"
 #endif
 /*
 * Copyright (c) 2014-2017 Cesanta Software Limited
@@ -3196,7 +3196,7 @@ extern const struct mg_iface_vtable mg_socket_iface_vtable;
 #define CS_MONGOOSE_SRC_NET_IF_SOCKS_H_
 
 #if MG_ENABLE_SOCKS
-/* Amalgamated: #include "mongoose/src/net_if.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -3210,11 +3210,11 @@ extern const struct mg_iface_vtable mg_socks_iface_vtable;
 #endif /* MG_ENABLE_SOCKS */
 #endif /* CS_MONGOOSE_SRC_NET_IF_SOCKS_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if.c"
+#line 1 "mongoose/src/mg_net_if.c"
 #endif
-/* Amalgamated: #include "mongoose/src/net_if.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/net_if_socket.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if_socket.h" */
 
 extern const struct mg_iface_vtable mg_default_iface_vtable;
 
@@ -3254,7 +3254,7 @@ struct mg_iface *mg_find_iface(struct mg_mgr *mgr,
   return NULL;
 }
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if_socket.c"
+#line 1 "mongoose/src/mg_net_if_socket.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -3263,9 +3263,9 @@ struct mg_iface *mg_find_iface(struct mg_mgr *mgr,
 
 #if MG_ENABLE_NET_IF_SOCKET
 
-/* Amalgamated: #include "mongoose/src/net_if_socket.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/util.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if_socket.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_util.h" */
 
 #define MG_TCP_RECV_BUFFER_SIZE 1024
 #define MG_UDP_RECV_BUFFER_SIZE 1500
@@ -4006,7 +4006,7 @@ const struct mg_iface_vtable mg_default_iface_vtable = MG_SOCKET_IFACE_VTABLE;
 
 #endif /* MG_ENABLE_NET_IF_SOCKET */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if_socks.c"
+#line 1 "mongoose/src/mg_net_if_socks.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -4218,7 +4218,7 @@ struct mg_iface *mg_socks_mk_iface(struct mg_mgr *mgr, const char *proxy_addr) {
 
 #endif
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/ssl_if_openssl.c"
+#line 1 "mongoose/src/mg_ssl_if_openssl.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -4615,7 +4615,7 @@ const char *mg_set_ssl(struct mg_connection *nc, const char *cert,
 
 #endif /* MG_ENABLE_SSL && MG_SSL_IF == MG_SSL_IF_OPENSSL */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/ssl_if_mbedtls.c"
+#line 1 "mongoose/src/mg_ssl_if_mbedtls.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -5096,15 +5096,15 @@ int mg_ssl_if_mbed_random(void *ctx, unsigned char *buf, size_t len) {
 
 #endif /* MG_ENABLE_SSL && MG_SSL_IF == MG_SSL_IF_MBEDTLS */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/uri.c"
+#line 1 "mongoose/src/mg_uri.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
  * All rights reserved
  */
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/uri.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_uri.h" */
 
 /*
  * scan string until encountering one of `seps`, keeping track of component
@@ -5360,7 +5360,7 @@ out:
   return result;
 }
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http.c"
+#line 1 "mongoose/src/mg_http.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5370,8 +5370,8 @@ out:
 #if MG_ENABLE_HTTP
 
 /* Amalgamated: #include "common/md5.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/util.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_util.h" */
 
 static const char *mg_version_header = "Mongoose/" MG_VERSION;
 
@@ -8274,7 +8274,7 @@ void mg_register_http_endpoint(struct mg_connection *nc, const char *uri_path,
 
 #endif /* MG_ENABLE_HTTP */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_cgi.c"
+#line 1 "mongoose/src/mg_http_cgi.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -8791,7 +8791,7 @@ MG_INTERNAL void mg_http_free_proto_data_cgi(struct mg_http_proto_data_cgi *d) {
 
 #endif /* MG_ENABLE_HTTP && MG_ENABLE_HTTP_CGI */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_ssi.c"
+#line 1 "mongoose/src/mg_http_ssi.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -8987,7 +8987,7 @@ MG_INTERNAL void mg_handle_ssi_request(struct mg_connection *nc,
 
 #endif /* MG_ENABLE_HTTP_SSI && MG_ENABLE_HTTP && MG_ENABLE_FILESYSTEM */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_webdav.c"
+#line 1 "mongoose/src/mg_http_webdav.c"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -9259,7 +9259,7 @@ MG_INTERNAL void mg_handle_put(struct mg_connection *nc, const char *path,
 
 #endif /* MG_ENABLE_HTTP && MG_ENABLE_HTTP_WEBDAV */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_websocket.c"
+#line 1 "mongoose/src/mg_http_websocket.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -9779,7 +9779,7 @@ struct mg_connection *mg_connect_ws(
 }
 #endif /* MG_ENABLE_HTTP && MG_ENABLE_HTTP_WEBSOCKET */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/util.c"
+#line 1 "mongoose/src/mg_util.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -9787,8 +9787,8 @@ struct mg_connection *mg_connect_ws(
  */
 
 /* Amalgamated: #include "common/cs_base64.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/util.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_util.h" */
 
 /* For platforms with limited libc */
 #ifndef MAX
@@ -10118,7 +10118,7 @@ struct mg_str mg_url_encode(const struct mg_str src) {
   return mg_mk_str_n(mb.buf, mb.len - 1);
 }
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/mqtt.c"
+#line 1 "mongoose/src/mg_mqtt.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -10129,8 +10129,8 @@ struct mg_str mg_url_encode(const struct mg_str src) {
 
 #include <string.h>
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/mqtt.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_mqtt.h" */
 
 static uint16_t getu16(const char *p) {
   const uint8_t *up = (const uint8_t *) p;
@@ -10587,15 +10587,15 @@ void mg_mqtt_disconnect(struct mg_connection *nc) {
 
 #endif /* MG_ENABLE_MQTT */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/mqtt_server.c"
+#line 1 "mongoose/src/mg_mqtt_server.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
  * All rights reserved
  */
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/mqtt-server.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_mqtt_server.h" */
 
 #if MG_ENABLE_MQTT_BROKER
 
@@ -10784,7 +10784,7 @@ struct mg_mqtt_session *mg_mqtt_next(struct mg_mqtt_broker *brk,
 
 #endif /* MG_ENABLE_MQTT_BROKER */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/dns.c"
+#line 1 "mongoose/src/mg_dns.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -10793,8 +10793,8 @@ struct mg_mqtt_session *mg_mqtt_next(struct mg_mqtt_broker *brk,
 
 #if MG_ENABLE_DNS
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/dns.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_dns.h" */
 
 static int mg_dns_tid = 0xa0;
 
@@ -11164,7 +11164,7 @@ void mg_set_protocol_dns(struct mg_connection *nc) {
 
 #endif /* MG_ENABLE_DNS */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/dns_server.c"
+#line 1 "mongoose/src/mg_dns_server.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -11173,7 +11173,7 @@ void mg_set_protocol_dns(struct mg_connection *nc) {
 
 #if MG_ENABLE_DNS_SERVER
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
 /* Amalgamated: #include "mongoose/src/dns-server.h" */
 
 struct mg_dns_reply mg_dns_create_reply(struct mbuf *io,
@@ -11238,7 +11238,7 @@ int mg_dns_reply_record(struct mg_dns_reply *reply,
 
 #endif /* MG_ENABLE_DNS_SERVER */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/resolv.c"
+#line 1 "mongoose/src/mg_resolv.c"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -11247,8 +11247,8 @@ int mg_dns_reply_record(struct mg_dns_reply *reply,
 
 #if MG_ENABLE_ASYNC_RESOLVER
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/resolv.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_resolv.h" */
 
 #ifndef MG_DEFAULT_NAMESERVER
 #define MG_DEFAULT_NAMESERVER "8.8.8.8"
@@ -11533,7 +11533,7 @@ void mg_set_nameserver(struct mg_mgr *mgr, const char *nameserver) {
 
 #endif /* MG_ENABLE_ASYNC_RESOLVER */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/coap.c"
+#line 1 "mongoose/src/mg_coap.c"
 #endif
 /*
  * Copyright (c) 2015 Cesanta Software Limited
@@ -11552,8 +11552,8 @@ void mg_set_nameserver(struct mg_mgr *mgr, const char *nameserver) {
  * license, as set out in <https://www.cesanta.com/license>.
  */
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/coap.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_coap.h" */
 
 #if MG_ENABLE_COAP
 
@@ -12133,16 +12133,16 @@ int mg_set_protocol_coap(struct mg_connection *nc) {
 
 #endif /* MG_ENABLE_COAP */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/sntp.c"
+#line 1 "mongoose/src/mg_sntp.c"
 #endif
 /*
  * Copyright (c) 2016 Cesanta Software Limited
  * All rights reserved
  */
 
-/* Amalgamated: #include "mongoose/src/internal.h" */
-/* Amalgamated: #include "mongoose/src/sntp.h" */
-/* Amalgamated: #include "mongoose/src/util.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_sntp.h" */
+/* Amalgamated: #include "mongoose/src/mg_util.h" */
 
 #if MG_ENABLE_SNTP
 
@@ -12424,7 +12424,7 @@ struct mg_connection *mg_sntp_get_time(struct mg_mgr *mgr,
 
 #endif /* MG_ENABLE_SNTP */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/socks.c"
+#line 1 "mongoose/src/mg_socks.c"
 #endif
 /*
  * Copyright (c) 2017 Cesanta Software Limited
@@ -12433,8 +12433,8 @@ struct mg_connection *mg_sntp_get_time(struct mg_mgr *mgr,
 
 #if MG_ENABLE_SOCKS
 
-/* Amalgamated: #include "mongoose/src/socks.h" */
-/* Amalgamated: #include "mongoose/src/internal.h" */
+/* Amalgamated: #include "mongoose/src/mg_socks.h" */
+/* Amalgamated: #include "mongoose/src/mg_internal.h" */
 
 /*
  *  https://www.ietf.org/rfc/rfc1928.txt paragraph 3, handle client handshake
diff --git a/mongoose.h b/mongoose.h
index 64676ba43..48c9db501 100644
--- a/mongoose.h
+++ b/mongoose.h
@@ -1,5 +1,5 @@
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/common.h"
+#line 1 "mongoose/src/mg_common.h"
 #endif
 /*
  * Copyright (c) 2004-2013 Sergey Lyubka
@@ -3000,7 +3000,7 @@ struct {								\
 
 #endif /* !_SYS_QUEUE_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/features.h"
+#line 1 "mongoose/src/mg_features.h"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -3179,7 +3179,7 @@ struct {								\
 
 #endif /* CS_MONGOOSE_SRC_FEATURES_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net_if.h"
+#line 1 "mongoose/src/mg_net_if.h"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -3312,7 +3312,7 @@ void mg_if_timer(struct mg_connection *c, double now);
 
 #endif /* CS_MONGOOSE_SRC_NET_IF_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/ssl_if.h"
+#line 1 "mongoose/src/mg_ssl_if.h"
 #endif
 /*
  * Copyright (c) 2014-2016 Cesanta Software Limited
@@ -3370,7 +3370,7 @@ int mg_ssl_if_write(struct mg_connection *nc, const void *data, size_t len);
 
 #endif /* CS_MONGOOSE_SRC_SSL_IF_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/net.h"
+#line 1 "mongoose/src/mg_net.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -3402,8 +3402,8 @@ int mg_ssl_if_write(struct mg_connection *nc, const void *data, size_t len);
 #ifndef CS_MONGOOSE_SRC_NET_H_
 #define CS_MONGOOSE_SRC_NET_H_
 
-/* Amalgamated: #include "mongoose/src/common.h" */
-/* Amalgamated: #include "mongoose/src/net_if.h" */
+/* Amalgamated: #include "mongoose/src/mg_common.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if.h" */
 /* Amalgamated: #include "common/mbuf.h" */
 
 #ifndef MG_VPRINTF_BUFFER_SIZE
@@ -3964,7 +3964,7 @@ double mg_time(void);
 
 #endif /* CS_MONGOOSE_SRC_NET_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/uri.h"
+#line 1 "mongoose/src/mg_uri.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -3978,7 +3978,7 @@ double mg_time(void);
 #ifndef CS_MONGOOSE_SRC_URI_H_
 #define CS_MONGOOSE_SRC_URI_H_
 
-/* Amalgamated: #include "mongoose/src/net.h" */
+/* Amalgamated: #include "mongoose/src/mg_net.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -4034,7 +4034,7 @@ int mg_normalize_uri_path(const struct mg_str *in, struct mg_str *out);
 #endif /* __cplusplus */
 #endif /* CS_MONGOOSE_SRC_URI_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/util.h"
+#line 1 "mongoose/src/mg_util.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -4050,8 +4050,8 @@ int mg_normalize_uri_path(const struct mg_str *in, struct mg_str *out);
 
 #include <stdio.h>
 
-/* Amalgamated: #include "mongoose/src/common.h" */
-/* Amalgamated: #include "mongoose/src/net_if.h" */
+/* Amalgamated: #include "mongoose/src/mg_common.h" */
+/* Amalgamated: #include "mongoose/src/mg_net_if.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -4245,7 +4245,7 @@ struct mg_str mg_url_encode(const struct mg_str src);
 #endif /* __cplusplus */
 #endif /* CS_MONGOOSE_SRC_UTIL_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http.h"
+#line 1 "mongoose/src/mg_http.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -4261,7 +4261,7 @@ struct mg_str mg_url_encode(const struct mg_str src);
 
 #if MG_ENABLE_HTTP
 
-/* Amalgamated: #include "mongoose/src/net.h" */
+/* Amalgamated: #include "mongoose/src/mg_net.h" */
 /* Amalgamated: #include "common/mg_str.h" */
 
 #ifdef __cplusplus
@@ -4612,7 +4612,7 @@ void mg_http_send_digest_auth_request(struct mg_connection *c,
 
 #endif /* CS_MONGOOSE_SRC_HTTP_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_server.h"
+#line 1 "mongoose/src/mg_http_server.h"
 #endif
 /*
  * === Server API reference
@@ -5155,7 +5155,7 @@ void mg_http_reverse_proxy(struct mg_connection *nc,
 
 #endif /* CS_MONGOOSE_SRC_HTTP_SERVER_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/http_client.h"
+#line 1 "mongoose/src/mg_http_client.h"
 #endif
 /*
  * === Client API reference
@@ -5220,7 +5220,7 @@ int mg_http_create_digest_auth_header(char *buf, size_t buf_len,
 #endif /* __cplusplus */
 #endif /* CS_MONGOOSE_SRC_HTTP_CLIENT_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/mqtt.h"
+#line 1 "mongoose/src/mg_mqtt.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5246,7 +5246,7 @@ int mg_http_create_digest_auth_header(char *buf, size_t buf_len,
 #ifndef CS_MONGOOSE_SRC_MQTT_H_
 #define CS_MONGOOSE_SRC_MQTT_H_
 
-/* Amalgamated: #include "mongoose/src/net.h" */
+/* Amalgamated: #include "mongoose/src/mg_net.h" */
 
 struct mg_mqtt_message {
   int cmd;
@@ -5451,7 +5451,7 @@ int mg_mqtt_vmatch_topic_expression(const char *exp, struct mg_str topic);
 
 #endif /* CS_MONGOOSE_SRC_MQTT_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/mqtt_server.h"
+#line 1 "mongoose/src/mg_mqtt_server.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5480,7 +5480,7 @@ int mg_mqtt_vmatch_topic_expression(const char *exp, struct mg_str topic);
 #if MG_ENABLE_MQTT_BROKER
 
 /* Amalgamated: #include "common/queue.h" */
-/* Amalgamated: #include "mongoose/src/mqtt.h" */
+/* Amalgamated: #include "mongoose/src/mg_mqtt.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -5558,7 +5558,7 @@ struct mg_mqtt_session *mg_mqtt_next(struct mg_mqtt_broker *brk,
 #endif /* MG_ENABLE_MQTT_BROKER */
 #endif /* CS_MONGOOSE_SRC_MQTT_BROKER_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/dns.h"
+#line 1 "mongoose/src/mg_dns.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5572,7 +5572,7 @@ struct mg_mqtt_session *mg_mqtt_next(struct mg_mqtt_broker *brk,
 #ifndef CS_MONGOOSE_SRC_DNS_H_
 #define CS_MONGOOSE_SRC_DNS_H_
 
-/* Amalgamated: #include "mongoose/src/net.h" */
+/* Amalgamated: #include "mongoose/src/mg_net.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -5725,7 +5725,7 @@ void mg_set_protocol_dns(struct mg_connection *nc);
 #endif /* __cplusplus */
 #endif /* CS_MONGOOSE_SRC_DNS_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/dns_server.h"
+#line 1 "mongoose/src/mg_dns_server.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5743,7 +5743,7 @@ void mg_set_protocol_dns(struct mg_connection *nc);
 
 #if MG_ENABLE_DNS_SERVER
 
-/* Amalgamated: #include "mongoose/src/dns.h" */
+/* Amalgamated: #include "mongoose/src/mg_dns.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -5822,7 +5822,7 @@ void mg_dns_send_reply(struct mg_connection *nc, struct mg_dns_reply *r);
 #endif /* MG_ENABLE_DNS_SERVER */
 #endif /* CS_MONGOOSE_SRC_DNS_SERVER_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/resolv.h"
+#line 1 "mongoose/src/mg_resolv.h"
 #endif
 /*
  * Copyright (c) 2014 Cesanta Software Limited
@@ -5836,7 +5836,7 @@ void mg_dns_send_reply(struct mg_connection *nc, struct mg_dns_reply *r);
 #ifndef CS_MONGOOSE_SRC_RESOLV_H_
 #define CS_MONGOOSE_SRC_RESOLV_H_
 
-/* Amalgamated: #include "mongoose/src/dns.h" */
+/* Amalgamated: #include "mongoose/src/mg_dns.h" */
 
 #ifdef __cplusplus
 extern "C" {
@@ -5906,7 +5906,7 @@ int mg_resolve_from_hosts_file(const char *host, union socket_address *usa);
 #endif /* __cplusplus */
 #endif /* CS_MONGOOSE_SRC_RESOLV_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/coap.h"
+#line 1 "mongoose/src/mg_coap.h"
 #endif
 /*
  * Copyright (c) 2015 Cesanta Software Limited
@@ -6074,7 +6074,7 @@ uint32_t mg_coap_compose(struct mg_coap_message *cm, struct mbuf *io);
 
 #endif /* CS_MONGOOSE_SRC_COAP_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/sntp.h"
+#line 1 "mongoose/src/mg_sntp.h"
 #endif
 /*
  * Copyright (c) 2016 Cesanta Software Limited
@@ -6131,7 +6131,7 @@ struct mg_connection *mg_sntp_get_time(struct mg_mgr *mgr,
 
 #endif /* CS_MONGOOSE_SRC_SNTP_H_ */
 #ifdef MG_MODULE_LINES
-#line 1 "mongoose/src/socks.h"
+#line 1 "mongoose/src/mg_socks.h"
 #endif
 /*
  * Copyright (c) 2017 Cesanta Software Limited
diff --git a/src/coap.c b/src/mg_coap.c
similarity index 99%
rename from src/coap.c
rename to src/mg_coap.c
index e7d85c3a7..15f97ecb1 100644
--- a/src/coap.c
+++ b/src/mg_coap.c
@@ -15,8 +15,8 @@
  * license, as set out in <https://www.cesanta.com/license>.
  */
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/coap.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_coap.h"
 
 #if MG_ENABLE_COAP
 
diff --git a/src/coap.h b/src/mg_coap.h
similarity index 100%
rename from src/coap.h
rename to src/mg_coap.h
diff --git a/src/common.h b/src/mg_common.h
similarity index 100%
rename from src/common.h
rename to src/mg_common.h
diff --git a/src/dns.c b/src/mg_dns.c
similarity index 99%
rename from src/dns.c
rename to src/mg_dns.c
index 93752ebc6..13bd1bdff 100644
--- a/src/dns.c
+++ b/src/mg_dns.c
@@ -5,8 +5,8 @@
 
 #if MG_ENABLE_DNS
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/dns.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_dns.h"
 
 static int mg_dns_tid = 0xa0;
 
diff --git a/src/dns.h b/src/mg_dns.h
similarity index 99%
rename from src/dns.h
rename to src/mg_dns.h
index 02182e4a4..5536b671e 100644
--- a/src/dns.h
+++ b/src/mg_dns.h
@@ -10,7 +10,7 @@
 #ifndef CS_MONGOOSE_SRC_DNS_H_
 #define CS_MONGOOSE_SRC_DNS_H_
 
-#include "mongoose/src/net.h"
+#include "mongoose/src/mg_net.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/dns_server.c b/src/mg_dns_server.c
similarity index 97%
rename from src/dns_server.c
rename to src/mg_dns_server.c
index 4e20bdfb5..56568dfb3 100644
--- a/src/dns_server.c
+++ b/src/mg_dns_server.c
@@ -5,7 +5,7 @@
 
 #if MG_ENABLE_DNS_SERVER
 
-#include "mongoose/src/internal.h"
+#include "mongoose/src/mg_internal.h"
 #include "mongoose/src/dns-server.h"
 
 struct mg_dns_reply mg_dns_create_reply(struct mbuf *io,
diff --git a/src/dns_server.h b/src/mg_dns_server.h
similarity index 98%
rename from src/dns_server.h
rename to src/mg_dns_server.h
index cc2d18d83..33bcbdec1 100644
--- a/src/dns_server.h
+++ b/src/mg_dns_server.h
@@ -14,7 +14,7 @@
 
 #if MG_ENABLE_DNS_SERVER
 
-#include "mongoose/src/dns.h"
+#include "mongoose/src/mg_dns.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/features.h b/src/mg_features.h
similarity index 100%
rename from src/features.h
rename to src/mg_features.h
diff --git a/src/http.c b/src/mg_http.c
similarity index 99%
rename from src/http.c
rename to src/mg_http.c
index 26467d6d5..b6fba11d1 100644
--- a/src/http.c
+++ b/src/mg_http.c
@@ -6,8 +6,8 @@
 #if MG_ENABLE_HTTP
 
 #include "common/md5.h"
-#include "mongoose/src/internal.h"
-#include "mongoose/src/util.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_util.h"
 
 static const char *mg_version_header = "Mongoose/" MG_VERSION;
 
diff --git a/src/http.h b/src/mg_http.h
similarity index 99%
rename from src/http.h
rename to src/mg_http.h
index 7c2c7e994..30a14564d 100644
--- a/src/http.h
+++ b/src/mg_http.h
@@ -12,7 +12,7 @@
 
 #if MG_ENABLE_HTTP
 
-#include "mongoose/src/net.h"
+#include "mongoose/src/mg_net.h"
 #include "common/mg_str.h"
 
 #ifdef __cplusplus
diff --git a/src/http_cgi.c b/src/mg_http_cgi.c
similarity index 100%
rename from src/http_cgi.c
rename to src/mg_http_cgi.c
diff --git a/src/http_client.h b/src/mg_http_client.h
similarity index 100%
rename from src/http_client.h
rename to src/mg_http_client.h
diff --git a/src/http_server.h b/src/mg_http_server.h
similarity index 100%
rename from src/http_server.h
rename to src/mg_http_server.h
diff --git a/src/http_ssi.c b/src/mg_http_ssi.c
similarity index 100%
rename from src/http_ssi.c
rename to src/mg_http_ssi.c
diff --git a/src/http_webdav.c b/src/mg_http_webdav.c
similarity index 100%
rename from src/http_webdav.c
rename to src/mg_http_webdav.c
diff --git a/src/http_websocket.c b/src/mg_http_websocket.c
similarity index 100%
rename from src/http_websocket.c
rename to src/mg_http_websocket.c
diff --git a/src/internal.h b/src/mg_internal.h
similarity index 98%
rename from src/internal.h
rename to src/mg_internal.h
index d7a2625c0..13d04ae32 100644
--- a/src/internal.h
+++ b/src/mg_internal.h
@@ -31,8 +31,8 @@
 #endif
 
 #include "common/cs_dbg.h"
-#include "mongoose/src/http.h"
-#include "mongoose/src/net.h"
+#include "mongoose/src/mg_http.h"
+#include "mongoose/src/mg_net.h"
 
 #define MG_CTL_MSG_MESSAGE_SIZE 8192
 
diff --git a/src/modules.mk b/src/mg_modules.mk
similarity index 72%
rename from src/modules.mk
rename to src/mg_modules.mk
index 93c3539d4..235e0d5ff 100644
--- a/src/modules.mk
+++ b/src/mg_modules.mk
@@ -1,6 +1,6 @@
 COMMON = ../../common
 
-HEADERS = common.h \
+HEADERS = mg_common.h \
           $(COMMON)/platform.h \
           $(COMMON)/platforms/platform_windows.h \
           $(COMMON)/platforms/platform_unix.h \
@@ -28,23 +28,23 @@ HEADERS = common.h \
           $(COMMON)/cs_base64.h \
           $(COMMON)/str_util.h \
           $(COMMON)/queue.h \
-          features.h \
-          net_if.h \
-          ssl_if.h \
-          net.h \
-          uri.h \
-          util.h \
-          http.h \
-          http_server.h \
-          http_client.h \
-          mqtt.h \
-          mqtt_server.h \
-          dns.h \
-          dns_server.h \
-          resolv.h \
-          coap.h \
-          sntp.h \
-          socks.h
+          mg_features.h \
+          mg_net_if.h \
+          mg_ssl_if.h \
+          mg_net.h \
+          mg_uri.h \
+          mg_util.h \
+          mg_http.h \
+          mg_http_server.h \
+          mg_http_client.h \
+          mg_mqtt.h \
+          mg_mqtt_server.h \
+          mg_dns.h \
+          mg_dns_server.h \
+          mg_resolv.h \
+          mg_coap.h \
+          mg_sntp.h \
+          mg_socks.h
 
 SOURCES = $(COMMON)/mg_mem.h \
           $(COMMON)/cs_base64.c \
@@ -59,29 +59,29 @@ SOURCES = $(COMMON)/mg_mem.h \
           $(COMMON)/mbuf.c \
           $(COMMON)/mg_str.c \
           $(COMMON)/str_util.c \
-          net.c \
-          net_if_socket.h \
-          net_if_socks.h \
-          net_if.c \
-          net_if_socket.c \
-          net_if_socks.c \
-          ssl_if_openssl.c \
-          ssl_if_mbedtls.c \
-          uri.c \
-          http.c \
-          http_cgi.c \
-          http_ssi.c \
-          http_webdav.c \
-          http_websocket.c \
-          util.c \
-          mqtt.c \
-          mqtt_server.c \
-          dns.c \
-          dns_server.c \
-          resolv.c \
-          coap.c \
-          sntp.c \
-          socks.c \
+          mg_net.c \
+          mg_net_if_socket.h \
+          mg_net_if_socks.h \
+          mg_net_if.c \
+          mg_net_if_socket.c \
+          mg_net_if_socks.c \
+          mg_ssl_if_openssl.c \
+          mg_ssl_if_mbedtls.c \
+          mg_uri.c \
+          mg_http.c \
+          mg_http_cgi.c \
+          mg_http_ssi.c \
+          mg_http_webdav.c \
+          mg_http_websocket.c \
+          mg_util.c \
+          mg_mqtt.c \
+          mg_mqtt_server.c \
+          mg_dns.c \
+          mg_dns_server.c \
+          mg_resolv.c \
+          mg_coap.c \
+          mg_sntp.c \
+          mg_socks.c \
           $(COMMON)/platforms/cc3200/cc3200_libc.c \
           $(COMMON)/platforms/msp432/msp432_libc.c \
           $(COMMON)/platforms/nrf5/nrf5_libc.c \
diff --git a/src/mqtt.c b/src/mg_mqtt.c
similarity index 99%
rename from src/mqtt.c
rename to src/mg_mqtt.c
index 216c00bf2..399f4a5c7 100644
--- a/src/mqtt.c
+++ b/src/mg_mqtt.c
@@ -7,8 +7,8 @@
 
 #include <string.h>
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/mqtt.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_mqtt.h"
 
 static uint16_t getu16(const char *p) {
   const uint8_t *up = (const uint8_t *) p;
diff --git a/src/mqtt.h b/src/mg_mqtt.h
similarity index 99%
rename from src/mqtt.h
rename to src/mg_mqtt.h
index af161f794..2328e4a99 100644
--- a/src/mqtt.h
+++ b/src/mg_mqtt.h
@@ -22,7 +22,7 @@
 #ifndef CS_MONGOOSE_SRC_MQTT_H_
 #define CS_MONGOOSE_SRC_MQTT_H_
 
-#include "mongoose/src/net.h"
+#include "mongoose/src/mg_net.h"
 
 struct mg_mqtt_message {
   int cmd;
diff --git a/src/mqtt_client.h b/src/mg_mqtt_client.h
similarity index 100%
rename from src/mqtt_client.h
rename to src/mg_mqtt_client.h
diff --git a/src/mqtt_server.c b/src/mg_mqtt_server.c
similarity index 98%
rename from src/mqtt_server.c
rename to src/mg_mqtt_server.c
index af96d6f95..4083f2822 100644
--- a/src/mqtt_server.c
+++ b/src/mg_mqtt_server.c
@@ -3,8 +3,8 @@
  * All rights reserved
  */
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/mqtt-server.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_mqtt_server.h"
 
 #if MG_ENABLE_MQTT_BROKER
 
diff --git a/src/mqtt_server.h b/src/mg_mqtt_server.h
similarity index 98%
rename from src/mqtt_server.h
rename to src/mg_mqtt_server.h
index db736e894..ebbcfef7e 100644
--- a/src/mqtt_server.h
+++ b/src/mg_mqtt_server.h
@@ -25,7 +25,7 @@
 #if MG_ENABLE_MQTT_BROKER
 
 #include "common/queue.h"
-#include "mongoose/src/mqtt.h"
+#include "mongoose/src/mg_mqtt.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/net.c b/src/mg_net.c
similarity index 99%
rename from src/net.c
rename to src/mg_net.c
index e7496b72f..a59786073 100644
--- a/src/net.c
+++ b/src/mg_net.c
@@ -17,10 +17,10 @@
  */
 
 #include "common/cs_time.h"
-#include "mongoose/src/dns.h"
-#include "mongoose/src/internal.h"
-#include "mongoose/src/resolv.h"
-#include "mongoose/src/util.h"
+#include "mongoose/src/mg_dns.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_resolv.h"
+#include "mongoose/src/mg_util.h"
 
 #define MG_MAX_HOST_LEN 200
 
diff --git a/src/net.h b/src/mg_net.h
similarity index 99%
rename from src/net.h
rename to src/mg_net.h
index 1ecb869c3..8b5b02e76 100644
--- a/src/net.h
+++ b/src/mg_net.h
@@ -28,8 +28,8 @@
 #ifndef CS_MONGOOSE_SRC_NET_H_
 #define CS_MONGOOSE_SRC_NET_H_
 
-#include "mongoose/src/common.h"
-#include "mongoose/src/net_if.h"
+#include "mongoose/src/mg_common.h"
+#include "mongoose/src/mg_net_if.h"
 #include "common/mbuf.h"
 
 #ifndef MG_VPRINTF_BUFFER_SIZE
diff --git a/src/net_if.c b/src/mg_net_if.c
similarity index 89%
rename from src/net_if.c
rename to src/mg_net_if.c
index fee459949..6a7864b2c 100644
--- a/src/net_if.c
+++ b/src/mg_net_if.c
@@ -1,6 +1,6 @@
-#include "mongoose/src/net_if.h"
-#include "mongoose/src/internal.h"
-#include "mongoose/src/net_if_socket.h"
+#include "mongoose/src/mg_net_if.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_net_if_socket.h"
 
 extern const struct mg_iface_vtable mg_default_iface_vtable;
 
diff --git a/src/net_if.h b/src/mg_net_if.h
similarity index 100%
rename from src/net_if.h
rename to src/mg_net_if.h
diff --git a/src/net_if_socket.c b/src/mg_net_if_socket.c
similarity index 99%
rename from src/net_if_socket.c
rename to src/mg_net_if_socket.c
index 2b7bda627..014761ea5 100644
--- a/src/net_if_socket.c
+++ b/src/mg_net_if_socket.c
@@ -5,9 +5,9 @@
 
 #if MG_ENABLE_NET_IF_SOCKET
 
-#include "mongoose/src/net_if_socket.h"
-#include "mongoose/src/internal.h"
-#include "mongoose/src/util.h"
+#include "mongoose/src/mg_net_if_socket.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_util.h"
 
 #define MG_TCP_RECV_BUFFER_SIZE 1024
 #define MG_UDP_RECV_BUFFER_SIZE 1500
diff --git a/src/net_if_socket.h b/src/mg_net_if_socket.h
similarity index 93%
rename from src/net_if_socket.h
rename to src/mg_net_if_socket.h
index 50afe5d69..9ce65baf7 100644
--- a/src/net_if_socket.h
+++ b/src/mg_net_if_socket.h
@@ -6,7 +6,7 @@
 #ifndef CS_MONGOOSE_SRC_NET_IF_SOCKET_H_
 #define CS_MONGOOSE_SRC_NET_IF_SOCKET_H_
 
-#include "mongoose/src/net_if.h"
+#include "mongoose/src/mg_net_if.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/net_if_socks.c b/src/mg_net_if_socks.c
similarity index 100%
rename from src/net_if_socks.c
rename to src/mg_net_if_socks.c
diff --git a/src/net_if_socks.h b/src/mg_net_if_socks.h
similarity index 92%
rename from src/net_if_socks.h
rename to src/mg_net_if_socks.h
index f89c354de..0257a95fe 100644
--- a/src/net_if_socks.h
+++ b/src/mg_net_if_socks.h
@@ -7,7 +7,7 @@
 #define CS_MONGOOSE_SRC_NET_IF_SOCKS_H_
 
 #if MG_ENABLE_SOCKS
-#include "mongoose/src/net_if.h"
+#include "mongoose/src/mg_net_if.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/resolv.c b/src/mg_resolv.c
similarity index 99%
rename from src/resolv.c
rename to src/mg_resolv.c
index 1241d88df..a4c771fd3 100644
--- a/src/resolv.c
+++ b/src/mg_resolv.c
@@ -5,8 +5,8 @@
 
 #if MG_ENABLE_ASYNC_RESOLVER
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/resolv.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_resolv.h"
 
 #ifndef MG_DEFAULT_NAMESERVER
 #define MG_DEFAULT_NAMESERVER "8.8.8.8"
diff --git a/src/resolv.h b/src/mg_resolv.h
similarity index 98%
rename from src/resolv.h
rename to src/mg_resolv.h
index 17635b2d8..51e4f2be7 100644
--- a/src/resolv.h
+++ b/src/mg_resolv.h
@@ -10,7 +10,7 @@
 #ifndef CS_MONGOOSE_SRC_RESOLV_H_
 #define CS_MONGOOSE_SRC_RESOLV_H_
 
-#include "mongoose/src/dns.h"
+#include "mongoose/src/mg_dns.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/sntp.c b/src/mg_sntp.c
similarity index 98%
rename from src/sntp.c
rename to src/mg_sntp.c
index 4482540ef..0d74cff03 100644
--- a/src/sntp.c
+++ b/src/mg_sntp.c
@@ -3,9 +3,9 @@
  * All rights reserved
  */
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/sntp.h"
-#include "mongoose/src/util.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_sntp.h"
+#include "mongoose/src/mg_util.h"
 
 #if MG_ENABLE_SNTP
 
diff --git a/src/sntp.h b/src/mg_sntp.h
similarity index 100%
rename from src/sntp.h
rename to src/mg_sntp.h
diff --git a/src/socks.c b/src/mg_socks.c
similarity index 98%
rename from src/socks.c
rename to src/mg_socks.c
index bb4b44c80..3fb18491e 100644
--- a/src/socks.c
+++ b/src/mg_socks.c
@@ -5,8 +5,8 @@
 
 #if MG_ENABLE_SOCKS
 
-#include "mongoose/src/socks.h"
-#include "mongoose/src/internal.h"
+#include "mongoose/src/mg_socks.h"
+#include "mongoose/src/mg_internal.h"
 
 /*
  *  https://www.ietf.org/rfc/rfc1928.txt paragraph 3, handle client handshake
diff --git a/src/socks.h b/src/mg_socks.h
similarity index 100%
rename from src/socks.h
rename to src/mg_socks.h
diff --git a/src/ssl_if.h b/src/mg_ssl_if.h
similarity index 100%
rename from src/ssl_if.h
rename to src/mg_ssl_if.h
diff --git a/src/ssl_if_mbedtls.c b/src/mg_ssl_if_mbedtls.c
similarity index 100%
rename from src/ssl_if_mbedtls.c
rename to src/mg_ssl_if_mbedtls.c
diff --git a/src/ssl_if_openssl.c b/src/mg_ssl_if_openssl.c
similarity index 100%
rename from src/ssl_if_openssl.c
rename to src/mg_ssl_if_openssl.c
diff --git a/src/uri.c b/src/mg_uri.c
similarity index 98%
rename from src/uri.c
rename to src/mg_uri.c
index 90c397f38..34c062656 100644
--- a/src/uri.c
+++ b/src/mg_uri.c
@@ -3,8 +3,8 @@
  * All rights reserved
  */
 
-#include "mongoose/src/internal.h"
-#include "mongoose/src/uri.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_uri.h"
 
 /*
  * scan string until encountering one of `seps`, keeping track of component
diff --git a/src/uri.h b/src/mg_uri.h
similarity index 98%
rename from src/uri.h
rename to src/mg_uri.h
index 7e31d54a2..476ef6cd3 100644
--- a/src/uri.h
+++ b/src/mg_uri.h
@@ -10,7 +10,7 @@
 #ifndef CS_MONGOOSE_SRC_URI_H_
 #define CS_MONGOOSE_SRC_URI_H_
 
-#include "mongoose/src/net.h"
+#include "mongoose/src/mg_net.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/src/util.c b/src/mg_util.c
similarity index 99%
rename from src/util.c
rename to src/mg_util.c
index 4202c5327..a58148603 100644
--- a/src/util.c
+++ b/src/mg_util.c
@@ -4,8 +4,8 @@
  */
 
 #include "common/cs_base64.h"
-#include "mongoose/src/internal.h"
-#include "mongoose/src/util.h"
+#include "mongoose/src/mg_internal.h"
+#include "mongoose/src/mg_util.h"
 
 /* For platforms with limited libc */
 #ifndef MAX
diff --git a/src/util.h b/src/mg_util.h
similarity index 98%
rename from src/util.h
rename to src/mg_util.h
index 15a6ee24a..742f98e2b 100644
--- a/src/util.h
+++ b/src/mg_util.h
@@ -12,8 +12,8 @@
 
 #include <stdio.h>
 
-#include "mongoose/src/common.h"
-#include "mongoose/src/net_if.h"
+#include "mongoose/src/mg_common.h"
+#include "mongoose/src/mg_net_if.h"
 
 #ifdef __cplusplus
 extern "C" {
diff --git a/test/Makefile b/test/Makefile
index ecdc5ec98..ad7c1252f 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -47,7 +47,7 @@ LDFLAGS += -lmbedcrypto -lmbedtls -lmbedx509
 endif
 
 include test.mk
-include $(SRC_DIR)/modules.mk
+include $(SRC_DIR)/mg_modules.mk
 
 # http://crossgcc.rts-software.org/doku.php?id=compiling_for_win32
 MINGW_GCC=/usr/local/gcc-4.8.0-qt-4.8.4-for-mingw32/win32-gcc/bin/i586-mingw32-gcc
diff --git a/test/unit_test.c b/test/unit_test.c
index 9fdd7b776..1bce202ea 100644
--- a/test/unit_test.c
+++ b/test/unit_test.c
@@ -16,7 +16,7 @@
  */
 
 #include "mongoose/mongoose.h"
-#include "mongoose/src/internal.h"
+#include "mongoose/src/mg_internal.h"
 #include "unit_test.h"
 #include "common/test_util.h"
 #include "common/cs_md5.h"
-- 
GitLab