> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zixflow.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Advanced Configuration

> Advanced Configuration — Zixflow JavaScript SDK integration guide.

### Browser Configuration

```javascript theme={null}
import { AnalyticsBrowser } from '@zixflow/analytics-browser'

const analytics = AnalyticsBrowser.load({
  // Required
  apiKey: 'YOUR_API_KEY',

  // Delivery strategy
  deliveryStrategy: {
    strategy: 'batching',  // or 'standard'
    config: {
      size: 10,       // Batch size
      timeout: 5000   // Batch timeout (ms)
    }
  },

  // Disable page views
  disablePageView: false,

  // Disable client-side persistence
  disableClientPersistence: false,

  // Plugins
  plugins: [
    // Custom plugins
  ],

  // Middleware
  addSourceMiddleware: (middleware) => {
    // Add source middleware
  },

  // Initial page view
  initialPageview: true,

  // Obfuscate
  obfuscate: false
})
```

***

### Node.js Configuration

```javascript theme={null}
import { Analytics } from '@zixflow/analytics-node'

const analytics = new Analytics({
  // Required
  writeKey: 'YOUR_API_KEY',

  // API path (optional)
  path: '/v1/track',

  // Batching
  maxEventsInBatch: 15,      // Max events per batch
  flushInterval: 10000,      // Flush interval (ms)

  // Retries
  maxRetries: 3,             // Max retry attempts
  httpRequestTimeout: 10000, // Request timeout (ms)

  // Disable events
  disable: false,

  // Enable/disable specific features
  enable: true
})
```

***

### Delivery Strategies (Browser)

#### Standard Delivery

Send each event immediately:

```javascript theme={null}
const analytics = AnalyticsBrowser.load({
  apiKey: 'YOUR_API_KEY',
  deliveryStrategy: {
    strategy: 'standard'
  }
})
```

#### Batched Delivery

Batch events for efficiency:

```javascript theme={null}
const analytics = AnalyticsBrowser.load({
  apiKey: 'YOUR_API_KEY',
  deliveryStrategy: {
    strategy: 'batching',
    config: {
      size: 10,        // Send after 10 events
      timeout: 5000    // Or after 5 seconds
    }
  }
})
```

***
