@harnessio/react-ccm-optimization-service-client 0.3.2 → 0.3.3
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.
- package/dist/ccm-optimization-service/src/services/hooks/useGetAiGovernancePoliciesSpendMutation.d.ts +23 -0
- package/dist/ccm-optimization-service/src/services/hooks/useGetAiGovernancePoliciesSpendMutation.js +14 -0
- package/dist/ccm-optimization-service/src/services/hooks/useGetAiGovernancePolicySubjectsSpendMutation.d.ts +27 -0
- package/dist/ccm-optimization-service/src/services/hooks/useGetAiGovernancePolicySubjectsSpendMutation.js +14 -0
- package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePoliciesMutation.d.ts +1 -1
- package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePoliciesMutation.js +1 -1
- package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePolicySubjectsMutation.d.ts +1 -1
- package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePolicySubjectsMutation.js +1 -1
- package/dist/ccm-optimization-service/src/services/index.d.ts +10 -0
- package/dist/ccm-optimization-service/src/services/index.js +2 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceApprovalRequest.d.ts +4 -1
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceApprovalRequestList.d.ts +1 -1
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendRequest.d.ts +9 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendRequest.js +4 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendResponse.d.ts +4 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendResponse.js +1 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPolicySubjectsSpendRequest.d.ts +9 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPolicySubjectsSpendRequest.js +4 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPolicySubjectsSpendResponse.d.ts +4 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPolicySubjectsSpendResponse.js +1 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernancePolicySpendMetrics.d.ts +13 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernancePolicySpendMetrics.js +1 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernancePolicySubjectRow.d.ts +3 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceSubjectSpendMetrics.d.ts +21 -0
- package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceSubjectSpendMetrics.js +4 -0
- package/package.json +1 -1
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { AiGovernanceGetPoliciesSpendResponse } from '../schemas/AiGovernanceGetPoliciesSpendResponse';
|
|
3
|
+
import type { AiGovernanceGetPoliciesSpendRequest } from '../schemas/AiGovernanceGetPoliciesSpendRequest';
|
|
4
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
5
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
6
|
+
export interface GetAiGovernancePoliciesSpendMutationPathParams {
|
|
7
|
+
account_id: string;
|
|
8
|
+
}
|
|
9
|
+
export interface GetAiGovernancePoliciesSpendMutationQueryParams {
|
|
10
|
+
accountIdentifier: string;
|
|
11
|
+
}
|
|
12
|
+
export type GetAiGovernancePoliciesSpendRequestBody = AiGovernanceGetPoliciesSpendRequest;
|
|
13
|
+
export type GetAiGovernancePoliciesSpendOkResponse = ResponseWithPagination<AiGovernanceGetPoliciesSpendResponse>;
|
|
14
|
+
export type GetAiGovernancePoliciesSpendErrorResponse = unknown;
|
|
15
|
+
export interface GetAiGovernancePoliciesSpendProps extends GetAiGovernancePoliciesSpendMutationPathParams, Omit<FetcherOptions<GetAiGovernancePoliciesSpendMutationQueryParams, GetAiGovernancePoliciesSpendRequestBody>, 'url'> {
|
|
16
|
+
queryParams: GetAiGovernancePoliciesSpendMutationQueryParams;
|
|
17
|
+
body: GetAiGovernancePoliciesSpendRequestBody;
|
|
18
|
+
}
|
|
19
|
+
export declare function getAiGovernancePoliciesSpend(props: GetAiGovernancePoliciesSpendProps): Promise<GetAiGovernancePoliciesSpendOkResponse>;
|
|
20
|
+
/**
|
|
21
|
+
* Returns live cumulativeSpend, spendPercent, and userHealth for up to 50 policies in one request. GraphQL spend lookups are deduplicated by connector scope and budget period across the batch, then fetched in parallel with at most 10 concurrent scope requests. Merge results with list rows by policyId; period metadata and warnings come from the list response. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles receive metrics only for policies in allowed folders.
|
|
22
|
+
*/
|
|
23
|
+
export declare function useGetAiGovernancePoliciesSpendMutation(options?: Omit<UseMutationOptions<GetAiGovernancePoliciesSpendOkResponse, GetAiGovernancePoliciesSpendErrorResponse, GetAiGovernancePoliciesSpendProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<GetAiGovernancePoliciesSpendOkResponse, unknown, GetAiGovernancePoliciesSpendProps, unknown>;
|
package/dist/ccm-optimization-service/src/services/hooks/useGetAiGovernancePoliciesSpendMutation.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function getAiGovernancePoliciesSpend(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/accounts/${props.account_id}/ai-governance/policies/spend`, method: 'POST' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Returns live cumulativeSpend, spendPercent, and userHealth for up to 50 policies in one request. GraphQL spend lookups are deduplicated by connector scope and budget period across the batch, then fetched in parallel with at most 10 concurrent scope requests. Merge results with list rows by policyId; period metadata and warnings come from the list response. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles receive metrics only for policies in allowed folders.
|
|
11
|
+
*/
|
|
12
|
+
export function useGetAiGovernancePoliciesSpendMutation(options) {
|
|
13
|
+
return useMutation((mutateProps) => getAiGovernancePoliciesSpend(mutateProps), options);
|
|
14
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
2
|
+
import type { AiGovernanceGetPolicySubjectsSpendResponse } from '../schemas/AiGovernanceGetPolicySubjectsSpendResponse';
|
|
3
|
+
import type { AiGovernanceGetPolicySubjectsSpendRequest } from '../schemas/AiGovernanceGetPolicySubjectsSpendRequest';
|
|
4
|
+
import type { ResponseWithPagination } from '../helpers';
|
|
5
|
+
import { FetcherOptions } from '../../../../fetcher/index.js';
|
|
6
|
+
export interface GetAiGovernancePolicySubjectsSpendMutationPathParams {
|
|
7
|
+
account_id: string;
|
|
8
|
+
/**
|
|
9
|
+
* @format uuid
|
|
10
|
+
*/
|
|
11
|
+
policy_id: string;
|
|
12
|
+
}
|
|
13
|
+
export interface GetAiGovernancePolicySubjectsSpendMutationQueryParams {
|
|
14
|
+
accountIdentifier: string;
|
|
15
|
+
}
|
|
16
|
+
export type GetAiGovernancePolicySubjectsSpendRequestBody = AiGovernanceGetPolicySubjectsSpendRequest;
|
|
17
|
+
export type GetAiGovernancePolicySubjectsSpendOkResponse = ResponseWithPagination<AiGovernanceGetPolicySubjectsSpendResponse>;
|
|
18
|
+
export type GetAiGovernancePolicySubjectsSpendErrorResponse = unknown;
|
|
19
|
+
export interface GetAiGovernancePolicySubjectsSpendProps extends GetAiGovernancePolicySubjectsSpendMutationPathParams, Omit<FetcherOptions<GetAiGovernancePolicySubjectsSpendMutationQueryParams, GetAiGovernancePolicySubjectsSpendRequestBody>, 'url'> {
|
|
20
|
+
queryParams: GetAiGovernancePolicySubjectsSpendMutationQueryParams;
|
|
21
|
+
body: GetAiGovernancePolicySubjectsSpendRequestBody;
|
|
22
|
+
}
|
|
23
|
+
export declare function getAiGovernancePolicySubjectsSpend(props: GetAiGovernancePolicySubjectsSpendProps): Promise<GetAiGovernancePolicySubjectsSpendOkResponse>;
|
|
24
|
+
/**
|
|
25
|
+
* Returns live spendAmount, spendPercent, and status for up to 100 subjects on one policy in a single GraphQL-backed evaluation. Merge results with subjects list rows by email. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
26
|
+
*/
|
|
27
|
+
export declare function useGetAiGovernancePolicySubjectsSpendMutation(options?: Omit<UseMutationOptions<GetAiGovernancePolicySubjectsSpendOkResponse, GetAiGovernancePolicySubjectsSpendErrorResponse, GetAiGovernancePolicySubjectsSpendProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<GetAiGovernancePolicySubjectsSpendOkResponse, unknown, GetAiGovernancePolicySubjectsSpendProps, unknown>;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
// This code is autogenerated using @harnessio/oats-cli.
|
|
3
|
+
// Please do not modify this code directly.
|
|
4
|
+
import { useMutation } from '@tanstack/react-query';
|
|
5
|
+
import { fetcher } from '../../../../fetcher/index.js';
|
|
6
|
+
export function getAiGovernancePolicySubjectsSpend(props) {
|
|
7
|
+
return fetcher(Object.assign({ url: `/accounts/${props.account_id}/ai-governance/policies/${props.policy_id}/subjects/spend`, method: 'POST' }, props));
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Returns live spendAmount, spendPercent, and status for up to 100 subjects on one policy in a single GraphQL-backed evaluation. Merge results with subjects list rows by email. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
11
|
+
*/
|
|
12
|
+
export function useGetAiGovernancePolicySubjectsSpendMutation(options) {
|
|
13
|
+
return useMutation((mutateProps) => getAiGovernancePolicySubjectsSpend(mutateProps), options);
|
|
14
|
+
}
|
package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePoliciesMutation.d.ts
CHANGED
|
@@ -18,6 +18,6 @@ export interface ListAiGovernancePoliciesProps extends ListAiGovernancePoliciesM
|
|
|
18
18
|
}
|
|
19
19
|
export declare function listAiGovernancePolicies(props: ListAiGovernancePoliciesProps): Promise<ListAiGovernancePoliciesOkResponse>;
|
|
20
20
|
/**
|
|
21
|
-
* Returns a paginated list of governance policies. Each item is a flat object with persisted policy fields (id, name, folderId, document, audit metadata) plus
|
|
21
|
+
* Returns a paginated list of governance policies. Each item is a flat object with persisted policy fields (id, name, folderId, document, audit metadata) plus DB-derived metrics (subjects, budget, period, pending/blocked counts). List responses omit rawYaml and spend fields; use the batch policy spend API to hydrate cumulativeSpend, spendPercent, and userHealth. Use query for case-insensitive partial name search; supports filters on name, folder_id, created_at, and updated_at. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
22
22
|
*/
|
|
23
23
|
export declare function useListAiGovernancePoliciesMutation(options?: Omit<UseMutationOptions<ListAiGovernancePoliciesOkResponse, ListAiGovernancePoliciesErrorResponse, ListAiGovernancePoliciesProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<ListAiGovernancePoliciesOkResponse, unknown, ListAiGovernancePoliciesProps, unknown>;
|
package/dist/ccm-optimization-service/src/services/hooks/useListAiGovernancePoliciesMutation.js
CHANGED
|
@@ -7,7 +7,7 @@ export function listAiGovernancePolicies(props) {
|
|
|
7
7
|
return fetcher(Object.assign({ url: `/accounts/${props.account_id}/ai-governance/policies/list`, method: 'POST' }, props));
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Returns a paginated list of governance policies. Each item is a flat object with persisted policy fields (id, name, folderId, document, audit metadata) plus
|
|
10
|
+
* Returns a paginated list of governance policies. Each item is a flat object with persisted policy fields (id, name, folderId, document, audit metadata) plus DB-derived metrics (subjects, budget, period, pending/blocked counts). List responses omit rawYaml and spend fields; use the batch policy spend API to hydrate cumulativeSpend, spendPercent, and userHealth. Use query for case-insensitive partial name search; supports filters on name, folder_id, created_at, and updated_at. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
11
11
|
*/
|
|
12
12
|
export function useListAiGovernancePoliciesMutation(options) {
|
|
13
13
|
return useMutation((mutateProps) => listAiGovernancePolicies(mutateProps), options);
|
|
@@ -22,6 +22,6 @@ export interface ListAiGovernancePolicySubjectsProps extends ListAiGovernancePol
|
|
|
22
22
|
}
|
|
23
23
|
export declare function listAiGovernancePolicySubjects(props: ListAiGovernancePolicySubjectsProps): Promise<ListAiGovernancePolicySubjectsOkResponse>;
|
|
24
24
|
/**
|
|
25
|
-
* Returns a paginated admin view of subjects mapped to a governance policy. Each row includes effective budget (after active overrides),
|
|
25
|
+
* Returns a paginated admin view of subjects mapped to a governance policy. Each row includes effective budget (after active overrides), any open budget raise request, and blocked status. List responses omit spend and health fields; use the batch subject spend API to hydrate spendAmount, spendPercent, and status. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
26
26
|
*/
|
|
27
27
|
export declare function useListAiGovernancePolicySubjectsMutation(options?: Omit<UseMutationOptions<ListAiGovernancePolicySubjectsOkResponse, ListAiGovernancePolicySubjectsErrorResponse, ListAiGovernancePolicySubjectsProps>, 'mutationKey' | 'mutationFn'>): import("@tanstack/react-query").UseMutationResult<ListAiGovernancePolicySubjectsOkResponse, unknown, ListAiGovernancePolicySubjectsProps, unknown>;
|
|
@@ -7,7 +7,7 @@ export function listAiGovernancePolicySubjects(props) {
|
|
|
7
7
|
return fetcher(Object.assign({ url: `/accounts/${props.account_id}/ai-governance/policies/${props.policy_id}/subjects`, method: 'POST' }, props));
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Returns a paginated admin view of subjects mapped to a governance policy. Each row includes effective budget (after active overrides),
|
|
10
|
+
* Returns a paginated admin view of subjects mapped to a governance policy. Each row includes effective budget (after active overrides), any open budget raise request, and blocked status. List responses omit spend and health fields; use the batch subject spend API to hydrate spendAmount, spendPercent, and status. Requires CCM Budget View permission (ccm_budget_view); folder-scoped roles may access only policies in allowed folders.
|
|
11
11
|
*/
|
|
12
12
|
export function useListAiGovernancePolicySubjectsMutation(options) {
|
|
13
13
|
return useMutation((mutateProps) => listAiGovernancePolicySubjects(mutateProps), options);
|
|
@@ -119,10 +119,14 @@ export type { GenerateOnboardCommandErrorResponse, GenerateOnboardCommandMutatio
|
|
|
119
119
|
export { generateOnboardCommand, useGenerateOnboardCommandMutation, } from './hooks/useGenerateOnboardCommandMutation';
|
|
120
120
|
export type { GetAccessPointErrorResponse, GetAccessPointOkResponse, GetAccessPointProps, GetAccessPointQueryPathParams, GetAccessPointQueryQueryParams, } from './hooks/useGetAccessPointQuery';
|
|
121
121
|
export { getAccessPoint, useGetAccessPointQuery } from './hooks/useGetAccessPointQuery';
|
|
122
|
+
export type { GetAiGovernancePoliciesSpendErrorResponse, GetAiGovernancePoliciesSpendMutationPathParams, GetAiGovernancePoliciesSpendMutationQueryParams, GetAiGovernancePoliciesSpendOkResponse, GetAiGovernancePoliciesSpendProps, GetAiGovernancePoliciesSpendRequestBody, } from './hooks/useGetAiGovernancePoliciesSpendMutation';
|
|
123
|
+
export { getAiGovernancePoliciesSpend, useGetAiGovernancePoliciesSpendMutation, } from './hooks/useGetAiGovernancePoliciesSpendMutation';
|
|
122
124
|
export type { GetAiGovernancePolicyOverviewErrorResponse, GetAiGovernancePolicyOverviewOkResponse, GetAiGovernancePolicyOverviewProps, GetAiGovernancePolicyOverviewQueryPathParams, GetAiGovernancePolicyOverviewQueryQueryParams, } from './hooks/useGetAiGovernancePolicyOverviewQuery';
|
|
123
125
|
export { getAiGovernancePolicyOverview, useGetAiGovernancePolicyOverviewQuery, } from './hooks/useGetAiGovernancePolicyOverviewQuery';
|
|
124
126
|
export type { GetAiGovernancePolicyErrorResponse, GetAiGovernancePolicyOkResponse, GetAiGovernancePolicyProps, GetAiGovernancePolicyQueryPathParams, GetAiGovernancePolicyQueryQueryParams, } from './hooks/useGetAiGovernancePolicyQuery';
|
|
125
127
|
export { getAiGovernancePolicy, useGetAiGovernancePolicyQuery, } from './hooks/useGetAiGovernancePolicyQuery';
|
|
128
|
+
export type { GetAiGovernancePolicySubjectsSpendErrorResponse, GetAiGovernancePolicySubjectsSpendMutationPathParams, GetAiGovernancePolicySubjectsSpendMutationQueryParams, GetAiGovernancePolicySubjectsSpendOkResponse, GetAiGovernancePolicySubjectsSpendProps, GetAiGovernancePolicySubjectsSpendRequestBody, } from './hooks/useGetAiGovernancePolicySubjectsSpendMutation';
|
|
129
|
+
export { getAiGovernancePolicySubjectsSpend, useGetAiGovernancePolicySubjectsSpendMutation, } from './hooks/useGetAiGovernancePolicySubjectsSpendMutation';
|
|
126
130
|
export type { GetAllAsGsErrorResponse, GetAllAsGsMutationPathParams, GetAllAsGsMutationQueryParams, GetAllAsGsOkResponse, GetAllAsGsProps, GetAllAsGsRequestBody, } from './hooks/useGetAllAsGsMutation';
|
|
127
131
|
export { getAllAsGs, useGetAllAsGsMutation } from './hooks/useGetAllAsGsMutation';
|
|
128
132
|
export type { GetAllRuleFiltersErrorResponse, GetAllRuleFiltersOkResponse, GetAllRuleFiltersProps, GetAllRuleFiltersQueryPathParams, GetAllRuleFiltersQueryQueryParams, } from './hooks/useGetAllRuleFiltersQuery';
|
|
@@ -375,6 +379,10 @@ export type { AiGovernanceDryRunResponse } from './schemas/AiGovernanceDryRunRes
|
|
|
375
379
|
export type { AiGovernanceDryRunResult } from './schemas/AiGovernanceDryRunResult';
|
|
376
380
|
export type { AiGovernanceDryRunRuleResult } from './schemas/AiGovernanceDryRunRuleResult';
|
|
377
381
|
export type { AiGovernanceDryRunSubject } from './schemas/AiGovernanceDryRunSubject';
|
|
382
|
+
export type { AiGovernanceGetPoliciesSpendRequest } from './schemas/AiGovernanceGetPoliciesSpendRequest';
|
|
383
|
+
export type { AiGovernanceGetPoliciesSpendResponse } from './schemas/AiGovernanceGetPoliciesSpendResponse';
|
|
384
|
+
export type { AiGovernanceGetPolicySubjectsSpendRequest } from './schemas/AiGovernanceGetPolicySubjectsSpendRequest';
|
|
385
|
+
export type { AiGovernanceGetPolicySubjectsSpendResponse } from './schemas/AiGovernanceGetPolicySubjectsSpendResponse';
|
|
378
386
|
export type { AiGovernanceGovernancePeriod } from './schemas/AiGovernanceGovernancePeriod';
|
|
379
387
|
export type { AiGovernanceMyOverrideRequestsList } from './schemas/AiGovernanceMyOverrideRequestsList';
|
|
380
388
|
export type { AiGovernanceMyOverrideRequestsListRequest } from './schemas/AiGovernanceMyOverrideRequestsListRequest';
|
|
@@ -392,6 +400,7 @@ export type { AiGovernancePolicyListResponse } from './schemas/AiGovernancePolic
|
|
|
392
400
|
export type { AiGovernancePolicyOverviewMetrics } from './schemas/AiGovernancePolicyOverviewMetrics';
|
|
393
401
|
export type { AiGovernancePolicyResponse } from './schemas/AiGovernancePolicyResponse';
|
|
394
402
|
export type { AiGovernancePolicySpec } from './schemas/AiGovernancePolicySpec';
|
|
403
|
+
export type { AiGovernancePolicySpendMetrics } from './schemas/AiGovernancePolicySpendMetrics';
|
|
395
404
|
export type { AiGovernancePolicySubjectRow } from './schemas/AiGovernancePolicySubjectRow';
|
|
396
405
|
export type { AiGovernancePolicySubjectsRequest } from './schemas/AiGovernancePolicySubjectsRequest';
|
|
397
406
|
export type { AiGovernancePolicySubjectsResponse } from './schemas/AiGovernancePolicySubjectsResponse';
|
|
@@ -406,6 +415,7 @@ export type { AiGovernanceReviewOverridesResult } from './schemas/AiGovernanceRe
|
|
|
406
415
|
export type { AiGovernanceRuleBudget } from './schemas/AiGovernanceRuleBudget';
|
|
407
416
|
export type { AiGovernanceRuleOverride } from './schemas/AiGovernanceRuleOverride';
|
|
408
417
|
export type { AiGovernanceRuleOverrideResponse } from './schemas/AiGovernanceRuleOverrideResponse';
|
|
418
|
+
export type { AiGovernanceSubjectSpendMetrics } from './schemas/AiGovernanceSubjectSpendMetrics';
|
|
409
419
|
export type { AiGovernanceSubjects } from './schemas/AiGovernanceSubjects';
|
|
410
420
|
export type { AiGovernanceUserBudgetOverview } from './schemas/AiGovernanceUserBudgetOverview';
|
|
411
421
|
export type { AiGovernanceUserBudgetOverviewResponse } from './schemas/AiGovernanceUserBudgetOverviewResponse';
|
|
@@ -58,8 +58,10 @@ export { gatewaySessionReport, useGatewaySessionReportMutation, } from './hooks/
|
|
|
58
58
|
export { generateDeboardCommand, useGenerateDeboardCommandMutation, } from './hooks/useGenerateDeboardCommandMutation';
|
|
59
59
|
export { generateOnboardCommand, useGenerateOnboardCommandMutation, } from './hooks/useGenerateOnboardCommandMutation';
|
|
60
60
|
export { getAccessPoint, useGetAccessPointQuery } from './hooks/useGetAccessPointQuery';
|
|
61
|
+
export { getAiGovernancePoliciesSpend, useGetAiGovernancePoliciesSpendMutation, } from './hooks/useGetAiGovernancePoliciesSpendMutation';
|
|
61
62
|
export { getAiGovernancePolicyOverview, useGetAiGovernancePolicyOverviewQuery, } from './hooks/useGetAiGovernancePolicyOverviewQuery';
|
|
62
63
|
export { getAiGovernancePolicy, useGetAiGovernancePolicyQuery, } from './hooks/useGetAiGovernancePolicyQuery';
|
|
64
|
+
export { getAiGovernancePolicySubjectsSpend, useGetAiGovernancePolicySubjectsSpendMutation, } from './hooks/useGetAiGovernancePolicySubjectsSpendMutation';
|
|
63
65
|
export { getAllAsGs, useGetAllAsGsMutation } from './hooks/useGetAllAsGsMutation';
|
|
64
66
|
export { getAllRuleFilters, useGetAllRuleFiltersQuery } from './hooks/useGetAllRuleFiltersQuery';
|
|
65
67
|
export { getAllTags, useGetAllTagsQuery } from './hooks/useGetAllTagsQuery';
|
|
@@ -29,7 +29,10 @@ export interface AiGovernanceApprovalRequest {
|
|
|
29
29
|
* Requested budget ceiling raise in USD dollars
|
|
30
30
|
*/
|
|
31
31
|
requestedAmount: number;
|
|
32
|
-
|
|
32
|
+
/**
|
|
33
|
+
* deferred/submitted = auto-approve in progress; pending = awaiting admin review; approved/rejected/expired/error = closed
|
|
34
|
+
*/
|
|
35
|
+
status: 'approved' | 'deferred' | 'error' | 'expired' | 'pending' | 'rejected' | 'submitted';
|
|
33
36
|
subjectId: string;
|
|
34
37
|
/**
|
|
35
38
|
* @format date-time
|
package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendRequest.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Batch spend enrichment request. Accepts up to 50 policy IDs. After deduplicating connector scope and budget period keys across the batch, the server issues GraphQL spend fetches in parallel with a concurrency limit of 10.
|
|
3
|
+
*/
|
|
4
|
+
export interface AiGovernanceGetPoliciesSpendRequest {
|
|
5
|
+
/**
|
|
6
|
+
* Policy IDs to enrich with live spend metrics. Maximum 50 IDs per request.
|
|
7
|
+
*/
|
|
8
|
+
policyIds: string[];
|
|
9
|
+
}
|
package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceGetPoliciesSpendResponse.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Batch subject spend enrichment request. Accepts up to 100 subject emails per request. The server evaluates the primary budget-cap rule once for the batch.
|
|
3
|
+
*/
|
|
4
|
+
export interface AiGovernanceGetPolicySubjectsSpendRequest {
|
|
5
|
+
/**
|
|
6
|
+
* Subject emails to enrich with live spend metrics. Maximum 100 IDs per request.
|
|
7
|
+
*/
|
|
8
|
+
subjectIds: string[];
|
|
9
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/ccm-optimization-service/src/services/schemas/AiGovernancePolicySpendMetrics.d.ts
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { AiGovernancePolicyUserHealth } from '../schemas/AiGovernancePolicyUserHealth';
|
|
2
|
+
/**
|
|
3
|
+
* Live spend and health metrics for one policy returned by the batch spend API. Period metadata and warnings are on the list response.
|
|
4
|
+
*/
|
|
5
|
+
export interface AiGovernancePolicySpendMetrics {
|
|
6
|
+
cumulativeSpend?: number | null;
|
|
7
|
+
/**
|
|
8
|
+
* @format uuid
|
|
9
|
+
*/
|
|
10
|
+
policyId: string;
|
|
11
|
+
spendPercent?: number | null;
|
|
12
|
+
userHealth?: AiGovernancePolicyUserHealth | null;
|
|
13
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/ccm-optimization-service/src/services/schemas/AiGovernancePolicySubjectRow.d.ts
CHANGED
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
import type { AiGovernanceApprovalRequestView } from '../schemas/AiGovernanceApprovalRequestView';
|
|
2
|
+
/**
|
|
3
|
+
* Admin subject row for a governance policy. Spend and health bands may be omitted from list responses; use the batch subject spend API when absent.
|
|
4
|
+
*/
|
|
2
5
|
export interface AiGovernancePolicySubjectRow {
|
|
3
6
|
/**
|
|
4
7
|
* True when the subject has an active block-user enforcement action
|
package/dist/ccm-optimization-service/src/services/schemas/AiGovernanceSubjectSpendMetrics.d.ts
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Live spend and health metrics for one subject returned by the batch subject spend API.
|
|
3
|
+
*/
|
|
4
|
+
export interface AiGovernanceSubjectSpendMetrics {
|
|
5
|
+
/**
|
|
6
|
+
* Subject email
|
|
7
|
+
*/
|
|
8
|
+
email: string;
|
|
9
|
+
/**
|
|
10
|
+
* Current-period spend for the primary budget-cap rule
|
|
11
|
+
*/
|
|
12
|
+
spendAmount: number;
|
|
13
|
+
/**
|
|
14
|
+
* Spend as a percentage of effective budget
|
|
15
|
+
*/
|
|
16
|
+
spendPercent: number;
|
|
17
|
+
/**
|
|
18
|
+
* Budget utilization band for the subject
|
|
19
|
+
*/
|
|
20
|
+
status: 'atRisk' | 'good' | 'overBudget';
|
|
21
|
+
}
|
package/package.json
CHANGED