Skip to content

Commit

Permalink
Add raw_post_data var to statuscake
Browse files Browse the repository at this point in the history
  • Loading branch information
matthijswolters-rl committed Oct 4, 2024
1 parent 29669dd commit e4596fb
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
4 changes: 4 additions & 0 deletions api/v1alpha1/endpointmonitor_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,10 @@ type StatusCakeConfig struct {
// String to look for within the response. Considered down if not found
// +optional
FindString string `json:"findString,omitempty"`

// RawPostData can be used to send parameters within the URL. Changes the request from a GET to a POST
// +optional
RawPostData string `json:"rawPostData,omitempty"`
}

// PingdomConfig defines the configuration for Pingdom Monitor Provider
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,10 @@ spec:
port:
description: TCP Port
type: integer
rawPostData:
description: RawPostData can be used to send parameters within
the URL. Changes the request from a GET to a POST
type: string
realBrowser:
description: Enable Real Browser
type: boolean
Expand Down
3 changes: 3 additions & 0 deletions pkg/monitors/statuscake/statuscake-monitor.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,9 @@ func buildUpsertForm(m models.Monitor, cgroup string) url.Values {
if providerConfig != nil {
f.Add("find_string", providerConfig.FindString)
}
if providerConfig != nil && len(providerConfig.RawPostData) > 0 {
f.Add("post_raw", providerConfig.RawPostData)
}
return f
}

Expand Down

0 comments on commit e4596fb

Please sign in to comment.