Skip to content
Snippets Groups Projects

Add Get Web hook events API

Compare and Show latest version
1 file
+ 0
1
Compare changes
  • Side-by-side
  • Inline
@@ -27,7 +27,6 @@ class WebHookLog < ApplicationRecord
before_save :set_url_hash, if: -> { interpolated_url.present? }
scope :by_status_code, ->(status_code) { where(response_status: status_code) }
scope :by_date_range, ->(from, to) { where(created_at: from.beginning_of_day..to.end_of_day) }
def self.recent(number_of_days = 2)
raise ArgumentError, '`recent` scope can only provide up to 7 days of log records' if number_of_days > 7
Loading