chia-agent 14.0.0-beta.3 → 14.1.0

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.
Files changed (116) hide show
  1. package/CHANGELOG.md +171 -2
  2. package/LICENSE +1 -1
  3. package/README.md +5 -5
  4. package/agent/index.d.ts +1 -1
  5. package/api/chia/consensus/block_record.d.ts +1 -1
  6. package/api/chia/consensus/blockchain.d.ts +2 -1
  7. package/api/chia/consensus/cost_calculator.d.ts +2 -3
  8. package/api/chia/data_layer/data_layer_util.d.ts +43 -10
  9. package/api/chia/data_layer/data_layer_wallet.d.ts +2 -2
  10. package/api/chia/farmer/farmer.d.ts +1 -1
  11. package/api/chia/full_node/signage_point.d.ts +1 -1
  12. package/api/chia/harvester/harvester.d.ts +1 -1
  13. package/api/chia/plot-sync/receiver.d.ts +2 -2
  14. package/api/chia/plotters/bladebit.d.ts +1 -1
  15. package/api/chia/plotters/chiapos.d.ts +1 -1
  16. package/api/chia/plotters/maxmax.d.ts +1 -1
  17. package/api/chia/plotting/util.d.ts +3 -3
  18. package/api/chia/pool/{store.d.ts → record.d.ts} +1 -1
  19. package/api/chia/pools/pool_config.d.ts +1 -1
  20. package/api/chia/pools/pool_wallet_info.d.ts +2 -2
  21. package/api/chia/protocols/farmer_protocol.d.ts +28 -6
  22. package/api/chia/protocols/harvester_protocol.d.ts +1 -1
  23. package/api/chia/protocols/pool_protocol.d.ts +13 -13
  24. package/api/chia/rpc/util.d.ts +12 -0
  25. package/api/chia/rpc/util.js +2 -0
  26. package/api/chia/rpc/wallet_request_types.d.ts +11 -0
  27. package/api/chia/rpc/wallet_request_types.js +2 -0
  28. package/api/chia/server/outbound_message.d.ts +1 -1
  29. package/api/chia/timelord/types.d.ts +1 -1
  30. package/api/chia/types/_python_types_.d.ts +22 -22
  31. package/api/chia/types/blockchain_format/classgroup.d.ts +1 -1
  32. package/api/chia/types/blockchain_format/coin.d.ts +1 -1
  33. package/api/chia/types/blockchain_format/foliage.d.ts +4 -4
  34. package/api/chia/types/blockchain_format/pool_target.d.ts +1 -1
  35. package/api/chia/types/blockchain_format/program.d.ts +1 -1
  36. package/api/chia/types/blockchain_format/proof_of_space.d.ts +1 -1
  37. package/api/chia/types/blockchain_format/reward_chain_block.d.ts +2 -2
  38. package/api/chia/types/blockchain_format/serialized_program.d.ts +1 -1
  39. package/api/chia/types/blockchain_format/sized_bytes.d.ts +7 -7
  40. package/api/chia/types/blockchain_format/slots.d.ts +4 -4
  41. package/api/chia/types/blockchain_format/sub_epoch_summary.d.ts +1 -1
  42. package/api/chia/types/blockchain_format/vdf.d.ts +2 -2
  43. package/api/chia/types/clvm_cost.d.ts +1 -1
  44. package/api/chia/types/coin_record.d.ts +2 -2
  45. package/api/chia/types/coin_spend.d.ts +2 -2
  46. package/api/chia/types/condition_opcode.d.ts +1 -1
  47. package/api/chia/types/condition_with_args.d.ts +1 -1
  48. package/api/chia/types/end_of_slot_bundle.d.ts +1 -1
  49. package/api/chia/types/full_block.d.ts +5 -1
  50. package/api/chia/types/mempool_item.d.ts +4 -3
  51. package/api/chia/types/mojos.d.ts +1 -1
  52. package/api/chia/types/signing_mode.d.ts +6 -5
  53. package/api/chia/types/spend_bundle.d.ts +1 -1
  54. package/api/chia/types/spend_bundle_condition.d.ts +2 -2
  55. package/api/chia/types/unfinished_header_block.d.ts +1 -1
  56. package/api/chia/util/keychain.d.ts +2 -2
  57. package/api/chia/util/misc.d.ts +1 -1
  58. package/api/chia/wallet/cat_wallet/cat_constants.d.ts +1 -1
  59. package/api/chia/wallet/conditions.d.ts +2 -2
  60. package/api/chia/wallet/dao_wallet/dao_info.d.ts +5 -5
  61. package/api/chia/wallet/dao_wallet/dao_wallet.d.ts +3 -3
  62. package/api/chia/wallet/lineage_proof.d.ts +1 -1
  63. package/api/chia/wallet/nft_wallet/nft_info.d.ts +1 -1
  64. package/api/chia/wallet/notification_store.d.ts +8 -0
  65. package/api/chia/wallet/notification_store.js +2 -0
  66. package/api/chia/wallet/puzzle_drivers.d.ts +2 -2
  67. package/api/chia/wallet/puzzles/clawback/metadata.d.ts +2 -2
  68. package/api/chia/wallet/trade_record.d.ts +3 -3
  69. package/api/chia/wallet/transaction_record.d.ts +4 -4
  70. package/api/chia/wallet/util/quality_filter.d.ts +5 -5
  71. package/api/chia/wallet/util/tx_config.d.ts +4 -11
  72. package/api/chia/wallet/util/wallet_types.d.ts +1 -1
  73. package/api/chia/wallet/vc_wallet/vc_drivers.d.ts +2 -2
  74. package/api/chia/wallet/vc_wallet/vc_store.d.ts +1 -1
  75. package/api/chia/wallet/wallet_coin_record.d.ts +2 -2
  76. package/api/chia/wallet/wallet_coin_store.d.ts +1 -1
  77. package/api/chia/wallet/wallet_info.d.ts +2 -2
  78. package/api/chia/wallet/wallet_node.d.ts +1 -1
  79. package/api/rpc/common/index.d.ts +32 -24
  80. package/api/rpc/common/index.js +8 -1
  81. package/api/rpc/crawler/index.d.ts +10 -10
  82. package/api/rpc/data_layer/index.d.ts +181 -123
  83. package/api/rpc/data_layer/index.js +23 -2
  84. package/api/rpc/farmer/index.d.ts +52 -55
  85. package/api/rpc/full_node/index.d.ts +140 -154
  86. package/api/rpc/full_node/index.js +2 -9
  87. package/api/rpc/harvester/index.d.ts +31 -34
  88. package/api/rpc/index.d.ts +7 -7
  89. package/api/rpc/index.js +10 -7
  90. package/api/rpc/pool/index.d.ts +13 -13
  91. package/api/rpc/wallet/index.d.ts +649 -644
  92. package/api/rpc/wallet/index.js +13 -13
  93. package/api/types.d.ts +3 -3
  94. package/api/ws/chia_plots_create/index.d.ts +7 -7
  95. package/api/ws/crawler/index.d.ts +9 -9
  96. package/api/ws/daemon/index.d.ts +159 -154
  97. package/api/ws/daemon/index.js +9 -2
  98. package/api/ws/farmer/index.d.ts +34 -34
  99. package/api/ws/full_node/index.d.ts +17 -17
  100. package/api/ws/harvester/index.d.ts +19 -19
  101. package/api/ws/index.d.ts +2 -2
  102. package/api/ws/index.js +2 -1
  103. package/api/ws/timelord/index.d.ts +14 -14
  104. package/api/ws/wallet/index.d.ts +22 -22
  105. package/bin/cli.js +3 -3
  106. package/config/index.d.ts +1 -1
  107. package/config/index.js +3 -3
  108. package/daemon/connection.js +9 -10
  109. package/daemon/index.d.ts +6 -6
  110. package/daemon/index.js +21 -21
  111. package/index.js +5 -1
  112. package/logger.d.ts +3 -3
  113. package/package.json +3 -3
  114. package/rpc/index.d.ts +6 -4
  115. package/rpc/index.js +29 -29
  116. /package/api/chia/pool/{store.js → record.js} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,8 +1,142 @@
1
1
  # Changelog
2
2
 
3
+ ## [14.1.0]
4
+ ### Changed
5
+ -`get_network_info` RPC API is now commonized and available in addition to `full_node` and `wallet`.
6
+ - [DataLayer RPC API](./src/api/rpc/data_layer)
7
+ - [`get_keys`](./src/api/rpc/data_layer/README.md#get_keysagent-params)
8
+ - Added `page` to request parameter
9
+ - Added `max_page_size` to request parameter
10
+ - Added `total_pages`, `total_bytes` and `root_hash` to response
11
+ - [`get_keys_values`](./src/api/rpc/data_layer/README.md#get_keys_valuesagent-params)
12
+ - Added `page` to request parameter
13
+ - Added `max_page_size` to request parameter
14
+ - Added `total_pages`, `total_bytes` and `root_hash` to response
15
+ - [`batch_update`](./src/api/rpc/data_layer/README.md#batch_updateagent-params)
16
+ - Added `submit_on_chain` to request parameter
17
+ - Made `tx_id` in response optional
18
+ - [`get_kv_diff`](./src/api/rpc/data_layer/README.md#get_kv_diffagent-params)
19
+ - Added `page` to request parameter
20
+ - Added `max_page_size` to request parameter
21
+ - Added `total_pages` and `total_bytes` to response
22
+ - [Wallet RPC API](./src/api/rpc/wallet)
23
+ - [`push_transactions`](./src/api/rpc/wallet/README.md#push_transactionsagent-params)
24
+ - A request parameter `transactions` is allowed to be `TransactionRecordConvenience[]`
25
+ - [`create_new_wallet`](./src/api/rpc/wallet/README.md#create_new_walletagent-params)
26
+ - `transactions` is added to response for `cat_wallet` if `mode` in request is `new`
27
+ - `transactions` is added to response for `dao_wallet`
28
+ - `transactions` is added to response for `pool_wallet` if `mode` in request is `new`
29
+ - [`send_transaction`](./src/api/rpc/wallet/README.md#send_transactionagent-params)
30
+ - Changed the type of `fee` to `uint64` and made it optional
31
+ - Added `transactions` to response
32
+ - [`send_transaction_multi`](./src/api/rpc/wallet/README.md#send_transaction_multiagent-params)
33
+ - Simplified `TSendTransactionMultiRequest`
34
+ - Added `transactions` to response
35
+ - [`spend_clawback_coins`](./src/api/rpc/wallet/README.md#spend_clawback_coinsagent-params)
36
+ - Added `transactions` to response
37
+ - [`send_notification`](./src/api/rpc/wallet/README.md#send_notificationagent-params)
38
+ - Added `transactions` to response
39
+ - [`cat_spend`](./src/api/rpc/wallet/README.md#cat_spendagent-params)
40
+ - Added `transactions` to response
41
+ - [`create_offer_for_ids`](./src/api/rpc/wallet/README.md#create_offer_for_idsagent-params)
42
+ - Added `transactions` to response
43
+ - [`take_offer`](./src/api/rpc/wallet/README.md#take_offeragent-params)
44
+ - Added `transactions` to response
45
+ - [`cancel_offer`](./src/api/rpc/wallet/README.md#cancel_offeragent-params)
46
+ - Added `transactions` to response
47
+ - [`cancel_offers`](./src/api/rpc/wallet/README.md#cancel_offersagent-params)
48
+ - Added `transactions` to response
49
+ - [`did_update_recovery_ids`](./src/api/rpc/wallet/README.md#did_update_recovery_idsagent-params)
50
+ - Added `transactions` to response
51
+ - [`did_message_spend`](./src/api/rpc/wallet/README.md#did_message_spendagent-params)
52
+ - Added `transactions` to response
53
+ - [`did_update_metadata`](./src/api/rpc/wallet/README.md#did_update_metadataagent-params)
54
+ - Added `transactions` to response
55
+ - [`did_recovery_spend`](./src/api/rpc/wallet/README.md#did_recovery_spendagent-params)
56
+ - Added `transactions` to response
57
+ - [`did_create_attest`](./src/api/rpc/wallet/README.md#did_create_attestagent-params)
58
+ - Added `transactions` to response
59
+ - [`did_transfer_did`](./src/api/rpc/wallet/README.md#did_transfer_didagent-params)
60
+ - Added `transactions` to response
61
+ - [`dao_add_funds_to_treasury`](./src/api/rpc/wallet/README.md#dao_add_funds_to_treasuryagent-params)
62
+ - Added `transactions` to response
63
+ - [`dao_send_to_lockup`](./src/api/rpc/wallet/README.md#dao_send_to_lockupagent-params)
64
+ - Added `transactions` to response
65
+ - [`dao_exit_lockup`](./src/api/rpc/wallet/README.md#dao_exit_lockupagent-params)
66
+ - Added `transactions` to response
67
+ - [`dao_create_proposal`](./src/api/rpc/wallet/README.md#dao_create_proposalagent-params)
68
+ - Added `transactions` to response
69
+ - [`dao_vote_on_proposal`](./src/api/rpc/wallet/README.md#dao_vote_on_proposalagent-params)
70
+ - Added `transactions` to response
71
+ - [`dao_close_proposal`](./src/api/rpc/wallet/README.md#dao_close_proposalagent-params)
72
+ - Added `transactions` to response
73
+ - [`dao_free_coins_from_finished_proposals`](./src/api/rpc/wallet/README.md#dao_free_coins_from_finished_proposalsagent-params)
74
+ - Added `transactions` to response
75
+ - [`nft_mint_nft`](./src/api/rpc/wallet/README.md#nft_mint_nftagent-params)
76
+ - Added `transactions` to response
77
+ - [`nft_set_nft_did`](./src/api/rpc/wallet/README.md#nft_set_nft_didagent-params)
78
+ - Added `transactions` to response
79
+ - [`nft_set_did_bulk`](./src/api/rpc/wallet/README.md#nft_set_did_bulkagent-params)
80
+ - Added `transactions` to response
81
+ - [`nft_transfer_bulk`](./src/api/rpc/wallet/README.md#nft_transfer_bulkagent-params)
82
+ - Added `transactions` to response
83
+ - [`nft_transfer_nft`](./src/api/rpc/wallet/README.md#nft_transfer_nftagent-params)
84
+ - Added `transactions` to response
85
+ - [`nft_add_uri`](./src/api/rpc/wallet/README.md#nft_add_uriagent-params)
86
+ - Added `transactions` to response
87
+ - [`nft_mint_bulk`](./src/api/rpc/wallet/README.md#nft_mint_bulkagent-params)
88
+ - Added `transactions` to response
89
+ - [`create_signed_transaction`](./src/api/rpc/wallet/README.md#create_signed_transactionagent-params)
90
+ - Added `morph_bytes` to request parameter
91
+ - Added `transactions` to response
92
+ - [`pw_join_pool`](./src/api/rpc/wallet/README.md#pw_join_poolagent-params)
93
+ - Added `transactions` to response
94
+ - [`pw_self_pool`](./src/api/rpc/wallet/README.md#pw_self_poolagent-params)
95
+ - Added `transactions` to response
96
+ - [`pw_absorb_rewards`](./src/api/rpc/wallet/README.md#pw_absorb_rewardsagent-params)
97
+ - Added `transactions` to response
98
+ - [`dl_update_root`](./src/api/rpc/wallet/README.md#dl_update_rootagent-params)
99
+ - Added `transactions` to response
100
+ - [`dl_update_multiple`](./src/api/rpc/wallet/README.md#dl_update_multipleagent-params)
101
+ - Added `transactions` to response
102
+ - Moved `TxEndpoint` to [src/chia/rpc/util.ts](./src/api/chia/rpc/util.ts) (Previously `src/chia/wallet/util/tx_config.ts`)
103
+ - Renamed `TxEndPoint` to `TXEndpointRequest`
104
+ - Renamed `TxEndpointForCompat` to `TXEndpointForCompat`
105
+ - Renamed `TxConfigLoader` to `TXConfigLoader`
106
+ - Changed the types of `passed` and `closed` in ProposalInfo` to `bool` (Previously they were `Optional<bool>`)
107
+ As a result, the RPC APIs below are affected
108
+ - `dao_get_proposals` of Wallet RPC API
109
+ - `dao_adjust_filter_level` of Wallet RPC API
110
+ - Upgraded dependencies and replaced `yarn.lock` with `pnpm-lock.yaml`
111
+ - Moved `FarmerRecord` to [src/chia/pool/record.ts](./src/api/chia/pool/record.ts) (
112
+ Previously `src/chia/pool/store.ts`)
113
+ ### Added
114
+ - [Daemon WebSocket API](./src/api/ws/daemon)
115
+ - [`get_network_info`](./src/api/ws/daemon/README.md#get_network_infodaemon)
116
+ - [Common RPC API](./src/api/rpc/common)
117
+ - [`get_network_info`](./src/api/rpc/common/README.md#get_network_infoagent)
118
+ - [DataLayer RPC API](./src/api/rpc/data_layer)
119
+ - [`submit_pending_root`](./src/api/rpc/data_layer/README.md#submit_pending_rootagent-params)
120
+ ### Fixed
121
+ - Renamed `ReceiveBlockResult` to `AddBlockResult` (type `ReceiveBlockResult` is still available to avoid breaking change)
122
+ - Fixed an invalid `TCreate_New_DAO_WalletRequest` README location.
123
+ - Fixed an issue where `pubkey` and `pubhash` in request of Wallet RPC API `did_recovery_spend` was not optional in the API doc.
124
+ - Fixed lint errors
125
+ ### Removed
126
+ - [FullNode RPC API](./src/api/rpc/data_layer)
127
+ - `get_network_info_of_full_node`
128
+ - [Wallet RPC API](./src/api/rpc/wallet)
129
+ - `get_network_info_of_wallet`
130
+ - Removed empty request parameter types like `{}`
131
+
3
132
  ## [14.0.0]
4
133
  ### Breaking change
5
134
  - When RPC API responds with `success: false`, its `Promise` now does `reject`. (Previously it does `resolve`)
135
+ - At chia-blockchain@2.2.1, in `chia/consensus/cost_calculator.py`,
136
+ `NPCResult.cost` was removed.
137
+ As a result, the RPC APIs below might be incompatible between `2.1.4` and `2.2.1`.
138
+ - `get_all_mempool_items` of FullNode RPC API
139
+ - `get_mempool_item_by_tx_id` of FullNode RPC API
6
140
  ### Changed
7
141
  - Loosened a type of `agent` to call RPC APIs. RPC APIs can be invoked with `agent` which just implements
8
142
  `sendMessage` method depicted as below.
@@ -15,6 +149,36 @@ export interface APIAgent {
15
149
  ): Promise<M>;
16
150
  }
17
151
  ```
152
+ - `sp_source_data` was added to [`NewSignagePoint`](./src/api/chia/protocols/farmer_protocol.ts)
153
+ As a result the following API responses were affected
154
+ - [`on_signage_point`](./src/api/ws/full_node/README.md#on_signage_point)
155
+ - [`on_new_signage_point`](./src/api/ws/farmer/README.md#on_new_signage_point)
156
+ - `include_signature_source_data` was added to [`DeclareProofOfSpace`](./src/api/chia/protocols/farmer_protocol.ts)
157
+ As a result the following API responses were affected
158
+ - [`on_proof`](./src/api/ws/farmer/README.md#on_proof)
159
+ - `foliage_block_data`, `foliage_transaction_block_data` and `rc_block_unfinished` were added to [`RequestSignedValues`](./src/api/chia/protocols/farmer_protocol.ts)
160
+ - `eligible_for_fast_forward` was added to [`BundleCoinSpend`](./src/api/chia/types/mempool_item.ts)
161
+ - `CHIP_0002_P2_DELEGATED_CONDITIONS` was added to [`SigningMode`](./src/api/chia/types/signing_mode.ts)
162
+ As a result the following API responses were affected
163
+ - [`verify_signature`](./src/api/rpc/wallet/README.md#verify_signatureagent-params)
164
+ - [`sign_message_by_address`](./src/api/rpc/wallet/README.md#sign_message_by_addressagent-params)
165
+ - [`sign_message_by_id`](./src/api/rpc/wallet/README.md#sign_message_by_idagent-params)
166
+ - [Wallet RPC API](./src/api/rpc/wallet)
167
+ - [`get_notifications`](./src/api/rpc/wallet/README.md#get_notificationsagent-params)
168
+ - The types of request parameters were slightly changed
169
+ - `ids` are now `bytes32[]` (previously `str[]`)
170
+ - `start` are now `uint32` (previously `int[]`)
171
+ - `end` are now `uint32` (previously `int[]`)
172
+ - The types of response parameters were slightly changed
173
+ - `id` are now `bytes32` (previously `str`)
174
+ - `message` are now `bytes` (previously `str`)
175
+ - [`get_offer_summary`](./src/api/rpc/wallet/README.md#get_offer_summaryagent-params)
176
+ - The following properties were added to the response parameters
177
+ - `additions: str[]`
178
+ - `removals: str[]`
179
+ - [`nft_get_info`](./src/api/rpc/wallet/README.md#nft_get_infoagent-params)
180
+ - The following properties were removed from the response parameters
181
+ - `ignore_size_limit`
18
182
  ### Added
19
183
  - Added connectivity options for `RPCAgent`.
20
184
  - `keepAlive` (default: `true`)
@@ -54,11 +218,16 @@ const httpsAgent = new HttpsAgent({
54
218
  const agent = new RPCAgent({httpsAgent: httpsAgent}); // `new RPCAgent({httpAgent: httpAgent});` is also allowed.
55
219
  const res = await get_plots(agent);
56
220
  ```
221
+ - [DataLayer RPC API](./src/api/rpc/data_layer)
222
+ - [`get_proof`](./src/api/rpc/data_layer/README.md#get_proofagent-params)
223
+ - [`verify_proof`](./src/api/rpc/data_layer/README.md#verify_proofagent-params)
57
224
  - [FullNode RPC API](./src/api/rpc/full_node)
58
225
  - [`get_aggsig_additional_data`](./src/api/rpc/full_node/README.md#get_aggsig_additional_dataagent)
59
-
226
+ - [Wallet RPC API](./src/api/rpc/wallet)
227
+ - [`dl_verify_proof`](./src/api/rpc/wallet/README.md#dl_verify_proofagent-params)
60
228
  ### Fixed
61
229
  - Fixed an issue where some of the RPC Pool APIs did not handle request parameters correctly.
230
+ - Added missing attribute `peak_height` to [`NewSignagePoint`](./src/api/chia/protocols/farmer_protocol.ts)
62
231
 
63
232
  ## [13.2.0]
64
233
  ### Added
@@ -1345,7 +1514,7 @@ daemon.sendMessage(destination, get_block_record_by_height_command, data);
1345
1514
  Initial release.
1346
1515
 
1347
1516
  <!-- [Unreleased]: https://github.com/Chia-Mine/chia-agent/compare/v0.0.1...v0.0.2 -->
1348
-
1517
+ [14.1.0]: https://github.com/Chia-Mine/chia-agent/compare/v14.0.0...v14.1.0
1349
1518
  [14.0.0]: https://github.com/Chia-Mine/chia-agent/compare/v13.2.0...v14.0.0
1350
1519
  [13.2.0]: https://github.com/Chia-Mine/chia-agent/compare/v13.1.0...v13.2.0
1351
1520
  [13.1.0]: https://github.com/Chia-Mine/chia-agent/compare/v13.0.1...v13.1.0
package/LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  The MIT License
2
2
 
3
- Copyright (c) 2019 Admin ChiaMineJP <admin@chiamine.jp>
3
+ Copyright (c) 2024 Izumi Hoshino <admin@chiamine.jp>
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
package/README.md CHANGED
@@ -2,7 +2,7 @@
2
2
  [![npm version](https://badge.fury.io/js/chia-agent.svg)](https://badge.fury.io/js/chia-agent) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
3
3
 
4
4
  chia rpc/websocket client library for NodeJS.
5
- Supports all RPC/Websocket API available at `chia 2.1.2/2.1.3/2.1.4`.
5
+ Supports all RPC/Websocket API available at `chia 2.3.0`.
6
6
  \(If you need previous version, search for the corresponding release [here](https://github.com/Chia-Mine/chia-agent/releases)\)
7
7
 
8
8
  you can develop your own nodejs script with `chia-agent` to:
@@ -22,10 +22,10 @@ yarn add chia-agent
22
22
 
23
23
  ## Compatibility
24
24
  This code is compatible with:
25
- - [`b5fe5020ec75b29e91a399b6648ff0a1a683ca04`](https://github.com/Chia-Network/chia-blockchain/tree/b5fe5020ec75b29e91a399b6648ff0a1a683ca04) of [chia-blockchain 2.1.4](https://github.com/Chia-Network/chia-blockchain)
26
- - [Diff to the main branch of chia-blockchain](https://github.com/Chia-Network/chia-blockchain/compare/b5fe5020ec75b29e91a399b6648ff0a1a683ca04...main)
27
- - [`6c1c7ecd2ed7307760d1673dc2b1057f22e08fd5`](https://github.com/Chia-Network/pool-reference/tree/6c1c7ecd2ed7307760d1673dc2b1057f22e08fd5) of [pool-reference](https://github.com/Chia-Network/pool-reference)
28
- - [Diff to the main branch of pool-reference](https://github.com/Chia-Network/pool-reference/compare/6c1c7ecd2ed7307760d1673dc2b1057f22e08fd5...main)
25
+ - [`5ec14169475030d00767a821b674f76407f7f075`](https://github.com/Chia-Network/chia-blockchain/tree/5ec14169475030d00767a821b674f76407f7f075) of [chia-blockchain 2.3.0](https://github.com/Chia-Network/chia-blockchain)
26
+ - [Diff to the main branch of chia-blockchain](https://github.com/Chia-Network/chia-blockchain/compare/5ec14169475030d00767a821b674f76407f7f075...main)
27
+ - [`66cfc09e01b8b3590efab6928867a6b463c5e557`](https://github.com/Chia-Network/pool-reference/tree/66cfc09e01b8b3590efab6928867a6b463c5e557) of [pool-reference](https://github.com/Chia-Network/pool-reference)
28
+ - [Diff to the main branch of pool-reference](https://github.com/Chia-Network/pool-reference/compare/66cfc09e01b8b3590efab6928867a6b463c5e557...main)
29
29
 
30
30
  ## API
31
31
  There are 2 kinds of APIs in chia.
package/agent/index.d.ts CHANGED
@@ -1,3 +1,3 @@
1
1
  export interface APIAgent {
2
- sendMessage<M extends unknown>(destination: string, command: string, data?: Record<string, unknown>): Promise<M>;
2
+ sendMessage<M>(destination: string, command: string, data?: Record<string, unknown>): Promise<M>;
3
3
  }
@@ -3,7 +3,7 @@ import { ClassgroupElement } from "../types/blockchain_format/classgroup";
3
3
  import { Coin } from "../types/blockchain_format/coin";
4
4
  import { SubEpochSummary } from "../types/blockchain_format/sub_epoch_summary";
5
5
  import { bool, Optional, uint128, uint32, uint64, uint8 } from "../types/_python_types_";
6
- export declare type BlockRecord = {
6
+ export type BlockRecord = {
7
7
  header_hash: bytes32;
8
8
  prev_hash: bytes32;
9
9
  height: uint32;
@@ -1 +1,2 @@
1
- export declare type ReceiveBlockResult = 1 | 2 | 3 | 4 | 5;
1
+ export type AddBlockResult = 1 | 2 | 3 | 4 | 5;
2
+ export type ReceiveBlockResult = AddBlockResult;
@@ -1,7 +1,6 @@
1
1
  import { SpendBundleConditions } from "../types/spend_bundle_condition";
2
- import { Optional, uint16, uint64 } from "../types/_python_types_";
3
- export declare type NPCResult = {
2
+ import { Optional, uint16 } from "../types/_python_types_";
3
+ export type NPCResult = {
4
4
  error: Optional<uint16>;
5
5
  conds: Optional<SpendBundleConditions>;
6
- cost: uint64;
7
6
  };
@@ -1,49 +1,82 @@
1
- import { int, Optional, str } from "../types/_python_types_";
1
+ import { bool, int, Optional, str, uint8 } from "../types/_python_types_";
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
- export declare type KeyValueMarshalled = {
3
+ export type KeyValueMarshalled = {
4
4
  key: str;
5
5
  value: str;
6
6
  };
7
- export declare type OfferStoreMarshalled = {
7
+ export type OfferStoreMarshalled = {
8
8
  store_id: str;
9
9
  inclusions: KeyValueMarshalled[];
10
10
  };
11
- export declare type StoreProofsMarshalled = {
11
+ export type StoreProofsMarshalled = {
12
12
  store_id: str;
13
13
  proofs: ProofMarshalled[];
14
14
  };
15
- export declare type ProofMarshalled = {
15
+ export type ProofMarshalled = {
16
16
  key: str;
17
17
  value: str;
18
18
  node_hash: str;
19
19
  layers: LayerMarshalled[];
20
20
  };
21
- export declare type LayerMarshalled = {
21
+ export type LayerMarshalled = {
22
22
  other_hash_side: "left" | "right";
23
23
  other_hash: str;
24
24
  combined_hash: str;
25
25
  };
26
- export declare type OfferMarshalled = {
26
+ export type OfferMarshalled = {
27
27
  trade_id: str;
28
28
  offer: str;
29
29
  taker: OfferStoreMarshalled[];
30
30
  maker: StoreProofsMarshalled[];
31
31
  };
32
- export declare type SyncStatus = {
32
+ export type SyncStatus = {
33
33
  root_hash: bytes32;
34
34
  generation: int;
35
35
  target_root_hash: bytes32;
36
36
  target_generation: int;
37
37
  };
38
- export declare type PluginStatusMarshalled = {
38
+ export type PluginStatusMarshalled = {
39
39
  plugin_status: {
40
40
  uploaders: Record<str, Record<str, any>>;
41
41
  downloaders: Record<str, Record<str, any>>;
42
42
  };
43
43
  };
44
- export declare type RootMarshalled = {
44
+ export type RootMarshalled = {
45
45
  tree_id: str;
46
46
  node_hash: Optional<str>;
47
47
  generation: int;
48
48
  status: int;
49
49
  };
50
+ export type ProofLayer = {
51
+ other_hash_side: uint8;
52
+ other_hash: bytes32;
53
+ combined_hash: bytes32;
54
+ };
55
+ export type HashOnlyProof = {
56
+ key_clvm_hash: bytes32;
57
+ value_clvm_hash: bytes32;
58
+ node_hash: bytes32;
59
+ layers: ProofLayer[];
60
+ };
61
+ export type KeyValueHashes = {
62
+ key_clvm_hash: bytes32;
63
+ value_clvm_hash: bytes32;
64
+ };
65
+ export type ProofResultInclusions = {
66
+ store_id: bytes32;
67
+ inclusions: KeyValueHashes[];
68
+ };
69
+ export type StoreProofsHashes = {
70
+ store_id: bytes32;
71
+ proofs: HashOnlyProof[];
72
+ };
73
+ export type DLProof = {
74
+ store_proofs: StoreProofsHashes;
75
+ coin_id: bytes32;
76
+ inner_puzzle_hash: bytes32;
77
+ };
78
+ export type VerifyProofResponse = {
79
+ verified_clvm_hashes: ProofResultInclusions;
80
+ current_root: bool;
81
+ success: bool;
82
+ };
@@ -1,7 +1,7 @@
1
1
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
2
2
  import { bool, str, uint32, uint64 } from "../types/_python_types_";
3
3
  import { LineageProof } from "../wallet/lineage_proof";
4
- export declare type SingletonRecord = {
4
+ export type SingletonRecord = {
5
5
  coin_id: bytes32;
6
6
  launcher_id: bytes32;
7
7
  root: bytes32;
@@ -12,7 +12,7 @@ export declare type SingletonRecord = {
12
12
  generation: uint32;
13
13
  timestamp: uint64;
14
14
  };
15
- export declare type Mirror = {
15
+ export type Mirror = {
16
16
  coin_id: str;
17
17
  launcher_id: str;
18
18
  amount: uint64;
@@ -1,7 +1,7 @@
1
1
  import { float, int, str, uint32, uint64, uint8 } from "../types/_python_types_";
2
2
  import { PoolWalletConfig } from "../pools/pool_config";
3
3
  import { ErrorResponse } from "../protocols/pool_protocol";
4
- export declare type PoolState = {
4
+ export type PoolState = {
5
5
  points_found_since_start: int;
6
6
  points_found_24h: Array<[uint32, uint64]>;
7
7
  points_acknowledged_since_start: int;
@@ -1,6 +1,6 @@
1
1
  import { VDFInfo, VDFProof } from "../types/blockchain_format/vdf";
2
2
  import { Optional } from "../types/_python_types_";
3
- export declare type SignagePoint = {
3
+ export type SignagePoint = {
4
4
  cc_vdf: Optional<VDFInfo>;
5
5
  cc_proof: Optional<VDFProof>;
6
6
  rc_vdf: Optional<VDFInfo>;
@@ -1,6 +1,6 @@
1
1
  import { bytes, G1Element, int, Optional, str } from "../types/_python_types_";
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
- export declare type Plot = {
3
+ export type Plot = {
4
4
  filename: str;
5
5
  size: int;
6
6
  plot_id: bytes;
@@ -2,8 +2,8 @@ import { bytes32 } from "../types/blockchain_format/sized_bytes";
2
2
  import { bool, float, int, None, Optional, str, uint32 } from "../types/_python_types_";
3
3
  import { Plot } from "../protocols/harvester_protocol";
4
4
  import { HarvestingMode } from "../plotting/util";
5
- export declare type MayBeSummary<S, O> = S extends true ? int : O;
6
- export declare type Receiver<SUMMARY extends boolean = false> = {
5
+ export type MayBeSummary<S, O> = S extends true ? int : O;
6
+ export type Receiver<SUMMARY extends boolean = false> = {
7
7
  connection: {
8
8
  node_id: bytes32;
9
9
  host: str;
@@ -1,6 +1,6 @@
1
1
  import { bool, str } from "../types/_python_types_";
2
2
  export declare const display_name = "BladeBit Plotter";
3
- export declare type bladebit_install_info = {
3
+ export type bladebit_install_info = {
4
4
  display_name: typeof display_name;
5
5
  version?: str;
6
6
  installed: bool;
@@ -1,6 +1,6 @@
1
1
  import { bool, str } from "../types/_python_types_";
2
2
  export declare const display_name = "Chia Proof of Space";
3
- export declare type chiapos_install_info = {
3
+ export type chiapos_install_info = {
4
4
  display_name: typeof display_name;
5
5
  version: str;
6
6
  installed: bool;
@@ -1,6 +1,6 @@
1
1
  import { bool, str } from "../types/_python_types_";
2
2
  export declare const display_name = "madMAx Plotter";
3
- export declare type madmax_install_info = {
3
+ export type madmax_install_info = {
4
4
  display_name: typeof display_name;
5
5
  version?: str;
6
6
  installed: bool;
@@ -1,3 +1,3 @@
1
- export declare type CPU_HARVESTING = 1;
2
- export declare type GPU_HARVESTING = 2;
3
- export declare type HarvestingMode = CPU_HARVESTING | GPU_HARVESTING;
1
+ export type CPU_HARVESTING = 1;
2
+ export type GPU_HARVESTING = 2;
3
+ export type HarvestingMode = CPU_HARVESTING | GPU_HARVESTING;
@@ -2,7 +2,7 @@ import { bytes32 } from "../types/blockchain_format/sized_bytes";
2
2
  import { bool, G1Element, str, uint64 } from "../types/_python_types_";
3
3
  import { CoinSpend } from "../types/coin_spend";
4
4
  import { PoolState } from "../pools/pool_wallet_info";
5
- export declare type FarmerRecord = {
5
+ export type FarmerRecord = {
6
6
  launcher_id: bytes32;
7
7
  p2_singleton_puzzle_hash: bytes32;
8
8
  delay_time: uint64;
@@ -1,6 +1,6 @@
1
1
  import { G1Element, str } from "../types/_python_types_";
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
- export declare type PoolWalletConfig = {
3
+ export type PoolWalletConfig = {
4
4
  launcher_id: bytes32;
5
5
  pool_url: str;
6
6
  payout_instructions: str;
@@ -2,7 +2,7 @@ import { G1Element, Optional, str, uint32, uint8 } from "../types/_python_types_
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
3
  import { Coin } from "../types/blockchain_format/coin";
4
4
  import { Program } from "../types/blockchain_format/program";
5
- export declare type PoolState = {
5
+ export type PoolState = {
6
6
  version: uint8;
7
7
  state: uint8;
8
8
  target_puzzle_hash: bytes32;
@@ -10,7 +10,7 @@ export declare type PoolState = {
10
10
  pool_url: Optional<str>;
11
11
  relative_lock_height: uint32;
12
12
  };
13
- export declare type PoolWalletInfo = {
13
+ export type PoolWalletInfo = {
14
14
  current: PoolState;
15
15
  target: Optional<PoolState>;
16
16
  launcher_coin: Coin;
@@ -1,16 +1,34 @@
1
- import { G2Element, Optional, uint32, uint64, uint8 } from "../types/_python_types_";
1
+ import { bool, G2Element, Optional, uint32, uint64, uint8 } from "../types/_python_types_";
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
3
  import { ProofOfSpace } from "../types/blockchain_format/proof_of_space";
4
4
  import { PoolTarget } from "../types/blockchain_format/pool_target";
5
- export declare type NewSignagePoint = {
5
+ import { ClassgroupElement } from "../types/blockchain_format/classgroup";
6
+ import { ChallengeChainSubSlot, RewardChainSubSlot } from "../types/blockchain_format/slots";
7
+ import { FoliageBlockData, FoliageTransactionBlock } from "../types/blockchain_format/foliage";
8
+ import { RewardChainBlockUnfinished } from "../types/blockchain_format/reward_chain_block";
9
+ export type SPSubSlotSourceData = {
10
+ cc_sub_slot: ChallengeChainSubSlot;
11
+ rc_sub_slot: RewardChainSubSlot;
12
+ };
13
+ export type SPVDFSourceData = {
14
+ cc_vdf: ClassgroupElement;
15
+ rc_vdf: ClassgroupElement;
16
+ };
17
+ export type SignagePointSourceData = {
18
+ sub_slot_data: Optional<SPSubSlotSourceData>;
19
+ vdf_data: Optional<SPVDFSourceData>;
20
+ };
21
+ export type NewSignagePoint = {
6
22
  challenge_hash: bytes32;
7
23
  challenge_chain_sp: bytes32;
8
24
  reward_chain_sp: bytes32;
9
25
  difficulty: uint64;
10
26
  sub_slot_iters: uint64;
11
27
  signage_point_index: uint8;
28
+ peak_height: uint32;
29
+ sp_source_data: Optional<SignagePointSourceData>;
12
30
  };
13
- export declare type DeclareProofOfSpace = {
31
+ export type DeclareProofOfSpace = {
14
32
  challenge_hash: bytes32;
15
33
  challenge_chain_sp: bytes32;
16
34
  signage_point_index: uint8;
@@ -21,13 +39,17 @@ export declare type DeclareProofOfSpace = {
21
39
  farmer_puzzle_hash: bytes32;
22
40
  pool_target: Optional<PoolTarget>;
23
41
  pool_signature: Optional<G2Element>;
42
+ include_signature_source_data: bool;
24
43
  };
25
- export declare type RequestSignedValues = {
44
+ export type RequestSignedValues = {
26
45
  quality_string: bytes32;
27
46
  foliage_block_data_hash: bytes32;
28
47
  foliage_transaction_block_hash: bytes32;
48
+ foliage_block_data: Optional<FoliageBlockData>;
49
+ foliage_transaction_block_data: Optional<FoliageTransactionBlock>;
50
+ rc_block_unfinished: Optional<RewardChainBlockUnfinished>;
29
51
  };
30
- export declare type FarmingInfo = {
52
+ export type FarmingInfo = {
31
53
  challenge_hash: bytes32;
32
54
  sp_hash: bytes32;
33
55
  timestamp: uint64;
@@ -36,7 +58,7 @@ export declare type FarmingInfo = {
36
58
  total_plots: uint32;
37
59
  lookup_time: uint64;
38
60
  };
39
- export declare type SignedValues = {
61
+ export type SignedValues = {
40
62
  quality_string: bytes32;
41
63
  foliage_block_data_signature: G2Element;
42
64
  foliage_transaction_block_signature: G2Element;
@@ -1,6 +1,6 @@
1
1
  import { G1Element, Optional, str, uint64, uint8 } from "../types/_python_types_";
2
2
  import { bytes32 } from "../types/blockchain_format/sized_bytes";
3
- export declare type Plot = {
3
+ export type Plot = {
4
4
  filename: str;
5
5
  size: uint8;
6
6
  plot_id: bytes32;