[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6F7SCR8W3D434RKR89WA70S":3,"skill-same:01M6F7SCR8W3D434RKR89WA70S":75},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":39,"linkOnly":40,"markdownContent":41,"markdownBody":42,"frontMatter":43,"refName":52,"commitSha":53,"skillDirectory":54,"forksCount":55,"repositoryHtmlUrl":56,"repositoryHomepageUrl":57,"ownerHtmlUrl":58,"ownerBlogUrl":6,"ownerDescription":59,"updatedAt":60,"install":61,"resources":74},"01M6F7SCR8W3D434RKR89WA70S","brightdata-local-dev-loop",null,"Configure Bright Data local development with hot reload and testing.\nUse when setting up a development environment, configuring test workflows,\nor establishing a fast iteration cycle with Bright Data.\nTrigger with phrases like \"brightdata dev setup\", \"brightdata local development\",\n\"brightdata dev environment\", \"develop with brightdata\".","ComeOnOliver\u002Fskillshub","ComeOnOliver","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F43215937?v=4","01M6E5JNFECJAAVFE0W7SMWWD2","Haoran Shu","01M6E5JNNDQS7AJZDYFQ8TPZCK",67,"MIT","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fjeremylongshore\u002Fclaude-code-plugins-plus-skills\u002Fbrightdata-local-dev-loop\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38],"local dev","brightdata local dev loop","local","brightdata","loop","dev","Bash","code","configure","read","write","edit","scraping","up","workflows","cycle","dev setup","iteration","io","testing","2026-11-10 10:12:30",false,"---\nname: brightdata-local-dev-loop\ndescription: |\n  Configure Bright Data local development with hot reload and testing.\n  Use when setting up a development environment, configuring test workflows,\n  or establishing a fast iteration cycle with Bright Data.\n  Trigger with phrases like \"brightdata dev setup\", \"brightdata local development\",\n  \"brightdata dev environment\", \"develop with brightdata\".\nallowed-tools: Read, Write, Edit, Bash(npm:*), Bash(pnpm:*), Grep\nversion: 1.0.0\nlicense: MIT\nauthor: Jeremy Longshore \u003Cjeremy@intentsolutions.io>\ntags: [saas, scraping, data, brightdata]\ncompatible-with: claude-code\n---\n\n# Bright Data Local Dev Loop\n\n## Overview\n\nSet up a fast, reproducible local development workflow for Bright Data scraping projects with mocked proxy responses, cached results, and vitest integration.\n\n## Prerequisites\n\n- Completed `brightdata-install-auth` setup\n- Node.js 18+ with npm\u002Fpnpm\n- brd-ca.crt SSL certificate downloaded\n\n## Instructions\n\n### Step 1: Create Project Structure\n\n```\nmy-scraper\u002F\n├── src\u002F\n│   ├── brightdata\u002F\n│   │   ├── proxy.ts         # Proxy configuration helper\n│   │   ├── scraper.ts       # Scraping functions\n│   │   └── cache.ts         # Response caching for dev\n│   └── index.ts\n├── tests\u002F\n│   ├── fixtures\u002F            # Cached HTML responses\n│   │   └── example.html\n│   └── scraper.test.ts\n├── .env.local               # Local credentials (git-ignored)\n├── .env.example             # Template for team\n├── brd-ca.crt               # Bright Data SSL cert (git-ignored)\n└── package.json\n```\n\n### Step 2: Build Proxy Configuration Module\n\n```typescript\n\u002F\u002F src\u002Fbrightdata\u002Fproxy.ts\nimport 'dotenv\u002Fconfig';\n\nexport interface BrightDataProxy {\n  host: string;\n  port: number;\n  auth: { username: string; password: string };\n}\n\nexport function getProxy(options?: {\n  country?: string;\n  city?: string;\n  session?: string;\n}): BrightDataProxy {\n  const { BRIGHTDATA_CUSTOMER_ID, BRIGHTDATA_ZONE, BRIGHTDATA_ZONE_PASSWORD } = process.env;\n  if (!BRIGHTDATA_CUSTOMER_ID || !BRIGHTDATA_ZONE || !BRIGHTDATA_ZONE_PASSWORD) {\n    throw new Error('Missing BRIGHTDATA_* environment variables');\n  }\n\n  let username = `brd-customer-${BRIGHTDATA_CUSTOMER_ID}-zone-${BRIGHTDATA_ZONE}`;\n  if (options?.country) username += `-country-${options.country}`;\n  if (options?.city) username += `-city-${options.city}`;\n  if (options?.session) username += `-session-${options.session}`;\n\n  return {\n    host: 'brd.superproxy.io',\n    port: 33335,\n    auth: { username, password: BRIGHTDATA_ZONE_PASSWORD },\n  };\n}\n```\n\n### Step 3: Add Response Cache for Development\n\n```typescript\n\u002F\u002F src\u002Fbrightdata\u002Fcache.ts — cache scraped pages to avoid burning proxy credits\nimport { createHash } from 'crypto';\nimport { existsSync, readFileSync, writeFileSync, mkdirSync } from 'fs';\nimport { join } from 'path';\n\nconst CACHE_DIR = join(process.cwd(), '.scrape-cache');\n\nexport function getCachedResponse(url: string): string | null {\n  const key = createHash('md5').update(url).digest('hex');\n  const path = join(CACHE_DIR, `${key}.html`);\n  return existsSync(path) ? readFileSync(path, 'utf-8') : null;\n}\n\nexport function setCachedResponse(url: string, html: string): void {\n  mkdirSync(CACHE_DIR, { recursive: true });\n  const key = createHash('md5').update(url).digest('hex');\n  writeFileSync(join(CACHE_DIR, `${key}.html`), html);\n}\n```\n\n### Step 4: Configure Testing with Mocked Responses\n\n```typescript\n\u002F\u002F tests\u002Fscraper.test.ts\nimport { describe, it, expect, vi, beforeEach } from 'vitest';\nimport axios from 'axios';\n\nvi.mock('axios');\nconst mockedAxios = vi.mocked(axios);\n\ndescribe('Bright Data Scraper', () => {\n  beforeEach(() => vi.clearAllMocks());\n\n  it('should scrape through proxy and return HTML', async () => {\n    mockedAxios.get.mockResolvedValueOnce({\n      status: 200,\n      data: '\u003Chtml>\u003Chead>\u003Ctitle>Test\u003C\u002Ftitle>\u003C\u002Fhead>\u003C\u002Fhtml>',\n    });\n\n    const { scrape } = await import('..\u002Fsrc\u002Fbrightdata\u002Fscraper');\n    const html = await scrape('https:\u002F\u002Fexample.com');\n    expect(html).toContain('\u003Ctitle>Test\u003C\u002Ftitle>');\n\n    \u002F\u002F Verify proxy was configured\n    expect(mockedAxios.get).toHaveBeenCalledWith(\n      'https:\u002F\u002Fexample.com',\n      expect.objectContaining({\n        proxy: expect.objectContaining({ host: 'brd.superproxy.io' }),\n      }),\n    );\n  });\n\n  it('should retry on 502 proxy errors', async () => {\n    mockedAxios.get\n      .mockRejectedValueOnce({ response: { status: 502 } })\n      .mockResolvedValueOnce({ status: 200, data: '\u003Chtml>OK\u003C\u002Fhtml>' });\n\n    const { scrapeWithRetry } = await import('..\u002Fsrc\u002Fbrightdata\u002Fscraper');\n    const html = await scrapeWithRetry('https:\u002F\u002Fexample.com');\n    expect(html).toContain('OK');\n    expect(mockedAxios.get).toHaveBeenCalledTimes(2);\n  });\n});\n```\n\n### Step 5: Package Scripts\n\n```json\n{\n  \"scripts\": {\n    \"dev\": \"tsx watch src\u002Findex.ts\",\n    \"scrape\": \"tsx src\u002Findex.ts\",\n    \"test\": \"vitest\",\n    \"test:watch\": \"vitest --watch\",\n    \"test:live\": \"BRIGHTDATA_LIVE=1 vitest --testPathPattern=integration\"\n  }\n}\n```\n\n## Output\n\n- Proxy config module with geo-targeting support\n- Response cache to avoid burning credits during development\n- Mocked test suite that doesn't require live proxy access\n- Live integration test flag (`BRIGHTDATA_LIVE=1`)\n\n## Error Handling\n\n| Error | Cause | Solution |\n|-------|-------|----------|\n| `Missing BRIGHTDATA_* vars` | No `.env.local` | Copy from `.env.example` |\n| Cache stale | Old cached HTML | Delete `.scrape-cache\u002F` directory |\n| Mock not working | Import order | Use `vi.mock()` before dynamic imports |\n| SSL errors in tests | CA cert path | Tests use mocks, not live proxy |\n\n## Resources\n\n- [Bright Data Proxy Docs](https:\u002F\u002Fdocs.brightdata.com\u002Fgeneral\u002Faccount\u002Fproxy-infrastructure)\n- [Vitest Documentation](https:\u002F\u002Fvitest.dev\u002F)\n- [tsx Documentation](https:\u002F\u002Fgithub.com\u002Fesbuild-kit\u002Ftsx)\n\n## Next Steps\n\nSee `brightdata-sdk-patterns` for production-ready code patterns.\n\n","# Bright Data Local Dev Loop\n\n## Overview\n\nSet up a fast, reproducible local development workflow for Bright Data scraping projects with mocked proxy responses, cached results, and vitest integration.\n\n## Prerequisites\n\n- Completed `brightdata-install-auth` setup\n- Node.js 18+ with npm\u002Fpnpm\n- brd-ca.crt SSL certificate downloaded\n\n## Instructions\n\n### Step 1: Create Project Structure\n\n```\nmy-scraper\u002F\n├── src\u002F\n│   ├── brightdata\u002F\n│   │   ├── proxy.ts         # Proxy configuration helper\n│   │   ├── scraper.ts       # Scraping functions\n│   │   └── cache.ts         # Response caching for dev\n│   └── index.ts\n├── tests\u002F\n│   ├── fixtures\u002F            # Cached HTML responses\n│   │   └── example.html\n│   └── scraper.test.ts\n├── .env.local               # Local credentials (git-ignored)\n├── .env.example             # Template for team\n├── brd-ca.crt               # Bright Data SSL cert (git-ignored)\n└── package.json\n```\n\n### Step 2: Build Proxy Configuration Module\n\n```typescript\n\u002F\u002F src\u002Fbrightdata\u002Fproxy.ts\nimport 'dotenv\u002Fconfig';\n\nexport interface BrightDataProxy {\n  host: string;\n  port: number;\n  auth: { username: string; password: string };\n}\n\nexport function getProxy(options?: {\n  country?: string;\n  city?: string;\n  session?: string;\n}): BrightDataProxy {\n  const { BRIGHTDATA_CUSTOMER_ID, BRIGHTDATA_ZONE, BRIGHTDATA_ZONE_PASSWORD } = process.env;\n  if (!BRIGHTDATA_CUSTOMER_ID || !BRIGHTDATA_ZONE || !BRIGHTDATA_ZONE_PASSWORD) {\n    throw new Error('Missing BRIGHTDATA_* environment variables');\n  }\n\n  let username = `brd-customer-${BRIGHTDATA_CUSTOMER_ID}-zone-${BRIGHTDATA_ZONE}`;\n  if (options?.country) username += `-country-${options.country}`;\n  if (options?.city) username += `-city-${options.city}`;\n  if (options?.session) username += `-session-${options.session}`;\n\n  return {\n    host: 'brd.superproxy.io',\n    port: 33335,\n    auth: { username, password: BRIGHTDATA_ZONE_PASSWORD },\n  };\n}\n```\n\n### Step 3: Add Response Cache for Development\n\n```typescript\n\u002F\u002F src\u002Fbrightdata\u002Fcache.ts — cache scraped pages to avoid burning proxy credits\nimport { createHash } from 'crypto';\nimport { existsSync, readFileSync, writeFileSync, mkdirSync } from 'fs';\nimport { join } from 'path';\n\nconst CACHE_DIR = join(process.cwd(), '.scrape-cache');\n\nexport function getCachedResponse(url: string): string | null {\n  const key = createHash('md5').update(url).digest('hex');\n  const path = join(CACHE_DIR, `${key}.html`);\n  return existsSync(path) ? readFileSync(path, 'utf-8') : null;\n}\n\nexport function setCachedResponse(url: string, html: string): void {\n  mkdirSync(CACHE_DIR, { recursive: true });\n  const key = createHash('md5').update(url).digest('hex');\n  writeFileSync(join(CACHE_DIR, `${key}.html`), html);\n}\n```\n\n### Step 4: Configure Testing with Mocked Responses\n\n```typescript\n\u002F\u002F tests\u002Fscraper.test.ts\nimport { describe, it, expect, vi, beforeEach } from 'vitest';\nimport axios from 'axios';\n\nvi.mock('axios');\nconst mockedAxios = vi.mocked(axios);\n\ndescribe('Bright Data Scraper', () => {\n  beforeEach(() => vi.clearAllMocks());\n\n  it('should scrape through proxy and return HTML', async () => {\n    mockedAxios.get.mockResolvedValueOnce({\n      status: 200,\n      data: '\u003Chtml>\u003Chead>\u003Ctitle>Test\u003C\u002Ftitle>\u003C\u002Fhead>\u003C\u002Fhtml>',\n    });\n\n    const { scrape } = await import('..\u002Fsrc\u002Fbrightdata\u002Fscraper');\n    const html = await scrape('https:\u002F\u002Fexample.com');\n    expect(html).toContain('\u003Ctitle>Test\u003C\u002Ftitle>');\n\n    \u002F\u002F Verify proxy was configured\n    expect(mockedAxios.get).toHaveBeenCalledWith(\n      'https:\u002F\u002Fexample.com',\n      expect.objectContaining({\n        proxy: expect.objectContaining({ host: 'brd.superproxy.io' }),\n      }),\n    );\n  });\n\n  it('should retry on 502 proxy errors', async () => {\n    mockedAxios.get\n      .mockRejectedValueOnce({ response: { status: 502 } })\n      .mockResolvedValueOnce({ status: 200, data: '\u003Chtml>OK\u003C\u002Fhtml>' });\n\n    const { scrapeWithRetry } = await import('..\u002Fsrc\u002Fbrightdata\u002Fscraper');\n    const html = await scrapeWithRetry('https:\u002F\u002Fexample.com');\n    expect(html).toContain('OK');\n    expect(mockedAxios.get).toHaveBeenCalledTimes(2);\n  });\n});\n```\n\n### Step 5: Package Scripts\n\n```json\n{\n  \"scripts\": {\n    \"dev\": \"tsx watch src\u002Findex.ts\",\n    \"scrape\": \"tsx src\u002Findex.ts\",\n    \"test\": \"vitest\",\n    \"test:watch\": \"vitest --watch\",\n    \"test:live\": \"BRIGHTDATA_LIVE=1 vitest --testPathPattern=integration\"\n  }\n}\n```\n\n## Output\n\n- Proxy config module with geo-targeting support\n- Response cache to avoid burning credits during development\n- Mocked test suite that doesn't require live proxy access\n- Live integration test flag (`BRIGHTDATA_LIVE=1`)\n\n## Error Handling\n\n| Error | Cause | Solution |\n|-------|-------|----------|\n| `Missing BRIGHTDATA_* vars` | No `.env.local` | Copy from `.env.example` |\n| Cache stale | Old cached HTML | Delete `.scrape-cache\u002F` directory |\n| Mock not working | Import order | Use `vi.mock()` before dynamic imports |\n| SSL errors in tests | CA cert path | Tests use mocks, not live proxy |\n\n## Resources\n\n- [Bright Data Proxy Docs](https:\u002F\u002Fdocs.brightdata.com\u002Fgeneral\u002Faccount\u002Fproxy-infrastructure)\n- [Vitest Documentation](https:\u002F\u002Fvitest.dev\u002F)\n- [tsx Documentation](https:\u002F\u002Fgithub.com\u002Fesbuild-kit\u002Ftsx)\n\n## Next Steps\n\nSee `brightdata-sdk-patterns` for production-ready code patterns.\n\n",{"name":5,"tags":44,"author":47,"license":15,"version":48,"description":49,"allowed-tools":50,"compatible-with":51},[45,31,46,22],"saas","data","Jeremy Longshore \u003Cjeremy@intentsolutions.io>","1.0.0","Configure Bright Data local development with hot reload and testing.\nUse when setting up a development environment, configuring test workflows,\nor establishing a fast iteration cycle with Bright Data.\nTrigger with phrases like \"brightdata dev setup\", \"brightdata local development\",\n\"brightdata dev environment\", \"develop with brightdata\".\n","Read, Write, Edit, Bash(npm:*), Bash(pnpm:*), Grep","claude-code","main","def8531e65114c0fca8fb8551c1871ee0eed705c","skills\u002Fjeremylongshore\u002Fclaude-code-plugins-plus-skills\u002Fbrightdata-local-dev-loop",24,"https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub","https:\u002F\u002Fskillshub.wtf","https:\u002F\u002Fgithub.com\u002FComeOnOliver","AI & Blockchain Engineer\r\n","2026-06-24 22:07:19",{"source":8,"skillName":5,"commands":62,"prompt":72,"zipAvailable":73},[63,66,69],{"tool":64,"command":65},"npx","npx skills add ComeOnOliver\u002Fskillshub --skill brightdata-local-dev-loop",{"tool":67,"command":68},"bunx","bunx skills add ComeOnOliver\u002Fskillshub --skill brightdata-local-dev-loop",{"tool":70,"command":71},"pnpm","pnpm dlx skills add ComeOnOliver\u002Fskillshub --skill brightdata-local-dev-loop","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fjeremylongshore\u002Fclaude-code-plugins-plus-skills\u002Fbrightdata-local-dev-loop\u002FSKILL.md",true,[],[76,85,94,103,109,115],{"skillNo":77,"name":78,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":39},"01M6FKJN13GMG4KY57J3QD8GY5","model-hierarchy-skill","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzscole\u002Fmodel-hierarchy-skill\u002Fmodel-hierarchy-skill\u002FSKILL.md",[],[82,83,84],"model","model hierarchy","model hierarchy skill",{"skillNo":86,"name":87,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":88,"categories":89,"keywords":90,"publishedAt":39},"01M6FKJJJ6GCAMR4PPPRD12M5X","zoom-mcp","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-mcp\u002FSKILL.md",[],[91,92,93],"MCP","zoom","zoom mcp",{"skillNo":95,"name":96,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":97,"categories":98,"keywords":99,"publishedAt":39},"01M6FKJE3KYT3KPEZMEEHYKA6K","zoom-apps-sdk","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fzoom-apps-sdk\u002FSKILL.md",[],[100,101,102,92],"sdk","zoom apps sdk","apps",{"skillNo":104,"name":105,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":39},"01M6FKJ9EDH9Q5VWDF8HAJRSP0","windows","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwindows\u002FSKILL.md",[],[105],{"skillNo":110,"name":111,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":112,"categories":113,"keywords":114,"publishedAt":39},"01M6FKJ666BEEFC3AE9GJ72Q93","whiteboard","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwhiteboard\u002FSKILL.md",[],[111],{"skillNo":116,"name":117,"nameZh":6,"description":6,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":118,"categories":119,"keywords":120,"publishedAt":39},"01M6FKJ21WFCDGTJQ2Q91T9DVW","websockets","https:\u002F\u002Fgithub.com\u002FComeOnOliver\u002Fskillshub\u002Fblob\u002Fmain\u002Fskills\u002Fzoom\u002Fskills\u002Fwebsockets\u002FSKILL.md",[],[117]]