2024-05-17 17:32:44 -04:00
|
|
|
config:
|
2024-05-17 18:09:19 -04:00
|
|
|
target: "https://staging-firecrawl-scraper-js.fly.dev/v0"
|
2024-05-22 08:30:32 -04:00
|
|
|
http:
|
|
|
|
timeout: 30
|
2024-05-17 17:32:44 -04:00
|
|
|
phases:
|
2024-05-17 18:09:19 -04:00
|
|
|
- duration: 60
|
2024-05-22 08:30:32 -04:00
|
|
|
arrivalRate: 10 # Initial load
|
|
|
|
- duration: 120
|
|
|
|
arrivalRate: 20 # Increased load
|
|
|
|
- duration: 180
|
|
|
|
arrivalRate: 30 # Peak load
|
|
|
|
- duration: 60
|
|
|
|
arrivalRate: 10 # Cool down
|
2024-05-17 17:32:44 -04:00
|
|
|
defaults:
|
|
|
|
headers:
|
2024-05-21 09:06:02 -04:00
|
|
|
Authorization: "Bearer {{ $env.TEST_API_KEY }}"
|
2024-05-17 17:32:44 -04:00
|
|
|
scenarios:
|
|
|
|
- name: Scrape a URL
|
|
|
|
flow:
|
|
|
|
- post:
|
|
|
|
url: "/scrape"
|
|
|
|
json:
|
|
|
|
url: "https://www.scrapethissite.com"
|
|
|
|
pageOptions:
|
|
|
|
onlyMainContent: true
|
|
|
|
capture:
|
|
|
|
- json: "$.data.markdown"
|
|
|
|
as: markdown_content
|
|
|
|
|
|
|
|
# - name: Crawl a URL
|
|
|
|
# flow:
|
|
|
|
# - post:
|
|
|
|
# url: "/crawl"
|
|
|
|
# json:
|
|
|
|
# url: "https://mendable.ai"
|
|
|
|
# crawlerOptions:
|
|
|
|
# includes: []
|
|
|
|
# excludes: ["blog/*"]
|
|
|
|
# limit: 100
|
|
|
|
# pageOptions:
|
|
|
|
# onlyMainContent: true
|
|
|
|
# capture:
|
|
|
|
# - json: "$.jobId"
|
|
|
|
# as: job_id
|
|
|
|
# - get:
|
|
|
|
# url: "/crawl/status/{{ job_id }}"
|
|
|
|
# capture:
|
|
|
|
# - json: "$.status"
|
|
|
|
# as: crawl_status
|
|
|
|
# until:
|
|
|
|
# - condition: "equals"
|
|
|
|
# value: "completed"
|
|
|
|
# variable: "crawl_status"
|
|
|
|
# retry:
|
|
|
|
# count: 20
|
|
|
|
# wait: 10
|
|
|
|
|
|
|
|
# - name: Search for a query
|
|
|
|
# flow:
|
|
|
|
# - post:
|
|
|
|
# url: "/search"
|
|
|
|
# json:
|
|
|
|
# query: "firecrawl"
|
|
|
|
# pageOptions:
|
|
|
|
# fetchPageContent: true
|
|
|
|
# capture:
|
|
|
|
# - json: "$.data[0].markdown"
|
|
|
|
# as: search_markdown_content
|