JustAMCPResourceExecutor๏
Inherits: Object
Lists and resolves resources exposed through the MCP resource API.
Description๏
JustAMCPResourceExecutor owns registered JustAMCPResource instances and resolves read requests by URI. It supports both fixed resources, such as system logs, and URI templates, such as project files under res://.
var resources = JustAMCPResourceExecutor.new()
var templates = resources.list_resource_templates()
var project_file = resources.read_resource("res://project.godot")
print(templates)
print(project_file)
Methods๏
void |
add_resource(resource: JustAMCPResource) |
list_resource_templates(cursor: String = "") |
|
list_resources(cursor: String = "") |
|
read_resource(uri: String) |
Method Descriptions๏
void add_resource(resource: JustAMCPResource) ๐
Registers a JustAMCPResource instance so it appears in resource listings and can service matching read requests.
Dictionary list_resource_templates(cursor: String = "") ๐
Returns a paginated MCP resources/templates/list dictionary with resourceTemplates and optional nextCursor.
Dictionary list_resources(cursor: String = "") ๐
Returns a paginated MCP resources/list dictionary with resources and optional nextCursor.
Dictionary read_resource(uri: String) ๐
Finds the registered resource that matches uri, reads it, and returns its contents. Legacy godot:// URIs are canonicalized to blazium:// where supported.