fix: add optional reason parameter to all tools for MCP compatibility
All checks were successful
Build and Push Monarch MCP Docker Image / build (push) Successful in 10s
All checks were successful
Build and Push Monarch MCP Docker Image / build (push) Successful in 10s
This commit is contained in:
@@ -39,7 +39,7 @@ def serialize_json(data: Any) -> str:
|
||||
|
||||
|
||||
@mcp.tool()
|
||||
async def get_accounts() -> str:
|
||||
async def get_accounts(reason: Optional[str] = None) -> str:
|
||||
"""Get all financial accounts from Monarch Money."""
|
||||
try:
|
||||
client = await get_authenticated_client()
|
||||
@@ -112,7 +112,7 @@ async def get_transactions(
|
||||
|
||||
|
||||
@mcp.tool()
|
||||
async def get_budgets() -> str:
|
||||
async def get_budgets(reason: Optional[str] = None) -> str:
|
||||
"""Get current budget information."""
|
||||
try:
|
||||
client = await get_authenticated_client()
|
||||
@@ -137,7 +137,7 @@ async def get_budgets() -> str:
|
||||
|
||||
|
||||
@mcp.tool()
|
||||
async def get_account_holdings(account_id: str) -> str:
|
||||
async def get_account_holdings(account_id: str, reason: Optional[str] = None) -> str:
|
||||
"""Get investment holdings for a specific account."""
|
||||
try:
|
||||
client = await get_authenticated_client()
|
||||
@@ -150,7 +150,7 @@ async def get_account_holdings(account_id: str) -> str:
|
||||
|
||||
|
||||
@mcp.tool()
|
||||
async def refresh_accounts() -> str:
|
||||
async def refresh_accounts(reason: Optional[str] = None) -> str:
|
||||
"""Request a refresh of account data from financial institutions."""
|
||||
try:
|
||||
client = await get_authenticated_client()
|
||||
|
||||
Reference in New Issue
Block a user