Skip to content

feat(capturekit): add CaptureKit integration - #9834

Open
josselinlbe wants to merge 2 commits into
simstudioai:stagingfrom
capturekitdev:feat/capturekit-integration
Open

josselinlbe wants to merge 2 commits into
simstudioai:stagingfrom
capturekitdev:feat/capturekit-integration

Conversation

@josselinlbe

Copy link
Copy Markdown

Summary

Adds a CaptureKit integration: tools, block, icon and generated docs page. I work on CaptureKit, so this PR comes from the CaptureKit team.

Capture any web page as a PNG, JPEG, WebP image or a PDF, by viewport, full page or CSS selector on 17+ emulated devices; extract a page's metadata, links and Markdown; fetch raw HTML; and get an AI summary of what a website offers.

Operations:

  • Take Screenshot (capturekit_screenshot): Capture a public web page as a PNG, JPEG, WebP image or a PDF, by viewport, full page or CSS selector, and store it as a file.
  • Extract Content (capturekit_extract_content): Render a web page and get its title, description, favicon, Open Graph image, internal, external and social links, and optionally its Markdown.
  • Fetch HTML (capturekit_fetch_html): Fetch the raw HTML of a public page over plain HTTP, without a browser.
  • Analyze Website (capturekit_analyze_website): Read a website and get an AI summary of its value proposition, business type, key features, categories, use cases, audience and contact details.

Credentials are a CaptureKit API key on the block (AuthMode.ApiKey), sent as the x-api-key header. Every tool is an external ToolConfig.request against the CaptureKit API.

Product update (if relevant)

Marketing, compliance and research teams can archive pages, track competitor pages, and turn websites into clean input for agents. The block appears in the integrations catalog with 7 templates and grounded skills; the docs page is apps/docs/content/docs/integrations/capturekit.mdx.

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation
  • Other: ___________

Testing

  • Outputs follow the documented OpenAPI response schemas, and every tool was run against the live CaptureKit API through its request and transformResponse to confirm the mapped outputs; fields that the API documents as nullable are optional outputs.
  • Local gate on this branch: bun run lint, bun run type-check, bun run check:audits (all 62 audits), bun run apps/sim/scripts/check-block-registry.ts origin/staging, bun run apps/sim/scripts/check-canvas-sentences.ts --block=capturekit, and the existing blocks and tools/request-transport Vitest suites all pass.
  • Regenerated artifacts are committed: tool metadata, docs, block successors and the docs manifest.
  • No new unit tests, following the repo's testing guidance; the live run above is the end-to-end check.

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Screenshots/Videos

Add a CaptureKit block for web page capture and content:
- Take a screenshot of a page as PNG, JPEG, WebP or PDF, full page or by
  CSS selector, on 17+ emulated devices, stored as a file
- Extract a page's metadata, internal, external and social links, and its
  Markdown
- Fetch a page's raw HTML without a browser
- Get an AI summary of what a website offers, its audience and contacts

Outputs follow the documented OpenAPI schemas and were checked against live
responses. Credentials are a CaptureKit API key sent in the x-api-key header.
@vercel

vercel Bot commented Nov 10, 2026

Copy link
Copy Markdown

Someone is attempting to deploy a commit to the Sim Team on Vercel.

A member of the Team first needs to authorize it.

@greptile-apps

greptile-apps Bot commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The changes affect workflows that choose to use the new CaptureKit integration.

No blocking behavior defect was established, but the two explicit repository requirements must be satisfied before merging.

Findings

  1. P2 Helpers live apart from caller ▶
  2. P2 Public icons lack required docs ▶

Summary

Adds CaptureKit with four API-key-backed operations:

  • Sim workflows can add CaptureKit and choose one of its four page actions.
  • CaptureKit returns a page screenshot or PDF as a workflow file.
  • CaptureKit turns rendered page details into separate workflow outputs.
  • CaptureKit returns raw page HTML for workflow steps.
  • CaptureKit turns a website into a summary and structured findings.

Two repository requirements remain: keep single-consumer helpers beside their caller and document the new exported icon functions.

Reviews (1) · Last reviewed commit: "feat(capturekit): add CaptureKit integra..." · Reviewed by Greptile

Comment thread apps/sim/tools/capturekit/utils.ts Outdated
Comment on lines +5 to +6
/** Reads a `CaptureKitPageMetadata` from an untyped CaptureKit API payload. */
export function mapCaptureKitPageMetadata(value: unknown): CaptureKitPageMetadata | null {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Helpers live apart from caller

Both exported helpers in utils.ts are used only by extract_content.ts. The repository requires helpers with one consumer to stay inline. Move both functions into extract_content.ts and remove this extra module before merging.

Context Used: CLAUDE.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

)
}

export function CaptureKitIcon(props: SVGProps<SVGSVGElement>) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Public icons lack required docs

The new CaptureKitIcon exports here and in apps/docs/components/icons.tsx lack TSDoc. The repository requires TSDoc on exported APIs. Add a short declaration comment above both functions before merging.

Context Used: CLAUDE.md (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

- Keep the two response mappers in extract_content.ts, their only caller
- Document the CaptureKitIcon export
- Read the operation from the mapper context so agent tools coerce the
  screenshot's numeric inputs too

This branch has not been deployed

No deployments
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.

1 participant