aboutsummaryrefslogtreecommitdiff
path: root/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info
diff options
context:
space:
mode:
authorS. Solomon Darnell2025-03-28 21:52:21 -0500
committerS. Solomon Darnell2025-03-28 21:52:21 -0500
commit4a52a71956a8d46fcb7294ac71734504bb09bcc2 (patch)
treeee3dc5af3b6313e921cd920906356f5d4febc4ed /.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info
parentcc961e04ba734dd72309fb548a2f97d67d578813 (diff)
downloadgn-ai-master.tar.gz
two version of R2R are hereHEADmaster
Diffstat (limited to '.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info')
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/INSTALLER1
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/LICENSE21
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/METADATA292
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/RECORD18
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/WHEEL5
-rw-r--r--.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/top_level.txt1
6 files changed, 338 insertions, 0 deletions
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/INSTALLER b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/INSTALLER
new file mode 100644
index 00000000..a1b589e3
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/INSTALLER
@@ -0,0 +1 @@
+pip
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/LICENSE b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/LICENSE
new file mode 100644
index 00000000..2635155f
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/LICENSE
@@ -0,0 +1,21 @@
+MIT License
+
+Copyright (c) 2024 Sideguide Technologies Inc.
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/METADATA b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/METADATA
new file mode 100644
index 00000000..71dd31bf
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/METADATA
@@ -0,0 +1,292 @@
+Metadata-Version: 2.1
+Name: firecrawl-py
+Version: 1.14.1
+Summary: Python SDK for Firecrawl API
+Home-page: https://github.com/mendableai/firecrawl
+Author: Mendable.ai
+Author-email: "Mendable.ai" <nick@mendable.ai>
+Maintainer-email: "Mendable.ai" <nick@mendable.ai>
+License: MIT License
+Project-URL: Documentation, https://docs.firecrawl.dev
+Project-URL: Source, https://github.com/mendableai/firecrawl
+Project-URL: Tracker, https://github.com/mendableai/firecrawl/issues
+Keywords: SDK,API,firecrawl
+Classifier: Development Status :: 5 - Production/Stable
+Classifier: Environment :: Web Environment
+Classifier: Intended Audience :: Developers
+Classifier: License :: OSI Approved :: MIT License
+Classifier: Natural Language :: English
+Classifier: Operating System :: OS Independent
+Classifier: Programming Language :: Python
+Classifier: Programming Language :: Python :: 3
+Classifier: Programming Language :: Python :: 3.8
+Classifier: Programming Language :: Python :: 3.9
+Classifier: Programming Language :: Python :: 3.10
+Classifier: Topic :: Internet
+Classifier: Topic :: Internet :: WWW/HTTP
+Classifier: Topic :: Internet :: WWW/HTTP :: Indexing/Search
+Classifier: Topic :: Software Development
+Classifier: Topic :: Software Development :: Libraries
+Classifier: Topic :: Software Development :: Libraries :: Python Modules
+Classifier: Topic :: Text Processing
+Classifier: Topic :: Text Processing :: Indexing
+Requires-Python: >=3.8
+Description-Content-Type: text/markdown
+License-File: LICENSE
+Requires-Dist: requests
+Requires-Dist: python-dotenv
+Requires-Dist: websockets
+Requires-Dist: nest-asyncio
+Requires-Dist: pydantic (>=2.10.3)
+
+# Firecrawl Python SDK
+
+The Firecrawl Python SDK is a library that allows you to easily scrape and crawl websites, and output the data in a format ready for use with language models (LLMs). It provides a simple and intuitive interface for interacting with the Firecrawl API.
+
+## Installation
+
+To install the Firecrawl Python SDK, you can use pip:
+
+```bash
+pip install firecrawl-py
+```
+
+## Usage
+
+1. Get an API key from [firecrawl.dev](https://firecrawl.dev)
+2. Set the API key as an environment variable named `FIRECRAWL_API_KEY` or pass it as a parameter to the `FirecrawlApp` class.
+
+Here's an example of how to use the SDK:
+
+```python
+from firecrawl.firecrawl import FirecrawlApp
+
+app = FirecrawlApp(api_key="fc-YOUR_API_KEY")
+
+# Scrape a website:
+scrape_status = app.scrape_url(
+ 'https://firecrawl.dev',
+ params={'formats': ['markdown', 'html']}
+)
+print(scrape_status)
+
+# Crawl a website:
+crawl_status = app.crawl_url(
+ 'https://firecrawl.dev',
+ params={
+ 'limit': 100,
+ 'scrapeOptions': {'formats': ['markdown', 'html']}
+ },
+ poll_interval=30
+)
+print(crawl_status)
+```
+
+### Scraping a URL
+
+To scrape a single URL, use the `scrape_url` method. It takes the URL as a parameter and returns the scraped data as a dictionary.
+
+```python
+url = 'https://example.com'
+scraped_data = app.scrape_url(url)
+```
+
+### Extracting structured data from a URL
+
+With LLM extraction, you can easily extract structured data from any URL. We support pydantic schemas to make it easier for you too. Here is how you to use it:
+
+```python
+class ArticleSchema(BaseModel):
+ title: str
+ points: int
+ by: str
+ commentsURL: str
+
+class TopArticlesSchema(BaseModel):
+ top: List[ArticleSchema] = Field(..., max_items=5, description="Top 5 stories")
+
+data = app.scrape_url('https://news.ycombinator.com', {
+ 'extractorOptions': {
+ 'extractionSchema': TopArticlesSchema.model_json_schema(),
+ 'mode': 'llm-extraction'
+ },
+ 'pageOptions':{
+ 'onlyMainContent': True
+ }
+})
+print(data["llm_extraction"])
+```
+
+### Crawling a Website
+
+To crawl a website, use the `crawl_url` method. It takes the starting URL and optional parameters as arguments. The `params` argument allows you to specify additional options for the crawl job, such as the maximum number of pages to crawl, allowed domains, and the output format.
+
+```python
+idempotency_key = str(uuid.uuid4()) # optional idempotency key
+crawl_result = app.crawl_url('firecrawl.dev', {'excludePaths': ['blog/*']}, 2, idempotency_key)
+print(crawl_result)
+```
+
+### Asynchronous Crawl a Website
+
+To crawl a website asynchronously, use the `async_crawl_url` method. It takes the starting URL and optional parameters as arguments. The `params` argument allows you to specify additional options for the crawl job, such as the maximum number of pages to crawl, allowed domains, and the output format.
+
+```python
+crawl_result = app.async_crawl_url('firecrawl.dev', {'excludePaths': ['blog/*']}, "")
+print(crawl_result)
+```
+
+### Checking Crawl Status
+
+To check the status of a crawl job, use the `check_crawl_status` method. It takes the job ID as a parameter and returns the current status of the crawl job.
+
+```python
+id = crawl_result['id']
+status = app.check_crawl_status(id)
+```
+
+### Map a Website
+
+Use `map_url` to generate a list of URLs from a website. The `params` argument let you customize the mapping process, including options to exclude subdomains or to utilize the sitemap.
+
+```python
+# Map a website:
+map_result = app.map_url('https://example.com')
+print(map_result)
+```
+
+### Crawl a website with WebSockets
+
+To crawl a website with WebSockets, use the `crawl_url_and_watch` method. It takes the starting URL and optional parameters as arguments. The `params` argument allows you to specify additional options for the crawl job, such as the maximum number of pages to crawl, allowed domains, and the output format.
+
+```python
+# inside an async function...
+nest_asyncio.apply()
+
+# Define event handlers
+def on_document(detail):
+ print("DOC", detail)
+
+def on_error(detail):
+ print("ERR", detail['error'])
+
+def on_done(detail):
+ print("DONE", detail['status'])
+
+ # Function to start the crawl and watch process
+async def start_crawl_and_watch():
+ # Initiate the crawl job and get the watcher
+ watcher = app.crawl_url_and_watch('firecrawl.dev', { 'excludePaths': ['blog/*'], 'limit': 5 })
+
+ # Add event listeners
+ watcher.add_event_listener("document", on_document)
+ watcher.add_event_listener("error", on_error)
+ watcher.add_event_listener("done", on_done)
+
+ # Start the watcher
+ await watcher.connect()
+
+# Run the event loop
+await start_crawl_and_watch()
+```
+
+### Scraping multiple URLs in batch
+
+To batch scrape multiple URLs, use the `batch_scrape_urls` method. It takes the URLs and optional parameters as arguments. The `params` argument allows you to specify additional options for the scraper such as the output formats.
+
+```python
+idempotency_key = str(uuid.uuid4()) # optional idempotency key
+batch_scrape_result = app.batch_scrape_urls(['firecrawl.dev', 'mendable.ai'], {'formats': ['markdown', 'html']}, 2, idempotency_key)
+print(batch_scrape_result)
+```
+
+### Asynchronous batch scrape
+
+To run a batch scrape asynchronously, use the `async_batch_scrape_urls` method. It takes the starting URL and optional parameters as arguments. The `params` argument allows you to specify additional options for the scraper, such as the output formats.
+
+```python
+batch_scrape_result = app.async_batch_scrape_urls(['firecrawl.dev', 'mendable.ai'], {'formats': ['markdown', 'html']})
+print(batch_scrape_result)
+```
+
+### Checking batch scrape status
+
+To check the status of an asynchronous batch scrape job, use the `check_batch_scrape_status` method. It takes the job ID as a parameter and returns the current status of the batch scrape job.
+
+```python
+id = batch_scrape_result['id']
+status = app.check_batch_scrape_status(id)
+```
+
+### Batch scrape with WebSockets
+
+To use batch scrape with WebSockets, use the `batch_scrape_urls_and_watch` method. It takes the starting URL and optional parameters as arguments. The `params` argument allows you to specify additional options for the scraper, such as the output formats.
+
+```python
+# inside an async function...
+nest_asyncio.apply()
+
+# Define event handlers
+def on_document(detail):
+ print("DOC", detail)
+
+def on_error(detail):
+ print("ERR", detail['error'])
+
+def on_done(detail):
+ print("DONE", detail['status'])
+
+# Function to start the crawl and watch process
+async def start_crawl_and_watch():
+ # Initiate the crawl job and get the watcher
+ watcher = app.batch_scrape_urls_and_watch(['firecrawl.dev', 'mendable.ai'], {'formats': ['markdown', 'html']})
+
+ # Add event listeners
+ watcher.add_event_listener("document", on_document)
+ watcher.add_event_listener("error", on_error)
+ watcher.add_event_listener("done", on_done)
+
+ # Start the watcher
+ await watcher.connect()
+
+# Run the event loop
+await start_crawl_and_watch()
+```
+
+## Error Handling
+
+The SDK handles errors returned by the Firecrawl API and raises appropriate exceptions. If an error occurs during a request, an exception will be raised with a descriptive error message.
+
+## Running the Tests with Pytest
+
+To ensure the functionality of the Firecrawl Python SDK, we have included end-to-end tests using `pytest`. These tests cover various aspects of the SDK, including URL scraping, web searching, and website crawling.
+
+### Running the Tests
+
+To run the tests, execute the following commands:
+
+Install pytest:
+
+```bash
+pip install pytest
+```
+
+Run:
+
+```bash
+pytest firecrawl/__tests__/e2e_withAuth/test.py
+```
+
+## Contributing
+
+Contributions to the Firecrawl Python SDK are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the GitHub repository.
+
+## License
+
+The Firecrawl Python SDK is licensed under the MIT License. This means you are free to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the SDK, subject to the following conditions:
+
+- The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+
+Please note that while this SDK is MIT licensed, it is part of a larger project which may be under different licensing terms. Always refer to the license information in the root directory of the main project for overall licensing details.
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/RECORD b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/RECORD
new file mode 100644
index 00000000..35647ea3
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/RECORD
@@ -0,0 +1,18 @@
+firecrawl/__init__.py,sha256=8K1hYYug2X_Qr7GGahrBPrPGQkcPx7T4kISbs4xeEbc,2544
+firecrawl/__pycache__/__init__.cpython-312.pyc,,
+firecrawl/__pycache__/firecrawl.cpython-312.pyc,,
+firecrawl/__tests__/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
+firecrawl/__tests__/e2e_withAuth/__pycache__/__init__.cpython-312.pyc,,
+firecrawl/__tests__/e2e_withAuth/__pycache__/test.cpython-312.pyc,,
+firecrawl/__tests__/e2e_withAuth/test.py,sha256=-Fq2vPcMo0iQi4dwsUkkCd931ybDaTxMBnZbRfGdDcA,7931
+firecrawl/__tests__/v1/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
+firecrawl/__tests__/v1/e2e_withAuth/__pycache__/__init__.cpython-312.pyc,,
+firecrawl/__tests__/v1/e2e_withAuth/__pycache__/test.cpython-312.pyc,,
+firecrawl/__tests__/v1/e2e_withAuth/test.py,sha256=DcCw-cohtnL-t9XPekUtRoQrgg3UCWu8Ikqudf9ory8,19880
+firecrawl/firecrawl.py,sha256=sc0BiinzTi1DMBCil2c-ce1RxV7WwTaCKIvXmhGImzg,52473
+firecrawl_py-1.14.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4
+firecrawl_py-1.14.1.dist-info/LICENSE,sha256=nPCunEDwjRGHlmjvsiDUyIWbkqqyj3Ej84ntnh0g0zA,1084
+firecrawl_py-1.14.1.dist-info/METADATA,sha256=guz2LxqWb4yFuPZV9K6qlWGV7hqGnasr66lyhMekhok,10575
+firecrawl_py-1.14.1.dist-info/RECORD,,
+firecrawl_py-1.14.1.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
+firecrawl_py-1.14.1.dist-info/top_level.txt,sha256=jTvz79zWhiyAezfmmHe4FQ-hR60C59UU5FrjMjijLu8,10
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/WHEEL b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/WHEEL
new file mode 100644
index 00000000..57e3d840
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/WHEEL
@@ -0,0 +1,5 @@
+Wheel-Version: 1.0
+Generator: bdist_wheel (0.38.4)
+Root-Is-Purelib: true
+Tag: py3-none-any
+
diff --git a/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/top_level.txt b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/top_level.txt
new file mode 100644
index 00000000..8bce1a1f
--- /dev/null
+++ b/.venv/lib/python3.12/site-packages/firecrawl_py-1.14.1.dist-info/top_level.txt
@@ -0,0 +1 @@
+firecrawl