Skip to main content
Glama

get_current_time

Retrieve the current date and time for integration with AI agents or automated workflows using the Slim MCP server's RESTful API.

Instructions

Get the current date and time.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that implements the logic for the 'get_current_time' tool, returning the current local date and time as a formatted string.
    def get_current_time() -> str: """Get the current date and time. """ now = datetime.now() return f"Current date and time: {now.strftime('%Y-%m-%d %H:%M:%S')}"
  • Registers the 'get_current_time' function as an MCP tool using the decorator.
    mcp.tool()(get_current_time)

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/webdevtodayjason/slim-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server