class Io::Flow::V0::Models::WebhookSettings
Sets organization level settings to determine things like how many retries on delivery, how long we wait, etc. By default, we will attempt delivery up to 6 times, using exponential backoff with a see of 1 minute (60k ms) - which means that we will retry over the course of approximately an hour before giving up.
Attributes
retry_max_attempts[R]
retry_sleep_ms[R]
secret[R]
sleep_ms[R]
Public Class Methods
new(incoming={})
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 72969 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) @secret = (x = opts.delete(:secret); x.nil? ? nil : HttpClient::Preconditions.assert_class('secret', x, String)) @retry_max_attempts = HttpClient::Preconditions.assert_class('retry_max_attempts', (x = opts.delete(:retry_max_attempts); x.nil? ? 6 : x), Integer) @retry_sleep_ms = HttpClient::Preconditions.assert_class('retry_sleep_ms', (x = opts.delete(:retry_sleep_ms); x.nil? ? 60000 : x), Integer) @sleep_ms = HttpClient::Preconditions.assert_class('sleep_ms', (x = opts.delete(:sleep_ms); x.nil? ? 0 : x), Integer) end
Public Instance Methods
copy(incoming={})
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 72981 def copy(incoming={}) WebhookSettings.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end
to_hash()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 72985 def to_hash { :secret => secret, :retry_max_attempts => retry_max_attempts, :retry_sleep_ms => retry_sleep_ms, :sleep_ms => sleep_ms } end
to_json()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 72977 def to_json JSON.dump(to_hash) end