import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { PutLoggingConfigurationRequest, PutLoggingConfigurationResponse } from "../models/models_0"; /** * @public */ export type { __MetadataBearer }; /** * @public * * The input for {@link PutLoggingConfigurationCommand}. */ export interface PutLoggingConfigurationCommandInput extends PutLoggingConfigurationRequest { } /** * @public * * The output of {@link PutLoggingConfigurationCommand}. */ export interface PutLoggingConfigurationCommandOutput extends PutLoggingConfigurationResponse, __MetadataBearer { } declare const PutLoggingConfigurationCommand_base: { new (input: PutLoggingConfigurationCommandInput): import("@smithy/core/client").CommandImpl; new (input: PutLoggingConfigurationCommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): import("@smithy/types").EndpointParameterInstructions; }; /** * *

This is AWS WAF Classic documentation. For * more information, see AWS * WAF Classic in the developer guide.

*

* For the latest version of AWS * WAF, use the AWS WAFV2 API and see the AWS WAF Developer Guide. With the latest version, AWS WAF has a single set of endpoints for regional and global use.

*
*

Associates a LoggingConfiguration with a specified web ACL.

*

You can access information about all traffic that AWS WAF inspects using the following * steps:

*
    *
  1. *

    Create an Amazon Kinesis Data * Firehose.

    *

    Create the data firehose with a PUT source and in the region that you are operating. However, if you are capturing logs for Amazon CloudFront, always create the firehose in US East (N. Virginia).

    * *

    Do not create the data firehose using a Kinesis stream as your source.

    *
    *
  2. *
  3. *

    Associate that firehose to your web ACL using a PutLoggingConfiguration request.

    *
  4. *
* *

When you successfully enable logging using a PutLoggingConfiguration request, AWS WAF will create a service linked role with the necessary permissions to write logs to the Amazon Kinesis Data Firehose. For more information, see Logging Web ACL Traffic Information in the AWS WAF Developer Guide.

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { WAFRegionalClient, PutLoggingConfigurationCommand } from "@aws-sdk/client-waf-regional"; // ES Modules import * // const { WAFRegionalClient, PutLoggingConfigurationCommand } = require("@aws-sdk/client-waf-regional"); // CommonJS import * // import type { WAFRegionalClientConfig } from "@aws-sdk/client-waf-regional"; * const config = {}; // type is WAFRegionalClientConfig * const client = new WAFRegionalClient(config); * const input = { // PutLoggingConfigurationRequest * LoggingConfiguration: { // LoggingConfiguration * ResourceArn: "STRING_VALUE", // required * LogDestinationConfigs: [ // LogDestinationConfigs // required * "STRING_VALUE", * ], * RedactedFields: [ // RedactedFields * { // FieldToMatch * Type: "URI" || "QUERY_STRING" || "HEADER" || "METHOD" || "BODY" || "SINGLE_QUERY_ARG" || "ALL_QUERY_ARGS", // required * Data: "STRING_VALUE", * }, * ], * }, * }; * const command = new PutLoggingConfigurationCommand(input); * const response = await client.send(command); * // { // PutLoggingConfigurationResponse * // LoggingConfiguration: { // LoggingConfiguration * // ResourceArn: "STRING_VALUE", // required * // LogDestinationConfigs: [ // LogDestinationConfigs // required * // "STRING_VALUE", * // ], * // RedactedFields: [ // RedactedFields * // { // FieldToMatch * // Type: "URI" || "QUERY_STRING" || "HEADER" || "METHOD" || "BODY" || "SINGLE_QUERY_ARG" || "ALL_QUERY_ARGS", // required * // Data: "STRING_VALUE", * // }, * // ], * // }, * // }; * * ``` * * @param PutLoggingConfigurationCommandInput - {@link PutLoggingConfigurationCommandInput} * @returns {@link PutLoggingConfigurationCommandOutput} * @see {@link PutLoggingConfigurationCommandInput} for command's `input` shape. * @see {@link PutLoggingConfigurationCommandOutput} for command's `response` shape. * @see {@link WAFRegionalClientResolvedConfig | config} for WAFRegionalClient's `config` shape. * * @throws {@link WAFInternalErrorException} (server fault) *

The operation failed because of a system problem, even though the request was valid. Retry your request.

* * @throws {@link WAFNonexistentItemException} (client fault) *

The operation failed because the referenced object doesn't exist.

* * @throws {@link WAFServiceLinkedRoleErrorException} (client fault) *

AWS WAF is not able to access the service linked role. This can be caused by a previous PutLoggingConfiguration request, which can lock the service linked role for about 20 seconds. Please try your request again. The service linked role can also be locked by a previous DeleteServiceLinkedRole request, which can lock the role for 15 minutes or more. If you recently made a DeleteServiceLinkedRole, wait at least 15 minutes and try the request again. If you receive this same exception again, you will have to wait additional time until the role is unlocked.

* * @throws {@link WAFStaleDataException} (client fault) *

The operation failed because you tried to create, update, or delete an object by using a change token that has already been used.

* * @throws {@link WAFRegionalServiceException} *

Base exception class for all service exceptions from WAFRegional service.

* * * @public */ export declare class PutLoggingConfigurationCommand extends PutLoggingConfigurationCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: PutLoggingConfigurationRequest; output: PutLoggingConfigurationResponse; }; sdk: { input: PutLoggingConfigurationCommandInput; output: PutLoggingConfigurationCommandOutput; }; }; }