/** * Neynar API * The Neynar API allows you to interact with the Farcaster protocol among other things. See the [Neynar docs](https://docs.neynar.com/reference) for more details. * * The version of the OpenAPI document: 3.137.0 * Contact: team@neynar.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import type { Configuration } from '../configuration'; import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios'; import { type RequestArgs, BaseAPI } from '../base'; import type { BalanceResponse } from '../models'; import type { BatchGetTokenMetadata200Response } from '../models'; import type { CreateX402Signature200Response } from '../models'; import type { CreateX402SignatureRequest } from '../models'; import type { DeployErc721201Response } from '../models'; import type { DeployErc721Request } from '../models'; import type { DeployFungibleResponse } from '../models'; import type { FetchFungibleTrades200Response } from '../models'; import type { FetchTrendingFungibles200Response } from '../models'; import type { FungiblesResponseSchema } from '../models'; import type { GetTokenMetadata200Response } from '../models'; import type { GetWalletBalances200Response } from '../models'; import type { MintNft200Response } from '../models'; import type { MintNftRequest } from '../models'; import type { RegisterUserOnChainReqBody } from '../models'; import type { RegisterUserOnChainResponse } from '../models'; import type { RelevantFungibleOwnersResponse } from '../models'; import type { SimulateNftMintResponse } from '../models'; import type { TransactionSendFungiblesReqBody } from '../models'; import type { TransactionSendFungiblesResponse } from '../models'; /** * OnchainApi - axios parameter creator * @export */ export declare const OnchainApiAxiosParamCreator: (configuration?: Configuration) => { /** * Fetch metadata for multiple tokens in a single request. Provide comma-separated networks and addresses in the same order. Maximum 100 tokens per request. * @summary Batch get token metadata * @param {string} networks Comma-separated list of blockchain networks. Each value must be a valid network (ethereum, optimism, base, arbitrum). * @param {string} addresses Comma-separated list of token contract addresses corresponding to each network * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BatchGetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/batch-get-token-metadata) * */ batchGetTokenMetadata: (networks: string, addresses: string, options?: RawAxiosRequestConfig) => Promise; /** * Create a signature for a given x402 resource using the specified wallet. * @summary Create x402 signature * @param {string} xWalletId Wallet ID to use for transactions * @param {string} xApiKey * @param {CreateX402SignatureRequest} createX402SignatureRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `CreateX402Signature200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/create-x402-signature) * */ createX402Signature: (xWalletId: string, xApiKey: string, createX402SignatureRequest: CreateX402SignatureRequest, options?: RawAxiosRequestConfig) => Promise; /** * Deploy a new ERC-721A (series) NFT collection. * @summary Deploy ERC-721 collection * @param {string} xWalletId Wallet ID to use for transactions * @param {DeployErc721Request} deployErc721Request * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployErc721201Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-erc721) * */ deployErc721: (xWalletId: string, deployErc721Request: DeployErc721Request, options?: RawAxiosRequestConfig) => Promise; /** * Creates a new token. This is an allowlisted API, reach out if you want access. * @summary Deploy fungible * @param {string} owner Ethereum address of the one who is creating the token * @param {string} symbol Symbol/Ticker for the token * @param {string} name Name of the token * @param {File | null} [metadataMedia] Media file associated with the token. Supported formats are image/jpeg, image/gif and image/png * @param {string} [metadataDescription] Description of the token * @param {DeployFungibleMetadataNsfwEnum} [metadataNsfw] Indicates if the token is NSFW (Not Safe For Work). * @param {string} [metadataWebsiteLink] Website link related to the token * @param {string} [metadataTwitter] Twitter profile link * @param {string} [metadataDiscord] Discord server link * @param {string} [metadataTelegram] Telegram link * @param {DeployFungibleNetworkEnum} [network] Network/Chain name * @param {DeployFungibleFactoryEnum} [factory] Factory name - wow -> [wow.xyz](https://wow.xyz) - clanker -> [clanker.world](https://www.clanker.world) * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployFungibleResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-fungible) * */ deployFungible: (owner: string, symbol: string, name: string, metadataMedia?: File | null, metadataDescription?: string, metadataNsfw?: DeployFungibleMetadataNsfwEnum, metadataWebsiteLink?: string, metadataTwitter?: string, metadataDiscord?: string, metadataTelegram?: string, network?: DeployFungibleNetworkEnum, factory?: DeployFungibleFactoryEnum, options?: RawAxiosRequestConfig) => Promise; /** * Get recent trades for a specific fungible within a timeframe. Returns trades ordered by timestamp (most recent first). * @summary Get fungible trades * @param {FetchFungibleTradesNetworkEnum} network * @param {string} address Contract address * @param {FetchFungibleTradesTimeWindowEnum} [timeWindow] Time window for trades e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * @param {number | null} [minAmountUsd] Minimum USD amount to filter trades * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchFungibleTrades200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungible-trades) * */ fetchFungibleTrades: (network: FetchFungibleTradesNetworkEnum, address: string, timeWindow?: FetchFungibleTradesTimeWindowEnum, minAmountUsd?: number | null, options?: RawAxiosRequestConfig) => Promise; /** * Fetch details for fungible assets identified by fungible identifiers. * @summary Fetch fungibles * @param {string} fungibles Comma-separated fungible identifiers * @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details. * @param {number | null} [viewerFid] Optional FID of the viewer to personalize cast count filtering * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FungiblesResponseSchema` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungibles) * */ fetchFungibles: (fungibles: string, xNeynarExperimental?: boolean, viewerFid?: number | null, options?: RawAxiosRequestConfig) => Promise; /** * Fetch a list of relevant owners for a on chain asset. If a viewer is provided, only relevant holders will be shown. This usually shows on a fungible asset page as \"X, Y, Z and N others you know own this asset\". * @summary Relevant owners * @param {string} contractAddress Contract address of the fungible asset (Ethereum or Solana) * @param {FetchRelevantFungibleOwnersNetworkEnum} network Network of the fungible asset. * @param {number} [viewerFid] If you provide a viewer_fid, the response will include token holders from the user\'s network, respecting their mutes and blocks and including viewer_context; if not provided, the response will show top token holders across the network—both sets can be combined to generate a longer list if desired. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RelevantFungibleOwnersResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-fungible-owners) * */ fetchRelevantFungibleOwners: (contractAddress: string, network: FetchRelevantFungibleOwnersNetworkEnum, viewerFid?: number, options?: RawAxiosRequestConfig) => Promise; /** * Fetch trending fungibles based on buy activity from watched addresses. Returns fungibles ranked by USD buy volume and buy count within the specified time window. * @summary Trending fungibles * @param {FetchTrendingFungiblesNetworkEnum} network * @param {FetchTrendingFungiblesTimeWindowEnum} [timeWindow] Time window for trending calculations e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchTrendingFungibles200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-fungibles) * */ fetchTrendingFungibles: (network: FetchTrendingFungiblesNetworkEnum, timeWindow?: FetchTrendingFungiblesTimeWindowEnum, options?: RawAxiosRequestConfig) => Promise; /** * Fetches the token balances of a user given their FID * @summary Token balance * @param {number} fid FID of the user to fetch * @param {Array} networks Comma separated list of networks to fetch balances for * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BalanceResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-balance) * */ fetchUserBalance: (fid: number, networks: Array, options?: RawAxiosRequestConfig) => Promise; /** * Fetch metadata for a specific token including price, market data, and basic information. Data is fetched from onchain-indexer with fallback to third-party providers. * @summary Get token metadata * @param {GetTokenMetadataNetworkEnum} network A blockchain network e.g. \"ethereum\", \"optimism\", \"base\", \"arbitrum\" * @param {string} address Ethereum address * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-token-metadata) * */ getTokenMetadata: (network: GetTokenMetadataNetworkEnum, address: string, options?: RawAxiosRequestConfig) => Promise; /** * Fetch all token balances for a wallet address across multiple networks. Results are paginated. * @summary Get wallet token balances * @param {string} networks Comma-separated list of networks to query. Each value must be a valid network (ethereum, optimism, base, arbitrum). * @param {string} address Ethereum address * @param {number} [limit] Number of results to return (max 100) (Default: 50, Maximum: 100) * @param {string} [cursor] Pagination cursor. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetWalletBalances200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-wallet-balances) * */ getWalletBalances: (networks: string, address: string, limit?: number, cursor?: string, options?: RawAxiosRequestConfig) => Promise; /** * Mints an NFT to one or more recipients on a specified network and contract, using a configured server wallet. Contact us to set up your wallet configuration if you don\'t have one. * @summary Mint NFT(s) * @param {string} xWalletId Wallet ID to use for transactions * @param {MintNftRequest} mintNftRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `MintNft200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/mint-nft) * */ mintNft: (xWalletId: string, mintNftRequest: MintNftRequest, options?: RawAxiosRequestConfig) => Promise; /** * Register a new farcaster account onchain. Optionally you can pass in signers to register a new account and create multiple signers in a single transaction. Requires x-wallet-id header. * @summary Register Farcaster account onchain * @param {string} xWalletId Wallet ID to use for transactions * @param {RegisterUserOnChainReqBody} registerUserOnChainReqBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RegisterUserOnChainResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/register-account-onchain) * */ registerAccountOnchain: (xWalletId: string, registerUserOnChainReqBody: RegisterUserOnChainReqBody, options?: RawAxiosRequestConfig) => Promise; /** * Send fungibles in bulk to several farcaster users. A funded wallet is to required use this API. React out to us on the Neynar channel on farcaster to get your wallet address. * @summary Send fungibles * @param {string} xWalletId Wallet ID to use for transactions * @param {TransactionSendFungiblesReqBody} transactionSendFungiblesReqBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `TransactionSendFungiblesResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/send-fungibles-to-users) * */ sendFungiblesToUsers: (xWalletId: string, transactionSendFungiblesReqBody: TransactionSendFungiblesReqBody, options?: RawAxiosRequestConfig) => Promise; /** * Simulates mint calldata for the given recipients, contract, and network. Useful for previewing calldata and ABI before minting. * @summary Simulate NFT mint calldata * @param {string} recipients JSON array of recipients (same structure as POST). * @param {string} nftContractAddress Ethereum address * @param {SimulateNftMintNetworkEnum} network Network to mint on. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `SimulateNftMintResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/simulate-nft-mint) * */ simulateNftMint: (recipients: string, nftContractAddress: string, network: SimulateNftMintNetworkEnum, options?: RawAxiosRequestConfig) => Promise; }; /** * OnchainApi - functional programming interface * @export */ export declare const OnchainApiFp: (configuration?: Configuration) => { /** * Fetch metadata for multiple tokens in a single request. Provide comma-separated networks and addresses in the same order. Maximum 100 tokens per request. * @summary Batch get token metadata * @param {string} networks Comma-separated list of blockchain networks. Each value must be a valid network (ethereum, optimism, base, arbitrum). * @param {string} addresses Comma-separated list of token contract addresses corresponding to each network * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BatchGetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/batch-get-token-metadata) * */ batchGetTokenMetadata(networks: string, addresses: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Create a signature for a given x402 resource using the specified wallet. * @summary Create x402 signature * @param {string} xWalletId Wallet ID to use for transactions * @param {string} xApiKey * @param {CreateX402SignatureRequest} createX402SignatureRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `CreateX402Signature200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/create-x402-signature) * */ createX402Signature(xWalletId: string, xApiKey: string, createX402SignatureRequest: CreateX402SignatureRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Deploy a new ERC-721A (series) NFT collection. * @summary Deploy ERC-721 collection * @param {string} xWalletId Wallet ID to use for transactions * @param {DeployErc721Request} deployErc721Request * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployErc721201Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-erc721) * */ deployErc721(xWalletId: string, deployErc721Request: DeployErc721Request, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Creates a new token. This is an allowlisted API, reach out if you want access. * @summary Deploy fungible * @param {string} owner Ethereum address of the one who is creating the token * @param {string} symbol Symbol/Ticker for the token * @param {string} name Name of the token * @param {File | null} [metadataMedia] Media file associated with the token. Supported formats are image/jpeg, image/gif and image/png * @param {string} [metadataDescription] Description of the token * @param {DeployFungibleMetadataNsfwEnum} [metadataNsfw] Indicates if the token is NSFW (Not Safe For Work). * @param {string} [metadataWebsiteLink] Website link related to the token * @param {string} [metadataTwitter] Twitter profile link * @param {string} [metadataDiscord] Discord server link * @param {string} [metadataTelegram] Telegram link * @param {DeployFungibleNetworkEnum} [network] Network/Chain name * @param {DeployFungibleFactoryEnum} [factory] Factory name - wow -> [wow.xyz](https://wow.xyz) - clanker -> [clanker.world](https://www.clanker.world) * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployFungibleResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-fungible) * */ deployFungible(owner: string, symbol: string, name: string, metadataMedia?: File | null, metadataDescription?: string, metadataNsfw?: DeployFungibleMetadataNsfwEnum, metadataWebsiteLink?: string, metadataTwitter?: string, metadataDiscord?: string, metadataTelegram?: string, network?: DeployFungibleNetworkEnum, factory?: DeployFungibleFactoryEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Get recent trades for a specific fungible within a timeframe. Returns trades ordered by timestamp (most recent first). * @summary Get fungible trades * @param {FetchFungibleTradesNetworkEnum} network * @param {string} address Contract address * @param {FetchFungibleTradesTimeWindowEnum} [timeWindow] Time window for trades e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * @param {number | null} [minAmountUsd] Minimum USD amount to filter trades * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchFungibleTrades200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungible-trades) * */ fetchFungibleTrades(network: FetchFungibleTradesNetworkEnum, address: string, timeWindow?: FetchFungibleTradesTimeWindowEnum, minAmountUsd?: number | null, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetch details for fungible assets identified by fungible identifiers. * @summary Fetch fungibles * @param {string} fungibles Comma-separated fungible identifiers * @param {boolean} [xNeynarExperimental] Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details. * @param {number | null} [viewerFid] Optional FID of the viewer to personalize cast count filtering * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FungiblesResponseSchema` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungibles) * */ fetchFungibles(fungibles: string, xNeynarExperimental?: boolean, viewerFid?: number | null, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetch a list of relevant owners for a on chain asset. If a viewer is provided, only relevant holders will be shown. This usually shows on a fungible asset page as \"X, Y, Z and N others you know own this asset\". * @summary Relevant owners * @param {string} contractAddress Contract address of the fungible asset (Ethereum or Solana) * @param {FetchRelevantFungibleOwnersNetworkEnum} network Network of the fungible asset. * @param {number} [viewerFid] If you provide a viewer_fid, the response will include token holders from the user\'s network, respecting their mutes and blocks and including viewer_context; if not provided, the response will show top token holders across the network—both sets can be combined to generate a longer list if desired. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RelevantFungibleOwnersResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-fungible-owners) * */ fetchRelevantFungibleOwners(contractAddress: string, network: FetchRelevantFungibleOwnersNetworkEnum, viewerFid?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetch trending fungibles based on buy activity from watched addresses. Returns fungibles ranked by USD buy volume and buy count within the specified time window. * @summary Trending fungibles * @param {FetchTrendingFungiblesNetworkEnum} network * @param {FetchTrendingFungiblesTimeWindowEnum} [timeWindow] Time window for trending calculations e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchTrendingFungibles200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-fungibles) * */ fetchTrendingFungibles(network: FetchTrendingFungiblesNetworkEnum, timeWindow?: FetchTrendingFungiblesTimeWindowEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetches the token balances of a user given their FID * @summary Token balance * @param {number} fid FID of the user to fetch * @param {Array} networks Comma separated list of networks to fetch balances for * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BalanceResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-balance) * */ fetchUserBalance(fid: number, networks: Array, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetch metadata for a specific token including price, market data, and basic information. Data is fetched from onchain-indexer with fallback to third-party providers. * @summary Get token metadata * @param {GetTokenMetadataNetworkEnum} network A blockchain network e.g. \"ethereum\", \"optimism\", \"base\", \"arbitrum\" * @param {string} address Ethereum address * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-token-metadata) * */ getTokenMetadata(network: GetTokenMetadataNetworkEnum, address: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Fetch all token balances for a wallet address across multiple networks. Results are paginated. * @summary Get wallet token balances * @param {string} networks Comma-separated list of networks to query. Each value must be a valid network (ethereum, optimism, base, arbitrum). * @param {string} address Ethereum address * @param {number} [limit] Number of results to return (max 100) (Default: 50, Maximum: 100) * @param {string} [cursor] Pagination cursor. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetWalletBalances200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-wallet-balances) * */ getWalletBalances(networks: string, address: string, limit?: number, cursor?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Mints an NFT to one or more recipients on a specified network and contract, using a configured server wallet. Contact us to set up your wallet configuration if you don\'t have one. * @summary Mint NFT(s) * @param {string} xWalletId Wallet ID to use for transactions * @param {MintNftRequest} mintNftRequest * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `MintNft200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/mint-nft) * */ mintNft(xWalletId: string, mintNftRequest: MintNftRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Register a new farcaster account onchain. Optionally you can pass in signers to register a new account and create multiple signers in a single transaction. Requires x-wallet-id header. * @summary Register Farcaster account onchain * @param {string} xWalletId Wallet ID to use for transactions * @param {RegisterUserOnChainReqBody} registerUserOnChainReqBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RegisterUserOnChainResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/register-account-onchain) * */ registerAccountOnchain(xWalletId: string, registerUserOnChainReqBody: RegisterUserOnChainReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Send fungibles in bulk to several farcaster users. A funded wallet is to required use this API. React out to us on the Neynar channel on farcaster to get your wallet address. * @summary Send fungibles * @param {string} xWalletId Wallet ID to use for transactions * @param {TransactionSendFungiblesReqBody} transactionSendFungiblesReqBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `TransactionSendFungiblesResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/send-fungibles-to-users) * */ sendFungiblesToUsers(xWalletId: string, transactionSendFungiblesReqBody: TransactionSendFungiblesReqBody, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; /** * Simulates mint calldata for the given recipients, contract, and network. Useful for previewing calldata and ABI before minting. * @summary Simulate NFT mint calldata * @param {string} recipients JSON array of recipients (same structure as POST). * @param {string} nftContractAddress Ethereum address * @param {SimulateNftMintNetworkEnum} network Network to mint on. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `SimulateNftMintResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/simulate-nft-mint) * */ simulateNftMint(recipients: string, nftContractAddress: string, network: SimulateNftMintNetworkEnum, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>; }; /** * OnchainApi - factory interface * @export */ export declare const OnchainApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => { /** * Fetch metadata for multiple tokens in a single request. Provide comma-separated networks and addresses in the same order. Maximum 100 tokens per request. * @summary Batch get token metadata * @param {OnchainApiBatchGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BatchGetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/batch-get-token-metadata) * */ batchGetTokenMetadata(requestParameters: OnchainApiBatchGetTokenMetadataRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Create a signature for a given x402 resource using the specified wallet. * @summary Create x402 signature * @param {OnchainApiCreateX402SignatureRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `CreateX402Signature200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/create-x402-signature) * */ createX402Signature(requestParameters: OnchainApiCreateX402SignatureRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Deploy a new ERC-721A (series) NFT collection. * @summary Deploy ERC-721 collection * @param {OnchainApiDeployErc721Request} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployErc721201Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-erc721) * */ deployErc721(requestParameters: OnchainApiDeployErc721Request, options?: RawAxiosRequestConfig): AxiosPromise; /** * Creates a new token. This is an allowlisted API, reach out if you want access. * @summary Deploy fungible * @param {OnchainApiDeployFungibleRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `DeployFungibleResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-fungible) * */ deployFungible(requestParameters: OnchainApiDeployFungibleRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Get recent trades for a specific fungible within a timeframe. Returns trades ordered by timestamp (most recent first). * @summary Get fungible trades * @param {OnchainApiFetchFungibleTradesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchFungibleTrades200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungible-trades) * */ fetchFungibleTrades(requestParameters: OnchainApiFetchFungibleTradesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch details for fungible assets identified by fungible identifiers. * @summary Fetch fungibles * @param {OnchainApiFetchFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FungiblesResponseSchema` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungibles) * */ fetchFungibles(requestParameters: OnchainApiFetchFungiblesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch a list of relevant owners for a on chain asset. If a viewer is provided, only relevant holders will be shown. This usually shows on a fungible asset page as \"X, Y, Z and N others you know own this asset\". * @summary Relevant owners * @param {OnchainApiFetchRelevantFungibleOwnersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RelevantFungibleOwnersResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-fungible-owners) * */ fetchRelevantFungibleOwners(requestParameters: OnchainApiFetchRelevantFungibleOwnersRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch trending fungibles based on buy activity from watched addresses. Returns fungibles ranked by USD buy volume and buy count within the specified time window. * @summary Trending fungibles * @param {OnchainApiFetchTrendingFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `FetchTrendingFungibles200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-fungibles) * */ fetchTrendingFungibles(requestParameters: OnchainApiFetchTrendingFungiblesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetches the token balances of a user given their FID * @summary Token balance * @param {OnchainApiFetchUserBalanceRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `BalanceResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-balance) * */ fetchUserBalance(requestParameters: OnchainApiFetchUserBalanceRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch metadata for a specific token including price, market data, and basic information. Data is fetched from onchain-indexer with fallback to third-party providers. * @summary Get token metadata * @param {OnchainApiGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-token-metadata) * */ getTokenMetadata(requestParameters: OnchainApiGetTokenMetadataRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch all token balances for a wallet address across multiple networks. Results are paginated. * @summary Get wallet token balances * @param {OnchainApiGetWalletBalancesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `GetWalletBalances200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-wallet-balances) * */ getWalletBalances(requestParameters: OnchainApiGetWalletBalancesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Mints an NFT to one or more recipients on a specified network and contract, using a configured server wallet. Contact us to set up your wallet configuration if you don\'t have one. * @summary Mint NFT(s) * @param {OnchainApiMintNftRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `MintNft200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/mint-nft) * */ mintNft(requestParameters: OnchainApiMintNftRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Register a new farcaster account onchain. Optionally you can pass in signers to register a new account and create multiple signers in a single transaction. Requires x-wallet-id header. * @summary Register Farcaster account onchain * @param {OnchainApiRegisterAccountOnchainRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `RegisterUserOnChainResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/register-account-onchain) * */ registerAccountOnchain(requestParameters: OnchainApiRegisterAccountOnchainRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Send fungibles in bulk to several farcaster users. A funded wallet is to required use this API. React out to us on the Neynar channel on farcaster to get your wallet address. * @summary Send fungibles * @param {OnchainApiSendFungiblesToUsersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `TransactionSendFungiblesResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/send-fungibles-to-users) * */ sendFungiblesToUsers(requestParameters: OnchainApiSendFungiblesToUsersRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Simulates mint calldata for the given recipients, contract, and network. Useful for previewing calldata and ABI before minting. * @summary Simulate NFT mint calldata * @param {OnchainApiSimulateNftMintRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @returns {Promise} A promise that resolves to a `SimulateNftMintResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/simulate-nft-mint) * */ simulateNftMint(requestParameters: OnchainApiSimulateNftMintRequest, options?: RawAxiosRequestConfig): AxiosPromise; }; /** * OnchainApi - interface * @export * @interface OnchainApi */ export interface OnchainApiInterface { /** * Fetch metadata for multiple tokens in a single request. Provide comma-separated networks and addresses in the same order. Maximum 100 tokens per request. * @summary Batch get token metadata * @param {OnchainApiBatchGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `BatchGetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/batch-get-token-metadata) * */ batchGetTokenMetadata(requestParameters: OnchainApiBatchGetTokenMetadataRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Create a signature for a given x402 resource using the specified wallet. * @summary Create x402 signature * @param {OnchainApiCreateX402SignatureRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `CreateX402Signature200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/create-x402-signature) * */ createX402Signature(requestParameters: OnchainApiCreateX402SignatureRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Deploy a new ERC-721A (series) NFT collection. * @summary Deploy ERC-721 collection * @param {OnchainApiDeployErc721Request} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `DeployErc721201Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-erc721) * */ deployErc721(requestParameters: OnchainApiDeployErc721Request, options?: RawAxiosRequestConfig): AxiosPromise; /** * Creates a new token. This is an allowlisted API, reach out if you want access. * @summary Deploy fungible * @param {OnchainApiDeployFungibleRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `DeployFungibleResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-fungible) * */ deployFungible(requestParameters: OnchainApiDeployFungibleRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Get recent trades for a specific fungible within a timeframe. Returns trades ordered by timestamp (most recent first). * @summary Get fungible trades * @param {OnchainApiFetchFungibleTradesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `FetchFungibleTrades200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungible-trades) * */ fetchFungibleTrades(requestParameters: OnchainApiFetchFungibleTradesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch details for fungible assets identified by fungible identifiers. * @summary Fetch fungibles * @param {OnchainApiFetchFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `FungiblesResponseSchema` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungibles) * */ fetchFungibles(requestParameters: OnchainApiFetchFungiblesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch a list of relevant owners for a on chain asset. If a viewer is provided, only relevant holders will be shown. This usually shows on a fungible asset page as \"X, Y, Z and N others you know own this asset\". * @summary Relevant owners * @param {OnchainApiFetchRelevantFungibleOwnersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `RelevantFungibleOwnersResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-fungible-owners) * */ fetchRelevantFungibleOwners(requestParameters: OnchainApiFetchRelevantFungibleOwnersRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch trending fungibles based on buy activity from watched addresses. Returns fungibles ranked by USD buy volume and buy count within the specified time window. * @summary Trending fungibles * @param {OnchainApiFetchTrendingFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `FetchTrendingFungibles200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-fungibles) * */ fetchTrendingFungibles(requestParameters: OnchainApiFetchTrendingFungiblesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetches the token balances of a user given their FID * @summary Token balance * @param {OnchainApiFetchUserBalanceRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `BalanceResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-balance) * */ fetchUserBalance(requestParameters: OnchainApiFetchUserBalanceRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch metadata for a specific token including price, market data, and basic information. Data is fetched from onchain-indexer with fallback to third-party providers. * @summary Get token metadata * @param {OnchainApiGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `GetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-token-metadata) * */ getTokenMetadata(requestParameters: OnchainApiGetTokenMetadataRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Fetch all token balances for a wallet address across multiple networks. Results are paginated. * @summary Get wallet token balances * @param {OnchainApiGetWalletBalancesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `GetWalletBalances200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-wallet-balances) * */ getWalletBalances(requestParameters: OnchainApiGetWalletBalancesRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Mints an NFT to one or more recipients on a specified network and contract, using a configured server wallet. Contact us to set up your wallet configuration if you don\'t have one. * @summary Mint NFT(s) * @param {OnchainApiMintNftRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `MintNft200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/mint-nft) * */ mintNft(requestParameters: OnchainApiMintNftRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Register a new farcaster account onchain. Optionally you can pass in signers to register a new account and create multiple signers in a single transaction. Requires x-wallet-id header. * @summary Register Farcaster account onchain * @param {OnchainApiRegisterAccountOnchainRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `RegisterUserOnChainResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/register-account-onchain) * */ registerAccountOnchain(requestParameters: OnchainApiRegisterAccountOnchainRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Send fungibles in bulk to several farcaster users. A funded wallet is to required use this API. React out to us on the Neynar channel on farcaster to get your wallet address. * @summary Send fungibles * @param {OnchainApiSendFungiblesToUsersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `TransactionSendFungiblesResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/send-fungibles-to-users) * */ sendFungiblesToUsers(requestParameters: OnchainApiSendFungiblesToUsersRequest, options?: RawAxiosRequestConfig): AxiosPromise; /** * Simulates mint calldata for the given recipients, contract, and network. Useful for previewing calldata and ABI before minting. * @summary Simulate NFT mint calldata * @param {OnchainApiSimulateNftMintRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApiInterface * @returns {Promise} A promise that resolves to a `SimulateNftMintResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/simulate-nft-mint) * */ simulateNftMint(requestParameters: OnchainApiSimulateNftMintRequest, options?: RawAxiosRequestConfig): AxiosPromise; } /** * Request parameters for batchGetTokenMetadata operation in OnchainApi. * @export * @interface OnchainApiBatchGetTokenMetadataRequest */ export interface OnchainApiBatchGetTokenMetadataRequest { /** * Comma-separated list of blockchain networks. Each value must be a valid network (ethereum, optimism, base, arbitrum). * * @commaSeparated * * @type {string} * @memberof OnchainApiBatchGetTokenMetadata */ readonly networks: string; /** * Comma-separated list of token contract addresses corresponding to each network * * @commaSeparated * * @type {string} * @memberof OnchainApiBatchGetTokenMetadata */ readonly addresses: string; } /** * Request parameters for createX402Signature operation in OnchainApi. * @export * @interface OnchainApiCreateX402SignatureRequest */ export interface OnchainApiCreateX402SignatureRequest { /** * Wallet ID to use for transactions * * * @globalHeader * @type {string} * @memberof OnchainApiCreateX402Signature */ readonly xWalletId: string; /** * * * * * @type {string} * @memberof OnchainApiCreateX402Signature */ readonly xApiKey: string; /** * * * * * @type {CreateX402SignatureRequest} * @memberof OnchainApiCreateX402Signature */ readonly createX402SignatureRequest: CreateX402SignatureRequest; } /** * Request parameters for deployErc721 operation in OnchainApi. * @export * @interface OnchainApiDeployErc721Request */ export interface OnchainApiDeployErc721Request { /** * Wallet ID to use for transactions * * * @globalHeader * @type {string} * @memberof OnchainApiDeployErc721 */ readonly xWalletId: string; /** * * * * * @type {DeployErc721Request} * @memberof OnchainApiDeployErc721 */ readonly deployErc721Request: DeployErc721Request; } /** * Request parameters for deployFungible operation in OnchainApi. * @export * @interface OnchainApiDeployFungibleRequest */ export interface OnchainApiDeployFungibleRequest { /** * Ethereum address of the one who is creating the token * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly owner: string; /** * Symbol/Ticker for the token * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly symbol: string; /** * Name of the token * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly name: string; /** * Media file associated with the token. Supported formats are image/jpeg, image/gif and image/png * * * * @type {File} * @memberof OnchainApiDeployFungible */ readonly metadataMedia?: File | null; /** * Description of the token * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataDescription?: string; /** * Indicates if the token is NSFW (Not Safe For Work). * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataNsfw?: DeployFungibleMetadataNsfwEnum; /** * Website link related to the token * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataWebsiteLink?: string; /** * Twitter profile link * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataTwitter?: string; /** * Discord server link * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataDiscord?: string; /** * Telegram link * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly metadataTelegram?: string; /** * Network/Chain name * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly network?: DeployFungibleNetworkEnum; /** * Factory name - wow -> [wow.xyz](https://wow.xyz) - clanker -> [clanker.world](https://www.clanker.world) * * * * @type {string} * @memberof OnchainApiDeployFungible */ readonly factory?: DeployFungibleFactoryEnum; } /** * Request parameters for fetchFungibleTrades operation in OnchainApi. * @export * @interface OnchainApiFetchFungibleTradesRequest */ export interface OnchainApiFetchFungibleTradesRequest { /** * * * * * @type {'base'} * @memberof OnchainApiFetchFungibleTrades */ readonly network: FetchFungibleTradesNetworkEnum; /** * Contract address * * * * @type {string} * @memberof OnchainApiFetchFungibleTrades */ readonly address: string; /** * Time window for trades e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * * * * @type {'1h' | '6h' | '12h' | '24h' | '7d'} * @memberof OnchainApiFetchFungibleTrades */ readonly timeWindow?: FetchFungibleTradesTimeWindowEnum; /** * Minimum USD amount to filter trades * * * * @type {number} * @memberof OnchainApiFetchFungibleTrades */ readonly minAmountUsd?: number | null; } /** * Request parameters for fetchFungibles operation in OnchainApi. * @export * @interface OnchainApiFetchFungiblesRequest */ export interface OnchainApiFetchFungiblesRequest { /** * Comma-separated fungible identifiers * * * * @type {string} * @memberof OnchainApiFetchFungibles */ readonly fungibles: string; /** * Enables experimental features including filtering based on the Neynar score. See [docs](https://neynar.notion.site/Experimental-Features-1d2655195a8b80eb98b4d4ae7b76ae4a) for more details. * * * @globalHeader * @type {boolean} * @memberof OnchainApiFetchFungibles */ readonly xNeynarExperimental?: boolean; /** * Optional FID of the viewer to personalize cast count filtering * * * * @type {number} * @memberof OnchainApiFetchFungibles */ readonly viewerFid?: number | null; } /** * Request parameters for fetchRelevantFungibleOwners operation in OnchainApi. * @export * @interface OnchainApiFetchRelevantFungibleOwnersRequest */ export interface OnchainApiFetchRelevantFungibleOwnersRequest { /** * Contract address of the fungible asset (Ethereum or Solana) * * * * @type {string} * @memberof OnchainApiFetchRelevantFungibleOwners */ readonly contractAddress: string; /** * Network of the fungible asset. * * * * @type {'ethereum' | 'optimism' | 'base' | 'arbitrum' | 'solana'} * @memberof OnchainApiFetchRelevantFungibleOwners */ readonly network: FetchRelevantFungibleOwnersNetworkEnum; /** * If you provide a viewer_fid, the response will include token holders from the user\'s network, respecting their mutes and blocks and including viewer_context; if not provided, the response will show top token holders across the network—both sets can be combined to generate a longer list if desired. * * * * @type {number} * @memberof OnchainApiFetchRelevantFungibleOwners */ readonly viewerFid?: number; } /** * Request parameters for fetchTrendingFungibles operation in OnchainApi. * @export * @interface OnchainApiFetchTrendingFungiblesRequest */ export interface OnchainApiFetchTrendingFungiblesRequest { /** * * * * * @type {'base'} * @memberof OnchainApiFetchTrendingFungibles */ readonly network: FetchTrendingFungiblesNetworkEnum; /** * Time window for trending calculations e.g. \"1h\", \"6h\", \"12h\", \"24h\", \"7d\" * * * * @type {'1h' | '6h' | '12h' | '24h' | '7d'} * @memberof OnchainApiFetchTrendingFungibles */ readonly timeWindow?: FetchTrendingFungiblesTimeWindowEnum; } /** * Request parameters for fetchUserBalance operation in OnchainApi. * @export * @interface OnchainApiFetchUserBalanceRequest */ export interface OnchainApiFetchUserBalanceRequest { /** * FID of the user to fetch * * * * @type {number} * @memberof OnchainApiFetchUserBalance */ readonly fid: number; /** * Comma separated list of networks to fetch balances for * * * * @type {Array<'ethereum' | 'optimism' | 'base' | 'arbitrum'>} * @memberof OnchainApiFetchUserBalance */ readonly networks: Array; } /** * Request parameters for getTokenMetadata operation in OnchainApi. * @export * @interface OnchainApiGetTokenMetadataRequest */ export interface OnchainApiGetTokenMetadataRequest { /** * A blockchain network e.g. \"ethereum\", \"optimism\", \"base\", \"arbitrum\" * * * * @type {'ethereum' | 'optimism' | 'base' | 'arbitrum'} * @memberof OnchainApiGetTokenMetadata */ readonly network: GetTokenMetadataNetworkEnum; /** * Ethereum address * * * * @type {string} * @memberof OnchainApiGetTokenMetadata */ readonly address: string; } /** * Request parameters for getWalletBalances operation in OnchainApi. * @export * @interface OnchainApiGetWalletBalancesRequest */ export interface OnchainApiGetWalletBalancesRequest { /** * Comma-separated list of networks to query. Each value must be a valid network (ethereum, optimism, base, arbitrum). * * @commaSeparated * * @type {string} * @memberof OnchainApiGetWalletBalances */ readonly networks: string; /** * Ethereum address * * * * @type {string} * @memberof OnchainApiGetWalletBalances */ readonly address: string; /** * Number of results to return (max 100) (Default: 50, Maximum: 100) * * * * @type {number} * @memberof OnchainApiGetWalletBalances */ readonly limit?: number; /** * Pagination cursor. * * * * @type {string} * @memberof OnchainApiGetWalletBalances */ readonly cursor?: string; } /** * Request parameters for mintNft operation in OnchainApi. * @export * @interface OnchainApiMintNftRequest */ export interface OnchainApiMintNftRequest { /** * Wallet ID to use for transactions * * * @globalHeader * @type {string} * @memberof OnchainApiMintNft */ readonly xWalletId: string; /** * * * * * @type {MintNftRequest} * @memberof OnchainApiMintNft */ readonly mintNftRequest: MintNftRequest; } /** * Request parameters for registerAccountOnchain operation in OnchainApi. * @export * @interface OnchainApiRegisterAccountOnchainRequest */ export interface OnchainApiRegisterAccountOnchainRequest { /** * Wallet ID to use for transactions * * * @globalHeader * @type {string} * @memberof OnchainApiRegisterAccountOnchain */ readonly xWalletId: string; /** * * * * * @type {RegisterUserOnChainReqBody} * @memberof OnchainApiRegisterAccountOnchain */ readonly registerUserOnChainReqBody: RegisterUserOnChainReqBody; } /** * Request parameters for sendFungiblesToUsers operation in OnchainApi. * @export * @interface OnchainApiSendFungiblesToUsersRequest */ export interface OnchainApiSendFungiblesToUsersRequest { /** * Wallet ID to use for transactions * * * @globalHeader * @type {string} * @memberof OnchainApiSendFungiblesToUsers */ readonly xWalletId: string; /** * * * * * @type {TransactionSendFungiblesReqBody} * @memberof OnchainApiSendFungiblesToUsers */ readonly transactionSendFungiblesReqBody: TransactionSendFungiblesReqBody; } /** * Request parameters for simulateNftMint operation in OnchainApi. * @export * @interface OnchainApiSimulateNftMintRequest */ export interface OnchainApiSimulateNftMintRequest { /** * JSON array of recipients (same structure as POST). * * * * @type {string} * @memberof OnchainApiSimulateNftMint */ readonly recipients: string; /** * Ethereum address * * * * @type {string} * @memberof OnchainApiSimulateNftMint */ readonly nftContractAddress: string; /** * Network to mint on. * * * * @type {'base' | 'optimism' | 'base-sepolia'} * @memberof OnchainApiSimulateNftMint */ readonly network: SimulateNftMintNetworkEnum; } /** * OnchainApi - object-oriented interface * @export * @class OnchainApi * @extends {BaseAPI} */ export declare class OnchainApi extends BaseAPI implements OnchainApiInterface { /** * Fetch metadata for multiple tokens in a single request. Provide comma-separated networks and addresses in the same order. Maximum 100 tokens per request. * @summary Batch get token metadata * @param {OnchainApiBatchGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `BatchGetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/batch-get-token-metadata) * */ batchGetTokenMetadata(requestParameters: OnchainApiBatchGetTokenMetadataRequest, options?: RawAxiosRequestConfig): Promise>; /** * Create a signature for a given x402 resource using the specified wallet. * @summary Create x402 signature * @param {OnchainApiCreateX402SignatureRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `CreateX402Signature200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/create-x402-signature) * */ createX402Signature(requestParameters: OnchainApiCreateX402SignatureRequest, options?: RawAxiosRequestConfig): Promise>; /** * Deploy a new ERC-721A (series) NFT collection. * @summary Deploy ERC-721 collection * @param {OnchainApiDeployErc721Request} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `DeployErc721201Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-erc721) * */ deployErc721(requestParameters: OnchainApiDeployErc721Request, options?: RawAxiosRequestConfig): Promise>; /** * Creates a new token. This is an allowlisted API, reach out if you want access. * @summary Deploy fungible * @param {OnchainApiDeployFungibleRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `DeployFungibleResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/deploy-fungible) * */ deployFungible(requestParameters: OnchainApiDeployFungibleRequest, options?: RawAxiosRequestConfig): Promise>; /** * Get recent trades for a specific fungible within a timeframe. Returns trades ordered by timestamp (most recent first). * @summary Get fungible trades * @param {OnchainApiFetchFungibleTradesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `FetchFungibleTrades200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungible-trades) * */ fetchFungibleTrades(requestParameters: OnchainApiFetchFungibleTradesRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetch details for fungible assets identified by fungible identifiers. * @summary Fetch fungibles * @param {OnchainApiFetchFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `FungiblesResponseSchema` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-fungibles) * */ fetchFungibles(requestParameters: OnchainApiFetchFungiblesRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetch a list of relevant owners for a on chain asset. If a viewer is provided, only relevant holders will be shown. This usually shows on a fungible asset page as \"X, Y, Z and N others you know own this asset\". * @summary Relevant owners * @param {OnchainApiFetchRelevantFungibleOwnersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `RelevantFungibleOwnersResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-relevant-fungible-owners) * */ fetchRelevantFungibleOwners(requestParameters: OnchainApiFetchRelevantFungibleOwnersRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetch trending fungibles based on buy activity from watched addresses. Returns fungibles ranked by USD buy volume and buy count within the specified time window. * @summary Trending fungibles * @param {OnchainApiFetchTrendingFungiblesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `FetchTrendingFungibles200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-trending-fungibles) * */ fetchTrendingFungibles(requestParameters: OnchainApiFetchTrendingFungiblesRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetches the token balances of a user given their FID * @summary Token balance * @param {OnchainApiFetchUserBalanceRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `BalanceResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/fetch-user-balance) * */ fetchUserBalance(requestParameters: OnchainApiFetchUserBalanceRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetch metadata for a specific token including price, market data, and basic information. Data is fetched from onchain-indexer with fallback to third-party providers. * @summary Get token metadata * @param {OnchainApiGetTokenMetadataRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `GetTokenMetadata200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-token-metadata) * */ getTokenMetadata(requestParameters: OnchainApiGetTokenMetadataRequest, options?: RawAxiosRequestConfig): Promise>; /** * Fetch all token balances for a wallet address across multiple networks. Results are paginated. * @summary Get wallet token balances * @param {OnchainApiGetWalletBalancesRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `GetWalletBalances200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/get-wallet-balances) * */ getWalletBalances(requestParameters: OnchainApiGetWalletBalancesRequest, options?: RawAxiosRequestConfig): Promise>; /** * Mints an NFT to one or more recipients on a specified network and contract, using a configured server wallet. Contact us to set up your wallet configuration if you don\'t have one. * @summary Mint NFT(s) * @param {OnchainApiMintNftRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `MintNft200Response` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/mint-nft) * */ mintNft(requestParameters: OnchainApiMintNftRequest, options?: RawAxiosRequestConfig): Promise>; /** * Register a new farcaster account onchain. Optionally you can pass in signers to register a new account and create multiple signers in a single transaction. Requires x-wallet-id header. * @summary Register Farcaster account onchain * @param {OnchainApiRegisterAccountOnchainRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `RegisterUserOnChainResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/register-account-onchain) * */ registerAccountOnchain(requestParameters: OnchainApiRegisterAccountOnchainRequest, options?: RawAxiosRequestConfig): Promise>; /** * Send fungibles in bulk to several farcaster users. A funded wallet is to required use this API. React out to us on the Neynar channel on farcaster to get your wallet address. * @summary Send fungibles * @param {OnchainApiSendFungiblesToUsersRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `TransactionSendFungiblesResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/send-fungibles-to-users) * */ sendFungiblesToUsers(requestParameters: OnchainApiSendFungiblesToUsersRequest, options?: RawAxiosRequestConfig): Promise>; /** * Simulates mint calldata for the given recipients, contract, and network. Useful for previewing calldata and ABI before minting. * @summary Simulate NFT mint calldata * @param {OnchainApiSimulateNftMintRequest} requestParameters Request parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof OnchainApi * @returns {Promise} A promise that resolves to a `SimulateNftMintResponse` object * * For more information, refer to the [API documentation](https://docs.neynar.com/reference/simulate-nft-mint) * */ simulateNftMint(requestParameters: OnchainApiSimulateNftMintRequest, options?: RawAxiosRequestConfig): Promise>; } /** * @export */ export declare const DeployFungibleMetadataNsfwEnum: { readonly True: "true"; readonly False: "false"; }; export type DeployFungibleMetadataNsfwEnum = typeof DeployFungibleMetadataNsfwEnum[keyof typeof DeployFungibleMetadataNsfwEnum]; /** * @export */ export declare const DeployFungibleNetworkEnum: { readonly Base: "base"; }; export type DeployFungibleNetworkEnum = typeof DeployFungibleNetworkEnum[keyof typeof DeployFungibleNetworkEnum]; /** * @export */ export declare const DeployFungibleFactoryEnum: { readonly Wow: "wow"; readonly Clanker: "clanker"; }; export type DeployFungibleFactoryEnum = typeof DeployFungibleFactoryEnum[keyof typeof DeployFungibleFactoryEnum]; /** * @export */ export declare const FetchFungibleTradesNetworkEnum: { readonly Base: "base"; }; export type FetchFungibleTradesNetworkEnum = typeof FetchFungibleTradesNetworkEnum[keyof typeof FetchFungibleTradesNetworkEnum]; /** * @export */ export declare const FetchFungibleTradesTimeWindowEnum: { readonly _1h: "1h"; readonly _6h: "6h"; readonly _12h: "12h"; readonly _24h: "24h"; readonly _7d: "7d"; }; export type FetchFungibleTradesTimeWindowEnum = typeof FetchFungibleTradesTimeWindowEnum[keyof typeof FetchFungibleTradesTimeWindowEnum]; /** * @export */ export declare const FetchRelevantFungibleOwnersNetworkEnum: { readonly Ethereum: "ethereum"; readonly Optimism: "optimism"; readonly Base: "base"; readonly Arbitrum: "arbitrum"; readonly Solana: "solana"; }; export type FetchRelevantFungibleOwnersNetworkEnum = typeof FetchRelevantFungibleOwnersNetworkEnum[keyof typeof FetchRelevantFungibleOwnersNetworkEnum]; /** * @export */ export declare const FetchTrendingFungiblesNetworkEnum: { readonly Base: "base"; }; export type FetchTrendingFungiblesNetworkEnum = typeof FetchTrendingFungiblesNetworkEnum[keyof typeof FetchTrendingFungiblesNetworkEnum]; /** * @export */ export declare const FetchTrendingFungiblesTimeWindowEnum: { readonly _1h: "1h"; readonly _6h: "6h"; readonly _12h: "12h"; readonly _24h: "24h"; readonly _7d: "7d"; }; export type FetchTrendingFungiblesTimeWindowEnum = typeof FetchTrendingFungiblesTimeWindowEnum[keyof typeof FetchTrendingFungiblesTimeWindowEnum]; /** * @export */ export declare const FetchUserBalanceNetworksEnum: { readonly Ethereum: "ethereum"; readonly Optimism: "optimism"; readonly Base: "base"; readonly Arbitrum: "arbitrum"; }; export type FetchUserBalanceNetworksEnum = typeof FetchUserBalanceNetworksEnum[keyof typeof FetchUserBalanceNetworksEnum]; /** * @export */ export declare const GetTokenMetadataNetworkEnum: { readonly Ethereum: "ethereum"; readonly Optimism: "optimism"; readonly Base: "base"; readonly Arbitrum: "arbitrum"; }; export type GetTokenMetadataNetworkEnum = typeof GetTokenMetadataNetworkEnum[keyof typeof GetTokenMetadataNetworkEnum]; /** * @export */ export declare const SimulateNftMintNetworkEnum: { readonly Base: "base"; readonly Optimism: "optimism"; readonly BaseSepolia: "base-sepolia"; }; export type SimulateNftMintNetworkEnum = typeof SimulateNftMintNetworkEnum[keyof typeof SimulateNftMintNetworkEnum];