[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"blog-post-tr-deno-ve-bun-proxy-kullanimi":3},{"success":4,"payload":5,"related":67,"errors":162},true,{"id":6,"slug":7,"title":8,"excerpt":9,"body_html":10,"meta_title":11,"meta_description":12,"canonical_url":13,"canonical_override":14,"og_title":15,"og_description":16,"og_image_url":17,"faq_json":18,"key_takeaways":28,"allow_index":34,"noindex_google_only":34,"allow_follow":4,"published_at":35,"updated_at":35,"content_updated_at":36,"featured_image_url":37,"featured_image_alt":38,"card_image_url":39,"reading_time_minutes":40,"author":41,"categories":45,"tags":52,"alternates":53,"locale_paths":57,"views":66},134,"deno-ve-bun-proxy-kullanimi","Deno ve Bun'da Proxy Kullanımı: Geliştirici Rehberi","Deno ve Bun'da fetch ile proxy kullanmanın yollarını, geo-targeting, sticky session, SOCKS5 ve production ipuçlarını kod örnekleriyle öğrenin.","\u003Cp>Deno ve Bun'da proxy kullanımı, modern JavaScript runtime'larında web scraping ve API istekleri yaparken karşılaşılan IP engellemelerini aşmanın en pratik yoludur. Node.js'in \u003Ccode>http.Agent\u003C\u002Fcode> veya \u003Ccode>https-proxy-agent\u003C\u002Fcode> paketlerine alışkın geliştiriciler, Deno ve Bun'a geçtiklerinde \u003Ccode>fetch()\u003C\u002Fcode>'in proxy'yi varsayılan olarak yok saydığını fark ederler. Bu rehber, Deno'da \u003Ccode>Deno.createHttpClient\u003C\u002Fcode> ve Bun'da \u003Ccode>fetch(url, { proxy })\u003C\u002Fcode> kullanarak residential proxy'leri nasıl yapılandıracağınızı, geo-targeting ve sticky session'ları nasıl kodlayacağınızı ve production'da karşılaşacağınız tuzakları nasıl aşacağınızı gösterir.\u003C\u002Fp>\n\n\u003Ch2>Deno ve Bun'da Proxy Kullanımı: Neden fetch() Proxy'leri Yok Sayar?\u003C\u002Fh2>\n\n\u003Cp>Web platformunun \u003Ccode>fetch()\u003C\u002Fcode> spesifikasyonu (\u003Ca href=\"https:\u002F\u002Ffetch.spec.whatwg.org\u002F\" rel=\"noopener noreferrer\">WHATWG Fetch Standard\u003C\u002Fa>), proxy yapılandırması tanımlamaz. Tarayıcılar proxy'yi işletim sistemi seviyesinde ele alır; JavaScript API'si buna müdahil olmaz. Bu nedenle hem Deno hem de Bun, \u003Ccode>fetch()\u003C\u002Fcode>'i proxy destekli olacak şekilde genişletir — ama farklı yollardan.\u003C\u002Fp>\n\n\u003Cp>Deno, \u003Ca href=\"https:\u002F\u002Fdocs.deno.com\u002Fapi\u002Fdeno\u002Ffetch\u002F#Deno.createHttpClient\" rel=\"noopener noreferrer\">Deno.createHttpClient\u003C\u002Fa> ile özel bir HTTP istemcisi oluşturur ve bunu \u003Ccode>fetch(url, { client })\u003C\u002Fcode> ile geçirir. Bun ise daha sade bir yaklaşım benimser: \u003Ccode>fetch(url, { proxy: 'http:\u002F\u002F...' })\u003C\u002Fcode> tek satırda proxy'yi devreye alır. Her iki yöntem de \u003Ccode>HTTP_PROXY\u003C\u002Fcode> ve \u003Ccode>HTTPS_PROXY\u003C\u002Fcode> ortam değişkenlerini destekler, ancak per-client yapılandırma her zaman ortam değişkenlerine tercih edilmelidir — çünkü aynı process içinde farklı proxy'ler kullanmanız gerekebilir.\u003C\u002Fp>\n\n\u003Ch2>Deno'da Deno.createHttpClient ile Proxy Kullanımı\u003C\u002Fh2>\n\n\u003Cp>Deno'da proxy kullanmak için önce bir \u003Ccode>HttpClient\u003C\u002Fcode> oluşturursunuz, ardından bunu \u003Ccode>fetch\u003C\u002Fcode>'in \u003Ccode>client\u003C\u002Fcode> seçeneğine geçirirsiniz. Proxy URL'si Basic Auth içerebilir ve \u003Ccode>basicAuth\u003C\u002Fcode> alanı ile kullanıcı adı\u002Fşifre ayrı da belirtilebilir.\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F deno-proxy.ts\n\u002F\u002F Çalıştırma: deno run --allow-net deno-proxy.ts\n\nconst PROXY_URL = &quot;http:\u002F\u002Fgate.proxyhat.com:8080&quot;;\nconst PROXY_USER = &quot;user-country-US-sid-abc123&quot;;\nconst PROXY_PASS = &quot;your_password&quot;;\n\nconst client = Deno.createHttpClient({\n  proxy: {\n    url: PROXY_URL,\n    basicAuth: {\n      username: PROXY_USER,\n      password: PROXY_PASS,\n    },\n  },\n  \u002F\u002F Özelleştirilmiş CA sertifikaları (kurumsal proxy veya self-signed TLS)\n  caCerts: Deno.readTextFileSync(&quot;.\u002Fcustom-ca.pem&quot;).split(\u002F-----END CERTIFICATE-----\u002F)\n    .filter(c =&gt; c.includes(&quot;BEGIN CERTIFICATE&quot;))\n    .map(c =&gt; c + &quot;-----END CERTIFICATE-----&quot;),\n});\n\ntry {\n  const res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, { client });\n  const data = await res.json();\n  console.log(&quot;Proxy IP:&quot;, data.origin);\n} catch (err) {\n  console.error(&quot;İstek başarısız:&quot;, err.message);\n} finally {\n  client.close(); \u002F\u002F Kaynak sızıntısını önle\n}\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Cp>Dikkat edin: \u003Ccode>user-country-US-sid-abc123\u003C\u002Fcode> formatı, ProxyHat'ın kullanıcı adı içinde hem geo-targeting hem de sticky session belirtmenin yoludur. Bu istek bir ABD IP'sinden gelir ve \u003Ccode>abc123\u003C\u002Fcode> session ID'si boyunca aynı IP kalır. \u003Ccode>client.close()\u003C\u002Fcode> çağrısı, Deno 1.38+ sürümlerinde connection pool'u serbest bırakır ve dosya tanımlayıcı sızıntısını önler.\u003C\u002Fp>\n\n\u003Ch3>Deno'da SOCKS5 Proxy\u003C\u002Fh3>\n\n\u003Cp>SOCKS5 gerektiğinde port \u003Ccode>1080\u003C\u002Fcode> kullanılır:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F deno-socks5.ts\nconst client = Deno.createHttpClient({\n  proxy: {\n    url: &quot;socks5:\u002F\u002Fgate.proxyhat.com:1080&quot;,\n    basicAuth: {\n      username: &quot;user-country-DE-region-state_of_berlin-city-berlin&quot;,\n      password: &quot;your_password&quot;,\n    },\n  },\n});\n\nconst res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, { client });\nconsole.log(await res.json());\nclient.close();\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Ch2>Bun'da fetch ile Proxy Kullanımı\u003C\u002Fh2>\n\n\u003Cp>Bun, proxy'yi \u003Ccode>fetch\u003C\u002Fcode>'in ikinci parametresine \u003Ccode>proxy\u003C\u002Fcode> anahtarı ile alır. Bu, Node.js'te \u003Ccode>https-proxy-agent\u003C\u002Fcode> kurmadan proxy kullanmanın en temiz yoludur.\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F bun-proxy.ts\n\u002F\u002F Çalıştırma: bun run bun-proxy.ts\n\nconst proxyUrl = &quot;http:\u002F\u002Fuser-country-DE-sid-sess01:pass@gate.proxyhat.com:8080&quot;;\n\ntry {\n  const res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, {\n    proxy: proxyUrl,\n  });\n  const data = await res.json();\n  console.log(&quot;Proxy IP:&quot;, data.origin);\n} catch (err) {\n  console.error(&quot;İstek başarısız:&quot;, err);\n}\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Cp>Bun'da SOCKS5 de aynı şekilde çalışır — sadece URL şemasını ve portu değiştirin:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F bun-socks5.ts\nconst res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, {\n  proxy: &quot;socks5:\u002F\u002Fuser-country-GB-sid-sess02:pass@gate.proxyhat.com:1080&quot;,\n});\nconsole.log(await res.json());\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Ch2>HTTP_PROXY \u002F HTTPS_PROXY Ortam Değişkenleri\u003C\u002Fh2>\n\n\u003Cp>Her iki runtime da \u003Ccode>HTTP_PROXY\u003C\u002Fcode> ve \u003Ccode>HTTPS_PROXY\u003C\u002Fcode> ortam değişkenlerini tanır. CLI araçları veya CI\u002FCD pipeline'larında bu yöntem pratiktir:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode># Terminal\nexport HTTPS_PROXY=&quot;http:\u002F\u002Fuser-country-US:pass@gate.proxyhat.com:8080&quot;\n\n# Deno\ndeno run --allow-net --allow-env script.ts\n\n# Bun\nbun run script.ts\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Cp>Ancak per-client yapılandırma, ortam değişkenlerine göre üç nedenden dolayı tercih edilir:\u003C\u002Fp>\n\n\u003Cul>\n  \u003Cli>\u003Cstrong>Farklı proxy'ler:\u003C\u002Fstrong> Aynı process içinde ABD ve Almanya proxy'si aynı anda kullanılabilir.\u003C\u002Fli>\n  \u003Cli>\u003Cstrong>Güvenlik:\u003C\u002Fstrong> Proxy kimlik bilgileri \u003Ccode>ps\u003C\u002Fcode> çıktısında görünmez.\u003C\u002Fli>\n  \u003Cli>\u003Cstrong>Test edilebilirlik:\u003C\u002Fstrong> Proxy URL'si kod içinde açıkça görünür, mock edilebilir.\u003C\u002Fli>\n\u003C\u002Ful>\n\n\u003Ch2>Residential Proxy'ler Neden Gerekli? Yüksek Engelleme Riski Olan Hedefler\u003C\u002Fh2>\n\n\u003Cp>Datacenter IP'leri, Cloudflare ve benzeri anti-bot sistemleri tarafından kolayca tanınır. Residential proxy'ler ise gerçek ISP'lerden gelir ve engelleme oranı önemli ölçüde düşüktür. Örneğin, e-ticaret fiyat izleme veya SERP scraping gibi görevlerde datacenter proxy'lerle başarı oranı %30-50'ye düşebilirken, residential proxy'lerle %90+ başarı oranı mümkündür.\u003C\u002Fp>\n\n\u003Cp>Aşağıdaki örnek, bir sticky session havuzunu eşzamanlı isteklerle döndürür ve her istek için \u003Ccode>AbortController\u003C\u002Fcode> ile 10 saniyelik timeout belirler:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F rotate-sessions.ts — Deno ve Bun&apos;da çalışır\n\nconst GATEWAY = &quot;gate.proxyhat.com:8080&quot;;\nconst PROXY_USER = &quot;your_user&quot;;\nconst PROXY_PASS = &quot;your_pass&quot;;\nconst TARGETS = [\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;,\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fheaders&quot;,\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fuser-agent&quot;,\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fuuid&quot;,\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fdelay\u002F2&quot;,\n];\n\n\u002F\u002F Her hedef için benzersiz sticky session ID oluştur\nfunction buildProxyUrl(sessionId: string, country = &quot;US&quot;): string {\n  return `http:\u002F\u002F${PROXY_USER}-country-${country}-sid-${sessionId}:${PROXY_PASS}@${GATEWAY}`;\n}\n\nasync function fetchWithTimeout(\n  url: string,\n  proxyUrl: string,\n  timeoutMs = 10000,\n): Promise&lt;{ ok: boolean; status: number; body: string; session: string }&gt; {\n  const controller = new AbortController();\n  const timer = setTimeout(() =&gt; controller.abort(), timeoutMs);\n\n  try {\n    \u002F\u002F Deno için client oluştur; Bun için proxy option&apos;ı kullan\n    const isDeno = typeof Deno !== &quot;undefined&quot; &amp;&amp; typeof Deno.createHttpClient === &quot;function&quot;;\n\n    let res: Response;\n    if (isDeno) {\n      const client = Deno.createHttpClient({\n        proxy: { url: proxyUrl },\n      });\n      res = await fetch(url, { client, signal: controller.signal });\n      client.close();\n    } else {\n      res = await fetch(url, { proxy: proxyUrl, signal: controller.signal });\n    }\n\n    const body = await res.text();\n    return { ok: res.ok, status: res.status, body, session: sessionId };\n  } catch (err) {\n    if (err.name === &quot;AbortError&quot;) {\n      return { ok: false, status: 0, body: &quot;TIMEOUT&quot;, session: sessionId };\n    }\n    throw err;\n  } finally {\n    clearTimeout(timer);\n  }\n}\n\n\u002F\u002F 5 eşzamanlı sticky session ile paralel istek\nconst sessionIds = Array.from({ length: TARGETS.length }, (_, i) =&gt; `sess-${Date.now()}-${i}`);\n\nconst results = await Promise.all(\n  TARGETS.map((url, i) =&gt; fetchWithTimeout(url, buildProxyUrl(sessionIds[i])))\n);\n\nfor (const r of results) {\n  console.log(`[${r.session}] ${r.status} — ${r.ok ? &quot;OK&quot; : &quot;FAIL&quot;} — ${r.body.slice(0, 80)}`);\n}\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Cp>Bu örnekte her istek farklı bir sticky session kullanır, böylece her biri farklı bir residential IP'den gelir. \u003Ccode>Promise.all\u003C\u002Fcode> ile eşzamanlı çalışır ve \u003Ccode>AbortController\u003C\u002Fcode> ile 10 saniye sonra takılı kalan istekler iptal edilir. 100 eşzamanlı session'a kadar ölçeklendirilebilir.\u003C\u002Fp>\n\n\u003Ch2>Production İpuçları: Retry, Backoff, Connection Reuse\u003C\u002Fh2>\n\n\u003Ch3>Exponential Backoff ile Retry\u003C\u002Fh3>\n\n\u003Cpre>\u003Ccode>\u002F\u002F retry.ts — Deno ve Bun uyumlu\n\nasync function fetchWithRetry(\n  url: string,\n  proxyUrl: string,\n  maxRetries = 3,\n  baseDelayMs = 1000,\n): Promise&lt;Response&gt; {\n  let lastError: Error | null = null;\n\n  for (let attempt = 0; attempt &lt;= maxRetries; attempt++) {\n    try {\n      const isDeno = typeof Deno !== &quot;undefined&quot; &amp;&amp; typeof Deno.createHttpClient === &quot;function&quot;;\n\n      if (isDeno) {\n        const client = Deno.createHttpClient({ proxy: { url: proxyUrl } });\n        const res = await fetch(url, { client });\n        client.close();\n        if (res.status === 429 || res.status &gt;= 500) {\n          throw new Error(`HTTP ${res.status}`);\n        }\n        return res;\n      } else {\n        const res = await fetch(url, { proxy: proxyUrl });\n        if (res.status === 429 || res.status &gt;= 500) {\n          throw new Error(`HTTP ${res.status}`);\n        }\n        return res;\n      }\n    } catch (err) {\n      lastError = err;\n      if (attempt &lt; maxRetries) {\n        const delay = baseDelayMs * Math.pow(2, attempt) + Math.random() * 500;\n        console.warn(`Deneme ${attempt + 1} başarısız: ${err.message}. ${Math.round(delay)}ms bekleniyor...`);\n        await new Promise(r =&gt; setTimeout(r, delay));\n      }\n    }\n  }\n\n  throw lastError;\n}\n\n\u002F\u002F Kullanım\nconst res = await fetchWithRetry(\n  &quot;https:\u002F\u002Fhttpbin.org\u002Fget&quot;,\n  &quot;http:\u002F\u002Fuser-country-US-sid-abc123:pass@gate.proxyhat.com:8080&quot;,\n);\nconsole.log(await res.json());\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Ch3>Connection Reuse ve Circuit Breaker\u003C\u002Fh3>\n\n\u003Cp>Deno'da \u003Ccode>Deno.createHttpClient\u003C\u002Fcode> ile oluşturulan client, connection pool'u yeniden kullanır. Aynı session ID ile birden çok istek yapıyorsanız, client'ı kapatmayın — yeniden kullanın. Bun'da ise \u003Ccode>fetch\u003C\u002Fcode> her çağrıda yeni bir bağlantı kurabilir; connection reuse için \u003Ccode>Bun.connect\u003C\u002Fcode> veya \u003Ccode>undici\u003C\u002Fcode> kullanmayı düşünebilirsiniz.\u003C\u002Fp>\n\n\u003Cp>Basit bir circuit breaker pattern'i:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F circuit-breaker.ts\nclass CircuitBreaker {\n  private failures = 0;\n  private lastFailureTime = 0;\n  private readonly threshold = 5;\n  private readonly resetTimeMs = 30000; \u002F\u002F 30 saniye\n\n  get isOpen(): boolean {\n    return this.failures &gt;= this.threshold &amp;&amp;\n      Date.now() - this.lastFailureTime &lt; this.resetTimeMs;\n  }\n\n  recordSuccess(): void {\n    this.failures = 0;\n  }\n\n  recordFailure(): void {\n    this.failures++;\n    this.lastFailureTime = Date.now();\n  }\n}\n\nconst breaker = new CircuitBreaker();\n\nasync function guardedFetch(url: string, proxyUrl: string): Promise&lt;Response&gt; {\n  if (breaker.isOpen) {\n    throw new Error(&quot;Circuit breaker açık — 30 saniye sonra tekrar deneyin&quot;);\n  }\n  try {\n    const isDeno = typeof Deno !== &quot;undefined&quot; &amp;&amp; typeof Deno.createHttpClient === &quot;function&quot;;\n    const res = isDeno\n      ? await fetch(url, { client: Deno.createHttpClient({ proxy: { url: proxyUrl } }) })\n      : await fetch(url, { proxy: proxyUrl });\n    breaker.recordSuccess();\n    return res;\n  } catch (err) {\n    breaker.recordFailure();\n    throw err;\n  }\n}\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Ch2>ProxyHat Node SDK ile Yan Yana Karşılaştırma\u003C\u002Fh2>\n\n\u003Cp>ProxyHat, hem Deno hem de Bun altında çalışan bir Node SDK'sı (\u003Ccode>proxyhat\u003C\u002Fcode>) sunar. SDK, API anahtarınızla aktif bir alt kullanıcının proxy URL'sini üretir (ülke, şehir, sticky session); isteği yine \u003Ccode>fetch\u003C\u002Fcode> gönderir. Aşağıda SDK kullanımı ve raw proxy ile karşılaştırması:\u003C\u002Fp>\n\n\u003Cpre>\u003Ccode>\u002F\u002F proxyhat-sdk.ts — Deno ve Bun&apos;da çalışır (npm: proxyhat)\n\u002F\u002F Kurulum — Bun: bun add proxyhat · Deno: deno add npm:proxyhat\nimport { ProxyHat } from &quot;proxyhat&quot;;\n\nconst ph = new ProxyHat({ apiKey: &quot;ph_your_api_key&quot; });\n\n\u002F\u002F SDK yalnızca proxy URL&apos;sini üretir (ülke + 10 dk sticky session); isteği fetch gönderir\nconst proxyUrl = await ph.connectionUrl({ country: &quot;us&quot;, sticky: &quot;10m&quot; });\n\nconst started = performance.now();\nlet res: Response;\nif (typeof Deno !== &quot;undefined&quot;) {\n  const u = new URL(proxyUrl);\n  const client = Deno.createHttpClient({\n    proxy: {\n      url: `${u.protocol}\u002F\u002F${u.host}`,\n      basicAuth: {\n        username: decodeURIComponent(u.username),\n        password: decodeURIComponent(u.password),\n      },\n    },\n  });\n  res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, { client });\n} else {\n  res = await fetch(&quot;https:\u002F\u002Fhttpbin.org\u002Fip&quot;, { proxy: proxyUrl });\n}\n\nconsole.log(await res.json());\nconsole.log(&quot;Geçen süre:&quot;, Math.round(performance.now() - started) + &quot;ms&quot;);\n\u003C\u002Fcode>\u003C\u002Fpre>\n\n\u003Ctable>\n  \u003Cthead>\n    \u003Ctr>\n      \u003Cth>Özellik\u003C\u002Fth>\n      \u003Cth>Raw fetch + proxy\u003C\u002Fth>\n      \u003Cth>ProxyHat SDK\u003C\u002Fth>\n    \u003C\u002Ftr>\n  \u003C\u002Fthead>\n  \u003Ctbody>\n    \u003Ctr>\n      \u003Ctd>Proxy URL yönetimi\u003C\u002Ftd>\n      \u003Ctd>Manuel string formatlama\u003C\u002Ftd>\n      \u003Ctd>Otomatik\u003C\u002Ftd>\n    \u003C\u002Ftr>\n    \u003Ctr>\n      \u003Ctd>Retry \u002F backoff\u003C\u002Ftd>\n      \u003Ctd>Kendi yazmanız gerekir\u003C\u002Ftd>\n      \u003Ctd>Yok — kendi yazmanız gerekir (yukarıdaki \u003Ccode>fetchWithRetry\u003C\u002Fcode>)\u003C\u002Ftd>\n    \u003C\u002Ftr>\n    \u003Ctr>\n      \u003Ctd>Session yönetimi\u003C\u002Ftd>\n      \u003Ctd>Manuel session ID üretimi\u003C\u002Ftd>\n      \u003Ctd>\u003Ccode>sticky: \"10m\"\u003C\u002Fcode> ile otomatik session ID\u003C\u002Ftd>\n    \u003C\u002Ftr>\n    \u003Ctr>\n      \u003Ctd>Metrik toplama\u003C\u002Ftd>\n      \u003Ctd>Yok\u003C\u002Ftd>\n      \u003Ctd>Yok\u003C\u002Ftd>\n    \u003C\u002Ftr>\n    \u003Ctr>\n      \u003Ctd>SOCKS5 desteği\u003C\u002Ftd>\n      \u003Ctd>Port 1080 ile manuel\u003C\u002Ftd>\n      \u003Ctd>\u003Ccode>protocol: \"socks5\"\u003C\u002Fcode> (port 1080)\u003C\u002Ftd>\n    \u003C\u002Ftr>\n    \u003Ctr>\n      \u003Ctd>CA sertifika yapılandırması\u003C\u002Ftd>\n      \u003Ctd>Deno'da caCerts, Bun'da yok\u003C\u002Ftd>\n      \u003Ctd>Yok — runtime ayarı (Deno: \u003Ccode>caCerts\u003C\u002Fcode>)\u003C\u002Ftd>\n    \u003C\u002Ftr>\n  \u003C\u002Ftbody>\n\u003C\u002Ftable>\n\n\u003Cp>SDK, \u003Ca href=\"https:\u002F\u002Fdocs.proxyhat.com\u002F\" rel=\"noopener noreferrer\">ProxyHat dokümantasyonunda\u003C\u002Fa> ayrıntılı açıklanmıştır. SDK, kimlik bilgilerini ve hedefleme sözdizimini elle yazma ihtiyacını ortadan kaldırır; retry, bağlantı yönetimi ve metrikler ise sizin kodunuzda kalır. \u003Ca href=\"\u002Ftr\u002Fpricing\">ProxyHat fiyatlandırması\u003C\u002Fa> sayfasından residential ve mobile planları karşılaştırılabilir.\u003C\u002Fp>\n\n\u003Ch2>EtiK Scraping: Yasal ve Etik Hususlar\u003C\u002Fh2>\n\n\u003Cp>Proxy kullanımı güçlü bir araçtır, ancak sorumlu kullanılmalıdır. İşte temel ilkeler:\u003C\u002Fp>\n\n\u003Cul>\n  \u003Cli>\u003Cstrong>Önce resmi API'yi kontrol edin:\u003C\u002Fstrong> Bir hedefin API'si varsa, scraping yerine onu kullanın. Daha hızlı, daha güvenilir ve yasal olarak daha güvenlidir.\u003C\u002Fli>\n  \u003Cli>\u003Cstrong>robots.txt'ye saygı gösterin:\u003C\u002Fstrong> \u003Ccode>\u002Frobots.txt\u003C\u002Fcode> dosyası, hangi yolların taranmaması gerektiğini belirtir. Bu kurallara uymak etik bir gerekliliktir.\u003C\u002Fli>\n  \u003Cli>Rate limit'e uyun: Saniyede 1-2 istek gibi makul bir hız tutun. Hedef sunucuyu DDoS etmeyin.\u003C\u002Fli>\n  \u003Cli>ABD'de CFAA: \u003Ca href=\"https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FComputer_Fraud_and_Abuse_Act\" rel=\"noopener noreferrer\">Computer Fraud and Abuse Act\u003C\u002Fa>, yetkisiz erişimi suç sayar. Public veri toplamak genellikle sorun değil, ancak ToS ihlali dava riski taşıyabilir.\u003C\u002Fli>\n  \u003Cli>AB'de GDPR: Kişisel veri içeren içerik topluyorsanız, GDPR uyumluluğu gerekir. IP adresleri bile kişisel veri sayılır.\u003C\u002Fli>\n  \u003Cli>Sadece public veri: Login arkasındaki verileri scraping yapmayın; bu ToS ihlali olabilir.\u003C\u002Fli>\n\u003C\u002Ful>\n\n\u003Cp>Daha fazla bilgi için \u003Ca href=\"\u002Ftr\u002Fuse-cases\u002Fweb-scraping\">web scraping kullanım senaryosu\u003C\u002Fa> ve \u003Ca href=\"\u002Ftr\u002Fuse-cases\u002Fserp-tracking\">SERP takibi\u003C\u002Fa> sayfalarımıza bakabilirsiniz. ProxyHat'ın \u003Ca href=\"\u002Ftr\u002Flocations\">lokasyon sayfası\u003C\u002Fa> üzerinden 190+ ülkedeki residential IP havuzunu inceleyebilirsiniz.\u003C\u002Fp>","Deno ve Bun'da Proxy Kullanımı: Geliştirici Rehberi | ProxyHat","Deno ve Bun'da proxy kullanımı için pratik rehber. Deno.createHttpClient ve Bun fetch proxy örnekleri, geo-targeting, sticky sessions ve production ipuçları.","\u002Ftr\u002Fblog\u002Fdeno-ve-bun-proxy-kullanimi",null,"Deno ve Bun'da Proxy Kullanımı | ProxyHat","Deno ve Bun'da fetch ile proxy kullanımı: Deno.createHttpClient, Bun fetch proxy, geo-targeting, sticky sessions ve production ipuçları.","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fdeno-ve-bun-proxy-kullanimi-og.webp",[19,22,25],{"question":20,"answer":21},"Deno ve Bun'da proxy kullanımı neden önemlidir?","Web scraping, SERP takibi ve fiyat izleme gibi görevlerde tek bir IP hızlıca engellenir. Proxy kullanımı, istekleri farklı IP'lerden dağıtarak block riskini azaltır, geo-targeting ile bölgesel içeriklere erişim sağlar ve rate limitlerini aşmanıza yardımcı olur. Deno ve Bun gibi modern runtime'larda proxy desteği native API'lerle gelir.",{"question":23,"answer":24},"Deno ve Bun'da proxy kullanımı için en iyi proxy tipi nedir?","Yüksek engelleme riski olan hedefler için residential proxy en iyi seçenektir, çünkü gerçek ISP IP'lerinden gelir ve datacenter proxy'lere göre daha az engellenir. Düşük latency gerektiren durumlarda datacenter proxy tercih edilebilir. Mobil proxy ise en yüksek güvenilirliği sunar ancak maliyeti daha yüksektir.",{"question":26,"answer":27},"Deno ve Bun'da proxy kullanırken blokları nasıl önlersiniz?","Sticky session ile IP rotasyonu yapın, geo-targeting kullanın, rate limit'e uyun, uygun User-Agent ve header'lar gönderin, retries ile backoff uygulayın ve AbortController ile timeout belirleyin. Ayrıca robots.txt kurallarına saygı gösterin ve mümkünse resmi API'leri tercih edin.",[29,30,31,32,33],"Deno'da proxy için Deno.createHttpClient ile özel istemci oluşturup fetch'e { client } olarak geçirin; işiniz bitince client.close() çağırın.","Bun'da proxy kullanımı daha sadedir: fetch(url, { proxy: 'http:\u002F\u002F...' }) tek satırda proxy'yi devreye alır, SOCKS5 için sadece şemayı değiştirin.","Per-client proxy yapılandırması, HTTP_PROXY ortam değişkenlerine tercih edilmelidir; aynı process'te farklı proxy'ler kullanmaya ve güvenliğe olanak tanır.","Residential proxy'ler datacenter IP'lere göre çok daha düşük engelleme oranı sunar; kullanıcı adı içinde geo-targeting ve sticky session belirtilebilir.","Production'da exponential backoff ile retry, AbortController ile timeout ve circuit breaker pattern'i kullanarak güvenilirliği artırın.",false,"2026-07-03T16:04:32+00:00","2026-11-17T10:13:54+00:00","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fdeno-ve-bun-proxy-kullanimi-master.webp","Using Proxies in Deno and Bun: A Code-First Guide for Modern JavaScript","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fdeno-ve-bun-proxy-kullanimi-card.webp",11,{"name":42,"slug":43,"bio":44,"avatar_url":14,"website_url":14,"social_links":14},"ProxyHat Team","proxyhat-team","The ProxyHat editorial team covers proxies, web scraping, and data extraction.",[46],{"id":47,"slug":48,"name":49,"description":14,"meta_title":50,"meta_description":51,"parent_id":14},4,"gelistirici-rehberleri","Geliştirici Rehberleri","Geliştirici Rehberleri | ProxyHat Blog","Proxy entegrasyonu için kod eğitimleri ve SDK rehberleri.",[],{"de":54,"ko":55,"en":56,"x-default":56},"\u002Fde\u002Fblog\u002Fproxys-in-deno-und-bun-nutzen","\u002Fko\u002Fblog\u002Fdeno-bun-proxy-fetch-gaide","\u002Fblog\u002Fusing-proxies-in-deno-and-bun",{"de":54,"fr":58,"pt":59,"es":60,"ko":55,"ru":61,"pl":62,"zh":63,"tr":13,"ja":64,"en":56,"it":65},"\u002Ffr\u002Fblog\u002Futiliser-proxies-deno-bun","\u002Fpt\u002Fblog\u002Fusar-proxies-deno-bun","\u002Fes\u002Fblog\u002Fusar-proxies-deno-bun-guia","\u002Fru\u002Fblog\u002Fispolzovanie-proksi-deno-bun-1","\u002Fpl\u002Fblog\u002Fuzywanie-proxy-w-deno-i-bun","\u002Fcn\u002Fblog\u002Fdeno-bun-daili-peizhi","\u002Fja\u002Fblog\u002Fdeno-bun-purokushi-gaido","\u002Fit\u002Fblog\u002Fproxy-deno-bun-guida",196,[68,102,129,146],{"id":69,"slug":70,"title":71,"excerpt":72,"featured_image_url":73,"featured_image_alt":74,"card_image_url":75,"og_image_url":76,"published_at":77,"updated_at":78,"content_updated_at":79,"reading_time_minutes":80,"is_featured":34,"indexable":4,"views":81,"author":82,"categories":83,"tags":85},210,"ai-ajanlari-icin-proxy-kurulumu","AI Ajanları için Proxy Kurulumu: browser-use, Crawl4AI ve MCP","Bulut VM'lerindeki ajanlar internete datacenter IP'lerinden çıkar. browser-use, Crawl4AI ve bir MCP sunucusu için güncel, çalışan proxy yapılandırmalarını; sticky ve rotasyon için bir karar tablosunu ve kaçınılması gereken maliyet tuzaklarını derledik.","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fai-ajanlari-icin-proxy-kurulumu-master.webp","Proxy Setup for AI Agents: browser-use, Crawl4AI and an MCP Server","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fai-ajanlari-icin-proxy-kurulumu-card.webp","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fai-ajanlari-icin-proxy-kurulumu-og.webp","2026-10-24T09:00:00+00:00","2026-10-24T09:00:20+00:00","2026-10-03T09:41:40+00:00",14,39,{"name":42,"slug":43,"bio":44,"avatar_url":14,"website_url":14,"social_links":14},[84],{"id":47,"slug":48,"name":49,"description":14,"meta_title":50,"meta_description":51,"parent_id":14},[86,90,94,98],{"id":87,"slug":88,"name":89},1,"web-scraping","Web Scraping",{"id":91,"slug":92,"name":93},2,"residential-proxy","Residential Proxy",{"id":95,"slug":96,"name":97},9,"python","Python",{"id":99,"slug":100,"name":101},22,"playwright","Playwright",{"id":103,"slug":104,"title":105,"excerpt":106,"featured_image_url":107,"featured_image_alt":108,"card_image_url":109,"og_image_url":110,"published_at":111,"updated_at":112,"content_updated_at":79,"reading_time_minutes":80,"is_featured":34,"indexable":4,"views":113,"author":114,"categories":115,"tags":117},206,"camoufox-residential-proxy-python-rehberi","Camoufox ve Residential Proxy: Kod Odaklı Python Rehberi","C++ düzeyinde yamalanmış Firefox olan Camoufox'u residential proxy arkasında çalıştırma: güncel Python API'si, geoip'in neden sabit oturum gerektirdiği, parmak izi tutarlılık listesi ve Patchright ya da nodriver'ın ne zaman daha uygun olduğu.","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcamoufox-residential-proxy-python-rehberi-master.webp","Camoufox with Residential Proxies: A Code-First Python Guide","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcamoufox-residential-proxy-python-rehberi-card.webp","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcamoufox-residential-proxy-python-rehberi-og.webp","2026-10-13T09:00:00+00:00","2026-10-13T09:00:22+00:00",48,{"name":42,"slug":43,"bio":44,"avatar_url":14,"website_url":14,"social_links":14},[116],{"id":47,"slug":48,"name":49,"description":14,"meta_title":50,"meta_description":51,"parent_id":14},[118,119,120,124,125],{"id":87,"slug":88,"name":89},{"id":91,"slug":92,"name":93},{"id":121,"slug":122,"name":123},6,"anti-tespit","Anti-Tespit",{"id":95,"slug":96,"name":97},{"id":126,"slug":127,"name":128},21,"headless-tarayici","Headless Tarayıcı",{"id":130,"slug":131,"title":132,"excerpt":133,"featured_image_url":134,"featured_image_alt":135,"card_image_url":136,"og_image_url":137,"published_at":138,"updated_at":138,"content_updated_at":139,"reading_time_minutes":140,"is_featured":34,"indexable":34,"views":141,"author":142,"categories":143,"tags":145},176,"nodejs-got-scraping-proxy-rehberi","Node.js'de got-scraping ile Proxy Tabanlı Web Scraping Rehberi","Node.js'de got-scraping kütüphanesinin header-generator, HTTP\u002F2 ve proxy desteğini üretim ölçeğinde nasıl kullanacağınızı öğrenin. Residential proxy rotation, retry hooks ve Crawlee entegrasyonu dahil.","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fnodejs-got-scraping-proxy-rehberi-master.webp","got-scraping in Node.js: A Developer's Guide with Residential Proxies","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fnodejs-got-scraping-proxy-rehberi-card.webp","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fnodejs-got-scraping-proxy-rehberi-og.webp","2026-08-04T16:05:06+00:00","2026-10-03T08:57:49+00:00",12,136,{"name":42,"slug":43,"bio":44,"avatar_url":14,"website_url":14,"social_links":14},[144],{"id":47,"slug":48,"name":49,"description":14,"meta_title":50,"meta_description":51,"parent_id":14},[],{"id":147,"slug":148,"title":149,"excerpt":150,"featured_image_url":151,"featured_image_alt":152,"card_image_url":153,"og_image_url":154,"published_at":155,"updated_at":155,"content_updated_at":156,"reading_time_minutes":140,"is_featured":34,"indexable":34,"views":157,"author":158,"categories":159,"tags":161},175,"colly-doner-proxy-rehberi","Colly'de Döner Proxy Kullanımı: Go ile Üretim Seviyesinde Web Scraping","Go'nun Colly çerçevesinde döner proxy'leri idiomatik şekilde nasıl entegre edeceğinizi öğrenin. Collector modeli, RoundRobinProxySwitcher, residential IP rotasyonu ve üretim desenlerini kapsayan geliştirici odaklı rehber.","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcolly-doner-proxy-rehberi-master.webp","Rotating Proxies in Colly: A Framework-Idiomatic Guide for Go Developers","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcolly-doner-proxy-rehberi-card.webp","https:\u002F\u002Fstatic.proxyhat.com\u002Fstorage\u002Fblog-covers\u002Ftr\u002Fcolly-doner-proxy-rehberi-og.webp","2026-08-04T10:05:34+00:00","2026-10-03T08:57:48+00:00",86,{"name":42,"slug":43,"bio":44,"avatar_url":14,"website_url":14,"social_links":14},[160],{"id":47,"slug":48,"name":49,"description":14,"meta_title":50,"meta_description":51,"parent_id":14},[],[]]