Module: ContextDev::Models::MonitorCreateResponse::Target

Extended by:
Internal::Type::Union
Defined in:
lib/context_dev/models/monitor_create_response.rb,
sig/context_dev/models/monitor_create_response.rbs

Overview

Discriminated union describing what the monitor watches.

See Also:

  • ContextDev::Models::MonitorCreateResponse#target

Defined Under Namespace

Classes: Extract, Page, Sitemap

Instance Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, derefed_variants, dump, hash, inspect, to_sorbet_type, variants, variants

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Instance Method Details

#initialize(url:, exclude: nil, include: nil, max_urls: nil, type: :sitemap) ⇒ Object

Watch a sitemap for URL additions and removals. Crawled URLs are normalized (lowercased host, no trailing slash/fragment) and scoped to the monitored site and its subdomains before comparison. A new URL set must be observed on two consecutive runs before a change is reported, suppressing one-run crawl flaps.

Parameters:

  • url (String)

    Sitemap URL to monitor.

  • exclude (Array<String>) (defaults to: nil)

    URL path patterns to exclude.

  • include (Array<String>) (defaults to: nil)

    URL path patterns to include.

  • max_urls (Integer) (defaults to: nil)

    Maximum number of sitemap URLs to track (capped at 10,000).

  • type (Symbol, :sitemap) (defaults to: :sitemap)


# File 'lib/context_dev/models/monitor_create_response.rb', line 311

#self?.variants::Array[ContextDev::Models::MonitorCreateResponse::target]

Returns:

  • (::Array[ContextDev::Models::MonitorCreateResponse::target])


339
# File 'sig/context_dev/models/monitor_create_response.rbs', line 339

def self?.variants: -> ::Array[ContextDev::Models::MonitorCreateResponse::target]