chore: import upstream snapshot with attribution
Tests / tests (map[TOXENV:py310], macos-latest, 3.10) (push) Has been cancelled
Tests / tests (map[TOXENV:py311], macos-latest, 3.11) (push) Has been cancelled
Tests / tests (map[TOXENV:py312], macos-latest, 3.12) (push) Has been cancelled
Tests / tests (map[TOXENV:py313], macos-latest, 3.13) (push) Has been cancelled

This commit is contained in:
wehub-resource-sync
2026-07-13 12:01:50 +08:00
commit 247153575d
244 changed files with 44853 additions and 0 deletions
+61
View File
@@ -0,0 +1,61 @@
---
search:
exclude: true
---
# MCP Server API Reference
The **Scrapling MCP Server** provides nine powerful tools for web scraping through the Model Context Protocol (MCP). This server integrates Scrapling's capabilities directly into AI chatbots and agents, allowing conversational web scraping with advanced anti-bot bypass features.
You can start the MCP server by running:
```bash
scrapling mcp
```
Or import the server class directly:
```python
from scrapling.core.ai import ScraplingMCPServer
server = ScraplingMCPServer()
server.serve(http=False, host="0.0.0.0", port=8000)
```
To set a custom Chromium-compatible browser executable for browser-based MCP tools, pass `executable_path`:
```python
server = ScraplingMCPServer(executable_path="/path/to/chromium")
```
## Response Model
The standardized response structure that's returned by all MCP server tools:
## ::: scrapling.core.ai.ResponseModel
handler: python
:docstring:
## Session Models
Model classes for session management:
## ::: scrapling.core.ai.SessionInfo
handler: python
:docstring:
## ::: scrapling.core.ai.SessionCreatedModel
handler: python
:docstring:
## ::: scrapling.core.ai.SessionClosedModel
handler: python
:docstring:
## MCP Server Class
The main MCP server class that provides all web scraping tools:
## ::: scrapling.core.ai.ScraplingMCPServer
handler: python
:docstring: