Chilkat Online Tools

GetRuleGroup SQL Server Example

AWS WAFV2

CREATE PROCEDURE ChilkatSample
AS
BEGIN
    DECLARE @hr int
    DECLARE @iTmp0 int
    DECLARE @sTmp0 nvarchar(max)
    -- This example requires the Chilkat API to have been previously unlocked.
    -- See Global Unlock Sample for sample code.

    DECLARE @rest int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.Rest', @rest OUT
    IF @hr <> 0
    BEGIN
        PRINT 'Failed to create ActiveX component'
        RETURN
    END

    DECLARE @success int

    DECLARE @authAws int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.AuthAws', @authAws OUT

    EXEC sp_OASetProperty @authAws, 'AccessKey', 'AWS_ACCESS_KEY'
    EXEC sp_OASetProperty @authAws, 'SecretKey', 'AWS_SECRET_KEY'

    -- Don't forget to change the region to your particular region. (Also make the same change in the call to Connect below.)
    EXEC sp_OASetProperty @authAws, 'Region', 'us-west-2'
    EXEC sp_OASetProperty @authAws, 'ServiceName', 'wafv2'
    -- SetAuthAws causes Chilkat to automatically add the following headers: Authorization, X-Amz-Date
    EXEC sp_OAMethod @rest, 'SetAuthAws', @success OUT, @authAws

    -- URL: https://wafv2.us-west-2.amazonaws.com/
    -- Use the same region as specified above.
    EXEC sp_OAMethod @rest, 'Connect', @success OUT, 'wafv2.us-west-2.amazonaws.com', 443, 1, 1
    IF @success <> 1
      BEGIN

        EXEC sp_OAGetProperty @rest, 'ConnectFailReason', @iTmp0 OUT
        PRINT 'ConnectFailReason: ' + @iTmp0
        EXEC sp_OAGetProperty @rest, 'LastErrorText', @sTmp0 OUT
        PRINT @sTmp0
        EXEC @hr = sp_OADestroy @rest
        EXEC @hr = sp_OADestroy @authAws
        RETURN
      END

    -- The following code creates the JSON request body.
    -- The JSON created by this code is shown below.

    -- Use this online tool to generate code from sample JSON:
    -- Generate Code to Create JSON

    DECLARE @json int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.JsonObject', @json OUT

    EXEC sp_OAMethod @json, 'UpdateString', @success OUT, 'ARN', 'string'
    EXEC sp_OAMethod @json, 'UpdateString', @success OUT, 'Id', 'string'
    EXEC sp_OAMethod @json, 'UpdateString', @success OUT, 'Name', 'string'
    EXEC sp_OAMethod @json, 'UpdateString', @success OUT, 'Scope', 'string'

    -- The JSON request body created by the above code:

    -- {
    --   "ARN": "string",
    --   "Id": "string",
    --   "Name": "string",
    --   "Scope": "string"
    -- }

    EXEC sp_OAMethod @rest, 'AddHeader', @success OUT, 'Content-Type', 'application/x-amz-json-1.1'
    EXEC sp_OAMethod @rest, 'AddHeader', @success OUT, 'X-Amz-Target', 'AWSWAF_20190729.GetRuleGroup'

    DECLARE @sbRequestBody int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.StringBuilder', @sbRequestBody OUT

    EXEC sp_OAMethod @json, 'EmitSb', @success OUT, @sbRequestBody
    DECLARE @sbResponseBody int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.StringBuilder', @sbResponseBody OUT

    EXEC sp_OAMethod @rest, 'FullRequestSb', @success OUT, 'POST', '/', @sbRequestBody, @sbResponseBody
    IF @success <> 1
      BEGIN
        EXEC sp_OAGetProperty @rest, 'LastErrorText', @sTmp0 OUT
        PRINT @sTmp0
        EXEC @hr = sp_OADestroy @rest
        EXEC @hr = sp_OADestroy @authAws
        EXEC @hr = sp_OADestroy @json
        EXEC @hr = sp_OADestroy @sbRequestBody
        EXEC @hr = sp_OADestroy @sbResponseBody
        RETURN
      END
    DECLARE @respStatusCode int
    EXEC sp_OAGetProperty @rest, 'ResponseStatusCode', @respStatusCode OUT

    PRINT 'response status code = ' + @respStatusCode
    IF @respStatusCode <> 200
      BEGIN

        PRINT 'Response Header:'
        EXEC sp_OAGetProperty @rest, 'ResponseHeader', @sTmp0 OUT
        PRINT @sTmp0

        PRINT 'Response Body:'
        EXEC sp_OAMethod @sbResponseBody, 'GetAsString', @sTmp0 OUT
        PRINT @sTmp0
        EXEC @hr = sp_OADestroy @rest
        EXEC @hr = sp_OADestroy @authAws
        EXEC @hr = sp_OADestroy @json
        EXEC @hr = sp_OADestroy @sbRequestBody
        EXEC @hr = sp_OADestroy @sbResponseBody
        RETURN
      END

    DECLARE @jResp int
    EXEC @hr = sp_OACreate 'Chilkat_9_5_0.JsonObject', @jResp OUT

    EXEC sp_OAMethod @jResp, 'LoadSb', @success OUT, @sbResponseBody

    -- The following code parses the JSON response.
    -- A sample JSON response is shown below the sample code.

    -- Use this online tool to generate parsing code from sample JSON:
    -- Generate Parsing Code from JSON

    DECLARE @CustomResponseBodyKey nvarchar(max)

    DECLARE @ResponseCode int

    DECLARE @ImmunityTime int

    DECLARE @Priority int

    DECLARE @OversizeHandling nvarchar(max)

    DECLARE @MatchScope nvarchar(max)

    DECLARE @CookiesOversizeHandling nvarchar(max)

    DECLARE @HeadersMatchScope nvarchar(max)

    DECLARE @HeadersOversizeHandling nvarchar(max)

    DECLARE @InvalidFallbackBehavior nvarchar(max)

    DECLARE @JsonBodyMatchScope nvarchar(max)

    DECLARE @JsonBodyOversizeHandling nvarchar(max)

    DECLARE @SingleHeaderName nvarchar(max)

    DECLARE @SingleQueryArgumentName nvarchar(max)

    DECLARE @PositionalConstraint nvarchar(max)

    DECLARE @SearchString int

    DECLARE @FallbackBehavior nvarchar(max)

    DECLARE @HeaderName nvarchar(max)

    DECLARE @IPSetReferenceStatementARN nvarchar(max)

    DECLARE @IPSetForwardedIPConfigFallbackBehavior nvarchar(max)

    DECLARE @IPSetForwardedIPConfigHeaderName nvarchar(max)

    DECLARE @Position nvarchar(max)

    DECLARE @Key nvarchar(max)

    DECLARE @Scope nvarchar(max)

    DECLARE @ManagedRuleGroupStatementName nvarchar(max)

    DECLARE @ScopeDownStatement nvarchar(max)

    DECLARE @VendorName nvarchar(max)

    DECLARE @Version nvarchar(max)

    DECLARE @Statement nvarchar(max)

    DECLARE @AggregateKeyType nvarchar(max)

    DECLARE @ForwardedIPConfigFallbackBehavior nvarchar(max)

    DECLARE @ForwardedIPConfigHeaderName nvarchar(max)

    DECLARE @Limit int

    DECLARE @RateBasedStatementScopeDownStatement nvarchar(max)

    DECLARE @BodyOversizeHandling nvarchar(max)

    DECLARE @CookiesMatchScope nvarchar(max)

    DECLARE @JsonBodyInvalidFallbackBehavior nvarchar(max)

    DECLARE @RegexString nvarchar(max)

    DECLARE @RegexPatternSetReferenceStatementARN nvarchar(max)

    DECLARE @RuleGroupReferenceStatementARN nvarchar(max)

    DECLARE @ComparisonOperator nvarchar(max)

    DECLARE @Size int

    DECLARE @VisibilityConfigCloudWatchMetricsEnabled int

    DECLARE @VisibilityConfigMetricName nvarchar(max)

    DECLARE @VisibilityConfigSampledRequestsEnabled int

    DECLARE @j int

    DECLARE @count_j int

    DECLARE @Value nvarchar(max)

    DECLARE @strVal nvarchar(max)

    DECLARE @v_Type nvarchar(max)

    DECLARE @LoginPath nvarchar(max)

    DECLARE @Identifier nvarchar(max)

    DECLARE @PayloadType nvarchar(max)

    DECLARE @UsernameFieldIdentifier nvarchar(max)

    DECLARE @LockToken nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @LockToken OUT, 'LockToken'
    DECLARE @ARN nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @ARN OUT, 'RuleGroup.ARN'
    DECLARE @Capacity int
    EXEC sp_OAMethod @jResp, 'IntOf', @Capacity OUT, 'RuleGroup.Capacity'
    DECLARE @Content nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @Content OUT, 'RuleGroup.CustomResponseBodies.string.Content'
    DECLARE @ContentType nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @ContentType OUT, 'RuleGroup.CustomResponseBodies.string.ContentType'
    DECLARE @Description nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @Description OUT, 'RuleGroup.Description'
    DECLARE @Id nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @Id OUT, 'RuleGroup.Id'
    DECLARE @LabelNamespace nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @LabelNamespace OUT, 'RuleGroup.LabelNamespace'
    DECLARE @Name nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Name'
    DECLARE @CloudWatchMetricsEnabled int
    EXEC sp_OAMethod @jResp, 'IntOf', @CloudWatchMetricsEnabled OUT, 'RuleGroup.VisibilityConfig.CloudWatchMetricsEnabled'
    DECLARE @MetricName nvarchar(max)
    EXEC sp_OAMethod @jResp, 'StringOf', @MetricName OUT, 'RuleGroup.VisibilityConfig.MetricName'
    DECLARE @SampledRequestsEnabled int
    EXEC sp_OAMethod @jResp, 'IntOf', @SampledRequestsEnabled OUT, 'RuleGroup.VisibilityConfig.SampledRequestsEnabled'
    DECLARE @i int
    SELECT @i = 0
    DECLARE @count_i int
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'RuleGroup.AvailableLabels'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.AvailableLabels[i].Name'
        SELECT @i = @i + 1
      END
    SELECT @i = 0
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'RuleGroup.ConsumedLabels'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.ConsumedLabels[i].Name'
        SELECT @i = @i + 1
      END
    SELECT @i = 0
    EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_i OUT, 'RuleGroup.Rules'
    WHILE @i < @count_i
      BEGIN
        EXEC sp_OASetProperty @jResp, 'I', @i
        EXEC sp_OAMethod @jResp, 'StringOf', @CustomResponseBodyKey OUT, 'RuleGroup.Rules[i].Action.Block.CustomResponse.CustomResponseBodyKey'
        EXEC sp_OAMethod @jResp, 'IntOf', @ResponseCode OUT, 'RuleGroup.Rules[i].Action.Block.CustomResponse.ResponseCode'
        EXEC sp_OAMethod @jResp, 'IntOf', @ImmunityTime OUT, 'RuleGroup.Rules[i].CaptchaConfig.ImmunityTimeProperty.ImmunityTime'
        EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Name'
        EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Priority'
        EXEC sp_OAMethod @jResp, 'StringOf', @OversizeHandling OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @MatchScope OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @InvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @PositionalConstraint OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.PositionalConstraint'
        EXEC sp_OAMethod @jResp, 'IntOf', @SearchString OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.SearchString'
        EXEC sp_OAMethod @jResp, 'StringOf', @FallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.GeoMatchStatement.ForwardedIPConfig.FallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeaderName OUT, 'RuleGroup.Rules[i].Statement.GeoMatchStatement.ForwardedIPConfig.HeaderName'
        EXEC sp_OAMethod @jResp, 'StringOf', @IPSetReferenceStatementARN OUT, 'RuleGroup.Rules[i].Statement.IPSetReferenceStatement.ARN'
        EXEC sp_OAMethod @jResp, 'StringOf', @IPSetForwardedIPConfigFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.IPSetReferenceStatement.IPSetForwardedIPConfig.FallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @IPSetForwardedIPConfigHeaderName OUT, 'RuleGroup.Rules[i].Statement.IPSetReferenceStatement.IPSetForwardedIPConfig.HeaderName'
        EXEC sp_OAMethod @jResp, 'StringOf', @Position OUT, 'RuleGroup.Rules[i].Statement.IPSetReferenceStatement.IPSetForwardedIPConfig.Position'
        EXEC sp_OAMethod @jResp, 'StringOf', @Key OUT, 'RuleGroup.Rules[i].Statement.LabelMatchStatement.Key'
        EXEC sp_OAMethod @jResp, 'StringOf', @Scope OUT, 'RuleGroup.Rules[i].Statement.LabelMatchStatement.Scope'
        EXEC sp_OAMethod @jResp, 'StringOf', @ManagedRuleGroupStatementName OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @ScopeDownStatement OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ScopeDownStatement'
        EXEC sp_OAMethod @jResp, 'StringOf', @VendorName OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.VendorName'
        EXEC sp_OAMethod @jResp, 'StringOf', @Version OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.Version'
        EXEC sp_OAMethod @jResp, 'StringOf', @Statement OUT, 'RuleGroup.Rules[i].Statement.NotStatement.Statement'
        EXEC sp_OAMethod @jResp, 'StringOf', @AggregateKeyType OUT, 'RuleGroup.Rules[i].Statement.RateBasedStatement.AggregateKeyType'
        EXEC sp_OAMethod @jResp, 'StringOf', @ForwardedIPConfigFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.RateBasedStatement.ForwardedIPConfig.FallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @ForwardedIPConfigHeaderName OUT, 'RuleGroup.Rules[i].Statement.RateBasedStatement.ForwardedIPConfig.HeaderName'
        EXEC sp_OAMethod @jResp, 'IntOf', @Limit OUT, 'RuleGroup.Rules[i].Statement.RateBasedStatement.Limit'
        EXEC sp_OAMethod @jResp, 'StringOf', @RateBasedStatementScopeDownStatement OUT, 'RuleGroup.Rules[i].Statement.RateBasedStatement.ScopeDownStatement'
        EXEC sp_OAMethod @jResp, 'StringOf', @BodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyInvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @RegexString OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.RegexString'
        EXEC sp_OAMethod @jResp, 'StringOf', @RegexPatternSetReferenceStatementARN OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.ARN'
        EXEC sp_OAMethod @jResp, 'StringOf', @BodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyInvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @RuleGroupReferenceStatementARN OUT, 'RuleGroup.Rules[i].Statement.RuleGroupReferenceStatement.ARN'
        EXEC sp_OAMethod @jResp, 'StringOf', @ComparisonOperator OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.ComparisonOperator'
        EXEC sp_OAMethod @jResp, 'StringOf', @BodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesMatchScope OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyInvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'IntOf', @Size OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.Size'
        EXEC sp_OAMethod @jResp, 'StringOf', @BodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesMatchScope OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyInvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @BodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Body.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesMatchScope OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @CookiesOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersMatchScope OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @HeadersOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyInvalidFallbackBehavior OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.JsonBody.InvalidFallbackBehavior'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyMatchScope OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.JsonBody.MatchScope'
        EXEC sp_OAMethod @jResp, 'StringOf', @JsonBodyOversizeHandling OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.JsonBody.OversizeHandling'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleHeaderName OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.SingleHeader.Name'
        EXEC sp_OAMethod @jResp, 'StringOf', @SingleQueryArgumentName OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.SingleQueryArgument.Name'
        EXEC sp_OAMethod @jResp, 'IntOf', @VisibilityConfigCloudWatchMetricsEnabled OUT, 'RuleGroup.Rules[i].VisibilityConfig.CloudWatchMetricsEnabled'
        EXEC sp_OAMethod @jResp, 'StringOf', @VisibilityConfigMetricName OUT, 'RuleGroup.Rules[i].VisibilityConfig.MetricName'
        EXEC sp_OAMethod @jResp, 'IntOf', @VisibilityConfigSampledRequestsEnabled OUT, 'RuleGroup.Rules[i].VisibilityConfig.SampledRequestsEnabled'
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Action.Allow.CustomRequestHandling.InsertHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Action.Allow.CustomRequestHandling.InsertHeaders[j].Name'
            EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'RuleGroup.Rules[i].Action.Allow.CustomRequestHandling.InsertHeaders[j].Value'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Action.Block.CustomResponse.ResponseHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Action.Block.CustomResponse.ResponseHeaders[j].Name'
            EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'RuleGroup.Rules[i].Action.Block.CustomResponse.ResponseHeaders[j].Value'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Action.Captcha.CustomRequestHandling.InsertHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Action.Captcha.CustomRequestHandling.InsertHeaders[j].Name'
            EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'RuleGroup.Rules[i].Action.Captcha.CustomRequestHandling.InsertHeaders[j].Value'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Action.Count.CustomRequestHandling.InsertHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Action.Count.CustomRequestHandling.InsertHeaders[j].Name'
            EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'RuleGroup.Rules[i].Action.Count.CustomRequestHandling.InsertHeaders[j].Value'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].OverrideAction.Count.CustomRequestHandling.InsertHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].OverrideAction.Count.CustomRequestHandling.InsertHeaders[j].Name'
            EXEC sp_OAMethod @jResp, 'StringOf', @Value OUT, 'RuleGroup.Rules[i].OverrideAction.Count.CustomRequestHandling.InsertHeaders[j].Value'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].RuleLabels'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].RuleLabels[j].Name'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.AndStatement.Statements'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.AndStatement.Statements[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.ByteMatchStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.GeoMatchStatement.CountryCodes'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.GeoMatchStatement.CountryCodes[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ExcludedRules'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ExcludedRules[j].Name'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ManagedRuleGroupConfigs'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @LoginPath OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ManagedRuleGroupConfigs[j].LoginPath'
            EXEC sp_OAMethod @jResp, 'StringOf', @Identifier OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ManagedRuleGroupConfigs[j].PasswordField.Identifier'
            EXEC sp_OAMethod @jResp, 'StringOf', @PayloadType OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ManagedRuleGroupConfigs[j].PayloadType'
            EXEC sp_OAMethod @jResp, 'StringOf', @UsernameFieldIdentifier OUT, 'RuleGroup.Rules[i].Statement.ManagedRuleGroupStatement.ManagedRuleGroupConfigs[j].UsernameField.Identifier'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.OrStatement.Statements'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.OrStatement.Statements[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.RegexMatchStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.RegexPatternSetReferenceStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.RuleGroupReferenceStatement.ExcludedRules'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @Name OUT, 'RuleGroup.Rules[i].Statement.RuleGroupReferenceStatement.ExcludedRules[j].Name'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.SizeConstraintStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.SqliMatchStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.MatchPattern.ExcludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Cookies.MatchPattern.IncludedCookies[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.MatchPattern.ExcludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.Headers.MatchPattern.IncludedHeaders[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'StringOf', @strVal OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.FieldToMatch.JsonBody.MatchPattern.IncludedPaths[j]'
            SELECT @j = @j + 1
          END
        SELECT @j = 0
        EXEC sp_OAMethod @jResp, 'SizeOfArray', @count_j OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.TextTransformations'
        WHILE @j < @count_j
          BEGIN
            EXEC sp_OASetProperty @jResp, 'J', @j
            EXEC sp_OAMethod @jResp, 'IntOf', @Priority OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.TextTransformations[j].Priority'
            EXEC sp_OAMethod @jResp, 'StringOf', @v_Type OUT, 'RuleGroup.Rules[i].Statement.XssMatchStatement.TextTransformations[j].Type'
            SELECT @j = @j + 1
          END
        SELECT @i = @i + 1
      END

    -- A sample JSON response body parsed by the above code:

    -- {
    --   "LockToken": "string",
    --   "RuleGroup": {
    --     "ARN": "string",
    --     "AvailableLabels": [
    --       {
    --         "Name": "string"
    --       }
    --     ],
    --     "Capacity": number,
    --     "ConsumedLabels": [
    --       {
    --         "Name": "string"
    --       }
    --     ],
    --     "CustomResponseBodies": {
    --       "string": {
    --         "Content": "string",
    --         "ContentType": "string"
    --       }
    --     },
    --     "Description": "string",
    --     "Id": "string",
    --     "LabelNamespace": "string",
    --     "Name": "string",
    --     "Rules": [
    --       {
    --         "Action": {
    --           "Allow": {
    --             "CustomRequestHandling": {
    --               "InsertHeaders": [
    --                 {
    --                   "Name": "string",
    --                   "Value": "string"
    --                 }
    --               ]
    --             }
    --           },
    --           "Block": {
    --             "CustomResponse": {
    --               "CustomResponseBodyKey": "string",
    --               "ResponseCode": number,
    --               "ResponseHeaders": [
    --                 {
    --                   "Name": "string",
    --                   "Value": "string"
    --                 }
    --               ]
    --             }
    --           },
    --           "Captcha": {
    --             "CustomRequestHandling": {
    --               "InsertHeaders": [
    --                 {
    --                   "Name": "string",
    --                   "Value": "string"
    --                 }
    --               ]
    --             }
    --           },
    --           "Count": {
    --             "CustomRequestHandling": {
    --               "InsertHeaders": [
    --                 {
    --                   "Name": "string",
    --                   "Value": "string"
    --                 }
    --               ]
    --             }
    --           }
    --         },
    --         "CaptchaConfig": {
    --           "ImmunityTimeProperty": {
    --             "ImmunityTime": number
    --           }
    --         },
    --         "Name": "string",
    --         "OverrideAction": {
    --           "Count": {
    --             "CustomRequestHandling": {
    --               "InsertHeaders": [
    --                 {
    --                   "Name": "string",
    --                   "Value": "string"
    --                 }
    --               ]
    --             }
    --           },
    --           "None": {}
    --         },
    --         "Priority": number,
    --         "RuleLabels": [
    --           {
    --             "Name": "string"
    --           }
    --         ],
    --         "Statement": {
    --           "AndStatement": {
    --             "Statements": [
    --               "Statement"
    --             ]
    --           },
    --           "ByteMatchStatement": {
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "PositionalConstraint": "string",
    --             "SearchString": blob,
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           },
    --           "GeoMatchStatement": {
    --             "CountryCodes": [
    --               "string"
    --             ],
    --             "ForwardedIPConfig": {
    --               "FallbackBehavior": "string",
    --               "HeaderName": "string"
    --             }
    --           },
    --           "IPSetReferenceStatement": {
    --             "ARN": "string",
    --             "IPSetForwardedIPConfig": {
    --               "FallbackBehavior": "string",
    --               "HeaderName": "string",
    --               "Position": "string"
    --             }
    --           },
    --           "LabelMatchStatement": {
    --             "Key": "string",
    --             "Scope": "string"
    --           },
    --           "ManagedRuleGroupStatement": {
    --             "ExcludedRules": [
    --               {
    --                 "Name": "string"
    --               }
    --             ],
    --             "ManagedRuleGroupConfigs": [
    --               {
    --                 "LoginPath": "string",
    --                 "PasswordField": {
    --                   "Identifier": "string"
    --                 },
    --                 "PayloadType": "string",
    --                 "UsernameField": {
    --                   "Identifier": "string"
    --                 }
    --               }
    --             ],
    --             "Name": "string",
    --             "ScopeDownStatement": "Statement",
    --             "VendorName": "string",
    --             "Version": "string"
    --           },
    --           "NotStatement": {
    --             "Statement": "Statement"
    --           },
    --           "OrStatement": {
    --             "Statements": [
    --               "Statement"
    --             ]
    --           },
    --           "RateBasedStatement": {
    --             "AggregateKeyType": "string",
    --             "ForwardedIPConfig": {
    --               "FallbackBehavior": "string",
    --               "HeaderName": "string"
    --             },
    --             "Limit": number,
    --             "ScopeDownStatement": "Statement"
    --           },
    --           "RegexMatchStatement": {
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "RegexString": "string",
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           },
    --           "RegexPatternSetReferenceStatement": {
    --             "ARN": "string",
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           },
    --           "RuleGroupReferenceStatement": {
    --             "ARN": "string",
    --             "ExcludedRules": [
    --               {
    --                 "Name": "string"
    --               }
    --             ]
    --           },
    --           "SizeConstraintStatement": {
    --             "ComparisonOperator": "string",
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "Size": number,
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           },
    --           "SqliMatchStatement": {
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           },
    --           "XssMatchStatement": {
    --             "FieldToMatch": {
    --               "AllQueryArguments": {},
    --               "Body": {
    --                 "OversizeHandling": "string"
    --               },
    --               "Cookies": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedCookies": [
    --                     "string"
    --                   ],
    --                   "IncludedCookies": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Headers": {
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "ExcludedHeaders": [
    --                     "string"
    --                   ],
    --                   "IncludedHeaders": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "JsonBody": {
    --                 "InvalidFallbackBehavior": "string",
    --                 "MatchPattern": {
    --                   "All": {},
    --                   "IncludedPaths": [
    --                     "string"
    --                   ]
    --                 },
    --                 "MatchScope": "string",
    --                 "OversizeHandling": "string"
    --               },
    --               "Method": {},
    --               "QueryString": {},
    --               "SingleHeader": {
    --                 "Name": "string"
    --               },
    --               "SingleQueryArgument": {
    --                 "Name": "string"
    --               },
    --               "UriPath": {}
    --             },
    --             "TextTransformations": [
    --               {
    --                 "Priority": number,
    --                 "Type": "string"
    --               }
    --             ]
    --           }
    --         },
    --         "VisibilityConfig": {
    --           "CloudWatchMetricsEnabled": boolean,
    --           "MetricName": "string",
    --           "SampledRequestsEnabled": boolean
    --         }
    --       }
    --     ],
    --     "VisibilityConfig": {
    --       "CloudWatchMetricsEnabled": boolean,
    --       "MetricName": "string",
    --       "SampledRequestsEnabled": boolean
    --     }
    --   }
    -- }

    EXEC @hr = sp_OADestroy @rest
    EXEC @hr = sp_OADestroy @authAws
    EXEC @hr = sp_OADestroy @json
    EXEC @hr = sp_OADestroy @sbRequestBody
    EXEC @hr = sp_OADestroy @sbResponseBody
    EXEC @hr = sp_OADestroy @jResp


END
GO