Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/SecretRichGarden/metasota-API-MCPWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/secretrichgarden/metasota-api-mcp/metaso-api-integration)<a href="https://agentmods.dev/rules/secretrichgarden/metasota-api-mcp/metaso-api-integration"><img src="https://agentmods.dev/badge/rules/secretrichgarden/metasota-api-mcp/metaso-api-integration/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/secretrichgarden/metasota-api-mcp/metaso-api-integration"><img src="https://agentmods.dev/badge/rules/secretrichgarden/metasota-api-mcp/metaso-api-integration.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00012 | $0.00987 |
| Opus 5 | $0.00006 | $0.00494 |
| Sonnet 5 | $0.00002 | $0.00197 |
| Haiku 4.5 | $0.00001 | $0.00099 |
Grade A, and why
metaso-api-integration scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Makes network callslowCapability
Not a fault in itself. Listed so you know the mod talks to something, and to what.
- Use `axios.create()` to configure a reusable instance with base headers How it starts
The opening of the file, as written. The whole thing — 120 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Metaso API Integration
API Configuration
- Base URL:
https://metaso.cn/api/v1 - Authentication: Bearer token via
Authorization: Bearer ${API_KEY}header - API Key: Must be provided via
METASO_API_KEYenvironment variable - Timeout: 30 seconds (30000ms) for all API requests
- Use
axios.create()to configure a reusable instance with base headers
API Endpoints
Search Endpoint
- Path:
/search - Method: POST
- Required Parameters:
q(string): Search query keywords
- Optional Parameters:
scope(string): Search scope -webpage,document,paper,image,video,podcastincludeSummary(boolean): Enable summary-based recall enhancementincludeRawContent(boolean): Fetch original webpage contentsize(number): Number of results to return (default: 10)conciseSnippet(boolean): Return concise original text snippets
Reader Endpoint
- Path:
/reader - Method: POST
- Required Parameters:
url(string): URL to read
- Response Format: Controlled by
AcceptheaderAccept: text/plain→ Returns MarkdownAccept: application/json→ Returns JSON
Chat Completions Endpoint
- Path:
/chat/completions - Method: POST
- Models:
ds-r1(deepseekr1),fast,fast_thinking - Supports: Streaming responses (
stream: true) - Scopes:
document,scholar,video,podcast(for RAG-based Q&A)
Response Schema Validation
- Always validate API responses using Zod schemas
- Expected response structure:
{
code: number, // 0 indicates success
data: {
results: Array<{
title: string,
url: string,
content?: string,
rawContent?: string
}>,
summary?: string
}
}
- Check
code !== 0and throw appropriate errors - Handle optional fields gracefully (use
.optional()in Zod schemas)
Error Handling Patterns
- Catch
AxiosErrorspecifically to extract HTTP status and response data - Provide meaningful error messages:
API请求失败: ${status} - ${message} - Always validate response schema before processing data
- Log detailed errors to stderr for debugging
- Return user-friendly error messages in MCP tool responses
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 120 lines · 12 tokens per session scan A f1b920cb5f71
metaso-api-integration is a cursor rule published in the GitHub repository SecretRichGarden/metasota-API-MCP (2 stars, last pushed 6mo ago), licensed Apache-2.0. It adds 12 tokens to every session and 987 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other cursor rules, from other repositories
python
Python best practices and patterns for modern software development with Flask and SQLite.
api-property-optionality-hygiene
Fix ApiProperty/ApiPropertyOptional optionality mismatches in DTO files; use for scheduled batch fixes or DTO edits.
django
Definitive guidelines for writing maintainable, performant, and secure Django applications, emphasizing modern best practices, clear code organization, and efficient patterns.
cursor
You are working on the checkout service. Preserve transaction integrity and auditability.
shared-libraries
Shared libraries - condition framework, inventory containers, file-backed DB, itinerary, references.
env-validation-gate
Env validation gate — every app with ≥1 required env var validates its contract at boot via Zod; raw process.env is banned outside the env module. Full pattern in .claude/skills/t2000-env-gate/.