@lifi/perps-types 3.3.2 → 4.0.1
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/cjs/account.d.ts +11 -2
- package/dist/cjs/account.d.ts.map +1 -1
- package/dist/cjs/action.d.ts +1 -0
- package/dist/cjs/action.d.ts.map +1 -1
- package/dist/cjs/asset.d.ts.map +1 -1
- package/dist/cjs/enums.d.ts +5 -0
- package/dist/cjs/enums.d.ts.map +1 -1
- package/dist/cjs/enums.js +7 -1
- package/dist/cjs/enums.js.map +1 -1
- package/dist/cjs/errors.d.ts.map +1 -1
- package/dist/cjs/market.d.ts +4 -0
- package/dist/cjs/market.d.ts.map +1 -1
- package/dist/cjs/primitives.d.ts.map +1 -1
- package/dist/cjs/providers.d.ts.map +1 -1
- package/dist/cjs/subscriptions.d.ts.map +1 -1
- package/dist/cjs/typedData.d.ts.map +1 -1
- package/dist/cjs/vote.d.ts.map +1 -1
- package/dist/cjs/vote.js.map +1 -1
- package/dist/esm/account.d.ts +223 -32
- package/dist/esm/account.d.ts.map +1 -1
- package/dist/esm/action.d.ts +205 -37
- package/dist/esm/action.d.ts.map +1 -1
- package/dist/esm/asset.d.ts +1 -4
- package/dist/esm/asset.d.ts.map +1 -1
- package/dist/esm/enums.d.ts +43 -20
- package/dist/esm/enums.d.ts.map +1 -1
- package/dist/esm/enums.js +43 -19
- package/dist/esm/enums.js.map +1 -1
- package/dist/esm/errors.d.ts +6 -1
- package/dist/esm/errors.d.ts.map +1 -1
- package/dist/esm/market.d.ts +57 -15
- package/dist/esm/market.d.ts.map +1 -1
- package/dist/esm/primitives.d.ts +12 -2
- package/dist/esm/primitives.d.ts.map +1 -1
- package/dist/esm/providers.d.ts +19 -6
- package/dist/esm/providers.d.ts.map +1 -1
- package/dist/esm/quote.d.ts +2 -2
- package/dist/esm/quote.d.ts.map +1 -1
- package/dist/esm/subscriptions.d.ts +27 -19
- package/dist/esm/subscriptions.d.ts.map +1 -1
- package/dist/esm/typedData.d.ts +15 -5
- package/dist/esm/typedData.d.ts.map +1 -1
- package/dist/esm/vote.d.ts +1 -3
- package/dist/esm/vote.d.ts.map +1 -1
- package/dist/esm/vote.js.map +1 -1
- package/dist/types/account.d.ts +223 -32
- package/dist/types/account.d.ts.map +1 -1
- package/dist/types/action.d.ts +205 -37
- package/dist/types/action.d.ts.map +1 -1
- package/dist/types/asset.d.ts +1 -4
- package/dist/types/asset.d.ts.map +1 -1
- package/dist/types/enums.d.ts +43 -20
- package/dist/types/enums.d.ts.map +1 -1
- package/dist/types/errors.d.ts +6 -1
- package/dist/types/errors.d.ts.map +1 -1
- package/dist/types/market.d.ts +57 -15
- package/dist/types/market.d.ts.map +1 -1
- package/dist/types/primitives.d.ts +12 -2
- package/dist/types/primitives.d.ts.map +1 -1
- package/dist/types/providers.d.ts +19 -6
- package/dist/types/providers.d.ts.map +1 -1
- package/dist/types/quote.d.ts +2 -2
- package/dist/types/quote.d.ts.map +1 -1
- package/dist/types/subscriptions.d.ts +27 -19
- package/dist/types/subscriptions.d.ts.map +1 -1
- package/dist/types/typedData.d.ts +15 -5
- package/dist/types/typedData.d.ts.map +1 -1
- package/dist/types/vote.d.ts +1 -3
- package/dist/types/vote.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/account.ts +225 -37
- package/src/action.ts +205 -37
- package/src/asset.ts +1 -4
- package/src/enums.ts +44 -20
- package/src/errors.ts +6 -1
- package/src/market.ts +69 -16
- package/src/primitives.ts +12 -2
- package/src/providers.ts +19 -6
- package/src/quote.ts +2 -2
- package/src/subscriptions.ts +27 -19
- package/src/typedData.ts +15 -5
- package/src/vote.ts +1 -3
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import type { AccountSummary, Balance, Fill, OpenOrder, Position, TriggerOrder } from './account.js';
|
|
2
2
|
import type { Candle, MarketContext, OhlcvInterval, OrderbookResponse, Trade } from './market.js';
|
|
3
3
|
import type { Address } from './primitives.js';
|
|
4
|
-
/** @public */
|
|
4
|
+
/** Subscription for the provider's aggregate market-context stream. @public */
|
|
5
5
|
export type MarketsContextSubscription = {
|
|
6
6
|
channel: 'marketsContext';
|
|
7
7
|
dex: string;
|
|
8
8
|
};
|
|
9
|
-
/** @public */
|
|
9
|
+
/** Subscription for one market's live context stream. @public */
|
|
10
10
|
export type MarketContextSubscription = {
|
|
11
11
|
channel: 'marketContext';
|
|
12
12
|
dex: string;
|
|
13
13
|
marketId: string;
|
|
14
14
|
};
|
|
15
|
-
/** @public */
|
|
15
|
+
/** Subscription for streamed order-book updates for one market. @public */
|
|
16
16
|
export type OrderbookSubscription = {
|
|
17
17
|
channel: 'orderbook';
|
|
18
18
|
dex: string;
|
|
@@ -26,77 +26,81 @@ export type OrderbookSubscription = {
|
|
|
26
26
|
*/
|
|
27
27
|
priceStep?: number;
|
|
28
28
|
};
|
|
29
|
-
/** @public */
|
|
29
|
+
/** Subscription for OHLCV candle updates for one market and interval. @public */
|
|
30
30
|
export type CandleSubscription = {
|
|
31
31
|
channel: 'candle';
|
|
32
32
|
dex: string;
|
|
33
33
|
marketId: string;
|
|
34
34
|
interval: OhlcvInterval;
|
|
35
35
|
};
|
|
36
|
-
/** @public */
|
|
36
|
+
/** Subscription for recent trade updates for one market. @public */
|
|
37
37
|
export type TradesSubscription = {
|
|
38
38
|
channel: 'trades';
|
|
39
39
|
dex: string;
|
|
40
40
|
marketId: string;
|
|
41
41
|
};
|
|
42
|
-
/** @public */
|
|
42
|
+
/** Subscription for order lifecycle updates for one account. @public */
|
|
43
43
|
export type OrderUpdatesSubscription = {
|
|
44
44
|
channel: 'orderUpdates';
|
|
45
45
|
dex: string;
|
|
46
46
|
address: Address;
|
|
47
47
|
};
|
|
48
|
-
/** @public */
|
|
48
|
+
/** Subscription for execution/fill updates for one account. @public */
|
|
49
49
|
export type FillsSubscription = {
|
|
50
50
|
channel: 'fills';
|
|
51
51
|
dex: string;
|
|
52
52
|
address: Address;
|
|
53
53
|
};
|
|
54
|
-
/** @public */
|
|
54
|
+
/** Subscription for the full open-position set for one account. @public */
|
|
55
55
|
export type PositionsSubscription = {
|
|
56
56
|
channel: 'positions';
|
|
57
57
|
dex: string;
|
|
58
58
|
address: Address;
|
|
59
59
|
};
|
|
60
|
-
/** @public */
|
|
60
|
+
/** Subscription for spot-balance updates for one account. @public */
|
|
61
61
|
export type SpotBalancesSubscription = {
|
|
62
62
|
channel: 'spotBalances';
|
|
63
63
|
dex: string;
|
|
64
64
|
address: Address;
|
|
65
65
|
};
|
|
66
|
-
/** @public */
|
|
66
|
+
/** Subscription for aggregate account-summary updates for one account. @public */
|
|
67
67
|
export type AccountSummarySubscription = {
|
|
68
68
|
channel: 'accountSummary';
|
|
69
69
|
dex: string;
|
|
70
70
|
address: Address;
|
|
71
71
|
};
|
|
72
|
-
/**
|
|
72
|
+
/**
|
|
73
|
+
* Union of all websocket subscription request shapes.
|
|
74
|
+
*
|
|
75
|
+
* @public
|
|
76
|
+
*/
|
|
73
77
|
export type Subscription = MarketsContextSubscription | MarketContextSubscription | OrderbookSubscription | CandleSubscription | TradesSubscription | OrderUpdatesSubscription | FillsSubscription | PositionsSubscription | SpotBalancesSubscription | AccountSummarySubscription;
|
|
74
|
-
/** @public */
|
|
78
|
+
/** Event containing the provider's aggregate market contexts. @public */
|
|
75
79
|
export type MarketsContextEvent = {
|
|
76
80
|
channel: 'marketsContext';
|
|
77
81
|
data: Record<string, MarketContext>;
|
|
78
82
|
};
|
|
79
|
-
/** @public */
|
|
83
|
+
/** Event containing one market's live context. @public */
|
|
80
84
|
export type MarketContextEvent = {
|
|
81
85
|
channel: 'marketContext';
|
|
82
86
|
data: MarketContext;
|
|
83
87
|
};
|
|
84
|
-
/** @public */
|
|
88
|
+
/** Event containing an order-book snapshot or update. @public */
|
|
85
89
|
export type OrderbookEvent = {
|
|
86
90
|
channel: 'orderbook';
|
|
87
91
|
data: OrderbookResponse;
|
|
88
92
|
};
|
|
89
|
-
/** @public */
|
|
93
|
+
/** Event containing one OHLCV candle. @public */
|
|
90
94
|
export type CandleEvent = {
|
|
91
95
|
channel: 'candle';
|
|
92
96
|
data: Candle;
|
|
93
97
|
};
|
|
94
|
-
/** @public */
|
|
98
|
+
/** Event containing recent trades. @public */
|
|
95
99
|
export type TradesEvent = {
|
|
96
100
|
channel: 'trades';
|
|
97
101
|
data: Trade[];
|
|
98
102
|
};
|
|
99
|
-
/** @public */
|
|
103
|
+
/** Event containing order upserts and terminal order ids. @public */
|
|
100
104
|
export type OrderUpdatesEvent = {
|
|
101
105
|
channel: 'orderUpdates';
|
|
102
106
|
data: {
|
|
@@ -111,7 +115,7 @@ export type OrderUpdatesEvent = {
|
|
|
111
115
|
terminated: string[];
|
|
112
116
|
};
|
|
113
117
|
};
|
|
114
|
-
/** @public */
|
|
118
|
+
/** Event containing newly observed executions/fills. @public */
|
|
115
119
|
export type FillsEvent = {
|
|
116
120
|
channel: 'fills';
|
|
117
121
|
data: Fill[];
|
|
@@ -148,6 +152,10 @@ export type AccountSummaryEvent = {
|
|
|
148
152
|
channel: 'accountSummary';
|
|
149
153
|
data: AccountSummary;
|
|
150
154
|
};
|
|
151
|
-
/**
|
|
155
|
+
/**
|
|
156
|
+
* Union of all websocket event frame shapes emitted for subscriptions.
|
|
157
|
+
*
|
|
158
|
+
* @public
|
|
159
|
+
*/
|
|
152
160
|
export type SubscriptionEvent = MarketsContextEvent | MarketContextEvent | OrderbookEvent | CandleEvent | TradesEvent | OrderUpdatesEvent | FillsEvent | PositionsEvent | SpotBalancesEvent | AccountSummaryEvent;
|
|
153
161
|
//# sourceMappingURL=subscriptions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"subscriptions.d.ts","sourceRoot":"","sources":["../../src/subscriptions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,cAAc,EACd,OAAO,EACP,IAAI,EACJ,SAAS,EACT,QAAQ,EACR,YAAY,EACb,MAAM,cAAc,CAAA;AACrB,OAAO,KAAK,EACV,MAAM,EACN,aAAa,EAC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AAED;;;;GAIG;AACH,MAAM,MAAM,iBAAiB,GACzB,mBAAmB,GACnB,kBAAkB,GAClB,cAAc,GACd,WAAW,GACX,WAAW,GACX,iBAAiB,GACjB,UAAU,GACV,cAAc,GACd,iBAAiB,GACjB,mBAAmB,CAAA"}
|
package/dist/esm/typedData.d.ts
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
import type { Address, Hex } from './primitives.js';
|
|
2
|
-
/**
|
|
2
|
+
/**
|
|
3
|
+
* EIP-712 domain fields used to identify a signing domain. `chainId` is the
|
|
4
|
+
* numeric EVM chain id when present.
|
|
5
|
+
*
|
|
6
|
+
* @public
|
|
7
|
+
*/
|
|
3
8
|
export interface TypedDataDomain {
|
|
4
9
|
name?: string;
|
|
5
10
|
version?: string;
|
|
@@ -7,21 +12,26 @@ export interface TypedDataDomain {
|
|
|
7
12
|
verifyingContract?: Address;
|
|
8
13
|
salt?: Hex;
|
|
9
14
|
}
|
|
10
|
-
/** @public */
|
|
15
|
+
/** One named field in an EIP-712 primary type definition. @public */
|
|
11
16
|
export interface TypedDataParameter {
|
|
12
17
|
name: string;
|
|
13
18
|
type: string;
|
|
14
19
|
}
|
|
15
|
-
/** @public */
|
|
20
|
+
/** Primary-type name used by a perps EIP-712 payload. @public */
|
|
16
21
|
export type PerpsPrimaryType = string;
|
|
17
|
-
/**
|
|
22
|
+
/**
|
|
23
|
+
* Provider-neutral EIP-712 payload passed between backend and SDK. `message`
|
|
24
|
+
* intentionally remains open because each action defines its own fields.
|
|
25
|
+
*
|
|
26
|
+
* @public
|
|
27
|
+
*/
|
|
18
28
|
export type PerpsTypedData = {
|
|
19
29
|
domain: TypedDataDomain;
|
|
20
30
|
types: Record<string, readonly TypedDataParameter[]>;
|
|
21
31
|
primaryType: PerpsPrimaryType;
|
|
22
32
|
message: Record<string, any>;
|
|
23
33
|
};
|
|
24
|
-
/** @public */
|
|
34
|
+
/** EIP-712 payload accompanied by its client-produced signature. @public */
|
|
25
35
|
export type PerpsSignedTypedData = PerpsTypedData & {
|
|
26
36
|
signature: Hex;
|
|
27
37
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typedData.d.ts","sourceRoot":"","sources":["../../src/typedData.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,iBAAiB,CAAA;AAEnD
|
|
1
|
+
{"version":3,"file":"typedData.d.ts","sourceRoot":"","sources":["../../src/typedData.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,MAAM,iBAAiB,CAAA;AAEnD;;;;;GAKG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,IAAI,CAAC,EAAE,GAAG,CAAA;CACX;AAED,qEAAqE;AACrE,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,MAAM,CAAA;CACb;AAED,iEAAiE;AACjE,MAAM,MAAM,gBAAgB,GAAG,MAAM,CAAA;AAErC;;;;;GAKG;AACH,MAAM,MAAM,cAAc,GAAG;IAC3B,MAAM,EAAE,eAAe,CAAA;IACvB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,kBAAkB,EAAE,CAAC,CAAA;IACpD,WAAW,EAAE,gBAAgB,CAAA;IAC7B,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;CAC7B,CAAA;AAED,4EAA4E;AAC5E,MAAM,MAAM,oBAAoB,GAAG,cAAc,GAAG;IAClD,SAAS,EAAE,GAAG,CAAA;CACf,CAAA"}
|
package/dist/esm/vote.d.ts
CHANGED
|
@@ -7,7 +7,7 @@ import type { PerpsTypedData, TypedDataParameter } from './typedData.js';
|
|
|
7
7
|
* @public
|
|
8
8
|
*/
|
|
9
9
|
export declare const META_PROVIDER = "meta";
|
|
10
|
-
/** @public */
|
|
10
|
+
/** Type alias for the {@link META_PROVIDER} provider-independent sentinel. @public */
|
|
11
11
|
export type MetaProvider = typeof META_PROVIDER;
|
|
12
12
|
/**
|
|
13
13
|
* Vote direction. `up` endorses the subject; `down` opposes it.
|
|
@@ -29,7 +29,6 @@ export type VoteType = 'provider';
|
|
|
29
29
|
* @public
|
|
30
30
|
*/
|
|
31
31
|
export interface VoteParams {
|
|
32
|
-
/** Key of the inactive provider being voted on (the voted-on subject). */
|
|
33
32
|
targetProvider: string;
|
|
34
33
|
direction: VoteDirection;
|
|
35
34
|
voteType: VoteType;
|
|
@@ -39,7 +38,6 @@ export interface VoteParams {
|
|
|
39
38
|
* @public
|
|
40
39
|
*/
|
|
41
40
|
export interface VoteMessage {
|
|
42
|
-
/** Key of the inactive provider being voted on. */
|
|
43
41
|
targetProvider: string;
|
|
44
42
|
direction: VoteDirection;
|
|
45
43
|
voteType: VoteType;
|
package/dist/esm/vote.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vote.d.ts","sourceRoot":"","sources":["../../src/vote.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAA;AAExE;;;;;GAKG;AACH,eAAO,MAAM,aAAa,SAAS,CAAA;AAEnC,
|
|
1
|
+
{"version":3,"file":"vote.d.ts","sourceRoot":"","sources":["../../src/vote.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAA;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAA;AAExE;;;;;GAKG;AACH,eAAO,MAAM,aAAa,SAAS,CAAA;AAEnC,sFAAsF;AACtF,MAAM,MAAM,YAAY,GAAG,OAAO,aAAa,CAAA;AAE/C;;;GAGG;AACH,MAAM,MAAM,aAAa,GAAG,IAAI,GAAG,MAAM,CAAA;AAEzC;;;;GAIG;AACH,MAAM,MAAM,QAAQ,GAAG,UAAU,CAAA;AAEjC;;;;;;;GAOG;AACH,MAAM,WAAW,UAAU;IACzB,cAAc,EAAE,MAAM,CAAA;IACtB,SAAS,EAAE,aAAa,CAAA;IACxB,QAAQ,EAAE,QAAQ,CAAA;CACnB;AAED;;;GAGG;AACH,MAAM,WAAW,WAAW;IAC1B,cAAc,EAAE,MAAM,CAAA;IACtB,SAAS,EAAE,aAAa,CAAA;IACxB,QAAQ,EAAE,QAAQ,CAAA;IAClB,KAAK,EAAE,OAAO,CAAA;IACd,sCAAsC;IACtC,SAAS,EAAE,MAAM,CAAA;CAClB;AAED;;;;GAIG;AACH,eAAO,MAAM,cAAc,EAAE,SAAS,kBAAkB,EAMvD,CAAA;AAED;;;;GAIG;AACH,MAAM,WAAW,aAAc,SAAQ,cAAc;IACnD,WAAW,EAAE,MAAM,CAAA;IACnB,KAAK,EAAE;QAAE,IAAI,EAAE,SAAS,kBAAkB,EAAE,CAAA;KAAE,GAAG,cAAc,CAAC,OAAO,CAAC,CAAA;IACxE,OAAO,EAAE,WAAW,CAAA;CACrB"}
|
package/dist/esm/vote.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vote.js","sourceRoot":"","sources":["../../src/vote.ts"],"names":[],"mappings":"AAGA;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAA;
|
|
1
|
+
{"version":3,"file":"vote.js","sourceRoot":"","sources":["../../src/vote.ts"],"names":[],"mappings":"AAGA;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAA;AA6CnC;;;;GAIG;AACH,MAAM,CAAC,MAAM,cAAc,GAAkC;IAC3D,EAAE,IAAI,EAAE,gBAAgB,EAAE,IAAI,EAAE,QAAQ,EAAE;IAC1C,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,QAAQ,EAAE;IACrC,EAAE,IAAI,EAAE,UAAU,EAAE,IAAI,EAAE,QAAQ,EAAE;IACpC,EAAE,IAAI,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE;IAClC,EAAE,IAAI,EAAE,WAAW,EAAE,IAAI,EAAE,SAAS,EAAE;CACvC,CAAA"}
|