The CaptureKit connector lets your AI agent act in each user's CaptureKit account. Each user connects their own CaptureKit API key once, and Scalekit sends it with every call, so your agent never handles credentials. It comes with 4 tools.
- Tools
- 4
- What they doRead · write · destructive
- 4 · 0 · 04 read0 write0 destructive
- Users sign in with
- API key
Setup
Install the SDK
Terminal window npm install @scalekit-sdk/node dotenvTerminal window pip install scalekit-sdk-python python-dotenvSet your credentials
Add your Scalekit credentials to your
.envfile. Find values in app.scalekit.com > Developers > API Credentials..env SCALEKIT_ENVIRONMENT_URL=<your-environment-url>SCALEKIT_CLIENT_ID=<your-client-id>SCALEKIT_CLIENT_SECRET=<your-client-secret>Create the CaptureKit connection
In AgentKit > Connections, create a CaptureKit connection. The name you give it is the
connection_nameyour code passes. See Configure connections.Authorize a user and make your first call
quickstart.mts import { ScalekitClient } from '@scalekit-sdk/node'import 'dotenv/config'import { createInterface } from 'node:readline/promises'const scalekit = new ScalekitClient(process.env.SCALEKIT_ENVIRONMENT_URL,process.env.SCALEKIT_CLIENT_ID,process.env.SCALEKIT_CLIENT_SECRET,)const actions = scalekit.actionsconst connector = 'capturekit'const identifier = 'user_123'// Generate an authorization link for the userconst { link } = await actions.getAuthorizationLink({ connectionName: connector, identifier })console.log('Authorize CaptureKit:', link)const rl = createInterface({ input: process.stdin, output: process.stdout })await rl.question('Press Enter after authorizing...')rl.close()// Make your first callconst result = await actions.executeTool({connector,identifier,toolName: 'capturekit_usage_get',toolInput: {},})console.log(result)Terminal window npx tsx quickstart.mtsquickstart.py import osfrom scalekit import ScalekitClientfrom dotenv import load_dotenvload_dotenv()scalekit_client = ScalekitClient(env_url=os.getenv("SCALEKIT_ENVIRONMENT_URL"),client_id=os.getenv("SCALEKIT_CLIENT_ID"),client_secret=os.getenv("SCALEKIT_CLIENT_SECRET"),)actions = scalekit_client.actionsconnection_name = "capturekit"identifier = "user_123"# Generate an authorization link for the userlink_response = actions.get_authorization_link(connection_name=connection_name,identifier=identifier,)print("Authorize CaptureKit:", link_response.link)input("Press Enter after authorizing...")# Make your first callresult = actions.execute_tool(tool_input={},tool_name="capturekit_usage_get",connection_name=connection_name,identifier=identifier,)print(result)Terminal window python quickstart.pyEach user opens the link once and enters their CaptureKit credentials there. See Authorize a user for the full flow and statuses.
Tools
Pass the exact name toexecute_toolcapturekit_content_getLoad a webpage in a browser and extract its content, optionally as cleaned Markdown, raw HTML and the site's sitemap.Read-onlyGet Page Content
Load a webpage in a browser and extract its content, optionally as cleaned Markdown, raw HTML and the site's sitemap. Returns the page's title, metadata, links and text, plus HTML, Markdown or sitemap when requested. Use use_defuddle true for the main article content only.
Inputs
urlstringrequired- The URL of the webpage to capture. Example: https://example.com/pricing.
block_resourcesstring- Comma-separated list of resource types to block (e.g., “image,stylesheet,font”). Types: document, stylesheet, image, media, font, script, texttrack, xhr, fetch, eventsource, websocket, manifest, other. Example: image,font.
block_urlsstring- Comma-separated list of URL patterns to block (e.g., “analytics,tracking,advertisement”). You can specify URLs, domains, or simple patterns like “.example.com/”. Example: analytics,tracking.
cacheboolean- Cache the response. Example: true.
cache_ttlinteger- Cache the response for a custom TTL (in seconds). Example: 3600.
delayinteger- Delay in seconds before capturing the screenshot. Example: 2.
include_htmlboolean- Include the raw HTML of the webpage in the response. Example: true.
include_markdownboolean- Include the Markdown of the webpage in the response. Example: true.
include_sitemapboolean- Include the sitemap of the website in the response. Example: true.
proxystring- Specify a proxy server to route your request through. Supports HTTP, HTTPS, and SOCKS5 proxies. Format: http://username:password@proxy.com:PORT. Useful for bypassing geo-restrictions and rotating IPs. Example: http://user:pass@proxy.example.com:8080.
remove_adsboolean- Automatically remove ads before capturing. Example: true.
remove_cookie_bannersboolean- Automatically remove cookie banners before capturing. Example: true.
remove_selectorsstring- A comma-separated list of elements to hide before capturing (e.g., ads, popups). Example: .newsletter-popup,#chat-widget.
use_defuddleboolean- Use Defuddle to clean and extract the main content from web pages. This popular library removes unnecessary elements like comments, sidebars, headers, footers, and other non-essential elements, leaving only the primary content. When enabled, the HTML response will be processed through Defuddle before being returned. Example: true.
wait_for_selectorstring- Wait for a specific element to appear before taking the screenshot. Example: #main-content.
wait_untilstring- Define when to capture. Example: networkidle2.one of
domcontentloadedloadnetworkidle0networkidle2
capturekit_page_analyzeLoad a webpage and have AI analyze it, optionally guided by your own prompt and extra response fields.Read-onlyAnalyze Page with AI
Load a webpage and have AI analyze it, optionally guided by your own prompt and extra response fields. Returns structured insights about the page's content, design and technology, plus any custom fields. Use capturekit_content_get for the raw text or Markdown.
Inputs
urlstringrequired- The URL of the webpage to capture. Example: https://example.com/pricing.
cacheboolean- Cache the response. Example: true.
cache_ttlinteger- Cache the response for a custom TTL (in seconds). Example: 3600.
custom_promptstring- Add your own instructions to guide the AI’s analysis. Example: List the pricing tiers and their monthly prices.
custom_responsestring- JSON-stringified object of extra fields the AI should fill in, mapping each field name to what it should hold. Example: {"sentiment": "sentiment", "language": "language"}
proxystring- Specify a proxy server to route your request through. Supports HTTP, HTTPS, and SOCKS5 proxies. Format: http://username:password@proxy.com:PORT. Useful for bypassing geo-restrictions and rotating IPs. Example: http://user:pass@proxy.example.com:8080.
capturekit_usage_getGet the account's live quota and credit usage.Read-onlyGet Usage
Get the account's live quota and credit usage. Returns remaining, total_used, renewal_date, subscription and credits balances, packs, rate limits and the API key's details. It costs no credits.
Inputs
This tool takes no inputs.
capturekit_website_crawlFetch a web page through CaptureKit's crawler.Read-onlyCrawl Website Page
Fetch a web page through CaptureKit's crawler. Returns the page data, or its HTML source when return_page_source is true. Use capturekit_content_get for rendered content and Markdown.
Inputs
querystringrequired- A website URL with either the http or https protocol. Example: https://example.com.
allow_redirectsboolean- If set to false, do not follow redirects. Example: true.
return_page_sourceboolean- If set to true, the response will be the HTML source of the page. Example: true.
No tools match.