Application configuration with privateKey and RPC URL
Logger instance for detailed operation tracking
Optionaloptions: CreateStorageContextOptionsOptional dataset selection and callbacks
SynapseService with initialized Synapse and storage context
// Standard setup (reuses wallet's dataset)
const service = await setupSynapse(config, logger)
// Create new dataset for multi-user scenario
const service = await setupSynapse(config, logger, {
dataset: { createNew: true }
})
// Connect to specific dataset
const service = await setupSynapse(config, logger, {
dataset: { useExisting: 123 }
})
Set up complete Synapse service with SDK and storage context
This function demonstrates the complete setup flow for Synapse:
Our wrapping of Synapse initialization and storage context creation is primarily to handle our custom configuration needs and add detailed logging and progress tracking.