context.dev 2.16.0 → 2.17.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.
Files changed (168) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +24 -0
  3. data/README.md +1 -1
  4. data/lib/context_dev/models/ai_extract_product_params.rb +53 -8
  5. data/lib/context_dev/models/ai_extract_product_response.rb +10 -1
  6. data/lib/context_dev/models/ai_extract_products_params.rb +116 -16
  7. data/lib/context_dev/models/ai_extract_products_response.rb +11 -1
  8. data/lib/context_dev/models/brand_retrieve_params.rb +355 -60
  9. data/lib/context_dev/models/brand_retrieve_response.rb +71 -62
  10. data/lib/context_dev/models/brand_retrieve_simplified_params.rb +57 -11
  11. data/lib/context_dev/models/brand_retrieve_simplified_response.rb +72 -63
  12. data/lib/context_dev/models/industry_retrieve_naics_params.rb +53 -8
  13. data/lib/context_dev/models/industry_retrieve_naics_response.rb +10 -1
  14. data/lib/context_dev/models/industry_retrieve_sic_params.rb +53 -8
  15. data/lib/context_dev/models/industry_retrieve_sic_response.rb +10 -1
  16. data/lib/context_dev/models/monitor_create_params.rb +27 -3
  17. data/lib/context_dev/models/monitor_create_response.rb +30 -5
  18. data/lib/context_dev/models/monitor_list_response.rb +30 -5
  19. data/lib/context_dev/models/monitor_retrieve_response.rb +30 -5
  20. data/lib/context_dev/models/monitor_update_params.rb +27 -3
  21. data/lib/context_dev/models/monitor_update_response.rb +30 -5
  22. data/lib/context_dev/models/person_enrich_params.rb +53 -8
  23. data/lib/context_dev/models/person_enrich_response.rb +10 -1
  24. data/lib/context_dev/models/utility_prefetch_params.rb +48 -8
  25. data/lib/context_dev/models/web_answers_params.rb +124 -0
  26. data/lib/context_dev/models/web_answers_response.rb +68 -0
  27. data/lib/context_dev/models/web_extract_competitors_params.rb +53 -8
  28. data/lib/context_dev/models/web_extract_competitors_response.rb +10 -1
  29. data/lib/context_dev/models/web_extract_fonts_params.rb +58 -11
  30. data/lib/context_dev/models/web_extract_fonts_response.rb +32 -1
  31. data/lib/context_dev/models/web_extract_params.rb +53 -8
  32. data/lib/context_dev/models/web_extract_response.rb +10 -1
  33. data/lib/context_dev/models/web_extract_styleguide_params.rb +58 -11
  34. data/lib/context_dev/models/web_extract_styleguide_response.rb +32 -1
  35. data/lib/context_dev/models/web_screenshot_params.rb +58 -10
  36. data/lib/context_dev/models/web_screenshot_response.rb +32 -1
  37. data/lib/context_dev/models/web_search_params.rb +112 -16
  38. data/lib/context_dev/models/web_search_response.rb +49 -4
  39. data/lib/context_dev/models/web_web_crawl_md_params.rb +53 -8
  40. data/lib/context_dev/models/web_web_crawl_md_response.rb +11 -1
  41. data/lib/context_dev/models/web_web_scrape_bytes_params.rb +344 -0
  42. data/lib/context_dev/models/web_web_scrape_bytes_response.rb +135 -0
  43. data/lib/context_dev/models/web_web_scrape_html_params.rb +57 -10
  44. data/lib/context_dev/models/web_web_scrape_html_response.rb +32 -1
  45. data/lib/context_dev/models/web_web_scrape_images_params.rb +57 -10
  46. data/lib/context_dev/models/web_web_scrape_images_response.rb +42 -1
  47. data/lib/context_dev/models/web_web_scrape_md_params.rb +57 -10
  48. data/lib/context_dev/models/web_web_scrape_md_response.rb +32 -1
  49. data/lib/context_dev/models/web_web_scrape_sitemap_params.rb +53 -8
  50. data/lib/context_dev/models/web_web_scrape_sitemap_response.rb +11 -1
  51. data/lib/context_dev/models.rb +4 -0
  52. data/lib/context_dev/resources/ai.rb +2 -2
  53. data/lib/context_dev/resources/brand.rb +3 -3
  54. data/lib/context_dev/resources/industry.rb +6 -6
  55. data/lib/context_dev/resources/people.rb +2 -2
  56. data/lib/context_dev/resources/utility.rb +2 -2
  57. data/lib/context_dev/resources/web.rb +119 -33
  58. data/lib/context_dev/version.rb +1 -1
  59. data/lib/context_dev.rb +4 -0
  60. data/rbi/context_dev/models/ai_extract_product_params.rbi +125 -13
  61. data/rbi/context_dev/models/ai_extract_product_response.rbi +13 -0
  62. data/rbi/context_dev/models/ai_extract_products_params.rbi +264 -26
  63. data/rbi/context_dev/models/ai_extract_products_response.rbi +15 -0
  64. data/rbi/context_dev/models/brand_retrieve_params.rbi +816 -102
  65. data/rbi/context_dev/models/brand_retrieve_response.rbi +136 -131
  66. data/rbi/context_dev/models/brand_retrieve_simplified_params.rbi +136 -19
  67. data/rbi/context_dev/models/brand_retrieve_simplified_response.rbi +140 -135
  68. data/rbi/context_dev/models/industry_retrieve_naics_params.rbi +127 -13
  69. data/rbi/context_dev/models/industry_retrieve_naics_response.rbi +13 -0
  70. data/rbi/context_dev/models/industry_retrieve_sic_params.rbi +127 -13
  71. data/rbi/context_dev/models/industry_retrieve_sic_response.rbi +13 -0
  72. data/rbi/context_dev/models/monitor_create_params.rbi +40 -2
  73. data/rbi/context_dev/models/monitor_create_response.rbi +44 -4
  74. data/rbi/context_dev/models/monitor_list_response.rbi +44 -4
  75. data/rbi/context_dev/models/monitor_retrieve_response.rbi +44 -4
  76. data/rbi/context_dev/models/monitor_update_params.rbi +40 -2
  77. data/rbi/context_dev/models/monitor_update_response.rbi +44 -4
  78. data/rbi/context_dev/models/person_enrich_params.rbi +123 -13
  79. data/rbi/context_dev/models/person_enrich_response.rbi +16 -3
  80. data/rbi/context_dev/models/utility_prefetch_params.rbi +112 -13
  81. data/rbi/context_dev/models/web_answers_params.rbi +234 -0
  82. data/rbi/context_dev/models/web_answers_response.rbi +122 -0
  83. data/rbi/context_dev/models/web_extract_competitors_params.rbi +127 -13
  84. data/rbi/context_dev/models/web_extract_competitors_response.rbi +16 -3
  85. data/rbi/context_dev/models/web_extract_fonts_params.rbi +132 -19
  86. data/rbi/context_dev/models/web_extract_fonts_response.rbi +71 -0
  87. data/rbi/context_dev/models/web_extract_params.rbi +120 -13
  88. data/rbi/context_dev/models/web_extract_response.rbi +16 -3
  89. data/rbi/context_dev/models/web_extract_styleguide_params.rbi +136 -19
  90. data/rbi/context_dev/models/web_extract_styleguide_response.rbi +71 -0
  91. data/rbi/context_dev/models/web_screenshot_params.rbi +132 -17
  92. data/rbi/context_dev/models/web_screenshot_response.rbi +71 -0
  93. data/rbi/context_dev/models/web_search_params.rbi +253 -26
  94. data/rbi/context_dev/models/web_search_response.rbi +96 -8
  95. data/rbi/context_dev/models/web_web_crawl_md_params.rbi +123 -13
  96. data/rbi/context_dev/models/web_web_crawl_md_response.rbi +19 -3
  97. data/rbi/context_dev/models/web_web_scrape_bytes_params.rbi +699 -0
  98. data/rbi/context_dev/models/web_web_scrape_bytes_response.rbi +238 -0
  99. data/rbi/context_dev/models/web_web_scrape_html_params.rbi +132 -17
  100. data/rbi/context_dev/models/web_web_scrape_html_response.rbi +61 -0
  101. data/rbi/context_dev/models/web_web_scrape_images_params.rbi +134 -17
  102. data/rbi/context_dev/models/web_web_scrape_images_response.rbi +89 -3
  103. data/rbi/context_dev/models/web_web_scrape_md_params.rbi +130 -17
  104. data/rbi/context_dev/models/web_web_scrape_md_response.rbi +61 -0
  105. data/rbi/context_dev/models/web_web_scrape_sitemap_params.rbi +127 -13
  106. data/rbi/context_dev/models/web_web_scrape_sitemap_response.rbi +18 -3
  107. data/rbi/context_dev/models.rbi +4 -0
  108. data/rbi/context_dev/resources/ai.rbi +5 -5
  109. data/rbi/context_dev/resources/brand.rbi +9 -8
  110. data/rbi/context_dev/resources/industry.rbi +12 -10
  111. data/rbi/context_dev/resources/people.rbi +5 -5
  112. data/rbi/context_dev/resources/utility.rbi +5 -5
  113. data/rbi/context_dev/resources/web.rbi +170 -72
  114. data/sig/context_dev/models/ai_extract_product_params.rbs +44 -5
  115. data/sig/context_dev/models/ai_extract_product_response.rbs +7 -0
  116. data/sig/context_dev/models/ai_extract_products_params.rbs +88 -10
  117. data/sig/context_dev/models/ai_extract_products_response.rbs +7 -0
  118. data/sig/context_dev/models/brand_retrieve_params.rbs +264 -30
  119. data/sig/context_dev/models/brand_retrieve_response.rbs +53 -54
  120. data/sig/context_dev/models/brand_retrieve_simplified_params.rbs +44 -5
  121. data/sig/context_dev/models/brand_retrieve_simplified_response.rbs +53 -54
  122. data/sig/context_dev/models/industry_retrieve_naics_params.rbs +44 -5
  123. data/sig/context_dev/models/industry_retrieve_naics_response.rbs +7 -0
  124. data/sig/context_dev/models/industry_retrieve_sic_params.rbs +44 -5
  125. data/sig/context_dev/models/industry_retrieve_sic_response.rbs +7 -0
  126. data/sig/context_dev/models/monitor_create_params.rbs +14 -0
  127. data/sig/context_dev/models/monitor_create_response.rbs +14 -0
  128. data/sig/context_dev/models/monitor_list_response.rbs +14 -0
  129. data/sig/context_dev/models/monitor_retrieve_response.rbs +14 -0
  130. data/sig/context_dev/models/monitor_update_params.rbs +14 -0
  131. data/sig/context_dev/models/monitor_update_response.rbs +14 -0
  132. data/sig/context_dev/models/person_enrich_params.rbs +44 -5
  133. data/sig/context_dev/models/person_enrich_response.rbs +10 -3
  134. data/sig/context_dev/models/utility_prefetch_params.rbs +43 -5
  135. data/sig/context_dev/models/web_answers_params.rbs +106 -0
  136. data/sig/context_dev/models/web_answers_response.rbs +60 -0
  137. data/sig/context_dev/models/web_extract_competitors_params.rbs +44 -5
  138. data/sig/context_dev/models/web_extract_competitors_response.rbs +10 -3
  139. data/sig/context_dev/models/web_extract_fonts_params.rbs +44 -5
  140. data/sig/context_dev/models/web_extract_fonts_response.rbs +20 -0
  141. data/sig/context_dev/models/web_extract_params.rbs +44 -5
  142. data/sig/context_dev/models/web_extract_response.rbs +10 -3
  143. data/sig/context_dev/models/web_extract_styleguide_params.rbs +44 -5
  144. data/sig/context_dev/models/web_extract_styleguide_response.rbs +20 -0
  145. data/sig/context_dev/models/web_screenshot_params.rbs +44 -5
  146. data/sig/context_dev/models/web_screenshot_response.rbs +20 -0
  147. data/sig/context_dev/models/web_search_params.rbs +88 -10
  148. data/sig/context_dev/models/web_search_response.rbs +33 -6
  149. data/sig/context_dev/models/web_web_crawl_md_params.rbs +44 -5
  150. data/sig/context_dev/models/web_web_crawl_md_response.rbs +10 -3
  151. data/sig/context_dev/models/web_web_scrape_bytes_params.rbs +531 -0
  152. data/sig/context_dev/models/web_web_scrape_bytes_response.rbs +108 -0
  153. data/sig/context_dev/models/web_web_scrape_html_params.rbs +44 -5
  154. data/sig/context_dev/models/web_web_scrape_html_response.rbs +16 -0
  155. data/sig/context_dev/models/web_web_scrape_images_params.rbs +44 -5
  156. data/sig/context_dev/models/web_web_scrape_images_response.rbs +30 -3
  157. data/sig/context_dev/models/web_web_scrape_md_params.rbs +44 -5
  158. data/sig/context_dev/models/web_web_scrape_md_response.rbs +16 -0
  159. data/sig/context_dev/models/web_web_scrape_sitemap_params.rbs +44 -5
  160. data/sig/context_dev/models/web_web_scrape_sitemap_response.rbs +10 -3
  161. data/sig/context_dev/models.rbs +4 -0
  162. data/sig/context_dev/resources/ai.rbs +1 -1
  163. data/sig/context_dev/resources/brand.rbs +1 -1
  164. data/sig/context_dev/resources/industry.rbs +2 -2
  165. data/sig/context_dev/resources/people.rbs +1 -1
  166. data/sig/context_dev/resources/utility.rbs +1 -1
  167. data/sig/context_dev/resources/web.rbs +30 -11
  168. metadata +14 -2
@@ -38,6 +38,13 @@ module ContextDev
38
38
  # @return [ContextDev::Models::IndustryRetrieveSicResponse::KeyMetadata, nil]
39
39
  optional :key_metadata, -> { ContextDev::Models::IndustryRetrieveSicResponse::KeyMetadata }
40
40
 
41
+ # @!attribute partial
42
+ # True when the timeout ended processing and this response contains only usable
43
+ # results completed so far. Unfinished results are omitted.
44
+ #
45
+ # @return [Boolean, nil]
46
+ optional :partial, ContextDev::Internal::Type::Boolean
47
+
41
48
  # @!attribute status
42
49
  # Status of the response, e.g., 'ok'
43
50
  #
@@ -50,7 +57,7 @@ module ContextDev
50
57
  # @return [String, nil]
51
58
  optional :type, String
52
59
 
53
- # @!method initialize(request_id:, classification: nil, codes: nil, domain: nil, key_metadata: nil, status: nil, type: nil)
60
+ # @!method initialize(request_id:, classification: nil, codes: nil, domain: nil, key_metadata: nil, partial: nil, status: nil, type: nil)
54
61
  # Some parameter documentations has been truncated, see
55
62
  # {ContextDev::Models::IndustryRetrieveSicResponse} for more details.
56
63
  #
@@ -64,6 +71,8 @@ module ContextDev
64
71
  #
65
72
  # @param key_metadata [ContextDev::Models::IndustryRetrieveSicResponse::KeyMetadata] Credit usage, included whenever a valid API key is provided.
66
73
  #
74
+ # @param partial [Boolean] True when the timeout ended processing and this response contains only usable re
75
+ #
67
76
  # @param status [String] Status of the response, e.g., 'ok'
68
77
  #
69
78
  # @param type [String] Industry classification type, for sic api it will be `sic`
@@ -97,6 +97,25 @@ module ContextDev
97
97
  # @return [String]
98
98
  required :url, String
99
99
 
100
+ # @!attribute exclude_selectors
101
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
102
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
103
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
104
+ # creates a new baseline.
105
+ #
106
+ # @return [Array<String>, nil]
107
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
108
+
109
+ # @!attribute include_selectors
110
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
111
+ # combined in document order before text extraction, instead of automatic
112
+ # main-content selection. Omit or pass an empty array to use automatic
113
+ # main-content extraction. If the filtered page has no usable text, the run fails
114
+ # without replacing the baseline. Changing these selectors creates a new baseline.
115
+ #
116
+ # @return [Array<String>, nil]
117
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
118
+
100
119
  # @!attribute instructions
101
120
  # Plain-language goal describing which page changes matter. When provided without
102
121
  # change_detection, semantic detection is inferred.
@@ -110,7 +129,7 @@ module ContextDev
110
129
  # @return [Boolean, nil]
111
130
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
112
131
 
113
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
132
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
114
133
  # Some parameter documentations has been truncated, see
115
134
  # {ContextDev::Models::MonitorCreateParams::Target::Page} for more details.
116
135
  #
@@ -119,6 +138,10 @@ module ContextDev
119
138
  #
120
139
  # @param url [String]
121
140
  #
141
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
142
+ #
143
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
144
+ #
122
145
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
123
146
  #
124
147
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -371,7 +394,8 @@ module ContextDev
371
394
 
372
395
  class Webhook < ContextDev::Internal::Type::BaseModel
373
396
  # @!attribute url
374
- # Webhook URL events are delivered to.
397
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
398
+ # automatically formatted as Slack messages.
375
399
  #
376
400
  # @return [String]
377
401
  required :url, String
@@ -396,7 +420,7 @@ module ContextDev
396
420
  # Some parameter documentations has been truncated, see
397
421
  # {ContextDev::Models::MonitorCreateParams::Webhook} for more details.
398
422
  #
399
- # @param url [String] Webhook URL events are delivered to.
423
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
400
424
  #
401
425
  # @param events [Array<Symbol, ContextDev::Models::MonitorCreateParams::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
402
426
  #
@@ -331,6 +331,25 @@ module ContextDev
331
331
  # @return [String]
332
332
  required :url, String
333
333
 
334
+ # @!attribute exclude_selectors
335
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
336
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
337
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
338
+ # creates a new baseline.
339
+ #
340
+ # @return [Array<String>, nil]
341
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
342
+
343
+ # @!attribute include_selectors
344
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
345
+ # combined in document order before text extraction, instead of automatic
346
+ # main-content selection. Omit or pass an empty array to use automatic
347
+ # main-content extraction. If the filtered page has no usable text, the run fails
348
+ # without replacing the baseline. Changing these selectors creates a new baseline.
349
+ #
350
+ # @return [Array<String>, nil]
351
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
352
+
334
353
  # @!attribute instructions
335
354
  # Plain-language goal describing which page changes matter. When provided without
336
355
  # change_detection, semantic detection is inferred.
@@ -344,7 +363,7 @@ module ContextDev
344
363
  # @return [Boolean, nil]
345
364
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
346
365
 
347
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
366
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
348
367
  # Some parameter documentations has been truncated, see
349
368
  # {ContextDev::Models::MonitorCreateResponse::Target::Page} for more details.
350
369
  #
@@ -353,6 +372,10 @@ module ContextDev
353
372
  #
354
373
  # @param url [String]
355
374
  #
375
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
376
+ #
377
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
378
+ #
356
379
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
357
380
  #
358
381
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -618,7 +641,8 @@ module ContextDev
618
641
  # @see ContextDev::Models::MonitorCreateResponse#webhook
619
642
  class Webhook < ContextDev::Internal::Type::BaseModel
620
643
  # @!attribute url
621
- # Webhook URL events are delivered to.
644
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
645
+ # automatically formatted as Slack messages.
622
646
  #
623
647
  # @return [String]
624
648
  required :url, String
@@ -641,7 +665,8 @@ module ContextDev
641
665
 
642
666
  response_only do
643
667
  # @!attribute secret
644
- # Signing secret used to verify webhook authenticity. Each delivery includes an
668
+ # Signing secret used to verify webhook authenticity. Omitted unless the API key
669
+ # has monitors:write permission or full access. Each delivery includes an
645
670
  # `X-Context-Signature: t=<unix>,v1=<hmac>` header, where the HMAC is SHA-256 over
646
671
  # `"{t}.{rawRequestBody}"` keyed by this secret. Recompute it with a constant-time
647
672
  # compare and reject stale timestamps to prevent replay. Generated by the API;
@@ -655,13 +680,13 @@ module ContextDev
655
680
  # Some parameter documentations has been truncated, see
656
681
  # {ContextDev::Models::MonitorCreateResponse::Webhook} for more details.
657
682
  #
658
- # @param url [String] Webhook URL events are delivered to.
683
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
659
684
  #
660
685
  # @param events [Array<Symbol, ContextDev::Models::MonitorCreateResponse::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
661
686
  #
662
687
  # @param retry_ [ContextDev::Models::RetryConfig] Webhook retry settings. Use {} for the default schedule.
663
688
  #
664
- # @param secret [String] Signing secret used to verify webhook authenticity. Each delivery includes an `X
689
+ # @param secret [String] Signing secret used to verify webhook authenticity. Omitted unless the API key h
665
690
 
666
691
  module Event
667
692
  extend ContextDev::Internal::Type::Enum
@@ -344,6 +344,25 @@ module ContextDev
344
344
  # @return [String]
345
345
  required :url, String
346
346
 
347
+ # @!attribute exclude_selectors
348
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
349
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
350
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
351
+ # creates a new baseline.
352
+ #
353
+ # @return [Array<String>, nil]
354
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
355
+
356
+ # @!attribute include_selectors
357
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
358
+ # combined in document order before text extraction, instead of automatic
359
+ # main-content selection. Omit or pass an empty array to use automatic
360
+ # main-content extraction. If the filtered page has no usable text, the run fails
361
+ # without replacing the baseline. Changing these selectors creates a new baseline.
362
+ #
363
+ # @return [Array<String>, nil]
364
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
365
+
347
366
  # @!attribute instructions
348
367
  # Plain-language goal describing which page changes matter. When provided without
349
368
  # change_detection, semantic detection is inferred.
@@ -357,7 +376,7 @@ module ContextDev
357
376
  # @return [Boolean, nil]
358
377
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
359
378
 
360
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
379
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
361
380
  # Some parameter documentations has been truncated, see
362
381
  # {ContextDev::Models::MonitorListResponse::Data::Target::Page} for more details.
363
382
  #
@@ -366,6 +385,10 @@ module ContextDev
366
385
  #
367
386
  # @param url [String]
368
387
  #
388
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
389
+ #
390
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
391
+ #
369
392
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
370
393
  #
371
394
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -632,7 +655,8 @@ module ContextDev
632
655
  # @see ContextDev::Models::MonitorListResponse::Data#webhook
633
656
  class Webhook < ContextDev::Internal::Type::BaseModel
634
657
  # @!attribute url
635
- # Webhook URL events are delivered to.
658
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
659
+ # automatically formatted as Slack messages.
636
660
  #
637
661
  # @return [String]
638
662
  required :url, String
@@ -655,7 +679,8 @@ module ContextDev
655
679
 
656
680
  response_only do
657
681
  # @!attribute secret
658
- # Signing secret used to verify webhook authenticity. Each delivery includes an
682
+ # Signing secret used to verify webhook authenticity. Omitted unless the API key
683
+ # has monitors:write permission or full access. Each delivery includes an
659
684
  # `X-Context-Signature: t=<unix>,v1=<hmac>` header, where the HMAC is SHA-256 over
660
685
  # `"{t}.{rawRequestBody}"` keyed by this secret. Recompute it with a constant-time
661
686
  # compare and reject stale timestamps to prevent replay. Generated by the API;
@@ -669,13 +694,13 @@ module ContextDev
669
694
  # Some parameter documentations has been truncated, see
670
695
  # {ContextDev::Models::MonitorListResponse::Data::Webhook} for more details.
671
696
  #
672
- # @param url [String] Webhook URL events are delivered to.
697
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
673
698
  #
674
699
  # @param events [Array<Symbol, ContextDev::Models::MonitorListResponse::Data::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
675
700
  #
676
701
  # @param retry_ [ContextDev::Models::RetryConfig] Webhook retry settings. Use {} for the default schedule.
677
702
  #
678
- # @param secret [String] Signing secret used to verify webhook authenticity. Each delivery includes an `X
703
+ # @param secret [String] Signing secret used to verify webhook authenticity. Omitted unless the API key h
679
704
 
680
705
  module Event
681
706
  extend ContextDev::Internal::Type::Enum
@@ -321,6 +321,25 @@ module ContextDev
321
321
  # @return [String]
322
322
  required :url, String
323
323
 
324
+ # @!attribute exclude_selectors
325
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
326
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
327
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
328
+ # creates a new baseline.
329
+ #
330
+ # @return [Array<String>, nil]
331
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
332
+
333
+ # @!attribute include_selectors
334
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
335
+ # combined in document order before text extraction, instead of automatic
336
+ # main-content selection. Omit or pass an empty array to use automatic
337
+ # main-content extraction. If the filtered page has no usable text, the run fails
338
+ # without replacing the baseline. Changing these selectors creates a new baseline.
339
+ #
340
+ # @return [Array<String>, nil]
341
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
342
+
324
343
  # @!attribute instructions
325
344
  # Plain-language goal describing which page changes matter. When provided without
326
345
  # change_detection, semantic detection is inferred.
@@ -334,7 +353,7 @@ module ContextDev
334
353
  # @return [Boolean, nil]
335
354
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
336
355
 
337
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
356
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
338
357
  # Some parameter documentations has been truncated, see
339
358
  # {ContextDev::Models::MonitorRetrieveResponse::Target::Page} for more details.
340
359
  #
@@ -343,6 +362,10 @@ module ContextDev
343
362
  #
344
363
  # @param url [String]
345
364
  #
365
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
366
+ #
367
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
368
+ #
346
369
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
347
370
  #
348
371
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -608,7 +631,8 @@ module ContextDev
608
631
  # @see ContextDev::Models::MonitorRetrieveResponse#webhook
609
632
  class Webhook < ContextDev::Internal::Type::BaseModel
610
633
  # @!attribute url
611
- # Webhook URL events are delivered to.
634
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
635
+ # automatically formatted as Slack messages.
612
636
  #
613
637
  # @return [String]
614
638
  required :url, String
@@ -631,7 +655,8 @@ module ContextDev
631
655
 
632
656
  response_only do
633
657
  # @!attribute secret
634
- # Signing secret used to verify webhook authenticity. Each delivery includes an
658
+ # Signing secret used to verify webhook authenticity. Omitted unless the API key
659
+ # has monitors:write permission or full access. Each delivery includes an
635
660
  # `X-Context-Signature: t=<unix>,v1=<hmac>` header, where the HMAC is SHA-256 over
636
661
  # `"{t}.{rawRequestBody}"` keyed by this secret. Recompute it with a constant-time
637
662
  # compare and reject stale timestamps to prevent replay. Generated by the API;
@@ -645,13 +670,13 @@ module ContextDev
645
670
  # Some parameter documentations has been truncated, see
646
671
  # {ContextDev::Models::MonitorRetrieveResponse::Webhook} for more details.
647
672
  #
648
- # @param url [String] Webhook URL events are delivered to.
673
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
649
674
  #
650
675
  # @param events [Array<Symbol, ContextDev::Models::MonitorRetrieveResponse::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
651
676
  #
652
677
  # @param retry_ [ContextDev::Models::RetryConfig] Webhook retry settings. Use {} for the default schedule.
653
678
  #
654
- # @param secret [String] Signing secret used to verify webhook authenticity. Each delivery includes an `X
679
+ # @param secret [String] Signing secret used to verify webhook authenticity. Omitted unless the API key h
655
680
 
656
681
  module Event
657
682
  extend ContextDev::Internal::Type::Enum
@@ -219,6 +219,25 @@ module ContextDev
219
219
  # @return [String]
220
220
  required :url, String
221
221
 
222
+ # @!attribute exclude_selectors
223
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
224
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
225
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
226
+ # creates a new baseline.
227
+ #
228
+ # @return [Array<String>, nil]
229
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
230
+
231
+ # @!attribute include_selectors
232
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
233
+ # combined in document order before text extraction, instead of automatic
234
+ # main-content selection. Omit or pass an empty array to use automatic
235
+ # main-content extraction. If the filtered page has no usable text, the run fails
236
+ # without replacing the baseline. Changing these selectors creates a new baseline.
237
+ #
238
+ # @return [Array<String>, nil]
239
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
240
+
222
241
  # @!attribute instructions
223
242
  # Plain-language goal describing which page changes matter. When provided without
224
243
  # change_detection, semantic detection is inferred.
@@ -232,7 +251,7 @@ module ContextDev
232
251
  # @return [Boolean, nil]
233
252
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
234
253
 
235
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
254
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
236
255
  # Some parameter documentations has been truncated, see
237
256
  # {ContextDev::Models::MonitorUpdateParams::Target::Page} for more details.
238
257
  #
@@ -241,6 +260,10 @@ module ContextDev
241
260
  #
242
261
  # @param url [String]
243
262
  #
263
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
264
+ #
265
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
266
+ #
244
267
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
245
268
  #
246
269
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -376,7 +399,8 @@ module ContextDev
376
399
 
377
400
  class Webhook < ContextDev::Internal::Type::BaseModel
378
401
  # @!attribute url
379
- # Webhook URL events are delivered to.
402
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
403
+ # automatically formatted as Slack messages.
380
404
  #
381
405
  # @return [String]
382
406
  required :url, String
@@ -403,7 +427,7 @@ module ContextDev
403
427
  #
404
428
  # Set to null to remove the webhook.
405
429
  #
406
- # @param url [String] Webhook URL events are delivered to.
430
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
407
431
  #
408
432
  # @param events [Array<Symbol, ContextDev::Models::MonitorUpdateParams::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
409
433
  #
@@ -321,6 +321,25 @@ module ContextDev
321
321
  # @return [String]
322
322
  required :url, String
323
323
 
324
+ # @!attribute exclude_selectors
325
+ # CSS selectors for HTML regions to remove before text extraction. Applied after
326
+ # include_selectors; exclusion takes precedence when an element matches both. Omit
327
+ # or pass an empty array to apply no explicit exclusions. Changing these selectors
328
+ # creates a new baseline.
329
+ #
330
+ # @return [Array<String>, nil]
331
+ optional :exclude_selectors, ContextDev::Internal::Type::ArrayOf[String]
332
+
333
+ # @!attribute include_selectors
334
+ # CSS selectors defining the HTML regions to monitor. Matching subtrees are
335
+ # combined in document order before text extraction, instead of automatic
336
+ # main-content selection. Omit or pass an empty array to use automatic
337
+ # main-content extraction. If the filtered page has no usable text, the run fails
338
+ # without replacing the baseline. Changing these selectors creates a new baseline.
339
+ #
340
+ # @return [Array<String>, nil]
341
+ optional :include_selectors, ContextDev::Internal::Type::ArrayOf[String]
342
+
324
343
  # @!attribute instructions
325
344
  # Plain-language goal describing which page changes matter. When provided without
326
345
  # change_detection, semantic detection is inferred.
@@ -334,7 +353,7 @@ module ContextDev
334
353
  # @return [Boolean, nil]
335
354
  optional :normalize_whitespace, ContextDev::Internal::Type::Boolean
336
355
 
337
- # @!method initialize(url:, instructions: nil, normalize_whitespace: nil, type: :page)
356
+ # @!method initialize(url:, exclude_selectors: nil, include_selectors: nil, instructions: nil, normalize_whitespace: nil, type: :page)
338
357
  # Some parameter documentations has been truncated, see
339
358
  # {ContextDev::Models::MonitorUpdateResponse::Target::Page} for more details.
340
359
  #
@@ -343,6 +362,10 @@ module ContextDev
343
362
  #
344
363
  # @param url [String]
345
364
  #
365
+ # @param exclude_selectors [Array<String>] CSS selectors for HTML regions to remove before text extraction. Applied after i
366
+ #
367
+ # @param include_selectors [Array<String>] CSS selectors defining the HTML regions to monitor. Matching subtrees are combin
368
+ #
346
369
  # @param instructions [String] Plain-language goal describing which page changes matter. When provided without
347
370
  #
348
371
  # @param normalize_whitespace [Boolean] Normalize whitespace before comparing or analyzing text.
@@ -608,7 +631,8 @@ module ContextDev
608
631
  # @see ContextDev::Models::MonitorUpdateResponse#webhook
609
632
  class Webhook < ContextDev::Internal::Type::BaseModel
610
633
  # @!attribute url
611
- # Webhook URL events are delivered to.
634
+ # Webhook URL events are delivered to. Slack incoming webhook URLs are
635
+ # automatically formatted as Slack messages.
612
636
  #
613
637
  # @return [String]
614
638
  required :url, String
@@ -631,7 +655,8 @@ module ContextDev
631
655
 
632
656
  response_only do
633
657
  # @!attribute secret
634
- # Signing secret used to verify webhook authenticity. Each delivery includes an
658
+ # Signing secret used to verify webhook authenticity. Omitted unless the API key
659
+ # has monitors:write permission or full access. Each delivery includes an
635
660
  # `X-Context-Signature: t=<unix>,v1=<hmac>` header, where the HMAC is SHA-256 over
636
661
  # `"{t}.{rawRequestBody}"` keyed by this secret. Recompute it with a constant-time
637
662
  # compare and reject stale timestamps to prevent replay. Generated by the API;
@@ -645,13 +670,13 @@ module ContextDev
645
670
  # Some parameter documentations has been truncated, see
646
671
  # {ContextDev::Models::MonitorUpdateResponse::Webhook} for more details.
647
672
  #
648
- # @param url [String] Webhook URL events are delivered to.
673
+ # @param url [String] Webhook URL events are delivered to. Slack incoming webhook URLs are automatical
649
674
  #
650
675
  # @param events [Array<Symbol, ContextDev::Models::MonitorUpdateResponse::Webhook::Event>] Events delivered to this endpoint. `change.detected` fires only when a run detec
651
676
  #
652
677
  # @param retry_ [ContextDev::Models::RetryConfig] Webhook retry settings. Use {} for the default schedule.
653
678
  #
654
- # @param secret [String] Signing secret used to verify webhook authenticity. Each delivery includes an `X
679
+ # @param secret [String] Signing secret used to verify webhook authenticity. Omitted unless the API key h
655
680
 
656
681
  module Event
657
682
  extend ContextDev::Internal::Type::Enum
@@ -43,15 +43,15 @@ module ContextDev
43
43
  # @return [Array<String>, nil]
44
44
  optional :tags, ContextDev::Internal::Type::ArrayOf[String]
45
45
 
46
- # @!attribute timeout_ms
47
- # Optional timeout in milliseconds for the request. If the request takes longer
48
- # than this value, it will be aborted with a 408 status code. Maximum allowed
49
- # value is 300000ms (5 minutes).
46
+ # @!attribute timeout_opts
47
+ # Optional request deadline and behavior on timeout. For GET requests, use
48
+ # timeoutOpts[milliseconds]=30000&timeoutOpts[behavior]=fail or a JSON-encoded
49
+ # timeoutOpts object.
50
50
  #
51
- # @return [Integer, nil]
52
- optional :timeout_ms, Integer, api_name: :timeoutMS
51
+ # @return [ContextDev::Models::PersonEnrichParams::TimeoutOpts, nil]
52
+ optional :timeout_opts, -> { ContextDev::PersonEnrichParams::TimeoutOpts }, api_name: :timeoutOpts
53
53
 
54
- # @!method initialize(company: nil, education: nil, email: nil, location: nil, name: nil, social_urls: nil, tags: nil, timeout_ms: nil, request_options: {})
54
+ # @!method initialize(company: nil, education: nil, email: nil, location: nil, name: nil, social_urls: nil, tags: nil, timeout_opts: nil, request_options: {})
55
55
  # Some parameter documentations has been truncated, see
56
56
  # {ContextDev::Models::PersonEnrichParams} for more details.
57
57
  #
@@ -69,7 +69,7 @@ module ContextDev
69
69
  #
70
70
  # @param tags [Array<String>] Optional tags for tracking usage. Up to 20 tags, each 1 to 50 characters.
71
71
  #
72
- # @param timeout_ms [Integer] Optional timeout in milliseconds for the request. If the request takes longer th
72
+ # @param timeout_opts [ContextDev::Models::PersonEnrichParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
73
73
  #
74
74
  # @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
75
75
 
@@ -171,6 +171,51 @@ module ContextDev
171
171
  # @param first [String]
172
172
  # @param last [String]
173
173
  end
174
+
175
+ class TimeoutOpts < ContextDev::Internal::Type::BaseModel
176
+ # @!attribute milliseconds
177
+ # Request deadline in milliseconds. Maximum: 300000 (5 minutes).
178
+ #
179
+ # @return [Integer]
180
+ required :milliseconds, Integer
181
+
182
+ # @!attribute behavior
183
+ # What to do at the deadline. "fail" returns 408 REQUEST_TIMEOUT without charging
184
+ # credits. "return-partial" returns usable results collected so far; if none are
185
+ # available, the request still fails without charging credits. Partial results are
186
+ # not cached as complete results.
187
+ #
188
+ # @return [Symbol, ContextDev::Models::PersonEnrichParams::TimeoutOpts::Behavior, nil]
189
+ optional :behavior, enum: -> { ContextDev::PersonEnrichParams::TimeoutOpts::Behavior }
190
+
191
+ # @!method initialize(milliseconds:, behavior: nil)
192
+ # Some parameter documentations has been truncated, see
193
+ # {ContextDev::Models::PersonEnrichParams::TimeoutOpts} for more details.
194
+ #
195
+ # Optional request deadline and behavior on timeout. For GET requests, use
196
+ # timeoutOpts[milliseconds]=30000&timeoutOpts[behavior]=fail or a JSON-encoded
197
+ # timeoutOpts object.
198
+ #
199
+ # @param milliseconds [Integer] Request deadline in milliseconds. Maximum: 300000 (5 minutes).
200
+ #
201
+ # @param behavior [Symbol, ContextDev::Models::PersonEnrichParams::TimeoutOpts::Behavior] What to do at the deadline. "fail" returns 408 REQUEST_TIMEOUT without charging
202
+
203
+ # What to do at the deadline. "fail" returns 408 REQUEST_TIMEOUT without charging
204
+ # credits. "return-partial" returns usable results collected so far; if none are
205
+ # available, the request still fails without charging credits. Partial results are
206
+ # not cached as complete results.
207
+ #
208
+ # @see ContextDev::Models::PersonEnrichParams::TimeoutOpts#behavior
209
+ module Behavior
210
+ extend ContextDev::Internal::Type::Enum
211
+
212
+ FAIL = :fail
213
+ RETURN_PARTIAL = :"return-partial"
214
+
215
+ # @!method self.values
216
+ # @return [Array<Symbol>]
217
+ end
218
+ end
174
219
  end
175
220
  end
176
221
  end
@@ -23,7 +23,14 @@ module ContextDev
23
23
  # @return [ContextDev::Models::PersonEnrichResponse::KeyMetadata, nil]
24
24
  optional :key_metadata, -> { ContextDev::Models::PersonEnrichResponse::KeyMetadata }
25
25
 
26
- # @!method initialize(match:, request_id:, key_metadata: nil)
26
+ # @!attribute partial
27
+ # True when the timeout ended processing and this response contains the usable
28
+ # data completed so far. Unfinished fields are omitted.
29
+ #
30
+ # @return [Boolean, nil]
31
+ optional :partial, ContextDev::Internal::Type::Boolean
32
+
33
+ # @!method initialize(match:, request_id:, key_metadata: nil, partial: nil)
27
34
  # Some parameter documentations has been truncated, see
28
35
  # {ContextDev::Models::PersonEnrichResponse} for more details.
29
36
  #
@@ -32,6 +39,8 @@ module ContextDev
32
39
  # @param request_id [String] Unique id of this API call, also sent in the X-Request-Id response header. Quote
33
40
  #
34
41
  # @param key_metadata [ContextDev::Models::PersonEnrichResponse::KeyMetadata] Credit usage, included whenever a valid API key is provided.
42
+ #
43
+ # @param partial [Boolean] True when the timeout ended processing and this response contains the usable dat
35
44
 
36
45
  # The highest-scoring person candidate.
37
46
  #