import { BaseAPIRequestFactory } from "../../datadog-api-client-common/baseapi"; import { Configuration } from "../../datadog-api-client-common/configuration"; import { RequestContext, ResponseContext } from "../../datadog-api-client-common/http/http"; import { ControlNotificationSettingsResponse } from "../models/ControlNotificationSettingsResponse"; import { ControlNotificationSettingsUpdateRequest } from "../models/ControlNotificationSettingsUpdateRequest"; import { GovernanceConfigResponse } from "../models/GovernanceConfigResponse"; import { GovernanceControlDetectionResponse } from "../models/GovernanceControlDetectionResponse"; import { GovernanceControlDetectionsResponse } from "../models/GovernanceControlDetectionsResponse"; import { GovernanceControlDetectionUpdateRequest } from "../models/GovernanceControlDetectionUpdateRequest"; import { GovernanceControlResponse } from "../models/GovernanceControlResponse"; import { GovernanceControlsResponse } from "../models/GovernanceControlsResponse"; import { GovernanceControlUpdateRequest } from "../models/GovernanceControlUpdateRequest"; import { GovernanceInsightsResponse } from "../models/GovernanceInsightsResponse"; import { GovernanceMitigationRequest } from "../models/GovernanceMitigationRequest"; import { GovernanceNotificationSettingsResponse } from "../models/GovernanceNotificationSettingsResponse"; import { GovernanceNotificationSettingsUpdateRequest } from "../models/GovernanceNotificationSettingsUpdateRequest"; export declare class GovernanceConsoleApiRequestFactory extends BaseAPIRequestFactory { getGovernanceConfig(_options?: Configuration): Promise; getGovernanceControl(detectionType: string, _options?: Configuration): Promise; getGovernanceControlNotificationSettings(detectionType: string, _options?: Configuration): Promise; getGovernanceDetection(detectionId: string, _options?: Configuration): Promise; getGovernanceNotificationSettings(_options?: Configuration): Promise; listGovernanceControlDetections(detectionType: string, filterState?: string, filterQuery?: string, sort?: string, pageNumber?: number, pageSize?: number, _options?: Configuration): Promise; listGovernanceControls(_options?: Configuration): Promise; listGovernanceInsights(filterProduct?: Array, _options?: Configuration): Promise; mitigateGovernanceDetections(body: GovernanceMitigationRequest, _options?: Configuration): Promise; updateGovernanceControl(detectionType: string, body: GovernanceControlUpdateRequest, _options?: Configuration): Promise; updateGovernanceControlNotificationSettings(detectionType: string, body: ControlNotificationSettingsUpdateRequest, _options?: Configuration): Promise; updateGovernanceDetection(detectionId: string, body: GovernanceControlDetectionUpdateRequest, _options?: Configuration): Promise; updateGovernanceNotificationSettings(body: GovernanceNotificationSettingsUpdateRequest, _options?: Configuration): Promise; } export declare class GovernanceConsoleApiResponseProcessor { /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to getGovernanceConfig * @throws ApiException if the response code was not in [200, 299] */ getGovernanceConfig(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to getGovernanceControl * @throws ApiException if the response code was not in [200, 299] */ getGovernanceControl(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to getGovernanceControlNotificationSettings * @throws ApiException if the response code was not in [200, 299] */ getGovernanceControlNotificationSettings(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to getGovernanceDetection * @throws ApiException if the response code was not in [200, 299] */ getGovernanceDetection(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to getGovernanceNotificationSettings * @throws ApiException if the response code was not in [200, 299] */ getGovernanceNotificationSettings(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to listGovernanceControlDetections * @throws ApiException if the response code was not in [200, 299] */ listGovernanceControlDetections(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to listGovernanceControls * @throws ApiException if the response code was not in [200, 299] */ listGovernanceControls(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to listGovernanceInsights * @throws ApiException if the response code was not in [200, 299] */ listGovernanceInsights(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to mitigateGovernanceDetections * @throws ApiException if the response code was not in [200, 299] */ mitigateGovernanceDetections(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to updateGovernanceControl * @throws ApiException if the response code was not in [200, 299] */ updateGovernanceControl(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to updateGovernanceControlNotificationSettings * @throws ApiException if the response code was not in [200, 299] */ updateGovernanceControlNotificationSettings(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to updateGovernanceDetection * @throws ApiException if the response code was not in [200, 299] */ updateGovernanceDetection(response: ResponseContext): Promise; /** * Unwraps the actual response sent by the server from the response context and deserializes the response content * to the expected objects * * @params response Response returned by the server for a request to updateGovernanceNotificationSettings * @throws ApiException if the response code was not in [200, 299] */ updateGovernanceNotificationSettings(response: ResponseContext): Promise; } export interface GovernanceConsoleApiGetGovernanceControlRequest { /** * The detection type that identifies the control, for example `unused_api_keys`. * @type string */ detectionType: string; } export interface GovernanceConsoleApiGetGovernanceControlNotificationSettingsRequest { /** * The detection type that identifies the control; for example, `unused_api_keys`. * @type string */ detectionType: string; } export interface GovernanceConsoleApiGetGovernanceDetectionRequest { /** * The unique identifier of the detection. * @type string */ detectionId: string; } export interface GovernanceConsoleApiListGovernanceControlDetectionsRequest { /** * The detection type that identifies the control; for example, `unused_api_keys`. * @type string */ detectionType: string; /** * Restrict the results to detections in the given state. * @type string */ filterState?: string; /** * Restrict the results to detections matching the given free-text query. * @type string */ filterQuery?: string; /** * A comma-separated list of attributes to sort detections by. Prefix an attribute with * `-` for descending order. * * The attributes available for sorting are `id`, `created_at`, `assigned_to`, * `detection_type`, `display_name`, `exception_at`, `mitigate_after`, `mitigated_at`, * `priority`, `resource_id`, and `state`. Defaults to `created_at,-id`. * @type string */ sort?: string; /** * The zero-based index of the page to return; the first page is 0. * @type number */ pageNumber?: number; /** * The number of detections to return per page. * @type number */ pageSize?: number; } export interface GovernanceConsoleApiListGovernanceInsightsRequest { /** * Restrict the results to insights belonging to the given products. May be repeated to * filter by multiple products. Matching is case-insensitive. * @type Array */ filterProduct?: Array; } export interface GovernanceConsoleApiMitigateGovernanceDetectionsRequest { /** * @type GovernanceMitigationRequest */ body: GovernanceMitigationRequest; } export interface GovernanceConsoleApiUpdateGovernanceControlRequest { /** * The detection type that identifies the control, for example `unused_api_keys`. * @type string */ detectionType: string; /** * @type GovernanceControlUpdateRequest */ body: GovernanceControlUpdateRequest; } export interface GovernanceConsoleApiUpdateGovernanceControlNotificationSettingsRequest { /** * The detection type that identifies the control; for example, `unused_api_keys`. * @type string */ detectionType: string; /** * @type ControlNotificationSettingsUpdateRequest */ body: ControlNotificationSettingsUpdateRequest; } export interface GovernanceConsoleApiUpdateGovernanceDetectionRequest { /** * The unique identifier of the detection. * @type string */ detectionId: string; /** * @type GovernanceControlDetectionUpdateRequest */ body: GovernanceControlDetectionUpdateRequest; } export interface GovernanceConsoleApiUpdateGovernanceNotificationSettingsRequest { /** * @type GovernanceNotificationSettingsUpdateRequest */ body: GovernanceNotificationSettingsUpdateRequest; } export declare class GovernanceConsoleApi { private requestFactory; private responseProcessor; private configuration; constructor(configuration: Configuration, requestFactory?: GovernanceConsoleApiRequestFactory, responseProcessor?: GovernanceConsoleApiResponseProcessor); /** * Retrieve the Governance Console configuration for the organization, including whether the * Console is enabled, whether assignment notifications are enabled, and whether usage * attribution is configured. * @param param The request object */ getGovernanceConfig(options?: Configuration): Promise; /** * Retrieve a single governance control by its detection type, including the organization's current * detection, notification, and mitigation configuration and detection counts. * @param param The request object */ getGovernanceControl(param: GovernanceConsoleApiGetGovernanceControlRequest, options?: Configuration): Promise; /** * Retrieve the notification settings for the governance control with the given detection type, * including, for each supported event type, whether notifications are enabled and which * destinations receive them. * @param param The request object */ getGovernanceControlNotificationSettings(param: GovernanceConsoleApiGetGovernanceControlNotificationSettingsRequest, options?: Configuration): Promise; /** * Retrieve a single governance detection by its unique identifier. * @param param The request object */ getGovernanceDetection(param: GovernanceConsoleApiGetGovernanceDetectionRequest, options?: Configuration): Promise; /** * Retrieve the organization-wide governance notification settings, including whether users are * notified when detections are assigned to them. * @param param The request object */ getGovernanceNotificationSettings(options?: Configuration): Promise; /** * Retrieve the detections produced by the governance control with the given detection type. * Results can be filtered by state and free-text query, sorted, and paginated. * @param param The request object */ listGovernanceControlDetections(param: GovernanceConsoleApiListGovernanceControlDetectionsRequest, options?: Configuration): Promise; /** * Retrieve the list of governance controls configured for the organization. Each control pairs a * detection definition with the organization's current detection, notification, and mitigation * configuration, along with counts of active and mitigated detections. * @param param The request object */ listGovernanceControls(options?: Configuration): Promise; /** * Retrieve the list of governance insights available to the organization. Each insight * reports the query used to compute it, so that the value can be computed client-side. * Insights can be filtered by product. * @param param The request object */ listGovernanceInsights(param?: GovernanceConsoleApiListGovernanceInsightsRequest, options?: Configuration): Promise; /** * Apply a mitigation to a set of governance detections of a given detection type. When the * mitigation type is omitted, the control's configured mitigation is used. The request is * accepted for asynchronous processing. * @param param The request object */ mitigateGovernanceDetections(param: GovernanceConsoleApiMitigateGovernanceDetectionsRequest, options?: Configuration): Promise; /** * Update the detection, notification, and mitigation configuration of a governance control. Only * the attributes present in the request are modified. Changing the mitigation type or its * parameters may require additional permissions. * @param param The request object */ updateGovernanceControl(param: GovernanceConsoleApiUpdateGovernanceControlRequest, options?: Configuration): Promise; /** * Replace the notification settings for the governance control with the given detection type, * setting, for each supported event type, whether notifications are enabled and which * destinations receive them. * @param param The request object */ updateGovernanceControlNotificationSettings(param: GovernanceConsoleApiUpdateGovernanceControlNotificationSettingsRequest, options?: Configuration): Promise; /** * Update a governance detection by its unique identifier. Only the attributes present in the * request are modified, allowing a detection to be acknowledged as an exception, reopened, * reassigned, or deferred for mitigation. * @param param The request object */ updateGovernanceDetection(param: GovernanceConsoleApiUpdateGovernanceDetectionRequest, options?: Configuration): Promise; /** * Update the organization-wide governance notification settings. Only the attributes present in * the request are modified. * @param param The request object */ updateGovernanceNotificationSettings(param: GovernanceConsoleApiUpdateGovernanceNotificationSettingsRequest, options?: Configuration): Promise; }