Skip to content

Add support for AI Credit billing endpoint #4262

@elliotpeele

Description

@elliotpeele

With the recent introduction of AI Credits, there is a new endpoint for AI Credit usage:

/organizations/ORG/settings/billing/ai_credit/usage

The data structure looks to be the same as the premium request billing API.

{
"timePeriod": {
"year": 2026,
"month": 6
},
"organization": "ORG",
"usageItems": [
{
"product": "Copilot",
"sku": "Copilot AI Credits",
"model": "Auto: Claude Haiku 4.5",
"unitType": "ai-credits",
"pricePerUnit": 0.01,
"grossQuantity": 3956.1799545,
"grossAmount": 39.561799545,
"discountQuantity": 3956.1799545,
"discountAmount": 39.561799545,
"netQuantity": 0.0,
"netAmount": 0.0
},
{
"product": "Copilot",
"sku": "Copilot AI Credits",
"model": "Auto: Claude Sonnet 4.6",
"unitType": "ai-credits",
"pricePerUnit": 0.01,
"grossQuantity": 9498.6969165,
"grossAmount": 94.986969165,
"discountQuantity": 9564.710256,
"discountAmount": 95.64710256,
"netQuantity": 0.0,
"netAmount": 0.0
}
]
}

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions