Annotation-Based Discovery
Overview
Two Discovery Methods
Method
Purpose
Use Case
scan() — Packages & Directories
// Dot-notation package path
MCPServer( "myApp" ).scan( "models.tools" )
// Dot-notation with recursion disabled
MCPServer( "myApp" ).scan( "models.tools", false )
// Absolute directory path
MCPServer( "myApp" ).scan( "/path/to/tools/" )
// Relative directory path
MCPServer( "myApp" ).scan( "./tools" )scanClass() — Single Classes
Mixing scan() and scanClass()
@mcpTool Annotation
@mcpResource Annotation
@mcpPrompt Annotation
Complete Example
Project Structure
SearchTools.bx
AdminTools.bx
Application.bx
Benefits of Annotation-Based Discovery
Next Steps
Last updated