@taquito/rpc 20.0.0-beta.1 → 20.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/dist/lib/rpc-client-interface.js +1 -0
- package/dist/lib/rpc-client-modules/rpc-cache.js +22 -0
- package/dist/lib/taquito-rpc.js +15 -0
- package/dist/lib/version.js +2 -2
- package/dist/taquito-rpc.es6.js +40 -2
- package/dist/taquito-rpc.es6.js.map +1 -1
- package/dist/taquito-rpc.umd.js +40 -2
- package/dist/taquito-rpc.umd.js.map +1 -1
- package/dist/types/rpc-client-interface.d.ts +3 -1
- package/dist/types/rpc-client-modules/rpc-cache.d.ts +10 -1
- package/dist/types/taquito-rpc.d.ts +10 -1
- package/dist/types/types.d.ts +6 -0
- package/package.json +5 -5
|
@@ -27,6 +27,7 @@ var RPCMethodName;
|
|
|
27
27
|
RPCMethodName["GET_CURRENT_PROPOSAL"] = "getCurrentProposal";
|
|
28
28
|
RPCMethodName["GET_CURRENT_QUORUM"] = "getCurrentQuorum";
|
|
29
29
|
RPCMethodName["GET_DELEGATE"] = "getDelegate";
|
|
30
|
+
RPCMethodName["GET_ALL_DELEGATES"] = "getAllDelegates";
|
|
30
31
|
RPCMethodName["GET_DELEGATES"] = "getDelegates";
|
|
31
32
|
RPCMethodName["GET_VOTING_INFO"] = "getVotingInfo";
|
|
32
33
|
RPCMethodName["GET_ATTESTATION_RIGHTS"] = "getAttestationRights";
|
|
@@ -444,6 +444,28 @@ class RpcClientCache {
|
|
|
444
444
|
}
|
|
445
445
|
});
|
|
446
446
|
}
|
|
447
|
+
/**
|
|
448
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
449
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
450
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
451
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
452
|
+
*/
|
|
453
|
+
getAllDelegates(args = {}, { block } = rpc_client_interface_2.defaultRPCOptions) {
|
|
454
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
455
|
+
const key = this.formatCacheKey(this.rpcClient.getRpcUrl(), rpc_client_interface_1.RPCMethodName.GET_ALL_DELEGATES, [
|
|
456
|
+
block,
|
|
457
|
+
args,
|
|
458
|
+
]);
|
|
459
|
+
if (this.has(key)) {
|
|
460
|
+
return this.get(key);
|
|
461
|
+
}
|
|
462
|
+
else {
|
|
463
|
+
const response = this.rpcClient.getAllDelegates(args, { block });
|
|
464
|
+
this.put(key, response);
|
|
465
|
+
return response;
|
|
466
|
+
}
|
|
467
|
+
});
|
|
468
|
+
}
|
|
447
469
|
/**
|
|
448
470
|
* @param address delegate address which we want to retrieve
|
|
449
471
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
package/dist/lib/taquito-rpc.js
CHANGED
|
@@ -373,6 +373,21 @@ class RpcClient {
|
|
|
373
373
|
});
|
|
374
374
|
});
|
|
375
375
|
}
|
|
376
|
+
/**
|
|
377
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
378
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
379
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
380
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
381
|
+
*/
|
|
382
|
+
getAllDelegates(args = {}, { block } = rpc_client_interface_1.defaultRPCOptions) {
|
|
383
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
384
|
+
return yield this.httpBackend.createRequest({
|
|
385
|
+
url: this.createURL(`/chains/${this.chain}/blocks/${block}/context/delegates`),
|
|
386
|
+
method: 'GET',
|
|
387
|
+
query: args,
|
|
388
|
+
});
|
|
389
|
+
});
|
|
390
|
+
}
|
|
376
391
|
/**
|
|
377
392
|
* @param address delegate address which we want to retrieve
|
|
378
393
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
package/dist/lib/version.js
CHANGED
|
@@ -3,6 +3,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.VERSION = void 0;
|
|
4
4
|
// IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
|
|
5
5
|
exports.VERSION = {
|
|
6
|
-
"commitHash": "
|
|
7
|
-
"version": "20.0.0
|
|
6
|
+
"commitHash": "45fea4a361f29598063e448574800220c4687001",
|
|
7
|
+
"version": "20.0.0"
|
|
8
8
|
};
|
package/dist/taquito-rpc.es6.js
CHANGED
|
@@ -73,6 +73,7 @@ var RPCMethodName;
|
|
|
73
73
|
RPCMethodName["GET_CURRENT_PROPOSAL"] = "getCurrentProposal";
|
|
74
74
|
RPCMethodName["GET_CURRENT_QUORUM"] = "getCurrentQuorum";
|
|
75
75
|
RPCMethodName["GET_DELEGATE"] = "getDelegate";
|
|
76
|
+
RPCMethodName["GET_ALL_DELEGATES"] = "getAllDelegates";
|
|
76
77
|
RPCMethodName["GET_DELEGATES"] = "getDelegates";
|
|
77
78
|
RPCMethodName["GET_VOTING_INFO"] = "getVotingInfo";
|
|
78
79
|
RPCMethodName["GET_ATTESTATION_RIGHTS"] = "getAttestationRights";
|
|
@@ -545,6 +546,28 @@ class RpcClientCache {
|
|
|
545
546
|
}
|
|
546
547
|
});
|
|
547
548
|
}
|
|
549
|
+
/**
|
|
550
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
551
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
552
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
553
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
554
|
+
*/
|
|
555
|
+
getAllDelegates(args = {}, { block } = defaultRPCOptions) {
|
|
556
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
557
|
+
const key = this.formatCacheKey(this.rpcClient.getRpcUrl(), RPCMethodName.GET_ALL_DELEGATES, [
|
|
558
|
+
block,
|
|
559
|
+
args,
|
|
560
|
+
]);
|
|
561
|
+
if (this.has(key)) {
|
|
562
|
+
return this.get(key);
|
|
563
|
+
}
|
|
564
|
+
else {
|
|
565
|
+
const response = this.rpcClient.getAllDelegates(args, { block });
|
|
566
|
+
this.put(key, response);
|
|
567
|
+
return response;
|
|
568
|
+
}
|
|
569
|
+
});
|
|
570
|
+
}
|
|
548
571
|
/**
|
|
549
572
|
* @param address delegate address which we want to retrieve
|
|
550
573
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
@@ -1314,8 +1337,8 @@ var OpKind;
|
|
|
1314
1337
|
|
|
1315
1338
|
// IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
|
|
1316
1339
|
const VERSION = {
|
|
1317
|
-
"commitHash": "
|
|
1318
|
-
"version": "20.0.0
|
|
1340
|
+
"commitHash": "45fea4a361f29598063e448574800220c4687001",
|
|
1341
|
+
"version": "20.0.0"
|
|
1319
1342
|
};
|
|
1320
1343
|
|
|
1321
1344
|
/***
|
|
@@ -1634,6 +1657,21 @@ class RpcClient {
|
|
|
1634
1657
|
});
|
|
1635
1658
|
});
|
|
1636
1659
|
}
|
|
1660
|
+
/**
|
|
1661
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
1662
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
1663
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
1664
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
1665
|
+
*/
|
|
1666
|
+
getAllDelegates(args = {}, { block } = defaultRPCOptions) {
|
|
1667
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1668
|
+
return yield this.httpBackend.createRequest({
|
|
1669
|
+
url: this.createURL(`/chains/${this.chain}/blocks/${block}/context/delegates`),
|
|
1670
|
+
method: 'GET',
|
|
1671
|
+
query: args,
|
|
1672
|
+
});
|
|
1673
|
+
});
|
|
1674
|
+
}
|
|
1637
1675
|
/**
|
|
1638
1676
|
* @param address delegate address which we want to retrieve
|
|
1639
1677
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taquito-rpc.es6.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"taquito-rpc.es6.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/taquito-rpc.umd.js
CHANGED
|
@@ -74,6 +74,7 @@
|
|
|
74
74
|
RPCMethodName["GET_CURRENT_PROPOSAL"] = "getCurrentProposal";
|
|
75
75
|
RPCMethodName["GET_CURRENT_QUORUM"] = "getCurrentQuorum";
|
|
76
76
|
RPCMethodName["GET_DELEGATE"] = "getDelegate";
|
|
77
|
+
RPCMethodName["GET_ALL_DELEGATES"] = "getAllDelegates";
|
|
77
78
|
RPCMethodName["GET_DELEGATES"] = "getDelegates";
|
|
78
79
|
RPCMethodName["GET_VOTING_INFO"] = "getVotingInfo";
|
|
79
80
|
RPCMethodName["GET_ATTESTATION_RIGHTS"] = "getAttestationRights";
|
|
@@ -546,6 +547,28 @@
|
|
|
546
547
|
}
|
|
547
548
|
});
|
|
548
549
|
}
|
|
550
|
+
/**
|
|
551
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
552
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
553
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
554
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
555
|
+
*/
|
|
556
|
+
getAllDelegates(args = {}, { block } = defaultRPCOptions) {
|
|
557
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
558
|
+
const key = this.formatCacheKey(this.rpcClient.getRpcUrl(), RPCMethodName.GET_ALL_DELEGATES, [
|
|
559
|
+
block,
|
|
560
|
+
args,
|
|
561
|
+
]);
|
|
562
|
+
if (this.has(key)) {
|
|
563
|
+
return this.get(key);
|
|
564
|
+
}
|
|
565
|
+
else {
|
|
566
|
+
const response = this.rpcClient.getAllDelegates(args, { block });
|
|
567
|
+
this.put(key, response);
|
|
568
|
+
return response;
|
|
569
|
+
}
|
|
570
|
+
});
|
|
571
|
+
}
|
|
549
572
|
/**
|
|
550
573
|
* @param address delegate address which we want to retrieve
|
|
551
574
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
@@ -1315,8 +1338,8 @@
|
|
|
1315
1338
|
|
|
1316
1339
|
// IMPORTANT: THIS FILE IS AUTO GENERATED! DO NOT MANUALLY EDIT OR CHECKIN!
|
|
1317
1340
|
const VERSION = {
|
|
1318
|
-
"commitHash": "
|
|
1319
|
-
"version": "20.0.0
|
|
1341
|
+
"commitHash": "45fea4a361f29598063e448574800220c4687001",
|
|
1342
|
+
"version": "20.0.0"
|
|
1320
1343
|
};
|
|
1321
1344
|
|
|
1322
1345
|
/***
|
|
@@ -1635,6 +1658,21 @@
|
|
|
1635
1658
|
});
|
|
1636
1659
|
});
|
|
1637
1660
|
}
|
|
1661
|
+
/**
|
|
1662
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
1663
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
1664
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
1665
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
1666
|
+
*/
|
|
1667
|
+
getAllDelegates(args = {}, { block } = defaultRPCOptions) {
|
|
1668
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
1669
|
+
return yield this.httpBackend.createRequest({
|
|
1670
|
+
url: this.createURL(`/chains/${this.chain}/blocks/${block}/context/delegates`),
|
|
1671
|
+
method: 'GET',
|
|
1672
|
+
query: args,
|
|
1673
|
+
});
|
|
1674
|
+
});
|
|
1675
|
+
}
|
|
1638
1676
|
/**
|
|
1639
1677
|
* @param address delegate address which we want to retrieve
|
|
1640
1678
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taquito-rpc.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"taquito-rpc.umd.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BigNumber } from 'bignumber.js';
|
|
2
|
-
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunScriptViewParam, RPCRunViewParam, RunCodeResult, RunScriptViewResult, RunViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingInfoResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsV1, PendingOperationsV2, PendingOperationsQueryArguments, RPCSimulateOperationParam, AILaunchCycleResponse } from './types';
|
|
2
|
+
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunScriptViewParam, RPCRunViewParam, RunCodeResult, RunScriptViewResult, RunViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingInfoResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsV1, PendingOperationsV2, PendingOperationsQueryArguments, RPCSimulateOperationParam, AILaunchCycleResponse, AllDelegatesQueryArguments } from './types';
|
|
3
3
|
export interface RPCOptions {
|
|
4
4
|
block: string;
|
|
5
5
|
version?: 0 | 1 | '0' | '1';
|
|
@@ -23,6 +23,7 @@ export interface RpcClientInterface {
|
|
|
23
23
|
getDelegate(address: string, options?: RPCOptions): Promise<DelegateResponse>;
|
|
24
24
|
getBigMapKey(address: string, key: BigMapKey, options?: RPCOptions): Promise<BigMapGetResponse>;
|
|
25
25
|
getBigMapExpr(id: string, expr: string, options?: RPCOptions): Promise<BigMapResponse>;
|
|
26
|
+
getAllDelegates(args: AllDelegatesQueryArguments, options?: RPCOptions): Promise<string[]>;
|
|
26
27
|
getDelegates(address: string, options?: RPCOptions): Promise<DelegatesResponse>;
|
|
27
28
|
getVotingInfo(address: string, options?: RPCOptions): Promise<VotingInfoResponse>;
|
|
28
29
|
getConstants(options?: RPCOptions): Promise<ConstantsResponse>;
|
|
@@ -87,6 +88,7 @@ export declare enum RPCMethodName {
|
|
|
87
88
|
GET_CURRENT_PROPOSAL = "getCurrentProposal",
|
|
88
89
|
GET_CURRENT_QUORUM = "getCurrentQuorum",
|
|
89
90
|
GET_DELEGATE = "getDelegate",
|
|
91
|
+
GET_ALL_DELEGATES = "getAllDelegates",
|
|
90
92
|
GET_DELEGATES = "getDelegates",
|
|
91
93
|
GET_VOTING_INFO = "getVotingInfo",
|
|
92
94
|
GET_ATTESTATION_RIGHTS = "getAttestationRights",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import BigNumber from 'bignumber.js';
|
|
2
2
|
import { RpcClientInterface, RPCOptions } from '../rpc-client-interface';
|
|
3
|
-
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, VotingInfoResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunScriptViewParam, RPCRunViewParam, RunCodeResult, RunScriptViewResult, RunViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsQueryArguments, PendingOperationsV1, PendingOperationsV2, RPCSimulateOperationParam, AILaunchCycleResponse } from '../types';
|
|
3
|
+
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, VotingInfoResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunScriptViewParam, RPCRunViewParam, RunCodeResult, RunScriptViewResult, RunViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsQueryArguments, PendingOperationsV1, PendingOperationsV2, RPCSimulateOperationParam, AILaunchCycleResponse, AllDelegatesQueryArguments } from '../types';
|
|
4
4
|
interface CachedDataInterface {
|
|
5
5
|
[key: string]: {
|
|
6
6
|
handle: () => void;
|
|
@@ -163,6 +163,15 @@ export declare class RpcClientCache implements RpcClientInterface {
|
|
|
163
163
|
getBigMapExpr(id: string, expr: string, { block }?: {
|
|
164
164
|
block: string;
|
|
165
165
|
}): Promise<BigMapResponse>;
|
|
166
|
+
/**
|
|
167
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
168
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
169
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
170
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
171
|
+
*/
|
|
172
|
+
getAllDelegates(args?: AllDelegatesQueryArguments, { block }?: {
|
|
173
|
+
block: string;
|
|
174
|
+
}): Promise<string[]>;
|
|
166
175
|
/**
|
|
167
176
|
* @param address delegate address which we want to retrieve
|
|
168
177
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import { HttpBackend } from '@taquito/http-utils';
|
|
6
6
|
import BigNumber from 'bignumber.js';
|
|
7
7
|
import { RpcClientInterface, RPCOptions } from './rpc-client-interface';
|
|
8
|
-
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, VotingInfoResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunViewParam, RPCRunScriptViewParam, RunCodeResult, RunViewResult, RunScriptViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsQueryArguments, PendingOperationsV1, PendingOperationsV2, RPCSimulateOperationParam, AILaunchCycleResponse } from './types';
|
|
8
|
+
import { BakingRightsQueryArguments, BakingRightsResponse, BalanceResponse, UnstakeRequestsResponse, BallotListResponse, BallotsResponse, BigMapGetResponse, BigMapKey, BigMapResponse, BlockHeaderResponse, BlockMetadata, BlockResponse, ConstantsResponse, ContractResponse, CurrentProposalResponse, CurrentQuorumResponse, DelegateResponse, DelegatesResponse, VotingInfoResponse, AttestationRightsQueryArguments, AttestationRightsResponse, EntrypointsResponse, ForgeOperationsParams, ManagerKeyResponse, OperationHash, PackDataParams, PreapplyParams, PreapplyResponse, ProposalsResponse, ProtocolsResponse, RPCRunCodeParam, RPCRunOperationParam, RPCRunViewParam, RPCRunScriptViewParam, RunCodeResult, RunViewResult, RunScriptViewResult, SaplingDiffResponse, ScriptResponse, StorageResponse, UnparsingMode, VotesListingsResponse, VotingPeriodBlockResult, TicketTokenParams, AllTicketBalances, PendingOperationsQueryArguments, PendingOperationsV1, PendingOperationsV2, RPCSimulateOperationParam, AILaunchCycleResponse, AllDelegatesQueryArguments } from './types';
|
|
9
9
|
export { castToBigNumber } from './utils/utils';
|
|
10
10
|
export { RPCOptions, defaultChain, defaultRPCOptions, RpcClientInterface, } from './rpc-client-interface';
|
|
11
11
|
export { RpcClientCache } from './rpc-client-modules/rpc-cache';
|
|
@@ -160,6 +160,15 @@ export declare class RpcClient implements RpcClientInterface {
|
|
|
160
160
|
getBigMapExpr(id: string, expr: string, { block }?: {
|
|
161
161
|
block: string;
|
|
162
162
|
}): Promise<BigMapResponse>;
|
|
163
|
+
/**
|
|
164
|
+
* @param args contains optional query arguments (active, inactive, with_minimal_stake, without_minimal_stake)
|
|
165
|
+
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
|
166
|
+
* @description Lists all registered delegates by default with query arguments to filter unneeded values.
|
|
167
|
+
* @see https://tezos.gitlab.io/active/rpc.html#get-block-id-context-delegates-pkh
|
|
168
|
+
*/
|
|
169
|
+
getAllDelegates(args?: AllDelegatesQueryArguments, { block }?: {
|
|
170
|
+
block: string;
|
|
171
|
+
}): Promise<string[]>;
|
|
163
172
|
/**
|
|
164
173
|
* @param address delegate address which we want to retrieve
|
|
165
174
|
* @param options contains generic configuration for rpc calls to specified block (default to head)
|
package/dist/types/types.d.ts
CHANGED
|
@@ -923,6 +923,12 @@ export interface BlockResponse {
|
|
|
923
923
|
export type BakingRightsArgumentsDelegate = string | string[];
|
|
924
924
|
export type BakingRightsArgumentsCycle = number | number[];
|
|
925
925
|
export type BakingRightsArgumentsLevel = number | number[];
|
|
926
|
+
export type AllDelegatesQueryArguments = {
|
|
927
|
+
active?: boolean;
|
|
928
|
+
inactive?: boolean;
|
|
929
|
+
with_minimal_stake?: boolean;
|
|
930
|
+
without_minimal_stake?: boolean;
|
|
931
|
+
};
|
|
926
932
|
export type BakingRightsQueryArguments = BakingRightsQueryArgumentsBase;
|
|
927
933
|
export interface BakingRightsQueryArgumentsBase {
|
|
928
934
|
level?: BakingRightsArgumentsLevel;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@taquito/rpc",
|
|
3
|
-
"version": "20.0.0
|
|
3
|
+
"version": "20.0.0",
|
|
4
4
|
"description": "Provides low level methods, and types to invoke RPC calls from a Nomadic Tezos RPC node",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"tezos",
|
|
@@ -66,9 +66,9 @@
|
|
|
66
66
|
]
|
|
67
67
|
},
|
|
68
68
|
"dependencies": {
|
|
69
|
-
"@taquito/core": "^20.0.0
|
|
70
|
-
"@taquito/http-utils": "^20.0.0
|
|
71
|
-
"@taquito/utils": "^20.0.0
|
|
69
|
+
"@taquito/core": "^20.0.0",
|
|
70
|
+
"@taquito/http-utils": "^20.0.0",
|
|
71
|
+
"@taquito/utils": "^20.0.0",
|
|
72
72
|
"bignumber.js": "^9.1.2"
|
|
73
73
|
},
|
|
74
74
|
"devDependencies": {
|
|
@@ -98,5 +98,5 @@
|
|
|
98
98
|
"ts-toolbelt": "^9.6.0",
|
|
99
99
|
"typescript": "~5.2.2"
|
|
100
100
|
},
|
|
101
|
-
"gitHead": "
|
|
101
|
+
"gitHead": "4871f03155be8dfce81ff24cb45fe0e3049c7646"
|
|
102
102
|
}
|