@triadxyz/triad-protocol 0.5.3-beta.devnet → 0.5.5-beta.devnet
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/index.d.ts +7 -9
- package/dist/index.js +58 -40
- package/dist/{test.js → local-test.js} +47 -9
- package/dist/stake.d.ts +19 -18
- package/dist/stake.js +59 -96
- package/dist/trade.d.ts +32 -0
- package/dist/trade.js +138 -0
- package/dist/types/idl_triad_protocol.json +385 -295
- package/dist/types/index.d.ts +1 -14
- package/dist/types/stake.d.ts +3 -7
- package/dist/types/trade.d.ts +44 -0
- package/dist/types/trade.js +2 -0
- package/dist/types/triad_protocol.d.ts +961 -399
- package/dist/utils/constants.d.ts +6 -3
- package/dist/utils/constants.js +7 -4
- package/dist/utils/helpers.d.ts +3 -4
- package/dist/utils/helpers.js +16 -51
- package/package.json +2 -3
- package/dist/ticker.d.ts +0 -33
- package/dist/ticker.js +0 -43
- package/dist/vault.d.ts +0 -48
- package/dist/vault.js +0 -44
- /package/dist/{test.d.ts → local-test.d.ts} +0 -0
package/dist/types/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { PublicKey } from '@solana/web3.js';
|
|
2
2
|
export type RpcOptions = {
|
|
3
3
|
skipPreflight?: boolean;
|
|
4
4
|
microLamports?: number;
|
|
@@ -8,16 +8,3 @@ export type CreateUserArgs = {
|
|
|
8
8
|
name: string;
|
|
9
9
|
referral?: PublicKey;
|
|
10
10
|
};
|
|
11
|
-
export type OpenOreArgs = {
|
|
12
|
-
user: PublicKey;
|
|
13
|
-
payer: Keypair;
|
|
14
|
-
name: string;
|
|
15
|
-
referralName: string;
|
|
16
|
-
};
|
|
17
|
-
export type MineOreArgs = {
|
|
18
|
-
user: PublicKey;
|
|
19
|
-
payer: PublicKey;
|
|
20
|
-
bus: PublicKey;
|
|
21
|
-
digest: number[];
|
|
22
|
-
nonce: number[];
|
|
23
|
-
};
|
package/dist/types/stake.d.ts
CHANGED
|
@@ -19,10 +19,10 @@ export type InitializeStakeArgs = {
|
|
|
19
19
|
amount: BN;
|
|
20
20
|
collection: string;
|
|
21
21
|
};
|
|
22
|
-
export type
|
|
22
|
+
export type UpdateStakeVaultArgs = {
|
|
23
23
|
wallet: PublicKey;
|
|
24
|
-
amount
|
|
25
|
-
|
|
24
|
+
amount?: BN;
|
|
25
|
+
status?: boolean;
|
|
26
26
|
};
|
|
27
27
|
export type RequestWithdrawArgs = {
|
|
28
28
|
wallet: PublicKey;
|
|
@@ -34,10 +34,6 @@ export type WithdrawArgs = {
|
|
|
34
34
|
name: string;
|
|
35
35
|
mint: PublicKey;
|
|
36
36
|
};
|
|
37
|
-
export type UpdateStakeVaultStatusArgs = {
|
|
38
|
-
wallet: PublicKey;
|
|
39
|
-
isLocked: boolean;
|
|
40
|
-
};
|
|
41
37
|
export type ClaimStakeRewardsArgs = {
|
|
42
38
|
wallet: PublicKey;
|
|
43
39
|
nftName: string;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
export type Market = {
|
|
2
|
+
bump: number;
|
|
3
|
+
authority: string;
|
|
4
|
+
marketId: number;
|
|
5
|
+
name: string;
|
|
6
|
+
hypePrice: number;
|
|
7
|
+
flopPrice: number;
|
|
8
|
+
hypeLiquidity: number;
|
|
9
|
+
flopLiquidity: number;
|
|
10
|
+
totalHypeShares: number;
|
|
11
|
+
totalFlopShares: number;
|
|
12
|
+
totalVolume: number;
|
|
13
|
+
vaultTokenAccount: string;
|
|
14
|
+
mint: string;
|
|
15
|
+
ts: number;
|
|
16
|
+
updateTs: number;
|
|
17
|
+
openOrdersCount: number;
|
|
18
|
+
nextOrderId: number;
|
|
19
|
+
feeBps: number;
|
|
20
|
+
feeVault: string;
|
|
21
|
+
isActive: boolean;
|
|
22
|
+
isOfficial: boolean;
|
|
23
|
+
};
|
|
24
|
+
export type OrderDirection = {
|
|
25
|
+
hype: {};
|
|
26
|
+
} | {
|
|
27
|
+
flop: {};
|
|
28
|
+
};
|
|
29
|
+
export type OrderStatus = {
|
|
30
|
+
init: {};
|
|
31
|
+
} | {
|
|
32
|
+
open: {};
|
|
33
|
+
} | {
|
|
34
|
+
filled: {};
|
|
35
|
+
} | {
|
|
36
|
+
canceled: {};
|
|
37
|
+
} | {
|
|
38
|
+
closed: {};
|
|
39
|
+
};
|
|
40
|
+
export type OrderType = {
|
|
41
|
+
limit: {};
|
|
42
|
+
} | {
|
|
43
|
+
market: {};
|
|
44
|
+
};
|