context.dev 2.1.0 → 2.2.0
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +9 -0
- data/README.md +1 -1
- data/lib/context_dev/models/monitor_create_params.rb +16 -11
- data/lib/context_dev/models/monitor_create_response.rb +16 -11
- data/lib/context_dev/models/monitor_list_account_runs_response.rb +102 -1
- data/lib/context_dev/models/monitor_list_response.rb +16 -11
- data/lib/context_dev/models/monitor_list_runs_response.rb +100 -1
- data/lib/context_dev/models/monitor_retrieve_response.rb +16 -11
- data/lib/context_dev/models/monitor_update_params.rb +16 -11
- data/lib/context_dev/models/monitor_update_response.rb +16 -11
- data/lib/context_dev/version.rb +1 -1
- data/rbi/context_dev/models/monitor_create_params.rbi +21 -11
- data/rbi/context_dev/models/monitor_create_response.rbi +21 -11
- data/rbi/context_dev/models/monitor_list_account_runs_response.rbi +204 -3
- data/rbi/context_dev/models/monitor_list_response.rbi +21 -11
- data/rbi/context_dev/models/monitor_list_runs_response.rbi +204 -3
- data/rbi/context_dev/models/monitor_retrieve_response.rbi +21 -11
- data/rbi/context_dev/models/monitor_update_params.rbi +21 -11
- data/rbi/context_dev/models/monitor_update_response.rbi +21 -11
- data/sig/context_dev/models/monitor_list_account_runs_response.rbs +74 -3
- data/sig/context_dev/models/monitor_list_runs_response.rbs +74 -3
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 71a15fd21461c08a07aee8a7a0b03646393d119834f5977c703fa504a3fef780
|
|
4
|
+
data.tar.gz: cb91bfce1cc1e42798249e1a08001bbdf881ef37c0c9832783d7e511e721bd58
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3720fb3277c71cf83c1b01867e7cfb956e4b0588e421c23b5ef36fb7c715c5d4a94678e3de49ec83ab268628b1fccfa3b1f526f6a08ba459c213292930ebbe41
|
|
7
|
+
data.tar.gz: 60494a702cba70b719ef8e83f4d410d3e4a59af67cb0d0e478b7061646ba87702605505d8c09c311b8dd8d2fdd8bd60caf684a17904229291fcc1e29b9696e02
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2.2.0 (2026-07-10)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v2.1.0...v2.2.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v2.1.0...v2.2.0)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **api:** api update ([04e3709](https://github.com/context-dot-dev/context-ruby-sdk/commit/04e370916ae9679892d86fc297e3c935afa1e2c2))
|
|
10
|
+
* **api:** api update ([59b7e62](https://github.com/context-dot-dev/context-ruby-sdk/commit/59b7e62e57eff7482db12fe2dd1a97298620b88f))
|
|
11
|
+
|
|
3
12
|
## 2.1.0 (2026-07-08)
|
|
4
13
|
|
|
5
14
|
Full Changelog: [v2.0.0...v2.1.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v2.0.0...v2.1.0)
|
data/README.md
CHANGED
|
@@ -79,7 +79,7 @@ module ContextDev
|
|
|
79
79
|
# Detect exact changes. For page targets, this means visible text diffs. For sitemap targets, this means URL additions and removals.
|
|
80
80
|
variant :exact, -> { ContextDev::MonitorCreateParams::ChangeDetection::Exact }
|
|
81
81
|
|
|
82
|
-
# Detect meaning-level changes to
|
|
82
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or paraphrase-only differences. Which changes are meaningful is judged against the extract target's `instructions` (and `schema`, when provided).
|
|
83
83
|
variant :semantic, -> { ContextDev::MonitorCreateParams::ChangeDetection::Semantic }
|
|
84
84
|
|
|
85
85
|
class Exact < ContextDev::Internal::Type::BaseModel
|
|
@@ -107,9 +107,9 @@ module ContextDev
|
|
|
107
107
|
optional :confidence_threshold, Float
|
|
108
108
|
|
|
109
109
|
# @!method initialize(confidence_threshold: nil, type: :semantic)
|
|
110
|
-
# Detect meaning-level changes to
|
|
111
|
-
# paraphrase-only differences.
|
|
112
|
-
# target's `
|
|
110
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or
|
|
111
|
+
# paraphrase-only differences. Which changes are meaningful is judged against the
|
|
112
|
+
# extract target's `instructions` (and `schema`, when provided).
|
|
113
113
|
#
|
|
114
114
|
# @param confidence_threshold [Float]
|
|
115
115
|
# @param type [Symbol, :semantic]
|
|
@@ -187,7 +187,7 @@ module ContextDev
|
|
|
187
187
|
# 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. On a detected difference the sitemap is re-fetched within the same run and only URLs both observations agree on are reported, suppressing transient crawl flaps.
|
|
188
188
|
variant :sitemap, -> { ContextDev::MonitorCreateParams::Target::Sitemap }
|
|
189
189
|
|
|
190
|
-
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged against the monitor's instructions. The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
190
|
+
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged for relevance against the monitor's `instructions` (and `schema`, when provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
191
191
|
variant :extract, -> { ContextDev::MonitorCreateParams::Target::Extract }
|
|
192
192
|
|
|
193
193
|
class Page < ContextDev::Internal::Type::BaseModel
|
|
@@ -302,9 +302,14 @@ module ContextDev
|
|
|
302
302
|
optional :max_pages, Integer
|
|
303
303
|
|
|
304
304
|
# @!attribute schema
|
|
305
|
-
# JSON Schema describing the data you care about. It
|
|
306
|
-
# selected for tracking
|
|
307
|
-
#
|
|
305
|
+
# JSON Schema describing the data you care about. It is used three ways: it guides
|
|
306
|
+
# which pages are selected for tracking, it gives the change judge extra context
|
|
307
|
+
# on which changes matter (alongside `instructions`), and it defines the shape of
|
|
308
|
+
# the baseline `data` snapshot on GET /monitors/{monitor_id} (refreshed at most
|
|
309
|
+
# about once a day). It is not a response format for changes: change events and
|
|
310
|
+
# webhook payloads always contain diffs, summaries, and evidence excerpts — never
|
|
311
|
+
# data in this schema's shape. If omitted, a default summary + key-points schema
|
|
312
|
+
# is used.
|
|
308
313
|
#
|
|
309
314
|
# @return [Hash{Symbol=>Object}, nil]
|
|
310
315
|
optional :schema, ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]
|
|
@@ -316,8 +321,8 @@ module ContextDev
|
|
|
316
321
|
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl
|
|
317
322
|
# guided by `schema`/`instructions` selects up to `max_pages` relevant pages to
|
|
318
323
|
# track; each run re-checks exactly those pages, and confirmed content changes are
|
|
319
|
-
# judged against the monitor's instructions
|
|
320
|
-
# a periodic re-discovery crawl.
|
|
324
|
+
# judged for relevance against the monitor's `instructions` (and `schema`, when
|
|
325
|
+
# provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
321
326
|
#
|
|
322
327
|
# @param instructions [String] Natural-language instructions guiding which pages and facts to track and which c
|
|
323
328
|
#
|
|
@@ -329,7 +334,7 @@ module ContextDev
|
|
|
329
334
|
#
|
|
330
335
|
# @param max_pages [Integer] Maximum number of pages to track.
|
|
331
336
|
#
|
|
332
|
-
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It
|
|
337
|
+
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It is used three ways: it guides
|
|
333
338
|
#
|
|
334
339
|
# @param type [Symbol, :extract]
|
|
335
340
|
end
|
|
@@ -153,7 +153,7 @@ module ContextDev
|
|
|
153
153
|
# Detect exact changes. For page targets, this means visible text diffs. For sitemap targets, this means URL additions and removals.
|
|
154
154
|
variant :exact, -> { ContextDev::Models::MonitorCreateResponse::ChangeDetection::Exact }
|
|
155
155
|
|
|
156
|
-
# Detect meaning-level changes to
|
|
156
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or paraphrase-only differences. Which changes are meaningful is judged against the extract target's `instructions` (and `schema`, when provided).
|
|
157
157
|
variant :semantic, -> { ContextDev::Models::MonitorCreateResponse::ChangeDetection::Semantic }
|
|
158
158
|
|
|
159
159
|
class Exact < ContextDev::Internal::Type::BaseModel
|
|
@@ -181,9 +181,9 @@ module ContextDev
|
|
|
181
181
|
optional :confidence_threshold, Float
|
|
182
182
|
|
|
183
183
|
# @!method initialize(confidence_threshold: nil, type: :semantic)
|
|
184
|
-
# Detect meaning-level changes to
|
|
185
|
-
# paraphrase-only differences.
|
|
186
|
-
# target's `
|
|
184
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or
|
|
185
|
+
# paraphrase-only differences. Which changes are meaningful is judged against the
|
|
186
|
+
# extract target's `instructions` (and `schema`, when provided).
|
|
187
187
|
#
|
|
188
188
|
# @param confidence_threshold [Float]
|
|
189
189
|
# @param type [Symbol, :semantic]
|
|
@@ -295,7 +295,7 @@ module ContextDev
|
|
|
295
295
|
# 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. On a detected difference the sitemap is re-fetched within the same run and only URLs both observations agree on are reported, suppressing transient crawl flaps.
|
|
296
296
|
variant :sitemap, -> { ContextDev::Models::MonitorCreateResponse::Target::Sitemap }
|
|
297
297
|
|
|
298
|
-
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged against the monitor's instructions. The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
298
|
+
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged for relevance against the monitor's `instructions` (and `schema`, when provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
299
299
|
variant :extract, -> { ContextDev::Models::MonitorCreateResponse::Target::Extract }
|
|
300
300
|
|
|
301
301
|
class Page < ContextDev::Internal::Type::BaseModel
|
|
@@ -410,9 +410,14 @@ module ContextDev
|
|
|
410
410
|
optional :max_pages, Integer
|
|
411
411
|
|
|
412
412
|
# @!attribute schema
|
|
413
|
-
# JSON Schema describing the data you care about. It
|
|
414
|
-
# selected for tracking
|
|
415
|
-
#
|
|
413
|
+
# JSON Schema describing the data you care about. It is used three ways: it guides
|
|
414
|
+
# which pages are selected for tracking, it gives the change judge extra context
|
|
415
|
+
# on which changes matter (alongside `instructions`), and it defines the shape of
|
|
416
|
+
# the baseline `data` snapshot on GET /monitors/{monitor_id} (refreshed at most
|
|
417
|
+
# about once a day). It is not a response format for changes: change events and
|
|
418
|
+
# webhook payloads always contain diffs, summaries, and evidence excerpts — never
|
|
419
|
+
# data in this schema's shape. If omitted, a default summary + key-points schema
|
|
420
|
+
# is used.
|
|
416
421
|
#
|
|
417
422
|
# @return [Hash{Symbol=>Object}, nil]
|
|
418
423
|
optional :schema, ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]
|
|
@@ -424,8 +429,8 @@ module ContextDev
|
|
|
424
429
|
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl
|
|
425
430
|
# guided by `schema`/`instructions` selects up to `max_pages` relevant pages to
|
|
426
431
|
# track; each run re-checks exactly those pages, and confirmed content changes are
|
|
427
|
-
# judged against the monitor's instructions
|
|
428
|
-
# a periodic re-discovery crawl.
|
|
432
|
+
# judged for relevance against the monitor's `instructions` (and `schema`, when
|
|
433
|
+
# provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
429
434
|
#
|
|
430
435
|
# @param instructions [String] Natural-language instructions guiding which pages and facts to track and which c
|
|
431
436
|
#
|
|
@@ -437,7 +442,7 @@ module ContextDev
|
|
|
437
442
|
#
|
|
438
443
|
# @param max_pages [Integer] Maximum number of pages to track.
|
|
439
444
|
#
|
|
440
|
-
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It
|
|
445
|
+
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It is used three ways: it guides
|
|
441
446
|
#
|
|
442
447
|
# @param type [Symbol, :extract]
|
|
443
448
|
end
|
|
@@ -106,7 +106,16 @@ module ContextDev
|
|
|
106
106
|
# @return [Time, nil]
|
|
107
107
|
optional :started_at, Time, nil?: true
|
|
108
108
|
|
|
109
|
-
# @!
|
|
109
|
+
# @!attribute webhook_delivery
|
|
110
|
+
# The webhook delivery attempted for a change detected by this run. Omitted when
|
|
111
|
+
# no webhook was attempted, including historical runs created before delivery
|
|
112
|
+
# tracking was added.
|
|
113
|
+
#
|
|
114
|
+
# @return [ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery, nil]
|
|
115
|
+
optional :webhook_delivery,
|
|
116
|
+
-> { ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery }
|
|
117
|
+
|
|
118
|
+
# @!method initialize(id:, baseline_created:, change_detected:, change_detection_type:, credits_charged:, monitor_id:, run_type:, status:, target_type:, change_id: nil, completed_at: nil, error: nil, skip_reason: nil, started_at: nil, webhook_delivery: nil)
|
|
110
119
|
# Some parameter documentations has been truncated, see
|
|
111
120
|
# {ContextDev::Models::MonitorListAccountRunsResponse::Data} for more details.
|
|
112
121
|
#
|
|
@@ -137,6 +146,8 @@ module ContextDev
|
|
|
137
146
|
# @param skip_reason [Symbol, ContextDev::Models::MonitorListAccountRunsResponse::Data::SkipReason, nil] Why a skipped run never executed; null unless status is `skipped`.
|
|
138
147
|
#
|
|
139
148
|
# @param started_at [Time, nil]
|
|
149
|
+
#
|
|
150
|
+
# @param webhook_delivery [ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery] The webhook delivery attempted for a change detected by this run. Omitted when n
|
|
140
151
|
|
|
141
152
|
# @see ContextDev::Models::MonitorListAccountRunsResponse::Data#change_detection_type
|
|
142
153
|
module ChangeDetectionType
|
|
@@ -221,6 +232,96 @@ module ContextDev
|
|
|
221
232
|
# @!method self.values
|
|
222
233
|
# @return [Array<Symbol>]
|
|
223
234
|
end
|
|
235
|
+
|
|
236
|
+
# @see ContextDev::Models::MonitorListAccountRunsResponse::Data#webhook_delivery
|
|
237
|
+
class WebhookDelivery < ContextDev::Internal::Type::BaseModel
|
|
238
|
+
# @!attribute attempted_at
|
|
239
|
+
#
|
|
240
|
+
# @return [Time]
|
|
241
|
+
required :attempted_at, Time
|
|
242
|
+
|
|
243
|
+
# @!attribute error
|
|
244
|
+
#
|
|
245
|
+
# @return [ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Error, nil]
|
|
246
|
+
required :error,
|
|
247
|
+
-> { ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Error },
|
|
248
|
+
nil?: true
|
|
249
|
+
|
|
250
|
+
# @!attribute event_id
|
|
251
|
+
# Identifier sent in the X-Context-Id header.
|
|
252
|
+
#
|
|
253
|
+
# @return [String]
|
|
254
|
+
required :event_id, String
|
|
255
|
+
|
|
256
|
+
# @!attribute http_status
|
|
257
|
+
# The endpoint's final HTTP response status, or null when no response was
|
|
258
|
+
# received.
|
|
259
|
+
#
|
|
260
|
+
# @return [Integer, nil]
|
|
261
|
+
required :http_status, Integer, nil?: true
|
|
262
|
+
|
|
263
|
+
# @!attribute status
|
|
264
|
+
# Delivery outcome. delivered means any 2xx response; rejected means a non-2xx
|
|
265
|
+
# response; failed means no HTTP response was received; skipped_unsafe_url means
|
|
266
|
+
# the URL failed the public-endpoint safety check.
|
|
267
|
+
#
|
|
268
|
+
# @return [Symbol, ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Status]
|
|
269
|
+
required :status,
|
|
270
|
+
enum: -> { ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Status }
|
|
271
|
+
|
|
272
|
+
# @!method initialize(attempted_at:, error:, event_id:, http_status:, status:)
|
|
273
|
+
# Some parameter documentations has been truncated, see
|
|
274
|
+
# {ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery} for
|
|
275
|
+
# more details.
|
|
276
|
+
#
|
|
277
|
+
# The webhook delivery attempted for a change detected by this run. Omitted when
|
|
278
|
+
# no webhook was attempted, including historical runs created before delivery
|
|
279
|
+
# tracking was added.
|
|
280
|
+
#
|
|
281
|
+
# @param attempted_at [Time]
|
|
282
|
+
#
|
|
283
|
+
# @param error [ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Error, nil]
|
|
284
|
+
#
|
|
285
|
+
# @param event_id [String] Identifier sent in the X-Context-Id header.
|
|
286
|
+
#
|
|
287
|
+
# @param http_status [Integer, nil] The endpoint's final HTTP response status, or null when no response was received
|
|
288
|
+
#
|
|
289
|
+
# @param status [Symbol, ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery::Status] Delivery outcome. delivered means any 2xx response; rejected means a non-2xx res
|
|
290
|
+
|
|
291
|
+
# @see ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery#error
|
|
292
|
+
class Error < ContextDev::Internal::Type::BaseModel
|
|
293
|
+
# @!attribute code
|
|
294
|
+
#
|
|
295
|
+
# @return [String]
|
|
296
|
+
required :code, String
|
|
297
|
+
|
|
298
|
+
# @!attribute message
|
|
299
|
+
#
|
|
300
|
+
# @return [String]
|
|
301
|
+
required :message, String
|
|
302
|
+
|
|
303
|
+
# @!method initialize(code:, message:)
|
|
304
|
+
# @param code [String]
|
|
305
|
+
# @param message [String]
|
|
306
|
+
end
|
|
307
|
+
|
|
308
|
+
# Delivery outcome. delivered means any 2xx response; rejected means a non-2xx
|
|
309
|
+
# response; failed means no HTTP response was received; skipped_unsafe_url means
|
|
310
|
+
# the URL failed the public-endpoint safety check.
|
|
311
|
+
#
|
|
312
|
+
# @see ContextDev::Models::MonitorListAccountRunsResponse::Data::WebhookDelivery#status
|
|
313
|
+
module Status
|
|
314
|
+
extend ContextDev::Internal::Type::Enum
|
|
315
|
+
|
|
316
|
+
DELIVERED = :delivered
|
|
317
|
+
REJECTED = :rejected
|
|
318
|
+
FAILED = :failed
|
|
319
|
+
SKIPPED_UNSAFE_URL = :skipped_unsafe_url
|
|
320
|
+
|
|
321
|
+
# @!method self.values
|
|
322
|
+
# @return [Array<Symbol>]
|
|
323
|
+
end
|
|
324
|
+
end
|
|
224
325
|
end
|
|
225
326
|
end
|
|
226
327
|
end
|
|
@@ -174,7 +174,7 @@ module ContextDev
|
|
|
174
174
|
# Detect exact changes. For page targets, this means visible text diffs. For sitemap targets, this means URL additions and removals.
|
|
175
175
|
variant :exact, -> { ContextDev::Models::MonitorListResponse::Data::ChangeDetection::Exact }
|
|
176
176
|
|
|
177
|
-
# Detect meaning-level changes to
|
|
177
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or paraphrase-only differences. Which changes are meaningful is judged against the extract target's `instructions` (and `schema`, when provided).
|
|
178
178
|
variant :semantic, -> { ContextDev::Models::MonitorListResponse::Data::ChangeDetection::Semantic }
|
|
179
179
|
|
|
180
180
|
class Exact < ContextDev::Internal::Type::BaseModel
|
|
@@ -202,9 +202,9 @@ module ContextDev
|
|
|
202
202
|
optional :confidence_threshold, Float
|
|
203
203
|
|
|
204
204
|
# @!method initialize(confidence_threshold: nil, type: :semantic)
|
|
205
|
-
# Detect meaning-level changes to
|
|
206
|
-
# paraphrase-only differences.
|
|
207
|
-
# target's `
|
|
205
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or
|
|
206
|
+
# paraphrase-only differences. Which changes are meaningful is judged against the
|
|
207
|
+
# extract target's `instructions` (and `schema`, when provided).
|
|
208
208
|
#
|
|
209
209
|
# @param confidence_threshold [Float]
|
|
210
210
|
# @param type [Symbol, :semantic]
|
|
@@ -316,7 +316,7 @@ module ContextDev
|
|
|
316
316
|
# 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. On a detected difference the sitemap is re-fetched within the same run and only URLs both observations agree on are reported, suppressing transient crawl flaps.
|
|
317
317
|
variant :sitemap, -> { ContextDev::Models::MonitorListResponse::Data::Target::Sitemap }
|
|
318
318
|
|
|
319
|
-
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged against the monitor's instructions. The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
319
|
+
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged for relevance against the monitor's `instructions` (and `schema`, when provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
320
320
|
variant :extract, -> { ContextDev::Models::MonitorListResponse::Data::Target::Extract }
|
|
321
321
|
|
|
322
322
|
class Page < ContextDev::Internal::Type::BaseModel
|
|
@@ -431,9 +431,14 @@ module ContextDev
|
|
|
431
431
|
optional :max_pages, Integer
|
|
432
432
|
|
|
433
433
|
# @!attribute schema
|
|
434
|
-
# JSON Schema describing the data you care about. It
|
|
435
|
-
# selected for tracking
|
|
436
|
-
#
|
|
434
|
+
# JSON Schema describing the data you care about. It is used three ways: it guides
|
|
435
|
+
# which pages are selected for tracking, it gives the change judge extra context
|
|
436
|
+
# on which changes matter (alongside `instructions`), and it defines the shape of
|
|
437
|
+
# the baseline `data` snapshot on GET /monitors/{monitor_id} (refreshed at most
|
|
438
|
+
# about once a day). It is not a response format for changes: change events and
|
|
439
|
+
# webhook payloads always contain diffs, summaries, and evidence excerpts — never
|
|
440
|
+
# data in this schema's shape. If omitted, a default summary + key-points schema
|
|
441
|
+
# is used.
|
|
437
442
|
#
|
|
438
443
|
# @return [Hash{Symbol=>Object}, nil]
|
|
439
444
|
optional :schema, ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]
|
|
@@ -446,8 +451,8 @@ module ContextDev
|
|
|
446
451
|
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl
|
|
447
452
|
# guided by `schema`/`instructions` selects up to `max_pages` relevant pages to
|
|
448
453
|
# track; each run re-checks exactly those pages, and confirmed content changes are
|
|
449
|
-
# judged against the monitor's instructions
|
|
450
|
-
# a periodic re-discovery crawl.
|
|
454
|
+
# judged for relevance against the monitor's `instructions` (and `schema`, when
|
|
455
|
+
# provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
451
456
|
#
|
|
452
457
|
# @param instructions [String] Natural-language instructions guiding which pages and facts to track and which c
|
|
453
458
|
#
|
|
@@ -459,7 +464,7 @@ module ContextDev
|
|
|
459
464
|
#
|
|
460
465
|
# @param max_pages [Integer] Maximum number of pages to track.
|
|
461
466
|
#
|
|
462
|
-
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It
|
|
467
|
+
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It is used three ways: it guides
|
|
463
468
|
#
|
|
464
469
|
# @param type [Symbol, :extract]
|
|
465
470
|
end
|
|
@@ -106,7 +106,15 @@ module ContextDev
|
|
|
106
106
|
# @return [Time, nil]
|
|
107
107
|
optional :started_at, Time, nil?: true
|
|
108
108
|
|
|
109
|
-
# @!
|
|
109
|
+
# @!attribute webhook_delivery
|
|
110
|
+
# The webhook delivery attempted for a change detected by this run. Omitted when
|
|
111
|
+
# no webhook was attempted, including historical runs created before delivery
|
|
112
|
+
# tracking was added.
|
|
113
|
+
#
|
|
114
|
+
# @return [ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery, nil]
|
|
115
|
+
optional :webhook_delivery, -> { ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery }
|
|
116
|
+
|
|
117
|
+
# @!method initialize(id:, baseline_created:, change_detected:, change_detection_type:, credits_charged:, monitor_id:, run_type:, status:, target_type:, change_id: nil, completed_at: nil, error: nil, skip_reason: nil, started_at: nil, webhook_delivery: nil)
|
|
110
118
|
# Some parameter documentations has been truncated, see
|
|
111
119
|
# {ContextDev::Models::MonitorListRunsResponse::Data} for more details.
|
|
112
120
|
#
|
|
@@ -137,6 +145,8 @@ module ContextDev
|
|
|
137
145
|
# @param skip_reason [Symbol, ContextDev::Models::MonitorListRunsResponse::Data::SkipReason, nil] Why a skipped run never executed; null unless status is `skipped`.
|
|
138
146
|
#
|
|
139
147
|
# @param started_at [Time, nil]
|
|
148
|
+
#
|
|
149
|
+
# @param webhook_delivery [ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery] The webhook delivery attempted for a change detected by this run. Omitted when n
|
|
140
150
|
|
|
141
151
|
# @see ContextDev::Models::MonitorListRunsResponse::Data#change_detection_type
|
|
142
152
|
module ChangeDetectionType
|
|
@@ -221,6 +231,95 @@ module ContextDev
|
|
|
221
231
|
# @!method self.values
|
|
222
232
|
# @return [Array<Symbol>]
|
|
223
233
|
end
|
|
234
|
+
|
|
235
|
+
# @see ContextDev::Models::MonitorListRunsResponse::Data#webhook_delivery
|
|
236
|
+
class WebhookDelivery < ContextDev::Internal::Type::BaseModel
|
|
237
|
+
# @!attribute attempted_at
|
|
238
|
+
#
|
|
239
|
+
# @return [Time]
|
|
240
|
+
required :attempted_at, Time
|
|
241
|
+
|
|
242
|
+
# @!attribute error
|
|
243
|
+
#
|
|
244
|
+
# @return [ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Error, nil]
|
|
245
|
+
required :error,
|
|
246
|
+
-> { ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Error },
|
|
247
|
+
nil?: true
|
|
248
|
+
|
|
249
|
+
# @!attribute event_id
|
|
250
|
+
# Identifier sent in the X-Context-Id header.
|
|
251
|
+
#
|
|
252
|
+
# @return [String]
|
|
253
|
+
required :event_id, String
|
|
254
|
+
|
|
255
|
+
# @!attribute http_status
|
|
256
|
+
# The endpoint's final HTTP response status, or null when no response was
|
|
257
|
+
# received.
|
|
258
|
+
#
|
|
259
|
+
# @return [Integer, nil]
|
|
260
|
+
required :http_status, Integer, nil?: true
|
|
261
|
+
|
|
262
|
+
# @!attribute status
|
|
263
|
+
# Delivery outcome. delivered means any 2xx response; rejected means a non-2xx
|
|
264
|
+
# response; failed means no HTTP response was received; skipped_unsafe_url means
|
|
265
|
+
# the URL failed the public-endpoint safety check.
|
|
266
|
+
#
|
|
267
|
+
# @return [Symbol, ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Status]
|
|
268
|
+
required :status, enum: -> { ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Status }
|
|
269
|
+
|
|
270
|
+
# @!method initialize(attempted_at:, error:, event_id:, http_status:, status:)
|
|
271
|
+
# Some parameter documentations has been truncated, see
|
|
272
|
+
# {ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery} for more
|
|
273
|
+
# details.
|
|
274
|
+
#
|
|
275
|
+
# The webhook delivery attempted for a change detected by this run. Omitted when
|
|
276
|
+
# no webhook was attempted, including historical runs created before delivery
|
|
277
|
+
# tracking was added.
|
|
278
|
+
#
|
|
279
|
+
# @param attempted_at [Time]
|
|
280
|
+
#
|
|
281
|
+
# @param error [ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Error, nil]
|
|
282
|
+
#
|
|
283
|
+
# @param event_id [String] Identifier sent in the X-Context-Id header.
|
|
284
|
+
#
|
|
285
|
+
# @param http_status [Integer, nil] The endpoint's final HTTP response status, or null when no response was received
|
|
286
|
+
#
|
|
287
|
+
# @param status [Symbol, ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery::Status] Delivery outcome. delivered means any 2xx response; rejected means a non-2xx res
|
|
288
|
+
|
|
289
|
+
# @see ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery#error
|
|
290
|
+
class Error < ContextDev::Internal::Type::BaseModel
|
|
291
|
+
# @!attribute code
|
|
292
|
+
#
|
|
293
|
+
# @return [String]
|
|
294
|
+
required :code, String
|
|
295
|
+
|
|
296
|
+
# @!attribute message
|
|
297
|
+
#
|
|
298
|
+
# @return [String]
|
|
299
|
+
required :message, String
|
|
300
|
+
|
|
301
|
+
# @!method initialize(code:, message:)
|
|
302
|
+
# @param code [String]
|
|
303
|
+
# @param message [String]
|
|
304
|
+
end
|
|
305
|
+
|
|
306
|
+
# Delivery outcome. delivered means any 2xx response; rejected means a non-2xx
|
|
307
|
+
# response; failed means no HTTP response was received; skipped_unsafe_url means
|
|
308
|
+
# the URL failed the public-endpoint safety check.
|
|
309
|
+
#
|
|
310
|
+
# @see ContextDev::Models::MonitorListRunsResponse::Data::WebhookDelivery#status
|
|
311
|
+
module Status
|
|
312
|
+
extend ContextDev::Internal::Type::Enum
|
|
313
|
+
|
|
314
|
+
DELIVERED = :delivered
|
|
315
|
+
REJECTED = :rejected
|
|
316
|
+
FAILED = :failed
|
|
317
|
+
SKIPPED_UNSAFE_URL = :skipped_unsafe_url
|
|
318
|
+
|
|
319
|
+
# @!method self.values
|
|
320
|
+
# @return [Array<Symbol>]
|
|
321
|
+
end
|
|
322
|
+
end
|
|
224
323
|
end
|
|
225
324
|
end
|
|
226
325
|
end
|
|
@@ -153,7 +153,7 @@ module ContextDev
|
|
|
153
153
|
# Detect exact changes. For page targets, this means visible text diffs. For sitemap targets, this means URL additions and removals.
|
|
154
154
|
variant :exact, -> { ContextDev::Models::MonitorRetrieveResponse::ChangeDetection::Exact }
|
|
155
155
|
|
|
156
|
-
# Detect meaning-level changes to
|
|
156
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or paraphrase-only differences. Which changes are meaningful is judged against the extract target's `instructions` (and `schema`, when provided).
|
|
157
157
|
variant :semantic, -> { ContextDev::Models::MonitorRetrieveResponse::ChangeDetection::Semantic }
|
|
158
158
|
|
|
159
159
|
class Exact < ContextDev::Internal::Type::BaseModel
|
|
@@ -181,9 +181,9 @@ module ContextDev
|
|
|
181
181
|
optional :confidence_threshold, Float
|
|
182
182
|
|
|
183
183
|
# @!method initialize(confidence_threshold: nil, type: :semantic)
|
|
184
|
-
# Detect meaning-level changes to
|
|
185
|
-
# paraphrase-only differences.
|
|
186
|
-
# target's `
|
|
184
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or
|
|
185
|
+
# paraphrase-only differences. Which changes are meaningful is judged against the
|
|
186
|
+
# extract target's `instructions` (and `schema`, when provided).
|
|
187
187
|
#
|
|
188
188
|
# @param confidence_threshold [Float]
|
|
189
189
|
# @param type [Symbol, :semantic]
|
|
@@ -295,7 +295,7 @@ module ContextDev
|
|
|
295
295
|
# 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. On a detected difference the sitemap is re-fetched within the same run and only URLs both observations agree on are reported, suppressing transient crawl flaps.
|
|
296
296
|
variant :sitemap, -> { ContextDev::Models::MonitorRetrieveResponse::Target::Sitemap }
|
|
297
297
|
|
|
298
|
-
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged against the monitor's instructions. The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
298
|
+
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged for relevance against the monitor's `instructions` (and `schema`, when provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
299
299
|
variant :extract, -> { ContextDev::Models::MonitorRetrieveResponse::Target::Extract }
|
|
300
300
|
|
|
301
301
|
class Page < ContextDev::Internal::Type::BaseModel
|
|
@@ -410,9 +410,14 @@ module ContextDev
|
|
|
410
410
|
optional :max_pages, Integer
|
|
411
411
|
|
|
412
412
|
# @!attribute schema
|
|
413
|
-
# JSON Schema describing the data you care about. It
|
|
414
|
-
# selected for tracking
|
|
415
|
-
#
|
|
413
|
+
# JSON Schema describing the data you care about. It is used three ways: it guides
|
|
414
|
+
# which pages are selected for tracking, it gives the change judge extra context
|
|
415
|
+
# on which changes matter (alongside `instructions`), and it defines the shape of
|
|
416
|
+
# the baseline `data` snapshot on GET /monitors/{monitor_id} (refreshed at most
|
|
417
|
+
# about once a day). It is not a response format for changes: change events and
|
|
418
|
+
# webhook payloads always contain diffs, summaries, and evidence excerpts — never
|
|
419
|
+
# data in this schema's shape. If omitted, a default summary + key-points schema
|
|
420
|
+
# is used.
|
|
416
421
|
#
|
|
417
422
|
# @return [Hash{Symbol=>Object}, nil]
|
|
418
423
|
optional :schema, ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]
|
|
@@ -424,8 +429,8 @@ module ContextDev
|
|
|
424
429
|
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl
|
|
425
430
|
# guided by `schema`/`instructions` selects up to `max_pages` relevant pages to
|
|
426
431
|
# track; each run re-checks exactly those pages, and confirmed content changes are
|
|
427
|
-
# judged against the monitor's instructions
|
|
428
|
-
# a periodic re-discovery crawl.
|
|
432
|
+
# judged for relevance against the monitor's `instructions` (and `schema`, when
|
|
433
|
+
# provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
429
434
|
#
|
|
430
435
|
# @param instructions [String] Natural-language instructions guiding which pages and facts to track and which c
|
|
431
436
|
#
|
|
@@ -437,7 +442,7 @@ module ContextDev
|
|
|
437
442
|
#
|
|
438
443
|
# @param max_pages [Integer] Maximum number of pages to track.
|
|
439
444
|
#
|
|
440
|
-
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It
|
|
445
|
+
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It is used three ways: it guides
|
|
441
446
|
#
|
|
442
447
|
# @param type [Symbol, :extract]
|
|
443
448
|
end
|
|
@@ -85,7 +85,7 @@ module ContextDev
|
|
|
85
85
|
# Detect exact changes. For page targets, this means visible text diffs. For sitemap targets, this means URL additions and removals.
|
|
86
86
|
variant :exact, -> { ContextDev::MonitorUpdateParams::ChangeDetection::Exact }
|
|
87
87
|
|
|
88
|
-
# Detect meaning-level changes to
|
|
88
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or paraphrase-only differences. Which changes are meaningful is judged against the extract target's `instructions` (and `schema`, when provided).
|
|
89
89
|
variant :semantic, -> { ContextDev::MonitorUpdateParams::ChangeDetection::Semantic }
|
|
90
90
|
|
|
91
91
|
class Exact < ContextDev::Internal::Type::BaseModel
|
|
@@ -113,9 +113,9 @@ module ContextDev
|
|
|
113
113
|
optional :confidence_threshold, Float
|
|
114
114
|
|
|
115
115
|
# @!method initialize(confidence_threshold: nil, type: :semantic)
|
|
116
|
-
# Detect meaning-level changes to
|
|
117
|
-
# paraphrase-only differences.
|
|
118
|
-
# target's `
|
|
116
|
+
# Detect meaning-level changes to tracked page content, ignoring cosmetic or
|
|
117
|
+
# paraphrase-only differences. Which changes are meaningful is judged against the
|
|
118
|
+
# extract target's `instructions` (and `schema`, when provided).
|
|
119
119
|
#
|
|
120
120
|
# @param confidence_threshold [Float]
|
|
121
121
|
# @param type [Symbol, :semantic]
|
|
@@ -203,7 +203,7 @@ module ContextDev
|
|
|
203
203
|
# 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. On a detected difference the sitemap is re-fetched within the same run and only URLs both observations agree on are reported, suppressing transient crawl flaps.
|
|
204
204
|
variant :sitemap, -> { ContextDev::MonitorUpdateParams::Target::Sitemap }
|
|
205
205
|
|
|
206
|
-
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged against the monitor's instructions. The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
206
|
+
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl guided by `schema`/`instructions` selects up to `max_pages` relevant pages to track; each run re-checks exactly those pages, and confirmed content changes are judged for relevance against the monitor's `instructions` (and `schema`, when provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
207
207
|
variant :extract, -> { ContextDev::MonitorUpdateParams::Target::Extract }
|
|
208
208
|
|
|
209
209
|
class Page < ContextDev::Internal::Type::BaseModel
|
|
@@ -318,9 +318,14 @@ module ContextDev
|
|
|
318
318
|
optional :max_pages, Integer
|
|
319
319
|
|
|
320
320
|
# @!attribute schema
|
|
321
|
-
# JSON Schema describing the data you care about. It
|
|
322
|
-
# selected for tracking
|
|
323
|
-
#
|
|
321
|
+
# JSON Schema describing the data you care about. It is used three ways: it guides
|
|
322
|
+
# which pages are selected for tracking, it gives the change judge extra context
|
|
323
|
+
# on which changes matter (alongside `instructions`), and it defines the shape of
|
|
324
|
+
# the baseline `data` snapshot on GET /monitors/{monitor_id} (refreshed at most
|
|
325
|
+
# about once a day). It is not a response format for changes: change events and
|
|
326
|
+
# webhook payloads always contain diffs, summaries, and evidence excerpts — never
|
|
327
|
+
# data in this schema's shape. If omitted, a default summary + key-points schema
|
|
328
|
+
# is used.
|
|
324
329
|
#
|
|
325
330
|
# @return [Hash{Symbol=>Object}, nil]
|
|
326
331
|
optional :schema, ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]
|
|
@@ -332,8 +337,8 @@ module ContextDev
|
|
|
332
337
|
# Watch the monitor-relevant pages of a site for meaningful changes. A crawl
|
|
333
338
|
# guided by `schema`/`instructions` selects up to `max_pages` relevant pages to
|
|
334
339
|
# track; each run re-checks exactly those pages, and confirmed content changes are
|
|
335
|
-
# judged against the monitor's instructions
|
|
336
|
-
# a periodic re-discovery crawl.
|
|
340
|
+
# judged for relevance against the monitor's `instructions` (and `schema`, when
|
|
341
|
+
# provided). The tracked page set is refreshed by a periodic re-discovery crawl.
|
|
337
342
|
#
|
|
338
343
|
# @param instructions [String] Natural-language instructions guiding which pages and facts to track and which c
|
|
339
344
|
#
|
|
@@ -345,7 +350,7 @@ module ContextDev
|
|
|
345
350
|
#
|
|
346
351
|
# @param max_pages [Integer] Maximum number of pages to track.
|
|
347
352
|
#
|
|
348
|
-
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It
|
|
353
|
+
# @param schema [Hash{Symbol=>Object}] JSON Schema describing the data you care about. It is used three ways: it guides
|
|
349
354
|
#
|
|
350
355
|
# @param type [Symbol, :extract]
|
|
351
356
|
end
|