Skip to main content
Glama
FINANCIAL_ENDPOINT_FINDINGS.md3.74 kB
# Financial Endpoint Investigation - Findings ## Summary The `/financialReports` endpoint **does not exist** or is **not accessible** for the current Hostaway account (161051). ## Test Results ### ✅ Working Endpoints - **OAuth Authentication**: Successfully obtaining access tokens - **GET /listings**: Returns 200 with property data - **GET /reservations**: Returns 200 with booking data (via MCP server) ### ❌ Not Working - **GET /financialReports**: Returns 404 "Resource not found" - **All variations tested**: - `/financialReports` - `/financial/reports` - `/reports/financial` - With different parameter formats (`startDate` vs `start_date`) ## Root Cause The 404 error indicates one of the following: 1. **Account Permissions**: The Hostaway account (161051) may not have access to the Financial Reporting feature - This is a premium/enterprise feature in many property management systems - Requires specific plan tier or add-on 2. **API Version Mismatch**: The endpoint might be in a different API version - Current tests use: `https://api.hostaway.com/v1` - Financial features might be in v2 or require different base URL 3. **Feature Not Enabled**: Even if the account has the right tier, the financial reporting module may need to be explicitly enabled in the Hostaway dashboard ## Evidence ```bash # Authentication works ✅ Got access token: eyJ0eXAiOiJKV1QiLCJh... # Basic endpoints work ✅ /listings endpoint works! Status: 200 Response keys: ['status', 'result', 'count', 'limit', 'offset'] # Financial endpoint doesn't exist ❌ /financialReports Status: 404 Error: {'status': 'fail', 'message': 'Resource not found'} ``` ## Next Steps ### Option 1: Verify Account Access 1. Log into your Hostaway account at https://dashboard.hostaway.com 2. Check your account plan/tier 3. Verify if "Financial Reports" or "Revenue Analytics" features are available 4. If not available, contact Hostaway support to enable or upgrade ### Option 2: Check Hostaway Documentation 1. Contact Hostaway support to get: - List of available endpoints for your account tier - Documentation for financial reporting (if available) - Alternative endpoints for revenue/expense data ### Option 3: Use Alternative Data Sources Since direct financial reports aren't available, you can calculate financials from available data: ```python # Get reservations with revenue data reservations = await client.get_reservations() # Calculate totals total_revenue = sum(r.get('totalPrice', 0) for r in reservations) total_bookings = len(reservations) # Get listing expenses (if available in listing details) listings = await client.get_listings() # Check if listings include expense/cost fields ``` ## Recommendation **The financial endpoint implementation in the codebase is aspirational** - it was built based on what the API *should* provide, but the actual Hostaway account doesn't have access to this feature. **Immediate Actions**: 1. Remove or document the financial endpoints as "requires premium Hostaway account" 2. Add feature detection to return a helpful error message 3. Consider implementing calculated financials from reservation data as a workaround ## Files Affected - `src/api/routes/financial.py` - API route implementation - `src/services/hostaway_client.py` - Client methods (lines 425-477) - `tests/integration/test_financial_api.py` - Tests using mocks (not real API) ## Technical Details **Test Script**: `test_hostaway_direct.py` **Tested Against**: Hostaway API v1 (https://api.hostaway.com/v1) **Account ID**: 161051 **Test Date**: 2025-10-19 --- **Status**: ⚠️ Feature Not Available **Action Required**: Account verification/upgrade or implement workaround

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/darrentmorgan/hostaway-mcp'

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