---
title: "Get group members AI spend"
method: GET
path: "/api/v2/groups/{group}/members/ai/spend"
tags: ["Enterprise"]
---

# Get group members AI spend

`GET /api/v2/groups/{group}/members/ai/spend`

Returns aggregate AI spend attributed to the group per requested user.
A maximum of 100 user IDs may be requested per call, and requests with more are rejected, so callers are expected to batch across multiple requests.
User IDs that are not members of the group, or that the caller has no read access to, are silently omitted.

## Path parameters

- `group` string, uuid, required

## Query parameters

- `user_ids` string, required

## Response `200`

OK

- CodersdkGroupMembersAISpend
  - `members` CodersdkGroupMemberAISpend[]
    - `effective_group_id` string, uuid — EffectiveGroupID is the user's effective budget group within the queried group's organization, falling back to the Everyone group when no budget applies. Null when the effective group belongs to a different organization than the queried group.
    - `group_budget` CodersdkAIBudgetLimit
      - `limit_source` 'user_override' | 'group'
      - `spend_limit_micros` integer
    - `group_spend_micros` integer — GroupSpendMicros is the user's spend attributed to the queried group over the current budget period.
    - `user_id` string, uuid
  - `period_end` string, date-time — PeriodEnd is the exclusive upper bound of the current budget period.
  - `period_start` string, date-time — PeriodStart is the inclusive lower bound of the current budget period.

---

[API](https://skmtc.net/coder/apis/coder-api.md) · [All operations](https://skmtc.net/coder/apis/coder-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/coder/coder-api/versions/56b6e9f08540/schema)
