---
title: "Get Graph Usage"
method: GET
path: "/v1/graphs/{graph_id}/usage"
tags: ["Usage"]
---

# Get Graph Usage

`GET /v1/graphs/{graph_id}/usage`

## Request

- Base URL: `https://api.robosystems.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.robosystems.ai/v1/graphs/{graph_id}/usage`
- Auth: one of:
  - API key in header `X-API-Key`
  - HTTP bearer

Time ranges: 24h, 7d, 30d, current_month, last_month. Toggle storage, credits, performance, and events sections via query params.

## Path parameters

- `graph_id` string, required

## Query parameters

- `time_range` string: Time range: 24h, 7d, 30d, current_month, last_month
- `include_storage` boolean: Include storage usage summary
- `include_credits` boolean: Include credit consumption summary
- `include_performance` boolean: Include performance insights (may be slower)
- `include_events` boolean: Include recent usage events

## Response `200`

Successful Response

- GraphUsageResponse: Response model for graph usage statistics.
  - `graph_id` string, required: Graph database identifier
  - `time_range` string, required: Time range for usage data
  - `storage_summary` StorageSummary: Storage usage summary.
    - `graph_tier` string, required: Subscription tier
    - `avg_storage_gb` number, required: Time-weighted average storage in GB over the period
    - `max_storage_gb` number, required: Peak storage in GB
    - `min_storage_gb` number, required: Minimum storage in GB
    - `measurement_count` integer, required: Number of measurements taken
  - `credit_summary` CreditSummary: Credit consumption summary.
    - `graph_tier` string, required: Subscription tier
    - `total_credits_consumed` number, required: Total credits consumed
    - `total_base_cost` number, required: Total base cost before multipliers
    - `operation_breakdown` object, required: Credit usage by operation type
    - `cached_operations` integer, required: Number of cached operations
    - `billable_operations` integer, required: Number of billable operations
    - `transaction_count` integer, required: Total transaction count
  - `performance_insights` PerformanceInsights: Performance analytics.
    - `analysis_period_days` integer, required: Analysis period in days
    - `total_operations` integer, required: Total operations analyzed
    - `operation_stats` object, required: Performance stats by operation type
    - `slow_queries` object[], required: Top slow queries (over 5 seconds)
    - `performance_score` integer, required: Performance score (0-100)
  - `recent_events` object[]: Recent usage events
  - `timestamp` string, required: Usage collection timestamp

## Other responses

- `400`: Invalid request
- `401`: Authentication required
- `403`: Access denied
- `404`: Resource not found
- `422`: Validation Error
- `429`: Rate limit exceeded
- `500`: Internal server error

---

[API](https://skmtc.dev/robosystems/apis/robosystems-api.md) · [All operations](https://skmtc.dev/robosystems/apis/robosystems-api/llms.txt) · [OpenAPI document](https://skmtc.dev/robosystems/apis/robosystems-api/revisions/e661e2d5ca6a?raw)
