Connecting to ScrapingBee
Using API Key Authentication
ScrapingBee uses API key authentication. To obtain an API key:
- Sign in to your ScrapingBee account at https://app.scrapingbee.com
- Navigate to the Dashboard and locate your API key in the top section.
- Copy the API key for use in the connection string.
After obtaining your API key, set the following connection properties:
- AuthScheme: Set this to APIKey.
- APIKey: Set this to your ScrapingBee API key.
Example Connection String
Profile=C:\profiles\ScrapingBee.apip;AuthScheme=APIKey;ProfileSettings="APIKey=your_api_key";
Connecting to ScrapingBee
Once the authentication is configured, you can connect to ScrapingBee and query data from any of the available tables. All tables require at least one input parameter (such as a search query or product ID) to retrieve data.
Available Tables
The ScrapingBee API Profile provides access to the following tables:
- GoogleSearchResults: Returns Google classic organic search results (requires Search query)
- GoogleNewsResults: Returns Google News search results (requires Search query)
- GoogleLocalResults: Returns Google local business search results (requires Search query)
- GoogleMapsResults: Returns Google Maps business results (requires Search query)
- FastSearchResults: Returns fast Google search results at lower credit cost (requires Search query)
- YouTubeVideoMetadata: Returns YouTube video metadata including stats and formats (requires VideoIdInput)
- YouTubeVideoTranscript: Returns YouTube video transcript text and segments (requires VideoIdInput)
- AmazonSearchResults: Returns Amazon product search results (requires Query)
- AmazonProductDetails: Returns Amazon product details by ASIN (requires AsinQuery)
- WalmartSearchResults: Returns Walmart product search results (requires Query)
- WalmartProductDetails: Returns Walmart product details (requires ProductId)
- ChatGptResults: Returns ChatGPT AI query results in markdown, text, and JSON (requires PromptInput)
Important Notes
- All tables require at least one input parameter to retrieve data. Use WHERE clauses to supply required inputs.
- ScrapingBee API requests consume credits. Credit costs vary by endpoint and rendering mode.
- The ChatGPT endpoint costs 15 credits per request.
- Amazon and Walmart endpoints support light_request mode (default) for lower credit consumption.
- The Fast Search endpoint provides Google results at lower credit cost than the standard Google endpoint.
API Documentation
For more information about the ScrapingBee API, see the official ScrapingBee documentation.
Usage Examples
Google Search:
SELECT * FROM GoogleSearchResults WHERE SearchQuery = 'cdata drivers'
Google News Search:
SELECT * FROM GoogleNewsResults WHERE SearchQuery = 'technology news'
Google Local Search:
SELECT * FROM GoogleLocalResults WHERE SearchQuery = 'coffee shops'
Google Maps Search:
SELECT * FROM GoogleMapsResults WHERE SearchQuery = 'restaurants near me'
Fast Google Search:
SELECT * FROM FastSearchResults WHERE SearchQuery = 'cdata drivers'
Amazon Product Search:
SELECT * FROM AmazonSearchResults WHERE SearchQuery = 'wireless headphones'
Amazon Product Details:
SELECT * FROM AmazonProductDetails WHERE ProductAsin = 'B08N5WRWNW'
Walmart Product Search:
SELECT * FROM WalmartSearchResults WHERE SearchQuery = 'laptop'
Walmart Product Details:
SELECT * FROM WalmartProductDetails WHERE ProductId = '10451711'
YouTube Video Metadata:
SELECT * FROM YouTubeVideoMetadata WHERE VideoId = 'rfscVS0vtbw'
YouTube Video Transcript:
SELECT * FROM YouTubeVideoTranscript WHERE VideoId = 'rfscVS0vtbw'
ChatGPT Query:
SELECT * FROM ChatGptResults WHERE UserPrompt = 'What is the capital of France?'
Connection Properties
The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider.
| Property | Description |
| APIKey | The API key for your ScrapingBee account. |
| AuthScheme | The scheme used for authentication. Accepted entries are APIKey or None. Allowed values are: BASIC, NONE, NTLM, OAUTH, APIKEY, OAUTH_CLIENT |