brightdata-cost-tuning
Optimize Bright Data costs through tier selection, sampling, and usage monitoring. Use when analyzing Bright Data billing, reducing API costs, or implementing usage monitoring and budget alerts. Trigger with phrases like "brightdata cost", "brightdata billing", "reduce brightdata costs", "brightdata pricing", "brightdata expensive", "brightdata budget".
Best use case
brightdata-cost-tuning is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Optimize Bright Data costs through tier selection, sampling, and usage monitoring. Use when analyzing Bright Data billing, reducing API costs, or implementing usage monitoring and budget alerts. Trigger with phrases like "brightdata cost", "brightdata billing", "reduce brightdata costs", "brightdata pricing", "brightdata expensive", "brightdata budget".
Teams using brightdata-cost-tuning 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
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/brightdata-cost-tuning/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How brightdata-cost-tuning Compares
| Feature / Agent | brightdata-cost-tuning | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Optimize Bright Data costs through tier selection, sampling, and usage monitoring. Use when analyzing Bright Data billing, reducing API costs, or implementing usage monitoring and budget alerts. Trigger with phrases like "brightdata cost", "brightdata billing", "reduce brightdata costs", "brightdata pricing", "brightdata expensive", "brightdata budget".
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
AI Agents for Coding
Browse AI agent skills for coding, debugging, testing, refactoring, code review, and developer workflows across Claude, Cursor, and Codex.
Best AI Skills for Claude
Explore the best AI skills for Claude and Claude Code across coding, research, workflow automation, documentation, and agent operations.
ChatGPT vs Claude for Agent Skills
Compare ChatGPT and Claude for AI agent skills across coding, writing, research, and reusable workflow execution.
SKILL.md Source
# Bright Data Cost Tuning
## Overview
Optimize Bright Data costs through product selection, caching, and usage monitoring. Bright Data charges per request (Web Unlocker, SERP API), per GB (Residential Proxy), or per page (Datasets). Choosing the right product and avoiding redundant requests is the primary cost lever.
## Prerequisites
- Access to Bright Data billing dashboard
- Understanding of current scraping volumes
- Usage monitoring configured (optional)
## Pricing Model
| Product | Pricing | Typical Cost | Best For |
|---------|---------|-------------|----------|
| Residential Proxy | Per GB transferred | $8-15/GB | High-volume, simple pages |
| Web Unlocker | Per successful request | $1-3/1000 req | Anti-bot protected sites |
| Scraping Browser | Per browser session | $5-10/1000 sessions | JS-heavy SPAs |
| SERP API | Per search | $2-5/1000 searches | Search engine results |
| Datasets (pre-built) | Per record | $0.001-0.01/record | Bulk data (Amazon, LinkedIn) |
| Web Scraper API | Per page | Varies by dataset | Custom async scraping |
## Instructions
### Step 1: Product Selection Cost Matrix
```typescript
function estimateMonthlyCost(config: {
product: 'residential' | 'web_unlocker' | 'scraping_browser' | 'serp_api';
requestsPerMonth: number;
avgPageSizeKB?: number;
}) {
switch (config.product) {
case 'residential':
const gbTransferred = (config.requestsPerMonth * (config.avgPageSizeKB || 200)) / 1_000_000;
return { cost: gbTransferred * 10, unit: 'GB', quantity: gbTransferred };
case 'web_unlocker':
return { cost: config.requestsPerMonth * 0.002, unit: 'requests', quantity: config.requestsPerMonth };
case 'scraping_browser':
return { cost: config.requestsPerMonth * 0.008, unit: 'sessions', quantity: config.requestsPerMonth };
case 'serp_api':
return { cost: config.requestsPerMonth * 0.003, unit: 'searches', quantity: config.requestsPerMonth };
}
}
// Example: 50,000 product pages/month
console.log(estimateMonthlyCost({ product: 'web_unlocker', requestsPerMonth: 50000 }));
// { cost: 100, unit: 'requests', quantity: 50000 }
console.log(estimateMonthlyCost({ product: 'residential', requestsPerMonth: 50000, avgPageSizeKB: 300 }));
// { cost: 150, unit: 'GB', quantity: 15 }
```
### Step 2: Reduce Costs with Caching
```typescript
// Response caching is the single biggest cost saver
// Cache policy by data freshness requirements
const CACHE_TTLS = {
product_price: 3600000, // 1 hour — prices change frequently
product_details: 86400000, // 24 hours — descriptions rarely change
search_results: 1800000, // 30 minutes — SERPs change often
static_page: 604800000, // 7 days — about/contact pages
};
// Track cache savings
let cacheSavings = 0;
function trackCacheHit(product: string) {
const costPerRequest = { web_unlocker: 0.002, scraping_browser: 0.008, serp_api: 0.003 };
cacheSavings += costPerRequest[product] || 0.002;
console.log(`Cache savings this session: $${cacheSavings.toFixed(4)}`);
}
```
### Step 3: Use Bulk APIs for Volume Jobs
```typescript
// Individual requests: 50,000 requests * $0.002 = $100
// Web Scraper API: 1 trigger with 50,000 URLs = typically cheaper (volume discounts)
async function bulkScrapeForCost(urls: string[]) {
// Batch into single trigger — one API call, lower cost
const response = await fetch(
`https://api.brightdata.com/datasets/v3/trigger?dataset_id=${DATASET_ID}&format=json`,
{
method: 'POST',
headers: {
'Authorization': `Bearer ${process.env.BRIGHTDATA_API_TOKEN}`,
'Content-Type': 'application/json',
},
body: JSON.stringify(urls.map(url => ({ url }))),
}
);
return response.json();
}
```
### Step 4: Usage Monitoring
```typescript
class BrightDataUsageTracker {
private dailyRequests = 0;
private dailyCost = 0;
private readonly budgetAlert: number;
constructor(dailyBudgetUSD: number) {
this.budgetAlert = dailyBudgetUSD * 0.8;
}
track(product: string) {
this.dailyRequests++;
const costs = { web_unlocker: 0.002, scraping_browser: 0.008, serp_api: 0.003, residential: 0.0001 };
this.dailyCost += costs[product] || 0.002;
if (this.dailyCost > this.budgetAlert) {
console.warn(`BUDGET ALERT: Daily cost $${this.dailyCost.toFixed(2)} exceeds 80% of budget`);
}
}
report() {
return {
requests: this.dailyRequests,
estimatedCost: `$${this.dailyCost.toFixed(2)}`,
projectedMonthly: `$${(this.dailyCost * 30).toFixed(2)}`,
};
}
}
```
### Step 5: Cost Reduction Checklist
- [ ] Cache responses to avoid re-scraping same URLs
- [ ] Use Residential Proxy for simple pages (cheaper per request)
- [ ] Use Web Scraper API for 100+ URL bulk jobs
- [ ] Use Datasets API for common targets (Amazon, LinkedIn) — pre-built scrapers
- [ ] Set budget alerts in Bright Data CP > Billing
- [ ] Monitor daily usage with tracker class above
- [ ] Avoid Scraping Browser for pages that don't need JavaScript
## Output
- Product selection matching cost requirements
- Response caching reducing redundant requests
- Budget monitoring and alerting
- Projected monthly cost estimates
## Error Handling
| Issue | Cause | Solution |
|-------|-------|----------|
| Unexpected charges | Using expensive product for simple pages | Switch to Residential Proxy |
| Budget exceeded | No monitoring | Implement usage tracker |
| Overpaying for data | Scraping what Datasets API provides | Check pre-built datasets first |
| High per-request cost | No caching | Add response cache (biggest lever) |
## Resources
- [Bright Data Pricing](https://brightdata.com/pricing)
- [Billing Dashboard](https://brightdata.com/cp/billing)
- [Pre-built Datasets](https://brightdata.com/products/datasets)
## Next Steps
For architecture patterns, see `brightdata-reference-architecture`.Related Skills
workhuman-performance-tuning
Workhuman performance tuning for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman performance tuning".
workhuman-cost-tuning
Workhuman cost tuning for employee recognition and rewards API. Use when integrating Workhuman Social Recognition, or building recognition workflows with HRIS systems. Trigger: "workhuman cost tuning".
wispr-performance-tuning
Wispr Flow performance tuning for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr performance tuning".
wispr-cost-tuning
Wispr Flow cost tuning for voice-to-text API integration. Use when integrating Wispr Flow dictation, WebSocket streaming, or building voice-powered applications. Trigger: "wispr cost tuning".
windsurf-performance-tuning
Optimize Windsurf IDE performance: indexing speed, Cascade responsiveness, and memory usage. Use when Windsurf is slow, indexing takes too long, Cascade times out, or the IDE uses too much memory. Trigger with phrases like "windsurf slow", "windsurf performance", "optimize windsurf", "windsurf memory", "cascade slow", "indexing slow".
windsurf-cost-tuning
Optimize Windsurf licensing costs through seat management, tier selection, and credit monitoring. Use when analyzing Windsurf billing, reducing per-seat costs, or implementing usage monitoring and budget controls. Trigger with phrases like "windsurf cost", "windsurf billing", "reduce windsurf costs", "windsurf pricing", "windsurf budget".
webflow-performance-tuning
Optimize Webflow API performance with response caching, bulk endpoint batching, CDN-cached live item reads, pagination optimization, and connection pooling. Use when experiencing slow API responses or optimizing request throughput. Trigger with phrases like "webflow performance", "optimize webflow", "webflow latency", "webflow caching", "webflow slow", "webflow batch".
webflow-cost-tuning
Optimize Webflow costs through plan selection, CDN read optimization, bulk endpoint usage, and API usage monitoring with budget alerts. Use when analyzing Webflow billing, reducing API costs, or implementing usage monitoring for Webflow integrations. Trigger with phrases like "webflow cost", "webflow billing", "reduce webflow costs", "webflow pricing", "webflow budget".
vercel-performance-tuning
Optimize Vercel deployment performance with caching, bundle optimization, and cold start reduction. Use when experiencing slow page loads, optimizing Core Web Vitals, or reducing serverless function cold start times. Trigger with phrases like "vercel performance", "optimize vercel", "vercel latency", "vercel caching", "vercel slow", "vercel cold start".
vercel-cost-tuning
Optimize Vercel costs through plan selection, function efficiency, and usage monitoring. Use when analyzing Vercel billing, reducing function execution costs, or implementing spend management and budget alerts. Trigger with phrases like "vercel cost", "vercel billing", "reduce vercel costs", "vercel pricing", "vercel expensive", "vercel budget".
veeva-performance-tuning
Veeva Vault performance tuning for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva performance tuning".
veeva-cost-tuning
Veeva Vault cost tuning for REST API and clinical operations. Use when working with Veeva Vault document management and CRM. Trigger: "veeva cost tuning".