Skip to main content
Glama

box_ai_extract_structured_using_template_tool

Extract structured data from Box files using templates to create single metadata records from one or multiple documents.

Instructions

Extract structured data from one or more files and return a SINGLE metadata instance.

This tool analyzes the provided file(s) and extracts information to populate a single metadata instance based on the specified template. When multiple files are provided, Box AI combines information from ALL files to create ONE complete metadata record.

Use cases:

  • Single file: Extract metadata from one receipt, invoice, or document

  • Multiple files: Combine data from multiple sources into one metadata instance (e.g., extract customer info from both a contract PDF and a supporting letter)

NOT for batch processing: If you need to extract metadata from multiple files as separate instances, call this tool once per file in a loop.

Args: ctx (Context): The context object containing the request and lifespan context. file_ids (List[str]): The IDs of the files to read. template_key (str): The ID of the template to use for extraction. ai_agent_id (Optional[str]): The ID of the AI agent to use for processing. Returns: dict: The extracted structured data in a json string format.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
file_idsYes
template_keyYes
ai_agent_idNo

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/box-community/mcp-server-box'

If you have feedback or need assistance with the MCP directory API, please join our Discord server