@merkl/api 0.10.420 → 0.10.422
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/database/api/.generated/drizzle/schema.d.ts +127 -0
- package/dist/database/api/.generated/drizzle/schema.js +13 -0
- package/dist/database/api/.generated/drizzle/schema.ts +15 -0
- package/dist/database/api/.generated/edge.js +28 -4
- package/dist/database/api/.generated/index-browser.js +25 -1
- package/dist/database/api/.generated/index.d.ts +1633 -205
- package/dist/database/api/.generated/index.js +28 -4
- package/dist/database/api/.generated/package.json +1 -1
- package/dist/database/api/.generated/schema.prisma +19 -0
- package/dist/database/api/.generated/wasm.js +25 -1
- package/dist/src/eden/index.d.ts +75 -115
- package/dist/src/index.d.ts +15 -23
- package/dist/src/index.js +1 -1
- package/dist/src/libs/campaigns/utils/getEulerV2Vaults.d.ts +5 -0
- package/dist/src/libs/campaigns/utils/getEulerV2Vaults.js +63 -4
- package/dist/src/libs/campaigns/utils/getUniswapV4Pools.js +72 -13
- package/dist/src/modules/v4/campaign/campaign.controller.d.ts +1 -1
- package/dist/src/modules/v4/campaign/campaign.repository.d.ts +9 -9
- package/dist/src/modules/v4/campaign/campaign.service.d.ts +1 -1
- package/dist/src/modules/v4/dynamicData/dynamicData.controller.d.ts +1 -1
- package/dist/src/modules/v4/interaction/interaction.service.js +2 -3
- package/dist/src/modules/v4/opportunity/opportunity.controller.d.ts +3 -3
- package/dist/src/modules/v4/opportunity/opportunity.model.d.ts +5 -5
- package/dist/src/modules/v4/opportunity/opportunity.repository.d.ts +72 -72
- package/dist/src/modules/v4/opportunity/opportunity.service.d.ts +1 -1
- package/dist/src/modules/v4/programPayload/programPayload.repository.d.ts +5 -0
- package/dist/src/modules/v4/programPayload/programPayload.repository.js +93 -4
- package/dist/src/modules/v4/reward/reward.controller.d.ts +4 -12
- package/dist/src/modules/v4/reward/reward.repository.d.ts +7 -11
- package/dist/src/modules/v4/reward/reward.service.d.ts +5 -10
- package/dist/src/modules/v4/router.d.ts +15 -23
- package/dist/src/modules/v4/status/status.controller.d.ts +6 -6
- package/dist/src/modules/v4/status/status.repository.d.ts +6 -6
- package/dist/src/modules/v4/status/status.service.d.ts +6 -6
- package/dist/src/modules/v4/token/token.repository.d.ts +2 -2
- package/dist/src/modules/v4/token/token.service.d.ts +3 -2
- package/dist/src/modules/v4/user/user.repository.d.ts +1 -1
- package/dist/src/modules/v4/user/user.service.d.ts +1 -1
- package/dist/src/utils/prisma.d.ts +3 -16
- package/dist/src/utils/prisma.js +1 -2
- package/dist/tsconfig.package.tsbuildinfo +1 -1
- package/package.json +1 -1
@@ -281,6 +281,7 @@ export declare const v4: Elysia<"/v4", false, {
|
|
281
281
|
tags: string[];
|
282
282
|
icon: string;
|
283
283
|
} | null | undefined;
|
284
|
+
depositUrl?: string | undefined;
|
284
285
|
aprRecord?: {
|
285
286
|
timestamp: string | bigint;
|
286
287
|
cumulated: number;
|
@@ -292,7 +293,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
292
293
|
aprRecordId: string;
|
293
294
|
}[];
|
294
295
|
} | undefined;
|
295
|
-
depositUrl?: string | undefined;
|
296
296
|
tvlRecord?: {
|
297
297
|
total: number;
|
298
298
|
timestamp: string | bigint;
|
@@ -405,6 +405,7 @@ export declare const v4: Elysia<"/v4", false, {
|
|
405
405
|
tags: string[];
|
406
406
|
icon: string;
|
407
407
|
} | null | undefined;
|
408
|
+
depositUrl?: string | undefined;
|
408
409
|
aprRecord?: {
|
409
410
|
timestamp: string | bigint;
|
410
411
|
cumulated: number;
|
@@ -416,7 +417,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
416
417
|
aprRecordId: string;
|
417
418
|
}[];
|
418
419
|
} | undefined;
|
419
|
-
depositUrl?: string | undefined;
|
420
420
|
tvlRecord?: {
|
421
421
|
total: number;
|
422
422
|
timestamp: string | bigint;
|
@@ -564,6 +564,7 @@ export declare const v4: Elysia<"/v4", false, {
|
|
564
564
|
tags: string[];
|
565
565
|
icon: string;
|
566
566
|
} | null | undefined;
|
567
|
+
depositUrl?: string | undefined;
|
567
568
|
aprRecord?: {
|
568
569
|
timestamp: string | bigint;
|
569
570
|
cumulated: number;
|
@@ -575,7 +576,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
575
576
|
aprRecordId: string;
|
576
577
|
}[];
|
577
578
|
} | undefined;
|
578
|
-
depositUrl?: string | undefined;
|
579
579
|
tvlRecord?: {
|
580
580
|
total: number;
|
581
581
|
timestamp: string | bigint;
|
@@ -1056,10 +1056,10 @@ export declare const v4: Elysia<"/v4", false, {
|
|
1056
1056
|
response: {
|
1057
1057
|
200: {
|
1058
1058
|
endTimestamp: bigint;
|
1059
|
+
campaignId: string;
|
1059
1060
|
CampaignStatus: {
|
1060
1061
|
computedUntil: bigint;
|
1061
1062
|
}[];
|
1062
|
-
campaignId: string;
|
1063
1063
|
}[];
|
1064
1064
|
};
|
1065
1065
|
};
|
@@ -1576,12 +1576,8 @@ export declare const v4: Elysia<"/v4", false, {
|
|
1576
1576
|
};
|
1577
1577
|
headers: unknown;
|
1578
1578
|
response: {
|
1579
|
-
|
1580
|
-
|
1581
|
-
claimed: string;
|
1582
|
-
pending: string;
|
1583
|
-
recipient: string;
|
1584
|
-
}[];
|
1579
|
+
[x: string]: any;
|
1580
|
+
200: any;
|
1585
1581
|
};
|
1586
1582
|
};
|
1587
1583
|
};
|
@@ -1645,12 +1641,8 @@ export declare const v4: Elysia<"/v4", false, {
|
|
1645
1641
|
};
|
1646
1642
|
headers: unknown;
|
1647
1643
|
response: {
|
1648
|
-
|
1649
|
-
|
1650
|
-
claimed: string;
|
1651
|
-
pending: string;
|
1652
|
-
recipient: string;
|
1653
|
-
}[];
|
1644
|
+
[x: string]: any;
|
1645
|
+
200: any;
|
1654
1646
|
};
|
1655
1647
|
};
|
1656
1648
|
};
|
@@ -2967,13 +2959,13 @@ export declare const v4: Elysia<"/v4", false, {
|
|
2967
2959
|
chainId?: number | undefined;
|
2968
2960
|
startTimestamp?: string | undefined;
|
2969
2961
|
endTimestamp?: string | undefined;
|
2970
|
-
campaignStatus?: {} | undefined;
|
2971
2962
|
distributionChainId?: number | undefined;
|
2972
2963
|
campaignId?: string | undefined;
|
2973
2964
|
rewardTokenId?: string | undefined;
|
2974
2965
|
amount?: string | undefined;
|
2975
2966
|
opportunityId?: string | undefined;
|
2976
2967
|
creatorAddress?: string | undefined;
|
2968
|
+
campaignStatus?: {} | undefined;
|
2977
2969
|
rewardToken?: {} | undefined;
|
2978
2970
|
rewardTokenAddress?: string | undefined;
|
2979
2971
|
distributionChain?: {} | undefined;
|
@@ -3147,6 +3139,12 @@ export declare const v4: Elysia<"/v4", false, {
|
|
3147
3139
|
delayFormatted: string;
|
3148
3140
|
startTimestamp: bigint;
|
3149
3141
|
endTimestamp: bigint;
|
3142
|
+
computeChainId: number;
|
3143
|
+
distributionChainId: number;
|
3144
|
+
campaignId: string;
|
3145
|
+
Opportunity: {
|
3146
|
+
name: string;
|
3147
|
+
};
|
3150
3148
|
CampaignStatus: {
|
3151
3149
|
error: string;
|
3152
3150
|
details: import("database/api/.generated/runtime/library").JsonValue;
|
@@ -3155,12 +3153,6 @@ export declare const v4: Elysia<"/v4", false, {
|
|
3155
3153
|
computedUntil: bigint;
|
3156
3154
|
processingStarted: bigint;
|
3157
3155
|
}[];
|
3158
|
-
Opportunity: {
|
3159
|
-
name: string;
|
3160
|
-
};
|
3161
|
-
computeChainId: number;
|
3162
|
-
distributionChainId: number;
|
3163
|
-
campaignId: string;
|
3164
3156
|
}[];
|
3165
3157
|
};
|
3166
3158
|
};
|
@@ -130,6 +130,12 @@ export declare const StatusController: Elysia<"/campaign-status", false, {
|
|
130
130
|
delayFormatted: string;
|
131
131
|
startTimestamp: bigint;
|
132
132
|
endTimestamp: bigint;
|
133
|
+
computeChainId: number;
|
134
|
+
distributionChainId: number;
|
135
|
+
campaignId: string;
|
136
|
+
Opportunity: {
|
137
|
+
name: string;
|
138
|
+
};
|
133
139
|
CampaignStatus: {
|
134
140
|
error: string;
|
135
141
|
details: import("database/api/.generated/runtime/library").JsonValue;
|
@@ -138,12 +144,6 @@ export declare const StatusController: Elysia<"/campaign-status", false, {
|
|
138
144
|
computedUntil: bigint;
|
139
145
|
processingStarted: bigint;
|
140
146
|
}[];
|
141
|
-
Opportunity: {
|
142
|
-
name: string;
|
143
|
-
};
|
144
|
-
computeChainId: number;
|
145
|
-
distributionChainId: number;
|
146
|
-
campaignId: string;
|
147
147
|
}[];
|
148
148
|
};
|
149
149
|
};
|
@@ -70,6 +70,12 @@ export declare class StatusRepository {
|
|
70
70
|
static findManyDelay(query: DelayModel): Promise<{
|
71
71
|
startTimestamp: bigint;
|
72
72
|
endTimestamp: bigint;
|
73
|
+
computeChainId: number;
|
74
|
+
distributionChainId: number;
|
75
|
+
campaignId: string;
|
76
|
+
Opportunity: {
|
77
|
+
name: string;
|
78
|
+
};
|
73
79
|
CampaignStatus: {
|
74
80
|
error: string;
|
75
81
|
details: Prisma.JsonValue;
|
@@ -78,11 +84,5 @@ export declare class StatusRepository {
|
|
78
84
|
computedUntil: bigint;
|
79
85
|
processingStarted: bigint;
|
80
86
|
}[];
|
81
|
-
Opportunity: {
|
82
|
-
name: string;
|
83
|
-
};
|
84
|
-
computeChainId: number;
|
85
|
-
distributionChainId: number;
|
86
|
-
campaignId: string;
|
87
87
|
}[]>;
|
88
88
|
}
|
@@ -40,6 +40,12 @@ export declare class StatusService {
|
|
40
40
|
delayFormatted: string;
|
41
41
|
startTimestamp: bigint;
|
42
42
|
endTimestamp: bigint;
|
43
|
+
computeChainId: number;
|
44
|
+
distributionChainId: number;
|
45
|
+
campaignId: string;
|
46
|
+
Opportunity: {
|
47
|
+
name: string;
|
48
|
+
};
|
43
49
|
CampaignStatus: {
|
44
50
|
error: string;
|
45
51
|
details: import("database/api/.generated/runtime/library").JsonValue;
|
@@ -48,11 +54,5 @@ export declare class StatusService {
|
|
48
54
|
computedUntil: bigint;
|
49
55
|
processingStarted: bigint;
|
50
56
|
}[];
|
51
|
-
Opportunity: {
|
52
|
-
name: string;
|
53
|
-
};
|
54
|
-
computeChainId: number;
|
55
|
-
distributionChainId: number;
|
56
|
-
campaignId: string;
|
57
57
|
}[]>;
|
58
58
|
}
|
@@ -67,14 +67,14 @@ export declare abstract class TokenRepository {
|
|
67
67
|
* @param price value
|
68
68
|
* @param excludeAddresses to not update even if symbol match
|
69
69
|
*/
|
70
|
-
static updateSymbolPrices(symbol: string, price: number, excludeAddresses: string[]): Promise<import("database/api/.generated
|
70
|
+
static updateSymbolPrices(symbol: string, price: number, excludeAddresses: string[]): Promise<import("../../../../database/api/.generated").Prisma.BatchPayload>;
|
71
71
|
/**
|
72
72
|
* Updates price of tokens that share the same address
|
73
73
|
* @param address
|
74
74
|
* @param price value
|
75
75
|
* @param chainId
|
76
76
|
*/
|
77
|
-
static updateAddressPrices(address: string, price: number, chainId?: number): Promise<import("database/api/.generated
|
77
|
+
static updateAddressPrices(address: string, price: number, chainId?: number): Promise<import("../../../../database/api/.generated").Prisma.BatchPayload>;
|
78
78
|
static findChains(): Promise<Record<string, ChainId>>;
|
79
79
|
/**
|
80
80
|
* create a token on database
|
@@ -1,5 +1,6 @@
|
|
1
1
|
import type { CreateTokenModel, GetTokenQueryModel, Token, TokenModel, TokenUnique, UpdateTokenModel } from "./";
|
2
2
|
import type { Pricer } from "../../../utils/pricer";
|
3
|
+
import { Prisma } from "../../../../database/api/.generated";
|
3
4
|
import { type ChainId } from "@sdk";
|
4
5
|
import { TokenRepository } from "./token.repository";
|
5
6
|
export declare abstract class TokenService {
|
@@ -71,14 +72,14 @@ export declare abstract class TokenService {
|
|
71
72
|
* @param price value
|
72
73
|
* @param excludeAddresses to not update symbols that defined using addresses
|
73
74
|
*/
|
74
|
-
static updateSymbolPrices(symbol: string, price: number, excludeAddresses: string[]): Promise<
|
75
|
+
static updateSymbolPrices(symbol: string, price: number, excludeAddresses: string[]): Promise<Prisma.BatchPayload>;
|
75
76
|
/**
|
76
77
|
* Updates price of tokens that share the same address
|
77
78
|
* @param address
|
78
79
|
* @param price value
|
79
80
|
* @param chainId
|
80
81
|
*/
|
81
|
-
static updateAddressPrices(address: string, price: number, chainId?: number): Promise<
|
82
|
+
static updateAddressPrices(address: string, price: number, chainId?: number): Promise<Prisma.BatchPayload>;
|
82
83
|
/**
|
83
84
|
* Updates price of tokens that share the same symbol
|
84
85
|
* @param symbol
|
@@ -20,7 +20,7 @@ export declare abstract class UserRepository {
|
|
20
20
|
address: string;
|
21
21
|
creatorId: string | null;
|
22
22
|
}>;
|
23
|
-
static createMany(users: UserModel[]): Promise<import("database/api/.generated
|
23
|
+
static createMany(users: UserModel[]): Promise<import("../../../../database/api/.generated").Prisma.BatchPayload>;
|
24
24
|
static updateTags(address: string, tags: string[]): Promise<{
|
25
25
|
tags: string[];
|
26
26
|
address: string;
|
@@ -20,7 +20,7 @@ export declare abstract class UserService {
|
|
20
20
|
address: string;
|
21
21
|
creatorId: string | null;
|
22
22
|
}>;
|
23
|
-
static createMany(users: UserModel[]): Promise<import("database/api/.generated
|
23
|
+
static createMany(users: UserModel[]): Promise<import("../../../../database/api/.generated").Prisma.BatchPayload>;
|
24
24
|
static updateTags(user: string, tags: string[]): Promise<{
|
25
25
|
tags: string[];
|
26
26
|
address: string;
|
@@ -1,25 +1,12 @@
|
|
1
|
+
import { PrismaClient as ApiPrismaClient } from "../../database/api/.generated";
|
1
2
|
import { PrismaClient as EnginePrismaClient } from "../../database/engine/.generated";
|
2
|
-
export declare const apiDbClient:
|
3
|
-
result: {};
|
4
|
-
model: {};
|
5
|
-
query: {};
|
6
|
-
client: {
|
7
|
-
$drizzle: () => import("drizzle-orm/prisma/pg").PrismaPgDatabase;
|
8
|
-
};
|
9
|
-
}, import("../../database/api/.generated").Prisma.PrismaClientOptions>, import("../../database/api/.generated").Prisma.TypeMapCb, {
|
10
|
-
result: {};
|
11
|
-
model: {};
|
12
|
-
query: {};
|
13
|
-
client: {
|
14
|
-
$drizzle: () => import("drizzle-orm/prisma/pg").PrismaPgDatabase;
|
15
|
-
};
|
16
|
-
}, {
|
3
|
+
export declare const apiDbClient: ApiPrismaClient<{
|
17
4
|
datasources: {
|
18
5
|
db: {
|
19
6
|
url: string;
|
20
7
|
};
|
21
8
|
};
|
22
|
-
}>;
|
9
|
+
}, never, import("database/api/.generated/runtime/library").DefaultArgs>;
|
23
10
|
export declare const engineDbClient: EnginePrismaClient<{
|
24
11
|
datasources: {
|
25
12
|
db: {
|
package/dist/src/utils/prisma.js
CHANGED
@@ -1,9 +1,8 @@
|
|
1
1
|
import { PrismaClient as ApiPrismaClient } from "../../database/api/.generated";
|
2
2
|
import { PrismaClient as EnginePrismaClient } from "../../database/engine/.generated";
|
3
|
-
import { drizzle } from "drizzle-orm/prisma/pg";
|
4
3
|
export const apiDbClient = new ApiPrismaClient({
|
5
4
|
datasources: { db: { url: `${process.env.DATABASE_API_URL}&connection_limit=250&pool_timeout=15` } },
|
6
|
-
})
|
5
|
+
});
|
7
6
|
export const engineDbClient = new EnginePrismaClient({
|
8
7
|
datasources: {
|
9
8
|
db: {
|