dash-platform-sdk 1.4.0-dev.3 → 1.4.0-dev.5
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/bundle.min.js +17 -17
- package/package.json +2 -2
- package/proto/generated/platform.client.d.ts +10 -0
- package/proto/generated/platform.client.js +7 -0
- package/proto/generated/platform.d.ts +160 -0
- package/proto/generated/platform.js +333 -1
- package/src/DashPlatformSDK.d.ts +3 -1
- package/src/DashPlatformSDK.js +8 -5
- package/src/dataContracts/create.d.ts +2 -2
- package/src/dataContracts/getDataContractByIdentifier.d.ts +1 -2
- package/src/dataContracts/index.d.ts +2 -2
- package/src/documents/create.d.ts +1 -2
- package/src/documents/index.d.ts +2 -2
- package/src/documents/query.d.ts +1 -2
- package/src/identities/getIdentityBalance.d.ts +1 -1
- package/src/identities/getIdentityByIdentifier.d.ts +1 -2
- package/src/identities/getIdentityContractNonce.d.ts +1 -1
- package/src/identities/getIdentityNonce.d.ts +1 -1
- package/src/identities/getIdentityPublicKeys.d.ts +1 -2
- package/src/identities/index.d.ts +2 -2
- package/src/names/index.d.ts +1 -2
- package/src/node/index.d.ts +2 -3
- package/src/node/index.js +2 -4
- package/src/node/totalCredits.d.ts +1 -2
- package/src/node/totalCredits.js +2 -2
- package/src/platformAddresses/getAddressInfo.d.ts +4 -0
- package/src/platformAddresses/getAddressInfo.js +45 -0
- package/src/platformAddresses/index.d.ts +15 -0
- package/src/platformAddresses/index.js +17 -0
- package/src/tokens/getIdentitiesTokenBalances.d.ts +1 -2
- package/src/tokens/getIdentityTokensBalances.d.ts +1 -2
- package/src/tokens/getTokenContractInfo.d.ts +1 -2
- package/src/tokens/getTokenDirectPurchasePrices.d.ts +2 -1
- package/src/tokens/getTokenTotalSupply.d.ts +2 -1
- package/src/tokens/index.d.ts +2 -2
- package/src/utils/index.d.ts +1 -2
- package/src/voting/index.d.ts +2 -2
- package/test/unit/PlatformAddress.spec.d.ts +1 -0
- package/test/unit/PlatformAddress.spec.js +13 -0
- package/types.d.ts +7 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dash-platform-sdk",
|
|
3
|
-
"version": "1.4.0-dev.
|
|
3
|
+
"version": "1.4.0-dev.5",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"description": "Lightweight SDK for accessing Dash Platform blockchain",
|
|
6
6
|
"ts-standard": {
|
|
@@ -55,6 +55,6 @@
|
|
|
55
55
|
"@scure/bip39": "^2.0.0",
|
|
56
56
|
"@scure/btc-signer": "^2.0.1",
|
|
57
57
|
"cbor-x": "^1.6.0",
|
|
58
|
-
"pshenmic-dpp": "2.0.0-dev.
|
|
58
|
+
"pshenmic-dpp": "2.0.0-dev.7"
|
|
59
59
|
}
|
|
60
60
|
}
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
import type { RpcTransport } from "@protobuf-ts/runtime-rpc";
|
|
2
2
|
import type { ServiceInfo } from "@protobuf-ts/runtime-rpc";
|
|
3
|
+
import type { GetAddressInfoResponse } from "./platform.js";
|
|
4
|
+
import type { GetAddressInfoRequest } from "./platform.js";
|
|
3
5
|
import type { WaitForStateTransitionResultResponse } from "./platform.js";
|
|
4
6
|
import type { WaitForStateTransitionResultRequest } from "./platform.js";
|
|
5
7
|
import type { GetTokenTotalSupplyResponse } from "./platform.js";
|
|
@@ -150,6 +152,10 @@ export interface IPlatformClient {
|
|
|
150
152
|
* @generated from protobuf rpc: waitForStateTransitionResult
|
|
151
153
|
*/
|
|
152
154
|
waitForStateTransitionResult(input: WaitForStateTransitionResultRequest, options?: RpcOptions): UnaryCall<WaitForStateTransitionResultRequest, WaitForStateTransitionResultResponse>;
|
|
155
|
+
/**
|
|
156
|
+
* @generated from protobuf rpc: getAddressInfo
|
|
157
|
+
*/
|
|
158
|
+
getAddressInfo(input: GetAddressInfoRequest, options?: RpcOptions): UnaryCall<GetAddressInfoRequest, GetAddressInfoResponse>;
|
|
153
159
|
}
|
|
154
160
|
/**
|
|
155
161
|
* @generated from protobuf service org.dash.platform.dapi.v0.Platform
|
|
@@ -258,4 +264,8 @@ export declare class PlatformClient implements IPlatformClient, ServiceInfo {
|
|
|
258
264
|
* @generated from protobuf rpc: waitForStateTransitionResult
|
|
259
265
|
*/
|
|
260
266
|
waitForStateTransitionResult(input: WaitForStateTransitionResultRequest, options?: RpcOptions): UnaryCall<WaitForStateTransitionResultRequest, WaitForStateTransitionResultResponse>;
|
|
267
|
+
/**
|
|
268
|
+
* @generated from protobuf rpc: getAddressInfo
|
|
269
|
+
*/
|
|
270
|
+
getAddressInfo(input: GetAddressInfoRequest, options?: RpcOptions): UnaryCall<GetAddressInfoRequest, GetAddressInfoResponse>;
|
|
261
271
|
}
|
|
@@ -179,4 +179,11 @@ export class PlatformClient {
|
|
|
179
179
|
const method = this.methods[23], opt = this._transport.mergeOptions(options);
|
|
180
180
|
return stackIntercept("unary", this._transport, method, opt, input);
|
|
181
181
|
}
|
|
182
|
+
/**
|
|
183
|
+
* @generated from protobuf rpc: getAddressInfo
|
|
184
|
+
*/
|
|
185
|
+
getAddressInfo(input, options) {
|
|
186
|
+
const method = this.methods[24], opt = this._transport.mergeOptions(options);
|
|
187
|
+
return stackIntercept("unary", this._transport, method, opt, input);
|
|
188
|
+
}
|
|
182
189
|
}
|
|
@@ -2783,6 +2783,106 @@ export interface WaitForStateTransitionResultResponse_WaitForStateTransitionResu
|
|
|
2783
2783
|
*/
|
|
2784
2784
|
metadata?: ResponseMetadata;
|
|
2785
2785
|
}
|
|
2786
|
+
/**
|
|
2787
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest
|
|
2788
|
+
*/
|
|
2789
|
+
export interface GetAddressInfoRequest {
|
|
2790
|
+
/**
|
|
2791
|
+
* @generated from protobuf oneof: version
|
|
2792
|
+
*/
|
|
2793
|
+
version: {
|
|
2794
|
+
oneofKind: "v0";
|
|
2795
|
+
/**
|
|
2796
|
+
* @generated from protobuf field: org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0 v0 = 1
|
|
2797
|
+
*/
|
|
2798
|
+
v0: GetAddressInfoRequest_GetAddressInfoRequestV0;
|
|
2799
|
+
} | {
|
|
2800
|
+
oneofKind: undefined;
|
|
2801
|
+
};
|
|
2802
|
+
}
|
|
2803
|
+
/**
|
|
2804
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0
|
|
2805
|
+
*/
|
|
2806
|
+
export interface GetAddressInfoRequest_GetAddressInfoRequestV0 {
|
|
2807
|
+
/**
|
|
2808
|
+
* @generated from protobuf field: bytes address = 1
|
|
2809
|
+
*/
|
|
2810
|
+
address: Uint8Array;
|
|
2811
|
+
/**
|
|
2812
|
+
* @generated from protobuf field: bool prove = 2
|
|
2813
|
+
*/
|
|
2814
|
+
prove: boolean;
|
|
2815
|
+
}
|
|
2816
|
+
/**
|
|
2817
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.AddressInfoEntry
|
|
2818
|
+
*/
|
|
2819
|
+
export interface AddressInfoEntry {
|
|
2820
|
+
/**
|
|
2821
|
+
* @generated from protobuf field: bytes address = 1
|
|
2822
|
+
*/
|
|
2823
|
+
address: Uint8Array;
|
|
2824
|
+
/**
|
|
2825
|
+
* @generated from protobuf field: optional org.dash.platform.dapi.v0.BalanceAndNonce balance_and_nonce = 2
|
|
2826
|
+
*/
|
|
2827
|
+
balanceAndNonce?: BalanceAndNonce;
|
|
2828
|
+
}
|
|
2829
|
+
/**
|
|
2830
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.BalanceAndNonce
|
|
2831
|
+
*/
|
|
2832
|
+
export interface BalanceAndNonce {
|
|
2833
|
+
/**
|
|
2834
|
+
* @generated from protobuf field: uint64 balance = 1
|
|
2835
|
+
*/
|
|
2836
|
+
balance: string;
|
|
2837
|
+
/**
|
|
2838
|
+
* @generated from protobuf field: uint32 nonce = 2
|
|
2839
|
+
*/
|
|
2840
|
+
nonce: number;
|
|
2841
|
+
}
|
|
2842
|
+
/**
|
|
2843
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse
|
|
2844
|
+
*/
|
|
2845
|
+
export interface GetAddressInfoResponse {
|
|
2846
|
+
/**
|
|
2847
|
+
* @generated from protobuf oneof: version
|
|
2848
|
+
*/
|
|
2849
|
+
version: {
|
|
2850
|
+
oneofKind: "v0";
|
|
2851
|
+
/**
|
|
2852
|
+
* @generated from protobuf field: org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0 v0 = 1
|
|
2853
|
+
*/
|
|
2854
|
+
v0: GetAddressInfoResponse_GetAddressInfoResponseV0;
|
|
2855
|
+
} | {
|
|
2856
|
+
oneofKind: undefined;
|
|
2857
|
+
};
|
|
2858
|
+
}
|
|
2859
|
+
/**
|
|
2860
|
+
* @generated from protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0
|
|
2861
|
+
*/
|
|
2862
|
+
export interface GetAddressInfoResponse_GetAddressInfoResponseV0 {
|
|
2863
|
+
/**
|
|
2864
|
+
* @generated from protobuf oneof: result
|
|
2865
|
+
*/
|
|
2866
|
+
result: {
|
|
2867
|
+
oneofKind: "addressInfoEntry";
|
|
2868
|
+
/**
|
|
2869
|
+
* @generated from protobuf field: org.dash.platform.dapi.v0.AddressInfoEntry address_info_entry = 1
|
|
2870
|
+
*/
|
|
2871
|
+
addressInfoEntry: AddressInfoEntry;
|
|
2872
|
+
} | {
|
|
2873
|
+
oneofKind: "proof";
|
|
2874
|
+
/**
|
|
2875
|
+
* @generated from protobuf field: org.dash.platform.dapi.v0.Proof proof = 2
|
|
2876
|
+
*/
|
|
2877
|
+
proof: Proof;
|
|
2878
|
+
} | {
|
|
2879
|
+
oneofKind: undefined;
|
|
2880
|
+
};
|
|
2881
|
+
/**
|
|
2882
|
+
* @generated from protobuf field: org.dash.platform.dapi.v0.ResponseMetadata metadata = 3
|
|
2883
|
+
*/
|
|
2884
|
+
metadata?: ResponseMetadata;
|
|
2885
|
+
}
|
|
2786
2886
|
/**
|
|
2787
2887
|
* @generated from protobuf enum org.dash.platform.dapi.v0.KeyPurpose
|
|
2788
2888
|
*/
|
|
@@ -4251,6 +4351,66 @@ declare class WaitForStateTransitionResultResponse_WaitForStateTransitionResultR
|
|
|
4251
4351
|
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.WaitForStateTransitionResultResponse.WaitForStateTransitionResultResponseV0
|
|
4252
4352
|
*/
|
|
4253
4353
|
export declare const WaitForStateTransitionResultResponse_WaitForStateTransitionResultResponseV0: WaitForStateTransitionResultResponse_WaitForStateTransitionResultResponseV0$Type;
|
|
4354
|
+
declare class GetAddressInfoRequest$Type extends MessageType<GetAddressInfoRequest> {
|
|
4355
|
+
constructor();
|
|
4356
|
+
create(value?: PartialMessage<GetAddressInfoRequest>): GetAddressInfoRequest;
|
|
4357
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAddressInfoRequest): GetAddressInfoRequest;
|
|
4358
|
+
internalBinaryWrite(message: GetAddressInfoRequest, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4359
|
+
}
|
|
4360
|
+
/**
|
|
4361
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest
|
|
4362
|
+
*/
|
|
4363
|
+
export declare const GetAddressInfoRequest: GetAddressInfoRequest$Type;
|
|
4364
|
+
declare class GetAddressInfoRequest_GetAddressInfoRequestV0$Type extends MessageType<GetAddressInfoRequest_GetAddressInfoRequestV0> {
|
|
4365
|
+
constructor();
|
|
4366
|
+
create(value?: PartialMessage<GetAddressInfoRequest_GetAddressInfoRequestV0>): GetAddressInfoRequest_GetAddressInfoRequestV0;
|
|
4367
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAddressInfoRequest_GetAddressInfoRequestV0): GetAddressInfoRequest_GetAddressInfoRequestV0;
|
|
4368
|
+
internalBinaryWrite(message: GetAddressInfoRequest_GetAddressInfoRequestV0, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4369
|
+
}
|
|
4370
|
+
/**
|
|
4371
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0
|
|
4372
|
+
*/
|
|
4373
|
+
export declare const GetAddressInfoRequest_GetAddressInfoRequestV0: GetAddressInfoRequest_GetAddressInfoRequestV0$Type;
|
|
4374
|
+
declare class AddressInfoEntry$Type extends MessageType<AddressInfoEntry> {
|
|
4375
|
+
constructor();
|
|
4376
|
+
create(value?: PartialMessage<AddressInfoEntry>): AddressInfoEntry;
|
|
4377
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: AddressInfoEntry): AddressInfoEntry;
|
|
4378
|
+
internalBinaryWrite(message: AddressInfoEntry, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4379
|
+
}
|
|
4380
|
+
/**
|
|
4381
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.AddressInfoEntry
|
|
4382
|
+
*/
|
|
4383
|
+
export declare const AddressInfoEntry: AddressInfoEntry$Type;
|
|
4384
|
+
declare class BalanceAndNonce$Type extends MessageType<BalanceAndNonce> {
|
|
4385
|
+
constructor();
|
|
4386
|
+
create(value?: PartialMessage<BalanceAndNonce>): BalanceAndNonce;
|
|
4387
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: BalanceAndNonce): BalanceAndNonce;
|
|
4388
|
+
internalBinaryWrite(message: BalanceAndNonce, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4389
|
+
}
|
|
4390
|
+
/**
|
|
4391
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.BalanceAndNonce
|
|
4392
|
+
*/
|
|
4393
|
+
export declare const BalanceAndNonce: BalanceAndNonce$Type;
|
|
4394
|
+
declare class GetAddressInfoResponse$Type extends MessageType<GetAddressInfoResponse> {
|
|
4395
|
+
constructor();
|
|
4396
|
+
create(value?: PartialMessage<GetAddressInfoResponse>): GetAddressInfoResponse;
|
|
4397
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAddressInfoResponse): GetAddressInfoResponse;
|
|
4398
|
+
internalBinaryWrite(message: GetAddressInfoResponse, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4399
|
+
}
|
|
4400
|
+
/**
|
|
4401
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse
|
|
4402
|
+
*/
|
|
4403
|
+
export declare const GetAddressInfoResponse: GetAddressInfoResponse$Type;
|
|
4404
|
+
declare class GetAddressInfoResponse_GetAddressInfoResponseV0$Type extends MessageType<GetAddressInfoResponse_GetAddressInfoResponseV0> {
|
|
4405
|
+
constructor();
|
|
4406
|
+
create(value?: PartialMessage<GetAddressInfoResponse_GetAddressInfoResponseV0>): GetAddressInfoResponse_GetAddressInfoResponseV0;
|
|
4407
|
+
internalBinaryRead(reader: IBinaryReader, length: number, options: BinaryReadOptions, target?: GetAddressInfoResponse_GetAddressInfoResponseV0): GetAddressInfoResponse_GetAddressInfoResponseV0;
|
|
4408
|
+
internalBinaryWrite(message: GetAddressInfoResponse_GetAddressInfoResponseV0, writer: IBinaryWriter, options: BinaryWriteOptions): IBinaryWriter;
|
|
4409
|
+
}
|
|
4410
|
+
/**
|
|
4411
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0
|
|
4412
|
+
*/
|
|
4413
|
+
export declare const GetAddressInfoResponse_GetAddressInfoResponseV0: GetAddressInfoResponse_GetAddressInfoResponseV0$Type;
|
|
4254
4414
|
/**
|
|
4255
4415
|
* @generated ServiceType for protobuf service org.dash.platform.dapi.v0.Platform
|
|
4256
4416
|
*/
|
|
@@ -8469,6 +8469,337 @@ class WaitForStateTransitionResultResponse_WaitForStateTransitionResultResponseV
|
|
|
8469
8469
|
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.WaitForStateTransitionResultResponse.WaitForStateTransitionResultResponseV0
|
|
8470
8470
|
*/
|
|
8471
8471
|
export const WaitForStateTransitionResultResponse_WaitForStateTransitionResultResponseV0 = new WaitForStateTransitionResultResponse_WaitForStateTransitionResultResponseV0$Type();
|
|
8472
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8473
|
+
class GetAddressInfoRequest$Type extends MessageType {
|
|
8474
|
+
constructor() {
|
|
8475
|
+
super("org.dash.platform.dapi.v0.GetAddressInfoRequest", [
|
|
8476
|
+
{ no: 1, name: "v0", kind: "message", oneof: "version", T: () => GetAddressInfoRequest_GetAddressInfoRequestV0 }
|
|
8477
|
+
]);
|
|
8478
|
+
}
|
|
8479
|
+
create(value) {
|
|
8480
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8481
|
+
message.version = { oneofKind: undefined };
|
|
8482
|
+
if (value !== undefined)
|
|
8483
|
+
reflectionMergePartial(this, message, value);
|
|
8484
|
+
return message;
|
|
8485
|
+
}
|
|
8486
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8487
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8488
|
+
while (reader.pos < end) {
|
|
8489
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8490
|
+
switch (fieldNo) {
|
|
8491
|
+
case /* org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0 v0 */ 1:
|
|
8492
|
+
message.version = {
|
|
8493
|
+
oneofKind: "v0",
|
|
8494
|
+
v0: GetAddressInfoRequest_GetAddressInfoRequestV0.internalBinaryRead(reader, reader.uint32(), options, message.version.v0)
|
|
8495
|
+
};
|
|
8496
|
+
break;
|
|
8497
|
+
default:
|
|
8498
|
+
let u = options.readUnknownField;
|
|
8499
|
+
if (u === "throw")
|
|
8500
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8501
|
+
let d = reader.skip(wireType);
|
|
8502
|
+
if (u !== false)
|
|
8503
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8504
|
+
}
|
|
8505
|
+
}
|
|
8506
|
+
return message;
|
|
8507
|
+
}
|
|
8508
|
+
internalBinaryWrite(message, writer, options) {
|
|
8509
|
+
/* org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0 v0 = 1; */
|
|
8510
|
+
if (message.version.oneofKind === "v0")
|
|
8511
|
+
GetAddressInfoRequest_GetAddressInfoRequestV0.internalBinaryWrite(message.version.v0, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
8512
|
+
let u = options.writeUnknownFields;
|
|
8513
|
+
if (u !== false)
|
|
8514
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8515
|
+
return writer;
|
|
8516
|
+
}
|
|
8517
|
+
}
|
|
8518
|
+
/**
|
|
8519
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest
|
|
8520
|
+
*/
|
|
8521
|
+
export const GetAddressInfoRequest = new GetAddressInfoRequest$Type();
|
|
8522
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8523
|
+
class GetAddressInfoRequest_GetAddressInfoRequestV0$Type extends MessageType {
|
|
8524
|
+
constructor() {
|
|
8525
|
+
super("org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0", [
|
|
8526
|
+
{ no: 1, name: "address", kind: "scalar", T: 12 /*ScalarType.BYTES*/ },
|
|
8527
|
+
{ no: 2, name: "prove", kind: "scalar", T: 8 /*ScalarType.BOOL*/ }
|
|
8528
|
+
]);
|
|
8529
|
+
}
|
|
8530
|
+
create(value) {
|
|
8531
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8532
|
+
message.address = new Uint8Array(0);
|
|
8533
|
+
message.prove = false;
|
|
8534
|
+
if (value !== undefined)
|
|
8535
|
+
reflectionMergePartial(this, message, value);
|
|
8536
|
+
return message;
|
|
8537
|
+
}
|
|
8538
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8539
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8540
|
+
while (reader.pos < end) {
|
|
8541
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8542
|
+
switch (fieldNo) {
|
|
8543
|
+
case /* bytes address */ 1:
|
|
8544
|
+
message.address = reader.bytes();
|
|
8545
|
+
break;
|
|
8546
|
+
case /* bool prove */ 2:
|
|
8547
|
+
message.prove = reader.bool();
|
|
8548
|
+
break;
|
|
8549
|
+
default:
|
|
8550
|
+
let u = options.readUnknownField;
|
|
8551
|
+
if (u === "throw")
|
|
8552
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8553
|
+
let d = reader.skip(wireType);
|
|
8554
|
+
if (u !== false)
|
|
8555
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8556
|
+
}
|
|
8557
|
+
}
|
|
8558
|
+
return message;
|
|
8559
|
+
}
|
|
8560
|
+
internalBinaryWrite(message, writer, options) {
|
|
8561
|
+
/* bytes address = 1; */
|
|
8562
|
+
if (message.address.length)
|
|
8563
|
+
writer.tag(1, WireType.LengthDelimited).bytes(message.address);
|
|
8564
|
+
/* bool prove = 2; */
|
|
8565
|
+
if (message.prove !== false)
|
|
8566
|
+
writer.tag(2, WireType.Varint).bool(message.prove);
|
|
8567
|
+
let u = options.writeUnknownFields;
|
|
8568
|
+
if (u !== false)
|
|
8569
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8570
|
+
return writer;
|
|
8571
|
+
}
|
|
8572
|
+
}
|
|
8573
|
+
/**
|
|
8574
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoRequest.GetAddressInfoRequestV0
|
|
8575
|
+
*/
|
|
8576
|
+
export const GetAddressInfoRequest_GetAddressInfoRequestV0 = new GetAddressInfoRequest_GetAddressInfoRequestV0$Type();
|
|
8577
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8578
|
+
class AddressInfoEntry$Type extends MessageType {
|
|
8579
|
+
constructor() {
|
|
8580
|
+
super("org.dash.platform.dapi.v0.AddressInfoEntry", [
|
|
8581
|
+
{ no: 1, name: "address", kind: "scalar", T: 12 /*ScalarType.BYTES*/ },
|
|
8582
|
+
{ no: 2, name: "balance_and_nonce", kind: "message", T: () => BalanceAndNonce }
|
|
8583
|
+
]);
|
|
8584
|
+
}
|
|
8585
|
+
create(value) {
|
|
8586
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8587
|
+
message.address = new Uint8Array(0);
|
|
8588
|
+
if (value !== undefined)
|
|
8589
|
+
reflectionMergePartial(this, message, value);
|
|
8590
|
+
return message;
|
|
8591
|
+
}
|
|
8592
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8593
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8594
|
+
while (reader.pos < end) {
|
|
8595
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8596
|
+
switch (fieldNo) {
|
|
8597
|
+
case /* bytes address */ 1:
|
|
8598
|
+
message.address = reader.bytes();
|
|
8599
|
+
break;
|
|
8600
|
+
case /* optional org.dash.platform.dapi.v0.BalanceAndNonce balance_and_nonce */ 2:
|
|
8601
|
+
message.balanceAndNonce = BalanceAndNonce.internalBinaryRead(reader, reader.uint32(), options, message.balanceAndNonce);
|
|
8602
|
+
break;
|
|
8603
|
+
default:
|
|
8604
|
+
let u = options.readUnknownField;
|
|
8605
|
+
if (u === "throw")
|
|
8606
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8607
|
+
let d = reader.skip(wireType);
|
|
8608
|
+
if (u !== false)
|
|
8609
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8610
|
+
}
|
|
8611
|
+
}
|
|
8612
|
+
return message;
|
|
8613
|
+
}
|
|
8614
|
+
internalBinaryWrite(message, writer, options) {
|
|
8615
|
+
/* bytes address = 1; */
|
|
8616
|
+
if (message.address.length)
|
|
8617
|
+
writer.tag(1, WireType.LengthDelimited).bytes(message.address);
|
|
8618
|
+
/* optional org.dash.platform.dapi.v0.BalanceAndNonce balance_and_nonce = 2; */
|
|
8619
|
+
if (message.balanceAndNonce)
|
|
8620
|
+
BalanceAndNonce.internalBinaryWrite(message.balanceAndNonce, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
8621
|
+
let u = options.writeUnknownFields;
|
|
8622
|
+
if (u !== false)
|
|
8623
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8624
|
+
return writer;
|
|
8625
|
+
}
|
|
8626
|
+
}
|
|
8627
|
+
/**
|
|
8628
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.AddressInfoEntry
|
|
8629
|
+
*/
|
|
8630
|
+
export const AddressInfoEntry = new AddressInfoEntry$Type();
|
|
8631
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8632
|
+
class BalanceAndNonce$Type extends MessageType {
|
|
8633
|
+
constructor() {
|
|
8634
|
+
super("org.dash.platform.dapi.v0.BalanceAndNonce", [
|
|
8635
|
+
{ no: 1, name: "balance", kind: "scalar", T: 4 /*ScalarType.UINT64*/ },
|
|
8636
|
+
{ no: 2, name: "nonce", kind: "scalar", T: 13 /*ScalarType.UINT32*/ }
|
|
8637
|
+
]);
|
|
8638
|
+
}
|
|
8639
|
+
create(value) {
|
|
8640
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8641
|
+
message.balance = "0";
|
|
8642
|
+
message.nonce = 0;
|
|
8643
|
+
if (value !== undefined)
|
|
8644
|
+
reflectionMergePartial(this, message, value);
|
|
8645
|
+
return message;
|
|
8646
|
+
}
|
|
8647
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8648
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8649
|
+
while (reader.pos < end) {
|
|
8650
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8651
|
+
switch (fieldNo) {
|
|
8652
|
+
case /* uint64 balance */ 1:
|
|
8653
|
+
message.balance = reader.uint64().toString();
|
|
8654
|
+
break;
|
|
8655
|
+
case /* uint32 nonce */ 2:
|
|
8656
|
+
message.nonce = reader.uint32();
|
|
8657
|
+
break;
|
|
8658
|
+
default:
|
|
8659
|
+
let u = options.readUnknownField;
|
|
8660
|
+
if (u === "throw")
|
|
8661
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8662
|
+
let d = reader.skip(wireType);
|
|
8663
|
+
if (u !== false)
|
|
8664
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8665
|
+
}
|
|
8666
|
+
}
|
|
8667
|
+
return message;
|
|
8668
|
+
}
|
|
8669
|
+
internalBinaryWrite(message, writer, options) {
|
|
8670
|
+
/* uint64 balance = 1; */
|
|
8671
|
+
if (message.balance !== "0")
|
|
8672
|
+
writer.tag(1, WireType.Varint).uint64(message.balance);
|
|
8673
|
+
/* uint32 nonce = 2; */
|
|
8674
|
+
if (message.nonce !== 0)
|
|
8675
|
+
writer.tag(2, WireType.Varint).uint32(message.nonce);
|
|
8676
|
+
let u = options.writeUnknownFields;
|
|
8677
|
+
if (u !== false)
|
|
8678
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8679
|
+
return writer;
|
|
8680
|
+
}
|
|
8681
|
+
}
|
|
8682
|
+
/**
|
|
8683
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.BalanceAndNonce
|
|
8684
|
+
*/
|
|
8685
|
+
export const BalanceAndNonce = new BalanceAndNonce$Type();
|
|
8686
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8687
|
+
class GetAddressInfoResponse$Type extends MessageType {
|
|
8688
|
+
constructor() {
|
|
8689
|
+
super("org.dash.platform.dapi.v0.GetAddressInfoResponse", [
|
|
8690
|
+
{ no: 1, name: "v0", kind: "message", oneof: "version", T: () => GetAddressInfoResponse_GetAddressInfoResponseV0 }
|
|
8691
|
+
]);
|
|
8692
|
+
}
|
|
8693
|
+
create(value) {
|
|
8694
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8695
|
+
message.version = { oneofKind: undefined };
|
|
8696
|
+
if (value !== undefined)
|
|
8697
|
+
reflectionMergePartial(this, message, value);
|
|
8698
|
+
return message;
|
|
8699
|
+
}
|
|
8700
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8701
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8702
|
+
while (reader.pos < end) {
|
|
8703
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8704
|
+
switch (fieldNo) {
|
|
8705
|
+
case /* org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0 v0 */ 1:
|
|
8706
|
+
message.version = {
|
|
8707
|
+
oneofKind: "v0",
|
|
8708
|
+
v0: GetAddressInfoResponse_GetAddressInfoResponseV0.internalBinaryRead(reader, reader.uint32(), options, message.version.v0)
|
|
8709
|
+
};
|
|
8710
|
+
break;
|
|
8711
|
+
default:
|
|
8712
|
+
let u = options.readUnknownField;
|
|
8713
|
+
if (u === "throw")
|
|
8714
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8715
|
+
let d = reader.skip(wireType);
|
|
8716
|
+
if (u !== false)
|
|
8717
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8718
|
+
}
|
|
8719
|
+
}
|
|
8720
|
+
return message;
|
|
8721
|
+
}
|
|
8722
|
+
internalBinaryWrite(message, writer, options) {
|
|
8723
|
+
/* org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0 v0 = 1; */
|
|
8724
|
+
if (message.version.oneofKind === "v0")
|
|
8725
|
+
GetAddressInfoResponse_GetAddressInfoResponseV0.internalBinaryWrite(message.version.v0, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
8726
|
+
let u = options.writeUnknownFields;
|
|
8727
|
+
if (u !== false)
|
|
8728
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8729
|
+
return writer;
|
|
8730
|
+
}
|
|
8731
|
+
}
|
|
8732
|
+
/**
|
|
8733
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse
|
|
8734
|
+
*/
|
|
8735
|
+
export const GetAddressInfoResponse = new GetAddressInfoResponse$Type();
|
|
8736
|
+
// @generated message type with reflection information, may provide speed optimized methods
|
|
8737
|
+
class GetAddressInfoResponse_GetAddressInfoResponseV0$Type extends MessageType {
|
|
8738
|
+
constructor() {
|
|
8739
|
+
super("org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0", [
|
|
8740
|
+
{ no: 1, name: "address_info_entry", kind: "message", oneof: "result", T: () => AddressInfoEntry },
|
|
8741
|
+
{ no: 2, name: "proof", kind: "message", oneof: "result", T: () => Proof },
|
|
8742
|
+
{ no: 3, name: "metadata", kind: "message", T: () => ResponseMetadata }
|
|
8743
|
+
]);
|
|
8744
|
+
}
|
|
8745
|
+
create(value) {
|
|
8746
|
+
const message = globalThis.Object.create((this.messagePrototype));
|
|
8747
|
+
message.result = { oneofKind: undefined };
|
|
8748
|
+
if (value !== undefined)
|
|
8749
|
+
reflectionMergePartial(this, message, value);
|
|
8750
|
+
return message;
|
|
8751
|
+
}
|
|
8752
|
+
internalBinaryRead(reader, length, options, target) {
|
|
8753
|
+
let message = target ?? this.create(), end = reader.pos + length;
|
|
8754
|
+
while (reader.pos < end) {
|
|
8755
|
+
let [fieldNo, wireType] = reader.tag();
|
|
8756
|
+
switch (fieldNo) {
|
|
8757
|
+
case /* org.dash.platform.dapi.v0.AddressInfoEntry address_info_entry */ 1:
|
|
8758
|
+
message.result = {
|
|
8759
|
+
oneofKind: "addressInfoEntry",
|
|
8760
|
+
addressInfoEntry: AddressInfoEntry.internalBinaryRead(reader, reader.uint32(), options, message.result.addressInfoEntry)
|
|
8761
|
+
};
|
|
8762
|
+
break;
|
|
8763
|
+
case /* org.dash.platform.dapi.v0.Proof proof */ 2:
|
|
8764
|
+
message.result = {
|
|
8765
|
+
oneofKind: "proof",
|
|
8766
|
+
proof: Proof.internalBinaryRead(reader, reader.uint32(), options, message.result.proof)
|
|
8767
|
+
};
|
|
8768
|
+
break;
|
|
8769
|
+
case /* org.dash.platform.dapi.v0.ResponseMetadata metadata */ 3:
|
|
8770
|
+
message.metadata = ResponseMetadata.internalBinaryRead(reader, reader.uint32(), options, message.metadata);
|
|
8771
|
+
break;
|
|
8772
|
+
default:
|
|
8773
|
+
let u = options.readUnknownField;
|
|
8774
|
+
if (u === "throw")
|
|
8775
|
+
throw new globalThis.Error(`Unknown field ${fieldNo} (wire type ${wireType}) for ${this.typeName}`);
|
|
8776
|
+
let d = reader.skip(wireType);
|
|
8777
|
+
if (u !== false)
|
|
8778
|
+
(u === true ? UnknownFieldHandler.onRead : u)(this.typeName, message, fieldNo, wireType, d);
|
|
8779
|
+
}
|
|
8780
|
+
}
|
|
8781
|
+
return message;
|
|
8782
|
+
}
|
|
8783
|
+
internalBinaryWrite(message, writer, options) {
|
|
8784
|
+
/* org.dash.platform.dapi.v0.AddressInfoEntry address_info_entry = 1; */
|
|
8785
|
+
if (message.result.oneofKind === "addressInfoEntry")
|
|
8786
|
+
AddressInfoEntry.internalBinaryWrite(message.result.addressInfoEntry, writer.tag(1, WireType.LengthDelimited).fork(), options).join();
|
|
8787
|
+
/* org.dash.platform.dapi.v0.Proof proof = 2; */
|
|
8788
|
+
if (message.result.oneofKind === "proof")
|
|
8789
|
+
Proof.internalBinaryWrite(message.result.proof, writer.tag(2, WireType.LengthDelimited).fork(), options).join();
|
|
8790
|
+
/* org.dash.platform.dapi.v0.ResponseMetadata metadata = 3; */
|
|
8791
|
+
if (message.metadata)
|
|
8792
|
+
ResponseMetadata.internalBinaryWrite(message.metadata, writer.tag(3, WireType.LengthDelimited).fork(), options).join();
|
|
8793
|
+
let u = options.writeUnknownFields;
|
|
8794
|
+
if (u !== false)
|
|
8795
|
+
(u == true ? UnknownFieldHandler.onWrite : u)(this.typeName, message, writer);
|
|
8796
|
+
return writer;
|
|
8797
|
+
}
|
|
8798
|
+
}
|
|
8799
|
+
/**
|
|
8800
|
+
* @generated MessageType for protobuf message org.dash.platform.dapi.v0.GetAddressInfoResponse.GetAddressInfoResponseV0
|
|
8801
|
+
*/
|
|
8802
|
+
export const GetAddressInfoResponse_GetAddressInfoResponseV0 = new GetAddressInfoResponse_GetAddressInfoResponseV0$Type();
|
|
8472
8803
|
/**
|
|
8473
8804
|
* @generated ServiceType for protobuf service org.dash.platform.dapi.v0.Platform
|
|
8474
8805
|
*/
|
|
@@ -8496,5 +8827,6 @@ export const Platform = new ServiceType("org.dash.platform.dapi.v0.Platform", [
|
|
|
8496
8827
|
{ name: "getTokenContractInfo", options: {}, I: GetTokenContractInfoRequest, O: GetTokenContractInfoResponse },
|
|
8497
8828
|
{ name: "getTokenDirectPurchasePrices", options: {}, I: GetTokenDirectPurchasePricesRequest, O: GetTokenDirectPurchasePricesResponse },
|
|
8498
8829
|
{ name: "getTokenTotalSupply", options: {}, I: GetTokenTotalSupplyRequest, O: GetTokenTotalSupplyResponse },
|
|
8499
|
-
{ name: "waitForStateTransitionResult", options: {}, I: WaitForStateTransitionResultRequest, O: WaitForStateTransitionResultResponse }
|
|
8830
|
+
{ name: "waitForStateTransitionResult", options: {}, I: WaitForStateTransitionResultRequest, O: WaitForStateTransitionResultResponse },
|
|
8831
|
+
{ name: "getAddressInfo", options: {}, I: GetAddressInfoRequest, O: GetAddressInfoResponse }
|
|
8500
8832
|
]);
|
package/src/DashPlatformSDK.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ import { ContestedResourcesController } from './contestedResources/index.js';
|
|
|
11
11
|
import { TokensController } from './tokens/index.js';
|
|
12
12
|
import { VotingController } from './voting/index.js';
|
|
13
13
|
import { Network } from '../types.js';
|
|
14
|
+
import { PlatformAddressesController } from './platformAddresses/index.js';
|
|
14
15
|
export interface GRPCOptions {
|
|
15
16
|
poolLimit: 5;
|
|
16
17
|
dapiUrl?: string | string[];
|
|
@@ -31,6 +32,7 @@ export declare class DashPlatformSDK {
|
|
|
31
32
|
/** @ignore **/
|
|
32
33
|
options?: SDKOptions;
|
|
33
34
|
contestedResources: ContestedResourcesController;
|
|
35
|
+
platformAddresses: PlatformAddressesController;
|
|
34
36
|
stateTransitions: StateTransitionsController;
|
|
35
37
|
dataContracts: DataContractsController;
|
|
36
38
|
identities: IdentitiesController;
|
|
@@ -56,7 +58,7 @@ export declare class DashPlatformSDK {
|
|
|
56
58
|
* @param grpcPool
|
|
57
59
|
* @param network
|
|
58
60
|
*/
|
|
59
|
-
_initialize(grpcPool: GRPCConnectionPool
|
|
61
|
+
_initialize(grpcPool: GRPCConnectionPool): void;
|
|
60
62
|
/**
|
|
61
63
|
* Get currently used network
|
|
62
64
|
*
|
package/src/DashPlatformSDK.js
CHANGED
|
@@ -10,6 +10,7 @@ import { DataContractsController } from './dataContracts/index.js';
|
|
|
10
10
|
import { ContestedResourcesController } from './contestedResources/index.js';
|
|
11
11
|
import { TokensController } from './tokens/index.js';
|
|
12
12
|
import { VotingController } from './voting/index.js';
|
|
13
|
+
import { PlatformAddressesController } from './platformAddresses/index.js';
|
|
13
14
|
/**
|
|
14
15
|
* Javascript SDK for that let you interact with a Dash Platform blockchain
|
|
15
16
|
*/
|
|
@@ -20,6 +21,7 @@ export class DashPlatformSDK {
|
|
|
20
21
|
/** @ignore **/
|
|
21
22
|
options;
|
|
22
23
|
contestedResources;
|
|
24
|
+
platformAddresses;
|
|
23
25
|
stateTransitions;
|
|
24
26
|
dataContracts;
|
|
25
27
|
identities;
|
|
@@ -49,7 +51,7 @@ export class DashPlatformSDK {
|
|
|
49
51
|
this.options.grpc = { dapiUrl: options.dapiUrl };
|
|
50
52
|
}
|
|
51
53
|
this.grpcPool = new GRPCConnectionPool(this.network, this.options?.grpc);
|
|
52
|
-
this._initialize(this.grpcPool
|
|
54
|
+
this._initialize(this.grpcPool);
|
|
53
55
|
}
|
|
54
56
|
/**
|
|
55
57
|
* @private
|
|
@@ -59,15 +61,16 @@ export class DashPlatformSDK {
|
|
|
59
61
|
* @param grpcPool
|
|
60
62
|
* @param network
|
|
61
63
|
*/
|
|
62
|
-
_initialize(grpcPool
|
|
64
|
+
_initialize(grpcPool) {
|
|
63
65
|
this.grpcPool = grpcPool;
|
|
64
|
-
this.stateTransitions = new StateTransitionsController(grpcPool);
|
|
65
66
|
this.contestedResources = new ContestedResourcesController(grpcPool);
|
|
67
|
+
this.platformAddresses = new PlatformAddressesController(grpcPool);
|
|
68
|
+
this.stateTransitions = new StateTransitionsController(grpcPool);
|
|
66
69
|
this.dataContracts = new DataContractsController(grpcPool);
|
|
67
70
|
this.identities = new IdentitiesController(grpcPool);
|
|
68
71
|
this.documents = new DocumentsController(grpcPool);
|
|
69
72
|
this.voting = new VotingController();
|
|
70
|
-
this.node = new NodeController(grpcPool
|
|
73
|
+
this.node = new NodeController(grpcPool);
|
|
71
74
|
this.tokens = new TokensController(grpcPool);
|
|
72
75
|
this.names = new NamesController(grpcPool);
|
|
73
76
|
this.keyPair = new KeyPairController();
|
|
@@ -91,6 +94,6 @@ export class DashPlatformSDK {
|
|
|
91
94
|
}
|
|
92
95
|
this.network = network;
|
|
93
96
|
const grpcPool = new GRPCConnectionPool(this.network, this.options?.grpc);
|
|
94
|
-
this._initialize(grpcPool
|
|
97
|
+
this._initialize(grpcPool);
|
|
95
98
|
}
|
|
96
99
|
}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { DataContractTokens, DataContractWASM, PlatformVersionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DataContractConfig
|
|
1
|
+
import { DataContractTokens, DataContractWASM, IdentifierLike, PlatformVersionWASM } from 'pshenmic-dpp';
|
|
2
|
+
import { DataContractConfig } from '../../types.js';
|
|
3
3
|
export default function createDataContract(ownerId: IdentifierLike, identityNonce: bigint, schema: object, tokenConfiguration?: DataContractTokens[], config?: DataContractConfig, fullValidation?: boolean | undefined, platformVersion?: PlatformVersionWASM | undefined): DataContractWASM;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { DataContractWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '../../types.js';
|
|
1
|
+
import { DataContractWASM, IdentifierLike } from 'pshenmic-dpp';
|
|
3
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
3
|
export default function getByIdentifier(grpcPool: GRPCConnectionPool, identifier: IdentifierLike): Promise<DataContractWASM>;
|