@hashgraphonline/standards-agent-kit
Version:
A modular SDK for building on-chain autonomous agents using Hashgraph Online Standards, including HCS-10 for agent discovery and communication.
46 lines (45 loc) • 1.67 kB
TypeScript
import { StructuredTool } from '@langchain/core/tools';
import { z } from 'zod';
import { IPlugin } from '../PluginInterface';
/**
* A Langchain tool to get the current HBAR price in USD.
*/
export declare class GetHbarPriceTool extends StructuredTool {
name: string;
description: string;
schema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
/**
* DISCLAIMER: THIS TOOL USES THE EXCHANGE RATE ENDPOINT FROM THE MIRROR NODE, AND IT IS NOT GUARANTEED TO BE ACCURATE.
* USE AN ORACLE OR OTHER SOURCES FOR PRODUCTION USE WHERE PRICE IS IMPORTANT.
* Retrieves the current price of HBAR in USD from the Hedera Mirror Node.
* @returns A promise that resolves to a string containing the current HBAR price in USD.
*/
protected _call(): Promise<string>;
}
/**
* DISCLAIMER: THIS PLUGIN USES THE EXCHANGE RATE ENDPOINT FROM THE MIRROR NODE, AND IT IS NOT GUARANTEED TO BE ACCURATE.
* USE AN ORACLE OR OTHER SOURCES FOR PRODUCTION USE WHERE PRICE IS IMPORTANT.
* Plugin to provide tools related to Hedera network information, like HBAR price.
*/
export declare class HbarPricePlugin implements IPlugin {
id: string;
name: string;
description: string;
version: string;
author: string;
private tools;
constructor();
/**
* Initializes the plugin. Currently no specific initialization needed.
*/
initialize(): Promise<void>;
/**
* Returns the tools provided by this plugin.
* @returns An array containing the GetHbarPriceTool.
*/
getTools(): StructuredTool[];
/**
* Cleans up resources. Currently no cleanup needed.
*/
cleanup(): Promise<void>;
}