hyper-sdk 2.12.5__tar.gz → 3.0.0__tar.gz

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.
Files changed (31) hide show
  1. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/PKG-INFO +29 -1
  2. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/README.md +394 -366
  3. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai_input.py +38 -35
  4. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/datadome/parse.py +140 -84
  5. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/datadome_input.py +113 -88
  6. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/session.py +33 -3
  7. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/session_async.py +34 -3
  8. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk.egg-info/PKG-INFO +29 -1
  9. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/pyproject.toml +1 -1
  10. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/LICENSE +0 -0
  11. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/__init__.py +0 -0
  12. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai/__init__.py +0 -0
  13. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai/pixel.py +0 -0
  14. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai/script_path.py +0 -0
  15. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai/sec_cpt.py +0 -0
  16. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/akamai/stop_signal.py +0 -0
  17. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/datadome/__init__.py +0 -0
  18. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/incapsula/__init__.py +0 -0
  19. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/incapsula/dynamic.py +0 -0
  20. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/incapsula/utmvc.py +0 -0
  21. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/incapsula_input.py +0 -0
  22. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/kasada/__init__.py +0 -0
  23. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/kasada/parse.py +0 -0
  24. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/kasada_input.py +0 -0
  25. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/shared.py +0 -0
  26. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk/trustdecision_input.py +0 -0
  27. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk.egg-info/SOURCES.txt +0 -0
  28. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk.egg-info/dependency_links.txt +0 -0
  29. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk.egg-info/requires.txt +0 -0
  30. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/hyper_sdk.egg-info/top_level.txt +0 -0
  31. {hyper_sdk-2.12.5 → hyper_sdk-3.0.0}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: hyper_sdk
3
- Version: 2.12.5
3
+ Version: 3.0.0
4
4
  Summary: Hyper Solutions Python SDK
5
5
  License: MIT License
6
6
 
@@ -386,6 +386,34 @@ device_link = parse_slider_device_check_link(
386
386
  )
387
387
  ```
388
388
 
389
+ ### Challenge Script
390
+
391
+ DataDome sometimes serves a challenge page with the **challenge script in its own file** instead of inlining it in the page:
392
+
393
+ ```html
394
+ <script defer src="https://ct.captcha-delivery.com/interstitial.1.33.0.202609141.js"></script>
395
+ ```
396
+
397
+ It switches between the two forms per request, so check every challenge page. When the page uses a separate file, fetch it with your own client so the request keeps your proxy, TLS fingerprint and headers, then pass the body as `script`:
398
+
399
+ ```python
400
+ from hyper_sdk import DataDomeInterstitialInput
401
+ from hyper_sdk.datadome import parse_challenge_script_url
402
+
403
+ script = ""
404
+ script_url = parse_challenge_script_url(html_content)
405
+ if script_url is not None:
406
+ script = your_client.get(script_url).text
407
+
408
+ result = session.generate_interstitial_payload(DataDomeInterstitialInput(
409
+ # other interstitial input fields
410
+ html=html_content,
411
+ script=script, # empty when the page inlines the script
412
+ ))
413
+ ```
414
+
415
+ The same applies to `DataDomeSliderInput`. One helper covers both challenge types, since the captcha page uses the same tag. `script` is optional and leaving it empty keeps working.
416
+
389
417
  ## 📖 Documentation
390
418
 
391
419
  For detailed documentation on how to use the SDK, including examples and API reference, please visit our documentation website: