feat: Add colorized request logging
This commit is contained in:
@@ -7,7 +7,10 @@ DHL is a lightweight, configurable HTTP/HTTPS mock server built with Rust and Ax
|
||||
- **Live Configuration Reloading**: Changes to `config.json` (routes, status codes, etc.) and response files are applied immediately without restarting the server.
|
||||
- **Multi-Route Support**: Define as many paths as you need.
|
||||
- **JSON Response Files**: Responses are loaded from external JSON files.
|
||||
- **Request Logging**: Detailed logging of incoming requests, including methods, paths, and headers.
|
||||
- **Colorized Request Logging**: Detailed logging of incoming requests with terminal colors. Status codes are color-coded for quick identification:
|
||||
- <span style="color:green">**2xx Success**</span>: Green
|
||||
- <span style="color:yellow">**4xx Client Error**</span>: Yellow
|
||||
- <span style="color:red">**5xx Server Error**</span>: Red
|
||||
- **Header Masking**: Sensitive headers like `Authorization` can be masked in logs.
|
||||
- **HTTPS/TLS Support**: Optional TLS support for secure connections.
|
||||
- **Automatic Default Generation**: Creates default configuration and response files if they are missing.
|
||||
|
||||
Reference in New Issue
Block a user