From bd377ae5847a7cc26b91ab41efbb47370ed59b18 Mon Sep 17 00:00:00 2001 From: Shawn Smith Date: Thu, 16 Mar 2023 13:20:37 +0900 Subject: [PATCH] generate site rule docs (#137) --- docs/resources/site_rule.md | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/docs/resources/site_rule.md b/docs/resources/site_rule.md index 6e3dc8b..a249ac4 100644 --- a/docs/resources/site_rule.md +++ b/docs/resources/site_rule.md @@ -113,7 +113,6 @@ resource "sigsci_site_rule" "test-signal-exclusion" { ### Required -- `actions` (Block Set, Min: 1, Max: 2) Actions (see [below for nested schema](#nestedblock--actions)) - `conditions` (Block Set, Min: 1, Max: 10) Conditions (see [below for nested schema](#nestedblock--conditions)) - `enabled` (Boolean) enable the rule - `expiration` (String) Date the rule will automatically be disabled. If rule is always enabled, will return empty string @@ -124,6 +123,7 @@ resource "sigsci_site_rule" "test-signal-exclusion" { ### Optional +- `actions` (Block Set, Max: 2) Actions (see [below for nested schema](#nestedblock--actions)) - `rate_limit` (Map of String) Rate Limit - `requestlogging` (String) Indicates whether to store the logs for requests that match the rule's conditions (sampled) or not store them (none). This field is only available for request rules that have a block or allow action. - `signal` (String) The signal id of the signal being excluded @@ -132,19 +132,6 @@ resource "sigsci_site_rule" "test-signal-exclusion" { - `id` (String) The ID of this resource. - -### Nested Schema for `actions` - -Required: - -- `type` (String) (block, allow, excludeSignal, addSignal) (rateLimit rule valid values: logRequest, blockSignal) - -Optional: - -- `response_code` (Number) HTTP code agent for agent to respond with. range: 400-499, defaults to '406' if not provided -- `signal` (String) signal id to tag - - ### Nested Schema for `conditions` @@ -189,6 +176,21 @@ Optional: - `operator` (String) type: single - (equals, doesNotEqual, contains, doesNotContain, like, notLike, exists, doesNotExist, inList, notInList) - `value` (String) type: single - See request fields (https://docs.signalsciences.net/using-signal-sciences/features/rules/#request-fields) + + + + +### Nested Schema for `actions` + +Required: + +- `type` (String) (block, allow, excludeSignal, addSignal) (rateLimit rule valid values: logRequest, blockSignal) + +Optional: + +- `response_code` (Number) HTTP code agent for agent to respond with. range: 400-499, defaults to '406' if not provided +- `signal` (String) signal id to tag + ### Templated Signals We have curated a list of templates for common rules, the full list of available signals is available below.