File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -563,6 +563,29 @@ private function handleCerts($api, $cmd)
563563 }
564564 }
565565
566+ private function handleIntegrator ($ api , $ cmd )
567+ {
568+ if (!array_key_exists ('idtoken ' , $ this ->opts ) || !$ this ->opts ['idtoken ' ]) {
569+ $ this ->log ->error ("no valid idtoken specified! please try re-login. " );
570+ return 2 ;
571+ }
572+ switch ($ cmd ) {
573+ case "listAccounts " :
574+ $ error = $ this ->checkArgs (['apikey ' , 'idtoken ' ]);
575+ if ($ error ) {
576+ return $ error ;
577+ }
578+ $ resp = $ this ->$ {"api " }->$ {"cmd " }(
579+ $ this ->opts ['idtoken ' ]
580+ );
581+ $ this ->log ->debug (print_r ($ resp , true ));
582+ return $ resp ;
583+ default :
584+ $ this ->log ->error ("Unknown api command " );
585+ return 3 ;
586+ }
587+ }
588+
566589 public function __call ($ methodCmd , $ methodApi )
567590 {
568591 // $methodApi array is populated on our internal calls to
@@ -585,6 +608,8 @@ public function __call($methodCmd, $methodApi)
585608 return $ this ->handlePgp ($ api , $ cmd , $ methodApi , $ methodCmd );
586609 case "certs " :
587610 return $ this ->handleCerts ($ api , $ cmd , $ methodApi , $ methodCmd );
611+ case "integrator " :
612+ return $ this ->handleIntegrator ($ api , $ cmd , $ methodApi , $ methodCmd );
588613 default :
589614 return 3 ;
590615 }
Original file line number Diff line number Diff line change 4747 wscli certs importCert [-c CONF] [-a APIKEY] [-i IDTOKEN] [-b BANK] [--certificate=<pem>] [--privatekey=<pem>]
4848 [--wsuserid=<wsuserid>] [--wstargetid=<wstargetid>] [--enccertificate=<pem>] [--encprivatekey=<pem>]
4949 wscli pgp listKeys [-c CONF] [-a APIKEY] [-i IDTOKEN]
50- wscli pgp uploadKey [-c CONF] [-a APIKEY] [-i IDTOKEN] [--pgpkeycontents=<pgpkeycontents>]
5150 wscli pgp deleteKey [-c CONF] [-a APIKEY] [-i IDTOKEN] [--pgpkeyid=<pgpkeyid>]
51+ wscli pgp uploadKey [-c CONF] [-a APIKEY] [-i IDTOKEN]
52+ [--pgpkeycontents=<pgpkeycontents>]
53+ wscli integrator listAccounts [-c CONF] [-a APIKEY] [-i IDTOKEN]
5254
5355
5456Options:
You can’t perform that action at this time.
0 commit comments