]> nmode's Git Repositories - signal-cli/commitdiff
Update json-rpc client
authorAsamK <asamk@gmx.de>
Sat, 21 May 2022 10:10:51 +0000 (12:10 +0200)
committerAsamK <asamk@gmx.de>
Sat, 21 May 2022 10:11:03 +0000 (12:11 +0200)
client/Cargo.lock
client/src/cli.rs
client/src/jsonrpc.rs
client/src/main.rs
graalvm-config-dir/reflect-config.json

index 855d74bc55abc82ff623527d4c510c05990f9b72..607cf0d53ede6aa9fbcac9059105f94b091c214b 100644 (file)
@@ -639,9 +639,9 @@ dependencies = [
 
 [[package]]
 name = "regex"
-version = "1.5.5"
+version = "1.5.6"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "1a11647b6b25ff05a515cb92c365cec08801e83423a235b51e231e1808747286"
+checksum = "d83f127d94bdbcda4c8cc2e50f6f84f4b611f69c902699ca385a39c3a75f9ff1"
 dependencies = [
  "aho-corasick",
  "memchr",
@@ -650,9 +650,9 @@ dependencies = [
 
 [[package]]
 name = "regex-syntax"
-version = "0.6.25"
+version = "0.6.26"
 source = "registry+https://github.com/rust-lang/crates.io-index"
-checksum = "f497285884f3fcff424ffc933e56d7cbca511def0c9831a7f9b5f6153e3cc89b"
+checksum = "49b3de9ec5dc0a3417da371aab17d729997c15010e7fd24ff707773a33bddb64"
 
 [[package]]
 name = "rustc_version"
index 01b59fedcfb43c00cf50bae4222d255b9b6ea5cc..a98b16d33c19c8bdf0bb1e6db65d8b201c720d8e 100644 (file)
@@ -164,6 +164,15 @@ pub enum CliCommands {
         sticker: Option<String>,
     },
     SendContacts,
+    SendPaymentNotification {
+        recipient: String,
+
+        #[clap(long)]
+        receipt: String,
+
+        #[clap(long)]
+        note: String,
+    },
     SendReaction {
         recipient: Vec<String>,
 
@@ -319,6 +328,9 @@ pub enum CliCommands {
         #[clap(long = "about-emoji")]
         about_emoji: Option<String>,
 
+        #[clap(long = "mobile-coin-address")]
+        mobile_coin_address: Option<String>,
+
         #[clap(long)]
         avatar: Option<String>,
 
index f91be25e7a9d77e317f458d6f05d151df9af42a2..3c8abbbdac42ff1ba1edad53a2ce8740f1dd4b4b 100644 (file)
@@ -135,6 +135,15 @@ pub trait Rpc {
     #[rpc(name = "sendContacts", params = "named")]
     fn send_contacts(&self, account: Option<String>) -> Result<Value>;
 
+    #[rpc(name = "sendPaymentNotification", params = "named")]
+    fn send_payment_notification(
+        &self,
+        account: Option<String>,
+        recipient: String,
+        receipt: String,
+        note: String,
+    ) -> Result<Value>;
+
     #[rpc(name = "sendReaction", params = "named")]
     fn send_reaction(
         &self,
@@ -263,6 +272,7 @@ pub trait Rpc {
         #[allow(non_snake_case)] familyName: Option<String>,
         about: Option<String>,
         #[allow(non_snake_case)] aboutEmoji: Option<String>,
+        #[allow(non_snake_case)] mobileCoinAddress: Option<String>,
         avatar: Option<String>,
         #[allow(non_snake_case)] removeAvatar: bool,
     ) -> Result<Value>;
index 622be8061b1315a0311c5fd1c75a534155b7adbd..c0ef0de6029909b2b4f667ceba5c4be474e7e201 100644 (file)
@@ -147,6 +147,15 @@ async fn main() -> Result<(), anyhow::Error> {
                 .await
         }
         cli::CliCommands::SendContacts => client.send_contacts(cli.account).await,
+        cli::CliCommands::SendPaymentNotification {
+            recipient,
+            receipt,
+            note,
+        } => {
+            client
+                .send_payment_notification(cli.account, recipient, receipt, note)
+                .await
+        }
         cli::CliCommands::SendReaction {
             recipient,
             group_id,
@@ -309,6 +318,7 @@ async fn main() -> Result<(), anyhow::Error> {
             family_name,
             about,
             about_emoji,
+            mobile_coin_address,
             avatar,
             remove_avatar,
         } => {
@@ -319,6 +329,7 @@ async fn main() -> Result<(), anyhow::Error> {
                     family_name,
                     about,
                     about_emoji,
+                    mobile_coin_address,
                     avatar,
                     remove_avatar,
                 )
index 6d5df0d0cec9b8b84fe92be4f163d7bc468c2bbd..503f17f56aee257d133953d285a583b206db5877 100644 (file)
     {"name":"type_"}
   ]
 },
+{
+  "name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$SyncMessage$OutgoingPayment",
+  "fields":[
+    {"name":"bitField0_"}, 
+    {"name":"note_"}, 
+    {"name":"paymentDetailCase_"}, 
+    {"name":"paymentDetail_"}, 
+    {"name":"recipientUuid_"}
+  ]
+},
+{
+  "name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$SyncMessage$OutgoingPayment$MobileCoin",
+  "fields":[
+    {"name":"amountPicoMob_"}, 
+    {"name":"bitField0_"}, 
+    {"name":"feePicoMob_"}, 
+    {"name":"ledgerBlockIndex_"}, 
+    {"name":"ledgerBlockTimestamp_"}, 
+    {"name":"outputPublicKeys_"}, 
+    {"name":"receipt_"}, 
+    {"name":"recipientAddress_"}, 
+    {"name":"spentKeyImages_"}
+  ]
+},
 {
   "name":"org.whispersystems.signalservice.internal.push.SignalServiceProtos$SyncMessage$PniIdentity",
   "fields":[