From 0ff3fb9cba67048cba3bed207fde2fdf8bdafa6e Mon Sep 17 00:00:00 2001 From: jbesraa Date: Thu, 10 Aug 2023 09:39:30 +0300 Subject: [PATCH] create_pj_request --- payjoin/src/uri.rs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/payjoin/src/uri.rs b/payjoin/src/uri.rs index 20c988f7c..bd8f1426d 100644 --- a/payjoin/src/uri.rs +++ b/payjoin/src/uri.rs @@ -51,6 +51,12 @@ pub trait UriExtNetworkUnchecked<'a>: sealed::UriExtNetworkUnchecked { } pub trait PjUriExt: sealed::UriExt { + /// Prepare an HTTP request and request context to process the response + /// + /// An HTTP client will own the Request data while Context sticks around so + /// a `(Request, Context)` tuple is returned to keep them separated. call: + /// + /// `let (request, context) = uri.create_pj_request(psbt, params);` #[cfg(feature = "send")] fn create_pj_request( self,