diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 7ae76d0..a15b398 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -15,7 +15,7 @@ jobs: strategy: matrix: - os: [ubuntu-latest, macos-latest] + os: [windows-latest, ubuntu-latest, macos-latest] steps: - uses: actions/checkout@v3 @@ -24,6 +24,9 @@ jobs: with: toolchain: stable override: true + - name: Install deps on Windows + if: runner.os == "Windows" + run: vcpkg install openssl:x64-windows-static-md - name: Install Deps On Linux if: runner.os == 'Linux' run: | diff --git a/Cargo.lock b/Cargo.lock index 70bd530..3d7bd0f 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -11,7 +11,7 @@ dependencies = [ "crossterm", "curl", "dirs", - "http 1.0.0", + "http 1.1.0", "lazy_static", "log", "mockito", @@ -118,9 +118,9 @@ dependencies = [ [[package]] name = "arboard" -version = "3.3.0" +version = "3.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "aafb29b107435aa276664c1db8954ac27a6e105cdad3c88287a199eb0e313c08" +checksum = "a2041f1943049c7978768d84e6d0fd95de98b76d6c4727b09e78ec253d29fa58" dependencies = [ "clipboard-win", "core-graphics", @@ -131,7 +131,7 @@ dependencies = [ "objc_id", "parking_lot", "thiserror", - "winapi", + "windows-sys 0.48.0", "x11rb", ] @@ -237,18 +237,18 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "clap" -version = "4.5.0" +version = "4.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "80c21025abd42669a92efc996ef13cfb2c5c627858421ea58d5c3b331a6c134f" +checksum = "949626d00e063efc93b6dca932419ceb5432f99769911c0b995f7e884c778813" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.5.0" +version = "4.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "458bf1f341769dfcf849846f65dffdf9146daa56bcd2a47cb4e1de9915567c99" +checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" dependencies = [ "anstream", "anstyle", @@ -264,13 +264,11 @@ checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" [[package]] name = "clipboard-win" -version = "4.5.0" +version = "5.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7191c27c2357d9b7ef96baac1773290d4ca63b24205b82a3fd8a0637afcf0362" +checksum = "d517d4b86184dbb111d3556a10f1c8a04da7428d2987bf1081602bf11c3aa9ee" dependencies = [ "error-code", - "str-buf", - "winapi", ] [[package]] @@ -328,9 +326,9 @@ checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" [[package]] name = "core-graphics" -version = "0.22.3" +version = "0.23.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2581bbab3b8ffc6fcbd550bf46c355135d16e9ff2a6ea032ad6b9bf1d7efe4fb" +checksum = "970a29baf4110c26fedbc7f82107d42c23f7e88e404c4577ed73fe99ff85a212" dependencies = [ "bitflags 1.3.2", "core-foundation", @@ -386,9 +384,9 @@ dependencies = [ [[package]] name = "curl" -version = "0.4.45" +version = "0.4.46" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f8e5123ab8c31200ce725939049ecd4a090b242608f24048131dedf9dd195aed" +checksum = "1e2161dd6eba090ff1594084e95fd67aeccf04382ffea77999ea94ed42ec67b6" dependencies = [ "curl-sys", "libc", @@ -401,9 +399,9 @@ dependencies = [ [[package]] name = "curl-sys" -version = "0.4.66+curl-8.3.0" +version = "0.4.72+curl-8.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "70c44a72e830f0e40ad90dda8a6ab6ed6314d39776599a58a2e5e37fbc6db5b9" +checksum = "29cbdc8314c447d11e8fd156dcdd031d9e02a7a976163e396b548c03153bc9ea" dependencies = [ "cc", "libc", @@ -412,7 +410,7 @@ dependencies = [ "openssl-sys", "pkg-config", "vcpkg", - "windows-sys 0.48.0", + "windows-sys 0.52.0", ] [[package]] @@ -477,13 +475,9 @@ dependencies = [ [[package]] name = "error-code" -version = "2.3.1" +version = "3.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64f18991e7bf11e7ffee451b5318b5c1a73c52d0d0ada6e5a3017c8c1ced6a21" -dependencies = [ - "libc", - "str-buf", -] +checksum = "a0474425d51df81997e2f90a21591180b38eccf27292d755f3e30750225c175b" [[package]] name = "fallible-iterator" @@ -524,18 +518,30 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "foreign-types" -version = "0.3.2" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f6f339eb8adc052cd2ca78910fda869aefa38d22d5cb648e6485e4d3fc06f3b1" +checksum = "d737d9aa519fb7b749cbc3b962edcf310a8dd1f4b67c91c4f83975dbdd17d965" dependencies = [ + "foreign-types-macros", "foreign-types-shared", ] +[[package]] +name = "foreign-types-macros" +version = "0.2.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a5c6c585bc94aaf2c7b51dd4c2ba22680844aba4c687be581871a6f518c5742" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.48", +] + [[package]] name = "foreign-types-shared" -version = "0.1.1" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" +checksum = "aa9a19cbb55df58761df49b23516a86d432839add4af60fc256da840f66ed35b" [[package]] name = "form_urlencoded" @@ -637,12 +643,12 @@ dependencies = [ [[package]] name = "gethostname" -version = "0.3.0" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb65d4ba3173c56a500b555b532f72c42e8d1fe64962b518897f8959fae2c177" +checksum = "0176e0459c2e4a1fe232f984bca6890e681076abb9934f6cea7c326f3fc47818" dependencies = [ "libc", - "winapi", + "windows-targets 0.48.5", ] [[package]] @@ -731,9 +737,9 @@ dependencies = [ [[package]] name = "http" -version = "1.0.0" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b32afd38673a8016f7c9ae69e5af41a58f81b1d31689040f2f1959594ce194ea" +checksum = "21b9ddb458710bc376481b842f5da65cdf31522de232c1ca8146abce2a358258" dependencies = [ "bytes", "fnv", @@ -923,9 +929,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.20" +version = "0.4.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5e6163cb8c49088c2c36f57875e58ccd8c87c7427f7fbd50ea6710b2f3f2e8f" +checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" [[package]] name = "lru" @@ -951,15 +957,6 @@ version = "2.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f232d6ef707e1956a43342693d2a31e72989554d58299d7a88738cc95b0d35c" -[[package]] -name = "memoffset" -version = "0.7.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5de893c32cde5f383baa4c04c5d6dbdd735cfd4a794b0debdb2bb1b421da5ff4" -dependencies = [ - "autocfg", -] - [[package]] name = "miniz_oxide" version = "0.7.1" @@ -1001,18 +998,6 @@ dependencies = [ "tokio", ] -[[package]] -name = "nix" -version = "0.26.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "598beaf3cc6fdd9a5dfb1630c2800c7acd31df7aaf0f565796fba2b53ca1af1b" -dependencies = [ - "bitflags 1.3.2", - "cfg-if", - "libc", - "memoffset", -] - [[package]] name = "num-integer" version = "0.1.45" @@ -1403,9 +1388,9 @@ dependencies = [ [[package]] name = "serde_json" -version = "1.0.113" +version = "1.0.114" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69801b70b1c3dac963ecb03a364ba0ceda9cf60c71cfe475e99864759c8b8a79" +checksum = "c5f09b1bd632ef549eaa9f60a1f8de742bdbc698e6cee2095fc84dde5f549ae0" dependencies = [ "itoa", "ryu", @@ -1526,12 +1511,6 @@ version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" -[[package]] -name = "str-buf" -version = "1.0.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e08d8363704e6c71fc928674353e6b7c23dcea9d82d7012c8faf2a3a025f8d0" - [[package]] name = "strsim" version = "0.11.0" @@ -1678,9 +1657,9 @@ dependencies = [ [[package]] name = "toml" -version = "0.8.10" +version = "0.8.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a9aad4a3066010876e8dcf5a8a06e70a558751117a145c6ce2b82c2e2054290" +checksum = "e9dd1545e8208b4a5af1aa9bbd0b4cf7e9ea08fabc5d0a5c67fcaafa17433aa3" dependencies = [ "serde", "serde_spanned", @@ -1699,9 +1678,9 @@ dependencies = [ [[package]] name = "toml_edit" -version = "0.22.4" +version = "0.22.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c9ffdf896f8daaabf9b66ba8e77ea1ed5ed0f72821b398aba62352e95062951" +checksum = "8e40bb779c5187258fd7aad0eb68cb8706a0a81fa712fbea808ab43c4b8374c4" dependencies = [ "indexmap 2.0.2", "serde", @@ -1834,15 +1813,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" -[[package]] -name = "winapi-wsapoll" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44c17110f57155602a80dca10be03852116403c9ff3cd25b079d666f2aa3df6e" -dependencies = [ - "winapi", -] - [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" @@ -2040,34 +2010,29 @@ checksum = "dff9641d1cd4be8d1a070daf9e3773c5f67e78b4d9d42263020c057706765c04" [[package]] name = "winnow" -version = "0.5.16" +version = "0.6.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "037711d82167854aff2018dfd193aa0fef5370f456732f0d5a0c59b0f1b4b907" +checksum = "dffa400e67ed5a4dd237983829e66475f0a4a26938c4b04c21baede6262215b8" dependencies = [ "memchr", ] [[package]] name = "x11rb" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1641b26d4dec61337c35a1b1aaf9e3cba8f46f0b43636c609ab0291a648040a" +checksum = "f8f25ead8c7e4cba123243a6367da5d3990e0d3affa708ea19dce96356bd9f1a" dependencies = [ "gethostname", - "nix", - "winapi", - "winapi-wsapoll", + "rustix", "x11rb-protocol", ] [[package]] name = "x11rb-protocol" -version = "0.12.0" +version = "0.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82d6c3f9a0fb6701fab8f6cea9b0c0bd5d6876f1f89f7fada07e558077c344bc" -dependencies = [ - "nix", -] +checksum = "e63e71c4b8bd9ffec2c963173a4dc4cbde9ee96961d4fcb4429db9929b606c34" [[package]] name = "zerocopy" diff --git a/Cargo.toml b/Cargo.toml index 4245b82..4db5e8f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,17 +23,17 @@ tui-input = "0.8.0" tui-widget-list = "0.8.2" lazy_static = "1.4.0" rusqlite = { version = "0.31.0", features = ["bundled"] } -serde_json = { version = "1.0.113", features = ["std"] } +serde_json = { version = "1.0.114", features = ["std"] } serde = { version = "1.0.196", features = ["derive"] } mockito = "1.2.0" regex = "1.10.3" -curl = { version = "0.4.45", features = ["http2", "ntlm"] } +curl = { version = "0.4.46", features = ["http2", "ntlm"] } dirs = "5.0.1" -http = "1.0.0" -toml = "0.8.10" -arboard = "3.3.0" -log = "0.4.20" -clap = "4.5.0" +http = "1.1.0" +toml = "0.8.12" +arboard = "3.3.2" +log = "0.4.21" +clap = "4.5.3" once_cell = "1.19.0" [profile.release] diff --git a/src/app.rs b/src/app.rs index 2aa9726..554cc57 100644 --- a/src/app.rs +++ b/src/app.rs @@ -6,6 +6,7 @@ use crate::request::curl::{AuthKind, Curl}; use crate::screens::screen::Screen; use crate::Config; use arboard::Clipboard; +use std::ops::DerefMut; use std::{error, mem}; use tui::widgets::{ListItem, ListState}; use tui_input::Input; @@ -231,14 +232,13 @@ impl<'a> App<'a> { pub fn select_item(&mut self) { if let Some(state) = self.state.as_mut() { if let Some(selected) = state.selected() { - // ^^^ returns usize index self.selected = Some(selected); } } } pub fn execute_command(&mut self) -> Result<(), String> { - self.command.execute(Some(&mut self.db)) + self.command.execute(Some(Box::new(self.db.deref_mut()))) } pub fn get_saved_keys(&self) -> Result, rusqlite::Error> { diff --git a/src/display/menuopts.rs b/src/display/menuopts.rs index 1ae6cd3..05f2876 100644 --- a/src/display/menuopts.rs +++ b/src/display/menuopts.rs @@ -1,9 +1,8 @@ /* -* Screen Menu Options +* String literals for Menus/Options */ - pub const SAVED_COMMANDS_PARAGRAPH: &str = - "\nPress q to exit\nPress Enter to Execute command\nPress 'ESC' or 'h' to go back\n"; + "\nPress q to exit\nPress Enter to Send Request\nPress 'ESC' or 'h' to go back\n"; pub const CURL: &str = "curl"; pub const WGET: &str = "wget"; pub const CUSTOM: &str = "custom"; @@ -12,7 +11,7 @@ pub const API_KEY_PARAGRAPH: &str = "Press q to quit\nPress 'ESC' or 'h' to go back\nPress Enter for Menu\n"; pub const HTTP_REQUEST: &str = "HTTP Request"; pub const DEFAULT_MENU_PARAGRAPH: &str = - "\nPress q to exit \n Press Enter to select \n Please select a Menu item\n keybindings to navigate"; + "\nPress q to exit. 'h' to go back \n Press Enter to select \n Please select a Menu item\n keybindings to navigate"; pub const AWS_AUTH_MSG: &str = "Alert: AWS Signature V4 Authentication is using the following ENV VARs: \nAWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_REGION"; @@ -29,7 +28,7 @@ pub const INPUT_MENU_TITLE: &str = "** Press i to enter Insert mode **"; pub const DOWNLOAD_MENU_TITLE: &str = "* CuTE ** Downloads *"; pub const ERROR_MENU_TITLE: &str = "* CuTE ** Error! *"; pub const SUCCESS_MENU_TITLE: &str = "* CuTE ** Success! *"; -pub const SUCCESS_MESSAGE: &str = "Command saved successfully"; +pub const SUCCESS_MESSAGE: &str = "Request saved successfully"; pub const INPUT_OPT_URL: &str = "Enter a URL for your {}\n and press Enter"; pub const INPUT_OPT_HEADERS: &str = "MUST be \"Key:Value\" pair and press Enter \n Example: Content-Type: application/json"; @@ -47,7 +46,6 @@ pub const NEWLINE: &str = "\n"; #[rustfmt::skip] pub const CUTE_LOGO: &str = " . . . . . . . . . . . . . . .p o w .. e r e d. . ..b.y .. - ``*`*`*`*``*``*` .uuuu. uuuuu, ``*`*'*'*'*''*'`*`*`*`*`'*'*'`**`'*'*'*`*`l *&%&* *&%&*  $#$#$#$#$#$#$#$` $#$#$``| #$#$#$''$#$#$#$#$#$#$#$#$#$#$ '#%#%#%#%#%#%#%##``i ** *&%&* *&%&* %%%%#``;;;;;;;` %%%%#``| %%%%#``| **`;; %%%%&*+`` **;;| %%%%%%` %%%%%%``b *%%* *&%&* *&%&* %%%%#``| *. %%%%#``| %%%%#``| ~ ` %%%%$*+` ` . %%%%%%`===#####`` ** *&%&* *&%&* @@ -63,7 +61,7 @@ pub const CUTE_LOGO2: &str = " @@@@@@@@. @@@ @@@ @@@@@@@ @@@@@@@@ !@@ ```` @@! @@@ @@! @@! !@!' !@! @!@ !@! !@! -!@!' @!@ !@! @!! @!!!:! +!@!' @!@ !@! @!! @!@!%! !!' !@! !!! !!! !!!!!: :!!' !!: !!! !!: !!: :!:'.. . :!: !:! :!: :!: @@ -72,7 +70,7 @@ pub const CUTE_LOGO2: &str = " "; pub const DISPLAY_OPT_VERBOSE: &str = " Verbose"; -pub const DISPLAY_OPT_COMMAND_SAVED: &str = " Command will be saved  "; +pub const DISPLAY_OPT_COMMAND_SAVED: &str = " Request will be saved  "; pub const DISPLAY_OPT_HEADERS: &str = " Response headers included 󱈝 "; pub const DISPLAY_OPT_PROGRESS_BAR: &str = " Enable Progress Bar 󰦖 "; pub const DISPLAY_OPT_FAIL_ON_ERROR: &str = " Fail on error  "; @@ -82,7 +80,7 @@ pub const DISPLAY_OPT_UNRESTRICTED_AUTH: &str = "- Send auth to hosts if redirec pub const DISPLAY_OPT_MAX_REDIRECTS: &str = " Max redirects: "; pub const DISPLAY_OPT_UNIX_SOCKET: &str = " Unix Socket: "; pub const DISPLAY_OPT_CA_PATH: &str = " 󰄤 SSL Certificate path: "; -pub const DISPLAY_OPT_AUTH: &str = " Authentication: "; +pub const DISPLAY_OPT_AUTH: &str = " Auth: "; pub const DISPLAY_OPT_MATCH_WILDCARD: &str = " Match glob wildcard 󰛄 "; pub const DISPLAY_OPT_CERT_INFO: &str = " Request certificate info 󰄤 "; pub const DISPLAY_OPT_BODY: &str = " Request Body: "; @@ -126,8 +124,8 @@ pub const ALERT_MENU_OPTIONS_KEY: [&str; 3] = ["Delete", "Copy to Clipboard", "C pub const MAIN_MENU_OPTIONS: [&str; 4] = [ "Build and send an HTTP request 󰖟 ", "Download a remote file or directory 󰧩 ", - "View my stored API keys 󱂛  ", - "View or execute my saved commands  ", + "View Saved API keys 󱂛  ", + "View saved requests  ", ]; pub const REQUEST_MENU_OPTIONS: [&str; 12] = [ "Add a URL 󰖟 ", @@ -139,7 +137,7 @@ pub const REQUEST_MENU_OPTIONS: [&str; 12] = [ "Add Request Body 󰘦 ", "Save this Request  ", "Save your API token or login information  ", - "Execute command  ", + "Send Request  ", "More Options  ", "Clear all options  ", ]; @@ -192,6 +190,6 @@ pub const RESPONSE_MENU_OPTIONS: [&str; 5] = [ "Write to file? 󱇧 ", "View response headers 󰰀 ", "View response body 󰈮 ", - "Copy command to clipboard 󰅎 ", + "Copy CLI command to clipboard 󰅎 ", "Return to main menu  ", ]; diff --git a/src/request/command.rs b/src/request/command.rs index 0879759..c32a82d 100644 --- a/src/request/command.rs +++ b/src/request/command.rs @@ -32,7 +32,7 @@ impl Display for CmdType { } } impl CMD for Cmd<'_> { - fn execute(&mut self, db: Option<&mut Box>) -> Result<(), String> { + fn execute(&mut self, db: Option>) -> Result<(), String> { match self { Cmd::Curl(curl) => curl.execute(db), Cmd::Wget(wget) => wget.execute(db), @@ -277,7 +277,7 @@ impl CMD for Cmd<'_> { } } pub trait CMD { - fn execute(&mut self, db: Option<&mut Box>) -> Result<(), String>; + fn execute(&mut self, db: Option>) -> Result<(), String>; fn get_method(&self) -> Option; fn add_basic_auth(&mut self, info: &str); fn get_upload_file(&self) -> Option; diff --git a/src/request/curl.rs b/src/request/curl.rs index ac62bc6..8c17f90 100644 --- a/src/request/curl.rs +++ b/src/request/curl.rs @@ -363,7 +363,7 @@ impl<'a> CMD for Curl<'a> { self.upload_file.clone() } - fn execute(&mut self, mut db: Option<&mut Box>) -> Result<(), String> { + fn execute(&mut self, mut db: Option>) -> Result<(), String> { let mut list = List::new(); curl::init(); @@ -381,6 +381,7 @@ impl<'a> CMD for Curl<'a> { // Save command to DB if self.will_save_command() { if let Some(ref mut db) = db { + self.build_command_string(); let command_string = &self.get_command_string(); let command_json = serde_json::to_string(&self) .map_err(|e| format!("Error serializing command: {}", e))?; diff --git a/src/request/wget.rs b/src/request/wget.rs index 9e69b9e..6d52118 100644 --- a/src/request/wget.rs +++ b/src/request/wget.rs @@ -15,7 +15,7 @@ impl CMD for Wget { // This is just if we want to build a string from the command. Not sure if we are going // to need this, but we may end up storing download commands in DB - fn execute(&mut self, _db: Option<&mut Box>) -> Result<(), String> { + fn execute(&mut self, _db: Option>) -> Result<(), String> { self.build_command(); let command = std::process::Command::new("sh") .arg("-c") diff --git a/src/screens/input/input.rs b/src/screens/input/input.rs index 1e131d1..4a43062 100644 --- a/src/screens/input/input.rs +++ b/src/screens/input/input.rs @@ -296,10 +296,7 @@ fn parse_auth(auth: AuthType, app: &mut App, message: &str) { _ => AuthKind::None, }); if app.has_auth() { - app.opts.retain(|x| match x { - AppOptions::Auth(_) => false, - _ => true, - }); + app.opts.retain(|x| !matches!(x, AppOptions::Auth(_))); } app.opts.push(AppOptions::Auth(match auth { AuthType::Basic => AuthKind::Basic(String::from(message)),