Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions monitoring/api/v3/uptime-check-client/snippets.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ def create_uptime_check_config(project_name, host_name=None,
config.monitored_resource.labels.update(
{'host': host_name or 'example.com'})
config.http_check.request_method = monitoring_v3.enums.UptimeCheckConfig.HttpCheck.RequestMethod.GET
# Uncomment if you want a POST check
# config.http_check.request_method = monitoring_v3.enums.UptimeCheckConfig.HttpCheck.RequestMethod.POST
# config.http_check.content_type = monitoring_v3.enums.UptimeCheckConfig.HttpCheck.ContentType.URL_ENCODED
# config.http_check.body = 'foo=bar'
config.http_check.path = '/'
config.http_check.port = 80
config.timeout.seconds = 10
Expand Down