@lumoauth/api-client 1.3.0 → 1.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (237) hide show
  1. package/.openapi-generator/FILES +22 -0
  2. package/README.md +19 -5
  3. package/api/admin-agents-api.ts +166 -10
  4. package/api/admin-mcp-api.ts +5 -5
  5. package/api/admin-oauth-clients-api.ts +5 -5
  6. package/api/admin-sandbox-api.ts +5 -5
  7. package/api/admin-users-api.ts +27 -26
  8. package/api/admin-webhooks-api.ts +25 -25
  9. package/api/agents-api.ts +118 -0
  10. package/api/oauth-api.ts +111 -0
  11. package/dist/api/admin-agents-api.d.ts +94 -4
  12. package/dist/api/admin-agents-api.js +100 -10
  13. package/dist/api/admin-mcp-api.d.ts +5 -5
  14. package/dist/api/admin-mcp-api.js +4 -4
  15. package/dist/api/admin-oauth-clients-api.d.ts +5 -5
  16. package/dist/api/admin-oauth-clients-api.js +4 -4
  17. package/dist/api/admin-sandbox-api.d.ts +5 -5
  18. package/dist/api/admin-sandbox-api.js +4 -4
  19. package/dist/api/admin-users-api.d.ts +27 -26
  20. package/dist/api/admin-users-api.js +21 -20
  21. package/dist/api/admin-webhooks-api.d.ts +25 -25
  22. package/dist/api/admin-webhooks-api.js +20 -20
  23. package/dist/api/agents-api.d.ts +65 -0
  24. package/dist/api/agents-api.js +77 -0
  25. package/dist/api/oauth-api.d.ts +65 -0
  26. package/dist/api/oauth-api.js +72 -0
  27. package/dist/esm/api/admin-agents-api.d.ts +94 -4
  28. package/dist/esm/api/admin-agents-api.js +100 -10
  29. package/dist/esm/api/admin-mcp-api.d.ts +5 -5
  30. package/dist/esm/api/admin-mcp-api.js +4 -4
  31. package/dist/esm/api/admin-oauth-clients-api.d.ts +5 -5
  32. package/dist/esm/api/admin-oauth-clients-api.js +4 -4
  33. package/dist/esm/api/admin-sandbox-api.d.ts +5 -5
  34. package/dist/esm/api/admin-sandbox-api.js +4 -4
  35. package/dist/esm/api/admin-users-api.d.ts +27 -26
  36. package/dist/esm/api/admin-users-api.js +21 -20
  37. package/dist/esm/api/admin-webhooks-api.d.ts +25 -25
  38. package/dist/esm/api/admin-webhooks-api.js +20 -20
  39. package/dist/esm/api/agents-api.d.ts +65 -0
  40. package/dist/esm/api/agents-api.js +77 -0
  41. package/dist/esm/api/oauth-api.d.ts +65 -0
  42. package/dist/esm/api/oauth-api.js +73 -1
  43. package/dist/esm/models/abac-attribute-definition.d.ts +1 -1
  44. package/dist/esm/models/abac-resource-attribute.d.ts +1 -1
  45. package/dist/esm/models/admin-agents-agents-rotate-key-request.d.ts +30 -0
  46. package/dist/esm/models/admin-agents-agents-rotate-key-request.js +14 -0
  47. package/dist/esm/models/admin-agents-agents-rotate-key-response.d.ts +6 -0
  48. package/dist/esm/models/admin-agents-create-request.d.ts +8 -0
  49. package/dist/esm/models/admin-agents-report-usage-request.d.ts +30 -0
  50. package/dist/esm/models/admin-agents-report-usage-request.js +14 -0
  51. package/dist/esm/models/admin-agents-report-usage-response-data-recorded.d.ts +30 -0
  52. package/dist/esm/models/admin-agents-report-usage-response-data-recorded.js +14 -0
  53. package/dist/esm/models/admin-agents-report-usage-response-data.d.ts +33 -0
  54. package/dist/esm/models/admin-agents-report-usage-response-data.js +14 -0
  55. package/dist/esm/models/admin-agents-report-usage-response.d.ts +25 -0
  56. package/dist/esm/models/admin-agents-report-usage-response.js +14 -0
  57. package/dist/esm/models/admin-audit-logs-retention-response-data.d.ts +21 -3
  58. package/dist/esm/models/admin-identities-link-request.d.ts +8 -1
  59. package/dist/esm/models/admin-identities-link-request.js +1 -0
  60. package/dist/esm/models/admin-identities-list-response-data-bindings-item.d.ts +7 -0
  61. package/dist/esm/models/admin-identities-list-response-data-bindings-item.js +1 -0
  62. package/dist/esm/models/admin-sandbox-spawn-response-data.d.ts +18 -0
  63. package/dist/esm/models/admin-sandbox-spawn-response-data.js +14 -0
  64. package/dist/esm/models/admin-sandbox-spawn-response-data1.d.ts +24 -0
  65. package/dist/esm/models/admin-sandbox-spawn-response-data1.js +14 -0
  66. package/dist/esm/models/admin-sandbox-spawn-response.d.ts +3 -3
  67. package/dist/esm/models/admin-webhooks-delivery-replay-response-data.d.ts +48 -0
  68. package/dist/esm/models/admin-webhooks-delivery-replay-response-data.js +14 -0
  69. package/dist/esm/models/admin-webhooks-delivery-replay-response.d.ts +3 -3
  70. package/dist/esm/models/admin-webhooks-test-response.d.ts +6 -0
  71. package/dist/esm/models/attest-response-identity.d.ts +1 -1
  72. package/dist/esm/models/audit-log-entry.d.ts +1 -1
  73. package/dist/esm/models/authentication-settings-password-policy.d.ts +25 -1
  74. package/dist/esm/models/authentication-settings-password-rotation-policy.d.ts +1 -13
  75. package/dist/esm/models/authentication-settings.d.ts +13 -15
  76. package/dist/esm/models/authentication-settings.js +11 -0
  77. package/dist/esm/models/get-approval-status-response-approved-by.d.ts +2 -2
  78. package/dist/esm/models/index.d.ts +11 -0
  79. package/dist/esm/models/index.js +11 -0
  80. package/dist/esm/models/list-permissions-response-permissions-item.d.ts +1 -1
  81. package/dist/esm/models/oauth-client-secret-issued.d.ts +1 -1
  82. package/dist/esm/models/oauth-client.d.ts +6 -0
  83. package/dist/esm/models/push-enrollment-started.d.ts +1 -1
  84. package/dist/esm/models/put-admin-agents-update-request.d.ts +8 -0
  85. package/dist/esm/models/report-agent-usage-response.d.ts +33 -0
  86. package/dist/esm/models/report-agent-usage-response.js +14 -0
  87. package/dist/esm/models/request-magic-link-request.d.ts +42 -0
  88. package/dist/esm/models/request-magic-link-request.js +14 -0
  89. package/dist/esm/models/request-magic-link-response.d.ts +31 -0
  90. package/dist/esm/models/request-magic-link-response.js +21 -0
  91. package/dist/esm/models/scim-settings-inbound-protected-attributes.d.ts +2 -9
  92. package/dist/esm/models/scim-settings-inbound.d.ts +0 -8
  93. package/dist/esm/models/scim-settings-outbound.d.ts +2 -10
  94. package/dist/esm/models/set-user-attribute-response-data.d.ts +1 -1
  95. package/dist/esm/models/userinfo-response.d.ts +8 -0
  96. package/dist/models/abac-attribute-definition.d.ts +1 -1
  97. package/dist/models/abac-resource-attribute.d.ts +1 -1
  98. package/dist/models/admin-agents-agents-rotate-key-request.d.ts +30 -0
  99. package/dist/models/admin-agents-agents-rotate-key-request.js +15 -0
  100. package/dist/models/admin-agents-agents-rotate-key-response.d.ts +6 -0
  101. package/dist/models/admin-agents-create-request.d.ts +8 -0
  102. package/dist/models/admin-agents-report-usage-request.d.ts +30 -0
  103. package/dist/models/admin-agents-report-usage-request.js +15 -0
  104. package/dist/models/admin-agents-report-usage-response-data-recorded.d.ts +30 -0
  105. package/dist/models/admin-agents-report-usage-response-data-recorded.js +15 -0
  106. package/dist/models/admin-agents-report-usage-response-data.d.ts +33 -0
  107. package/dist/models/admin-agents-report-usage-response-data.js +15 -0
  108. package/dist/models/admin-agents-report-usage-response.d.ts +25 -0
  109. package/dist/models/admin-agents-report-usage-response.js +15 -0
  110. package/dist/models/admin-audit-logs-retention-response-data.d.ts +21 -3
  111. package/dist/models/admin-identities-link-request.d.ts +8 -1
  112. package/dist/models/admin-identities-link-request.js +1 -0
  113. package/dist/models/admin-identities-list-response-data-bindings-item.d.ts +7 -0
  114. package/dist/models/admin-identities-list-response-data-bindings-item.js +1 -0
  115. package/dist/models/admin-sandbox-spawn-response-data.d.ts +18 -0
  116. package/dist/models/admin-sandbox-spawn-response-data.js +15 -0
  117. package/dist/models/admin-sandbox-spawn-response-data1.d.ts +24 -0
  118. package/dist/models/admin-sandbox-spawn-response-data1.js +15 -0
  119. package/dist/models/admin-sandbox-spawn-response.d.ts +3 -3
  120. package/dist/models/admin-webhooks-delivery-replay-response-data.d.ts +48 -0
  121. package/dist/models/admin-webhooks-delivery-replay-response-data.js +15 -0
  122. package/dist/models/admin-webhooks-delivery-replay-response.d.ts +3 -3
  123. package/dist/models/admin-webhooks-test-response.d.ts +6 -0
  124. package/dist/models/attest-response-identity.d.ts +1 -1
  125. package/dist/models/audit-log-entry.d.ts +1 -1
  126. package/dist/models/authentication-settings-password-policy.d.ts +25 -1
  127. package/dist/models/authentication-settings-password-rotation-policy.d.ts +1 -13
  128. package/dist/models/authentication-settings.d.ts +13 -15
  129. package/dist/models/authentication-settings.js +12 -1
  130. package/dist/models/get-approval-status-response-approved-by.d.ts +2 -2
  131. package/dist/models/index.d.ts +11 -0
  132. package/dist/models/index.js +11 -0
  133. package/dist/models/list-permissions-response-permissions-item.d.ts +1 -1
  134. package/dist/models/oauth-client-secret-issued.d.ts +1 -1
  135. package/dist/models/oauth-client.d.ts +6 -0
  136. package/dist/models/push-enrollment-started.d.ts +1 -1
  137. package/dist/models/put-admin-agents-update-request.d.ts +8 -0
  138. package/dist/models/report-agent-usage-response.d.ts +33 -0
  139. package/dist/models/report-agent-usage-response.js +15 -0
  140. package/dist/models/request-magic-link-request.d.ts +42 -0
  141. package/dist/models/request-magic-link-request.js +15 -0
  142. package/dist/models/request-magic-link-response.d.ts +31 -0
  143. package/dist/models/request-magic-link-response.js +24 -0
  144. package/dist/models/scim-settings-inbound-protected-attributes.d.ts +2 -9
  145. package/dist/models/scim-settings-inbound.d.ts +0 -8
  146. package/dist/models/scim-settings-outbound.d.ts +2 -10
  147. package/dist/models/set-user-attribute-response-data.d.ts +1 -1
  148. package/dist/models/userinfo-response.d.ts +8 -0
  149. package/docs/AAuthApi.md +1 -1
  150. package/docs/AdminAbacApi.md +1 -1
  151. package/docs/AdminAgentsAgentsRotateKeyRequest.md +22 -0
  152. package/docs/AdminAgentsAgentsRotateKeyResponse.md +2 -0
  153. package/docs/AdminAgentsApi.md +83 -8
  154. package/docs/AdminAgentsCreateRequest.md +2 -0
  155. package/docs/AdminAgentsReportUsageRequest.md +22 -0
  156. package/docs/AdminAgentsReportUsageResponse.md +20 -0
  157. package/docs/AdminAgentsReportUsageResponseData.md +22 -0
  158. package/docs/AdminAgentsReportUsageResponseDataRecorded.md +22 -0
  159. package/docs/AdminAuditLogsRetentionResponseData.md +9 -3
  160. package/docs/AdminIdentitiesLinkRequest.md +3 -1
  161. package/docs/AdminIdentitiesListResponseDataBindingsItem.md +2 -0
  162. package/docs/AdminMcpApi.md +2 -1
  163. package/docs/AdminOAuthClientsApi.md +2 -2
  164. package/docs/AdminSandboxApi.md +3 -1
  165. package/docs/AdminSandboxSpawnResponse.md +1 -1
  166. package/docs/AdminSandboxSpawnResponseData.md +32 -0
  167. package/docs/AdminSandboxSpawnResponseData1.md +20 -0
  168. package/docs/AdminUsersApi.md +8 -8
  169. package/docs/AdminWebhooksApi.md +7 -5
  170. package/docs/AdminWebhooksDeliveryReplayResponse.md +1 -1
  171. package/docs/AdminWebhooksDeliveryReplayResponseData.md +28 -0
  172. package/docs/AdminWebhooksTestResponse.md +2 -0
  173. package/docs/AgentsApi.md +64 -2
  174. package/docs/AttestResponseIdentity.md +1 -1
  175. package/docs/AuditLogEntry.md +1 -1
  176. package/docs/AuthenticationSettings.md +2 -6
  177. package/docs/AuthenticationSettingsPasswordPolicy.md +9 -0
  178. package/docs/AuthenticationSettingsPasswordRotationPolicy.md +1 -4
  179. package/docs/AuthorizationApi.md +1 -1
  180. package/docs/CreateClientResponseData.md +3 -1
  181. package/docs/EnrollAuthenticator201Response.md +1 -1
  182. package/docs/GetApprovalStatusResponseApprovedBy.md +1 -1
  183. package/docs/JitApi.md +3 -3
  184. package/docs/ListPermissionsResponsePermissionsItem.md +1 -1
  185. package/docs/OAuthApi.md +63 -2
  186. package/docs/OAuthClient.md +2 -0
  187. package/docs/OAuthClientSecretIssued.md +1 -1
  188. package/docs/OIDCApi.md +2 -2
  189. package/docs/PushEnrollmentStarted.md +1 -1
  190. package/docs/PutAdminAgentsUpdateRequest.md +2 -0
  191. package/docs/ReportAgentUsageResponse.md +22 -0
  192. package/docs/RequestMagicLinkRequest.md +26 -0
  193. package/docs/RequestMagicLinkResponse.md +20 -0
  194. package/docs/ScimSettingsInbound.md +0 -2
  195. package/docs/ScimSettingsInboundProtectedAttributes.md +3 -5
  196. package/docs/ScimSettingsOutbound.md +2 -4
  197. package/docs/TokenVaultApi.md +2 -2
  198. package/docs/UserinfoResponse.md +2 -0
  199. package/models/abac-attribute-definition.ts +1 -1
  200. package/models/abac-resource-attribute.ts +1 -1
  201. package/models/admin-agents-agents-rotate-key-request.ts +36 -0
  202. package/models/admin-agents-agents-rotate-key-response.ts +6 -0
  203. package/models/admin-agents-create-request.ts +6 -0
  204. package/models/admin-agents-report-usage-request.ts +36 -0
  205. package/models/admin-agents-report-usage-response-data-recorded.ts +36 -0
  206. package/models/admin-agents-report-usage-response-data.ts +39 -0
  207. package/models/admin-agents-report-usage-response.ts +33 -0
  208. package/models/admin-audit-logs-retention-response-data.ts +21 -3
  209. package/models/admin-identities-link-request.ts +8 -1
  210. package/models/admin-identities-list-response-data-bindings-item.ts +7 -0
  211. package/models/admin-sandbox-spawn-response-data.ts +29 -0
  212. package/models/admin-sandbox-spawn-response-data1.ts +30 -0
  213. package/models/admin-sandbox-spawn-response.ts +3 -3
  214. package/models/admin-webhooks-delivery-replay-response-data.ts +54 -0
  215. package/models/admin-webhooks-delivery-replay-response.ts +3 -3
  216. package/models/admin-webhooks-test-response.ts +6 -0
  217. package/models/attest-response-identity.ts +1 -1
  218. package/models/audit-log-entry.ts +1 -1
  219. package/models/authentication-settings-password-policy.ts +25 -1
  220. package/models/authentication-settings-password-rotation-policy.ts +1 -13
  221. package/models/authentication-settings.ts +13 -15
  222. package/models/get-approval-status-response-approved-by.ts +2 -2
  223. package/models/index.ts +11 -0
  224. package/models/list-permissions-response-permissions-item.ts +1 -1
  225. package/models/oauth-client-secret-issued.ts +1 -1
  226. package/models/oauth-client.ts +6 -0
  227. package/models/push-enrollment-started.ts +1 -1
  228. package/models/put-admin-agents-update-request.ts +6 -0
  229. package/models/report-agent-usage-response.ts +39 -0
  230. package/models/request-magic-link-request.ts +48 -0
  231. package/models/request-magic-link-response.ts +39 -0
  232. package/models/scim-settings-inbound-protected-attributes.ts +2 -10
  233. package/models/scim-settings-inbound.ts +0 -6
  234. package/models/scim-settings-outbound.ts +2 -8
  235. package/models/set-user-attribute-response-data.ts +1 -1
  236. package/models/userinfo-response.ts +6 -0
  237. package/package.json +1 -1
package/api/agents-api.ts CHANGED
@@ -22,6 +22,8 @@ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObj
22
22
  // @ts-ignore
23
23
  import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base';
24
24
  // @ts-ignore
25
+ import type { AdminAgentsReportUsageRequest } from '../models';
26
+ // @ts-ignore
25
27
  import type { AskRequest } from '../models';
26
28
  // @ts-ignore
27
29
  import type { AskResponse } from '../models';
@@ -46,6 +48,8 @@ import type { GetCurrentAgentResponse } from '../models';
46
48
  // @ts-ignore
47
49
  import type { RegisterAgentResponse } from '../models';
48
50
  // @ts-ignore
51
+ import type { ReportAgentUsageResponse } from '../models';
52
+ // @ts-ignore
49
53
  import type { SignedAgentCard } from '../models';
50
54
  // @ts-ignore
51
55
  import type { VerifyAgentCardResponse } from '../models';
@@ -410,6 +414,53 @@ export const AgentsApiAxiosParamCreator = function (configuration?: Configuratio
410
414
  options: localVarRequestOptions,
411
415
  };
412
416
  },
417
+ /**
418
+ * Adds the reported tokens and cost to the agent\'s budget windows (current UTC hour, day and month). LumoAuth does not see model calls, so token and cost limits apply only to usage that is reported here or through the Admin API. The report adds no API call and is accepted even when the budget is spent. Agent credentials only; portal test tokens are refused. Rate limited per agent.
419
+ * @summary Report the model tokens and cost that the agent used
420
+ * @param {string} orgId
421
+ * @param {AdminAgentsReportUsageRequest} adminAgentsReportUsageRequest
422
+ * @param {*} [options] Override http request option.
423
+ * @throws {RequiredError}
424
+ */
425
+ reportAgentUsage: async (orgId: string, adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
426
+ // verify required parameter 'orgId' is not null or undefined
427
+ assertParamExists('reportAgentUsage', 'orgId', orgId)
428
+ // verify required parameter 'adminAgentsReportUsageRequest' is not null or undefined
429
+ assertParamExists('reportAgentUsage', 'adminAgentsReportUsageRequest', adminAgentsReportUsageRequest)
430
+ const localVarPath = `/orgs/{orgId}/api/v1/agents/me/usage`
431
+ .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)));
432
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
433
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
434
+ let baseOptions;
435
+ if (configuration) {
436
+ baseOptions = configuration.baseOptions;
437
+ }
438
+
439
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
440
+ const localVarHeaderParameter = {} as any;
441
+ const localVarQueryParameter = {} as any;
442
+
443
+ // authentication ApiKeyAuth required
444
+ await setApiKeyToObject(localVarHeaderParameter, "X-API-Key", configuration)
445
+
446
+ // authentication BearerAuth required
447
+ // http bearer authentication required
448
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
449
+
450
+
451
+
452
+ localVarHeaderParameter['Content-Type'] = 'application/json';
453
+
454
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
455
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
456
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
457
+ localVarRequestOptions.data = serializeDataIfNeeded(adminAgentsReportUsageRequest, localVarRequestOptions, configuration)
458
+
459
+ return {
460
+ url: toPathString(localVarUrlObj),
461
+ options: localVarRequestOptions,
462
+ };
463
+ },
413
464
  /**
414
465
  * Authenticated (user, agent or API key of this organization). The body is the signed card itself, or {\"card\": {...}, \"jwks_uri\": \"https://...\"} to verify against an external issuer\'s key set (SSRF-guarded); by default the organization\'s own JWKS is used.
415
466
  * @summary Verify a signed A2A agent card
@@ -576,6 +627,20 @@ export const AgentsApiFp = function(configuration?: Configuration) {
576
627
  const localVarOperationServerBasePath = operationServerMap['AgentsApi.registerAgent']?.[localVarOperationServerIndex]?.url;
577
628
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
578
629
  },
630
+ /**
631
+ * Adds the reported tokens and cost to the agent\'s budget windows (current UTC hour, day and month). LumoAuth does not see model calls, so token and cost limits apply only to usage that is reported here or through the Admin API. The report adds no API call and is accepted even when the budget is spent. Agent credentials only; portal test tokens are refused. Rate limited per agent.
632
+ * @summary Report the model tokens and cost that the agent used
633
+ * @param {string} orgId
634
+ * @param {AdminAgentsReportUsageRequest} adminAgentsReportUsageRequest
635
+ * @param {*} [options] Override http request option.
636
+ * @throws {RequiredError}
637
+ */
638
+ async reportAgentUsage(orgId: string, adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<ReportAgentUsageResponse>> {
639
+ const localVarAxiosArgs = await localVarAxiosParamCreator.reportAgentUsage(orgId, adminAgentsReportUsageRequest, options);
640
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
641
+ const localVarOperationServerBasePath = operationServerMap['AgentsApi.reportAgentUsage']?.[localVarOperationServerIndex]?.url;
642
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
643
+ },
579
644
  /**
580
645
  * Authenticated (user, agent or API key of this organization). The body is the signed card itself, or {\"card\": {...}, \"jwks_uri\": \"https://...\"} to verify against an external issuer\'s key set (SSRF-guarded); by default the organization\'s own JWKS is used.
581
646
  * @summary Verify a signed A2A agent card
@@ -678,6 +743,16 @@ export const AgentsApiFactory = function (configuration?: Configuration, basePat
678
743
  registerAgent(requestParameters: AgentsApiRegisterAgentRequest, options?: RawAxiosRequestConfig): AxiosPromise<RegisterAgentResponse> {
679
744
  return localVarFp.registerAgent(requestParameters.orgId, options).then((request) => request(axios, basePath));
680
745
  },
746
+ /**
747
+ * Adds the reported tokens and cost to the agent\'s budget windows (current UTC hour, day and month). LumoAuth does not see model calls, so token and cost limits apply only to usage that is reported here or through the Admin API. The report adds no API call and is accepted even when the budget is spent. Agent credentials only; portal test tokens are refused. Rate limited per agent.
748
+ * @summary Report the model tokens and cost that the agent used
749
+ * @param {AgentsApiReportAgentUsageRequest} requestParameters Request parameters.
750
+ * @param {*} [options] Override http request option.
751
+ * @throws {RequiredError}
752
+ */
753
+ reportAgentUsage(requestParameters: AgentsApiReportAgentUsageRequest, options?: RawAxiosRequestConfig): AxiosPromise<ReportAgentUsageResponse> {
754
+ return localVarFp.reportAgentUsage(requestParameters.orgId, requestParameters.adminAgentsReportUsageRequest, options).then((request) => request(axios, basePath));
755
+ },
681
756
  /**
682
757
  * Authenticated (user, agent or API key of this organization). The body is the signed card itself, or {\"card\": {...}, \"jwks_uri\": \"https://...\"} to verify against an external issuer\'s key set (SSRF-guarded); by default the organization\'s own JWKS is used.
683
758
  * @summary Verify a signed A2A agent card
@@ -775,6 +850,16 @@ export interface AgentsApiInterface {
775
850
  */
776
851
  registerAgent(requestParameters: AgentsApiRegisterAgentRequest, options?: RawAxiosRequestConfig): AxiosPromise<RegisterAgentResponse>;
777
852
 
853
+ /**
854
+ * Adds the reported tokens and cost to the agent\'s budget windows (current UTC hour, day and month). LumoAuth does not see model calls, so token and cost limits apply only to usage that is reported here or through the Admin API. The report adds no API call and is accepted even when the budget is spent. Agent credentials only; portal test tokens are refused. Rate limited per agent.
855
+ * @summary Report the model tokens and cost that the agent used
856
+ * @param {AgentsApiReportAgentUsageRequest} requestParameters Request parameters.
857
+ * @param {*} [options] Override http request option.
858
+ * @throws {RequiredError}
859
+ * @memberof AgentsApiInterface
860
+ */
861
+ reportAgentUsage(requestParameters: AgentsApiReportAgentUsageRequest, options?: RawAxiosRequestConfig): AxiosPromise<ReportAgentUsageResponse>;
862
+
778
863
  /**
779
864
  * Authenticated (user, agent or API key of this organization). The body is the signed card itself, or {\"card\": {...}, \"jwks_uri\": \"https://...\"} to verify against an external issuer\'s key set (SSRF-guarded); by default the organization\'s own JWKS is used.
780
865
  * @summary Verify a signed A2A agent card
@@ -948,6 +1033,27 @@ export interface AgentsApiRegisterAgentRequest {
948
1033
  readonly orgId: string
949
1034
  }
950
1035
 
1036
+ /**
1037
+ * Request parameters for reportAgentUsage operation in AgentsApi.
1038
+ * @export
1039
+ * @interface AgentsApiReportAgentUsageRequest
1040
+ */
1041
+ export interface AgentsApiReportAgentUsageRequest {
1042
+ /**
1043
+ *
1044
+ * @type {string}
1045
+ * @memberof AgentsApiReportAgentUsage
1046
+ */
1047
+ readonly orgId: string
1048
+
1049
+ /**
1050
+ *
1051
+ * @type {AdminAgentsReportUsageRequest}
1052
+ * @memberof AgentsApiReportAgentUsage
1053
+ */
1054
+ readonly adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest
1055
+ }
1056
+
951
1057
  /**
952
1058
  * Request parameters for verifyAgentCard operation in AgentsApi.
953
1059
  * @export
@@ -1070,6 +1176,18 @@ export class AgentsApi extends BaseAPI implements AgentsApiInterface {
1070
1176
  return AgentsApiFp(this.configuration).registerAgent(requestParameters.orgId, options).then((request) => request(this.axios, this.basePath));
1071
1177
  }
1072
1178
 
1179
+ /**
1180
+ * Adds the reported tokens and cost to the agent\'s budget windows (current UTC hour, day and month). LumoAuth does not see model calls, so token and cost limits apply only to usage that is reported here or through the Admin API. The report adds no API call and is accepted even when the budget is spent. Agent credentials only; portal test tokens are refused. Rate limited per agent.
1181
+ * @summary Report the model tokens and cost that the agent used
1182
+ * @param {AgentsApiReportAgentUsageRequest} requestParameters Request parameters.
1183
+ * @param {*} [options] Override http request option.
1184
+ * @throws {RequiredError}
1185
+ * @memberof AgentsApi
1186
+ */
1187
+ public reportAgentUsage(requestParameters: AgentsApiReportAgentUsageRequest, options?: RawAxiosRequestConfig) {
1188
+ return AgentsApiFp(this.configuration).reportAgentUsage(requestParameters.orgId, requestParameters.adminAgentsReportUsageRequest, options).then((request) => request(this.axios, this.basePath));
1189
+ }
1190
+
1073
1191
  /**
1074
1192
  * Authenticated (user, agent or API key of this organization). The body is the signed card itself, or {\"card\": {...}, \"jwks_uri\": \"https://...\"} to verify against an external issuer\'s key set (SSRF-guarded); by default the organization\'s own JWKS is used.
1075
1193
  * @summary Verify a signed A2A agent card
package/api/oauth-api.ts CHANGED
@@ -34,6 +34,10 @@ import type { RegisterClientResponse } from '../models';
34
34
  // @ts-ignore
35
35
  import type { RegisteredClientMetadata } from '../models';
36
36
  // @ts-ignore
37
+ import type { RequestMagicLinkRequest } from '../models';
38
+ // @ts-ignore
39
+ import type { RequestMagicLinkResponse } from '../models';
40
+ // @ts-ignore
37
41
  import type { SubmitLoginJsonResponse } from '../models';
38
42
  // @ts-ignore
39
43
  import type { TokenResponse } from '../models';
@@ -383,6 +387,46 @@ export const OAuthApiAxiosParamCreator = function (configuration?: Configuration
383
387
  options: localVarRequestOptions,
384
388
  };
385
389
  },
390
+ /**
391
+ * For applications that render their own sign-in form. Mails a single-use sign-in link to the address when it belongs to an account of the organization, and gives the same answer when it does not. Signs nobody in and mints no tokens: the person opens the link, confirms on the hosted page, and is then sent to `return_to`, where the application starts its normal authorization flow. A browser request must come from one of the allowed origins of the application named by `client_id`.
392
+ * @summary Request a sign-in link by email
393
+ * @param {string} orgId
394
+ * @param {RequestMagicLinkRequest} requestMagicLinkRequest
395
+ * @param {*} [options] Override http request option.
396
+ * @throws {RequiredError}
397
+ */
398
+ requestMagicLink: async (orgId: string, requestMagicLinkRequest: RequestMagicLinkRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
399
+ // verify required parameter 'orgId' is not null or undefined
400
+ assertParamExists('requestMagicLink', 'orgId', orgId)
401
+ // verify required parameter 'requestMagicLinkRequest' is not null or undefined
402
+ assertParamExists('requestMagicLink', 'requestMagicLinkRequest', requestMagicLinkRequest)
403
+ const localVarPath = `/orgs/{orgId}/api/v1/oauth/magic-link`
404
+ .replace(`{${"orgId"}}`, encodeURIComponent(String(orgId)));
405
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
406
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
407
+ let baseOptions;
408
+ if (configuration) {
409
+ baseOptions = configuration.baseOptions;
410
+ }
411
+
412
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
413
+ const localVarHeaderParameter = {} as any;
414
+ const localVarQueryParameter = {} as any;
415
+
416
+
417
+
418
+ localVarHeaderParameter['Content-Type'] = 'application/json';
419
+
420
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
421
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
422
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
423
+ localVarRequestOptions.data = serializeDataIfNeeded(requestMagicLinkRequest, localVarRequestOptions, configuration)
424
+
425
+ return {
426
+ url: toPathString(localVarUrlObj),
427
+ options: localVarRequestOptions,
428
+ };
429
+ },
386
430
  /**
387
431
  * Revokes an access or refresh token (revoking a refresh token also revokes the access tokens issued with it). Requires client authentication. Always sent with Cache-Control: no-store.
388
432
  * @summary Token revocation (RFC 7009)
@@ -837,6 +881,20 @@ export const OAuthApiFp = function(configuration?: Configuration) {
837
881
  const localVarOperationServerBasePath = operationServerMap['OAuthApi.registerClient']?.[localVarOperationServerIndex]?.url;
838
882
  return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
839
883
  },
884
+ /**
885
+ * For applications that render their own sign-in form. Mails a single-use sign-in link to the address when it belongs to an account of the organization, and gives the same answer when it does not. Signs nobody in and mints no tokens: the person opens the link, confirms on the hosted page, and is then sent to `return_to`, where the application starts its normal authorization flow. A browser request must come from one of the allowed origins of the application named by `client_id`.
886
+ * @summary Request a sign-in link by email
887
+ * @param {string} orgId
888
+ * @param {RequestMagicLinkRequest} requestMagicLinkRequest
889
+ * @param {*} [options] Override http request option.
890
+ * @throws {RequiredError}
891
+ */
892
+ async requestMagicLink(orgId: string, requestMagicLinkRequest: RequestMagicLinkRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<RequestMagicLinkResponse>> {
893
+ const localVarAxiosArgs = await localVarAxiosParamCreator.requestMagicLink(orgId, requestMagicLinkRequest, options);
894
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
895
+ const localVarOperationServerBasePath = operationServerMap['OAuthApi.requestMagicLink']?.[localVarOperationServerIndex]?.url;
896
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
897
+ },
840
898
  /**
841
899
  * Revokes an access or refresh token (revoking a refresh token also revokes the access tokens issued with it). Requires client authentication. Always sent with Cache-Control: no-store.
842
900
  * @summary Token revocation (RFC 7009)
@@ -1057,6 +1115,16 @@ export const OAuthApiFactory = function (configuration?: Configuration, basePath
1057
1115
  registerClient(requestParameters: OAuthApiRegisterClientRequest, options?: RawAxiosRequestConfig): AxiosPromise<RegisterClientResponse> {
1058
1116
  return localVarFp.registerClient(requestParameters.orgId, options).then((request) => request(axios, basePath));
1059
1117
  },
1118
+ /**
1119
+ * For applications that render their own sign-in form. Mails a single-use sign-in link to the address when it belongs to an account of the organization, and gives the same answer when it does not. Signs nobody in and mints no tokens: the person opens the link, confirms on the hosted page, and is then sent to `return_to`, where the application starts its normal authorization flow. A browser request must come from one of the allowed origins of the application named by `client_id`.
1120
+ * @summary Request a sign-in link by email
1121
+ * @param {OAuthApiRequestMagicLinkRequest} requestParameters Request parameters.
1122
+ * @param {*} [options] Override http request option.
1123
+ * @throws {RequiredError}
1124
+ */
1125
+ requestMagicLink(requestParameters: OAuthApiRequestMagicLinkRequest, options?: RawAxiosRequestConfig): AxiosPromise<RequestMagicLinkResponse> {
1126
+ return localVarFp.requestMagicLink(requestParameters.orgId, requestParameters.requestMagicLinkRequest, options).then((request) => request(axios, basePath));
1127
+ },
1060
1128
  /**
1061
1129
  * Revokes an access or refresh token (revoking a refresh token also revokes the access tokens issued with it). Requires client authentication. Always sent with Cache-Control: no-store.
1062
1130
  * @summary Token revocation (RFC 7009)
@@ -1246,6 +1314,16 @@ export interface OAuthApiInterface {
1246
1314
  */
1247
1315
  registerClient(requestParameters: OAuthApiRegisterClientRequest, options?: RawAxiosRequestConfig): AxiosPromise<RegisterClientResponse>;
1248
1316
 
1317
+ /**
1318
+ * For applications that render their own sign-in form. Mails a single-use sign-in link to the address when it belongs to an account of the organization, and gives the same answer when it does not. Signs nobody in and mints no tokens: the person opens the link, confirms on the hosted page, and is then sent to `return_to`, where the application starts its normal authorization flow. A browser request must come from one of the allowed origins of the application named by `client_id`.
1319
+ * @summary Request a sign-in link by email
1320
+ * @param {OAuthApiRequestMagicLinkRequest} requestParameters Request parameters.
1321
+ * @param {*} [options] Override http request option.
1322
+ * @throws {RequiredError}
1323
+ * @memberof OAuthApiInterface
1324
+ */
1325
+ requestMagicLink(requestParameters: OAuthApiRequestMagicLinkRequest, options?: RawAxiosRequestConfig): AxiosPromise<RequestMagicLinkResponse>;
1326
+
1249
1327
  /**
1250
1328
  * Revokes an access or refresh token (revoking a refresh token also revokes the access tokens issued with it). Requires client authentication. Always sent with Cache-Control: no-store.
1251
1329
  * @summary Token revocation (RFC 7009)
@@ -1471,6 +1549,27 @@ export interface OAuthApiRegisterClientRequest {
1471
1549
  readonly orgId: string
1472
1550
  }
1473
1551
 
1552
+ /**
1553
+ * Request parameters for requestMagicLink operation in OAuthApi.
1554
+ * @export
1555
+ * @interface OAuthApiRequestMagicLinkRequest
1556
+ */
1557
+ export interface OAuthApiRequestMagicLinkRequest {
1558
+ /**
1559
+ *
1560
+ * @type {string}
1561
+ * @memberof OAuthApiRequestMagicLink
1562
+ */
1563
+ readonly orgId: string
1564
+
1565
+ /**
1566
+ *
1567
+ * @type {RequestMagicLinkRequest}
1568
+ * @memberof OAuthApiRequestMagicLink
1569
+ */
1570
+ readonly requestMagicLinkRequest: RequestMagicLinkRequest
1571
+ }
1572
+
1474
1573
  /**
1475
1574
  * Request parameters for revoke operation in OAuthApi.
1476
1575
  * @export
@@ -1733,6 +1832,18 @@ export class OAuthApi extends BaseAPI implements OAuthApiInterface {
1733
1832
  return OAuthApiFp(this.configuration).registerClient(requestParameters.orgId, options).then((request) => request(this.axios, this.basePath));
1734
1833
  }
1735
1834
 
1835
+ /**
1836
+ * For applications that render their own sign-in form. Mails a single-use sign-in link to the address when it belongs to an account of the organization, and gives the same answer when it does not. Signs nobody in and mints no tokens: the person opens the link, confirms on the hosted page, and is then sent to `return_to`, where the application starts its normal authorization flow. A browser request must come from one of the allowed origins of the application named by `client_id`.
1837
+ * @summary Request a sign-in link by email
1838
+ * @param {OAuthApiRequestMagicLinkRequest} requestParameters Request parameters.
1839
+ * @param {*} [options] Override http request option.
1840
+ * @throws {RequiredError}
1841
+ * @memberof OAuthApi
1842
+ */
1843
+ public requestMagicLink(requestParameters: OAuthApiRequestMagicLinkRequest, options?: RawAxiosRequestConfig) {
1844
+ return OAuthApiFp(this.configuration).requestMagicLink(requestParameters.orgId, requestParameters.requestMagicLinkRequest, options).then((request) => request(this.axios, this.basePath));
1845
+ }
1846
+
1736
1847
  /**
1737
1848
  * Revokes an access or refresh token (revoking a refresh token also revokes the access tokens issued with it). Requires client authentication. Always sent with Cache-Control: no-store.
1738
1849
  * @summary Token revocation (RFC 7009)
@@ -15,6 +15,7 @@ import { type RequestArgs, BaseAPI } from '../base';
15
15
  import type { AdminAgentsActivateResponse } from '../models';
16
16
  import type { AdminAgentsAgentsDisableResponse } from '../models';
17
17
  import type { AdminAgentsAgentsEnableResponse } from '../models';
18
+ import type { AdminAgentsAgentsRotateKeyRequest } from '../models';
18
19
  import type { AdminAgentsAgentsRotateKeyResponse } from '../models';
19
20
  import type { AdminAgentsCreateRequest } from '../models';
20
21
  import type { AdminAgentsCreateResponse } from '../models';
@@ -25,6 +26,8 @@ import type { AdminAgentsGenerateTokenResponse } from '../models';
25
26
  import type { AdminAgentsGetResponse } from '../models';
26
27
  import type { AdminAgentsGetScopesResponse } from '../models';
27
28
  import type { AdminAgentsListResponse } from '../models';
29
+ import type { AdminAgentsReportUsageRequest } from '../models';
30
+ import type { AdminAgentsReportUsageResponse } from '../models';
28
31
  import type { AdminAgentsRevokeKeyResponse } from '../models';
29
32
  import type { AdminAgentsRotateCredentialsResponse } from '../models';
30
33
  import type { AdminAgentsSetScopesRequest } from '../models';
@@ -68,10 +71,11 @@ export declare const AdminAgentsApiAxiosParamCreator: (configuration?: Configura
68
71
  * @summary Rotate agent API key
69
72
  * @param {string} orgId
70
73
  * @param {string} agentId
74
+ * @param {AdminAgentsAgentsRotateKeyRequest} [adminAgentsAgentsRotateKeyRequest] Optional lifetime of the new API key. Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
71
75
  * @param {*} [options] Override http request option.
72
76
  * @throws {RequiredError}
73
77
  */
74
- adminAgentsAgentsRotateKey: (orgId: string, agentId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
78
+ adminAgentsAgentsRotateKey: (orgId: string, agentId: string, adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
75
79
  /**
76
80
  *
77
81
  * @summary Create a new agent
@@ -135,6 +139,16 @@ export declare const AdminAgentsApiAxiosParamCreator: (configuration?: Configura
135
139
  * @throws {RequiredError}
136
140
  */
137
141
  adminAgentsList: (orgId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
142
+ /**
143
+ * For a trusted component of your organization, such as an AI gateway\'s spend callback or an orchestrator, that sees the agent\'s model calls. Adds the tokens and cost to the agent\'s budget windows (current UTC hour, day and month), exactly like POST /agents/me/usage from the agent itself. The report adds no API call and is accepted even when the budget is spent.
144
+ * @summary Report model tokens and cost for an agent
145
+ * @param {string} orgId
146
+ * @param {string} agentId
147
+ * @param {AdminAgentsReportUsageRequest} adminAgentsReportUsageRequest
148
+ * @param {*} [options] Override http request option.
149
+ * @throws {RequiredError}
150
+ */
151
+ adminAgentsReportUsage: (orgId: string, agentId: string, adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
138
152
  /**
139
153
  *
140
154
  * @summary Revoke agent API key (nullify it so it can no longer authenticate)
@@ -149,10 +163,11 @@ export declare const AdminAgentsApiAxiosParamCreator: (configuration?: Configura
149
163
  * @summary Rotate agent credentials
150
164
  * @param {string} orgId
151
165
  * @param {string} agentId
166
+ * @param {AdminAgentsAgentsRotateKeyRequest} [adminAgentsAgentsRotateKeyRequest] For an api_key agent, the optional lifetime of the new key (ignored for a client secret). Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
152
167
  * @param {*} [options] Override http request option.
153
168
  * @throws {RequiredError}
154
169
  */
155
- adminAgentsRotateCredentials: (orgId: string, agentId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
170
+ adminAgentsRotateCredentials: (orgId: string, agentId: string, adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
156
171
  /**
157
172
  *
158
173
  * @summary Update agent scopes/capabilities
@@ -221,10 +236,11 @@ export declare const AdminAgentsApiFp: (configuration?: Configuration) => {
221
236
  * @summary Rotate agent API key
222
237
  * @param {string} orgId
223
238
  * @param {string} agentId
239
+ * @param {AdminAgentsAgentsRotateKeyRequest} [adminAgentsAgentsRotateKeyRequest] Optional lifetime of the new API key. Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
224
240
  * @param {*} [options] Override http request option.
225
241
  * @throws {RequiredError}
226
242
  */
227
- adminAgentsAgentsRotateKey(orgId: string, agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsAgentsRotateKeyResponse>>;
243
+ adminAgentsAgentsRotateKey(orgId: string, agentId: string, adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsAgentsRotateKeyResponse>>;
228
244
  /**
229
245
  *
230
246
  * @summary Create a new agent
@@ -288,6 +304,16 @@ export declare const AdminAgentsApiFp: (configuration?: Configuration) => {
288
304
  * @throws {RequiredError}
289
305
  */
290
306
  adminAgentsList(orgId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsListResponse>>;
307
+ /**
308
+ * For a trusted component of your organization, such as an AI gateway\'s spend callback or an orchestrator, that sees the agent\'s model calls. Adds the tokens and cost to the agent\'s budget windows (current UTC hour, day and month), exactly like POST /agents/me/usage from the agent itself. The report adds no API call and is accepted even when the budget is spent.
309
+ * @summary Report model tokens and cost for an agent
310
+ * @param {string} orgId
311
+ * @param {string} agentId
312
+ * @param {AdminAgentsReportUsageRequest} adminAgentsReportUsageRequest
313
+ * @param {*} [options] Override http request option.
314
+ * @throws {RequiredError}
315
+ */
316
+ adminAgentsReportUsage(orgId: string, agentId: string, adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsReportUsageResponse>>;
291
317
  /**
292
318
  *
293
319
  * @summary Revoke agent API key (nullify it so it can no longer authenticate)
@@ -302,10 +328,11 @@ export declare const AdminAgentsApiFp: (configuration?: Configuration) => {
302
328
  * @summary Rotate agent credentials
303
329
  * @param {string} orgId
304
330
  * @param {string} agentId
331
+ * @param {AdminAgentsAgentsRotateKeyRequest} [adminAgentsAgentsRotateKeyRequest] For an api_key agent, the optional lifetime of the new key (ignored for a client secret). Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
305
332
  * @param {*} [options] Override http request option.
306
333
  * @throws {RequiredError}
307
334
  */
308
- adminAgentsRotateCredentials(orgId: string, agentId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsRotateCredentialsResponse>>;
335
+ adminAgentsRotateCredentials(orgId: string, agentId: string, adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AdminAgentsRotateCredentialsResponse>>;
309
336
  /**
310
337
  *
311
338
  * @summary Update agent scopes/capabilities
@@ -430,6 +457,14 @@ export declare const AdminAgentsApiFactory: (configuration?: Configuration, base
430
457
  * @throws {RequiredError}
431
458
  */
432
459
  adminAgentsList(requestParameters: AdminAgentsApiAdminAgentsListRequest, options?: RawAxiosRequestConfig): AxiosPromise<AdminAgentsListResponse>;
460
+ /**
461
+ * For a trusted component of your organization, such as an AI gateway\'s spend callback or an orchestrator, that sees the agent\'s model calls. Adds the tokens and cost to the agent\'s budget windows (current UTC hour, day and month), exactly like POST /agents/me/usage from the agent itself. The report adds no API call and is accepted even when the budget is spent.
462
+ * @summary Report model tokens and cost for an agent
463
+ * @param {AdminAgentsApiAdminAgentsReportUsageRequest} requestParameters Request parameters.
464
+ * @param {*} [options] Override http request option.
465
+ * @throws {RequiredError}
466
+ */
467
+ adminAgentsReportUsage(requestParameters: AdminAgentsApiAdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig): AxiosPromise<AdminAgentsReportUsageResponse>;
433
468
  /**
434
469
  *
435
470
  * @summary Revoke agent API key (nullify it so it can no longer authenticate)
@@ -576,6 +611,15 @@ export interface AdminAgentsApiInterface {
576
611
  * @memberof AdminAgentsApiInterface
577
612
  */
578
613
  adminAgentsList(requestParameters: AdminAgentsApiAdminAgentsListRequest, options?: RawAxiosRequestConfig): AxiosPromise<AdminAgentsListResponse>;
614
+ /**
615
+ * For a trusted component of your organization, such as an AI gateway\'s spend callback or an orchestrator, that sees the agent\'s model calls. Adds the tokens and cost to the agent\'s budget windows (current UTC hour, day and month), exactly like POST /agents/me/usage from the agent itself. The report adds no API call and is accepted even when the budget is spent.
616
+ * @summary Report model tokens and cost for an agent
617
+ * @param {AdminAgentsApiAdminAgentsReportUsageRequest} requestParameters Request parameters.
618
+ * @param {*} [options] Override http request option.
619
+ * @throws {RequiredError}
620
+ * @memberof AdminAgentsApiInterface
621
+ */
622
+ adminAgentsReportUsage(requestParameters: AdminAgentsApiAdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig): AxiosPromise<AdminAgentsReportUsageResponse>;
579
623
  /**
580
624
  *
581
625
  * @summary Revoke agent API key (nullify it so it can no longer authenticate)
@@ -697,6 +741,12 @@ export interface AdminAgentsApiAdminAgentsAgentsRotateKeyRequest {
697
741
  * @memberof AdminAgentsApiAdminAgentsAgentsRotateKey
698
742
  */
699
743
  readonly agentId: string;
744
+ /**
745
+ * Optional lifetime of the new API key. Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
746
+ * @type {AdminAgentsAgentsRotateKeyRequest}
747
+ * @memberof AdminAgentsApiAdminAgentsAgentsRotateKey
748
+ */
749
+ readonly adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest;
700
750
  }
701
751
  /**
702
752
  * Request parameters for adminAgentsCreate operation in AdminAgentsApi.
@@ -831,6 +881,31 @@ export interface AdminAgentsApiAdminAgentsListRequest {
831
881
  */
832
882
  readonly orgId: string;
833
883
  }
884
+ /**
885
+ * Request parameters for adminAgentsReportUsage operation in AdminAgentsApi.
886
+ * @export
887
+ * @interface AdminAgentsApiAdminAgentsReportUsageRequest
888
+ */
889
+ export interface AdminAgentsApiAdminAgentsReportUsageRequest {
890
+ /**
891
+ *
892
+ * @type {string}
893
+ * @memberof AdminAgentsApiAdminAgentsReportUsage
894
+ */
895
+ readonly orgId: string;
896
+ /**
897
+ *
898
+ * @type {string}
899
+ * @memberof AdminAgentsApiAdminAgentsReportUsage
900
+ */
901
+ readonly agentId: string;
902
+ /**
903
+ *
904
+ * @type {AdminAgentsReportUsageRequest}
905
+ * @memberof AdminAgentsApiAdminAgentsReportUsage
906
+ */
907
+ readonly adminAgentsReportUsageRequest: AdminAgentsReportUsageRequest;
908
+ }
834
909
  /**
835
910
  * Request parameters for adminAgentsRevokeKey operation in AdminAgentsApi.
836
911
  * @export
@@ -868,6 +943,12 @@ export interface AdminAgentsApiAdminAgentsRotateCredentialsRequest {
868
943
  * @memberof AdminAgentsApiAdminAgentsRotateCredentials
869
944
  */
870
945
  readonly agentId: string;
946
+ /**
947
+ * For an api_key agent, the optional lifetime of the new key (ignored for a client secret). Without either field the current expiry date is kept, unless it has already passed (then the new key gets 180 days).
948
+ * @type {AdminAgentsAgentsRotateKeyRequest}
949
+ * @memberof AdminAgentsApiAdminAgentsRotateCredentials
950
+ */
951
+ readonly adminAgentsAgentsRotateKeyRequest?: AdminAgentsAgentsRotateKeyRequest;
871
952
  }
872
953
  /**
873
954
  * Request parameters for adminAgentsSetScopes operation in AdminAgentsApi.
@@ -1050,6 +1131,15 @@ export declare class AdminAgentsApi extends BaseAPI implements AdminAgentsApiInt
1050
1131
  * @memberof AdminAgentsApi
1051
1132
  */
1052
1133
  adminAgentsList(requestParameters: AdminAgentsApiAdminAgentsListRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AdminAgentsListResponse, any, {}>>;
1134
+ /**
1135
+ * For a trusted component of your organization, such as an AI gateway\'s spend callback or an orchestrator, that sees the agent\'s model calls. Adds the tokens and cost to the agent\'s budget windows (current UTC hour, day and month), exactly like POST /agents/me/usage from the agent itself. The report adds no API call and is accepted even when the budget is spent.
1136
+ * @summary Report model tokens and cost for an agent
1137
+ * @param {AdminAgentsApiAdminAgentsReportUsageRequest} requestParameters Request parameters.
1138
+ * @param {*} [options] Override http request option.
1139
+ * @throws {RequiredError}
1140
+ * @memberof AdminAgentsApi
1141
+ */
1142
+ adminAgentsReportUsage(requestParameters: AdminAgentsApiAdminAgentsReportUsageRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AdminAgentsReportUsageResponse, any, {}>>;
1053
1143
  /**
1054
1144
  *
1055
1145
  * @summary Revoke agent API key (nullify it so it can no longer authenticate)