22#include <nlohmann/json.hpp>
54 const nlohmann::json &payload,
size_t wire_size,
69 const std::string &format,
70 const unsigned char *data,
size_t len,
std::string format_echo_blob(const std::string &topic, const std::string &format, const unsigned char *data, size_t len, const EchoRenderOptions &opts)
Formats one received blob message for mads echo stdout.
std::string format_echo_json(const std::string &topic, const nlohmann::json &payload, size_t wire_size, const EchoRenderOptions &opts)
Formats one received JSON message for mads echo stdout.
std::string base64_encode(const unsigned char *data, size_t len)
Standard base64 encoding (RFC 4648, with = padding).
Rendering choices for format_echo_json()/format_echo_blob(), mirroring mads echo's CLI flags.