interface EtherscanContract { SourceCode: string; ABI: string; ContractName: string; CompilerVersion: string; OptimizationUsed: string; Runs: string; ConstructorArguments: string; EVMVersion: string; Library: string; LicenseType: string; Proxy: string; Implementation: string; SwarmSource: string; } interface EtherscanGetSourceCodeNotOkResponse { status: '0'; message: 'NOTOK'; result: string; } interface EtherscanGetSourceCodeOkResponse { status: '1'; message: 'OK'; result: EtherscanContract[]; } export type EtherscanGetSourceCodeResponse = EtherscanGetSourceCodeNotOkResponse | EtherscanGetSourceCodeOkResponse; export type SourcifyVerifyRequest = { stdJsonInput: object; compilerVersion: string; contractIdentifier: string; creationTransactionHash?: string; }; export type SourcifyVerifyResponse = { verificationId: string; }; export type SourcifyVerifyStatusResponse = { isJobCompleted: boolean; verificationId: string; error: { customCode: string; message: string; errorId: string; recompiledCreationCode: string; recompiledRuntimeCode: string; onchainCreationCode: string; onchainRuntimeCode: string; creationTransactionHash: string; errorData: object; }; jobStartTime: string; jobFinishTime: string; compilationTime: string; contract: { match: 'exact_match' | 'match' | null; creationMatch: 'exact_match' | 'match' | null; runtimeMatch: 'exact_match' | 'match' | null; chainId: string; address: string; verifiedAt: string; matchId: string; }; }; export declare const ETHERSCAN_DEFAULT_SERVER_URL = "https://api.etherscan.io/v2/api"; export declare const SOURCIFY_DEFAULT_SERVER_URL = "https://sourcify.dev/server"; /** * Check if a smart contract is verified on Etherscan. * @link https://docs.etherscan.io/api-endpoints/contracts#get-contract-source-code-for-verified-contract-source-codes * @param address - The address of the smart contract. * @param apiUrl - Etherscan API URL. * @param apiKey - Etherscan API Key. * @returns True if the contract is verified, false otherwise. */ export declare function isEtherscanVerified(address: string, chainId: number, apiUrl: string, apiKey: string): Promise; /** * Check if a smart contract is verified on Sourcify. * @link https://docs.sourcify.dev/docs/api/#/Contract%20Lookup/get-contract * @param address - The address of the smart contract. * @param chainId - The chainId of the smart contract. * @param serverUrl - Sourcify API URL. * @returns True if the contract is verified, false otherwise. */ export declare function isSourcifyVerified(address: string, chainId: number, serverUrl: string | null): Promise; /** * Get the endpoint needed to do an actual verification with sourcify * @param address - The address of the smart contract. * @param chainId - The chainId of the smart contract. * @param serverUrl - Sourcify API URL. * @returns The URL to POST to */ export declare function getSourcifyVerificationEndpoint(chainId: number, address: string, serverOverride: string | null): string; /** * Get the endpoint needed to do an actual verification with sourcify * @param verificationId - The ID received from the verification endpoint * @param serverUrl - Sourcify API URL. * @returns The URL to GET */ export declare function getSourcifyVerificationStatusEndpoint(verificationId: string, serverOverride: string | null): string; export {}; //# sourceMappingURL=verify.d.ts.map