@merkl/api 1.0.47 → 1.0.49
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/src/eden/index.d.ts +4 -604
- package/dist/src/engine/implementations/Ajna/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Ambient/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Badger/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Clamm/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Compound/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/CompoundV3/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Default/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Dolomite/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/EigenLayer/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Encompassing/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/aave/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/bunni/metadata.d.ts +18 -0
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/bunni/tvl.d.ts +6 -0
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/euler/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/gamma/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/gearbox/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/hypurrfiIsolatedMarket/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/lendleVaults/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/metamorpho/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/pino/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/termmax/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/termmaxVault/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/uniswapV2/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20/subTypes/implementations/uniswapV2/mimswap/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc20Snapshot/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Erc721/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/ErcMultiToken/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/EventBased/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/FraxLend/metadataBorrow.d.ts +2 -2
- package/dist/src/engine/implementations/FraxLend/metadataCollateral.d.ts +1 -1
- package/dist/src/engine/implementations/Hyperdrive/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Ion/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/JsonAirdrop/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Locker/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Morpho/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/MultiLog/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Radiant/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Silo/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/UniswapV4/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/Vest/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/morphoBorrow/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/morphoCollateral/metadata.d.ts +1 -1
- package/dist/src/engine/implementations/morphoSupply/metadata.d.ts +1 -1
- package/dist/src/index.d.ts +2 -307
- package/dist/src/modules/v4/campaign/campaign.controller.d.ts +0 -55
- package/dist/src/modules/v4/campaign/campaign.convertor.d.ts +6 -0
- package/dist/src/modules/v4/campaign/campaign.formatter.d.ts +6 -0
- package/dist/src/modules/v4/campaign/campaign.model.d.ts +11 -9
- package/dist/src/modules/v4/campaign/campaign.repository.d.ts +32 -31
- package/dist/src/modules/v4/campaign/campaign.service.d.ts +18 -702
- package/dist/src/modules/v4/creator/creator.controller.d.ts +2 -162
- package/dist/src/modules/v4/creator/creator.service.d.ts +2 -162
- package/dist/src/modules/v4/opportunity/opportunity.controller.d.ts +0 -90
- package/dist/src/modules/v4/opportunity/opportunity.converter.d.ts +2 -6
- package/dist/src/modules/v4/opportunity/opportunity.formatter.d.ts +174 -0
- package/dist/src/modules/v4/opportunity/opportunity.model.d.ts +15 -5
- package/dist/src/modules/v4/opportunity/opportunity.repository.d.ts +2 -4
- package/dist/src/modules/v4/opportunity/opportunity.service.d.ts +14 -460
- package/dist/src/modules/v4/programPayload/programPayload.repository.d.ts +125 -1
- package/dist/src/modules/v4/reward/reward.service.d.ts +8 -88
- package/dist/src/modules/v4/router.d.ts +2 -307
- package/dist/src/modules/v4/status/status.model.d.ts +0 -1
- package/dist/src/modules/v4/status/status.service.d.ts +2 -2
- package/dist/src/utils/prices/services/coinGeckoService.d.ts +1 -1
- package/dist/src/utils/prices/services/defillamaService.d.ts +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
package/dist/src/index.d.ts
CHANGED
@@ -344,7 +344,6 @@ declare const app: Elysia<"", {
|
|
344
344
|
campaignStatus?: {
|
345
345
|
error?: string | undefined;
|
346
346
|
details?: any;
|
347
|
-
campaignId: string;
|
348
347
|
status: string;
|
349
348
|
computedUntil: string | number;
|
350
349
|
processingStarted: string | number;
|
@@ -383,10 +382,8 @@ declare const app: Elysia<"", {
|
|
383
382
|
computeChainId: number;
|
384
383
|
distributionChainId: number;
|
385
384
|
endTimestamp: string | number;
|
386
|
-
opportunityId: string;
|
387
385
|
creatorAddress: string;
|
388
386
|
subType: number | null;
|
389
|
-
rewardTokenId: string;
|
390
387
|
createdAt: string;
|
391
388
|
chain: {
|
392
389
|
explorers?: {
|
@@ -687,7 +684,6 @@ declare const app: Elysia<"", {
|
|
687
684
|
campaignStatus?: {
|
688
685
|
error?: string | undefined;
|
689
686
|
details?: any;
|
690
|
-
campaignId: string;
|
691
687
|
status: string;
|
692
688
|
computedUntil: string | number;
|
693
689
|
processingStarted: string | number;
|
@@ -726,10 +722,8 @@ declare const app: Elysia<"", {
|
|
726
722
|
computeChainId: number;
|
727
723
|
distributionChainId: number;
|
728
724
|
endTimestamp: string | number;
|
729
|
-
opportunityId: string;
|
730
725
|
creatorAddress: string;
|
731
726
|
subType: number | null;
|
732
|
-
rewardTokenId: string;
|
733
727
|
createdAt: string;
|
734
728
|
chain: {
|
735
729
|
explorers?: {
|
@@ -1259,90 +1253,6 @@ declare const app: Elysia<"", {
|
|
1259
1253
|
};
|
1260
1254
|
};
|
1261
1255
|
};
|
1262
|
-
} & {
|
1263
|
-
opportunities: {
|
1264
|
-
post: {
|
1265
|
-
body: {
|
1266
|
-
name?: string | undefined;
|
1267
|
-
description?: string | undefined;
|
1268
|
-
depositUrl?: string | undefined;
|
1269
|
-
explorerAddress?: string | undefined;
|
1270
|
-
howToSteps?: string[] | undefined;
|
1271
|
-
tags?: string[] | undefined;
|
1272
|
-
protocols?: string[] | undefined;
|
1273
|
-
mainProtocol?: string | undefined;
|
1274
|
-
tokens: {
|
1275
|
-
address: string;
|
1276
|
-
chainId: number;
|
1277
|
-
}[];
|
1278
|
-
status: "NONE" | "PAST" | "LIVE" | "SOON";
|
1279
|
-
chainId: number;
|
1280
|
-
action: "POOL" | "INVALID" | "HOLD" | "DROP" | "LEND" | "BORROW" | "LONG" | "SHORT" | "SWAP";
|
1281
|
-
type: string;
|
1282
|
-
identifier: string;
|
1283
|
-
};
|
1284
|
-
params: {};
|
1285
|
-
query: unknown;
|
1286
|
-
headers: {
|
1287
|
-
authorization: string;
|
1288
|
-
};
|
1289
|
-
response: {
|
1290
|
-
200: {
|
1291
|
-
Tokens: {
|
1292
|
-
symbol: string;
|
1293
|
-
name: string | null;
|
1294
|
-
decimals: number;
|
1295
|
-
price: number | null;
|
1296
|
-
address: string;
|
1297
|
-
id: string;
|
1298
|
-
chainId: number;
|
1299
|
-
icon: string;
|
1300
|
-
isNative: boolean;
|
1301
|
-
isPoint: boolean;
|
1302
|
-
isPreTGE: boolean;
|
1303
|
-
isTest: boolean;
|
1304
|
-
verified: boolean;
|
1305
|
-
displaySymbol: string;
|
1306
|
-
}[];
|
1307
|
-
Protocols: {
|
1308
|
-
name: string;
|
1309
|
-
description: string;
|
1310
|
-
id: string;
|
1311
|
-
url: string;
|
1312
|
-
icon: string;
|
1313
|
-
tags: string[];
|
1314
|
-
}[];
|
1315
|
-
name: string;
|
1316
|
-
apr: number;
|
1317
|
-
tvl: number;
|
1318
|
-
description: string;
|
1319
|
-
id: string;
|
1320
|
-
status: import("@package/databases").Status;
|
1321
|
-
chainId: number;
|
1322
|
-
action: import("@package/databases").OpportunityAction;
|
1323
|
-
type: string;
|
1324
|
-
depositUrl: string | null;
|
1325
|
-
explorerAddress: string | null;
|
1326
|
-
howToSteps: string[];
|
1327
|
-
mainProtocolId: string | null;
|
1328
|
-
manualOverrides: import("@package/databases").OpportunityManualOverride[];
|
1329
|
-
identifier: string;
|
1330
|
-
dailyRewards: number;
|
1331
|
-
tags: string[];
|
1332
|
-
lastCampaignCreatedAt: Date;
|
1333
|
-
};
|
1334
|
-
422: {
|
1335
|
-
type: "validation";
|
1336
|
-
on: string;
|
1337
|
-
summary?: string;
|
1338
|
-
message?: string;
|
1339
|
-
found?: unknown;
|
1340
|
-
property?: string;
|
1341
|
-
expected?: string;
|
1342
|
-
};
|
1343
|
-
};
|
1344
|
-
};
|
1345
|
-
};
|
1346
1256
|
} & {
|
1347
1257
|
opportunities: {
|
1348
1258
|
":id": {
|
@@ -1811,7 +1721,6 @@ declare const app: Elysia<"", {
|
|
1811
1721
|
campaignStatus?: {
|
1812
1722
|
error?: string | undefined;
|
1813
1723
|
details?: any;
|
1814
|
-
campaignId: string;
|
1815
1724
|
status: string;
|
1816
1725
|
computedUntil: string | number;
|
1817
1726
|
processingStarted: string | number;
|
@@ -1850,10 +1759,8 @@ declare const app: Elysia<"", {
|
|
1850
1759
|
computeChainId: number;
|
1851
1760
|
distributionChainId: number;
|
1852
1761
|
endTimestamp: string | number;
|
1853
|
-
opportunityId: string;
|
1854
1762
|
creatorAddress: string;
|
1855
1763
|
subType: number | null;
|
1856
|
-
rewardTokenId: string;
|
1857
1764
|
createdAt: string;
|
1858
1765
|
chain: {
|
1859
1766
|
explorers?: {
|
@@ -2119,7 +2026,6 @@ declare const app: Elysia<"", {
|
|
2119
2026
|
campaignStatus?: {
|
2120
2027
|
error?: string | undefined;
|
2121
2028
|
details?: any;
|
2122
|
-
campaignId: string;
|
2123
2029
|
status: string;
|
2124
2030
|
computedUntil: string | number;
|
2125
2031
|
processingStarted: string | number;
|
@@ -2158,10 +2064,8 @@ declare const app: Elysia<"", {
|
|
2158
2064
|
computeChainId: number;
|
2159
2065
|
distributionChainId: number;
|
2160
2066
|
endTimestamp: string | number;
|
2161
|
-
opportunityId: string;
|
2162
2067
|
creatorAddress: string;
|
2163
2068
|
subType: number | null;
|
2164
|
-
rewardTokenId: string;
|
2165
2069
|
createdAt: string;
|
2166
2070
|
chain: {
|
2167
2071
|
explorers?: {
|
@@ -2493,55 +2397,6 @@ declare const app: Elysia<"", {
|
|
2493
2397
|
};
|
2494
2398
|
};
|
2495
2399
|
};
|
2496
|
-
} & {
|
2497
|
-
campaigns: {
|
2498
|
-
metadata: {
|
2499
|
-
patch: {
|
2500
|
-
body: {
|
2501
|
-
campaignId: string;
|
2502
|
-
url: string;
|
2503
|
-
distributionChain: number;
|
2504
|
-
};
|
2505
|
-
params: {};
|
2506
|
-
query: unknown;
|
2507
|
-
headers: {
|
2508
|
-
authorization: string;
|
2509
|
-
};
|
2510
|
-
response: {
|
2511
|
-
200: {
|
2512
|
-
campaignId: string;
|
2513
|
-
description: string | null;
|
2514
|
-
id: string;
|
2515
|
-
params: import("@prisma/client/runtime/library").JsonValue;
|
2516
|
-
amount: string;
|
2517
|
-
startTimestamp: bigint;
|
2518
|
-
type: string;
|
2519
|
-
computeChainId: number;
|
2520
|
-
distributionChainId: number;
|
2521
|
-
endTimestamp: bigint;
|
2522
|
-
opportunityId: string;
|
2523
|
-
creatorAddress: string;
|
2524
|
-
distributionType: import("@package/databases").DistributionType;
|
2525
|
-
subType: number | null;
|
2526
|
-
rewardTokenId: string;
|
2527
|
-
manualOverrides: import("@package/databases").CampaignManualOverride[];
|
2528
|
-
createdAt: Date;
|
2529
|
-
rootCampaignId: string | null;
|
2530
|
-
parentCampaignId: string | null;
|
2531
|
-
};
|
2532
|
-
422: {
|
2533
|
-
type: "validation";
|
2534
|
-
on: string;
|
2535
|
-
summary?: string;
|
2536
|
-
message?: string;
|
2537
|
-
found?: unknown;
|
2538
|
-
property?: string;
|
2539
|
-
expected?: string;
|
2540
|
-
};
|
2541
|
-
};
|
2542
|
-
};
|
2543
|
-
};
|
2544
|
-
};
|
2545
2400
|
} & {
|
2546
2401
|
campaigns: {
|
2547
2402
|
tvls: {
|
@@ -7753,87 +7608,7 @@ declare const app: Elysia<"", {
|
|
7753
7608
|
createdAt: Date;
|
7754
7609
|
rootCampaignId: string | null;
|
7755
7610
|
parentCampaignId: string | null;
|
7756
|
-
}) |
|
7757
|
-
params: any;
|
7758
|
-
chain: {
|
7759
|
-
name: string;
|
7760
|
-
id: number;
|
7761
|
-
icon: string;
|
7762
|
-
};
|
7763
|
-
endTimestamp: number;
|
7764
|
-
startTimestamp: number;
|
7765
|
-
rewardToken: {
|
7766
|
-
symbol: string;
|
7767
|
-
name: string | null;
|
7768
|
-
decimals: number;
|
7769
|
-
address: string;
|
7770
|
-
id: string;
|
7771
|
-
chainId: number;
|
7772
|
-
icon: string;
|
7773
|
-
isNative: boolean;
|
7774
|
-
isPoint: boolean;
|
7775
|
-
isPreTGE: boolean;
|
7776
|
-
isTest: boolean;
|
7777
|
-
verified: boolean;
|
7778
|
-
} & {
|
7779
|
-
price?: number | null | undefined;
|
7780
|
-
isTokenWrapper?: boolean | undefined;
|
7781
|
-
tokenWrapperAddress?: string | undefined;
|
7782
|
-
};
|
7783
|
-
distributionChain: {
|
7784
|
-
name: string;
|
7785
|
-
id: number;
|
7786
|
-
icon: string;
|
7787
|
-
} | undefined;
|
7788
|
-
campaignStatus: {
|
7789
|
-
computedUntil: number;
|
7790
|
-
processingStarted: number;
|
7791
|
-
campaignId: string;
|
7792
|
-
error: string;
|
7793
|
-
status: import("@package/databases").RunStatus;
|
7794
|
-
details: import("@prisma/client/runtime/library").JsonValue;
|
7795
|
-
} | undefined;
|
7796
|
-
creatorAddress: string;
|
7797
|
-
creator: {
|
7798
|
-
address: string;
|
7799
|
-
tags: string[];
|
7800
|
-
creatorId: string | null;
|
7801
|
-
};
|
7802
|
-
createdAt: string;
|
7803
|
-
description: string | undefined;
|
7804
|
-
parentCampaignId: string | undefined;
|
7805
|
-
rootCampaignId: string | undefined;
|
7806
|
-
Opportunity: {
|
7807
|
-
name: string;
|
7808
|
-
apr: number;
|
7809
|
-
tvl: number;
|
7810
|
-
description: string;
|
7811
|
-
id: string;
|
7812
|
-
status: import("@package/databases").Status;
|
7813
|
-
chainId: number;
|
7814
|
-
action: import("@package/databases").OpportunityAction;
|
7815
|
-
type: string;
|
7816
|
-
depositUrl: string | null;
|
7817
|
-
explorerAddress: string | null;
|
7818
|
-
howToSteps: string[];
|
7819
|
-
mainProtocolId: string | null;
|
7820
|
-
manualOverrides: import("@package/databases").OpportunityManualOverride[];
|
7821
|
-
identifier: string;
|
7822
|
-
dailyRewards: number;
|
7823
|
-
tags: string[];
|
7824
|
-
lastCampaignCreatedAt: Date;
|
7825
|
-
};
|
7826
|
-
campaignId: string;
|
7827
|
-
id: string;
|
7828
|
-
amount: string;
|
7829
|
-
type: string;
|
7830
|
-
computeChainId: number;
|
7831
|
-
distributionChainId: number;
|
7832
|
-
opportunityId: string;
|
7833
|
-
distributionType: import("@package/databases").DistributionType;
|
7834
|
-
subType: number | null;
|
7835
|
-
rewardTokenId: string;
|
7836
|
-
})[];
|
7611
|
+
}) | Omit<import("./modules/v4/campaign/campaign.model").CampaignWithParams, "manualOverrides">)[];
|
7837
7612
|
422: {
|
7838
7613
|
type: "validation";
|
7839
7614
|
on: string;
|
@@ -7904,87 +7679,7 @@ declare const app: Elysia<"", {
|
|
7904
7679
|
createdAt: Date;
|
7905
7680
|
rootCampaignId: string | null;
|
7906
7681
|
parentCampaignId: string | null;
|
7907
|
-
})[] |
|
7908
|
-
params: any;
|
7909
|
-
chain: {
|
7910
|
-
name: string;
|
7911
|
-
id: number;
|
7912
|
-
icon: string;
|
7913
|
-
};
|
7914
|
-
endTimestamp: number;
|
7915
|
-
startTimestamp: number;
|
7916
|
-
rewardToken: {
|
7917
|
-
symbol: string;
|
7918
|
-
name: string | null;
|
7919
|
-
decimals: number;
|
7920
|
-
address: string;
|
7921
|
-
id: string;
|
7922
|
-
chainId: number;
|
7923
|
-
icon: string;
|
7924
|
-
isNative: boolean;
|
7925
|
-
isPoint: boolean;
|
7926
|
-
isPreTGE: boolean;
|
7927
|
-
isTest: boolean;
|
7928
|
-
verified: boolean;
|
7929
|
-
} & {
|
7930
|
-
price?: number | null | undefined;
|
7931
|
-
isTokenWrapper?: boolean | undefined;
|
7932
|
-
tokenWrapperAddress?: string | undefined;
|
7933
|
-
};
|
7934
|
-
distributionChain: {
|
7935
|
-
name: string;
|
7936
|
-
id: number;
|
7937
|
-
icon: string;
|
7938
|
-
} | undefined;
|
7939
|
-
campaignStatus: {
|
7940
|
-
computedUntil: number;
|
7941
|
-
processingStarted: number;
|
7942
|
-
campaignId: string;
|
7943
|
-
error: string;
|
7944
|
-
status: import("@package/databases").RunStatus;
|
7945
|
-
details: import("@prisma/client/runtime/library").JsonValue;
|
7946
|
-
} | undefined;
|
7947
|
-
creatorAddress: string;
|
7948
|
-
creator: {
|
7949
|
-
address: string;
|
7950
|
-
tags: string[];
|
7951
|
-
creatorId: string | null;
|
7952
|
-
};
|
7953
|
-
createdAt: string;
|
7954
|
-
description: string | undefined;
|
7955
|
-
parentCampaignId: string | undefined;
|
7956
|
-
rootCampaignId: string | undefined;
|
7957
|
-
Opportunity: {
|
7958
|
-
name: string;
|
7959
|
-
apr: number;
|
7960
|
-
tvl: number;
|
7961
|
-
description: string;
|
7962
|
-
id: string;
|
7963
|
-
status: import("@package/databases").Status;
|
7964
|
-
chainId: number;
|
7965
|
-
action: import("@package/databases").OpportunityAction;
|
7966
|
-
type: string;
|
7967
|
-
depositUrl: string | null;
|
7968
|
-
explorerAddress: string | null;
|
7969
|
-
howToSteps: string[];
|
7970
|
-
mainProtocolId: string | null;
|
7971
|
-
manualOverrides: import("@package/databases").OpportunityManualOverride[];
|
7972
|
-
identifier: string;
|
7973
|
-
dailyRewards: number;
|
7974
|
-
tags: string[];
|
7975
|
-
lastCampaignCreatedAt: Date;
|
7976
|
-
};
|
7977
|
-
campaignId: string;
|
7978
|
-
id: string;
|
7979
|
-
amount: string;
|
7980
|
-
type: string;
|
7981
|
-
computeChainId: number;
|
7982
|
-
distributionChainId: number;
|
7983
|
-
opportunityId: string;
|
7984
|
-
distributionType: import("@package/databases").DistributionType;
|
7985
|
-
subType: number | null;
|
7986
|
-
rewardTokenId: string;
|
7987
|
-
}[];
|
7682
|
+
})[] | Omit<import("./modules/v4/campaign/campaign.model").CampaignWithParams, "manualOverrides">[];
|
7988
7683
|
422: {
|
7989
7684
|
type: "validation";
|
7990
7685
|
on: string;
|
@@ -174,7 +174,6 @@ export declare const CampaignController: Elysia<"/campaigns", {
|
|
174
174
|
campaignStatus?: {
|
175
175
|
error?: string | undefined;
|
176
176
|
details?: any;
|
177
|
-
campaignId: string;
|
178
177
|
status: string;
|
179
178
|
computedUntil: string | number;
|
180
179
|
processingStarted: string | number;
|
@@ -213,10 +212,8 @@ export declare const CampaignController: Elysia<"/campaigns", {
|
|
213
212
|
computeChainId: number;
|
214
213
|
distributionChainId: number;
|
215
214
|
endTimestamp: string | number;
|
216
|
-
opportunityId: string;
|
217
215
|
creatorAddress: string;
|
218
216
|
subType: number | null;
|
219
|
-
rewardTokenId: string;
|
220
217
|
createdAt: string;
|
221
218
|
chain: {
|
222
219
|
explorers?: {
|
@@ -482,7 +479,6 @@ export declare const CampaignController: Elysia<"/campaigns", {
|
|
482
479
|
campaignStatus?: {
|
483
480
|
error?: string | undefined;
|
484
481
|
details?: any;
|
485
|
-
campaignId: string;
|
486
482
|
status: string;
|
487
483
|
computedUntil: string | number;
|
488
484
|
processingStarted: string | number;
|
@@ -521,10 +517,8 @@ export declare const CampaignController: Elysia<"/campaigns", {
|
|
521
517
|
computeChainId: number;
|
522
518
|
distributionChainId: number;
|
523
519
|
endTimestamp: string | number;
|
524
|
-
opportunityId: string;
|
525
520
|
creatorAddress: string;
|
526
521
|
subType: number | null;
|
527
|
-
rewardTokenId: string;
|
528
522
|
createdAt: string;
|
529
523
|
chain: {
|
530
524
|
explorers?: {
|
@@ -856,55 +850,6 @@ export declare const CampaignController: Elysia<"/campaigns", {
|
|
856
850
|
};
|
857
851
|
};
|
858
852
|
};
|
859
|
-
} & {
|
860
|
-
campaigns: {
|
861
|
-
metadata: {
|
862
|
-
patch: {
|
863
|
-
body: {
|
864
|
-
campaignId: string;
|
865
|
-
url: string;
|
866
|
-
distributionChain: number;
|
867
|
-
};
|
868
|
-
params: {};
|
869
|
-
query: unknown;
|
870
|
-
headers: {
|
871
|
-
authorization: string;
|
872
|
-
};
|
873
|
-
response: {
|
874
|
-
200: {
|
875
|
-
campaignId: string;
|
876
|
-
description: string | null;
|
877
|
-
id: string;
|
878
|
-
params: import("@prisma/client/runtime/library").JsonValue;
|
879
|
-
amount: string;
|
880
|
-
startTimestamp: bigint;
|
881
|
-
type: string;
|
882
|
-
computeChainId: number;
|
883
|
-
distributionChainId: number;
|
884
|
-
endTimestamp: bigint;
|
885
|
-
opportunityId: string;
|
886
|
-
creatorAddress: string;
|
887
|
-
distributionType: import("@package/databases").DistributionType;
|
888
|
-
subType: number | null;
|
889
|
-
rewardTokenId: string;
|
890
|
-
manualOverrides: import("@package/databases").CampaignManualOverride[];
|
891
|
-
createdAt: Date;
|
892
|
-
rootCampaignId: string | null;
|
893
|
-
parentCampaignId: string | null;
|
894
|
-
};
|
895
|
-
422: {
|
896
|
-
type: "validation";
|
897
|
-
on: string;
|
898
|
-
summary?: string;
|
899
|
-
message?: string;
|
900
|
-
found?: unknown;
|
901
|
-
property?: string;
|
902
|
-
expected?: string;
|
903
|
-
};
|
904
|
-
};
|
905
|
-
};
|
906
|
-
};
|
907
|
-
};
|
908
853
|
} & {
|
909
854
|
campaigns: {
|
910
855
|
tvls: {
|
@@ -0,0 +1,6 @@
|
|
1
|
+
import type { CampaignParameters, Campaign as CampaignType } from "@angleprotocol/sdk/ts";
|
2
|
+
import type { CampaignWithParams } from "../../../modules/v4/campaign/campaign.model";
|
3
|
+
import type { OpportunityService } from "../../../modules/v4/opportunity/opportunity.service";
|
4
|
+
export declare abstract class CampaignConvertor {
|
5
|
+
static convertToV3<C extends CampaignType>(campaignType: C, campaign: Exclude<Awaited<ReturnType<(typeof OpportunityService)["findMany"]>>[number]["campaigns"], undefined>[number] | Omit<CampaignWithParams<C>, "manualOverrides" | "opportunityId">, opportunityIdentifier: string): CampaignParameters<C>;
|
6
|
+
}
|
@@ -0,0 +1,6 @@
|
|
1
|
+
import type { Campaign as CampaignType } from "@angleprotocol/sdk/ts";
|
2
|
+
import type { CampaignWithParams } from "../../../modules/v4/campaign/campaign.model";
|
3
|
+
import type { CampaignRepository } from "./campaign.repository";
|
4
|
+
export declare abstract class CampaignFormatter {
|
5
|
+
static format<C extends CampaignType>(campaign: NonNullable<Awaited<ReturnType<(typeof CampaignRepository)["findUniqueOrThrow"]>>>): Omit<CampaignWithParams, "manualOverrides">;
|
6
|
+
}
|
@@ -2,13 +2,14 @@ import type { CampaignParameters, Campaign as CampaignType } from "@angleprotoco
|
|
2
2
|
import type { Resource } from "../../../modules/v4/prisma";
|
3
3
|
import { type Token } from "../../../modules/v4/token/token.model";
|
4
4
|
import { type Chain } from "../chain/chain.model";
|
5
|
+
import type { OpportunityLight } from "../opportunity/opportunity.model";
|
5
6
|
import { type Status as StatusModel } from "../status/status.model";
|
6
7
|
/**
|
7
8
|
* Campaign
|
8
9
|
* @description Target description of rewards campaigns
|
9
10
|
* @see {@link Resource}
|
10
11
|
*/
|
11
|
-
export type Campaign = Resource<"Campaign",
|
12
|
+
export type Campaign = Resource<"Campaign", undefined, {
|
12
13
|
chain: Chain["model"];
|
13
14
|
rewardToken: Token["model"];
|
14
15
|
distributionChain?: Chain["model"];
|
@@ -18,6 +19,7 @@ export type Campaign = Resource<"Campaign", "opportunityId" | "rewardTokenId", {
|
|
18
19
|
tags?: string[];
|
19
20
|
creatorId: string | null;
|
20
21
|
};
|
22
|
+
Opportunity?: OpportunityLight["model"];
|
21
23
|
description?: string;
|
22
24
|
endTimestamp: number;
|
23
25
|
startTimestamp: number;
|
@@ -40,9 +42,7 @@ export declare const CampaignResourceDto: import("@sinclair/typebox").TObject<{
|
|
40
42
|
campaignId: import("@sinclair/typebox").TString;
|
41
43
|
type: import("@sinclair/typebox").TString;
|
42
44
|
subType: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TNumber, import("@sinclair/typebox").TNull]>;
|
43
|
-
rewardTokenId: import("@sinclair/typebox").TString;
|
44
45
|
amount: import("@sinclair/typebox").TString;
|
45
|
-
opportunityId: import("@sinclair/typebox").TString;
|
46
46
|
startTimestamp: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNumber]>;
|
47
47
|
endTimestamp: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNumber]>;
|
48
48
|
creatorAddress: import("@sinclair/typebox").TString;
|
@@ -102,7 +102,6 @@ export declare const CampaignResourceDto: import("@sinclair/typebox").TObject<{
|
|
102
102
|
readonly FIX_REWARD_AMOUNT_PER_LIQUIDITY_AMOUNT: "FIX_REWARD_AMOUNT_PER_LIQUIDITY_AMOUNT";
|
103
103
|
}>>;
|
104
104
|
campaignStatus: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TObject<{
|
105
|
-
campaignId: import("@sinclair/typebox").TString;
|
106
105
|
computedUntil: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNumber]>;
|
107
106
|
processingStarted: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TNumber]>;
|
108
107
|
status: import("@sinclair/typebox").TString;
|
@@ -172,7 +171,7 @@ export declare const UpdateMetaDataCampaignDto: import("@sinclair/typebox").TObj
|
|
172
171
|
campaignId: import("@sinclair/typebox").TString;
|
173
172
|
url: import("@sinclair/typebox").TString;
|
174
173
|
}>;
|
175
|
-
export declare const
|
174
|
+
export declare const FindCampaignDto: import("@sinclair/typebox").TObject<{
|
176
175
|
id: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
177
176
|
creatorTag: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
178
177
|
creatorAddress: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
@@ -218,8 +217,11 @@ export type UpdateMetaDataCampaignModel = typeof UpdateMetaDataCampaignDto.stati
|
|
218
217
|
url: string;
|
219
218
|
};
|
220
219
|
export type TransactionModel = typeof TransactionDto.static;
|
221
|
-
export type
|
222
|
-
|
223
|
-
|
224
|
-
|
220
|
+
export type FindCampaignModel = typeof FindCampaignDto.static;
|
221
|
+
export type findCampaignWithStatusModel = Partial<{
|
222
|
+
computeChainId: number;
|
223
|
+
distributionChainId: number;
|
224
|
+
type: string;
|
225
|
+
creatorAddress: string;
|
226
|
+
}>;
|
225
227
|
export type CampaignConfigMinimalModel = typeof CampaignConfigMinimal.static;
|