Skip to content
v2.277.0

MonetizationConfigProperty Struct ​

Configures monetization for the web ACL or rule group.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_wafv2 as wafv2 } from 'aws-cdk-lib';
const monetizationConfigProperty: wafv2.CfnWebACL.MonetizationConfigProperty = {
  connectedAccountConfigs: [{
    connectedAccountArn: 'connectedAccountArn',
    paymentNetworks: [{
      chain: 'chain',
      prices: [{
        amount: 'amount',
        currency: 'currency',
      }],
    }],
  }],
  cryptoConfig: {
    paymentNetworks: [{
      chain: 'chain',
      prices: [{
        amount: 'amount',
        currency: 'currency',
      }],
      walletAddress: 'walletAddress',
    }],
  },
  currencyMode: 'currencyMode',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_wafv2 as wafv2

monetization_config_property = wafv2.CfnWebACL.MonetizationConfigProperty(
    connected_account_configs=[wafv2.CfnWebACL.ConnectedAccountConfigProperty(
        connected_account_arn="connectedAccountArn",
        payment_networks=[wafv2.CfnWebACL.ConnectedAccountChainConfigProperty(
            chain="chain",
            prices=[wafv2.CfnWebACL.ConnectedAccountPriceProperty(
                amount="amount",
                currency="currency"
            )]
        )]
    )],
    crypto_config=wafv2.CfnWebACL.CryptoConfigProperty(
        payment_networks=[wafv2.CfnWebACL.PaymentNetworkProperty(
            chain="chain",
            prices=[wafv2.CfnWebACL.PriceProperty(
                amount="amount",
                currency="currency"
            )],
            wallet_address="walletAddress"
        )]
    ),
    currency_mode="currencyMode"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.wafv2.*;

MonetizationConfigProperty monetizationConfigProperty = MonetizationConfigProperty.builder()
        .connectedAccountConfigs(List.of(ConnectedAccountConfigProperty.builder()
                .connectedAccountArn("connectedAccountArn")
                .paymentNetworks(List.of(ConnectedAccountChainConfigProperty.builder()
                        .chain("chain")
                        .prices(List.of(ConnectedAccountPriceProperty.builder()
                                .amount("amount")
                                .currency("currency")
                                .build()))
                        .build()))
                .build()))
        .cryptoConfig(CryptoConfigProperty.builder()
                .paymentNetworks(List.of(PaymentNetworkProperty.builder()
                        .chain("chain")
                        .prices(List.of(PriceProperty.builder()
                                .amount("amount")
                                .currency("currency")
                                .build()))
                        .walletAddress("walletAddress")
                        .build()))
                .build())
        .currencyMode("currencyMode")
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.WAFv2;

var monetizationConfigProperty = new MonetizationConfigProperty {
    ConnectedAccountConfigs = new [] { new ConnectedAccountConfigProperty {
        ConnectedAccountArn = "connectedAccountArn",
        PaymentNetworks = new [] { new ConnectedAccountChainConfigProperty {
            Chain = "chain",
            Prices = new [] { new ConnectedAccountPriceProperty {
                Amount = "amount",
                Currency = "currency"
            } }
        } }
    } },
    CryptoConfig = new CryptoConfigProperty {
        PaymentNetworks = new [] { new PaymentNetworkProperty {
            Chain = "chain",
            Prices = new [] { new PriceProperty {
                Amount = "amount",
                Currency = "currency"
            } },
            WalletAddress = "walletAddress"
        } }
    },
    CurrencyMode = "currencyMode"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

monetizationConfigProperty := &MonetizationConfigProperty{
	ConnectedAccountConfigs: []interface{}{
		&ConnectedAccountConfigProperty{
			ConnectedAccountArn: jsii.String("connectedAccountArn"),
			PaymentNetworks: []interface{}{
				&ConnectedAccountChainConfigProperty{
					Chain: jsii.String("chain"),
					Prices: []interface{}{
						&ConnectedAccountPriceProperty{
							Amount: jsii.String("amount"),
							Currency: jsii.String("currency"),
						},
					},
				},
			},
		},
	},
	CryptoConfig: &CryptoConfigProperty{
		PaymentNetworks: []interface{}{
			&PaymentNetworkProperty{
				Chain: jsii.String("chain"),
				Prices: []interface{}{
					&PriceProperty{
						Amount: jsii.String("amount"),
						Currency: jsii.String("currency"),
					},
				},
				WalletAddress: jsii.String("walletAddress"),
			},
		},
	},
	CurrencyMode: jsii.String("currencyMode"),
}

Properties ​

connectedAccountConfigsoptionalIResolvable | IResolvable | CfnWebACL.ConnectedAccountConfigProperty[]connected_account_configsoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, ConnectedAccountConfigProperty]]]connectedAccountConfigsoptionalIResolvableConnectedAccountConfigsoptionalIResolvableConnectedAccountConfigsoptionalinterface{}#
List of connected account configurations.

A connected account delegates deposit-address provisioning to the payments provider instead of specifying a wallet directly.

cryptoConfigoptionalIResolvable | CfnWebACL.CryptoConfigPropertycrypto_configoptionaltyping.Union[IResolvable, CryptoConfigProperty]cryptoConfigoptionalIResolvableCryptoConfigoptionalIResolvableCryptoConfigoptionalinterface{}#
Configures cryptocurrency payment settings.
currencyModeoptionalstringcurrency_modeoptionalstrcurrencyModeoptionalStringCurrencyModeoptionalstringCurrencyModeoptional*string#
The currency mode for monetization.

Use REAL for production payments and TEST for testing with testnet currencies.