diff --git a/apps/api/src/api-docs/swagger.yaml b/apps/api/src/api-docs/swagger.yaml index 1adb6c8..7d1ac75 100644 --- a/apps/api/src/api-docs/swagger.yaml +++ b/apps/api/src/api-docs/swagger.yaml @@ -4,8 +4,8 @@ info: description: Documentation for ZKchainHub API version: 1.0 servers: - - url: http://localhost:3000 - description: Local server + - url: / + description: Server tags: - name: Metrics diff --git a/apps/api/src/metrics/controllers/index.ts b/apps/api/src/metrics/controllers/index.ts index b500a05..469d113 100644 --- a/apps/api/src/metrics/controllers/index.ts +++ b/apps/api/src/metrics/controllers/index.ts @@ -32,13 +32,14 @@ export class MetricsController { }, new BigNumber(0)) .toString(); const chainIdStr = chainId.toString(); + const hasRpc = this.l2MetricsMap.has(chainId); if (!metadata) { return { chainId: chainIdStr, chainType: await this.l1MetricsService.chainType(chainId), baseToken: (await this.l1MetricsService.getBaseTokens([chainId]))[0], tvl, - rpc: false, + rpc: hasRpc, }; } return { @@ -47,7 +48,7 @@ export class MetricsController { baseToken: metadata.baseToken, tvl, metadata: new ZkChainMetadata(metadata), - rpc: false, + rpc: hasRpc, }; }), );