Class: XTwitterScraper::Models::Integration
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- XTwitterScraper::Models::Integration
- Defined in:
- lib/x_twitter_scraper/models/integration.rb
Overview
Instance Attribute Summary collapse
-
#config ⇒ Hash{Symbol=>Object}
Integration config — shape varies by type (JSON).
- #created_at ⇒ Time
-
#event_types ⇒ Array<Symbol, XTwitterScraper::Models::EventType>
Array of event types to subscribe to.
-
#filters ⇒ Hash{Symbol=>Object}?
Event filter rules (JSON).
- #id ⇒ String
- #is_active ⇒ Boolean
- #message_template ⇒ String?
- #name ⇒ String
- #scope_all_monitors ⇒ Boolean?
- #silent_push ⇒ Boolean?
- #type ⇒ Symbol, :telegram
Instance Method Summary collapse
-
#initialize(id:, config:, created_at:, event_types:, is_active:, name:, filters: nil, message_template: nil, scope_all_monitors: nil, silent_push: nil, type: :telegram) ⇒ Object
constructor
Third-party integration (e.g. Telegram) subscribed to monitor events.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(id:, config:, created_at:, event_types:, is_active:, name:, filters: nil, message_template: nil, scope_all_monitors: nil, silent_push: nil, type: :telegram) ⇒ Object
Third-party integration (e.g. Telegram) subscribed to monitor events.
|
|
# File 'lib/x_twitter_scraper/models/integration.rb', line 67
|
Instance Attribute Details
#config ⇒ Hash{Symbol=>Object}
Integration config — shape varies by type (JSON)
16 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 16 required :config, XTwitterScraper::Internal::Type::HashOf[XTwitterScraper::Internal::Type::Unknown] |
#created_at ⇒ Time
21 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 21 required :created_at, Time, api_name: :createdAt |
#event_types ⇒ Array<Symbol, XTwitterScraper::Models::EventType>
Array of event types to subscribe to.
27 28 29 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 27 required :event_types, -> { XTwitterScraper::Internal::Type::ArrayOf[enum: XTwitterScraper::EventType] }, api_name: :eventTypes |
#filters ⇒ Hash{Symbol=>Object}?
Event filter rules (JSON)
50 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 50 optional :filters, XTwitterScraper::Internal::Type::HashOf[XTwitterScraper::Internal::Type::Unknown] |
#id ⇒ String
10 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 10 required :id, String |
#is_active ⇒ Boolean
34 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 34 required :is_active, XTwitterScraper::Internal::Type::Boolean, api_name: :isActive |
#message_template ⇒ String?
55 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 55 optional :message_template, String, api_name: :messageTemplate |
#name ⇒ String
39 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 39 required :name, String |
#scope_all_monitors ⇒ Boolean?
60 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 60 optional :scope_all_monitors, XTwitterScraper::Internal::Type::Boolean, api_name: :scopeAllMonitors |
#silent_push ⇒ Boolean?
65 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 65 optional :silent_push, XTwitterScraper::Internal::Type::Boolean, api_name: :silentPush |
#type ⇒ Symbol, :telegram
44 |
# File 'lib/x_twitter_scraper/models/integration.rb', line 44 required :type, const: :telegram |