crawlberg 1.7.1 → 1.10.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
  # This file is auto-generated by alef — DO NOT EDIT.
2
- # alef:hash:925532ba2f606ce36a0d3444d5c96407ca56a1c55bcd256372a1ea2a383d11e5
2
+ # alef:hash:d323ed0aab9764791b48678b68c8fedcf8e7b3e1dbe50ec190a9023e68acc3bb
3
3
  # To regenerate: alef generate
4
4
  # To verify freshness: alef verify
5
5
  # frozen_string_literal: true
@@ -68,12 +68,10 @@ module Crawlberg
68
68
 
69
69
  # Username sent in the `Authorization: Basic` header.
70
70
  sig { returns(String) }
71
- # rubocop:disable Lint/UselessMethodDefinition
72
- def username = super
71
+ def username = Data.instance_method(:to_h).bind_call(self).fetch(:username)
73
72
  # Password sent in the `Authorization: Basic` header.
74
73
  sig { returns(String) }
75
- # rubocop:disable Lint/UselessMethodDefinition
76
- def password = super
74
+ def password = Data.instance_method(:to_h).bind_call(self).fetch(:password)
77
75
  sig { returns(T::Boolean) }
78
76
  def basic? = true
79
77
  sig { returns(T::Boolean) }
@@ -94,8 +92,7 @@ module Crawlberg
94
92
 
95
93
  # Token sent in the `Authorization: Bearer` header.
96
94
  sig { returns(String) }
97
- # rubocop:disable Lint/UselessMethodDefinition
98
- def token = super
95
+ def token = Data.instance_method(:to_h).bind_call(self).fetch(:token)
99
96
  sig { returns(T::Boolean) }
100
97
  def basic? = false
101
98
  sig { returns(T::Boolean) }
@@ -116,12 +113,10 @@ module Crawlberg
116
113
 
117
114
  # HTTP header name to set on each request.
118
115
  sig { returns(String) }
119
- # rubocop:disable Lint/UselessMethodDefinition
120
- def name = super
116
+ def name = Data.instance_method(:to_h).bind_call(self).fetch(:name)
121
117
  # HTTP header value to send.
122
118
  sig { returns(String) }
123
- # rubocop:disable Lint/UselessMethodDefinition
124
- def value = super
119
+ def value = Data.instance_method(:to_h).bind_call(self).fetch(:value)
125
120
  sig { returns(T::Boolean) }
126
121
  def basic? = false
127
122
  sig { returns(T::Boolean) }
@@ -175,8 +170,7 @@ module Crawlberg
175
170
 
176
171
  # The crawled page result.
177
172
  sig { returns(CrawlPageResult) }
178
- # rubocop:disable Lint/UselessMethodDefinition
179
- def result = super
173
+ def result = Data.instance_method(:to_h).bind_call(self).fetch(:result)
180
174
  sig { returns(T::Boolean) }
181
175
  def page? = true
182
176
  sig { returns(T::Boolean) }
@@ -197,12 +191,10 @@ module Crawlberg
197
191
 
198
192
  # The URL that failed.
199
193
  sig { returns(String) }
200
- # rubocop:disable Lint/UselessMethodDefinition
201
- def url = super
194
+ def url = Data.instance_method(:to_h).bind_call(self).fetch(:url)
202
195
  # The error message.
203
196
  sig { returns(String) }
204
- # rubocop:disable Lint/UselessMethodDefinition
205
- def error = super
197
+ def error = Data.instance_method(:to_h).bind_call(self).fetch(:error)
206
198
  sig { returns(T::Boolean) }
207
199
  def page? = false
208
200
  sig { returns(T::Boolean) }
@@ -223,8 +215,7 @@ module Crawlberg
223
215
 
224
216
  # Total number of pages crawled.
225
217
  sig { returns(Integer) }
226
- # rubocop:disable Lint/UselessMethodDefinition
227
- def pages_crawled = super
218
+ def pages_crawled = Data.instance_method(:to_h).bind_call(self).fetch(:pages_crawled)
228
219
  sig { returns(T::Boolean) }
229
220
  def page? = false
230
221
  sig { returns(T::Boolean) }
@@ -287,8 +278,7 @@ module Crawlberg
287
278
 
288
279
  # The hostname to match.
289
280
  sig { returns(String) }
290
- # rubocop:disable Lint/UselessMethodDefinition
291
- def value = super
281
+ def value = Data.instance_method(:to_h).bind_call(self).fetch(:value)
292
282
  sig { returns(T::Boolean) }
293
283
  def exact? = true
294
284
  sig { returns(T::Boolean) }
@@ -309,8 +299,7 @@ module Crawlberg
309
299
 
310
300
  # The dot-prefixed suffix to match. A leading dot is optional.
311
301
  sig { returns(String) }
312
- # rubocop:disable Lint/UselessMethodDefinition
313
- def value = super
302
+ def value = Data.instance_method(:to_h).bind_call(self).fetch(:value)
314
303
  sig { returns(T::Boolean) }
315
304
  def exact? = false
316
305
  sig { returns(T::Boolean) }
@@ -332,8 +321,7 @@ module Crawlberg
332
321
  # The CIDR block. Validated when built through [`HostMatcher::cidr`] or
333
322
  # deserialization.
334
323
  sig { returns(String) }
335
- # rubocop:disable Lint/UselessMethodDefinition
336
- def value = super
324
+ def value = Data.instance_method(:to_h).bind_call(self).fetch(:value)
337
325
  sig { returns(T::Boolean) }
338
326
  def exact? = false
339
327
  sig { returns(T::Boolean) }
@@ -395,8 +383,7 @@ module Crawlberg
395
383
 
396
384
  # CSS selector for the element to click.
397
385
  sig { returns(String) }
398
- # rubocop:disable Lint/UselessMethodDefinition
399
- def selector = super
386
+ def selector = Data.instance_method(:to_h).bind_call(self).fetch(:selector)
400
387
  sig { returns(T::Boolean) }
401
388
  def click? = true
402
389
  sig { returns(T::Boolean) }
@@ -427,12 +414,10 @@ module Crawlberg
427
414
 
428
415
  # CSS selector for the input element.
429
416
  sig { returns(String) }
430
- # rubocop:disable Lint/UselessMethodDefinition
431
- def selector = super
417
+ def selector = Data.instance_method(:to_h).bind_call(self).fetch(:selector)
432
418
  # Text to type into the element.
433
419
  sig { returns(String) }
434
- # rubocop:disable Lint/UselessMethodDefinition
435
- def text = super
420
+ def text = Data.instance_method(:to_h).bind_call(self).fetch(:text)
436
421
  sig { returns(T::Boolean) }
437
422
  def click? = false
438
423
  sig { returns(T::Boolean) }
@@ -463,8 +448,7 @@ module Crawlberg
463
448
 
464
449
  # Key name to press.
465
450
  sig { returns(String) }
466
- # rubocop:disable Lint/UselessMethodDefinition
467
- def key = super
451
+ def key = Data.instance_method(:to_h).bind_call(self).fetch(:key)
468
452
  sig { returns(T::Boolean) }
469
453
  def click? = false
470
454
  sig { returns(T::Boolean) }
@@ -495,16 +479,13 @@ module Crawlberg
495
479
 
496
480
  # Direction to scroll.
497
481
  sig { returns(ScrollDirection) }
498
- # rubocop:disable Lint/UselessMethodDefinition
499
- def direction = super
482
+ def direction = Data.instance_method(:to_h).bind_call(self).fetch(:direction)
500
483
  # Optional CSS selector for a scrollable element. Scrolls the page if absent.
501
484
  sig { returns(T.nilable(String)) }
502
- # rubocop:disable Lint/UselessMethodDefinition
503
- def selector = super
485
+ def selector = Data.instance_method(:to_h).bind_call(self).fetch(:selector)
504
486
  # Optional pixel amount to scroll. Uses a default if absent.
505
487
  sig { returns(T.nilable(Integer)) }
506
- # rubocop:disable Lint/UselessMethodDefinition
507
- def amount = super
488
+ def amount = Data.instance_method(:to_h).bind_call(self).fetch(:amount)
508
489
  sig { returns(T::Boolean) }
509
490
  def click? = false
510
491
  sig { returns(T::Boolean) }
@@ -539,12 +520,10 @@ module Crawlberg
539
520
 
540
521
  # Milliseconds to wait. Ignored if `selector` is provided.
541
522
  sig { returns(T.nilable(Integer)) }
542
- # rubocop:disable Lint/UselessMethodDefinition
543
- def milliseconds = super
523
+ def milliseconds = Data.instance_method(:to_h).bind_call(self).fetch(:milliseconds)
544
524
  # CSS selector to wait for.
545
525
  sig { returns(T.nilable(String)) }
546
- # rubocop:disable Lint/UselessMethodDefinition
547
- def selector = super
526
+ def selector = Data.instance_method(:to_h).bind_call(self).fetch(:selector)
548
527
  sig { returns(T::Boolean) }
549
528
  def click? = false
550
529
  sig { returns(T::Boolean) }
@@ -579,8 +558,7 @@ module Crawlberg
579
558
  # `full_page` (snake_case) alias so language bindings and fixtures can
580
559
  # use either convention without error.
581
560
  sig { returns(T.nilable(T::Boolean)) }
582
- # rubocop:disable Lint/UselessMethodDefinition
583
- def full_page = super
561
+ def full_page = Data.instance_method(:to_h).bind_call(self).fetch(:full_page)
584
562
  sig { returns(T::Boolean) }
585
563
  def click? = false
586
564
  sig { returns(T::Boolean) }
@@ -616,8 +594,7 @@ module Crawlberg
616
594
 
617
595
  # JavaScript source code to execute. Max 1 MB.
618
596
  sig { returns(String) }
619
- # rubocop:disable Lint/UselessMethodDefinition
620
- def script = super
597
+ def script = Data.instance_method(:to_h).bind_call(self).fetch(:script)
621
598
  sig { returns(T::Boolean) }
622
599
  def click? = false
623
600
  sig { returns(T::Boolean) }
@@ -1,10 +1,10 @@
1
1
  # This file is auto-generated by alef — DO NOT EDIT.
2
- # alef:hash:f45711d921997740dbd2259778d7ff9e5d0d75d2ce27ef835c9ce8916b1dc19d
2
+ # alef:hash:233df82206c190592be07a69f614e55087625819abb77c2acf04112c5d8380ee
3
3
  # To regenerate: alef generate
4
4
  # To verify freshness: alef verify
5
5
  # frozen_string_literal: true
6
6
 
7
7
  module Crawlberg
8
8
  ## The version string for this package.
9
- VERSION = "1.7.1"
9
+ VERSION = "1.10.1"
10
10
  end
data/sig/types.rbs CHANGED
@@ -1,5 +1,5 @@
1
1
  # This file is auto-generated by alef — DO NOT EDIT.
2
- # alef:hash:1a2c1bf0fb6b53091ffe21fcecbee4a7e5f8214d544addbfe5c39f34e5aa7590
2
+ # alef:hash:3beedc8e4020e7af03194ac67ead1f260c8777df76ad65e2d9682e60fc03dd3b
3
3
  # To regenerate: alef generate
4
4
  # To verify freshness: alef verify
5
5
 
@@ -70,11 +70,13 @@ def initialize: (?results: Array[BatchScrapeResult], ?total_count: Integer, ?com
70
70
  end
71
71
 
72
72
  class BrowserConfig
73
- attr_reader mode: BrowserMode
74
- attr_reader backend: BrowserBackend
73
+ attr_reader mode: enum_BrowserMode
74
+ attr_reader backend: enum_BrowserBackend
75
75
  attr_reader endpoint: String?
76
76
  attr_reader timeout: Integer
77
- attr_reader wait: BrowserWait
77
+ attr_reader overall_timeout: Integer
78
+ attr_reader shutdown_timeout: Integer
79
+ attr_reader wait: enum_BrowserWait
78
80
  attr_reader wait_selector: String?
79
81
  attr_reader extra_wait: Integer?
80
82
  attr_reader proxy: ProxyConfig?
@@ -83,8 +85,10 @@ def initialize: (?results: Array[BatchScrapeResult], ?total_count: Integer, ?com
83
85
  attr_reader robots_user_agent: String?
84
86
  attr_reader capture_network_events: bool
85
87
  attr_reader session_affinity: bool
88
+ attr_reader chrome_path: String?
89
+ attr_reader chrome_args: Array[String]
86
90
 
87
- def initialize: (?mode: BrowserMode, ?backend: BrowserBackend, ?endpoint: String, ?timeout: Integer, ?wait: BrowserWait, ?wait_selector: String, ?extra_wait: Integer, ?proxy: ProxyConfig, ?block_url_patterns: Array[String], ?eval_script: String, ?robots_user_agent: String, ?capture_network_events: bool, ?session_affinity: bool) -> void
91
+ def initialize: (?mode: enum_BrowserMode, ?backend: enum_BrowserBackend, ?endpoint: String, ?timeout: Integer, ?overall_timeout: Integer, ?shutdown_timeout: Integer, ?wait: enum_BrowserWait, ?wait_selector: String, ?extra_wait: Integer, ?proxy: ProxyConfig, ?block_url_patterns: Array[String], ?eval_script: String, ?robots_user_agent: String, ?capture_network_events: bool, ?session_affinity: bool, ?chrome_path: String, ?chrome_args: Array[String]) -> void
88
92
  end
89
93
 
90
94
  class BrowserExtras
@@ -123,8 +127,9 @@ def initialize: (?content: String, ?references: Array[CitationReference]) -> voi
123
127
  attr_reader wrap: bool
124
128
  attr_reader wrap_width: Integer
125
129
  attr_reader include_document_structure: bool
130
+ attr_reader extract_metadata: bool
126
131
 
127
- def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_navigation: bool, ?remove_forms: bool, ?strip_tags: Array[String], ?preserve_tags: Array[String], ?exclude_selectors: Array[String], ?skip_images: bool, ?max_depth: Integer, ?wrap: bool, ?wrap_width: Integer, ?include_document_structure: bool) -> void
132
+ def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_navigation: bool, ?remove_forms: bool, ?strip_tags: Array[String], ?preserve_tags: Array[String], ?exclude_selectors: Array[String], ?skip_images: bool, ?max_depth: Integer, ?wrap: bool, ?wrap_width: Integer, ?include_document_structure: bool, ?extract_metadata: bool) -> void
128
133
  end
129
134
 
130
135
  class CookieInfo
@@ -141,8 +146,8 @@ def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_
141
146
  attr_reader max_pages: Integer?
142
147
  attr_reader max_links_per_page: Integer?
143
148
  attr_reader max_concurrent: Integer?
144
- attr_reader crawl_strategy: CrawlStrategyKind
145
- attr_reader content_filter: ContentFilterKind?
149
+ attr_reader crawl_strategy: enum_CrawlStrategyKind
150
+ attr_reader content_filter: enum_ContentFilterKind?
146
151
  attr_reader bm25_query: String?
147
152
  attr_reader bm25_threshold: Float?
148
153
  attr_reader respect_robots_txt: bool
@@ -152,12 +157,20 @@ def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_
152
157
  attr_reader allow_subdomains: bool
153
158
  attr_reader include_paths: Array[String]
154
159
  attr_reader exclude_paths: Array[String]
160
+ attr_reader path_patterns_match_query: bool
161
+ attr_reader path_patterns_match_url: bool
162
+ attr_reader dedup_include_query: bool
163
+ attr_reader strip_tracking_params: bool
164
+ attr_reader tracking_params: Array[String]
155
165
  attr_reader custom_headers: Hash[String, String]
156
166
  attr_reader request_timeout: Integer
157
167
  attr_reader rate_limit_ms: Integer?
158
168
  attr_reader max_redirects: Integer
159
169
  attr_reader retry_count: Integer
160
170
  attr_reader retry_codes: Array[Integer]
171
+ attr_reader retry_initial_delay_ms: Integer
172
+ attr_reader retry_max_delay_ms: Integer
173
+ attr_reader rate_limit_jitter_ratio: Float
161
174
  attr_reader cookies_enabled: bool
162
175
  attr_reader auth: AuthConfig?
163
176
  attr_reader max_body_size: Integer?
@@ -166,7 +179,7 @@ def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_
166
179
  attr_reader map_limit: Integer?
167
180
  attr_reader map_search: String?
168
181
  attr_reader download_assets: bool
169
- attr_reader asset_types: Array[AssetCategory]
182
+ attr_reader asset_types: Array[enum_AssetCategory]
170
183
  attr_reader max_asset_size: Integer?
171
184
  attr_reader browser: BrowserConfig
172
185
  attr_reader proxy: ProxyConfig?
@@ -178,14 +191,14 @@ def initialize: (?output_format: String, ?preprocessing_preset: String, ?remove_
178
191
  attr_reader document_max_size: Integer?
179
192
  attr_reader document_mime_types: Array[String]
180
193
  attr_reader document_output_dir: String?
181
- attr_reader document_content_encoding: DocumentContentEncoding?
194
+ attr_reader document_content_encoding: enum_DocumentContentEncoding?
182
195
  attr_reader warc_output: String?
183
196
  attr_reader browser_profile: String?
184
197
  attr_reader save_browser_profile: bool
185
198
  attr_reader ssrf: SsrfPolicy
186
199
  attr_reader ssrf_deny_private_explicit: bool?
187
200
 
188
- def initialize: (?max_depth: Integer, ?max_pages: Integer, ?max_links_per_page: Integer, ?max_concurrent: Integer, ?crawl_strategy: CrawlStrategyKind, ?content_filter: ContentFilterKind, ?bm25_query: String, ?bm25_threshold: Float, ?respect_robots_txt: bool, ?soft_http_errors: bool, ?user_agent: String, ?stay_on_domain: bool, ?allow_subdomains: bool, ?include_paths: Array[String], ?exclude_paths: Array[String], ?custom_headers: Hash[String, String], ?request_timeout: Integer, ?rate_limit_ms: Integer, ?max_redirects: Integer, ?retry_count: Integer, ?retry_codes: Array[Integer], ?cookies_enabled: bool, ?auth: AuthConfig, ?max_body_size: Integer, ?remove_tags: Array[String], ?content: ContentConfig, ?map_limit: Integer, ?map_search: String, ?download_assets: bool, ?asset_types: Array[AssetCategory], ?max_asset_size: Integer, ?browser: BrowserConfig, ?proxy: ProxyConfig, ?user_agents: Array[String], ?capture_screenshot: bool, ?follow_document_urls: bool, ?document_url_depth: Integer, ?download_documents: bool, ?document_max_size: Integer, ?document_mime_types: Array[String], ?document_output_dir: String, ?document_content_encoding: DocumentContentEncoding, ?warc_output: String, ?browser_profile: String, ?save_browser_profile: bool, ?ssrf: SsrfPolicy, ?ssrf_deny_private_explicit: bool) -> void
201
+ def initialize: (?max_depth: Integer, ?max_pages: Integer, ?max_links_per_page: Integer, ?max_concurrent: Integer, ?crawl_strategy: enum_CrawlStrategyKind, ?content_filter: enum_ContentFilterKind, ?bm25_query: String, ?bm25_threshold: Float, ?respect_robots_txt: bool, ?soft_http_errors: bool, ?user_agent: String, ?stay_on_domain: bool, ?allow_subdomains: bool, ?include_paths: Array[String], ?exclude_paths: Array[String], ?path_patterns_match_query: bool, ?path_patterns_match_url: bool, ?dedup_include_query: bool, ?strip_tracking_params: bool, ?tracking_params: Array[String], ?custom_headers: Hash[String, String], ?request_timeout: Integer, ?rate_limit_ms: Integer, ?max_redirects: Integer, ?retry_count: Integer, ?retry_codes: Array[Integer], ?retry_initial_delay_ms: Integer, ?retry_max_delay_ms: Integer, ?rate_limit_jitter_ratio: Float, ?cookies_enabled: bool, ?auth: AuthConfig, ?max_body_size: Integer, ?remove_tags: Array[String], ?content: ContentConfig, ?map_limit: Integer, ?map_search: String, ?download_assets: bool, ?asset_types: Array[enum_AssetCategory], ?max_asset_size: Integer, ?browser: BrowserConfig, ?proxy: ProxyConfig, ?user_agents: Array[String], ?capture_screenshot: bool, ?follow_document_urls: bool, ?document_url_depth: Integer, ?download_documents: bool, ?document_max_size: Integer, ?document_mime_types: Array[String], ?document_output_dir: String, ?document_content_encoding: enum_DocumentContentEncoding, ?warc_output: String, ?browser_profile: String, ?save_browser_profile: bool, ?ssrf: SsrfPolicy, ?ssrf_deny_private_explicit: bool) -> void
189
202
  def validate: () -> void
190
203
  end
191
204
 
@@ -216,8 +229,13 @@ def batch_crawl_stream: (BatchCrawlStreamRequest req) -> Enumerator[CrawlEvent]
216
229
  attr_reader extraction_meta: ExtractionMeta?
217
230
  attr_reader downloaded_document: DownloadedDocument?
218
231
  attr_reader browser_used: bool
232
+ attr_reader final_url: String
233
+ attr_reader redirect_count: Integer
234
+ attr_reader noindex_detected: bool
235
+ attr_reader nofollow_detected: bool
236
+ attr_reader ssrf_refused_urls: Array[String]
219
237
 
220
- def initialize: (?url: String, ?normalized_url: String, ?status_code: Integer, ?content_type: String, ?html: String, ?body_size: Integer, ?metadata: PageMetadata, ?links: Array[LinkInfo], ?images: Array[ImageInfo], ?feeds: Array[FeedInfo], ?json_ld: Array[JsonLdEntry], ?depth: Integer, ?stayed_on_domain: bool, ?was_skipped: bool, ?is_pdf: bool, ?detected_charset: String, ?markdown: MarkdownResult, ?extracted_data: String, ?extraction_meta: ExtractionMeta, ?downloaded_document: DownloadedDocument, ?browser_used: bool) -> void
238
+ def initialize: (?url: String, ?normalized_url: String, ?status_code: Integer, ?content_type: String, ?html: String, ?body_size: Integer, ?metadata: PageMetadata, ?links: Array[LinkInfo], ?images: Array[ImageInfo], ?feeds: Array[FeedInfo], ?json_ld: Array[JsonLdEntry], ?depth: Integer, ?stayed_on_domain: bool, ?was_skipped: bool, ?is_pdf: bool, ?detected_charset: String, ?markdown: MarkdownResult, ?extracted_data: String, ?extraction_meta: ExtractionMeta, ?downloaded_document: DownloadedDocument, ?browser_used: bool, ?final_url: String, ?redirect_count: Integer, ?noindex_detected: bool, ?nofollow_detected: bool, ?ssrf_refused_urls: Array[String]) -> void
221
239
  end
222
240
 
223
241
  class CrawlResult
@@ -245,10 +263,10 @@ def initialize: (?pages: Array[CrawlPageResult], ?final_url: String, ?redirect_c
245
263
  attr_reader content_hash: String
246
264
  attr_reader mime_type: String?
247
265
  attr_reader size: Integer
248
- attr_reader asset_category: AssetCategory
266
+ attr_reader asset_category: enum_AssetCategory
249
267
  attr_reader html_tag: String?
250
268
 
251
- def initialize: (?url: String, ?content_hash: String, ?mime_type: String, ?size: Integer, ?asset_category: AssetCategory, ?html_tag: String) -> void
269
+ def initialize: (?url: String, ?content_hash: String, ?mime_type: String, ?size: Integer, ?asset_category: enum_AssetCategory, ?html_tag: String) -> void
252
270
  end
253
271
 
254
272
  class DownloadedDocument
@@ -287,9 +305,9 @@ def initialize: (?url: String, ?mime_type: String, ?size: Integer, ?filename: St
287
305
  class FeedInfo
288
306
  attr_reader url: String
289
307
  attr_reader title: String?
290
- attr_reader feed_type: FeedType
308
+ attr_reader feed_type: enum_FeedType
291
309
 
292
- def initialize: (?url: String, ?title: String, ?feed_type: FeedType) -> void
310
+ def initialize: (?url: String, ?title: String, ?feed_type: enum_FeedType) -> void
293
311
  end
294
312
 
295
313
  class HeadingInfo
@@ -311,9 +329,9 @@ def initialize: (?url: String, ?mime_type: String, ?size: Integer, ?filename: St
311
329
  attr_reader alt: String?
312
330
  attr_reader width: Integer?
313
331
  attr_reader height: Integer?
314
- attr_reader source: ImageSource
332
+ attr_reader source: enum_ImageSource
315
333
 
316
- def initialize: (?url: String, ?alt: String, ?width: Integer, ?height: Integer, ?source: ImageSource) -> void
334
+ def initialize: (?url: String, ?alt: String, ?width: Integer, ?height: Integer, ?source: enum_ImageSource) -> void
317
335
  end
318
336
 
319
337
  class InteractionResult
@@ -321,8 +339,9 @@ def initialize: (?url: String, ?mime_type: String, ?size: Integer, ?filename: St
321
339
  attr_reader final_html: String
322
340
  attr_reader final_url: String
323
341
  attr_reader screenshot_base64: String?
342
+ attr_reader ssrf_refused_urls: Array[String]
324
343
 
325
- def initialize: (?action_results: Array[ActionResult], ?final_html: String, ?final_url: String, ?screenshot_base64: String) -> void
344
+ def initialize: (?action_results: Array[ActionResult], ?final_html: String, ?final_url: String, ?screenshot_base64: String, ?ssrf_refused_urls: Array[String]) -> void
326
345
  end
327
346
 
328
347
  class JsonLdEntry
@@ -336,11 +355,11 @@ def initialize: (?action_results: Array[ActionResult], ?final_html: String, ?fin
336
355
  class LinkInfo
337
356
  attr_reader url: String
338
357
  attr_reader text: String
339
- attr_reader link_type: LinkType
358
+ attr_reader link_type: enum_LinkType
340
359
  attr_reader rel: String?
341
360
  attr_reader nofollow: bool
342
361
 
343
- def initialize: (?url: String, ?text: String, ?link_type: LinkType, ?rel: String, ?nofollow: bool) -> void
362
+ def initialize: (?url: String, ?text: String, ?link_type: enum_LinkType, ?rel: String, ?nofollow: bool) -> void
344
363
  end
345
364
 
346
365
  class MapResult
@@ -458,8 +477,9 @@ def initialize: (?title: String, ?description: String, ?canonical_url: String, ?
458
477
  attr_reader screenshot_base64: String?
459
478
  attr_reader downloaded_document: DownloadedDocument?
460
479
  attr_reader browser: BrowserExtras?
480
+ attr_reader ssrf_refused_urls: Array[String]
461
481
 
462
- def initialize: (?status_code: Integer, ?final_url: String, ?content_type: String, ?html: String, ?body_size: Integer, ?metadata: PageMetadata, ?links: Array[LinkInfo], ?images: Array[ImageInfo], ?feeds: Array[FeedInfo], ?json_ld: Array[JsonLdEntry], ?is_allowed: bool, ?crawl_delay: Integer, ?noindex_detected: bool, ?nofollow_detected: bool, ?x_robots_tag: String, ?is_pdf: bool, ?was_skipped: bool, ?detected_charset: String, ?auth_header_sent: bool, ?response_meta: ResponseMeta, ?assets: Array[DownloadedAsset], ?js_render_hint: bool, ?browser_used: bool, ?markdown: MarkdownResult, ?extracted_data: String, ?extraction_meta: ExtractionMeta, ?screenshot_base64: String, ?downloaded_document: DownloadedDocument, ?browser: BrowserExtras) -> void
482
+ def initialize: (?status_code: Integer, ?final_url: String, ?content_type: String, ?html: String, ?body_size: Integer, ?metadata: PageMetadata, ?links: Array[LinkInfo], ?images: Array[ImageInfo], ?feeds: Array[FeedInfo], ?json_ld: Array[JsonLdEntry], ?is_allowed: bool, ?crawl_delay: Integer, ?noindex_detected: bool, ?nofollow_detected: bool, ?x_robots_tag: String, ?is_pdf: bool, ?was_skipped: bool, ?detected_charset: String, ?auth_header_sent: bool, ?response_meta: ResponseMeta, ?assets: Array[DownloadedAsset], ?js_render_hint: bool, ?browser_used: bool, ?markdown: MarkdownResult, ?extracted_data: String, ?extraction_meta: ExtractionMeta, ?screenshot_base64: String, ?downloaded_document: DownloadedDocument, ?browser: BrowserExtras, ?ssrf_refused_urls: Array[String]) -> void
463
483
  end
464
484
 
465
485
  class SitemapUrl
@@ -474,67 +494,46 @@ def initialize: (?status_code: Integer, ?final_url: String, ?content_type: Strin
474
494
  class SsrfPolicy
475
495
  attr_reader deny_private: bool
476
496
  attr_reader allowlist: Array[HostMatcher]
497
+ attr_reader denylist: Array[HostMatcher]
477
498
  attr_reader max_redirects: Integer
478
499
  attr_reader scheme_allowlist: Array[String]
479
500
 
480
- def initialize: (?deny_private: bool, ?allowlist: Array[HostMatcher], ?max_redirects: Integer, ?scheme_allowlist: Array[String]) -> void
501
+ def initialize: (?deny_private: bool, ?allowlist: Array[HostMatcher], ?denylist: Array[HostMatcher], ?max_redirects: Integer, ?scheme_allowlist: Array[String]) -> void
481
502
  end
482
503
 
483
- class AssetCategory
484
- type value = :document | :image | :audio | :video | :font | :stylesheet | :script | :archive | :data | :other
485
- end
504
+ type enum_AssetCategory = :document | :image | :audio | :video | :font | :stylesheet | :script | :archive | :data | :other
486
505
 
487
506
  class AuthConfig
488
507
  end
489
508
 
490
- class BrowserBackend
491
- type value = :chromiumoxide | :native
492
- end
509
+ type enum_BrowserBackend = :chromiumoxide | :native
493
510
 
494
- class BrowserMode
495
- type value = :auto | :always | :never | :stealth
496
- end
511
+ type enum_BrowserMode = :auto | :always | :never | :stealth
497
512
 
498
- class BrowserWait
499
- type value = :network_idle | :selector | :fixed
500
- end
513
+ type enum_BrowserWait = :network_idle | :selector | :fixed
501
514
 
502
- class ContentFilterKind
503
- type value = :bm25
504
- end
515
+ type enum_ContentFilterKind = :bm25
505
516
 
506
517
  class CrawlEvent
507
518
  end
508
519
 
509
- class CrawlStrategyKind
510
- type value = :bfs | :dfs | :best_first | :adaptive
511
- end
520
+ type enum_CrawlStrategyKind = :bfs | :dfs | :best_first | :adaptive
512
521
 
513
- class DocumentContentEncoding
514
- type value = :base64
515
- end
522
+ type enum_DocumentContentEncoding = :base64
516
523
 
517
- class FeedType
518
- type value = :rss | :atom | :json_feed
519
- end
524
+ type enum_FeedType = :rss | :atom | :json_feed
520
525
 
521
526
  class HostMatcher
522
527
  end
523
528
 
524
- class ImageSource
525
- type value = :img | :picture_source | :"og:image" | :"twitter:image"
526
- end
529
+ type enum_ImageSource = :img | :picture_source | :"og:image" | :"twitter:image"
527
530
 
528
- class LinkType
529
- type value = :internal | :external | :anchor | :document
530
- end
531
+ type enum_LinkType = :internal | :external | :anchor | :document
531
532
 
532
533
  class PageAction
533
534
  end
534
535
 
535
- class ScrollDirection
536
- type value = :up | :down
537
- end
536
+ type enum_ScrollDirection = :up | :down
538
537
 
539
538
  def self.batch_crawl: (CrawlEngineHandle engine, Array[String] urls) -> BatchCrawlResults
540
539
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: crawlberg
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.1
4
+ version: 1.10.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Xberg Team
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-09-16 00:00:00.000000000 Z
11
+ date: 2026-10-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rb_sys