@merkl/api 0.15.27 → 0.15.29

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.
@@ -2713,6 +2713,10 @@ declare const eden: {
2713
2713
  live: string;
2714
2714
  tree: string;
2715
2715
  lastTree: string;
2716
+ admin: string;
2717
+ adminUrl: string;
2718
+ distributor: string;
2719
+ distributionCreator: string;
2716
2720
  endOfDisputePeriod: number;
2717
2721
  delayed: Awaited<ReturnType<typeof import("../modules/v4/status").StatusService.findManyDelay>>;
2718
2722
  };
@@ -5790,6 +5794,10 @@ declare const eden: {
5790
5794
  live: string;
5791
5795
  tree: string;
5792
5796
  lastTree: string;
5797
+ admin: string;
5798
+ adminUrl: string;
5799
+ distributor: string;
5800
+ distributionCreator: string;
5793
5801
  endOfDisputePeriod: number;
5794
5802
  delayed: Awaited<ReturnType<typeof import("../modules/v4/status").StatusService.findManyDelay>>;
5795
5803
  };
@@ -10196,6 +10204,10 @@ export declare const MerklApi: (domain: string | import("elysia").default<"", fa
10196
10204
  live: string;
10197
10205
  tree: string;
10198
10206
  lastTree: string;
10207
+ admin: string;
10208
+ adminUrl: string;
10209
+ distributor: string;
10210
+ distributionCreator: string;
10199
10211
  endOfDisputePeriod: number;
10200
10212
  delayed: Awaited<ReturnType<typeof import("../modules/v4/status").StatusService.findManyDelay>>;
10201
10213
  };
@@ -14293,6 +14305,10 @@ export declare const MerklApi: (domain: string | import("elysia").default<"", fa
14293
14305
  live: string;
14294
14306
  tree: string;
14295
14307
  lastTree: string;
14308
+ admin: string;
14309
+ adminUrl: string;
14310
+ distributor: string;
14311
+ distributionCreator: string;
14296
14312
  endOfDisputePeriod: number;
14297
14313
  delayed: Awaited<ReturnType<typeof import("../modules/v4/status").StatusService.findManyDelay>>;
14298
14314
  };
@@ -17370,6 +17386,10 @@ export declare const MerklApi: (domain: string | import("elysia").default<"", fa
17370
17386
  live: string;
17371
17387
  tree: string;
17372
17388
  lastTree: string;
17389
+ admin: string;
17390
+ adminUrl: string;
17391
+ distributor: string;
17392
+ distributionCreator: string;
17373
17393
  endOfDisputePeriod: number;
17374
17394
  delayed: Awaited<ReturnType<typeof import("../modules/v4/status").StatusService.findManyDelay>>;
17375
17395
  };
@@ -3344,6 +3344,10 @@ declare const app: Elysia<"", false, {
3344
3344
  live: string;
3345
3345
  tree: string;
3346
3346
  lastTree: string;
3347
+ admin: string;
3348
+ adminUrl: string;
3349
+ distributor: string;
3350
+ distributionCreator: string;
3347
3351
  endOfDisputePeriod: number;
3348
3352
  delayed: Awaited<ReturnType<typeof import("./modules/v4/status").StatusService.findManyDelay>>;
3349
3353
  };
@@ -3214,6 +3214,10 @@ export declare const v4: Elysia<"/v4", false, {
3214
3214
  live: string;
3215
3215
  tree: string;
3216
3216
  lastTree: string;
3217
+ admin: string;
3218
+ adminUrl: string;
3219
+ distributor: string;
3220
+ distributionCreator: string;
3217
3221
  endOfDisputePeriod: number;
3218
3222
  delayed: Awaited<ReturnType<typeof import("./status").StatusService.findManyDelay>>;
3219
3223
  };
@@ -164,6 +164,10 @@ export declare const StatusController: Elysia<"/campaign-status", false, {
164
164
  live: string;
165
165
  tree: string;
166
166
  lastTree: string;
167
+ admin: string;
168
+ adminUrl: string;
169
+ distributor: string;
170
+ distributionCreator: string;
167
171
  endOfDisputePeriod: number;
168
172
  delayed: Awaited<ReturnType<typeof StatusService.findManyDelay>>;
169
173
  };
@@ -39,6 +39,10 @@ export declare class StatusService {
39
39
  live: string;
40
40
  tree: string;
41
41
  lastTree: string;
42
+ admin: string;
43
+ adminUrl: string;
44
+ distributor: string;
45
+ distributionCreator: string;
42
46
  endOfDisputePeriod: number;
43
47
  delayed: Awaited<ReturnType<typeof StatusService.findManyDelay>>;
44
48
  }>>;
@@ -1,5 +1,5 @@
1
1
  import { RunStatus } from "../../../../database/api/.generated";
2
- import { HOUR, MAX_COMPUTE_JOB_TIME } from "@sdk";
2
+ import { HOUR, MAX_COMPUTE_JOB_TIME, getMultisigURL, registry } from "@sdk";
3
3
  import moment from "moment";
4
4
  import { CampaignService } from "../campaign";
5
5
  import { MerklRootService } from "../merklRoot";
@@ -59,12 +59,16 @@ export class StatusService {
59
59
  const merklRoots = await MerklRootService.fetchAll();
60
60
  const delayedCampaignPromises = await Promise.allSettled(Object.keys(merklRoots).map(chainId => StatusService.findManyDelay({ chainId: Number.parseInt(chainId), delayLowerBound: 4 * HOUR })));
61
61
  const res = {};
62
- for (const [index, chainId] of Object.keys(merklRoots).entries()) {
63
- if (delayedCampaignPromises[index].status === "rejected")
64
- continue;
65
- res[Number.parseInt(chainId)] = {
66
- ...merklRoots[Number.parseInt(chainId)],
67
- delayed: delayedCampaignPromises[index].value,
62
+ for (const [index, chainIdString] of Object.keys(merklRoots).entries()) {
63
+ const chainId = Number.parseInt(chainIdString);
64
+ const delayedCampaigns = delayedCampaignPromises[index].status === "rejected" ? [] : delayedCampaignPromises[index].value;
65
+ res[chainId] = {
66
+ ...merklRoots[chainId],
67
+ admin: registry(chainId)?.AngleLabs,
68
+ adminUrl: getMultisigURL(chainId, registry(chainId)?.AngleLabs),
69
+ distributor: registry(chainId)?.Merkl?.Distributor,
70
+ distributionCreator: registry(chainId)?.Merkl?.Disputer,
71
+ delayed: delayedCampaigns,
68
72
  };
69
73
  }
70
74
  return res;