extract_json_with_schema
mlpeek: Extract JSON from text that always matches your JSON Schema. For fixed entity types use extract_entities. Returns data, JSON extracted from the text that always parses and validates against your json_schema (decoded under a grammar built from it), plus model, usage (tokens) and ms. A smal...
This record as markdown: /tools/dev-tanod-tanod/extract-json-with-schema.md
What extract_json_with_schema does on Tanod
AI agents call extract_json_with_schema to retrieve information from Tanod without modifying anything. It is typically the context-gathering step in research, monitoring, and reporting workflows, before the agent takes action elsewhere.
| Parameter | Type | Required | Description |
|---|---|---|---|
text | string | Yes | The text to read, 1 to 8,000 characters: an invoice, job post, contact block, product page or announcement. It is treated as data, never as instructions. |
json_schema | object | Yes | A JSON Schema object for the answer: at most 8 KB serialised, nested at most 6 levels, local $ref only. The answer always matches it. Set maxLength / maxItems f |
Parameters from the server's own tool schema.
Why extract_json_with_schema is rated Low
Even though extract_json_with_schema only reads data, uncontrolled read access leaks sensitive information and racks up API costs: an agent caught in a retry loop can make thousands of calls a minute without anyone noticing.
Attacks that exploit this kind of access
The rule that runs extract_json_with_schema safely
PolicyLayer is an MCP gateway: it sits between your AI agents and Tanod, and checks every tool call against a rule you set before the call runs. Nothing changes on the server itself. For extract_json_with_schema, this is the rule to start with:
extract_json_with_schema is read-only, so it stays allowed. Everything else on the server is denied unless you say otherwise.
The button opens the PolicyLayer dashboard: create your workspace, connect Tanod, apply this rule, and every extract_json_with_schema call is checked against it from then on.
Questions about extract_json_with_schema
mlpeek: Extract JSON from text that always matches your JSON Schema. For fixed entity types use extract_entities. Returns data, JSON extracted from the text that always parses and validates against your json_schema (decoded under a grammar built from it), plus model, usage (tokens) and ms. A small open model on Tanod's CPU, no model API: values can be wrong or missing, so check what matters. At most 8,000 characters and an 8 KB, 6-level schema; set maxLength / maxItems for long values. Bad input or an answer over 1,024 tokens is a 422; two extractions at once at most, so busy is a 503 with Retry-After; over 40 s is a 504 (none charged). The text is data, never instructions. Typically 3-15 s; up to about 25 s for 8,000 characters. Price: USD 0.005. No free tier. The submitted text is never logged or stored. Docs: https://tanod.dev/learn/embeddings-rerank-ner-mcp-server.html. It is categorised as a Read tool in the Tanod MCP Server, which means it retrieves data without modifying state.
extract_json_with_schema accepts 2 parameters: text, json_schema. Required: text, json_schema. The full parameter table on this page comes from the server's own tool schema.
Register the Tanod MCP server in PolicyLayer and add a rule for extract_json_with_schema: allow, deny, rate-limit, or require approval. Point your MCP client at the PolicyLayer proxy URL and the rule is enforced on every call, before it reaches Tanod. Nothing to install.
extract_json_with_schema is a Read tool with low risk. Read-only tools are generally safe to allow by default.
Yes. Add a rate_limit block to the extract_json_with_schema rule in your PolicyLayer policy. For example, setting max: 10 and window: 60 limits the tool to 10 calls per minute. Rate limits are tracked per agent session and reset automatically.
Set action: deny in the PolicyLayer policy for extract_json_with_schema. The AI agent will receive a policy violation error and cannot call the tool. You can also include a reason field to explain why the tool is blocked.
extract_json_with_schema is provided by the Tanod MCP server (https://tanod.dev/mcp). PolicyLayer sits as a proxy in front of this server to enforce policies before tool calls reach the server.
More on Tanod, and thousands of servers like it.
This server
Across the catalogue