firecrawl 1.1.1__py3-none-any.whl → 1.2.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of firecrawl might be problematic. Click here for more details.

firecrawl/__init__.py CHANGED
@@ -13,7 +13,7 @@ import os
13
13
 
14
14
  from .firecrawl import FirecrawlApp
15
15
 
16
- __version__ = "1.1.1"
16
+ __version__ = "1.2.1"
17
17
 
18
18
  # Define the logger for the Firecrawl project
19
19
  logger: logging.Logger = logging.getLogger("firecrawl")
firecrawl/firecrawl.py CHANGED
@@ -59,20 +59,16 @@ class FirecrawlApp:
59
59
 
60
60
  # If there are additional params, process them
61
61
  if params:
62
- # Initialize extractorOptions if present
63
- extractor_options = params.get('extractorOptions', {})
64
- # Check and convert the extractionSchema if it's a Pydantic model
65
- if 'extractionSchema' in extractor_options:
66
- if hasattr(extractor_options['extractionSchema'], 'schema'):
67
- extractor_options['extractionSchema'] = extractor_options['extractionSchema'].schema()
68
- # Ensure 'mode' is set, defaulting to 'llm-extraction' if not explicitly provided
69
- extractor_options['mode'] = extractor_options.get('mode', 'llm-extraction')
70
- # Update the scrape_params with the processed extractorOptions
71
- scrape_params['extractorOptions'] = extractor_options
62
+ # Handle extract (for v1)
63
+ extract = params.get('extract', {})
64
+ if extract:
65
+ if 'schema' in extract and hasattr(extract['schema'], 'schema'):
66
+ extract['schema'] = extract['schema'].schema()
67
+ scrape_params['extract'] = extract
72
68
 
73
69
  # Include any other params directly at the top level of scrape_params
74
70
  for key, value in params.items():
75
- if key != 'extractorOptions':
71
+ if key not in ['extract']:
76
72
  scrape_params[key] = value
77
73
 
78
74
  endpoint = f'/v1/scrape'
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: firecrawl
3
- Version: 1.1.1
3
+ Version: 1.2.1
4
4
  Summary: Python SDK for Firecrawl API
5
5
  Home-page: https://github.com/mendableai/firecrawl
6
6
  Author: Mendable.ai
@@ -0,0 +1,11 @@
1
+ firecrawl/__init__.py,sha256=780HIcEC419TNBNDRX9JcihA5KxAKnvnR3ku28EVdUQ,1682
2
+ firecrawl/firecrawl.py,sha256=cEskO824x-uad2Ma7ZXHbtit6Ng6vz67dgt2kh0w5YA,17242
3
+ firecrawl/__tests__/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
+ firecrawl/__tests__/e2e_withAuth/test.py,sha256=L-umFR3WyrJso1EwqkxjbTMr5AEI4t5zDfhQcCzitOI,7911
5
+ firecrawl/__tests__/v1/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
+ firecrawl/__tests__/v1/e2e_withAuth/test.py,sha256=KQMmGAtJAIafja6EGtJ-W9162w2Hm6PNjqKl3_RQXLA,16456
7
+ firecrawl-1.2.1.dist-info/LICENSE,sha256=nPCunEDwjRGHlmjvsiDUyIWbkqqyj3Ej84ntnh0g0zA,1084
8
+ firecrawl-1.2.1.dist-info/METADATA,sha256=4k2JWb8r6v9PPIG3NgRnonxwM1F07VQiq9tkbavdSbc,8297
9
+ firecrawl-1.2.1.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
10
+ firecrawl-1.2.1.dist-info/top_level.txt,sha256=jTvz79zWhiyAezfmmHe4FQ-hR60C59UU5FrjMjijLu8,10
11
+ firecrawl-1.2.1.dist-info/RECORD,,
@@ -1,11 +0,0 @@
1
- firecrawl/__init__.py,sha256=j1M2OH1eJLLBEooOLOVrfgqyDyuOqSHdSRbxKE6FH2E,1682
2
- firecrawl/firecrawl.py,sha256=XIO5Pyw2w9i32f-fIjO5hgqLvPV7ZSi66pR0JQjFzVI,17713
3
- firecrawl/__tests__/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
- firecrawl/__tests__/e2e_withAuth/test.py,sha256=L-umFR3WyrJso1EwqkxjbTMr5AEI4t5zDfhQcCzitOI,7911
5
- firecrawl/__tests__/v1/e2e_withAuth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
- firecrawl/__tests__/v1/e2e_withAuth/test.py,sha256=KQMmGAtJAIafja6EGtJ-W9162w2Hm6PNjqKl3_RQXLA,16456
7
- firecrawl-1.1.1.dist-info/LICENSE,sha256=nPCunEDwjRGHlmjvsiDUyIWbkqqyj3Ej84ntnh0g0zA,1084
8
- firecrawl-1.1.1.dist-info/METADATA,sha256=I7nFWbZ4zD9GRoeQDtGfYVEnGEKNPT7ltkA0D4gUH0g,8297
9
- firecrawl-1.1.1.dist-info/WHEEL,sha256=2wepM1nk4DS4eFpYrW1TTqPcoGNfHhhO_i5m4cOimbo,92
10
- firecrawl-1.1.1.dist-info/top_level.txt,sha256=jTvz79zWhiyAezfmmHe4FQ-hR60C59UU5FrjMjijLu8,10
11
- firecrawl-1.1.1.dist-info/RECORD,,