Skip to content

API Types Reference

Complete TypeScript interface reference for the Integra verification platform.

Standardized result from all verification functions:

interface VerificationResult {
success: boolean;
verificationId: string;
chainId: string;
address: string;
match: 'full' | 'partial' | 'none';
artifacts?: {
abi: any[];
bytecode: string;
deployedBytecode: string;
metadata: string;
};
error?: string;
}

Compiler configuration for contract verification:

interface CompilerSettings {
evmVersion?: string;
optimizerEnabled: boolean;
optimizerRuns: number;
}

Job tracking for verification processes:

interface VerificationJobStatus {
isJobCompleted: boolean;
hasJobError: boolean;
errorMessage?: string;
createdAt: string;
completedAt?: string;
contractsWithVerificationData?: {
chainId: string;
address: string;
match: MatchType;
}[];
}

Complete verification submission with metadata:

interface SubmitVerificationRequest {
chainId: number;
address: string;
standardJsonInput: StandardJsonInput;
compilerVersion: string;
contractPath: string;
contractName: string;
constructorArguments?: string;
metadata: {
name: string;
category: ComponentCategory;
description: string;
publisher: {
name: string;
address: string;
};
};
}

Complete workflow tracking:

interface SubmissionStatus {
id: string;
status: VerificationStatus;
verificationCid?: string;
easAttestationUid?: string;
registryTxHash?: string;
createdAt: string;
completedAt?: string;
errorMessage?: string;
errorContext?: Record<string, unknown>;
}

Basic blockchain network information:

interface Chain {
chainId: number;
name: string;
displayName?: string;
nativeCurrency: {
name: string;
symbol: string;
decimals: number;
};
blockExplorerUrl?: string;
isTestnet: boolean;
}

Complete network configuration:

interface ChainWithRpc extends Chain {
rpc: {
primary: string;
fallback: string[];
};
}

Complete component metadata structure:

interface IntegraMetadataV1 {
identity: IdentityMetadata;
contract: ContractMetadata;
publisher: PublisherMetadata;
security?: SecurityMetadata;
documentation?: DocumentationMetadata;
media?: MediaMetadata;
compatibility?: CompatibilityMetadata;
proxy?: ProxyMetadata;
createdAt: string;
updatedAt: string;
}

Available component categories:

type ComponentCategory =
| 'Tokenizer'
| 'Resolver'
| 'Provider'
| 'Verifier'
| 'Registry'
| 'Utility';

Solidity compiler input format:

interface StandardJsonInput {
language: string;
sources: Record<string, { content: string }>;
settings: Record<string, unknown>;
}

Compilation result:

interface CompileResponse {
success: boolean;
abi?: any[];
bytecode?: string;
deployedBytecode?: string;
metadata?: string;
compilationTime?: number;
error?: string;
}

Contract deployment information:

interface DeployerInfo {
deployerAddress: string;
creationTxHash: string;
creationBlock: number;
timestamp: number;
}