dash-platform-sdk 1.3.0-dev.12 → 1.3.0-dev.14
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 +3 -3
- package/src/DashPlatformSDK.d.ts +1 -1
- package/src/constants.d.ts +1 -1
- package/src/constants.js +1 -1
- package/src/contestedResources/getContestedResourceVoteState.d.ts +1 -1
- package/src/contestedResources/index.d.ts +1 -1
- package/src/dataContracts/create.d.ts +1 -1
- package/src/dataContracts/getDataContractByIdentifier.d.ts +1 -1
- package/src/dataContracts/index.d.ts +1 -1
- package/src/documents/create.d.ts +1 -1
- package/src/documents/createStateTransition.d.ts +1 -1
- package/src/documents/index.d.ts +1 -1
- package/src/documents/query.d.ts +1 -1
- package/src/grpcConnectionPool.d.ts +1 -1
- package/src/identities/createStateTransition.d.ts +1 -1
- package/src/identities/getIdentityBalance.d.ts +1 -1
- package/src/identities/getIdentityByIdentifier.d.ts +1 -1
- package/src/identities/getIdentityContractNonce.d.ts +1 -1
- package/src/identities/getIdentityNonce.d.ts +1 -1
- package/src/identities/getIdentityPublicKeys.d.ts +1 -1
- package/src/identities/getIdentityPublicKeys.js +1 -1
- package/src/identities/index.d.ts +1 -1
- package/src/keyPair/index.d.ts +1 -1
- package/src/names/index.d.ts +1 -1
- package/src/node/index.d.ts +1 -1
- package/src/node/status.d.ts +1 -1
- package/src/node/totalCredits.d.ts +1 -1
- package/src/stateTransitions/broadcast.js +1 -1
- package/src/stateTransitions/waitForStateTransitionResult.js +1 -1
- package/src/tokens/createStateTransition.d.ts +1 -1
- package/src/tokens/getIdentitiesTokenBalances.d.ts +1 -1
- package/src/tokens/getIdentityTokensBalances.d.ts +1 -1
- package/src/tokens/getTokenContractInfo.d.ts +1 -1
- package/src/tokens/getTokenDirectPurchasePrices.d.ts +1 -1
- package/src/tokens/getTokenTotalSupply.d.ts +1 -1
- package/src/tokens/index.d.ts +1 -1
- package/src/utils/getEvonodeList.d.ts +1 -1
- package/src/utils/index.d.ts +8 -0
- package/src/utils/index.js +17 -0
- package/src/voting/index.d.ts +1 -1
- package/test/unit/ContestedResources.spec.js +1 -1
- package/test/unit/DataContract.spec.js +4 -3
- package/test/unit/Identity.spec.js +1 -1
- package/{src/types.d.ts → types.d.ts} +3 -2
- package/{src/types.js → types.js} +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dash-platform-sdk",
|
|
3
|
-
"version": "1.3.0-dev.
|
|
3
|
+
"version": "1.3.0-dev.14",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"description": "Lightweight SDK for accessing Dash Platform blockchain",
|
|
6
6
|
"ts-standard": {
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
"docs": "typedoc"
|
|
49
49
|
},
|
|
50
50
|
"peerDependencies": {
|
|
51
|
-
"pshenmic-dpp": "1.1.2-dev.
|
|
51
|
+
"pshenmic-dpp": "1.1.2-dev.8"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
54
|
"@bufbuild/protobuf": "^2.6.0",
|
|
@@ -59,6 +59,6 @@
|
|
|
59
59
|
"@scure/bip39": "^2.0.0",
|
|
60
60
|
"@scure/btc-signer": "^2.0.1",
|
|
61
61
|
"cbor-x": "^1.6.0",
|
|
62
|
-
"pshenmic-dpp": "1.1.2-dev.
|
|
62
|
+
"pshenmic-dpp": "1.1.2-dev.8"
|
|
63
63
|
}
|
|
64
64
|
}
|
package/src/DashPlatformSDK.d.ts
CHANGED
|
@@ -10,7 +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 { Network } from '
|
|
13
|
+
import { Network } from '../types.js';
|
|
14
14
|
export interface GRPCOptions {
|
|
15
15
|
poolLimit: 5;
|
|
16
16
|
dapiUrl?: string | string[];
|
package/src/constants.d.ts
CHANGED
|
@@ -9,4 +9,4 @@ export declare const MAINNET_ACTIVATION_HEIGHT = 2128896;
|
|
|
9
9
|
export declare const GRPC_DEFAULT_POOL_LIMIT = 5;
|
|
10
10
|
export declare const DPNS_DATA_CONTRACT_ID = "GWRSAVFMjXx8HpQFaNJMqBV7MBgMK4br5UESsB4S31Ec";
|
|
11
11
|
export declare const DPNS_DATA_CONTRACT_BYTES = "AeZoxlmvZq7h5ywYbd57W34KHXEqCcQNVyH2Ir9TxTFVAAAAAAABAQAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIGZG9tYWluFgsSEGRvY3VtZW50c011dGFibGUTABIMY2FuQmVEZWxldGVkEwESDHRyYW5zZmVyYWJsZQIBEgl0cmFkZU1vZGUCARIEdHlwZRIGb2JqZWN0EgdpbmRpY2VzFQIWBBIEbmFtZRIScGFyZW50TmFtZUFuZExhYmVsEgpwcm9wZXJ0aWVzFQIWARIabm9ybWFsaXplZFBhcmVudERvbWFpbk5hbWUSA2FzYxYBEg9ub3JtYWxpemVkTGFiZWwSA2FzYxIGdW5pcXVlEwESCWNvbnRlc3RlZBYDEgxmaWVsZE1hdGNoZXMVARYCEgVmaWVsZBIPbm9ybWFsaXplZExhYmVsEgxyZWdleFBhdHRlcm4SE15bYS16QS1aMDEtXXszLDE5fSQSCnJlc29sdXRpb24CABILZGVzY3JpcHRpb24SqklmIHRoZSBub3JtYWxpemVkIGxhYmVsIHBhcnQgb2YgdGhpcyBpbmRleCBpcyBsZXNzIHRoYW4gMjAgY2hhcmFjdGVycyAoYWxsIGFscGhhYmV0IGEteiwgQS1aLCAwLCAxLCBhbmQgLSkgdGhlbiBhIG1hc3Rlcm5vZGUgdm90ZSBjb250ZXN0IHRha2VzIHBsYWNlIHRvIGdpdmUgb3V0IHRoZSBuYW1lFgMSBG5hbWUSCmlkZW50aXR5SWQSDm51bGxTZWFyY2hhYmxlEwASC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= PlatformVersionWASM.
|
|
12
|
+
export declare const LATEST_PLATFORM_VERSION = PlatformVersionWASM.PLATFORM_V11;
|
package/src/constants.js
CHANGED
|
@@ -9,4 +9,4 @@ export const MAINNET_ACTIVATION_HEIGHT = 2128896;
|
|
|
9
9
|
export const GRPC_DEFAULT_POOL_LIMIT = 5;
|
|
10
10
|
export const DPNS_DATA_CONTRACT_ID = 'GWRSAVFMjXx8HpQFaNJMqBV7MBgMK4br5UESsB4S31Ec';
|
|
11
11
|
export const DPNS_DATA_CONTRACT_BYTES = 'AeZoxlmvZq7h5ywYbd57W34KHXEqCcQNVyH2Ir9TxTFVAAAAAAABAQAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAIGZG9tYWluFgsSEGRvY3VtZW50c011dGFibGUTABIMY2FuQmVEZWxldGVkEwESDHRyYW5zZmVyYWJsZQIBEgl0cmFkZU1vZGUCARIEdHlwZRIGb2JqZWN0EgdpbmRpY2VzFQIWBBIEbmFtZRIScGFyZW50TmFtZUFuZExhYmVsEgpwcm9wZXJ0aWVzFQIWARIabm9ybWFsaXplZFBhcmVudERvbWFpbk5hbWUSA2FzYxYBEg9ub3JtYWxpemVkTGFiZWwSA2FzYxIGdW5pcXVlEwESCWNvbnRlc3RlZBYDEgxmaWVsZE1hdGNoZXMVARYCEgVmaWVsZBIPbm9ybWFsaXplZExhYmVsEgxyZWdleFBhdHRlcm4SE15bYS16QS1aMDEtXXszLDE5fSQSCnJlc29sdXRpb24CABILZGVzY3JpcHRpb24SqklmIHRoZSBub3JtYWxpemVkIGxhYmVsIHBhcnQgb2YgdGhpcyBpbmRleCBpcyBsZXNzIHRoYW4gMjAgY2hhcmFjdGVycyAoYWxsIGFscGhhYmV0IGEteiwgQS1aLCAwLCAxLCBhbmQgLSkgdGhlbiBhIG1hc3Rlcm5vZGUgdm90ZSBjb250ZXN0IHRha2VzIHBsYWNlIHRvIGdpdmUgb3V0IHRoZSBuYW1lFgMSBG5hbWUSCm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AAA==';
|
|
12
|
-
export const LATEST_PLATFORM_VERSION = PlatformVersionWASM.
|
|
12
|
+
export const LATEST_PLATFORM_VERSION = PlatformVersionWASM.PLATFORM_V11;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ContestedResourceVoteState, ContestedStateResultType } from '
|
|
1
|
+
import { ContestedResourceVoteState, ContestedStateResultType } from '../../types.js';
|
|
2
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
3
3
|
import { GetContestedResourceVoteStateRequest_GetContestedResourceVoteStateRequestV0_StartAtIdentifierInfo } from '../../proto/generated/platform.js';
|
|
4
4
|
import { DataContractWASM } from 'pshenmic-dpp';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { ContestedResourceVoteState, ContestedStateResultType } from '
|
|
2
|
+
import { ContestedResourceVoteState, ContestedStateResultType } from '../../types.js';
|
|
3
3
|
import { DataContractWASM } from 'pshenmic-dpp';
|
|
4
4
|
import { StartAtIdentifierInfo } from './getContestedResourceVoteState.js';
|
|
5
5
|
/**
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DataContractWASM, PlatformVersionWASM, TokenConfigurationWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DataContractConfig, IdentifierLike } from '
|
|
2
|
+
import { DataContractConfig, IdentifierLike } from '../../types.js';
|
|
3
3
|
export default function createDataContract(ownerId: IdentifierLike, identityNonce: bigint, schema: object, tokenConfiguration?: TokenConfigurationWASM, config?: DataContractConfig, fullValidation?: boolean | undefined, platformVersion?: PlatformVersionWASM | undefined): DataContractWASM;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { DataContractWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
export default function getByIdentifier(grpcPool: GRPCConnectionPool, identifier: IdentifierLike): Promise<DataContractWASM>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DataContractConfig, IdentifierLike } from '
|
|
1
|
+
import { DataContractConfig, IdentifierLike } from '../../types.js';
|
|
2
2
|
import { DataContractWASM, PlatformVersionWASM, StateTransitionWASM, TokenConfigurationWASM } from 'pshenmic-dpp';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
/**
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DocumentWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
export default function createDocument(dataContractId: IdentifierLike, documentType: string, data: object, owner: IdentifierLike, revision?: bigint, documentId?: IdentifierLike): DocumentWASM;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DocumentWASM, StateTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DocumentTransitionParams } from '
|
|
2
|
+
import { DocumentTransitionParams } from '../../types.js';
|
|
3
3
|
export default function createStateTransition(document: DocumentWASM, type: 'create' | 'replace' | 'delete' | 'updatePrice' | 'transfer' | 'purchase', params: DocumentTransitionParams): StateTransitionWASM;
|
package/src/documents/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { DocumentTransitionParams, IdentifierLike } from '
|
|
1
|
+
import { DocumentTransitionParams, IdentifierLike } from '../../types.js';
|
|
2
2
|
import { DocumentWASM, IdentifierWASM, StateTransitionWASM } from 'pshenmic-dpp';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
/**
|
package/src/documents/query.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { DocumentWASM, IdentifierWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
export default function query(grpcPool: GRPCConnectionPool, dataContractId: IdentifierLike, documentTypeName: string, where?: ArrayLike<any>, orderBy?: ArrayLike<any>, limit?: number | undefined, startAt?: IdentifierWASM, startAfter?: IdentifierWASM): Promise<DocumentWASM[]>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { StateTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentityTransitionParams } from '
|
|
2
|
+
import { IdentityTransitionParams } from '../../types.js';
|
|
3
3
|
export default function createStateTransition(type: 'create' | 'update' | 'topUp' | 'creditTransfer' | 'withdrawal', params: IdentityTransitionParams): StateTransitionWASM;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { IdentifierLike } from '
|
|
1
|
+
import { IdentifierLike } from '../../types.js';
|
|
2
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
3
3
|
export default function getIdentityBalance(grpcPool: GRPCConnectionPool, identifier: IdentifierLike): Promise<bigint>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { IdentityWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
export default function getIdentityByIdentifier(grpcPool: GRPCConnectionPool, identifier: IdentifierLike): Promise<IdentityWASM>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { IdentifierLike } from '
|
|
1
|
+
import { IdentifierLike } from '../../types.js';
|
|
2
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
3
3
|
export default function getIdentityContractNonce(grpcPool: GRPCConnectionPool, identity: IdentifierLike, dataContract: IdentifierLike): Promise<bigint>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { IdentifierLike } from '
|
|
1
|
+
import { IdentifierLike } from '../../types.js';
|
|
2
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
3
3
|
export default function getIdentityNonce(grpcPool: GRPCConnectionPool, identifier: IdentifierLike): Promise<bigint>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { IdentityPublicKeyWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
4
4
|
export default function getIdentityPublicKeys(grpcPool: GRPCConnectionPool, identifier: IdentifierLike, keyIds?: number[]): Promise<IdentityPublicKeyWASM[]>;
|
|
@@ -3,7 +3,7 @@ import { IdentifierWASM, verifyIdentityKeysByIdentifierProof } from 'pshenmic-dp
|
|
|
3
3
|
import { getQuorumPublicKey } from '../utils/getQuorumPublicKey.js';
|
|
4
4
|
import bytesToHex from '../utils/bytesToHex.js';
|
|
5
5
|
import verifyTenderdashProof from '../utils/verifyTenderdashProof.js';
|
|
6
|
-
import { LATEST_PLATFORM_VERSION } from
|
|
6
|
+
import { LATEST_PLATFORM_VERSION } from '../constants.js';
|
|
7
7
|
export default async function getIdentityPublicKeys(grpcPool, identifier, keyIds) {
|
|
8
8
|
const id = new IdentifierWASM(identifier);
|
|
9
9
|
let requestType = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IdentifierLike, IdentityTransitionParams } from '
|
|
1
|
+
import { IdentifierLike, IdentityTransitionParams } from '../../types.js';
|
|
2
2
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
3
3
|
import { IdentityPublicKeyWASM, IdentityWASM, StateTransitionWASM } from 'pshenmic-dpp';
|
|
4
4
|
/**
|
package/src/keyPair/index.d.ts
CHANGED
package/src/names/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
2
|
import { DocumentWASM, PrivateKeyWASM } from 'pshenmic-dpp';
|
|
3
|
-
import { IdentifierLike } from '
|
|
3
|
+
import { IdentifierLike } from '../../types.js';
|
|
4
4
|
/**
|
|
5
5
|
* Functions related to DPNS names (usernames)
|
|
6
6
|
*
|
package/src/node/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { Network, NodeStatus } from '
|
|
2
|
+
import { Network, NodeStatus } from '../../types.js';
|
|
3
3
|
import { EpochInfo } from './epochs.js';
|
|
4
4
|
/**
|
|
5
5
|
* Node controller for requesting information about DAPI node
|
package/src/node/status.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BroadcastStateTransitionRequest } from '../../proto/generated/platform.js';
|
|
2
2
|
export default async function broadcast(grpcPool, stateTransition) {
|
|
3
|
-
if (stateTransition.signature
|
|
3
|
+
if (stateTransition.signature?.length === 0) {
|
|
4
4
|
throw new Error('State Transition is not signed');
|
|
5
5
|
}
|
|
6
6
|
const broadcastStateTransitionRequest = BroadcastStateTransitionRequest.create({
|
|
@@ -43,7 +43,7 @@ export default async function waitForStateTransitionResult(grpcPool, stateTransi
|
|
|
43
43
|
}
|
|
44
44
|
else if (v0.result.oneofKind === 'error') {
|
|
45
45
|
const { code, message, data } = v0.result.error;
|
|
46
|
-
throw new Error(`State transition ${txHash} failed to execute with code ${code}, message: ${message}, data: ${base64.encode(data)}`);
|
|
46
|
+
throw new Error(`State transition ${txHash} failed to execute with code ${String(code)}, message: ${String(message)}, data: ${base64.encode(data)}`);
|
|
47
47
|
}
|
|
48
48
|
else {
|
|
49
49
|
throw new Error('Unexpected oneOfKind returned for waitForStateTransitionResult');
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { IdentifierWASM, StateTransitionWASM, TokenBaseTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { TokenTransitionParams, TokenTransitionType } from '
|
|
2
|
+
import { TokenTransitionParams, TokenTransitionType } from '../../types.js';
|
|
3
3
|
export default function createStateTransition(base: TokenBaseTransitionWASM, ownerId: IdentifierWASM, type: TokenTransitionType, params: TokenTransitionParams): StateTransitionWASM;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import { IdentifierWASM } from 'pshenmic-dpp';
|
|
4
4
|
export interface IdentitiesTokenBalances {
|
|
5
5
|
identityId: IdentifierWASM;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import { IdentifierWASM } from 'pshenmic-dpp';
|
|
4
4
|
export interface IdentityTokenBalances {
|
|
5
5
|
tokenId: IdentifierWASM;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike } from '
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
3
3
|
import { IdentifierWASM } from 'pshenmic-dpp';
|
|
4
4
|
export interface TokenContractInfo {
|
|
5
5
|
dataContractId: IdentifierWASM;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike, TokenDirectPurchasePrices } from '
|
|
2
|
+
import { IdentifierLike, TokenDirectPurchasePrices } from '../../types.js';
|
|
3
3
|
export default function getTokenDirectPurchasePrices(grpcPool: GRPCConnectionPool, tokenIdentifiers: IdentifierLike[]): Promise<TokenDirectPurchasePrices[]>;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike, TokenTotalSupply } from '
|
|
2
|
+
import { IdentifierLike, TokenTotalSupply } from '../../types.js';
|
|
3
3
|
export default function getTokenTotalSupply(grpcPool: GRPCConnectionPool, tokenIdentifier: IdentifierLike): Promise<TokenTotalSupply>;
|
package/src/tokens/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import GRPCConnectionPool from '../grpcConnectionPool.js';
|
|
2
|
-
import { IdentifierLike, TokenDirectPurchasePrices, TokenTotalSupply, TokenTransitionParams, TokenTransitionType } from '
|
|
2
|
+
import { IdentifierLike, TokenDirectPurchasePrices, TokenTotalSupply, TokenTransitionParams, TokenTransitionType } from '../../types.js';
|
|
3
3
|
import { IdentitiesTokenBalances } from './getIdentitiesTokenBalances.js';
|
|
4
4
|
import { IdentityTokenBalances } from './getIdentityTokensBalances.js';
|
|
5
5
|
import { TokenContractInfo } from './getTokenContractInfo.js';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { MasternodeList, Network } from '
|
|
1
|
+
import { MasternodeList, Network } from '../../types.js';
|
|
2
2
|
export default function getDAPINodeList(network: Network): Promise<MasternodeList>;
|
package/src/utils/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { IdentifierWASM } from 'pshenmic-dpp';
|
|
2
|
+
import { IdentifierLike } from '../../types.js';
|
|
2
3
|
/**
|
|
3
4
|
* Collection of conversion functions
|
|
4
5
|
*
|
|
@@ -62,4 +63,11 @@ export declare class UtilsController {
|
|
|
62
63
|
* @return {string}
|
|
63
64
|
* */
|
|
64
65
|
createMasternodeIdentifier(proTxHash: string): IdentifierWASM;
|
|
66
|
+
/**
|
|
67
|
+
* Validates an identifier, accepts string or buffer
|
|
68
|
+
*
|
|
69
|
+
* @param identifier {IdentifierLike} identifier to test
|
|
70
|
+
* @return {boolean}
|
|
71
|
+
* */
|
|
72
|
+
validateIdentifier(identifier: IdentifierLike): boolean;
|
|
65
73
|
}
|
package/src/utils/index.js
CHANGED
|
@@ -3,6 +3,7 @@ import { base58 } from '@scure/base';
|
|
|
3
3
|
import hexToBytes from './hexToBytes.js';
|
|
4
4
|
import bytesToHex from './bytesToHex.js';
|
|
5
5
|
import { createVoterIdentityId } from './createVoterIdentityId.js';
|
|
6
|
+
import { IdentifierWASM } from 'pshenmic-dpp';
|
|
6
7
|
import { createMasternodeIdentityId } from './createMasternodeIdentityId.js';
|
|
7
8
|
/**
|
|
8
9
|
* Collection of conversion functions
|
|
@@ -81,4 +82,20 @@ export class UtilsController {
|
|
|
81
82
|
createMasternodeIdentifier(proTxHash) {
|
|
82
83
|
return createMasternodeIdentityId(proTxHash);
|
|
83
84
|
}
|
|
85
|
+
/**
|
|
86
|
+
* Validates an identifier, accepts string or buffer
|
|
87
|
+
*
|
|
88
|
+
* @param identifier {IdentifierLike} identifier to test
|
|
89
|
+
* @return {boolean}
|
|
90
|
+
* */
|
|
91
|
+
validateIdentifier(identifier) {
|
|
92
|
+
try {
|
|
93
|
+
// eslint-disable-next-line
|
|
94
|
+
new IdentifierWASM(identifier);
|
|
95
|
+
return true;
|
|
96
|
+
}
|
|
97
|
+
catch (e) {
|
|
98
|
+
return false;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
84
101
|
}
|
package/src/voting/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IdentifierLike, ResourceVoteChoice } from '
|
|
1
|
+
import { IdentifierLike, ResourceVoteChoice } from '../../types.js';
|
|
2
2
|
import { IdentifierWASM, StateTransitionWASM, VoteWASM } from 'pshenmic-dpp';
|
|
3
3
|
/**
|
|
4
4
|
* Voting controller for performing masternode votes
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DataContractWASM, PlatformVersionWASM, PrivateKeyWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DashPlatformSDK, ContestedStateResultType } from '../../
|
|
2
|
+
import { DashPlatformSDK, ContestedStateResultType } from '../../types.js';
|
|
3
3
|
import stringToIndexValueBytes from '../../src/utils/stringToIndexValueBytes.js';
|
|
4
4
|
let sdk;
|
|
5
5
|
let contract;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DataContractWASM, StateTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DashPlatformSDK } from '../../
|
|
2
|
+
import { DashPlatformSDK } from '../../types.js';
|
|
3
3
|
let sdk;
|
|
4
4
|
let ownerIdentifier;
|
|
5
5
|
let identityNonce;
|
|
@@ -11,7 +11,7 @@ describe('DataContract', () => {
|
|
|
11
11
|
ownerIdentifier = 'GARSAVFMjXx8HpQFaNJMqBV7MBgMK4br5UESsB4S31Ec';
|
|
12
12
|
identityNonce = BigInt(11);
|
|
13
13
|
config = {
|
|
14
|
-
$format_version: '
|
|
14
|
+
$format_version: '1',
|
|
15
15
|
canBeDeleted: true,
|
|
16
16
|
readonly: true,
|
|
17
17
|
keepsHistory: false,
|
|
@@ -19,7 +19,8 @@ describe('DataContract', () => {
|
|
|
19
19
|
documentsMutableContractDefault: false,
|
|
20
20
|
documentsCanBeDeletedContractDefault: true,
|
|
21
21
|
requiresIdentityEncryptionBoundedKey: null,
|
|
22
|
-
requiresIdentityDecryptionBoundedKey: null
|
|
22
|
+
requiresIdentityDecryptionBoundedKey: null,
|
|
23
|
+
sizedIntegerTypes: true
|
|
23
24
|
};
|
|
24
25
|
schema = {
|
|
25
26
|
note: {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CoreScriptWASM, IdentityPublicKeyWASM, IdentityWASM, KeyType, PrivateKeyWASM, Purpose, SecurityLevel, StateTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
-
import { DashPlatformSDK } from '../../
|
|
2
|
+
import { DashPlatformSDK } from '../../types.js';
|
|
3
3
|
import { base58 } from '@scure/base';
|
|
4
4
|
let sdk;
|
|
5
5
|
describe('Identity', () => {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { CoreScriptWASM, DocumentWASM, GasFeesPaidByWASM, IdentifierWASM, KeyType, Purpose, SecurityLevel, TokenEmergencyActionWASM, TokenPricingScheduleWASM } from 'pshenmic-dpp';
|
|
2
|
-
export { CoreScriptWASM, DocumentWASM, GasFeesPaidByWASM, IdentifierWASM, KeyType, Purpose, SecurityLevel, TokenEmergencyActionWASM, TokenPricingScheduleWASM } from 'pshenmic-dpp';
|
|
2
|
+
export { CoreScriptWASM, DocumentWASM, GasFeesPaidByWASM, IdentifierWASM, KeyType, Purpose, SecurityLevel, TokenEmergencyActionWASM, TokenPricingScheduleWASM, StateTransitionWASM, BatchTransitionWASM, IdentityPublicKeyWASM, PrivateKeyWASM, DataContractUpdateTransitionWASM, IdentityWASM, IdentityUpdateTransitionWASM, IdentityCreditTransferWASM, MasternodeVoteTransitionWASM } from 'pshenmic-dpp';
|
|
3
3
|
export type IdentifierLike = IdentifierWASM | string | Uint8Array;
|
|
4
4
|
export type Network = 'mainnet' | 'testnet';
|
|
5
|
-
export { DashPlatformSDK } from './DashPlatformSDK.js';
|
|
5
|
+
export { DashPlatformSDK } from './src/DashPlatformSDK.js';
|
|
6
6
|
export type MasternodeList = Record<string, MasternodeInfo>;
|
|
7
7
|
export interface DocumentTransitionParams {
|
|
8
8
|
identityContractNonce: bigint;
|
|
@@ -135,6 +135,7 @@ export interface DataContractConfig {
|
|
|
135
135
|
documentsCanBeDeletedContractDefault: boolean;
|
|
136
136
|
requiresIdentityEncryptionBoundedKey?: number | null;
|
|
137
137
|
requiresIdentityDecryptionBoundedKey?: number | null;
|
|
138
|
+
sizedIntegerTypes: boolean;
|
|
138
139
|
}
|
|
139
140
|
export type TokenTransitionType = 'burn' | 'mint' | 'transfer' | 'freeze' | 'unfreeze' | 'destroyFrozenFunds' | 'emergencyAction' | 'directPurchase' | 'setPriceForDirectPurchase';
|
|
140
141
|
export interface TokenTransitionParams {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { CoreScriptWASM, DocumentWASM, GasFeesPaidByWASM, IdentifierWASM, KeyType, Purpose, SecurityLevel, TokenEmergencyActionWASM, TokenPricingScheduleWASM } from 'pshenmic-dpp';
|
|
2
|
-
export { DashPlatformSDK } from './DashPlatformSDK.js';
|
|
1
|
+
export { CoreScriptWASM, DocumentWASM, GasFeesPaidByWASM, IdentifierWASM, KeyType, Purpose, SecurityLevel, TokenEmergencyActionWASM, TokenPricingScheduleWASM, StateTransitionWASM, BatchTransitionWASM, IdentityPublicKeyWASM, PrivateKeyWASM, DataContractUpdateTransitionWASM, IdentityWASM, IdentityUpdateTransitionWASM, IdentityCreditTransferWASM, MasternodeVoteTransitionWASM } from 'pshenmic-dpp';
|
|
2
|
+
export { DashPlatformSDK } from './src/DashPlatformSDK.js';
|
|
3
3
|
export var ContestedStateResultType;
|
|
4
4
|
(function (ContestedStateResultType) {
|
|
5
5
|
ContestedStateResultType[ContestedStateResultType["DOCUMENTS"] = 0] = "DOCUMENTS";
|