libZSservicesZSamazonka-waf-regionalZSamazonka-waf-regional
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.WAFRegional.UpdateRuleGroup

Description

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.

Inserts or deletes ActivatedRule objects in a RuleGroup.

You can only insert REGULAR rules into a rule group.

You can have a maximum of ten rules per rule group.

To create and configure a RuleGroup, perform the following steps:

  1. Create and update the Rules that you want to include in the RuleGroup. See CreateRule.
  2. Use GetChangeToken to get the change token that you provide in the ChangeToken parameter of an UpdateRuleGroup request.
  3. Submit an UpdateRuleGroup request to add Rules to the RuleGroup.
  4. Create and update a WebACL that contains the RuleGroup. See CreateWebACL.

If you want to replace one Rule with another, you delete the existing one and add the new one.

For more information about how to use the AWS WAF API to allow or block HTTP requests, see the AWS WAF Developer Guide.

Synopsis

Creating a Request

data UpdateRuleGroup Source #

See: newUpdateRuleGroup smart constructor.

Constructors

UpdateRuleGroup' 

Fields

  • ruleGroupId :: Text

    The RuleGroupId of the RuleGroup that you want to update. RuleGroupId is returned by CreateRuleGroup and by ListRuleGroups.

  • updates :: NonEmpty RuleGroupUpdate

    An array of RuleGroupUpdate objects that you want to insert into or delete from a RuleGroup.

    You can only insert REGULAR rules into a rule group.

    ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup to a WebACL. In this case you do not use ActivatedRule|Action. For all other update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction.

  • changeToken :: Text

    The value returned by the most recent call to GetChangeToken.

Instances

Instances details
Eq UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Read UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Show UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Generic UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Associated Types

type Rep UpdateRuleGroup :: Type -> Type #

NFData UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Methods

rnf :: UpdateRuleGroup -> () #

Hashable UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

ToJSON UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

AWSRequest UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Associated Types

type AWSResponse UpdateRuleGroup #

ToHeaders UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

ToPath UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

ToQuery UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

type Rep UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

type Rep UpdateRuleGroup = D1 ('MetaData "UpdateRuleGroup" "Amazonka.WAFRegional.UpdateRuleGroup" "libZSservicesZSamazonka-waf-regionalZSamazonka-waf-regional" 'False) (C1 ('MetaCons "UpdateRuleGroup'" 'PrefixI 'True) (S1 ('MetaSel ('Just "ruleGroupId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: (S1 ('MetaSel ('Just "updates") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (NonEmpty RuleGroupUpdate)) :*: S1 ('MetaSel ('Just "changeToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text))))
type AWSResponse UpdateRuleGroup Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

newUpdateRuleGroup Source #

Create a value of UpdateRuleGroup with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:ruleGroupId:UpdateRuleGroup', updateRuleGroup_ruleGroupId - The RuleGroupId of the RuleGroup that you want to update. RuleGroupId is returned by CreateRuleGroup and by ListRuleGroups.

$sel:updates:UpdateRuleGroup', updateRuleGroup_updates - An array of RuleGroupUpdate objects that you want to insert into or delete from a RuleGroup.

You can only insert REGULAR rules into a rule group.

ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup to a WebACL. In this case you do not use ActivatedRule|Action. For all other update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction.

$sel:changeToken:UpdateRuleGroup', updateRuleGroup_changeToken - The value returned by the most recent call to GetChangeToken.

Request Lenses

updateRuleGroup_ruleGroupId :: Lens' UpdateRuleGroup Text Source #

The RuleGroupId of the RuleGroup that you want to update. RuleGroupId is returned by CreateRuleGroup and by ListRuleGroups.

updateRuleGroup_updates :: Lens' UpdateRuleGroup (NonEmpty RuleGroupUpdate) Source #

An array of RuleGroupUpdate objects that you want to insert into or delete from a RuleGroup.

You can only insert REGULAR rules into a rule group.

ActivatedRule|OverrideAction applies only when updating or adding a RuleGroup to a WebACL. In this case you do not use ActivatedRule|Action. For all other update requests, ActivatedRule|Action is used instead of ActivatedRule|OverrideAction.

updateRuleGroup_changeToken :: Lens' UpdateRuleGroup Text Source #

The value returned by the most recent call to GetChangeToken.

Destructuring the Response

data UpdateRuleGroupResponse Source #

See: newUpdateRuleGroupResponse smart constructor.

Constructors

UpdateRuleGroupResponse' 

Fields

  • changeToken :: Maybe Text

    The ChangeToken that you used to submit the UpdateRuleGroup request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus.

  • httpStatus :: Int

    The response's http status code.

Instances

Instances details
Eq UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Read UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Show UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Generic UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Associated Types

type Rep UpdateRuleGroupResponse :: Type -> Type #

NFData UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

Methods

rnf :: UpdateRuleGroupResponse -> () #

type Rep UpdateRuleGroupResponse Source # 
Instance details

Defined in Amazonka.WAFRegional.UpdateRuleGroup

type Rep UpdateRuleGroupResponse = D1 ('MetaData "UpdateRuleGroupResponse" "Amazonka.WAFRegional.UpdateRuleGroup" "libZSservicesZSamazonka-waf-regionalZSamazonka-waf-regional" 'False) (C1 ('MetaCons "UpdateRuleGroupResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "changeToken") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))

newUpdateRuleGroupResponse Source #

Create a value of UpdateRuleGroupResponse with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:changeToken:UpdateRuleGroup', updateRuleGroupResponse_changeToken - The ChangeToken that you used to submit the UpdateRuleGroup request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus.

$sel:httpStatus:UpdateRuleGroupResponse', updateRuleGroupResponse_httpStatus - The response's http status code.

Response Lenses

updateRuleGroupResponse_changeToken :: Lens' UpdateRuleGroupResponse (Maybe Text) Source #

The ChangeToken that you used to submit the UpdateRuleGroup request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus.