Kütüphane / Web Kazıma ve Araştırma
Web Kazıma ve Araştırma
Bright Data ve Data Table ile web sayfalarını getirin ve önbelleğe alın
Diğer iş akışlarının bir URL ile çağırdığı yeniden kullanılabilir alt iş akışı. Önce zaman damgalı Data Table önbelleğini kontrol eder, yoksa sayfayı Bright Data üzerinden getirir ve markdown, HTML veya JSON döndürür.
Ne yapar
## One scraper your other workflows call, with a cache in front of it By the fifth workflow that fetches a page you have written the same Bright Data call, the same error check and the same fallback five times. This is that code, once, as a sub-workflow other workflows call with a URL. ### How it works It starts on an Execute Workflow Trigger - no schedule, no webhook. A caller passes url, optionally a format (markdown, html or json) and a max_age_minutes. First it looks in the cache. A Data Table keeps every result with a timestamp, so asking for the same URL inside your freshness window returns instantly and spends nothing. Five workflows checking the same page each morning become one request. On a miss it fetches through Bright Data, then checks the payload properly: Bright Data returns validation errors and blocks with HTTP 200 and an error body, and an empty body means the domain never resolved. If the result is empty or suspiciously thin it retries once with render: true, running the page in a real browser - which is what rescues single-page apps. It always returns the same fields, including ok, from_cache and error, so the caller can branch on the result instead of guessing. ### Setup 1. A Bright Data Header Auth credential and a Web Unlocker zone. 2. A Data Table called scrape_cache with columns url, content, status and fetched_at. It will not add missing ones. 3. In another workflow, add Execute Sub-workflow, pick this one, pass a url.
Adımlar
- A Workflow Asks For A Page
- Settings
- Read The Request
- Look In The Cache
- Is It Still Fresh?
- Serve From Cache?
- Straight From The Cache
- Fetch The Page
- Read What Came Back
- Does It Need A Browser?
- Try Again In A Browser
- Read The Rendered Page
- The First Fetch Was Fine
- Build The Answer
Toplam 15 adım.
Benzer otomasyonlar
Web Kazıma ve AraştırmaBenchmark employer brand on Glassdoor with Bright Data, OpenAI, Sheets and Slack24 adımWeb Kazıma ve AraştırmaBright Data Web Scraper ile Toplu Amazon Verisi Çıkar13 adımWeb Kazıma ve AraştırmaBright Data ve Gemini ile Web Sayfalarından Alıntı Çıkarma5 adımWeb Kazıma ve AraştırmaBright Data ve Gemini ile Web Sitesi Verilerini Yapılandırılmış Olarak Çıkar16 adım