See the AI allowance by person
const url = 'https://forge.example.com/api/billing/ai-caps';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://forge.example.com/api/billing/ai-caps \ --header 'Authorization: Bearer <token>'Everyone in the organization with what their calls on the instance’s own AI account cost this month, the most first, in millionths of a dollar, and the caps on each person’s share: default (kind none, dollars with microdollars, or share with percent of the month’s pool), defaultCapMicrodollars (what the default comes to, null for none), and for each person ownCapMicrodollars (set for them alone, null for none), capMicrodollars (the cap in force, null for none) and stopped. pool and poolSpent are the organization’s month. applies is false when the organization has no plan with an AI allowance, and nothing can then be set. With no cap set the pool is shared freely; the organization’s month and day apply on top of any cap. For administrators.
Authorizations
Section titled “Authorizations”Responses
Section titled “Responses”OK
object
object
object
Example generated
{ "applies": true, "poolMicrodollars": 1, "poolSpentMicrodollars": 1, "default": { "kind": "example", "microdollars": 1, "percent": 1 }, "defaultCapMicrodollars": 1, "version": 1, "people": [ { "personId": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "name": "example", "active": true, "spentMicrodollars": 1, "ownCapMicrodollars": 1, "capMicrodollars": 1, "stopped": true } ]}default
Section titled “default”A refusal or an error, as a problem document. A model or draft you may not see answers 404, as one that does not exist.
object
Example generated
{ "type": "example", "title": "example", "status": 1, "detail": "example", "instance": "example"}