@jaw.id/cli 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/oclif.manifest.json +150 -150
- package/package.json +2 -2
package/oclif.manifest.json
CHANGED
|
@@ -479,14 +479,15 @@
|
|
|
479
479
|
"call.js"
|
|
480
480
|
]
|
|
481
481
|
},
|
|
482
|
-
"
|
|
482
|
+
"x402:log": {
|
|
483
483
|
"aliases": [],
|
|
484
484
|
"args": {},
|
|
485
|
-
"description": "
|
|
485
|
+
"description": "Show the local x402 payment ledger: every attempt, paid, failed or refused, with amounts and transactions.",
|
|
486
486
|
"examples": [
|
|
487
|
-
"<%= config.bin %>
|
|
488
|
-
"<%= config.bin %>
|
|
489
|
-
"<%= config.bin %>
|
|
487
|
+
"<%= config.bin %> x402 log",
|
|
488
|
+
"<%= config.bin %> x402 log --limit 20",
|
|
489
|
+
"<%= config.bin %> x402 log --status failed",
|
|
490
|
+
"<%= config.bin %> x402 log --output json"
|
|
490
491
|
],
|
|
491
492
|
"flags": {
|
|
492
493
|
"output": {
|
|
@@ -534,36 +535,29 @@
|
|
|
534
535
|
"allowNo": false,
|
|
535
536
|
"type": "boolean"
|
|
536
537
|
},
|
|
537
|
-
"
|
|
538
|
-
"description": "
|
|
539
|
-
"
|
|
540
|
-
"x402"
|
|
541
|
-
],
|
|
542
|
-
"name": "permissions",
|
|
538
|
+
"limit": {
|
|
539
|
+
"description": "Show only the most recent N entries.",
|
|
540
|
+
"name": "limit",
|
|
543
541
|
"hasDynamicHelp": false,
|
|
544
542
|
"multiple": false,
|
|
545
543
|
"type": "option"
|
|
546
544
|
},
|
|
547
|
-
"
|
|
548
|
-
"description": "
|
|
549
|
-
"
|
|
550
|
-
"permissions"
|
|
551
|
-
],
|
|
552
|
-
"name": "x402",
|
|
553
|
-
"allowNo": false,
|
|
554
|
-
"type": "boolean"
|
|
555
|
-
},
|
|
556
|
-
"limit": {
|
|
557
|
-
"description": "Spend cap for --x402, as <amount>/<period> (default 10/day).",
|
|
558
|
-
"name": "limit",
|
|
545
|
+
"status": {
|
|
546
|
+
"description": "Show only entries with this outcome.",
|
|
547
|
+
"name": "status",
|
|
559
548
|
"hasDynamicHelp": false,
|
|
560
549
|
"multiple": false,
|
|
550
|
+
"options": [
|
|
551
|
+
"paid",
|
|
552
|
+
"failed",
|
|
553
|
+
"refused"
|
|
554
|
+
],
|
|
561
555
|
"type": "option"
|
|
562
556
|
}
|
|
563
557
|
},
|
|
564
558
|
"hasDynamicHelp": false,
|
|
565
559
|
"hiddenAliases": [],
|
|
566
|
-
"id": "
|
|
560
|
+
"id": "x402:log",
|
|
567
561
|
"pluginAlias": "@jaw.id/cli",
|
|
568
562
|
"pluginName": "@jaw.id/cli",
|
|
569
563
|
"pluginType": "core",
|
|
@@ -573,14 +567,25 @@
|
|
|
573
567
|
"relativePath": [
|
|
574
568
|
"dist",
|
|
575
569
|
"commands",
|
|
576
|
-
"
|
|
577
|
-
"
|
|
570
|
+
"x402",
|
|
571
|
+
"log.js"
|
|
578
572
|
]
|
|
579
573
|
},
|
|
580
|
-
"
|
|
574
|
+
"x402:pay": {
|
|
581
575
|
"aliases": [],
|
|
582
|
-
"args": {
|
|
583
|
-
|
|
576
|
+
"args": {
|
|
577
|
+
"url": {
|
|
578
|
+
"description": "Resource URL to fetch",
|
|
579
|
+
"name": "url",
|
|
580
|
+
"required": true
|
|
581
|
+
}
|
|
582
|
+
},
|
|
583
|
+
"description": "Fetch a URL, paying an x402 challenge with the session key. Dry run by default: pass --pay to actually spend.",
|
|
584
|
+
"examples": [
|
|
585
|
+
"<%= config.bin %> x402 pay https://api.example.com/resource",
|
|
586
|
+
"<%= config.bin %> x402 pay https://api.example.com/resource --pay",
|
|
587
|
+
"<%= config.bin %> x402 pay https://api.example.com/resource --pay --max-amount 50000"
|
|
588
|
+
],
|
|
584
589
|
"flags": {
|
|
585
590
|
"output": {
|
|
586
591
|
"char": "o",
|
|
@@ -627,16 +632,37 @@
|
|
|
627
632
|
"allowNo": false,
|
|
628
633
|
"type": "boolean"
|
|
629
634
|
},
|
|
630
|
-
"
|
|
631
|
-
"description": "
|
|
632
|
-
"name": "
|
|
635
|
+
"pay": {
|
|
636
|
+
"description": "Actually sign and send the payment. Without this the command stops before spending.",
|
|
637
|
+
"name": "pay",
|
|
633
638
|
"allowNo": false,
|
|
634
639
|
"type": "boolean"
|
|
640
|
+
},
|
|
641
|
+
"max-amount": {
|
|
642
|
+
"description": "Hard ceiling in base units for this call, on top of the configured policy.",
|
|
643
|
+
"name": "max-amount",
|
|
644
|
+
"hasDynamicHelp": false,
|
|
645
|
+
"multiple": false,
|
|
646
|
+
"type": "option"
|
|
647
|
+
},
|
|
648
|
+
"method": {
|
|
649
|
+
"description": "HTTP method (default GET).",
|
|
650
|
+
"name": "method",
|
|
651
|
+
"hasDynamicHelp": false,
|
|
652
|
+
"multiple": false,
|
|
653
|
+
"type": "option"
|
|
654
|
+
},
|
|
655
|
+
"body": {
|
|
656
|
+
"description": "Request body.",
|
|
657
|
+
"name": "body",
|
|
658
|
+
"hasDynamicHelp": false,
|
|
659
|
+
"multiple": false,
|
|
660
|
+
"type": "option"
|
|
635
661
|
}
|
|
636
662
|
},
|
|
637
663
|
"hasDynamicHelp": false,
|
|
638
664
|
"hiddenAliases": [],
|
|
639
|
-
"id": "
|
|
665
|
+
"id": "x402:pay",
|
|
640
666
|
"pluginAlias": "@jaw.id/cli",
|
|
641
667
|
"pluginName": "@jaw.id/cli",
|
|
642
668
|
"pluginType": "core",
|
|
@@ -646,20 +672,17 @@
|
|
|
646
672
|
"relativePath": [
|
|
647
673
|
"dist",
|
|
648
674
|
"commands",
|
|
649
|
-
"
|
|
650
|
-
"
|
|
675
|
+
"x402",
|
|
676
|
+
"pay.js"
|
|
651
677
|
]
|
|
652
678
|
},
|
|
653
|
-
"
|
|
679
|
+
"x402:status": {
|
|
654
680
|
"aliases": [],
|
|
655
681
|
"args": {},
|
|
656
|
-
"description": "
|
|
682
|
+
"description": "Show x402 payment readiness: which account holds the funds, the resolved caps, and what has been spent. Reads only, never pays.",
|
|
657
683
|
"examples": [
|
|
658
|
-
"<%= config.bin %>
|
|
659
|
-
"<%= config.bin %>
|
|
660
|
-
"<%= config.bin %> session setup --chain 84532",
|
|
661
|
-
"<%= config.bin %> session setup --permissions '{\"calls\":[...]}' --expiry 14",
|
|
662
|
-
"<%= config.bin %> session setup --permissions ./permissions.json"
|
|
684
|
+
"<%= config.bin %> x402 status",
|
|
685
|
+
"<%= config.bin %> x402 status --output json"
|
|
663
686
|
],
|
|
664
687
|
"flags": {
|
|
665
688
|
"output": {
|
|
@@ -706,44 +729,11 @@
|
|
|
706
729
|
"name": "quiet",
|
|
707
730
|
"allowNo": false,
|
|
708
731
|
"type": "boolean"
|
|
709
|
-
},
|
|
710
|
-
"permissions": {
|
|
711
|
-
"description": "Permission scope (inline JSON or file path). Overrides config.permissions.",
|
|
712
|
-
"exclusive": [
|
|
713
|
-
"x402"
|
|
714
|
-
],
|
|
715
|
-
"name": "permissions",
|
|
716
|
-
"hasDynamicHelp": false,
|
|
717
|
-
"multiple": false,
|
|
718
|
-
"type": "option"
|
|
719
|
-
},
|
|
720
|
-
"x402": {
|
|
721
|
-
"description": "Grant exactly what x402 payments need on this chain: a USDC transfer capped per period. Builds the permission from the asset registry so the USDC address and function signature do not have to be written by hand. Tune the cap with --limit.",
|
|
722
|
-
"exclusive": [
|
|
723
|
-
"permissions"
|
|
724
|
-
],
|
|
725
|
-
"name": "x402",
|
|
726
|
-
"allowNo": false,
|
|
727
|
-
"type": "boolean"
|
|
728
|
-
},
|
|
729
|
-
"limit": {
|
|
730
|
-
"description": "Spend cap for --x402, as <amount>/<period> (default 10/day). Examples: 25/day, 2.5/week, 100/month.",
|
|
731
|
-
"name": "limit",
|
|
732
|
-
"hasDynamicHelp": false,
|
|
733
|
-
"multiple": false,
|
|
734
|
-
"type": "option"
|
|
735
|
-
},
|
|
736
|
-
"expiry": {
|
|
737
|
-
"description": "Permission expiry in days. Overrides config.sessionExpiry.",
|
|
738
|
-
"name": "expiry",
|
|
739
|
-
"hasDynamicHelp": false,
|
|
740
|
-
"multiple": false,
|
|
741
|
-
"type": "option"
|
|
742
732
|
}
|
|
743
733
|
},
|
|
744
734
|
"hasDynamicHelp": false,
|
|
745
735
|
"hiddenAliases": [],
|
|
746
|
-
"id": "
|
|
736
|
+
"id": "x402:status",
|
|
747
737
|
"pluginAlias": "@jaw.id/cli",
|
|
748
738
|
"pluginName": "@jaw.id/cli",
|
|
749
739
|
"pluginType": "core",
|
|
@@ -753,14 +743,19 @@
|
|
|
753
743
|
"relativePath": [
|
|
754
744
|
"dist",
|
|
755
745
|
"commands",
|
|
756
|
-
"
|
|
757
|
-
"
|
|
746
|
+
"x402",
|
|
747
|
+
"status.js"
|
|
758
748
|
]
|
|
759
749
|
},
|
|
760
|
-
"session:
|
|
750
|
+
"session:add": {
|
|
761
751
|
"aliases": [],
|
|
762
752
|
"args": {},
|
|
763
|
-
"description": "
|
|
753
|
+
"description": "Add permissions to the current session, keeping the ones it already has (one browser approval to grant, one to revoke the old).",
|
|
754
|
+
"examples": [
|
|
755
|
+
"<%= config.bin %> session add --x402",
|
|
756
|
+
"<%= config.bin %> session add --x402 --limit 10/day",
|
|
757
|
+
"<%= config.bin %> session add --permissions '{\"calls\":[...]}'"
|
|
758
|
+
],
|
|
764
759
|
"flags": {
|
|
765
760
|
"output": {
|
|
766
761
|
"char": "o",
|
|
@@ -806,11 +801,37 @@
|
|
|
806
801
|
"name": "quiet",
|
|
807
802
|
"allowNo": false,
|
|
808
803
|
"type": "boolean"
|
|
804
|
+
},
|
|
805
|
+
"permissions": {
|
|
806
|
+
"description": "Permissions to add (inline JSON or file path).",
|
|
807
|
+
"exclusive": [
|
|
808
|
+
"x402"
|
|
809
|
+
],
|
|
810
|
+
"name": "permissions",
|
|
811
|
+
"hasDynamicHelp": false,
|
|
812
|
+
"multiple": false,
|
|
813
|
+
"type": "option"
|
|
814
|
+
},
|
|
815
|
+
"x402": {
|
|
816
|
+
"description": "Add exactly what x402 payments need on the session chain. Tune the cap with --limit.",
|
|
817
|
+
"exclusive": [
|
|
818
|
+
"permissions"
|
|
819
|
+
],
|
|
820
|
+
"name": "x402",
|
|
821
|
+
"allowNo": false,
|
|
822
|
+
"type": "boolean"
|
|
823
|
+
},
|
|
824
|
+
"limit": {
|
|
825
|
+
"description": "Spend cap for --x402, as <amount>/<period> (default 10/day).",
|
|
826
|
+
"name": "limit",
|
|
827
|
+
"hasDynamicHelp": false,
|
|
828
|
+
"multiple": false,
|
|
829
|
+
"type": "option"
|
|
809
830
|
}
|
|
810
831
|
},
|
|
811
832
|
"hasDynamicHelp": false,
|
|
812
833
|
"hiddenAliases": [],
|
|
813
|
-
"id": "session:
|
|
834
|
+
"id": "session:add",
|
|
814
835
|
"pluginAlias": "@jaw.id/cli",
|
|
815
836
|
"pluginName": "@jaw.id/cli",
|
|
816
837
|
"pluginType": "core",
|
|
@@ -821,19 +842,13 @@
|
|
|
821
842
|
"dist",
|
|
822
843
|
"commands",
|
|
823
844
|
"session",
|
|
824
|
-
"
|
|
845
|
+
"add.js"
|
|
825
846
|
]
|
|
826
847
|
},
|
|
827
|
-
"
|
|
848
|
+
"session:revoke": {
|
|
828
849
|
"aliases": [],
|
|
829
850
|
"args": {},
|
|
830
|
-
"description": "
|
|
831
|
-
"examples": [
|
|
832
|
-
"<%= config.bin %> x402 log",
|
|
833
|
-
"<%= config.bin %> x402 log --limit 20",
|
|
834
|
-
"<%= config.bin %> x402 log --status failed",
|
|
835
|
-
"<%= config.bin %> x402 log --output json"
|
|
836
|
-
],
|
|
851
|
+
"description": "Revoke on-chain permission and delete local session key.",
|
|
837
852
|
"flags": {
|
|
838
853
|
"output": {
|
|
839
854
|
"char": "o",
|
|
@@ -880,29 +895,16 @@
|
|
|
880
895
|
"allowNo": false,
|
|
881
896
|
"type": "boolean"
|
|
882
897
|
},
|
|
883
|
-
"
|
|
884
|
-
"description": "
|
|
885
|
-
"name": "
|
|
886
|
-
"
|
|
887
|
-
"
|
|
888
|
-
"type": "option"
|
|
889
|
-
},
|
|
890
|
-
"status": {
|
|
891
|
-
"description": "Show only entries with this outcome.",
|
|
892
|
-
"name": "status",
|
|
893
|
-
"hasDynamicHelp": false,
|
|
894
|
-
"multiple": false,
|
|
895
|
-
"options": [
|
|
896
|
-
"paid",
|
|
897
|
-
"failed",
|
|
898
|
-
"refused"
|
|
899
|
-
],
|
|
900
|
-
"type": "option"
|
|
898
|
+
"force": {
|
|
899
|
+
"description": "Delete the local session even if some permissions could not be revoked. They stay live on chain until they expire, and their ids are printed because deleting the session is what loses them.",
|
|
900
|
+
"name": "force",
|
|
901
|
+
"allowNo": false,
|
|
902
|
+
"type": "boolean"
|
|
901
903
|
}
|
|
902
904
|
},
|
|
903
905
|
"hasDynamicHelp": false,
|
|
904
906
|
"hiddenAliases": [],
|
|
905
|
-
"id": "
|
|
907
|
+
"id": "session:revoke",
|
|
906
908
|
"pluginAlias": "@jaw.id/cli",
|
|
907
909
|
"pluginName": "@jaw.id/cli",
|
|
908
910
|
"pluginType": "core",
|
|
@@ -912,24 +914,20 @@
|
|
|
912
914
|
"relativePath": [
|
|
913
915
|
"dist",
|
|
914
916
|
"commands",
|
|
915
|
-
"
|
|
916
|
-
"
|
|
917
|
+
"session",
|
|
918
|
+
"revoke.js"
|
|
917
919
|
]
|
|
918
920
|
},
|
|
919
|
-
"
|
|
921
|
+
"session:setup": {
|
|
920
922
|
"aliases": [],
|
|
921
|
-
"args": {
|
|
922
|
-
|
|
923
|
-
"description": "Resource URL to fetch",
|
|
924
|
-
"name": "url",
|
|
925
|
-
"required": true
|
|
926
|
-
}
|
|
927
|
-
},
|
|
928
|
-
"description": "Fetch a URL, paying an x402 challenge with the session key. Dry run by default: pass --pay to actually spend.",
|
|
923
|
+
"args": {},
|
|
924
|
+
"description": "Generate a session key and grant scoped on-chain permissions (one-time browser approval).",
|
|
929
925
|
"examples": [
|
|
930
|
-
"<%= config.bin %>
|
|
931
|
-
"<%= config.bin %> x402
|
|
932
|
-
"<%= config.bin %>
|
|
926
|
+
"<%= config.bin %> session setup --chain 8453 --x402",
|
|
927
|
+
"<%= config.bin %> session setup --chain 8453 --x402 --limit 25/day --expiry 14",
|
|
928
|
+
"<%= config.bin %> session setup --chain 84532",
|
|
929
|
+
"<%= config.bin %> session setup --permissions '{\"calls\":[...]}' --expiry 14",
|
|
930
|
+
"<%= config.bin %> session setup --permissions ./permissions.json"
|
|
933
931
|
],
|
|
934
932
|
"flags": {
|
|
935
933
|
"output": {
|
|
@@ -977,29 +975,35 @@
|
|
|
977
975
|
"allowNo": false,
|
|
978
976
|
"type": "boolean"
|
|
979
977
|
},
|
|
980
|
-
"
|
|
981
|
-
"description": "
|
|
982
|
-
"
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
"max-amount": {
|
|
987
|
-
"description": "Hard ceiling in base units for this call, on top of the configured policy.",
|
|
988
|
-
"name": "max-amount",
|
|
978
|
+
"permissions": {
|
|
979
|
+
"description": "Permission scope (inline JSON or file path). Overrides config.permissions.",
|
|
980
|
+
"exclusive": [
|
|
981
|
+
"x402"
|
|
982
|
+
],
|
|
983
|
+
"name": "permissions",
|
|
989
984
|
"hasDynamicHelp": false,
|
|
990
985
|
"multiple": false,
|
|
991
986
|
"type": "option"
|
|
992
987
|
},
|
|
993
|
-
"
|
|
994
|
-
"description": "
|
|
995
|
-
"
|
|
988
|
+
"x402": {
|
|
989
|
+
"description": "Grant exactly what x402 payments need on this chain: a USDC transfer capped per period. Builds the permission from the asset registry so the USDC address and function signature do not have to be written by hand. Tune the cap with --limit.",
|
|
990
|
+
"exclusive": [
|
|
991
|
+
"permissions"
|
|
992
|
+
],
|
|
993
|
+
"name": "x402",
|
|
994
|
+
"allowNo": false,
|
|
995
|
+
"type": "boolean"
|
|
996
|
+
},
|
|
997
|
+
"limit": {
|
|
998
|
+
"description": "Spend cap for --x402, as <amount>/<period> (default 10/day). Examples: 25/day, 2.5/week, 100/month.",
|
|
999
|
+
"name": "limit",
|
|
996
1000
|
"hasDynamicHelp": false,
|
|
997
1001
|
"multiple": false,
|
|
998
1002
|
"type": "option"
|
|
999
1003
|
},
|
|
1000
|
-
"
|
|
1001
|
-
"description": "
|
|
1002
|
-
"name": "
|
|
1004
|
+
"expiry": {
|
|
1005
|
+
"description": "Permission expiry in days. Overrides config.sessionExpiry.",
|
|
1006
|
+
"name": "expiry",
|
|
1003
1007
|
"hasDynamicHelp": false,
|
|
1004
1008
|
"multiple": false,
|
|
1005
1009
|
"type": "option"
|
|
@@ -1007,7 +1011,7 @@
|
|
|
1007
1011
|
},
|
|
1008
1012
|
"hasDynamicHelp": false,
|
|
1009
1013
|
"hiddenAliases": [],
|
|
1010
|
-
"id": "
|
|
1014
|
+
"id": "session:setup",
|
|
1011
1015
|
"pluginAlias": "@jaw.id/cli",
|
|
1012
1016
|
"pluginName": "@jaw.id/cli",
|
|
1013
1017
|
"pluginType": "core",
|
|
@@ -1017,18 +1021,14 @@
|
|
|
1017
1021
|
"relativePath": [
|
|
1018
1022
|
"dist",
|
|
1019
1023
|
"commands",
|
|
1020
|
-
"
|
|
1021
|
-
"
|
|
1024
|
+
"session",
|
|
1025
|
+
"setup.js"
|
|
1022
1026
|
]
|
|
1023
1027
|
},
|
|
1024
|
-
"
|
|
1028
|
+
"session:status": {
|
|
1025
1029
|
"aliases": [],
|
|
1026
1030
|
"args": {},
|
|
1027
|
-
"description": "Show
|
|
1028
|
-
"examples": [
|
|
1029
|
-
"<%= config.bin %> x402 status",
|
|
1030
|
-
"<%= config.bin %> x402 status --output json"
|
|
1031
|
-
],
|
|
1031
|
+
"description": "Show current session status (address, permissions, expiry).",
|
|
1032
1032
|
"flags": {
|
|
1033
1033
|
"output": {
|
|
1034
1034
|
"char": "o",
|
|
@@ -1078,7 +1078,7 @@
|
|
|
1078
1078
|
},
|
|
1079
1079
|
"hasDynamicHelp": false,
|
|
1080
1080
|
"hiddenAliases": [],
|
|
1081
|
-
"id": "
|
|
1081
|
+
"id": "session:status",
|
|
1082
1082
|
"pluginAlias": "@jaw.id/cli",
|
|
1083
1083
|
"pluginName": "@jaw.id/cli",
|
|
1084
1084
|
"pluginType": "core",
|
|
@@ -1088,10 +1088,10 @@
|
|
|
1088
1088
|
"relativePath": [
|
|
1089
1089
|
"dist",
|
|
1090
1090
|
"commands",
|
|
1091
|
-
"
|
|
1091
|
+
"session",
|
|
1092
1092
|
"status.js"
|
|
1093
1093
|
]
|
|
1094
1094
|
}
|
|
1095
1095
|
},
|
|
1096
|
-
"version": "0.2.
|
|
1096
|
+
"version": "0.2.1"
|
|
1097
1097
|
}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jaw.id/cli",
|
|
3
3
|
"description": "CLI + MCP Server for JAW.id smart accounts — for humans and AI agents",
|
|
4
|
-
"version": "0.2.
|
|
4
|
+
"version": "0.2.1",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"bin": {
|
|
@@ -112,7 +112,7 @@
|
|
|
112
112
|
}
|
|
113
113
|
},
|
|
114
114
|
"dependencies": {
|
|
115
|
-
"@jaw.id/core": "1.3.
|
|
115
|
+
"@jaw.id/core": "1.3.1",
|
|
116
116
|
"@modelcontextprotocol/sdk": "^1.12.1",
|
|
117
117
|
"@oclif/core": "^4.3.0",
|
|
118
118
|
"open": "^10.1.0",
|