GET
/
v2
/
enterprise
/
metrics
/
usage
curl -X GET "https://api.devin.ai/v2/enterprise/metrics/usage" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "sessions_count": 127,
  "searches_count": 89,
  "prs_opened": 45,
  "prs_closed": 42,
  "prs_merged": 38
}
Returns usage metrics including session count, search count, and PR counts for your enterprise within the specified time period.
Only the GitHub app integration provides properly enriched statistics around PRs and PR status.

Query Parameters

start_date
string
Start date for the metrics period. Defaults to the beginning of the current billing cycle.
end_date
string
End date for the metrics period. Defaults to the current date.
org_ids
array
Array of organization IDs to filter metrics. If not provided, returns metrics for all organizations.
user_ids
array
Array of user IDs to filter metrics. If not provided, returns metrics for all users.

Response

sessions_count
integer
required
Total number of Devin sessions created in the specified period
searches_count
integer
required
Total number of Devin searches (ADA queries) run in the specified period
prs_opened
integer
required
Total number of pull requests opened in the specified period
prs_closed
integer
required
Total number of pull requests closed in the specified period
prs_merged
integer
required
Total number of pull requests merged in the specified period
curl -X GET "https://api.devin.ai/v2/enterprise/metrics/usage" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "sessions_count": 127,
  "searches_count": 89,
  "prs_opened": 45,
  "prs_closed": 42,
  "prs_merged": 38
}