跳转到主要内容

Documentation Index

Fetch the complete documentation index at: https://injectivelabs-mintlify-jp-developers-first-half-1777019423.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

通过 peggy API 查询链的示例代码片段。

使用 gRPC

获取 peggy 相关参数

import { ChainGrpcPeggyApi } from "@injectivelabs/sdk-ts/client/chain";
import { getNetworkEndpoints, Network } from "@injectivelabs/networks";

const endpoints = getNetworkEndpoints(Network.Testnet);
const chainGrpcPeggyApi = new ChainGrpcPeggyApi(endpoints.grpc);

const moduleParams = await chainGrpcPeggyApi.fetchModuleParams();

console.log(moduleParams);
Last modified on April 24, 2026