Skip to content

docs: migrate company-info SDK cookbook to v2 API#91

Merged
VinciGit00 merged 2 commits into
mainfrom
docs/cookbook-company-info-v2
May 11, 2026
Merged

docs: migrate company-info SDK cookbook to v2 API#91
VinciGit00 merged 2 commits into
mainfrom
docs/cookbook-company-info-v2

Conversation

@Vikrant-Khedkar
Copy link
Copy Markdown
Collaborator

@Vikrant-Khedkar Vikrant-Khedkar commented May 11, 2026

Summary

image

First of N PRs restoring + migrating the cookbook notebooks that were removed in 1f3b123 to the v2 SDK API. This PR migrates cookbook/company-info/scrapegraph_sdk.ipynb and swaps the outdated banner image.

Migration

Old New
from scrapegraph_py import Client from scrapegraph_py import ScrapeGraphAI
Client(api_key=...) ScrapeGraphAI() (auto-reads SGAI_API_KEY)
smartscraper(website_url=, user_prompt=, output_schema=) extract(prompt, url=, schema=Schema.model_json_schema())
response['result'] / response['request_id'] response.data.json_data + .status / .error check
broken async link → examples/async_smartscraper_example.py (404) examples/extract/extract_basic_async.py
https://dashboard.scrapegraphai.com/ https://scrapegraphai.com/dashboard
Old "Presentazione senza titolo.pptx" banner (163 KB inline base64) New ScrapeGraphAI banner (87 KB inline base64)

Validation

  • Tested locally end-to-end against live API — runs clean, dataframes render, CSVs written

Follow-ups (separate PRs, not blocking this)

Same migration pattern still needs to be applied to:

  • cookbook/github-trending/scrapegraph_sdk.ipynb
  • cookbook/homes-forsale/scrapegraph_sdk.ipynb
  • cookbook/wired-news/scrapegraph_sdk.ipynb
  • cookbook/chat-webpage-simple-rag/scrapegraph_burr_lancedb.ipynb (heavier: markdownify → scrape, sgai_logger removal)
  • LangChain / LlamaIndex / LangGraph / CrewAI integration notebooks (13 files — need separate verification that the wrapper packages target v2)
  • Banner swap across the remaining 17 notebooks (single PR once they're restored)

🤖 Generated with Claude Code

- Client -> ScrapeGraphAI (auto-reads SGAI_API_KEY)
- smartscraper(website_url=, user_prompt=, output_schema=)
  -> extract(prompt, url=, schema=model_json_schema())
- Response shape: response['result'] -> response.data.json_data
- Fix broken async example link
- Update dashboard URL: dashboard.scrapegraphai.com -> scrapegraphai.com/dashboard

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 11, 2026

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

Replaces the old "Presentazione senza titolo.pptx" base64 banner
with the updated ScrapeGraphAI banner (163KB -> 87KB).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@Vikrant-Khedkar Vikrant-Khedkar marked this pull request as ready for review May 11, 2026 08:07
@VinciGit00 VinciGit00 merged commit 9649095 into main May 11, 2026
6 checks passed
@VinciGit00 VinciGit00 deleted the docs/cookbook-company-info-v2 branch May 11, 2026 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants