Browse the API reference

Get Graph Usage

get/v1/graphs/{graph_id}/usage

Part of Usage.

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

Authentication

Authenticate in any one of these ways — not all of them:

  • API key in the X-API-Key header.
  • Bearer token in the Authorization header.

Path parameters

NameTypeDescription
graph_idrequiredstringGraph Id

Query parameters

NameTypeDescription
time_rangeoptionalstringTime range: 24h, 7d, 30d, current_month, last_month

Default: "30d"

include_storageoptionalbooleanInclude storage usage summary

Default: true

include_creditsoptionalbooleanInclude credit consumption summary

Default: true

include_performanceoptionalbooleanInclude performance insights (may be slower)

Default: false

include_eventsoptionalbooleanInclude recent usage events

Default: false

Example request

curl
curl -X GET "https://api.robosystems.ai/v1/graphs/{graph_id}/usage" \
  -H "X-API-Key: $ROBOSYSTEMS_API_KEY"

Responses

200 Successful Response

FieldTypeDescription
graph_idrequiredstring

Graph database identifier

time_rangerequiredstring

Time range for usage data

storage_summaryoptionalStorageSummary

Storage usage summary

StorageSummary fields
FieldTypeDescription
graph_tierrequiredstring

Subscription tier

avg_storage_gbrequirednumber

Time-weighted average storage in GB over the period

max_storage_gbrequirednumber

Peak storage in GB

min_storage_gbrequirednumber

Minimum storage in GB

measurement_countrequiredinteger

Number of measurements taken

credit_summaryoptionalCreditSummary

Credit consumption summary

CreditSummary fields
FieldTypeDescription
graph_tierrequiredstring

Subscription tier

total_credits_consumedrequirednumber

Total credits consumed

total_base_costrequirednumber

Total base cost before multipliers

operation_breakdownrequiredobject

Credit usage by operation type

cached_operationsrequiredinteger

Number of cached operations

billable_operationsrequiredinteger

Number of billable operations

transaction_countrequiredinteger

Total transaction count

performance_insightsoptionalPerformanceInsights

Performance analytics

PerformanceInsights fields
FieldTypeDescription
analysis_period_daysrequiredinteger

Analysis period in days

total_operationsrequiredinteger

Total operations analyzed

operation_statsrequiredobject

Performance stats by operation type

slow_queriesrequiredobject[]

Top slow queries (over 5 seconds)

performance_scorerequiredinteger

Performance score (0-100)

recent_eventsoptionalobject[]

Recent usage events

timestamprequiredstring

Usage collection timestamp

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