Skip to main content

meteosource_tool/
lib.rs

1//! Meteosource weather integration for the agent platform.
2//!
3//! The crate exposes a tool that resolves a place name and retrieves its
4//! current weather and hourly forecast from the Meteosource API.
5
6mod tool;
7mod weather;
8
9use std::path::PathBuf;
10
11use agent_config::ConfigError;
12use agent_runtime::ToolRegistry;
13
14/// Register the Meteosource weather tool.
15pub fn register_tools(registry: &mut ToolRegistry) -> Result<(), ConfigError> {
16    let definition_path = PathBuf::from(env!("CARGO_MANIFEST_DIR")).join("data/meteosource.toml");
17    registry.register_from_file(definition_path, tool::MeteosourceWeather)
18}