@dhedge/backend-flatcoin-core 0.2.63 → 0.2.64
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Logger } from '@nestjs/common';
|
|
2
|
-
import { AnnouncedLimitOrder, AnnouncedOrder, DepositEvent, LeverageAdjust, LeveragePositionEvent, Position, UnitHolder, WithdrawEvent } from '../utils';
|
|
2
|
+
import { AnnouncedLimitOrder, AnnouncedOrder, DepositEvent, LeverageAdjust, LeveragePositionEvent, LimitOrderExecuted, Position, UnitHolder, WithdrawEvent } from '../utils';
|
|
3
3
|
import { GraphQLClient } from 'graphql-request';
|
|
4
4
|
export declare class GraphQueryService {
|
|
5
5
|
private readonly graphQLClient;
|
|
@@ -20,7 +20,7 @@ export declare class GraphQueryService {
|
|
|
20
20
|
getWithdrawsByTimestampFrom(timestampFrom: number): Promise<WithdrawEvent[]>;
|
|
21
21
|
getWithdrawsByWithdrawerAddress(account: string, blockFrom: number): Promise<WithdrawEvent[]>;
|
|
22
22
|
getLimitOrderAnnounceds(blockNumberFrom: number): Promise<AnnouncedLimitOrder[]>;
|
|
23
|
-
getLimitOrderExecutedsByTimestampFrom(timestampFrom: number): Promise<
|
|
23
|
+
getLimitOrderExecutedsByTimestampFrom(timestampFrom: number): Promise<LimitOrderExecuted[]>;
|
|
24
24
|
getAllOpenPositions(): Promise<Position[]>;
|
|
25
25
|
getOpenPositions(skip: number, first: number): Promise<Position[]>;
|
|
26
26
|
getAllClosedPositions(): Promise<Position[]>;
|
|
@@ -382,9 +382,11 @@ exports.getLeverageClosesByTimestampFromQuery = (0, graphql_request_1.gql) `
|
|
|
382
382
|
exports.getLeverageAdjustsByTimestampFromQuery = (0, graphql_request_1.gql) `
|
|
383
383
|
query GetLeverageAdhusts($blockTimestamp: Int) {
|
|
384
384
|
leverageAdjusts(where: { blockTimestamp_gt: $blockTimestamp }) {
|
|
385
|
+
tokenId
|
|
385
386
|
blockTimestamp
|
|
386
387
|
transactionHash
|
|
387
388
|
executedBy
|
|
389
|
+
blockNumber
|
|
388
390
|
}
|
|
389
391
|
}
|
|
390
392
|
`;
|
|
@@ -395,6 +397,7 @@ exports.getLeverageAdjustsByBlockFromQuery = (0, graphql_request_1.gql) `
|
|
|
395
397
|
blockNumber
|
|
396
398
|
transactionHash
|
|
397
399
|
executedBy
|
|
400
|
+
blockNumber
|
|
398
401
|
}
|
|
399
402
|
}
|
|
400
403
|
`;
|
|
@@ -47,9 +47,11 @@ export interface LeveragePositionEvent {
|
|
|
47
47
|
executedBy: string;
|
|
48
48
|
}
|
|
49
49
|
export interface LeverageAdjust {
|
|
50
|
+
tokenId: number;
|
|
50
51
|
blockTimestamp: number;
|
|
51
52
|
transactionHash: string;
|
|
52
53
|
executedBy: string;
|
|
54
|
+
blockNumber: number;
|
|
53
55
|
}
|
|
54
56
|
export interface AnnouncedLimitOrder {
|
|
55
57
|
id: string;
|