SynapseOptions
Defined in: packages/synapse-sdk/src/types.ts:37
Options for initializing the Synapse instance Must provide one of:
- privateKey + rpcURL (for server environments)
- provider (for browser environments - user handles MetaMask coupling)
- signer (for direct ethers.js integration)
Properties
Section titled “Properties”authorization?
Section titled “authorization?”optional authorization: string;
Defined in: packages/synapse-sdk/src/types.ts:52
Authorization header value for API authentication (e.g., Bearer token)
disableNonceManager?
Section titled “disableNonceManager?”optional disableNonceManager: boolean;
Defined in: packages/synapse-sdk/src/types.ts:61
Whether to disable NonceManager for automatic nonce management (default: false, meaning NonceManager is used)
pdpVerifierAddress?
Section titled “pdpVerifierAddress?”optional pdpVerifierAddress: string;
Defined in: packages/synapse-sdk/src/types.ts:65
Override PDPVerifier contract address (defaults to network’s default)
pieceRetriever?
Section titled “pieceRetriever?”optional pieceRetriever: PieceRetriever;
Defined in: packages/synapse-sdk/src/types.ts:59
Optional override for piece retrieval
privateKey?
Section titled “privateKey?”optional privateKey: string;
Defined in: packages/synapse-sdk/src/types.ts:41
Private key for signing transactions (requires rpcURL)
provider?
Section titled “provider?”optional provider: Provider;
Defined in: packages/synapse-sdk/src/types.ts:43
Ethers Provider instance (handles both reads and transactions)
rpcURL?
Section titled “rpcURL?”optional rpcURL: string;
Defined in: packages/synapse-sdk/src/types.ts:50
RPC URL for Filecoin node (required with privateKey)
signer?
Section titled “signer?”optional signer: Signer;
Defined in: packages/synapse-sdk/src/types.ts:45
Ethers Signer instance (for direct ethers.js integration)
subgraphConfig?
Section titled “subgraphConfig?”optional subgraphConfig: SubgraphConfig;
Defined in: packages/synapse-sdk/src/types.ts:71
Optional configuration for the default subgraph service, to enable subgraph-based retrieval.
subgraphService?
Section titled “subgraphService?”optional subgraphService: SubgraphRetrievalService;
Defined in: packages/synapse-sdk/src/types.ts:69
Optional override for default subgraph service, to enable subgraph-based retrieval.
warmStorageAddress?
Section titled “warmStorageAddress?”optional warmStorageAddress: string;
Defined in: packages/synapse-sdk/src/types.ts:63
Override Warm Storage service contract address (defaults to network’s default)
withCDN?
Section titled “withCDN?”optional withCDN: boolean;
Defined in: packages/synapse-sdk/src/types.ts:57
Whether to use CDN for retrievals (default: false)