Skip to main content
Glama
covalenthq

GoldRush MCP Server

by covalenthq

nft_for_address

Retrieve and display NFT collections held by a wallet address on supported blockchain networks, with options to filter spam and manage metadata fetching.

Instructions

Commonly used to render the NFTs (including ERC721 and ERC1155) held by an address. Required: chainName (blockchain network name), walletAddress (wallet address or ENS/domain). Optional: noSpam (filter spam, default true), noNftAssetMetadata (exclude metadata for faster response, default true), withUncached (fetch uncached metadata, may be slower, default false). Returns complete details of NFTs in the wallet including metadata.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chainNameYesThe blockchain network to query (e.g., 'eth-mainnet', 'matic-mainnet', 'bsc-mainnet').
walletAddressYesThe wallet address to get NFTs for. Can be a wallet address or ENS/domain name.
noSpamNoFilter out spam/scam NFTs from results. Default is true.
noNftAssetMetadataNoSkip fetching NFT asset metadata for faster response. Default is true.
withUncachedNoFetch uncached metadata directly from source (may be slower but more up-to-date). Default is false.

Implementation Reference

  • The "nft_for_address" tool is registered and implemented in src/services/NftService.ts. It uses the Covalent GoldRushClient to fetch NFT data and returns the result as a text content object.
    server.tool(
        "nft_for_address",
        "Commonly used to render the NFTs (including ERC721 and ERC1155) held by an address.\n" +
            "Required: chainName (blockchain network name), walletAddress (wallet address or ENS/domain).\n" +
            "Optional: noSpam (filter spam, default true), noNftAssetMetadata (exclude metadata for faster response, default true), " +
            "withUncached (fetch uncached metadata, may be slower, default false).\n" +
            "Returns complete details of NFTs in the wallet including metadata.",
        {
            chainName: z
                .enum(Object.values(ChainName) as [string, ...string[]])
                .describe(
                    "The blockchain network to query (e.g., 'eth-mainnet', 'matic-mainnet', 'bsc-mainnet')."
                ),
            walletAddress: z
                .string()
                .describe(
                    "The wallet address to get NFTs for. Can be a wallet address or ENS/domain name."
                ),
            noSpam: z
                .boolean()
                .optional()
                .default(true)
                .describe(
                    "Filter out spam/scam NFTs from results. Default is true."
                ),
            noNftAssetMetadata: z
                .boolean()
                .optional()
                .default(true)
                .describe(
                    "Skip fetching NFT asset metadata for faster response. Default is true."
                ),
            withUncached: z
                .boolean()
                .optional()
                .default(false)
                .describe(
                    "Fetch uncached metadata directly from source (may be slower but more up-to-date). Default is false."
                ),
        },
        async (params) => {
            try {
                const response =
                    await goldRushClient.NftService.getNftsForAddress(
                        params.chainName as Chain,
                        params.walletAddress,
                        {
                            noSpam: params.noSpam,
                            noNftAssetMetadata: params.noNftAssetMetadata,
                            withUncached: params.withUncached,
                        }
                    );
                return {
                    content: [
                        {
                            type: "text",
                            text: stringifyWithBigInt(response.data),
                        },
                    ],
                };
            } catch (err) {
                return {
                    content: [{ type: "text", text: `Error: ${err}` }],
                    isError: true,
                };
            }
        }
    );

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/covalenthq/goldrush-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server