Skip to content

Commit

Permalink
fix: add Position to RulesetRule
Browse files Browse the repository at this point in the history
  • Loading branch information
vroy committed May 3, 2024
1 parent 1096abb commit 427dfaf
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions rulesets.go
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,7 @@ type RulesetRule struct {
RateLimit *RulesetRuleRateLimit `json:"ratelimit,omitempty"`
ExposedCredentialCheck *RulesetRuleExposedCredentialCheck `json:"exposed_credential_check,omitempty"`
Logging *RulesetRuleLogging `json:"logging,omitempty"`
Position *RulesetRulePosition `json:"position,omitempty"`
}

// RulesetRuleRateLimit contains the structure of a HTTP rate limit Ruleset Rule.
Expand All @@ -674,6 +675,13 @@ type RulesetRuleRateLimit struct {
RequestsToOrigin bool `json:"requests_to_origin,omitempty"`
}

// RulesetRulePositon contains the structure of a Ruleset Rule position.
type RulesetRulePosition struct {
Index int `json:"index,omitempty"`
Before string `json:"before,omitempty"`
After string `json:"after,omitempty"`
}

// RulesetRuleExposedCredentialCheck contains the structure of an exposed
// credential check Ruleset Rule.
type RulesetRuleExposedCredentialCheck struct {
Expand Down

0 comments on commit 427dfaf

Please sign in to comment.