Class FtpDownloadTool
A built-in tool for downloading a file from an FTP server.
Downloads a remote file and either saves it to a local path or returns the content as text. When returning as text, content is truncated to the configured maximum text length. Local path access is validated against the configured allow/block lists.
public sealed class FtpDownloadTool : IBuiltInTool, ITool, IToolMetadata
- Inheritance
-
FtpDownloadTool
- Implements
- Inherited Members
Examples
var download = new FtpDownloadTool(new FtpToolOptions
{
Host = "ftp.example.com",
Username = "user",
Password = "pass"
});
Constructors
- FtpDownloadTool()
Initializes a new instance with default options.
- FtpDownloadTool(FtpToolOptions)
Initializes a new instance with the specified options.
Properties
- Description
Gets a concise description of what the tool does.
- InputSchema
Gets the JSON Schema defining the expected input arguments.
- Name
Gets the stable, unique identifier for this tool.
Methods
- InvokeAsync(string, CancellationToken)
Executes the tool with the specified JSON arguments.