twinmind-debug-bundle

Collect comprehensive diagnostic information for TwinMind issues. Use when preparing support requests, investigating complex problems, or gathering evidence for bug reports. Trigger with phrases like "twinmind debug", "twinmind diagnostics", "collect twinmind info", "twinmind support bundle".

1,868 stars

Best use case

twinmind-debug-bundle is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Collect comprehensive diagnostic information for TwinMind issues. Use when preparing support requests, investigating complex problems, or gathering evidence for bug reports. Trigger with phrases like "twinmind debug", "twinmind diagnostics", "collect twinmind info", "twinmind support bundle".

Teams using twinmind-debug-bundle should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/twinmind-debug-bundle/SKILL.md --create-dirs "https://raw.githubusercontent.com/jeremylongshore/claude-code-plugins-plus-skills/main/plugins/saas-packs/twinmind-pack/skills/twinmind-debug-bundle/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/twinmind-debug-bundle/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How twinmind-debug-bundle Compares

Feature / Agenttwinmind-debug-bundleStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Collect comprehensive diagnostic information for TwinMind issues. Use when preparing support requests, investigating complex problems, or gathering evidence for bug reports. Trigger with phrases like "twinmind debug", "twinmind diagnostics", "collect twinmind info", "twinmind support bundle".

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

Related Guides

SKILL.md Source

# TwinMind Debug Bundle

## Current State
!`node --version 2>/dev/null || echo 'N/A'`
!`python3 --version 2>/dev/null || echo 'N/A'`
!`uname -a`

## Overview
Collect comprehensive diagnostic data to troubleshoot TwinMind issues.

## Prerequisites
- TwinMind extension or API configured
- Access to browser developer tools
- Command-line access (for API debugging)

## Instructions

### Step 1: Create Debug Bundle Script

```typescript
// scripts/twinmind-debug-bundle.ts
import * as fs from 'fs';
import * as os from 'os';
import * as path from 'path';

interface DebugBundle {
  timestamp: string;
  environment: EnvironmentInfo;
  apiStatus: ApiStatus;
  recentErrors: ErrorEntry[];
  configuration: ConfigSnapshot;
  networkTests: NetworkTest[];
}

interface EnvironmentInfo {
  nodeVersion: string;
  platform: string;
  arch: string;
  osRelease: string;
  timezone: string;
  memory: {
    total: number;
    free: number;
    used: number;
  };
}

interface ApiStatus {
  healthy: boolean;
  latencyMs: number;
  endpoint: string;
  responseHeaders?: Record<string, string>;
}

interface ErrorEntry {
  timestamp: string;
  type: string;
  message: string;
  stack?: string;
  context?: Record<string, any>;
}

interface ConfigSnapshot {
  apiKeyPresent: boolean;
  apiKeyPrefix: string;
  baseUrl: string;
  timeout: number;
  environment: string;
}

interface NetworkTest {
  endpoint: string;
  reachable: boolean;
  latencyMs?: number;
  error?: string;
}

export async function generateDebugBundle(): Promise<DebugBundle> {
  const bundle: DebugBundle = {
    timestamp: new Date().toISOString(),
    environment: getEnvironmentInfo(),
    apiStatus: await checkApiStatus(),
    recentErrors: collectRecentErrors(),
    configuration: getConfigSnapshot(),
    networkTests: await runNetworkTests(),
  };

  return bundle;
}

function getEnvironmentInfo(): EnvironmentInfo {
  return {
    nodeVersion: process.version,
    platform: os.platform(),
    arch: os.arch(),
    osRelease: os.release(),
    timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
    memory: {
      total: os.totalmem(),
      free: os.freemem(),
      used: os.totalmem() - os.freemem(),
    },
  };
}

async function checkApiStatus(): Promise<ApiStatus> {
  const endpoint = process.env.TWINMIND_API_URL || 'https://api.twinmind.com/v1';
  const start = Date.now();

  try {
    const response = await fetch(`${endpoint}/health`, {
      headers: {
        'Authorization': `Bearer ${process.env.TWINMIND_API_KEY}`,
      },
    });

    return {
      healthy: response.ok,
      latencyMs: Date.now() - start,
      endpoint,
      responseHeaders: Object.fromEntries(response.headers.entries()),
    };
  } catch (error: any) {
    return {
      healthy: false,
      latencyMs: Date.now() - start,
      endpoint,
    };
  }
}

function collectRecentErrors(): ErrorEntry[] {
  // In a real implementation, this would read from error logs
  // For now, return empty array
  return [];
}

function getConfigSnapshot(): ConfigSnapshot {
  const apiKey = process.env.TWINMIND_API_KEY || '';

  return {
    apiKeyPresent: apiKey.length > 0,
    apiKeyPrefix: apiKey.substring(0, 8) + '...',
    baseUrl: process.env.TWINMIND_API_URL || 'https://api.twinmind.com/v1',
    timeout: parseInt(process.env.TWINMIND_TIMEOUT || '30000'),  # 30000: 30 seconds in ms
    environment: process.env.NODE_ENV || 'development',
  };
}

async function runNetworkTests(): Promise<NetworkTest[]> {
  const endpoints = [
    'https://api.twinmind.com',
    'https://status.twinmind.com',
    'https://twinmind.com',
  ];

  const tests: NetworkTest[] = [];

  for (const endpoint of endpoints) {
    const start = Date.now();
    try {
      const response = await fetch(endpoint, { method: 'HEAD' });
      tests.push({
        endpoint,
        reachable: response.ok,
        latencyMs: Date.now() - start,
      });
    } catch (error: any) {
      tests.push({
        endpoint,
        reachable: false,
        error: error.message,
      });
    }
  }

  return tests;
}

// Save bundle to file
export async function saveDebugBundle(outputPath?: string): Promise<string> {
  const bundle = await generateDebugBundle();

  const filename = outputPath || path.join(
    os.tmpdir(),
    `twinmind-debug-${Date.now()}.json`
  );

  fs.writeFileSync(filename, JSON.stringify(bundle, null, 2));

  console.log(`Debug bundle saved to: ${filename}`);
  return filename;
}
```

### Step 2: Run Debug Bundle Collection

```bash
set -euo pipefail
# Using the script
npx ts-node scripts/twinmind-debug-bundle.ts

# Or quick CLI commands:

# Check API health
curl -w "\nLatency: %{time_total}s\n" \
  -H "Authorization: Bearer $TWINMIND_API_KEY" \
  https://api.twinmind.com/v1/health

# Check account status
curl -H "Authorization: Bearer $TWINMIND_API_KEY" \
  https://api.twinmind.com/v1/me | jq

# Check rate limit status
curl -I -H "Authorization: Bearer $TWINMIND_API_KEY" \
  https://api.twinmind.com/v1/health 2>/dev/null | grep -i ratelimit

# Test transcription endpoint
curl -X POST \
  -H "Authorization: Bearer $TWINMIND_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"audio_url":"https://example.com/test.mp3"}' \
  https://api.twinmind.com/v1/transcribe
```

### Step 3: Browser Extension Debugging

```javascript
// Open Chrome DevTools (F12) on any TwinMind page
// Console commands for debugging:

// Check extension version
chrome.runtime.getManifest().version

// Check stored data
chrome.storage.local.get(null, console.log)

// Check permissions
navigator.permissions.query({name: 'microphone'}).then(console.log)

// Check audio devices
navigator.mediaDevices.enumerateDevices().then(devices => {
  console.log('Audio devices:', devices.filter(d => d.kind === 'audioinput'))
})

// Check extension errors
// Go to: chrome://extensions > TwinMind > Errors
```

### Step 4: Collect Network HAR File

```
1. Open Chrome DevTools (F12)
2. Go to Network tab
3. Check "Preserve log"
4. Reproduce the issue
5. Right-click > Save all as HAR with content
```

### Step 5: Generate Full Debug Report

```typescript
// scripts/full-debug-report.ts
import { generateDebugBundle } from './twinmind-debug-bundle';

async function generateFullReport() {
  const bundle = await generateDebugBundle();

  const report = `
# TwinMind Debug Report
Generated: ${bundle.timestamp}

## Environment
- Node: ${bundle.environment.nodeVersion}
- Platform: ${bundle.environment.platform} (${bundle.environment.arch})
- OS: ${bundle.environment.osRelease}
- Timezone: ${bundle.environment.timezone}
- Memory: ${Math.round(bundle.environment.memory.used / 1024 / 1024)}MB / ${Math.round(bundle.environment.memory.total / 1024 / 1024)}MB  # 1024: 1 KB

## API Status
- Healthy: ${bundle.apiStatus.healthy ? 'Yes' : 'No'}
- Latency: ${bundle.apiStatus.latencyMs}ms
- Endpoint: ${bundle.apiStatus.endpoint}

## Configuration
- API Key Present: ${bundle.configuration.apiKeyPresent}
- API Key Prefix: ${bundle.configuration.apiKeyPrefix}
- Base URL: ${bundle.configuration.baseUrl}
- Timeout: ${bundle.configuration.timeout}ms
- Environment: ${bundle.configuration.environment}

## Network Tests
${bundle.networkTests.map(t =>
  `- ${t.endpoint}: ${t.reachable ? `OK (${t.latencyMs}ms)` : `FAILED - ${t.error}`}`
).join('\n')}

## Recent Errors
${bundle.recentErrors.length === 0 ? 'No recent errors' :
  bundle.recentErrors.map(e =>
    `- [${e.timestamp}] ${e.type}: ${e.message}`
  ).join('\n')
}

## Troubleshooting Steps Taken
[ ] Verified API key is valid
[ ] Checked microphone permissions
[ ] Tested network connectivity
[ ] Cleared browser cache/data
[ ] Disabled conflicting extensions
[ ] Reproduced in incognito mode

## Issue Description
[Describe the issue here]

## Steps to Reproduce
1. [Step 1]
2. [Step 2]
3. [Step 3]

## Expected Behavior
[What should happen]

## Actual Behavior
[What actually happens]
`;

  console.log(report);
  return report;
}

generateFullReport();
```

## Output
- JSON debug bundle file
- Environment information
- API connectivity status
- Network test results
- Configuration snapshot (no secrets)
- Debug report template

Example output:
```json
{
  "timestamp": "2025-01-15T10:30:00Z",  # 2025 year
  "environment": {
    "nodeVersion": "v20.10.0",
    "platform": "darwin",
    "arch": "arm64"
  },
  "apiStatus": {
    "healthy": true,
    "latencyMs": 145
  },
  "networkTests": [
    {"endpoint": "https://api.twinmind.com", "reachable": true, "latencyMs": 120}
  ]
}
```

## Error Handling

| Issue | Cause | Solution |
|-------|-------|----------|
| API unreachable | Network/firewall | Check VPN/proxy settings |
| Auth failed | Invalid key | Regenerate API key |
| Timeout | Slow network | Increase timeout value |
| Missing env vars | Not configured | Check .env file |

## Information to Include in Support Request

1. **Debug bundle JSON** - Generated by this script
2. **HAR file** - Network requests during failure
3. **Console logs** - Browser or terminal errors
4. **Request ID** - From response headers (X-Request-Id)
5. **Timestamps** - When the issue occurred
6. **Steps to reproduce** - Detailed sequence

## Security Notes

The debug bundle intentionally excludes:
- Full API keys (only prefix shown)
- Audio content
- Transcript content
- Personal information
- OAuth tokens

Always review the bundle before sharing with support.

## Resources
- [TwinMind Support](https://twinmind.com/support)
- [TwinMind Status](https://status.twinmind.com)
- [Community Forum](https://community.twinmind.com)

## Next Steps
For rate limiting strategies, see `twinmind-rate-limits`.

## Examples

**Basic usage**: Apply twinmind debug bundle to a standard project setup with default configuration options.

**Advanced scenario**: Customize twinmind debug bundle for production environments with multiple constraints and team-specific requirements.

Related Skills

workhuman-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Workhuman debug bundle for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman debug bundle".

wispr-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Wispr Flow debug bundle for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr debug bundle".

webflow-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Collect Webflow debug evidence for support tickets and troubleshooting. Gathers SDK version, token validation, rate limit status, site connectivity, CMS health, and error logs into a single diagnostic bundle. Trigger with phrases like "webflow debug", "webflow support bundle", "collect webflow logs", "webflow diagnostic", "webflow troubleshoot".

vercel-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Collect Vercel debug evidence for support tickets and troubleshooting. Use when encountering persistent issues, preparing support tickets, or collecting diagnostic information for Vercel problems. Trigger with phrases like "vercel debug", "vercel support bundle", "collect vercel logs", "vercel diagnostic".

veeva-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Veeva Vault debug bundle for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva debug bundle".

vastai-debug-bundle

1868
from jeremylongshore/claude-code-plugins-plus-skills

Collect Vast.ai debug evidence for support tickets and troubleshooting. Use when encountering persistent issues, preparing support tickets, or collecting diagnostic information for Vast.ai problems. Trigger with phrases like "vastai debug", "vastai support bundle", "collect vastai logs", "vastai diagnostic".

twinmind-webhooks-events

1868
from jeremylongshore/claude-code-plugins-plus-skills

Handle TwinMind meeting events including transcription completion, action item extraction, and calendar sync notifications. Use when implementing webhooks events, or managing TwinMind meeting AI operations. Trigger with phrases like "twinmind webhooks events", "twinmind webhooks events".

twinmind-upgrade-migration

1868
from jeremylongshore/claude-code-plugins-plus-skills

Upgrade between TwinMind plan tiers and migrate configurations. Use when upgrading from Free to Pro, Pro to Enterprise, or migrating between TwinMind environments. Trigger with phrases like "upgrade twinmind", "twinmind pro", "twinmind enterprise", "migrate twinmind", "twinmind tier change".

twinmind-security-basics

1868
from jeremylongshore/claude-code-plugins-plus-skills

Security best practices for TwinMind: on-device audio processing, encrypted cloud backups, microphone permissions, and data privacy controls. Use when implementing security basics, or managing TwinMind meeting AI operations. Trigger with phrases like "twinmind security basics", "twinmind security basics".

twinmind-sdk-patterns

1868
from jeremylongshore/claude-code-plugins-plus-skills

Apply production-ready TwinMind SDK patterns for TypeScript and Python. Use when implementing TwinMind integrations, refactoring API usage, or establishing team coding standards for meeting AI integration. Trigger with phrases like "twinmind SDK patterns", "twinmind best practices", "twinmind code patterns", "idiomatic twinmind".

twinmind-reference-architecture

1868
from jeremylongshore/claude-code-plugins-plus-skills

Production architecture for meeting AI systems using TwinMind: transcription pipeline, memory vault, action item workflow, and calendar integration. Use when implementing reference architecture, or managing TwinMind meeting AI operations. Trigger with phrases like "twinmind reference architecture", "twinmind reference architecture".

twinmind-rate-limits

1868
from jeremylongshore/claude-code-plugins-plus-skills

Implement TwinMind rate limiting, backoff, and optimization patterns. Use when handling rate limit errors, implementing retry logic, or optimizing API request throughput for TwinMind. Trigger with phrases like "twinmind rate limit", "twinmind throttling", "twinmind 429", "twinmind retry", "twinmind backoff".