chia-agent 16.1.6 → 18.0.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.
- package/CHANGELOG.md +90 -0
- package/README.md +7 -7
- package/api/chia/protocols/harvester_protocol.d.ts +15 -0
- package/api/chia/protocols/outbound_message.d.ts +1 -1
- package/api/chia/protocols/solver_protocol.d.ts +14 -0
- package/api/chia/protocols/solver_protocol.js +2 -0
- package/api/chia/rpc/wallet_request_types.d.ts +1 -0
- package/api/chia/types/coin_spend.d.ts +3 -2
- package/api/chia/wallet/transaction_record.d.ts +10 -9
- package/api/chia_rs/chia-consensus/owned_conditions.d.ts +4 -0
- package/api/chia_rs/chia-protocol/partial_proof.d.ts +4 -0
- package/api/chia_rs/chia-protocol/partial_proof.js +2 -0
- package/api/chia_rs/chia-protocol/reward_chain_block.d.ts +1 -0
- package/api/chia_rs/chia-protocol/sub_epoch_summary.d.ts +1 -0
- package/api/rpc/farmer/index.d.ts +17 -3
- package/api/rpc/farmer/index.js +6 -1
- package/api/rpc/index.d.ts +4 -2
- package/api/rpc/index.js +20 -22
- package/api/rpc/solver/index.d.ts +15 -0
- package/api/rpc/solver/index.js +9 -0
- package/api/rpc/wallet/index.d.ts +63 -133
- package/api/rpc/wallet/index.js +4 -29
- package/api/ws/daemon/index.d.ts +1 -1
- package/package.json +1 -1
- package/rpc/index.d.ts +1 -1
- package/rpc/index.js +3 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,93 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [18.0.0]
|
|
4
|
+
Support for [`chia-blockchain@2.6.0`](https://github.com/Chia-Network/chia-blockchain/releases/tag/2.6.0)
|
|
5
|
+
|
|
6
|
+
### Breaking change
|
|
7
|
+
- `create_new_wallet`
|
|
8
|
+
- The response `type` is now the `WalletType` name string (`"CAT"`, `"DECENTRALIZED_ID"`, `"NFT"`, `"POOLING_WALLET"`)
|
|
9
|
+
instead of the integer enum value
|
|
10
|
+
- Pool wallet `mode: "recovery"` was removed
|
|
11
|
+
- Pool wallet response now includes `type`
|
|
12
|
+
- `asset_id`, `coin_name`, `newpuzhash`, `pubkey`, `launcher_id` and `p2_singleton_puzzle_hash` in responses
|
|
13
|
+
are now `0x`-prefixed hex
|
|
14
|
+
- The `{success: false, error: "invalid request"}` success-path variant was removed
|
|
15
|
+
(invalid requests now produce a standard RPC error response)
|
|
16
|
+
- `get_offer_summary`
|
|
17
|
+
- `summary.offered` / `summary.requested` amounts are now JSON strings (were numbers)
|
|
18
|
+
- `additions` / `removals` are now `0x`-prefixed hex
|
|
19
|
+
- DataLayer offer summaries are now typed as `TDataLayerOfferSummary`
|
|
20
|
+
- `create_signed_transaction` / `send_transaction_multi`
|
|
21
|
+
- Per-announcement `morph_bytes` was removed; only the top-level `morph_bytes` is applied
|
|
22
|
+
- All transaction endpoints now require a fully synced wallet
|
|
23
|
+
(may fail with `"Wallet needs to be fully synced before making transactions."`)
|
|
24
|
+
- `split_coins` with `number_of_coins == 0` and `combine_coins` with `number_of_coins < 2` now error
|
|
25
|
+
|
|
26
|
+
### Added
|
|
27
|
+
- [Harvester Protocol](./src/api/chia/protocols/harvester_protocol.ts)
|
|
28
|
+
- `PartialProofsData`: `partial_proofs` is now `PartialProof[]`; added `strength` and `plot_id`
|
|
29
|
+
- `Plot`: added `compression_level`; for v2 plots `size` now encodes `0x80 | strength`
|
|
30
|
+
- [Solver Protocol](./src/api/chia/protocols/solver_protocol.ts)
|
|
31
|
+
- `SolverInfo` is now `{partial_proof: PartialProof, plot_id, strength, size}`
|
|
32
|
+
- `SolverResponse.partial_proof` is now `PartialProof`
|
|
33
|
+
- Added `PartialProof` type (mirrors `chia_rs`)
|
|
34
|
+
|
|
35
|
+
### Changed
|
|
36
|
+
- Synchronized `chia_rs` type definitions with `chia_rs@0.35.2`
|
|
37
|
+
- `SubEpochSummary`: added `challenge_merkle_root`
|
|
38
|
+
- `RewardChainBlock`: added `header_mmr_root`
|
|
39
|
+
- `create_offer_for_ids`: `offer` dictionary values are canonically strings now (`Record<str, str | int>`)
|
|
40
|
+
- `get_transactions`: `start` / `end` widened to `uint32`
|
|
41
|
+
- `get_all_offers`: `start` / `end` are now bounded to `uint16`
|
|
42
|
+
|
|
43
|
+
## [17.0.0]
|
|
44
|
+
Support for [`chia-blockchain@2.5.7`](https://github.com/Chia-Network/chia-blockchain/releases/tag/2.5.7)
|
|
45
|
+
|
|
46
|
+
### Breaking change
|
|
47
|
+
- The following deprecated DID Wallet RPC APIs were removed (removed in chia-blockchain 2.5.7):
|
|
48
|
+
- `did_update_recovery_ids`
|
|
49
|
+
- `did_recovery_spend`
|
|
50
|
+
- `did_get_recovery_list`
|
|
51
|
+
- `did_create_attest`
|
|
52
|
+
- `did_get_information_needed_for_recovery`
|
|
53
|
+
- `TransactionRecord` wire format changed (chia-blockchain 2.5.7 now serializes transaction records
|
|
54
|
+
with plain `to_json_dict()`; the previous "convenience" format was removed)
|
|
55
|
+
- `memos` is now `Record<str, bytes[]>` (`{"0x<coin_id>": ["0x<memo>", ...]}`), previously `Array<[bytes32, bytes[]]>`
|
|
56
|
+
- `to_address` is now a regular field of `TransactionRecord`
|
|
57
|
+
- `TransactionRecordConvenience` and `TransactionRecordConvenienceWithMetadata` are deprecated aliases of
|
|
58
|
+
`TransactionRecord` and the new `TransactionRecordWithMetadata`
|
|
59
|
+
- [`get_block_spends_with_conditions`](./src/api/rpc/full_node/README.md#get_block_spends_with_conditionsagent-params)
|
|
60
|
+
- `conditions` are now serialized as `Array<[opcode: int, args: bytes[]]>` instead of `{opcode, vars}` objects
|
|
61
|
+
- `create_new_wallet` with `wallet_type: "did_wallet"` and `did_type: "new"` no longer accepts
|
|
62
|
+
`backup_dids` / `num_of_backup_ids_needed`
|
|
63
|
+
- `cat_spend`: `extra_delta` is now `str` (was `int`)
|
|
64
|
+
- Wallet responses of `get_wallets` / `get_wallet_balance(s)` now always include previously-omitted keys
|
|
65
|
+
(`fingerprint`, `asset_id`, `pending_approval_balance`, `authorized_providers`, `flags_needed`) with `null` defaults,
|
|
66
|
+
and serialize `bytes`-like values as `0x`-prefixed hex
|
|
67
|
+
|
|
68
|
+
### Added
|
|
69
|
+
- New `solver` RPC service support (introduced in chia-blockchain 2.5.7)
|
|
70
|
+
- [`get_state`](./src/api/rpc/solver/README.md#get_stateagent)
|
|
71
|
+
- `RPCAgent` now accepts `service: "solver"`
|
|
72
|
+
- `chia_solver` was added to daemon `TService`
|
|
73
|
+
- New Farmer RPC API [`connect_to_solver`](./src/api/rpc/farmer/README.md#connect_to_solveragent-params)
|
|
74
|
+
- `add_key`: new optional `label` request parameter
|
|
75
|
+
- `get_farmed_amount`: new optional `include_pool_rewards` request parameter
|
|
76
|
+
- [Harvester Protocol](./src/api/chia/protocols/harvester_protocol.ts): added `PartialProofsData`
|
|
77
|
+
- New [Solver Protocol](./src/api/chia/protocols/solver_protocol.ts): `SolverInfo`, `SolverResponse`
|
|
78
|
+
- `NodeType`: added `SOLVER = 8`
|
|
79
|
+
|
|
80
|
+
### Changed
|
|
81
|
+
- Synchronized `chia_rs` type definitions with `chia_rs@0.30.0`
|
|
82
|
+
- `SpendConditions`: added `fingerprint`
|
|
83
|
+
- `SpendBundleConditions`: added `num_atoms`, `num_pairs`, `heap_size`
|
|
84
|
+
- `send_notification`: `amount` is now optional (defaults to 0)
|
|
85
|
+
- `spend_clawback_coins`: `batch_size` is now optional `uint16`
|
|
86
|
+
- `get_transactions`: `start` / `end` are now `uint16`
|
|
87
|
+
- `get_next_address`: `new_address` is now optional
|
|
88
|
+
- `cat_asset_id_to_name`: unknown asset ids now resolve to `{wallet_id: null, name: null}` instead of an error
|
|
89
|
+
- `verify_signature`: `error` key is now always present (`null` on success)
|
|
90
|
+
|
|
3
91
|
## [16.1.6]
|
|
4
92
|
### Security
|
|
5
93
|
- Hardened the supply chain against compromised dependency releases
|
|
@@ -1954,6 +2042,8 @@ daemon.sendMessage(destination, get_block_record_by_height_command, data);
|
|
|
1954
2042
|
Initial release.
|
|
1955
2043
|
|
|
1956
2044
|
<!-- [Unreleased]: https://github.com/Chia-Mine/chia-agent/compare/v0.0.1...v0.0.2 -->
|
|
2045
|
+
[18.0.0]: https://github.com/Chia-Mine/chia-agent/compare/v17.0.0...v18.0.0
|
|
2046
|
+
[17.0.0]: https://github.com/Chia-Mine/chia-agent/compare/v16.1.6...v17.0.0
|
|
1957
2047
|
[16.1.6]: https://github.com/Chia-Mine/chia-agent/compare/v16.1.5...v16.1.6
|
|
1958
2048
|
[16.1.5]: https://github.com/Chia-Mine/chia-agent/compare/v16.1.4...v16.1.5
|
|
1959
2049
|
[16.1.4]: https://github.com/Chia-Mine/chia-agent/compare/v16.1.3...v16.1.4
|
package/README.md
CHANGED
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
[](https://badge.fury.io/js/chia-agent) [](https://opensource.org/licenses/MIT)
|
|
3
3
|
|
|
4
4
|
chia rpc/websocket client library for NodeJS.
|
|
5
|
-
Supports all RPC/Websocket API available at `2.
|
|
5
|
+
Supports all RPC/Websocket API available at `2.6.0` of [`chia-blockchain`](https://github.com/Chia-Network/chia-blockchain/).
|
|
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:
|
|
9
|
-
- retrieve latest data from RPC servers like `farmer`, `harvester`, `full_node`, `wallet`, `pool`, `data_layer`, `crawler`.
|
|
9
|
+
- retrieve latest data from RPC servers like `farmer`, `harvester`, `full_node`, `wallet`, `pool`, `data_layer`, `crawler`, `solver`.
|
|
10
10
|
- send email when proof is found.
|
|
11
11
|
- trigger scripts when target event is observed.
|
|
12
12
|
- start/stop services.
|
|
@@ -22,10 +22,10 @@ yarn add chia-agent
|
|
|
22
22
|
|
|
23
23
|
## Compatibility
|
|
24
24
|
This code is compatible with:
|
|
25
|
-
- [`
|
|
26
|
-
- [Diff to the main branch of chia-blockchain](https://github.com/Chia-Network/chia-blockchain/compare/
|
|
27
|
-
- [`
|
|
28
|
-
- [Diff to the main branch of chia_rs](https://github.com/Chia-Network/chia_rs/compare/
|
|
25
|
+
- [`a73171a119f27d3e94409f1a523207fd151b4b69`](https://github.com/Chia-Network/chia-blockchain/tree/a73171a119f27d3e94409f1a523207fd151b4b69) of [chia-blockchain 2.6.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/a73171a119f27d3e94409f1a523207fd151b4b69...main)
|
|
27
|
+
- [`a1d5fbcb15a12e3b5bde96d633e2e5419d7632f0`](https://github.com/Chia-Network/chia_rs/tree/a1d5fbcb15a12e3b5bde96d633e2e5419d7632f0) of [chia_rs 0.35.2](https://github.com/Chia-Network/chia_rs)
|
|
28
|
+
- [Diff to the main branch of chia_rs](https://github.com/Chia-Network/chia_rs/compare/a1d5fbcb15a12e3b5bde96d633e2e5419d7632f0...main)
|
|
29
29
|
- [`ef49150171cc243b09c0e5d5cb27f2249ffa3793`](https://github.com/Chia-Network/pool-reference/tree/ef49150171cc243b09c0e5d5cb27f2249ffa3793) of [pool-reference](https://github.com/Chia-Network/pool-reference)
|
|
30
30
|
- [Diff to the main branch of pool-reference](https://github.com/Chia-Network/pool-reference/compare/ef49150171cc243b09c0e5d5cb27f2249ffa3793...main)
|
|
31
31
|
|
|
@@ -34,7 +34,7 @@ There are 2 kinds of APIs in chia.
|
|
|
34
34
|
`RPC API` and `Websocket API`.
|
|
35
35
|
|
|
36
36
|
### RPC API
|
|
37
|
-
RPC API is used to send message directly to chia services like `farmer`, `harvester`, `full_node`, `wallet`, `data_layer`, `crawler`.
|
|
37
|
+
RPC API is used to send message directly to chia services like `farmer`, `harvester`, `full_node`, `wallet`, `data_layer`, `crawler`, `solver`.
|
|
38
38
|
|
|
39
39
|
RPC API is just an async function in a traditional request/response style.
|
|
40
40
|
|
|
@@ -2,6 +2,20 @@ import { Optional, str } from "../types/_python_types_";
|
|
|
2
2
|
import { G1Element } from "../../chia_rs/chia-bls/lib";
|
|
3
3
|
import { uint64, uint8 } from "../../chia_rs/wheel/python/sized_ints";
|
|
4
4
|
import { bytes32 } from "../../chia_rs/wheel/python/sized_bytes";
|
|
5
|
+
import { PartialProof } from "../../chia_rs/chia-protocol/partial_proof";
|
|
6
|
+
export type PartialProofsData = {
|
|
7
|
+
challenge_hash: bytes32;
|
|
8
|
+
sp_hash: bytes32;
|
|
9
|
+
plot_identifier: str;
|
|
10
|
+
partial_proofs: PartialProof[];
|
|
11
|
+
signage_point_index: uint8;
|
|
12
|
+
plot_size: uint8;
|
|
13
|
+
strength: uint8;
|
|
14
|
+
plot_id: bytes32;
|
|
15
|
+
pool_public_key: Optional<G1Element>;
|
|
16
|
+
pool_contract_puzzle_hash: Optional<bytes32>;
|
|
17
|
+
plot_public_key: G1Element;
|
|
18
|
+
};
|
|
5
19
|
export type Plot = {
|
|
6
20
|
filename: str;
|
|
7
21
|
size: uint8;
|
|
@@ -11,4 +25,5 @@ export type Plot = {
|
|
|
11
25
|
plot_public_key: G1Element;
|
|
12
26
|
file_size: uint64;
|
|
13
27
|
time_modified: uint64;
|
|
28
|
+
compression_level: Optional<uint8>;
|
|
14
29
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export type NodeType = 1 | 2 | 3 | 4 | 5 | 6 | 7;
|
|
1
|
+
export type NodeType = 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { bytes } from "../types/_python_types_";
|
|
2
|
+
import { uint8 } from "../../chia_rs/wheel/python/sized_ints";
|
|
3
|
+
import { bytes32 } from "../../chia_rs/wheel/python/sized_bytes";
|
|
4
|
+
import { PartialProof } from "../../chia_rs/chia-protocol/partial_proof";
|
|
5
|
+
export type SolverInfo = {
|
|
6
|
+
partial_proof: PartialProof;
|
|
7
|
+
plot_id: bytes32;
|
|
8
|
+
strength: uint8;
|
|
9
|
+
size: uint8;
|
|
10
|
+
};
|
|
11
|
+
export type SolverResponse = {
|
|
12
|
+
partial_proof: PartialProof;
|
|
13
|
+
proof: bytes;
|
|
14
|
+
};
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { bytes } from "./_python_types_";
|
|
2
|
+
import { int } from "../../chia_rs/wheel/python/sized_ints";
|
|
2
3
|
import { CoinSpend } from "../../chia_rs/chia-protocol/coin_spend";
|
|
3
4
|
export type CoinSpendWithConditions = {
|
|
4
5
|
coin_spend: CoinSpend;
|
|
5
|
-
conditions:
|
|
6
|
+
conditions: Array<[int, bytes[]]>;
|
|
6
7
|
};
|
|
@@ -21,18 +21,19 @@ export type TransactionRecordOld = {
|
|
|
21
21
|
trade_id: Optional<bytes32>;
|
|
22
22
|
type: uint32;
|
|
23
23
|
name: bytes32;
|
|
24
|
-
memos:
|
|
24
|
+
memos: Record<str, bytes[]>;
|
|
25
25
|
};
|
|
26
26
|
export type TransactionRecord = TransactionRecordOld & {
|
|
27
|
+
to_address: str;
|
|
27
28
|
valid_times: ConditionValidTimes;
|
|
28
29
|
};
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
export type TransactionRecordConvenienceWithMetadata = {
|
|
34
|
-
metadata: ClawbackMetadata & {
|
|
30
|
+
/** @deprecated Use {@link TransactionRecord} instead */
|
|
31
|
+
export type TransactionRecordConvenience = TransactionRecord;
|
|
32
|
+
export type TransactionRecordWithMetadata = TransactionRecord & {
|
|
33
|
+
metadata: Optional<ClawbackMetadata & {
|
|
35
34
|
coin_id: str;
|
|
36
35
|
spent: bool;
|
|
37
|
-
}
|
|
38
|
-
}
|
|
36
|
+
}>;
|
|
37
|
+
};
|
|
38
|
+
/** @deprecated Use {@link TransactionRecordWithMetadata} instead */
|
|
39
|
+
export type TransactionRecordConvenienceWithMetadata = TransactionRecordWithMetadata;
|
|
@@ -24,6 +24,7 @@ export type SpendConditions = {
|
|
|
24
24
|
flags: uint32;
|
|
25
25
|
execution_cost: uint64;
|
|
26
26
|
condition_cost: uint64;
|
|
27
|
+
fingerprint: bytes;
|
|
27
28
|
};
|
|
28
29
|
export type SpendBundleConditions = {
|
|
29
30
|
spends: SpendConditions[];
|
|
@@ -39,4 +40,7 @@ export type SpendBundleConditions = {
|
|
|
39
40
|
validated_signature: bool;
|
|
40
41
|
execution_cost: uint64;
|
|
41
42
|
condition_cost: uint64;
|
|
43
|
+
num_atoms: uint32;
|
|
44
|
+
num_pairs: uint32;
|
|
45
|
+
heap_size: uint32;
|
|
42
46
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ProofOfSpace } from "../../chia_rs/chia-protocol/proof_of_space";
|
|
2
|
-
import { bool, Optional, str } from "../../chia/types/_python_types_";
|
|
2
|
+
import { bool, False, Optional, str, True } from "../../chia/types/_python_types_";
|
|
3
3
|
import { int, uint32, uint64, uint8 } from "../../chia_rs/wheel/python/sized_ints";
|
|
4
4
|
import { bytes32 } from "../../chia_rs/wheel/python/sized_bytes";
|
|
5
5
|
import { TRPCAgent } from "../../../rpc/index";
|
|
@@ -177,5 +177,19 @@ export type TGetPoolLinkResponse = {
|
|
|
177
177
|
};
|
|
178
178
|
export type WsGetPoolLinkMessage = GetMessageType<chia_farmer_service, get_pool_login_link_command, TGetPoolLinkResponse>;
|
|
179
179
|
export declare function get_pool_login_link<T extends TRPCAgent | TDaemon>(agent: T, params: TGetPoolLinkRequest): Promise<ResType<T, TGetPoolLinkResponse, WsGetPoolLinkMessage>>;
|
|
180
|
-
export
|
|
181
|
-
export type
|
|
180
|
+
export declare const connect_to_solver_command = "connect_to_solver";
|
|
181
|
+
export type connect_to_solver_command = typeof connect_to_solver_command;
|
|
182
|
+
export type TConnectToSolverRequest = {
|
|
183
|
+
host: str;
|
|
184
|
+
port: int;
|
|
185
|
+
};
|
|
186
|
+
export type TConnectToSolverResponse = {
|
|
187
|
+
success: True;
|
|
188
|
+
} | {
|
|
189
|
+
success: False;
|
|
190
|
+
error: str;
|
|
191
|
+
};
|
|
192
|
+
export type WsConnectToSolverMessage = GetMessageType<chia_farmer_service, connect_to_solver_command, TConnectToSolverResponse>;
|
|
193
|
+
export declare function connect_to_solver<T extends TRPCAgent | TDaemon>(agent: T, params: TConnectToSolverRequest): Promise<ResType<T, TConnectToSolverResponse, WsConnectToSolverMessage>>;
|
|
194
|
+
export type RpcFarmerMessage = TGetRewardTargetResponse | TGetSignagePointResponse | TGetSignagePointsResponse | TSetRewardTargetResponse | TGetHarvestersResponse | TGetHarvestersSummaryResponse | TGetHarvesterPlotsValidResponse | TGetHarvesterPlotsInvalidResponse | TGetHarvesterPlotsKeysMissingResponse | TGetHarvesterPlotsDuplicatesResponse | TSetPayoutInstructionsResponse | TGetPoolStateResponse | TGetPoolLinkResponse | TConnectToSolverResponse;
|
|
195
|
+
export type RpcFarmerMessageOnWs = WsGetRewardTargetsMessage | WsGetSignagePointMessage | WsGetSignagePointsMessage | WsSetRewardTargetsMessage | WsGetHarvestersMessage | WsGetHarvestersSummaryMessage | WsGetHarvesterPlotsValidMessage | WsGetHarvesterPlotsInvalidMessage | WsGetHarvesterPlotsKeysMissingMessage | WsGetHarvesterPlotsDuplicatesMessage | WsSetPayoutInstructionsMessage | WsGetPoolStateMessage | WsGetPoolLinkMessage | WsConnectToSolverMessage;
|
package/api/rpc/farmer/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.get_pool_login_link_command = exports.get_harvester_plots_duplicates_command = exports.get_harvester_plots_keys_missing_command = exports.get_harvester_plots_invalid_command = exports.get_harvester_plots_valid_command = exports.get_harvesters_summary_command = exports.get_harvesters_command = exports.set_payout_instructions_command = exports.get_pool_state_command = exports.set_reward_targets_command = exports.get_reward_targets_command = exports.get_signage_points_command = exports.get_signage_point_command = exports.chia_farmer_service = void 0;
|
|
3
|
+
exports.connect_to_solver_command = exports.get_pool_login_link_command = exports.get_harvester_plots_duplicates_command = exports.get_harvester_plots_keys_missing_command = exports.get_harvester_plots_invalid_command = exports.get_harvester_plots_valid_command = exports.get_harvesters_summary_command = exports.get_harvesters_command = exports.set_payout_instructions_command = exports.get_pool_state_command = exports.set_reward_targets_command = exports.get_reward_targets_command = exports.get_signage_points_command = exports.get_signage_point_command = exports.chia_farmer_service = void 0;
|
|
4
4
|
exports.get_signage_point = get_signage_point;
|
|
5
5
|
exports.get_signage_points = get_signage_points;
|
|
6
6
|
exports.get_reward_targets = get_reward_targets;
|
|
@@ -14,6 +14,7 @@ exports.get_harvester_plots_invalid = get_harvester_plots_invalid;
|
|
|
14
14
|
exports.get_harvester_plots_keys_missing = get_harvester_plots_keys_missing;
|
|
15
15
|
exports.get_harvester_plots_duplicates = get_harvester_plots_duplicates;
|
|
16
16
|
exports.get_pool_login_link = get_pool_login_link;
|
|
17
|
+
exports.connect_to_solver = connect_to_solver;
|
|
17
18
|
exports.chia_farmer_service = "chia_farmer";
|
|
18
19
|
exports.get_signage_point_command = "get_signage_point";
|
|
19
20
|
async function get_signage_point(agent, params) {
|
|
@@ -67,3 +68,7 @@ exports.get_pool_login_link_command = "get_pool_login_link";
|
|
|
67
68
|
async function get_pool_login_link(agent, params) {
|
|
68
69
|
return agent.sendMessage(exports.chia_farmer_service, exports.get_pool_login_link_command, params);
|
|
69
70
|
}
|
|
71
|
+
exports.connect_to_solver_command = "connect_to_solver";
|
|
72
|
+
async function connect_to_solver(agent, params) {
|
|
73
|
+
return agent.sendMessage(exports.chia_farmer_service, exports.connect_to_solver_command, params);
|
|
74
|
+
}
|
package/api/rpc/index.d.ts
CHANGED
|
@@ -5,11 +5,13 @@ export { chia_full_node_service, TGetAdditionsAndRemovalsRequest, TGetAdditionsA
|
|
|
5
5
|
import type { RpcHarvesterMessage } from "./harvester/index";
|
|
6
6
|
export { chia_harvester_service, TAddPlotDirectoryRequest, TAddPlotDirectoryResponse, add_plot_directory, TDeletePlotRequest, TDeletePlotResponse, delete_plot, TGetPlotDirectoriesResponse, get_plot_directories, TGetPlotsResponse, get_plots, TRefreshPlotsResponse, refresh_plots, TRemovePlotDirectoryRequest, TRemovePlotDirectoryResponse, remove_plot_directory, TGetHarvesterConfigResponse, get_harvester_config, TUpdateHarvesterConfigRequest, TUpdateHarvesterConfigResponse, update_harvester_config, } from "./harvester/index";
|
|
7
7
|
import type { RpcWalletMessage } from "./wallet/index";
|
|
8
|
-
export { chia_wallet_service, TAddKeyRequest, TAddKeyResponse, add_key, TAddRateLimitedFundsRequest, TAddRateLimitedFundsResponse, add_rate_limited_funds, TAdditions, TCancelOfferRequest, TCancelOfferResponse, cancel_offer, TCancelOffersRequest, TCancelOffersResponse, cancel_offers, TCatGetAssetIdRequest, TCatGetAssetIdResponse, cat_get_asset_id, TCatGetNameRequest, TCatGetNameResponse, cat_get_name, TGetStrayCatsResponse, get_stray_cats, TCatAssetIdToNameRequest, TCatAssetIdToNameResponse, cat_asset_id_to_name, TCatSetNameRequest, TCatSetNameResponse, cat_set_name, TCatSpendRequest, TCatSpendResponse, cat_spend, TCheckOfferValidityRequest, TCheckOfferValidityResponse, check_offer_validity, TCreateNewWalletRequest, TCreateNewWalletResponse, create_new_wallet, TCreateOfferForIdsRequest, TCreateOfferForIdsResponse, create_offer_for_ids, TCreateSignedTransactionRequest, TCreateSignedTransactionResponse, create_signed_transaction, TDeleteUnconfirmedTransactionsRequest, TDeleteUnconfirmedTransactionsResponse, delete_unconfirmed_transactions, TSelectCoinsRequest, TSelectCoinsResponse, select_coins, TGetCurrentDerivationIndexResponse, get_current_derivation_index, TExtendDerivationIndexRequest, TExtendDerivationIndexResponse, extend_derivation_index, TGetNotificationsRequest, TGetNotificationsResponse, get_notifications, TDeleteNotificationsRequest, TDeleteNotificationsResponse, delete_notifications, TSendNotificationRequest, TSendNotificationResponse, send_notification, TSignMessageByAddressRequest, TSignMessageByAddressResponse, sign_message_by_address, TSignMessageByIdRequest, TSignMessageByIdResponse, sign_message_by_id, TVerifySignatureRequest, TVerifySignatureResponse, verify_signature, TGetTransactionMemoRequest, TGetTransactionMemoResponse, get_transaction_memo, TSplitCoinsRequest, TSplitCoinsResponse, split_coins, TCombineCoinsRequest, TCombineCoinsResponse, combine_coins, TNftCalculateRoyaltiesRequest, TNftCalculateRoyaltiesResponse, nft_calculate_royalties, TNftMintBulkRequest, TNftMintBulkResponse, nft_mint_bulk, TNftSetDidBulkRequest, TNftSetDidBulkResponse, nft_set_did_bulk, TNftTransferBulkRequest, TNftTransferBulkResponse, nft_transfer_bulk, TCreate_New_CAT_WalletRequest, TCreate_New_CAT_WalletResponse, TCreate_New_DID_WalletRequest, TCreate_New_DID_WalletResponse, TDeleteAllKeysResponse, delete_all_keys, TSetWalletResyncOnStartupRequest, TSetWalletResyncOnStartupResponse, set_wallet_resync_on_startup, TDeleteKeyRequest, TDeleteKeyResponse, delete_key, TDidSetWalletNameRequest, TDidSetWalletNameResponse, did_set_wallet_name, TDidGetWalletNameRequest, TDidGetWalletNameResponse, did_get_wallet_name,
|
|
8
|
+
export { chia_wallet_service, TAddKeyRequest, TAddKeyResponse, add_key, TAddRateLimitedFundsRequest, TAddRateLimitedFundsResponse, add_rate_limited_funds, TAdditions, TCancelOfferRequest, TCancelOfferResponse, cancel_offer, TCancelOffersRequest, TCancelOffersResponse, cancel_offers, TCatGetAssetIdRequest, TCatGetAssetIdResponse, cat_get_asset_id, TCatGetNameRequest, TCatGetNameResponse, cat_get_name, TGetStrayCatsResponse, get_stray_cats, TCatAssetIdToNameRequest, TCatAssetIdToNameResponse, cat_asset_id_to_name, TCatSetNameRequest, TCatSetNameResponse, cat_set_name, TCatSpendRequest, TCatSpendResponse, cat_spend, TCheckOfferValidityRequest, TCheckOfferValidityResponse, check_offer_validity, TCreateNewWalletRequest, TCreateNewWalletResponse, create_new_wallet, TCreateOfferForIdsRequest, TCreateOfferForIdsResponse, create_offer_for_ids, TCreateSignedTransactionRequest, TCreateSignedTransactionResponse, create_signed_transaction, TDeleteUnconfirmedTransactionsRequest, TDeleteUnconfirmedTransactionsResponse, delete_unconfirmed_transactions, TSelectCoinsRequest, TSelectCoinsResponse, select_coins, TGetCurrentDerivationIndexResponse, get_current_derivation_index, TExtendDerivationIndexRequest, TExtendDerivationIndexResponse, extend_derivation_index, TGetNotificationsRequest, TGetNotificationsResponse, get_notifications, TDeleteNotificationsRequest, TDeleteNotificationsResponse, delete_notifications, TSendNotificationRequest, TSendNotificationResponse, send_notification, TSignMessageByAddressRequest, TSignMessageByAddressResponse, sign_message_by_address, TSignMessageByIdRequest, TSignMessageByIdResponse, sign_message_by_id, TVerifySignatureRequest, TVerifySignatureResponse, verify_signature, TGetTransactionMemoRequest, TGetTransactionMemoResponse, get_transaction_memo, TSplitCoinsRequest, TSplitCoinsResponse, split_coins, TCombineCoinsRequest, TCombineCoinsResponse, combine_coins, TNftCalculateRoyaltiesRequest, TNftCalculateRoyaltiesResponse, nft_calculate_royalties, TNftMintBulkRequest, TNftMintBulkResponse, nft_mint_bulk, TNftSetDidBulkRequest, TNftSetDidBulkResponse, nft_set_did_bulk, TNftTransferBulkRequest, TNftTransferBulkResponse, nft_transfer_bulk, TCreate_New_CAT_WalletRequest, TCreate_New_CAT_WalletResponse, TCreate_New_DID_WalletRequest, TCreate_New_DID_WalletResponse, TDeleteAllKeysResponse, delete_all_keys, TSetWalletResyncOnStartupRequest, TSetWalletResyncOnStartupResponse, set_wallet_resync_on_startup, TDeleteKeyRequest, TDeleteKeyResponse, delete_key, TDidSetWalletNameRequest, TDidSetWalletNameResponse, did_set_wallet_name, TDidGetWalletNameRequest, TDidGetWalletNameResponse, did_get_wallet_name, TDidCreateBackupFileRequest, TDidCreateBackupFileResponse, did_create_backup_file, TDidTransferDidRequest, TDidTransferDidResponse, did_transfer_did, TDidGetDidRequest, TDidGetDidResponse, did_get_did, TDidGetCurrentCoinInfoRequest, TDidGetCurrentCoinInfoResponse, did_get_current_coin_info, TDidGetPubkeyRequest, TDidGetPubkeyResponse, did_get_pubkey, TDidGetMetadataRequest, TDidGetMetadataResponse, did_get_metadata, TDidSpendRequest, TDidSpendResponse, did_spend, TDidUpdateMetadataRequest, TDidUpdateMetadataResponse, did_update_metadata, TNftMintNftRequest, TNftMintNftResponse, nft_mint_nft, TNftCountNftsRequest, TNftCountNftsResponse, nft_count_nfts, TNftGetNftsRequest, TNftGetNftsResponse, nft_get_nfts, TNftSetNftDidRequest, TNftSetNftDidResponse, nft_set_nft_did, TNftGetByDidRequest, TNftGetByDidResponse, nft_get_by_did, TNftGetWalletDidRequest, TNftGetWalletDidResponse, nft_get_wallet_did, TNftGetWalletsWithDidsResponse, nft_get_wallets_with_dids, TNftSetNftStatusRequest, TNftSetNftStatusResponse, nft_set_nft_status, TNftTransferNftRequest, TNftTransferNftResponse, nft_transfer_nft, TNftGetInfoRequest, TNftGetInfoResponse, nft_get_info, TNftAddUriRequest, TNftAddUriResponse, nft_add_uri, TGetTimestampForHeightResponse, get_timestamp_for_height, TSetAutoClaimRequest, TSetAutoClaimResponse, set_auto_claim, TGetAutoClaimResponse, get_auto_claim, TGenerateMnemonicResponse, generate_mnemonic, TGetAllOffersRequest, TGetAllOffersResponse, get_all_offers, TGetCatListResponse, get_cat_list, TGetFarmedAmountResponse, get_farmed_amount, TGetHeightInfoResponse, get_height_info, TGetInitialFreezePeriodResponseOfWallet, get_initial_freeze_period_of_wallet, TGetLoggedInFingerprintResponse, get_logged_in_fingerprint, TGetOfferRequest, TGetOfferResponse, get_offer, TGetOffersCountResponse, get_offers_count, TGetOfferSummaryRequest, TGetOfferSummaryResponse, get_offer_summary, TGetNextAddressRequest, TGetNextAddressResponse, get_next_address, TGetPrivateKeyRequest, TGetPrivateKeyResponse, get_private_key, TGetPublicKeysResponse, get_public_keys, TGetSyncStatusResponse, get_sync_status, TGetTransactionCountRequest, TGetTransactionCountResponse, get_transaction_count, TGetTransactionRequest, TGetTransactionResponse, get_transaction, TGetTransactionsRequest, TGetTransactionsResponse, get_transactions, TGetWalletBalanceRequest, TGetWalletBalanceResponse, get_wallet_balance, TGetWalletBalancesRequest, TGetWalletBalancesResponse, get_wallet_balances, TGetWalletsRequest, TGetWalletsResponse, get_wallets, TLoginRequest, TLoginResponse, log_in, TPushTxRequest as TPushTxRequestOfWallet, TPushTxResponse as TPushTxResponseOfWallet, push_tx as push_tx_wallet, TPushTransactionsRequest, TPushTransactionsResponse, push_transactions, TPwJoinPoolRequest, TPwJoinPoolResponse, pw_join_pool, TPwSelfPoolRequest, TPwSelfPoolResponse, pw_self_pool, TPwAbsorbRewardsRequest, TPwAbsorbRewardsResponse, pw_absorb_rewards, TPwStatusRequest, TPwStatusResponse, pw_status, TRlSetUserInfoRequest, TRlSetUserInfoResponse, rl_set_user_info, TSendClawbackTransactionRequest, TSendClawbackTransactionResponse, send_clawback_transaction, TSendTransactionRequest, TSendTransactionResponse, send_transaction, TSendTransactionMultiRequest, TSendTransactionMultiResponse, send_transaction_multi, TSpendClawbackCoinsRequest, TSpendClawbackCoinsResponse, spend_clawback_coins, TGetCoinRecordsRequest, TGetCoinRecordsResponse, get_coin_records, TTakeOfferRequest, TTakeOfferResponse, take_offer, TCreateNewDlRequest, TCreateNewDlResponse, create_new_dl, TDlTrackNewRequest, TDlTrackNewResponse, dl_track_new, TDlStopTrackingRequest, TDlStopTrackingResponse, dl_stop_tracking, TDlLatestSingletonRequest, TDlLatestSingletonResponse, dl_latest_singleton, TDlSingletonsByRootRequest, TDlSingletonsByRootResponse, dl_singletons_by_root, TDlUpdateRootRequest, TDlUpdateRootResponse, dl_update_root, TDlUpdateMultipleRequest, TDlUpdateMultipleResponse, dl_update_multiple, TDlHistoryRequest, TDlHistoryResponse, dl_history, TDlOwnedSingletonsResponse, dl_owned_singletons, TDlGetMirrorsRequest, TDlGetMirrorsResponse, dl_get_mirrors, TDlNewMirrorRequest, TDlNewMirrorResponse, dl_new_mirror, TDlDeleteMirrorRequest, TDlDeleteMirrorResponse, dl_delete_mirror, TDlVerifyProofRequest, TDlVerifyProofResponse, dl_verify_proof, TVcMintRequest, TVcMintResponse, vc_mint, TVcGetRequest, TVcGetResponse, vc_get, TVcGetListRequest, TVcGetListResponse, vc_get_list, TVcSpendRequest, TVcSpendResponse, vc_spend, TVcAddProofsRequest, TVcAddProofsResponse, vc_add_proofs, TVcGetProofsForRootRequest, TVcGetProofsForRootResponse, vc_get_proofs_for_root, TVcRevokeRequest, TVcRevokeResponse, vc_revoke, TCrcatApprovePendingRequest, TCrcatApprovePendingResponse, crcat_approve_pending, TGatherSigningInfoRequest, TGatherSigningInfoResponse, gather_signing_info, TApplySignaturesRequest, TApplySignaturesResponse, apply_signatures, TSubmitTransactionsRequest, TSubmitTransactionsResponse, submit_transactions, TExecuteSigningInstructionsRequest, TExecuteSigningInstructionsResponse, execute_signing_instructions, } from "./wallet/index";
|
|
9
9
|
import type { RpcDataLayerMessage } from "./data_layer/index";
|
|
10
10
|
export { chia_data_layer_service, TWalletLogInRequest, TWalletLogInResponse, wallet_log_in, TCreateDataStoreRequest, TCreateDataStoreResponse, create_data_store, TGetOwnedStoresResponse, get_owned_stores, TBatchUpdateRequest, TBatchUpdateResponse, batch_update, TMultistoreBatchUpdateRequest, TMultistoreBatchUpdateResponse, multistore_batch_update, TSubmitPendingRootResponse, TSubmitPendingRootRequest, submit_pending_root, TSubmitAllPendingRootsRequest, TSubmitAllPendingRootsResponse, submit_all_pending_roots, TGetValueRequest, TGetValueResponse, get_value, TGetKeysRequest, TGetKeysResponse, get_keys, TGetKeysValuesRequest, TGetKeysValuesResponse, get_keys_values, TGetAncestorsRequest, TGetAncestorsResponse, get_ancestors, TGetRootRequest, TGetRootResponse, get_root, TGetLocalRootRequest, TGetLocalRootResponse, get_local_root, TGetRootsRequest, TGetRootsResponse, get_roots, TDeleteKeyRequest as TDeleteKeyDLRequest, TDeleteKeyResponse as TDeleteKeyDLResponse, delete_key as delete_key_dl, TInsertRequest, TInsertResponse, insert, TSubscribeRequest, TSubscribeResponse, subscribe, TUnsubscribeRequest, TUnsubscribeResponse, unsubscribe, TAddMirrorRequest, TAddMirrorResponse, add_mirror, TDeleteMirrorRequest, TDeleteMirrorResponse, delete_mirror, TGetMirrorsRequest, TGetMirrorsResponse, get_mirrors, TRemoveSubscriptionsRequest, TRemoveSubscriptionsResponse, remove_subscriptions, TSubscriptionsResponse, subscriptions, TGetKvDiffRequest, TGetKvDiffResponse, get_kv_diff, TGetRootHistoryRequest, TGetRootHistoryResponse, get_root_history, TAddMissingFilesRequest, TAddMissingFilesResponse, add_missing_files, TMakeOfferRequest, TMakeOfferResponse, make_offer, TTakeOfferRequest as TTakeOfferRequestDL, TTakeOfferResponse as TTakeOfferResponseDL, take_offer as take_offer_dl, TVerifyOfferRequest, TVerifyOfferResponse, verify_offer, TCancelOfferRequest as TCancelOfferRequestDL, TCancelOfferResponse as TCancelOfferResponseDL, cancel_offer as cancel_offer_dl, TGetSyncStatusRequest as TGetSyncStatusRequestDL, TGetSyncStatusResponse as TGetSyncStatusResponseDL, get_sync_status as get_sync_status_dl, TCheckPluginsResponse, check_plugins, TClearPendingRootsRequest, TClearPendingRootsResponse, clear_pending_roots, TGetProofRequest, TGetProofResponse, get_proof, TVerifyProofRequest, TVerifyProofResponse, verify_proof, } from "./data_layer/index";
|
|
11
11
|
import type { RpcCrawlerMessage } from "./crawler/index";
|
|
12
12
|
export { chia_crawler_service, TGetIpsAfterTimestampRequest, TGetIpsAfterTimestampResponse, TGetPeerCountsResponse, get_ips_after_timestamp, get_peer_counts, } from "./crawler/index";
|
|
13
|
+
import type { RpcSolverMessage } from "./solver/index";
|
|
14
|
+
export { chia_solver_service, TGetStateResponse, get_state, } from "./solver/index";
|
|
13
15
|
import type { RpcCommonMessage } from "./common/index";
|
|
14
16
|
export { chia_common_service, TGetNetworkInfoResponse, TGetConnectionsRequest, TGetConnectionsResponse, TOpenConnectionRequest, TOpenConnectionResponse, TCloseConnectionRequest, TCloseConnectionResponse, TStopNodeResponse, TGetRoutesResponse, TGetVersionResponse, THealthzResponse, TGetLogLevelResponse, TSetLogLevelResponse, TResetLogLevelResponse, get_network_info, get_connections, open_connection, close_connection, stop_node, get_routes, get_version, healthz, get_log_level, set_log_level, reset_log_level, } from "./common/index";
|
|
15
|
-
export type RpcMessage = RpcFarmerMessage | RpcFullNodeMessage | RpcHarvesterMessage | RpcWalletMessage | RpcDataLayerMessage | RpcCrawlerMessage | RpcCommonMessage;
|
|
17
|
+
export type RpcMessage = RpcFarmerMessage | RpcFullNodeMessage | RpcHarvesterMessage | RpcWalletMessage | RpcDataLayerMessage | RpcCrawlerMessage | RpcSolverMessage | RpcCommonMessage;
|
package/api/rpc/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.get_all_coins = exports.get_farming_ph = exports.get_auto_farming = exports.set_auto_farming = exports.farm_block = exports.get_all_blocks = exports.get_fee_estimate = exports.get_puzzle_and_solution = exports.push_tx = exports.get_unfinished_block_headers = exports.get_network_space = exports.get_mempool_item_by_tx_id = exports.get_initial_freeze_period_of_full_node = exports.get_coin_records_by_hint = exports.get_coin_records_by_parent_ids = exports.get_coin_records_by_puzzle_hashes = exports.get_coin_records_by_puzzle_hash = exports.get_coin_record_by_name = exports.get_coin_records_by_names = exports.get_recent_signage_point_or_eos = exports.get_block_count_metrics = exports.get_blocks = exports.get_blockchain_state = exports.get_block = exports.get_block_spends_with_conditions = exports.get_block_spends = exports.get_block_records = exports.get_block_record = exports.get_block_record_by_height = exports.create_block_generator = exports.get_mempool_items_by_coin_name = exports.get_all_mempool_tx_ids = exports.get_all_mempool_items = exports.get_aggsig_additional_data = exports.get_additions_and_removals = exports.chia_full_node_service = exports.get_pool_login_link = exports.get_pool_state = exports.set_pool_payout_instructions = exports.get_harvester_plots_duplicates = exports.get_harvester_plots_keys_missing = exports.get_harvester_plots_invalid = exports.get_harvester_plots_valid = exports.get_harvesters_summary = exports.get_harvesters = exports.set_reward_targets = exports.get_signage_points = exports.get_signage_point = exports.get_reward_targets = exports.chia_farmer_service = void 0;
|
|
4
|
-
exports.
|
|
5
|
-
exports.pw_join_pool = exports.push_transactions = exports.push_tx_wallet = exports.log_in = exports.get_wallets = exports.get_wallet_balances = exports.get_wallet_balance = exports.get_transactions = exports.get_transaction = exports.get_transaction_count = exports.get_sync_status = exports.get_public_keys = exports.get_private_key = exports.get_next_address = exports.get_offer_summary = exports.get_offers_count = exports.get_offer = exports.get_logged_in_fingerprint = exports.get_initial_freeze_period_of_wallet = exports.get_height_info = exports.get_farmed_amount = exports.get_cat_list = exports.get_all_offers = exports.generate_mnemonic = exports.get_auto_claim = exports.set_auto_claim = exports.get_timestamp_for_height = exports.nft_add_uri = exports.nft_get_info = exports.nft_transfer_nft = exports.nft_set_nft_status = exports.nft_get_wallets_with_dids = exports.nft_get_wallet_did = exports.nft_get_by_did = exports.nft_set_nft_did = exports.nft_get_nfts = exports.nft_count_nfts = exports.nft_mint_nft = exports.did_update_metadata = exports.
|
|
6
|
-
exports.get_roots = exports.get_local_root = exports.get_root = exports.get_ancestors = exports.get_keys_values = exports.get_keys = exports.get_value = exports.submit_all_pending_roots = exports.submit_pending_root = exports.multistore_batch_update = exports.batch_update = exports.get_owned_stores = exports.create_data_store = exports.wallet_log_in = exports.chia_data_layer_service = exports.execute_signing_instructions = exports.submit_transactions = exports.apply_signatures = exports.gather_signing_info = exports.crcat_approve_pending = exports.vc_revoke = exports.vc_get_proofs_for_root = exports.vc_add_proofs = exports.vc_spend = exports.vc_get_list = exports.vc_get = exports.vc_mint = exports.dl_verify_proof = exports.dl_delete_mirror = exports.dl_new_mirror = exports.dl_get_mirrors = exports.dl_owned_singletons = exports.dl_history = exports.dl_update_multiple = exports.dl_update_root = exports.dl_singletons_by_root = exports.dl_latest_singleton = exports.dl_stop_tracking = exports.dl_track_new = exports.create_new_dl = exports.take_offer = exports.get_coin_records = exports.spend_clawback_coins = exports.send_transaction_multi = exports.send_transaction =
|
|
7
|
-
exports.reset_log_level = exports.set_log_level = exports.get_log_level = exports.healthz = exports.get_version = exports.get_routes = exports.stop_node = exports.close_connection = exports.open_connection = exports.get_connections = exports.get_network_info = exports.chia_common_service = exports.get_peer_counts = exports.get_ips_after_timestamp = exports.chia_crawler_service = exports.verify_proof = exports.get_proof = exports.clear_pending_roots = exports.check_plugins = exports.get_sync_status_dl = exports.cancel_offer_dl = exports.verify_offer = exports.take_offer_dl = exports.make_offer = exports.add_missing_files = exports.get_root_history = exports.get_kv_diff = exports.subscriptions = exports.remove_subscriptions = exports.get_mirrors = exports.delete_mirror =
|
|
4
|
+
exports.did_create_backup_file = exports.did_get_wallet_name = exports.did_set_wallet_name = exports.delete_key = exports.set_wallet_resync_on_startup = exports.delete_all_keys = exports.nft_transfer_bulk = exports.nft_set_did_bulk = exports.nft_mint_bulk = exports.nft_calculate_royalties = exports.combine_coins = exports.split_coins = exports.get_transaction_memo = exports.verify_signature = exports.sign_message_by_id = exports.sign_message_by_address = exports.send_notification = exports.delete_notifications = exports.get_notifications = exports.extend_derivation_index = exports.get_current_derivation_index = exports.select_coins = exports.delete_unconfirmed_transactions = exports.create_signed_transaction = exports.create_offer_for_ids = exports.create_new_wallet = exports.check_offer_validity = exports.cat_spend = exports.cat_set_name = exports.cat_asset_id_to_name = exports.get_stray_cats = exports.cat_get_name = exports.cat_get_asset_id = exports.cancel_offers = exports.cancel_offer = exports.add_rate_limited_funds = exports.add_key = exports.chia_wallet_service = exports.update_harvester_config = exports.get_harvester_config = exports.remove_plot_directory = exports.refresh_plots = exports.get_plots = exports.get_plot_directories = exports.delete_plot = exports.add_plot_directory = exports.chia_harvester_service = exports.reorg_blocks = exports.revert_blocks = exports.get_all_puzzle_hashes = void 0;
|
|
5
|
+
exports.send_clawback_transaction = exports.rl_set_user_info = exports.pw_status = exports.pw_absorb_rewards = exports.pw_self_pool = exports.pw_join_pool = exports.push_transactions = exports.push_tx_wallet = exports.log_in = exports.get_wallets = exports.get_wallet_balances = exports.get_wallet_balance = exports.get_transactions = exports.get_transaction = exports.get_transaction_count = exports.get_sync_status = exports.get_public_keys = exports.get_private_key = exports.get_next_address = exports.get_offer_summary = exports.get_offers_count = exports.get_offer = exports.get_logged_in_fingerprint = exports.get_initial_freeze_period_of_wallet = exports.get_height_info = exports.get_farmed_amount = exports.get_cat_list = exports.get_all_offers = exports.generate_mnemonic = exports.get_auto_claim = exports.set_auto_claim = exports.get_timestamp_for_height = exports.nft_add_uri = exports.nft_get_info = exports.nft_transfer_nft = exports.nft_set_nft_status = exports.nft_get_wallets_with_dids = exports.nft_get_wallet_did = exports.nft_get_by_did = exports.nft_set_nft_did = exports.nft_get_nfts = exports.nft_count_nfts = exports.nft_mint_nft = exports.did_update_metadata = exports.did_spend = exports.did_get_metadata = exports.did_get_pubkey = exports.did_get_current_coin_info = exports.did_get_did = exports.did_transfer_did = void 0;
|
|
6
|
+
exports.add_mirror = exports.unsubscribe = exports.subscribe = exports.insert = exports.delete_key_dl = exports.get_roots = exports.get_local_root = exports.get_root = exports.get_ancestors = exports.get_keys_values = exports.get_keys = exports.get_value = exports.submit_all_pending_roots = exports.submit_pending_root = exports.multistore_batch_update = exports.batch_update = exports.get_owned_stores = exports.create_data_store = exports.wallet_log_in = exports.chia_data_layer_service = exports.execute_signing_instructions = exports.submit_transactions = exports.apply_signatures = exports.gather_signing_info = exports.crcat_approve_pending = exports.vc_revoke = exports.vc_get_proofs_for_root = exports.vc_add_proofs = exports.vc_spend = exports.vc_get_list = exports.vc_get = exports.vc_mint = exports.dl_verify_proof = exports.dl_delete_mirror = exports.dl_new_mirror = exports.dl_get_mirrors = exports.dl_owned_singletons = exports.dl_history = exports.dl_update_multiple = exports.dl_update_root = exports.dl_singletons_by_root = exports.dl_latest_singleton = exports.dl_stop_tracking = exports.dl_track_new = exports.create_new_dl = exports.take_offer = exports.get_coin_records = exports.spend_clawback_coins = exports.send_transaction_multi = exports.send_transaction = void 0;
|
|
7
|
+
exports.reset_log_level = exports.set_log_level = exports.get_log_level = exports.healthz = exports.get_version = exports.get_routes = exports.stop_node = exports.close_connection = exports.open_connection = exports.get_connections = exports.get_network_info = exports.chia_common_service = exports.get_state = exports.chia_solver_service = exports.get_peer_counts = exports.get_ips_after_timestamp = exports.chia_crawler_service = exports.verify_proof = exports.get_proof = exports.clear_pending_roots = exports.check_plugins = exports.get_sync_status_dl = exports.cancel_offer_dl = exports.verify_offer = exports.take_offer_dl = exports.make_offer = exports.add_missing_files = exports.get_root_history = exports.get_kv_diff = exports.subscriptions = exports.remove_subscriptions = exports.get_mirrors = exports.delete_mirror = void 0;
|
|
8
8
|
var index_1 = require("./farmer/index");
|
|
9
9
|
Object.defineProperty(exports, "chia_farmer_service", { enumerable: true, get: function () { return index_1.chia_farmer_service; } });
|
|
10
10
|
Object.defineProperty(exports, "get_reward_targets", { enumerable: true, get: function () { return index_1.get_reward_targets; } });
|
|
@@ -108,18 +108,13 @@ Object.defineProperty(exports, "set_wallet_resync_on_startup", { enumerable: tru
|
|
|
108
108
|
Object.defineProperty(exports, "delete_key", { enumerable: true, get: function () { return index_4.delete_key; } });
|
|
109
109
|
Object.defineProperty(exports, "did_set_wallet_name", { enumerable: true, get: function () { return index_4.did_set_wallet_name; } });
|
|
110
110
|
Object.defineProperty(exports, "did_get_wallet_name", { enumerable: true, get: function () { return index_4.did_get_wallet_name; } });
|
|
111
|
-
Object.defineProperty(exports, "did_create_attest", { enumerable: true, get: function () { return index_4.did_create_attest; } });
|
|
112
111
|
Object.defineProperty(exports, "did_create_backup_file", { enumerable: true, get: function () { return index_4.did_create_backup_file; } });
|
|
113
112
|
Object.defineProperty(exports, "did_transfer_did", { enumerable: true, get: function () { return index_4.did_transfer_did; } });
|
|
114
113
|
Object.defineProperty(exports, "did_get_did", { enumerable: true, get: function () { return index_4.did_get_did; } });
|
|
115
|
-
Object.defineProperty(exports, "did_get_information_needed_for_recovery", { enumerable: true, get: function () { return index_4.did_get_information_needed_for_recovery; } });
|
|
116
114
|
Object.defineProperty(exports, "did_get_current_coin_info", { enumerable: true, get: function () { return index_4.did_get_current_coin_info; } });
|
|
117
115
|
Object.defineProperty(exports, "did_get_pubkey", { enumerable: true, get: function () { return index_4.did_get_pubkey; } });
|
|
118
|
-
Object.defineProperty(exports, "did_get_recovery_list", { enumerable: true, get: function () { return index_4.did_get_recovery_list; } });
|
|
119
116
|
Object.defineProperty(exports, "did_get_metadata", { enumerable: true, get: function () { return index_4.did_get_metadata; } });
|
|
120
|
-
Object.defineProperty(exports, "did_recovery_spend", { enumerable: true, get: function () { return index_4.did_recovery_spend; } });
|
|
121
117
|
Object.defineProperty(exports, "did_spend", { enumerable: true, get: function () { return index_4.did_spend; } });
|
|
122
|
-
Object.defineProperty(exports, "did_update_recovery_ids", { enumerable: true, get: function () { return index_4.did_update_recovery_ids; } });
|
|
123
118
|
Object.defineProperty(exports, "did_update_metadata", { enumerable: true, get: function () { return index_4.did_update_metadata; } });
|
|
124
119
|
Object.defineProperty(exports, "nft_mint_nft", { enumerable: true, get: function () { return index_4.nft_mint_nft; } });
|
|
125
120
|
Object.defineProperty(exports, "nft_count_nfts", { enumerable: true, get: function () { return index_4.nft_count_nfts; } });
|
|
@@ -235,16 +230,19 @@ var index_6 = require("./crawler/index");
|
|
|
235
230
|
Object.defineProperty(exports, "chia_crawler_service", { enumerable: true, get: function () { return index_6.chia_crawler_service; } });
|
|
236
231
|
Object.defineProperty(exports, "get_ips_after_timestamp", { enumerable: true, get: function () { return index_6.get_ips_after_timestamp; } });
|
|
237
232
|
Object.defineProperty(exports, "get_peer_counts", { enumerable: true, get: function () { return index_6.get_peer_counts; } });
|
|
238
|
-
var index_7 = require("./
|
|
239
|
-
Object.defineProperty(exports, "
|
|
240
|
-
Object.defineProperty(exports, "
|
|
241
|
-
|
|
242
|
-
Object.defineProperty(exports, "
|
|
243
|
-
Object.defineProperty(exports, "
|
|
244
|
-
Object.defineProperty(exports, "
|
|
245
|
-
Object.defineProperty(exports, "
|
|
246
|
-
Object.defineProperty(exports, "
|
|
247
|
-
Object.defineProperty(exports, "
|
|
248
|
-
Object.defineProperty(exports, "
|
|
249
|
-
Object.defineProperty(exports, "
|
|
250
|
-
Object.defineProperty(exports, "
|
|
233
|
+
var index_7 = require("./solver/index");
|
|
234
|
+
Object.defineProperty(exports, "chia_solver_service", { enumerable: true, get: function () { return index_7.chia_solver_service; } });
|
|
235
|
+
Object.defineProperty(exports, "get_state", { enumerable: true, get: function () { return index_7.get_state; } });
|
|
236
|
+
var index_8 = require("./common/index");
|
|
237
|
+
Object.defineProperty(exports, "chia_common_service", { enumerable: true, get: function () { return index_8.chia_common_service; } });
|
|
238
|
+
Object.defineProperty(exports, "get_network_info", { enumerable: true, get: function () { return index_8.get_network_info; } });
|
|
239
|
+
Object.defineProperty(exports, "get_connections", { enumerable: true, get: function () { return index_8.get_connections; } });
|
|
240
|
+
Object.defineProperty(exports, "open_connection", { enumerable: true, get: function () { return index_8.open_connection; } });
|
|
241
|
+
Object.defineProperty(exports, "close_connection", { enumerable: true, get: function () { return index_8.close_connection; } });
|
|
242
|
+
Object.defineProperty(exports, "stop_node", { enumerable: true, get: function () { return index_8.stop_node; } });
|
|
243
|
+
Object.defineProperty(exports, "get_routes", { enumerable: true, get: function () { return index_8.get_routes; } });
|
|
244
|
+
Object.defineProperty(exports, "get_version", { enumerable: true, get: function () { return index_8.get_version; } });
|
|
245
|
+
Object.defineProperty(exports, "healthz", { enumerable: true, get: function () { return index_8.healthz; } });
|
|
246
|
+
Object.defineProperty(exports, "get_log_level", { enumerable: true, get: function () { return index_8.get_log_level; } });
|
|
247
|
+
Object.defineProperty(exports, "set_log_level", { enumerable: true, get: function () { return index_8.set_log_level; } });
|
|
248
|
+
Object.defineProperty(exports, "reset_log_level", { enumerable: true, get: function () { return index_8.reset_log_level; } });
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { bool } from "../../chia/types/_python_types_";
|
|
2
|
+
import { TRPCAgent } from "../../../rpc/index";
|
|
3
|
+
import { TDaemon } from "../../../daemon/index";
|
|
4
|
+
import { GetMessageType, ResType } from "../../types";
|
|
5
|
+
export declare const chia_solver_service = "chia_solver";
|
|
6
|
+
export type chia_solver_service = typeof chia_solver_service;
|
|
7
|
+
export declare const get_state_command = "get_state";
|
|
8
|
+
export type get_state_command = typeof get_state_command;
|
|
9
|
+
export type TGetStateResponse = {
|
|
10
|
+
started: bool;
|
|
11
|
+
};
|
|
12
|
+
export type WsGetStateMessage = GetMessageType<chia_solver_service, get_state_command, TGetStateResponse>;
|
|
13
|
+
export declare function get_state<T extends TRPCAgent | TDaemon>(agent: T): Promise<ResType<T, TGetStateResponse, WsGetStateMessage>>;
|
|
14
|
+
export type RpcSolverMessage = TGetStateResponse;
|
|
15
|
+
export type RpcSolverMessageOnWs = WsGetStateMessage;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.get_state_command = exports.chia_solver_service = void 0;
|
|
4
|
+
exports.get_state = get_state;
|
|
5
|
+
exports.chia_solver_service = "chia_solver";
|
|
6
|
+
exports.get_state_command = "get_state";
|
|
7
|
+
async function get_state(agent) {
|
|
8
|
+
return agent.sendMessage(exports.chia_solver_service, exports.get_state_command);
|
|
9
|
+
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { WalletInfo } from "../../chia/wallet/wallet_info";
|
|
2
2
|
import { Coin } from "../../chia/types/blockchain_format/coin";
|
|
3
3
|
import { bool, bytes, False, None, Optional, str, True } from "../../chia/types/_python_types_";
|
|
4
|
-
import { int, uint16, uint32, uint64
|
|
4
|
+
import { int, uint16, uint32, uint64 } from "../../chia_rs/wheel/python/sized_ints";
|
|
5
5
|
import { bytes32 } from "../../chia_rs/wheel/python/sized_bytes";
|
|
6
6
|
import { TransactionRecord, TransactionRecordConvenience, TransactionRecordConvenienceWithMetadata } from "../../chia/wallet/transaction_record";
|
|
7
|
-
import { SpendBundle } from "../../chia_rs/chia-protocol/spend_bundle";
|
|
8
7
|
import { TRPCAgent } from "../../../rpc";
|
|
9
8
|
import { PoolWalletInfo } from "../../chia/pools/pool_wallet_info";
|
|
10
9
|
import { TradeRecordConvenience } from "../../chia/wallet/trade_record";
|
|
@@ -146,9 +145,13 @@ export type TGetWalletsRequest = {
|
|
|
146
145
|
type?: int;
|
|
147
146
|
include_data?: bool;
|
|
148
147
|
};
|
|
148
|
+
export type WalletInfoResponse = WalletInfo & {
|
|
149
|
+
authorized_providers: bytes32[];
|
|
150
|
+
flags_needed: str[];
|
|
151
|
+
};
|
|
149
152
|
export type TGetWalletsResponse = {
|
|
150
|
-
wallets:
|
|
151
|
-
fingerprint
|
|
153
|
+
wallets: WalletInfoResponse[];
|
|
154
|
+
fingerprint: Optional<uint32>;
|
|
152
155
|
};
|
|
153
156
|
export type WsGetWalletsMessage = GetMessageType<chia_wallet_service, get_wallets_command, TGetWalletsResponse>;
|
|
154
157
|
export declare function get_wallets<T extends TRPCAgent | TDaemon>(agent: T, data: TGetWalletsRequest): Promise<ResType<T, TGetWalletsResponse, WsGetWalletsMessage>>;
|
|
@@ -166,7 +169,7 @@ export type TCreate_New_CAT_WalletRequest = {
|
|
|
166
169
|
asset_id: str;
|
|
167
170
|
};
|
|
168
171
|
export type TCreate_New_CAT_WalletResponse = {
|
|
169
|
-
type:
|
|
172
|
+
type: "CAT";
|
|
170
173
|
asset_id: str;
|
|
171
174
|
wallet_id: uint32;
|
|
172
175
|
transactions: TransactionRecordConvenience[];
|
|
@@ -176,8 +179,6 @@ export type TCreateNewDidWalletRequestNew = {
|
|
|
176
179
|
fee?: uint64;
|
|
177
180
|
wallet_type: "did_wallet";
|
|
178
181
|
did_type: "new";
|
|
179
|
-
backup_dids: str[];
|
|
180
|
-
num_of_backup_ids_needed: uint64;
|
|
181
182
|
amount: int;
|
|
182
183
|
metadata?: Record<str, str>;
|
|
183
184
|
wallet_name?: str;
|
|
@@ -191,13 +192,15 @@ export type TCreateNewDidWalletRequestRecovery = {
|
|
|
191
192
|
export type TCreate_New_DID_WalletRequest = TCreateNewDidWalletRequestNew | TCreateNewDidWalletRequestRecovery;
|
|
192
193
|
export type TCreateNewDidWalletResponseNew = {
|
|
193
194
|
success: True;
|
|
194
|
-
type:
|
|
195
|
+
type: "DECENTRALIZED_ID";
|
|
195
196
|
my_did: str;
|
|
196
197
|
wallet_id: uint32;
|
|
198
|
+
transactions: TransactionRecordConvenience[];
|
|
199
|
+
signing_responses?: str[];
|
|
197
200
|
};
|
|
198
201
|
export type TCreateNewDidWalletResponseRecovery = {
|
|
199
202
|
success: True;
|
|
200
|
-
type:
|
|
203
|
+
type: "DECENTRALIZED_ID";
|
|
201
204
|
my_did: str;
|
|
202
205
|
wallet_id: uint32;
|
|
203
206
|
coin_name: str;
|
|
@@ -216,7 +219,7 @@ export type TCreate_New_NFT_WalletRequest = {
|
|
|
216
219
|
};
|
|
217
220
|
export type TCreate_New_NFT_WalletResponse = {
|
|
218
221
|
success: True;
|
|
219
|
-
type:
|
|
222
|
+
type: "NFT";
|
|
220
223
|
wallet_id: uint32;
|
|
221
224
|
};
|
|
222
225
|
export type TCreate_New_Pool_WalletRequest = {
|
|
@@ -233,12 +236,9 @@ export type TCreate_New_Pool_WalletRequest = {
|
|
|
233
236
|
};
|
|
234
237
|
p2_singleton_delayed_ph?: str;
|
|
235
238
|
p2_singleton_delay_time?: uint64;
|
|
236
|
-
} | {
|
|
237
|
-
fee?: uint64;
|
|
238
|
-
wallet_type: "pool_wallet";
|
|
239
|
-
mode: "recovery";
|
|
240
239
|
};
|
|
241
240
|
export type TCreate_New_Pool_WalletResponse = {
|
|
241
|
+
type: "POOLING_WALLET";
|
|
242
242
|
total_fee: uint64;
|
|
243
243
|
transaction: TransactionRecord;
|
|
244
244
|
transactions: TransactionRecordConvenience[];
|
|
@@ -246,24 +246,21 @@ export type TCreate_New_Pool_WalletResponse = {
|
|
|
246
246
|
launcher_id: str;
|
|
247
247
|
p2_singleton_puzzle_hash: str;
|
|
248
248
|
};
|
|
249
|
-
export type TCreateWalletErrorResponse = {
|
|
250
|
-
success: False;
|
|
251
|
-
error: str;
|
|
252
|
-
};
|
|
253
249
|
export declare const create_new_wallet_command = "create_new_wallet";
|
|
254
250
|
export type create_new_wallet_command = typeof create_new_wallet_command;
|
|
255
251
|
export type TCreateNewWalletRequestWithTx = TCreate_New_CAT_WalletRequest | TCreate_New_Pool_WalletRequest;
|
|
256
252
|
export type TCreateNewWalletRequestWithoutTx = TCreate_New_DID_WalletRequest | TCreate_New_NFT_WalletRequest;
|
|
257
253
|
export type TCreateNewWalletRequest = (TCreateNewWalletRequestWithTx | TCreateNewWalletRequestWithoutTx) & TXEndpointRequest;
|
|
258
|
-
export type TCreateNewWalletResponse = TCreate_New_CAT_WalletResponse | TCreate_New_DID_WalletResponse | TCreate_New_NFT_WalletResponse | TCreate_New_Pool_WalletResponse
|
|
254
|
+
export type TCreateNewWalletResponse = TCreate_New_CAT_WalletResponse | TCreate_New_DID_WalletResponse | TCreate_New_NFT_WalletResponse | TCreate_New_Pool_WalletResponse;
|
|
259
255
|
export type GetCreateNewWalletResponse<REQ extends TCreateNewWalletRequest> = REQ extends TCreate_New_CAT_WalletRequest ? TCreate_New_CAT_WalletResponse : REQ extends TCreate_New_DID_WalletRequest ? REQ extends TCreateNewDidWalletRequestNew ? TCreateNewDidWalletResponseNew : TCreateNewDidWalletResponseRecovery : REQ extends TCreate_New_NFT_WalletRequest ? TCreate_New_NFT_WalletResponse : TCreate_New_Pool_WalletResponse;
|
|
260
256
|
export type WsCreateNewWalletMessage<R> = GetMessageType<chia_wallet_service, create_new_wallet_command, R>;
|
|
261
257
|
export declare function create_new_wallet<T extends TRPCAgent | TDaemon, D extends TCreateNewWalletRequest>(agent: T, data: D): Promise<ResType<T, D extends TCreateNewWalletRequestWithTx ? TxeResp<D, GetCreateNewWalletResponse<D>> : GetCreateNewWalletResponse<D>, WsCreateNewWalletMessage<D extends TCreateNewWalletRequestWithTx ? TxeResp<D, GetCreateNewWalletResponse<D>> : GetCreateNewWalletResponse<D>>>>;
|
|
262
258
|
export type WalletBalance = Balance & {
|
|
263
259
|
wallet_id: uint32;
|
|
264
260
|
wallet_type: int;
|
|
265
|
-
fingerprint
|
|
266
|
-
asset_id
|
|
261
|
+
fingerprint: Optional<uint32>;
|
|
262
|
+
asset_id: Optional<str>;
|
|
263
|
+
pending_approval_balance: Optional<uint64>;
|
|
267
264
|
};
|
|
268
265
|
export declare const get_wallet_balance_command = "get_wallet_balance";
|
|
269
266
|
export type get_wallet_balance_command = typeof get_wallet_balance_command;
|
|
@@ -300,8 +297,8 @@ export declare const get_transactions_command = "get_transactions";
|
|
|
300
297
|
export type get_transactions_command = typeof get_transactions_command;
|
|
301
298
|
export type TGetTransactionsRequest = {
|
|
302
299
|
wallet_id: int;
|
|
303
|
-
start?:
|
|
304
|
-
end?:
|
|
300
|
+
start?: uint32;
|
|
301
|
+
end?: uint32;
|
|
305
302
|
sort_key?: str;
|
|
306
303
|
reverse?: bool;
|
|
307
304
|
to_address?: str;
|
|
@@ -317,7 +314,7 @@ export declare function get_transactions<T extends TRPCAgent | TDaemon>(agent: T
|
|
|
317
314
|
export declare const get_next_address_command = "get_next_address";
|
|
318
315
|
export type get_next_address_command = typeof get_next_address_command;
|
|
319
316
|
export type TGetNextAddressRequest = {
|
|
320
|
-
new_address
|
|
317
|
+
new_address?: bool;
|
|
321
318
|
wallet_id: int;
|
|
322
319
|
};
|
|
323
320
|
export type TGetNextAddressResponse = {
|
|
@@ -328,16 +325,17 @@ export type WsGetNextAddressMessage = GetMessageType<chia_wallet_service, get_ne
|
|
|
328
325
|
export declare function get_next_address<T extends TRPCAgent | TDaemon>(agent: T, data: TGetNextAddressRequest): Promise<ResType<T, TGetNextAddressResponse, WsGetNextAddressMessage>>;
|
|
329
326
|
export declare const send_transaction_command = "send_transaction";
|
|
330
327
|
export type send_transaction_command = typeof send_transaction_command;
|
|
328
|
+
export type ClawbackPuzzleDecoratorOverride = {
|
|
329
|
+
decorator: "CLAWBACK";
|
|
330
|
+
clawback_timelock: uint64;
|
|
331
|
+
};
|
|
331
332
|
export type TSendTransactionRequest = {
|
|
332
333
|
wallet_id: uint32;
|
|
333
334
|
amount: int;
|
|
334
335
|
fee?: uint64;
|
|
335
336
|
address: str;
|
|
336
337
|
memos?: str[];
|
|
337
|
-
puzzle_decorator?:
|
|
338
|
-
decorator: str;
|
|
339
|
-
clawback_timelock?: uint64;
|
|
340
|
-
}>;
|
|
338
|
+
puzzle_decorator?: ClawbackPuzzleDecoratorOverride[];
|
|
341
339
|
} & TXEndpointRequest;
|
|
342
340
|
export type TSendTransactionResponse = {
|
|
343
341
|
transaction: TransactionRecordConvenience;
|
|
@@ -364,7 +362,7 @@ export type spend_clawback_coins_command = typeof spend_clawback_coins_command;
|
|
|
364
362
|
export type TSpendClawbackCoinsRequest = {
|
|
365
363
|
coin_ids: str[];
|
|
366
364
|
fee?: uint64;
|
|
367
|
-
batch_size
|
|
365
|
+
batch_size?: uint16;
|
|
368
366
|
force?: bool;
|
|
369
367
|
} & TXEndpointRequest;
|
|
370
368
|
export type TSpendClawbackCoinsResponse = {
|
|
@@ -409,7 +407,10 @@ export type TGetFarmedAmountResponse = {
|
|
|
409
407
|
blocks_won: uint32;
|
|
410
408
|
};
|
|
411
409
|
export type WsGetFarmedAmountMessage = GetMessageType<chia_wallet_service, get_farmed_amount_command, TGetFarmedAmountResponse>;
|
|
412
|
-
export
|
|
410
|
+
export type TGetFarmedAmountRequest = {
|
|
411
|
+
include_pool_rewards?: bool;
|
|
412
|
+
};
|
|
413
|
+
export declare function get_farmed_amount<T extends TRPCAgent | TDaemon>(agent: T, data?: TGetFarmedAmountRequest): Promise<ResType<T, TGetFarmedAmountResponse, WsGetFarmedAmountMessage>>;
|
|
413
414
|
export type TAdditions = {
|
|
414
415
|
amount: uint64;
|
|
415
416
|
puzzle_hash: str;
|
|
@@ -418,12 +419,10 @@ export type TAdditions = {
|
|
|
418
419
|
export type TCoinAnnouncement = {
|
|
419
420
|
coin_id: str;
|
|
420
421
|
message: str;
|
|
421
|
-
morph_bytes?: str;
|
|
422
422
|
};
|
|
423
423
|
export type TPuzzleAnnouncement = {
|
|
424
424
|
puzzle_hash: str;
|
|
425
425
|
message: str;
|
|
426
|
-
morph_bytes?: str;
|
|
427
426
|
};
|
|
428
427
|
export declare const create_signed_transaction_command = "create_signed_transaction";
|
|
429
428
|
export type create_signed_transaction_command = typeof create_signed_transaction_command;
|
|
@@ -434,7 +433,7 @@ export type TCreateSignedTransactionRequest = {
|
|
|
434
433
|
coins?: Coin[];
|
|
435
434
|
coin_announcements?: TCoinAnnouncement[];
|
|
436
435
|
puzzle_announcements?: TPuzzleAnnouncement[];
|
|
437
|
-
morph_bytes?:
|
|
436
|
+
morph_bytes?: str;
|
|
438
437
|
} & TXEndpointRequest;
|
|
439
438
|
export type TCreateSignedTransactionResponse = {
|
|
440
439
|
signed_txs: TransactionRecordConvenience[];
|
|
@@ -533,7 +532,7 @@ export type send_notification_command = typeof send_notification_command;
|
|
|
533
532
|
export type TSendNotificationRequest = {
|
|
534
533
|
target: str;
|
|
535
534
|
message: str;
|
|
536
|
-
amount
|
|
535
|
+
amount?: uint64;
|
|
537
536
|
fee?: uint64;
|
|
538
537
|
} & TXEndpointRequest;
|
|
539
538
|
export type TSendNotificationResponse = {
|
|
@@ -554,6 +553,7 @@ export type TVerifySignatureRequest = {
|
|
|
554
553
|
};
|
|
555
554
|
export type TVerifySignatureResponse = {
|
|
556
555
|
isValid: True;
|
|
556
|
+
error: None;
|
|
557
557
|
} | {
|
|
558
558
|
isValid: False;
|
|
559
559
|
error: str;
|
|
@@ -653,7 +653,7 @@ export type TCatAssetIdToNameRequest = {
|
|
|
653
653
|
};
|
|
654
654
|
export type TCatAssetIdToNameResponse = {
|
|
655
655
|
wallet_id: Optional<uint32>;
|
|
656
|
-
name: str
|
|
656
|
+
name: Optional<str>;
|
|
657
657
|
};
|
|
658
658
|
export type WsCatAssetIdToNameMessage = GetMessageType<chia_wallet_service, cat_asset_id_to_name_command, TCatAssetIdToNameResponse>;
|
|
659
659
|
export declare function cat_asset_id_to_name<T extends TRPCAgent | TDaemon>(agent: T, data: TCatAssetIdToNameRequest): Promise<ResType<T, TCatAssetIdToNameResponse, WsCatAssetIdToNameMessage>>;
|
|
@@ -685,12 +685,12 @@ export type cat_spend_command = typeof cat_spend_command;
|
|
|
685
685
|
export type TCatSpendRequest = {
|
|
686
686
|
wallet_id: uint32;
|
|
687
687
|
additions?: TAdditions[];
|
|
688
|
-
fee
|
|
689
|
-
amount
|
|
690
|
-
inner_address
|
|
688
|
+
fee?: uint64;
|
|
689
|
+
amount?: uint64;
|
|
690
|
+
inner_address?: str;
|
|
691
691
|
memos?: str[];
|
|
692
692
|
coins?: Coin[];
|
|
693
|
-
extra_delta?:
|
|
693
|
+
extra_delta?: str;
|
|
694
694
|
tail_reveal?: str;
|
|
695
695
|
tail_solution?: str;
|
|
696
696
|
} & TXEndpointRequest;
|
|
@@ -716,7 +716,7 @@ export declare function cat_get_asset_id<T extends TRPCAgent | TDaemon>(agent: T
|
|
|
716
716
|
export declare const create_offer_for_ids_command = "create_offer_for_ids";
|
|
717
717
|
export type create_offer_for_ids_command = typeof create_offer_for_ids_command;
|
|
718
718
|
export type TCreateOfferForIdsRequest = {
|
|
719
|
-
offer: Record<
|
|
719
|
+
offer: Record<str, str | int>;
|
|
720
720
|
fee?: uint64;
|
|
721
721
|
validate_only?: bool;
|
|
722
722
|
driver_dict?: TDriverDict;
|
|
@@ -736,16 +736,27 @@ export type TGetOfferSummaryRequest = {
|
|
|
736
736
|
offer: str;
|
|
737
737
|
advanced?: bool;
|
|
738
738
|
};
|
|
739
|
+
export type TOfferSummary = {
|
|
740
|
+
offered: Record<str, str>;
|
|
741
|
+
requested: Record<str, str>;
|
|
742
|
+
fees: int;
|
|
743
|
+
infos: TDriverDict;
|
|
744
|
+
additions: str[];
|
|
745
|
+
removals: str[];
|
|
746
|
+
valid_times: Omit<ConditionValidTimes, "max_secs_after_created" | "min_secs_since_created" | "max_blocks_after_created" | "min_blocks_since_created">;
|
|
747
|
+
};
|
|
748
|
+
export type TDataLayerOfferSummary = {
|
|
749
|
+
offered: Array<{
|
|
750
|
+
launcher_id: str;
|
|
751
|
+
new_root: str;
|
|
752
|
+
dependencies: Array<{
|
|
753
|
+
launcher_id: str;
|
|
754
|
+
values_to_prove: str[];
|
|
755
|
+
}>;
|
|
756
|
+
}>;
|
|
757
|
+
};
|
|
739
758
|
export type TGetOfferSummaryResponse = {
|
|
740
|
-
summary:
|
|
741
|
-
offered: Record<str, int>;
|
|
742
|
-
requested: Record<str, int>;
|
|
743
|
-
fees: int;
|
|
744
|
-
infos: TDriverDict;
|
|
745
|
-
additions: str[];
|
|
746
|
-
removals: str[];
|
|
747
|
-
valid_times: Omit<ConditionValidTimes, "max_secs_after_created" | "min_secs_since_created" | "max_blocks_after_created" | "min_blocks_since_created">;
|
|
748
|
-
};
|
|
759
|
+
summary: TOfferSummary | TDataLayerOfferSummary;
|
|
749
760
|
id: bytes32;
|
|
750
761
|
};
|
|
751
762
|
export type WsGetOfferSummaryMessage = GetMessageType<chia_wallet_service, get_offer_summary_command, TGetOfferSummaryResponse>;
|
|
@@ -791,8 +802,8 @@ export declare function get_offer<T extends TRPCAgent | TDaemon>(agent: T, data:
|
|
|
791
802
|
export declare const get_all_offers_command = "get_all_offers";
|
|
792
803
|
export type get_all_offers_command = typeof get_all_offers_command;
|
|
793
804
|
export type TGetAllOffersRequest = {
|
|
794
|
-
start?:
|
|
795
|
-
end?:
|
|
805
|
+
start?: uint16;
|
|
806
|
+
end?: uint16;
|
|
796
807
|
exclude_my_offers?: bool;
|
|
797
808
|
exclude_taken_offers?: bool;
|
|
798
809
|
include_completed?: bool;
|
|
@@ -871,20 +882,6 @@ export type TDidGetWalletNameResponse = {
|
|
|
871
882
|
};
|
|
872
883
|
export type WsDidGetWalletNameMessage = GetMessageType<chia_wallet_service, did_get_wallet_name_command, TDidGetWalletNameResponse>;
|
|
873
884
|
export declare function did_get_wallet_name<T extends TRPCAgent | TDaemon>(agent: T, data: TDidGetWalletNameRequest): Promise<ResType<T, TDidGetWalletNameResponse, WsDidGetWalletNameMessage>>;
|
|
874
|
-
export declare const did_update_recovery_ids_command = "did_update_recovery_ids";
|
|
875
|
-
export type did_update_recovery_ids_command = typeof did_update_recovery_ids_command;
|
|
876
|
-
export type TDidUpdateRecoveryIdsRequest = {
|
|
877
|
-
wallet_id: uint32;
|
|
878
|
-
new_list: str[];
|
|
879
|
-
num_verifications_required?: uint64;
|
|
880
|
-
} & TXEndpointRequest;
|
|
881
|
-
export type TDidUpdateRecoveryIdsResponse = {
|
|
882
|
-
success: bool;
|
|
883
|
-
transactions: TransactionRecordConvenience[];
|
|
884
|
-
signing_responses?: str[];
|
|
885
|
-
};
|
|
886
|
-
export type WsDidUpdateRecoveryIdsMessage<R> = GetMessageType<chia_wallet_service, did_update_recovery_ids_command, R>;
|
|
887
|
-
export declare function did_update_recovery_ids<T extends TRPCAgent | TDaemon, D extends TDidUpdateRecoveryIdsRequest>(agent: T, data: D): Promise<ResType<T, TxeResp<D, TDidUpdateRecoveryIdsResponse>, WsDidUpdateRecoveryIdsMessage<TxeResp<D, TDidUpdateRecoveryIdsResponse>>>>;
|
|
888
885
|
export declare const did_update_metadata_command = "did_update_metadata";
|
|
889
886
|
export type did_update_metadata_command = typeof did_update_metadata_command;
|
|
890
887
|
export type TDidUpdateMetadataRequest = {
|
|
@@ -939,38 +936,6 @@ export type TDidGetDidResponse = {
|
|
|
939
936
|
};
|
|
940
937
|
export type WsDidGetDidMessage = GetMessageType<chia_wallet_service, did_get_did_command, TDidGetDidResponse>;
|
|
941
938
|
export declare function did_get_did<T extends TRPCAgent | TDaemon>(agent: T, data: TDidGetDidRequest): Promise<ResType<T, TDidGetDidResponse, WsDidGetDidMessage>>;
|
|
942
|
-
export declare const did_recovery_spend_command = "did_recovery_spend";
|
|
943
|
-
export type did_recovery_spend_command = typeof did_recovery_spend_command;
|
|
944
|
-
export type TDidRecoverySpendRequest = {
|
|
945
|
-
wallet_id: uint32;
|
|
946
|
-
attest_data: str[];
|
|
947
|
-
pubkey?: str;
|
|
948
|
-
puzhash?: str;
|
|
949
|
-
push?: bool;
|
|
950
|
-
};
|
|
951
|
-
export type TDidRecoverySpendResponse = {
|
|
952
|
-
success: True;
|
|
953
|
-
spend_bundle: SpendBundle;
|
|
954
|
-
transactions: TransactionRecordConvenience[];
|
|
955
|
-
} | {
|
|
956
|
-
success: False;
|
|
957
|
-
reason: str;
|
|
958
|
-
};
|
|
959
|
-
export type WsDidRecoverySpendMessage = GetMessageType<chia_wallet_service, did_recovery_spend_command, TDidRecoverySpendResponse>;
|
|
960
|
-
export declare function did_recovery_spend<T extends TRPCAgent | TDaemon>(agent: T, data: TDidRecoverySpendRequest): Promise<ResType<T, TDidRecoverySpendResponse, WsDidRecoverySpendMessage>>;
|
|
961
|
-
export declare const did_get_recovery_list_command = "did_get_recovery_list";
|
|
962
|
-
export type did_get_recovery_list_command = typeof did_get_recovery_list_command;
|
|
963
|
-
export type TDidGetRecoveryListRequest = {
|
|
964
|
-
wallet_id: uint32;
|
|
965
|
-
};
|
|
966
|
-
export type TDidGetRecoveryListResponse = {
|
|
967
|
-
success: bool;
|
|
968
|
-
wallet_id: uint32;
|
|
969
|
-
recovery_list: str[];
|
|
970
|
-
num_required: uint64;
|
|
971
|
-
};
|
|
972
|
-
export type WsDidGetRecoveryListMessage = GetMessageType<chia_wallet_service, did_get_recovery_list_command, TDidGetRecoveryListResponse>;
|
|
973
|
-
export declare function did_get_recovery_list<T extends TRPCAgent | TDaemon>(agent: T, data: TDidGetRecoveryListRequest): Promise<ResType<T, TDidGetRecoveryListResponse, WsDidGetRecoveryListMessage>>;
|
|
974
939
|
export declare const did_get_metadata_command = "did_get_metadata";
|
|
975
940
|
export type did_get_metadata_command = typeof did_get_metadata_command;
|
|
976
941
|
export type TDidGetMetadataRequest = {
|
|
@@ -983,41 +948,6 @@ export type TDidGetMetadataResponse = {
|
|
|
983
948
|
};
|
|
984
949
|
export type WsDidGetMetadataMessage = GetMessageType<chia_wallet_service, did_get_metadata_command, TDidGetMetadataResponse>;
|
|
985
950
|
export declare function did_get_metadata<T extends TRPCAgent | TDaemon>(agent: T, data: TDidGetMetadataRequest): Promise<ResType<T, TDidGetMetadataResponse, WsDidGetMetadataMessage>>;
|
|
986
|
-
export declare const did_create_attest_command = "did_create_attest";
|
|
987
|
-
export type did_create_attest_command = typeof did_create_attest_command;
|
|
988
|
-
export type TDidCreateAttestRequest = {
|
|
989
|
-
wallet_id: uint32;
|
|
990
|
-
coin_name: str;
|
|
991
|
-
puzhash: str;
|
|
992
|
-
} & TXEndpointRequest;
|
|
993
|
-
export type TDidCreateAttestResponse = {
|
|
994
|
-
success: True;
|
|
995
|
-
message_spend_bundle: str;
|
|
996
|
-
info: [str, str, uint64];
|
|
997
|
-
attest_data: str;
|
|
998
|
-
transactions: TransactionRecordConvenience[];
|
|
999
|
-
signing_responses?: str[];
|
|
1000
|
-
} | {
|
|
1001
|
-
success: False;
|
|
1002
|
-
};
|
|
1003
|
-
export type WsDidCreateAttestMessage<R> = GetMessageType<chia_wallet_service, did_create_attest_command, R>;
|
|
1004
|
-
export declare function did_create_attest<T extends TRPCAgent | TDaemon, D extends TDidCreateAttestRequest>(agent: T, data: D): Promise<ResType<T, TxeResp<D, TDidCreateAttestResponse>, WsDidCreateAttestMessage<TxeResp<D, TDidCreateAttestResponse>>>>;
|
|
1005
|
-
export declare const did_get_information_needed_for_recovery_command = "did_get_information_needed_for_recovery";
|
|
1006
|
-
export type did_get_information_needed_for_recovery_command = typeof did_get_information_needed_for_recovery_command;
|
|
1007
|
-
export type TDidGetInformationNeededForRecoveryRequest = {
|
|
1008
|
-
wallet_id: uint32;
|
|
1009
|
-
};
|
|
1010
|
-
export type TDidGetInformationNeededForRecoveryResponse = {
|
|
1011
|
-
success: bool;
|
|
1012
|
-
wallet_id: uint32;
|
|
1013
|
-
my_did: str;
|
|
1014
|
-
coin_name: str;
|
|
1015
|
-
newpuzhash: Optional<bytes32>;
|
|
1016
|
-
pubkey: Optional<bytes>;
|
|
1017
|
-
backup_dids: bytes[];
|
|
1018
|
-
};
|
|
1019
|
-
export type WsDidGetInformationNeededForRecoveryMessage = GetMessageType<chia_wallet_service, did_get_information_needed_for_recovery_command, TDidGetInformationNeededForRecoveryResponse>;
|
|
1020
|
-
export declare function did_get_information_needed_for_recovery<T extends TRPCAgent | TDaemon>(agent: T, data: TDidGetInformationNeededForRecoveryRequest): Promise<ResType<T, TDidGetInformationNeededForRecoveryResponse, WsDidGetInformationNeededForRecoveryMessage>>;
|
|
1021
951
|
export declare const did_get_current_coin_info_command = "did_get_current_coin_info";
|
|
1022
952
|
export type did_get_current_coin_info_command = typeof did_get_current_coin_info_command;
|
|
1023
953
|
export type TDidGetCurrentCoinInfoRequest = {
|
|
@@ -1737,4 +1667,4 @@ export type TExecuteSigningInstructionsRequest = ExecuteSigningInstructions | Ex
|
|
|
1737
1667
|
export type TExecuteSigningInstructionsResponse = ExecuteSigningInstructionsResponse | ExecuteSigningInstructionsResponseCHIP0029;
|
|
1738
1668
|
export type WsExecuteSigningInstructionsMessage<R> = GetMessageType<chia_wallet_service, execute_signing_instructions_command, R>;
|
|
1739
1669
|
export declare function execute_signing_instructions<T extends TRPCAgent | TDaemon, D extends TExecuteSigningInstructionsRequest>(agent: T, data: D): Promise<ResType<T, D extends ExecuteSigningInstructionsCHIP0029 ? ExecuteSigningInstructionsResponseCHIP0029 : ExecuteSigningInstructionsResponse, WsExecuteSigningInstructionsMessage<D extends ExecuteSigningInstructionsCHIP0029 ? ExecuteSigningInstructionsResponseCHIP0029 : ExecuteSigningInstructionsResponse>>>;
|
|
1740
|
-
export type RpcWalletMessage = TAddKeyResponse | TAddRateLimitedFundsResponse | TCancelOfferResponse | TCancelOffersResponse | TCatGetAssetIdResponse | TCatGetNameResponse | TGetStrayCatsResponse | TCatAssetIdToNameResponse | TCatSetNameResponse | TCatSpendResponse | TCheckOfferValidityResponse | TCreateNewWalletResponse | TCreateOfferForIdsResponse | TCreateSignedTransactionResponse | TDeleteUnconfirmedTransactionsResponse | TSelectCoinsResponse | TGetSpendableCoinsResponse | TGetCoinRecordsByNamesResponse | TGetCurrentDerivationIndexResponse | TExtendDerivationIndexResponse | TGetNotificationsResponse | TDeleteNotificationsResponse | TSendNotificationResponse | TSignMessageByAddressResponse | TSignMessageByIdResponse | TVerifySignatureResponse | TGetTransactionMemoResponse | TSplitCoinsResponse | TCombineCoinsResponse | TNftCalculateRoyaltiesResponse | TNftMintBulkResponse | TNftSetDidBulkResponse | TNftTransferBulkResponse | TDeleteAllKeysResponse | TSetWalletResyncOnStartupResponse | TDeleteKeyResponse | TCheckDeleteKeyResponse | TDidSetWalletNameResponse | TDidGetWalletNameResponse |
|
|
1670
|
+
export type RpcWalletMessage = TAddKeyResponse | TAddRateLimitedFundsResponse | TCancelOfferResponse | TCancelOffersResponse | TCatGetAssetIdResponse | TCatGetNameResponse | TGetStrayCatsResponse | TCatAssetIdToNameResponse | TCatSetNameResponse | TCatSpendResponse | TCheckOfferValidityResponse | TCreateNewWalletResponse | TCreateOfferForIdsResponse | TCreateSignedTransactionResponse | TDeleteUnconfirmedTransactionsResponse | TSelectCoinsResponse | TGetSpendableCoinsResponse | TGetCoinRecordsByNamesResponse | TGetCurrentDerivationIndexResponse | TExtendDerivationIndexResponse | TGetNotificationsResponse | TDeleteNotificationsResponse | TSendNotificationResponse | TSignMessageByAddressResponse | TSignMessageByIdResponse | TVerifySignatureResponse | TGetTransactionMemoResponse | TSplitCoinsResponse | TCombineCoinsResponse | TNftCalculateRoyaltiesResponse | TNftMintBulkResponse | TNftSetDidBulkResponse | TNftTransferBulkResponse | TDeleteAllKeysResponse | TSetWalletResyncOnStartupResponse | TDeleteKeyResponse | TCheckDeleteKeyResponse | TDidSetWalletNameResponse | TDidGetWalletNameResponse | TDidCreateBackupFileResponse | TDidTransferDidResponse | TDidMessageSpendResponse | TDidGetInfoResponse | TDidFindLostDidResponse | TDidGetDidResponse | TDidGetCurrentCoinInfoResponse | TDidGetPubkeyResponse | TDidGetMetadataResponse | TDidSpendResponse | TDidUpdateMetadataResponse | TNftMintNftResponse | TNftCountNftsResponse | TNftGetNftsResponse | TNftSetNftDidResponse | TNftGetByDidResponse | TNftGetWalletDidResponse | TNftGetWalletsWithDidsResponse | TNftSetNftStatusResponse | TNftTransferNftResponse | TNftGetInfoResponse | TNftAddUriResponse | TGetTimestampForHeightResponse | TSetAutoClaimResponse | TGetAutoClaimResponse | TGenerateMnemonicResponse | TGetAllOffersResponse | TGetCatListResponse | TGetFarmedAmountResponse | TGetHeightInfoResponse | TGetInitialFreezePeriodResponseOfWallet | TGetLoggedInFingerprintResponse | TGetOfferResponse | TGetOffersCountResponse | TGetOfferSummaryResponse | TGetNextAddressResponse | TGetPrivateKeyResponse | TGetPublicKeysResponse | TGetSyncStatusResponse | TGetTransactionResponse | TGetTransactionCountResponse | TGetTransactionsResponse | TGetWalletBalanceResponse | TGetWalletBalancesResponse | TGetWalletsResponse | TLoginResponse | TPushTxResponseOfWallet | TPushTransactionsResponse | TPwJoinPoolResponse | TPwSelfPoolResponse | TPwAbsorbRewardsResponse | TPwStatusResponse | TRlSetUserInfoResponse | TSendClawbackTransactionResponse | TSendTransactionResponse | TSendTransactionMultiResponse | TSpendClawbackCoinsResponse | TGetCoinRecordsResponse | TTakeOfferResponse | TCreateNewDlResponse | TDlTrackNewResponse | TDlStopTrackingResponse | TDlLatestSingletonResponse | TDlSingletonsByRootResponse | TDlUpdateRootResponse | TDlUpdateMultipleResponse | TDlHistoryResponse | TDlOwnedSingletonsResponse | TDlGetMirrorsResponse | TDlNewMirrorResponse | TDlDeleteMirrorResponse | TDlVerifyProofResponse | TVcMintResponse | TVcGetResponse | TVcGetListResponse | TVcSpendResponse | TVcAddProofsResponse | TVcGetProofsForRootResponse | TVcRevokeResponse | TCrcatApprovePendingResponse | TGatherSigningInfoResponse | TApplySignaturesResponse | TSubmitTransactionsResponse | TExecuteSigningInstructionsResponse;
|
package/api/rpc/wallet/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.cat_set_name_command = exports.get_cat_list_command = exports.sign_message_by_id_command = exports.sign_message_by_address_command = exports.combine_coins_command = exports.split_coins_command = exports.get_transaction_memo_command = exports.verify_signature_command = exports.send_notification_command = exports.delete_notifications_command = exports.get_notifications_command = exports.extend_derivation_index_command = exports.get_current_derivation_index_command = exports.get_coin_records_by_names_command = exports.get_spendable_coins_command = exports.select_coins_command = exports.delete_unconfirmed_transactions_command = exports.create_signed_transaction_command = exports.get_farmed_amount_command = exports.get_transaction_count_command = exports.get_coin_records_command = exports.spend_clawback_coins_command = exports.send_transaction_multi_command = exports.send_transaction_command = exports.get_next_address_command = exports.get_transactions_command = exports.get_transaction_command = exports.get_wallet_balances_command = exports.get_wallet_balance_command = exports.create_new_wallet_command = exports.get_wallets_command = exports.get_initial_freeze_period_command_of_wallet = exports.get_auto_claim_command = exports.set_auto_claim_command = exports.get_timestamp_for_height_command = exports.push_transactions_command = exports.push_tx_command = exports.get_height_info_command = exports.get_sync_status_command = exports.set_wallet_resync_on_startup_command = exports.delete_all_keys_command = exports.check_delete_key_command = exports.delete_key_command = exports.add_key_command = exports.generate_mnemonic_command = exports.get_private_key_command = exports.get_public_keys_command = exports.get_logged_in_fingerprint_command = exports.log_in_command = exports.chia_wallet_service = void 0;
|
|
4
|
-
exports.add_rate_limited_funds_command = exports.send_clawback_transaction_command = exports.rl_set_user_info_command = exports.nft_mint_bulk_command = exports.nft_calculate_royalties_command = exports.nft_add_uri_command = exports.nft_get_info_command = exports.nft_transfer_nft_command = exports.nft_set_nft_status_command = exports.nft_get_wallets_with_dids_command = exports.nft_get_wallet_did_command = exports.nft_get_by_did_command = exports.nft_transfer_bulk_command = exports.nft_set_did_bulk_command = exports.nft_set_nft_did_command = exports.nft_get_nfts_command = exports.nft_count_nfts_command = exports.nft_mint_nft_command = exports.did_transfer_did_command = exports.did_find_lost_did_command = exports.did_get_info_command = exports.did_message_spend_command = exports.did_create_backup_file_command = exports.did_get_current_coin_info_command = exports.
|
|
5
|
-
exports.execute_signing_instructions_command = exports.submit_transactions_command = exports.apply_signatures_command = exports.gather_signing_info_command = exports.crcat_approve_pending_command = exports.vc_revoke_command = exports.vc_get_proofs_for_root_command = exports.vc_add_proofs_command = exports.vc_spend_command = exports.vc_get_list_command = exports.vc_get_command = exports.vc_mint_command = exports.dl_verify_proof_command = exports.dl_delete_mirror_command = exports.dl_new_mirror_command = exports.dl_get_mirrors_command = exports.dl_owned_singletons_command = exports.dl_history_command = exports.dl_update_multiple_command = exports.dl_update_root_command = exports.dl_singletons_by_root_command = exports.dl_latest_singleton_command = exports.dl_stop_tracking_command = exports.dl_track_new_command =
|
|
4
|
+
exports.create_new_dl_command = exports.pw_status_command = exports.pw_absorb_rewards_command = exports.pw_self_pool_command = exports.pw_join_pool_command = exports.add_rate_limited_funds_command = exports.send_clawback_transaction_command = exports.rl_set_user_info_command = exports.nft_mint_bulk_command = exports.nft_calculate_royalties_command = exports.nft_add_uri_command = exports.nft_get_info_command = exports.nft_transfer_nft_command = exports.nft_set_nft_status_command = exports.nft_get_wallets_with_dids_command = exports.nft_get_wallet_did_command = exports.nft_get_by_did_command = exports.nft_transfer_bulk_command = exports.nft_set_did_bulk_command = exports.nft_set_nft_did_command = exports.nft_get_nfts_command = exports.nft_count_nfts_command = exports.nft_mint_nft_command = exports.did_transfer_did_command = exports.did_find_lost_did_command = exports.did_get_info_command = exports.did_message_spend_command = exports.did_create_backup_file_command = exports.did_get_current_coin_info_command = exports.did_get_metadata_command = exports.did_get_did_command = exports.did_get_pubkey_command = exports.did_spend_command = exports.did_update_metadata_command = exports.did_get_wallet_name_command = exports.did_set_wallet_name_command = exports.cancel_offers_command = exports.cancel_offer_command = exports.get_offers_count_command = exports.get_all_offers_command = exports.get_offer_command = exports.take_offer_command = exports.check_offer_validity_command = exports.get_offer_summary_command = exports.create_offer_for_ids_command = exports.cat_get_asset_id_command = exports.cat_spend_command = exports.get_stray_cats_command = exports.cat_get_name_command = exports.cat_asset_id_to_name_command = void 0;
|
|
5
|
+
exports.execute_signing_instructions_command = exports.submit_transactions_command = exports.apply_signatures_command = exports.gather_signing_info_command = exports.crcat_approve_pending_command = exports.vc_revoke_command = exports.vc_get_proofs_for_root_command = exports.vc_add_proofs_command = exports.vc_spend_command = exports.vc_get_list_command = exports.vc_get_command = exports.vc_mint_command = exports.dl_verify_proof_command = exports.dl_delete_mirror_command = exports.dl_new_mirror_command = exports.dl_get_mirrors_command = exports.dl_owned_singletons_command = exports.dl_history_command = exports.dl_update_multiple_command = exports.dl_update_root_command = exports.dl_singletons_by_root_command = exports.dl_latest_singleton_command = exports.dl_stop_tracking_command = exports.dl_track_new_command = void 0;
|
|
6
6
|
exports.log_in = log_in;
|
|
7
7
|
exports.get_logged_in_fingerprint = get_logged_in_fingerprint;
|
|
8
8
|
exports.get_public_keys = get_public_keys;
|
|
@@ -68,16 +68,11 @@ exports.cancel_offer = cancel_offer;
|
|
|
68
68
|
exports.cancel_offers = cancel_offers;
|
|
69
69
|
exports.did_set_wallet_name = did_set_wallet_name;
|
|
70
70
|
exports.did_get_wallet_name = did_get_wallet_name;
|
|
71
|
-
exports.did_update_recovery_ids = did_update_recovery_ids;
|
|
72
71
|
exports.did_update_metadata = did_update_metadata;
|
|
73
72
|
exports.did_spend = did_spend;
|
|
74
73
|
exports.did_get_pubkey = did_get_pubkey;
|
|
75
74
|
exports.did_get_did = did_get_did;
|
|
76
|
-
exports.did_recovery_spend = did_recovery_spend;
|
|
77
|
-
exports.did_get_recovery_list = did_get_recovery_list;
|
|
78
75
|
exports.did_get_metadata = did_get_metadata;
|
|
79
|
-
exports.did_create_attest = did_create_attest;
|
|
80
|
-
exports.did_get_information_needed_for_recovery = did_get_information_needed_for_recovery;
|
|
81
76
|
exports.did_get_current_coin_info = did_get_current_coin_info;
|
|
82
77
|
exports.did_create_backup_file = did_create_backup_file;
|
|
83
78
|
exports.did_message_spend = did_message_spend;
|
|
@@ -257,8 +252,8 @@ async function get_transaction_count(agent, data) {
|
|
|
257
252
|
return agent.sendMessage(exports.chia_wallet_service, exports.get_transaction_count_command, data);
|
|
258
253
|
}
|
|
259
254
|
exports.get_farmed_amount_command = "get_farmed_amount";
|
|
260
|
-
async function get_farmed_amount(agent) {
|
|
261
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.get_farmed_amount_command);
|
|
255
|
+
async function get_farmed_amount(agent, data) {
|
|
256
|
+
return agent.sendMessage(exports.chia_wallet_service, exports.get_farmed_amount_command, data);
|
|
262
257
|
}
|
|
263
258
|
exports.create_signed_transaction_command = "create_signed_transaction";
|
|
264
259
|
async function create_signed_transaction(agent, data) {
|
|
@@ -398,10 +393,6 @@ exports.did_get_wallet_name_command = "did_get_wallet_name";
|
|
|
398
393
|
async function did_get_wallet_name(agent, data) {
|
|
399
394
|
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_wallet_name_command, data);
|
|
400
395
|
}
|
|
401
|
-
exports.did_update_recovery_ids_command = "did_update_recovery_ids";
|
|
402
|
-
async function did_update_recovery_ids(agent, data) {
|
|
403
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.did_update_recovery_ids_command, data);
|
|
404
|
-
}
|
|
405
396
|
exports.did_update_metadata_command = "did_update_metadata";
|
|
406
397
|
async function did_update_metadata(agent, data) {
|
|
407
398
|
return agent.sendMessage(exports.chia_wallet_service, exports.did_update_metadata_command, data);
|
|
@@ -419,26 +410,10 @@ exports.did_get_did_command = "did_get_did";
|
|
|
419
410
|
async function did_get_did(agent, data) {
|
|
420
411
|
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_did_command, data);
|
|
421
412
|
}
|
|
422
|
-
exports.did_recovery_spend_command = "did_recovery_spend";
|
|
423
|
-
async function did_recovery_spend(agent, data) {
|
|
424
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.did_recovery_spend_command, data);
|
|
425
|
-
}
|
|
426
|
-
exports.did_get_recovery_list_command = "did_get_recovery_list";
|
|
427
|
-
async function did_get_recovery_list(agent, data) {
|
|
428
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_recovery_list_command, data);
|
|
429
|
-
}
|
|
430
413
|
exports.did_get_metadata_command = "did_get_metadata";
|
|
431
414
|
async function did_get_metadata(agent, data) {
|
|
432
415
|
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_metadata_command, data);
|
|
433
416
|
}
|
|
434
|
-
exports.did_create_attest_command = "did_create_attest";
|
|
435
|
-
async function did_create_attest(agent, data) {
|
|
436
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.did_create_attest_command, data);
|
|
437
|
-
}
|
|
438
|
-
exports.did_get_information_needed_for_recovery_command = "did_get_information_needed_for_recovery";
|
|
439
|
-
async function did_get_information_needed_for_recovery(agent, data) {
|
|
440
|
-
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_information_needed_for_recovery_command, data);
|
|
441
|
-
}
|
|
442
417
|
exports.did_get_current_coin_info_command = "did_get_current_coin_info";
|
|
443
418
|
async function did_get_current_coin_info(agent, data) {
|
|
444
419
|
return agent.sendMessage(exports.chia_wallet_service, exports.did_get_current_coin_info_command, data);
|
package/api/ws/daemon/index.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ export type TPingResponse = {
|
|
|
18
18
|
};
|
|
19
19
|
export type WsPingMessage = GetMessageType<daemon_service, ping_command, TPingResponse>;
|
|
20
20
|
export declare function ping(daemon: TDaemon): Promise<WsPingMessage>;
|
|
21
|
-
export type TService = "chia" | "chia_wallet" | "chia_full_node" | "chia_harvester" | "chia_farmer" | "chia_introducer" | "chia_timelord" | "chia_timelord_launcher" | "chia_full_node_simulator";
|
|
21
|
+
export type TService = "chia" | "chia_wallet" | "chia_full_node" | "chia_harvester" | "chia_farmer" | "chia_introducer" | "chia_timelord" | "chia_timelord_launcher" | "chia_full_node_simulator" | "chia_solver";
|
|
22
22
|
export declare const start_service_command = "start_service";
|
|
23
23
|
export type start_service_command = typeof start_service_command;
|
|
24
24
|
export type TStartServiceRequest = {
|
package/package.json
CHANGED
package/rpc/index.d.ts
CHANGED
|
@@ -6,7 +6,7 @@ export declare class RpcError extends Error {
|
|
|
6
6
|
response: unknown;
|
|
7
7
|
constructor(message: string, response: unknown);
|
|
8
8
|
}
|
|
9
|
-
type TDestination = "farmer" | "harvester" | "full_node" | "wallet" | "data_layer" | "daemon" | "pool";
|
|
9
|
+
type TDestination = "farmer" | "harvester" | "full_node" | "wallet" | "data_layer" | "solver" | "daemon" | "pool";
|
|
10
10
|
export declare function getConnectionInfoFromConfig(destination: TDestination, config: TConfig): {
|
|
11
11
|
hostname: string;
|
|
12
12
|
port: number;
|
package/rpc/index.js
CHANGED
|
@@ -43,6 +43,9 @@ function getConnectionInfoFromConfig(destination, config) {
|
|
|
43
43
|
else if (destination === "data_layer") {
|
|
44
44
|
port = +config["/data_layer/rpc_port"];
|
|
45
45
|
}
|
|
46
|
+
else if (destination === "solver") {
|
|
47
|
+
port = +config["/solver/rpc_port"];
|
|
48
|
+
}
|
|
46
49
|
else if (destination === "pool") {
|
|
47
50
|
const poolUrl = config["/pool/pool_list/0/pool_url"];
|
|
48
51
|
const regex = /^(https?:\/\/)?([^/:]+):?(\d*)/;
|