aboutsummaryrefslogtreecommitdiffstats
path: root/adenosine-cli/src/lib.rs
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2022-12-19 20:03:55 -0800
committerBryan Newbold <bnewbold@robocracy.org>2022-12-19 20:21:32 -0800
commit0ff84da5a2e5fcf2dd9ad952ee9afb22241de785 (patch)
tree8b087724b5e5bef58a21ca732a38817b2ab01fa0 /adenosine-cli/src/lib.rs
parent0e170f77bae6851602b0c946708c97cfcb4ac3cf (diff)
downloadadenosine-0ff84da5a2e5fcf2dd9ad952ee9afb22241de785.tar.gz
adenosine-0ff84da5a2e5fcf2dd9ad952ee9afb22241de785.zip
cli: add XRPC query/rpc debug logging
Diffstat (limited to 'adenosine-cli/src/lib.rs')
-rw-r--r--adenosine-cli/src/lib.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/adenosine-cli/src/lib.rs b/adenosine-cli/src/lib.rs
index e232667..0db2cb4 100644
--- a/adenosine-cli/src/lib.rs
+++ b/adenosine-cli/src/lib.rs
@@ -61,6 +61,7 @@ impl XrpcClient {
nsid: &Nsid,
params: Option<HashMap<String, String>>,
) -> Result<Option<Value>> {
+ log::debug!("XRPC GET endpoint={} params={:?}", nsid, params);
let params: HashMap<String, String> = params.unwrap_or_default();
let res = self
.http_client
@@ -121,6 +122,12 @@ impl XrpcClient {
body: Option<Value>,
) -> Result<Option<Value>> {
let params: HashMap<String, String> = params.unwrap_or_default();
+ log::debug!(
+ "XRPC POST endpoint={} params={:?} body={:?}",
+ nsid,
+ params,
+ body
+ );
let mut req = self
.http_client
.post(format!("{}/xrpc/{}", self.host, nsid))