From 552b0da3028057ae9d92b90810c6ea8e0c829a00 Mon Sep 17 00:00:00 2001 From: Yaco 0x Date: Fri, 13 Sep 2024 12:13:10 -0300 Subject: [PATCH] fix: include blockmeta config on agent start --- apps/agent/src/index.ts | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/apps/agent/src/index.ts b/apps/agent/src/index.ts index fbcdf31..d5b9778 100644 --- a/apps/agent/src/index.ts +++ b/apps/agent/src/index.ts @@ -17,6 +17,15 @@ const config = { }, blockNumberService: { chainRpcUrls: new Map([["eip155:1" as const, ["localhost"]]]), + blockmetaConfig: { + baseUrl: new URL("localhost:443"), + servicePaths: { + blockByTime: "/sf.blockmeta.v2.BlockByTime", + block: "/sf.blockmeta.v2.Block", + }, + bearerToken: "secret-token", + bearerTokenExpirationWindow: 365 * 24 * 60 * 60 * 1000, // 1 year + }, }, processor: { msBetweenChecks: 1, @@ -34,6 +43,7 @@ const main = async (): Promise => { const blockNumberService = new BlockNumberService( config.blockNumberService.chainRpcUrls, + config.blockNumberService.blockmetaConfig, logger, );