bt_http_cli_conf

Crates.iobt_http_cli_conf
lib.rsbt_http_cli_conf
version0.1.3
created_at2025-03-19 19:08:03.780892+00
updated_at2026-01-12 16:06:03.989701+00
descriptionRetrieve the HTTP client configuration for a given environment from a YAML file.
homepagehttps://github.com/bachuetech/bt_http_cli_conf
repositoryhttps://github.com/bachuetech/bt_http_cli_conf
max_upload_size
id1598503
size19,827
(bachuetech)

documentation

README

Project Title

BT HTTP CLI CONFIG

Description

The get_http_client_config function is used to retrieve the HTTP client configuration for a given environment. It loads the configuration from a YAML file specified by an environment variable or specific path if the environment variable is nout found and returns the configuration as a vector of tuples containing key-value pairs.

Usage


const API_MGR_CONFIG_YML: &str = "config/http/client-config.yml";
const API_MGR_CONFIG_YML_ENV_VAR_NAME: &str = "BT_HTTPCLI_YMLCONFIGFILE";

let environment = "dev";

let conf = get_http_client_bool_config(&environment.to_owned()
                                        , &API_MGR_CONFIG_YML_ENV_VAR_NAME.to_string()
                                        , &API_MGR_CONFIG_YML.to_string());

Version History

  • 0.1.0
    • Initial Release
  • 0.1.1
    • Change parameters
  • 0.1.2
    • Update dependencies
  • 0.1.3
    • Update dependencies

License

GPL-3.0-only

Commit count: 6

cargo fmt