Skip to main content
GET
/
api
/
reports
/
dashboard
Get Dashboard Summary
curl --request GET \
  --url https://api.example.com/api/reports/dashboard
{
  "summary": {
    "income": 123,
    "expense": 123,
    "cashFlow": 123,
    "totalAvailable": 123
  },
  "chartData": [
    {
      "categoryName": "<string>",
      "total": 123,
      "color": "<string>"
    }
  ],
  "expensesAnalysis": {
    "fixed": 123,
    "variable": 123
  }
}
Retrieves comprehensive financial analytics and summary statistics for the authenticated user’s dashboard.

Authentication

Requires Bearer token authentication via Authorization header.

Query Parameters

accountId
string
Filter statistics by a specific account. If omitted, returns data for all accounts.

Response

Returns a comprehensive analytics object with summary metrics, category breakdown, and expense analysis.
summary
object
Overall financial summary metrics
chartData
array
Expense breakdown by category, sorted by total (descending)
expensesAnalysis
object
Analysis of fixed vs variable expenses

Example Request

curl -X GET "https://api.yourfinanceapp.com/api/reports/dashboard?accountId=account_123" \
  -H "Authorization: Bearer YOUR_TOKEN"

Example Response

{
  "summary": {
    "income": 5000.00,
    "expense": 3200.50,
    "cashFlow": 1799.50,
    "totalAvailable": 12500.00
  },
  "chartData": [
    {
      "categoryName": "Housing",
      "total": 1200.00,
      "color": "#3b82f6"
    },
    {
      "categoryName": "Food",
      "total": 850.50,
      "color": "#10b981"
    },
    {
      "categoryName": "Transportation",
      "total": 450.00,
      "color": "#f59e0b"
    }
  ],
  "expensesAnalysis": {
    "fixed": 1800.00,
    "variable": 1400.50
  }
}

Use Cases

  • Dashboard Visualization: Display financial overview with charts and metrics
  • Budget Tracking: Monitor spending patterns across categories
  • Financial Planning: Analyze fixed vs variable expenses for budgeting
  • Account Filtering: View metrics for specific accounts or all accounts combined

Notes

  • Transfer transactions are automatically excluded from income/expense calculations
  • Categories containing “Transferencia” (case-insensitive) are filtered out
  • Chart data is sorted by total amount in descending order
  • When accountId is provided, totalAvailable reflects only that account’s balance
  • Without accountId, totalAvailable shows the sum of all user accounts

Build docs developers (and LLMs) love