context.dev 1.32.0 → 1.34.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 84c6c1d646faa0e2b50484631fd24d94e14a3922f768cf5fbe22bdd829d9e0cf
4
- data.tar.gz: 8ea87eb1159e215732cc1c8b6344be0ed139712e2cff821dcca00406ce35d5b0
3
+ metadata.gz: fd17c0a5c6f2ce8e8539a2173689b2013c87fbaba2cceedc66594c51d9289f2b
4
+ data.tar.gz: 6db4666ba083805420a21d4d6bc9094df09fa3175e7773423e612442e34e2ae0
5
5
  SHA512:
6
- metadata.gz: ecf08bc1935ccfa130092a303ef4f25ed6c1a776703fcb85b9fbb411897cefe18aeaca4c44bae016f264f4f69e2a08a00c1b8bdf3bb4b14c388cc80c289d36c2
7
- data.tar.gz: ae6c0aeff49f2c3c4419e22949fe02ecc6861102221acd2dddcf88bd49daef2ae0f33af30b871430ba141bac75a7b1b727deba7def727f0d92a49b7e771918c9
6
+ metadata.gz: c191886c414c10297b0b53fb6f10317183db917af443628ec65b16edbca1067e4258f7e992f0e1b61afe27a85da4f69a88284a9911917c7b4e6c4b545b3ca591
7
+ data.tar.gz: 3942beaa1e6fe0113a3ecf025531876a3b90fc0fb92658986062b0205b603cc7c1ac5900b1ee690b6b24f125e9555d7103deabe94e6c51da3d33801b3ee49004
data/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.34.0 (2026-06-19)
4
+
5
+ Full Changelog: [v1.33.0...v1.34.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v1.33.0...v1.34.0)
6
+
7
+ ### Features
8
+
9
+ * **api:** api update ([94469da](https://github.com/context-dot-dev/context-ruby-sdk/commit/94469da02de1d8713f5bcb723cab05f0e23bb33d))
10
+
11
+ ## 1.33.0 (2026-06-18)
12
+
13
+ Full Changelog: [v1.32.0...v1.33.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v1.32.0...v1.33.0)
14
+
15
+ ### Features
16
+
17
+ * **api:** api update ([65310de](https://github.com/context-dot-dev/context-ruby-sdk/commit/65310de1d9739b217660fc4ab8e5462bc5a0f081))
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * **client:** send content-type header for requests with an omitted optional body ([63d0f66](https://github.com/context-dot-dev/context-ruby-sdk/commit/63d0f66c1d871786bf80989b7a8ad11b859ec12a))
23
+
3
24
  ## 1.32.0 (2026-06-11)
4
25
 
5
26
  Full Changelog: [v1.31.0...v1.32.0](https://github.com/context-dot-dev/context-ruby-sdk/compare/v1.31.0...v1.32.0)
data/README.md CHANGED
@@ -26,7 +26,7 @@ To use this gem, install via Bundler by adding the following to your application
26
26
  <!-- x-release-please-start-version -->
27
27
 
28
28
  ```ruby
29
- gem "context.dev", "~> 1.32.0"
29
+ gem "context.dev", "~> 1.34.0"
30
30
  ```
31
31
 
32
32
  <!-- x-release-please-end -->
@@ -306,7 +306,10 @@ module ContextDev
306
306
  ContextDev::Internal::Util.deep_merge(*[req[:body], opts[:extra_body]].compact)
307
307
  end
308
308
 
309
- headers.delete("content-type") if body.nil?
309
+ # Generated methods always pass `req[:body]` for operations that define a
310
+ # request body, so only elide the content-type header when the operation
311
+ # has no body at all, not when an optional body param was omitted.
312
+ headers.delete("content-type") if body.nil? && !req.key?(:body)
310
313
 
311
314
  url = ContextDev::Internal::Util.join_parsed_uri(
312
315
  @base_url_components,
@@ -105,6 +105,19 @@ module ContextDev
105
105
  # @return [Integer]
106
106
  required :crawl_depth, Integer, api_name: :crawlDepth
107
107
 
108
+ # @!attribute final_url
109
+ # Final URL scraped after redirects or scraper fallback, when known. Falls back to
110
+ # sourceUrl when unavailable.
111
+ #
112
+ # @return [String]
113
+ required :final_url, String, api_name: :finalUrl
114
+
115
+ # @!attribute source_url
116
+ # Original URL requested by the caller.
117
+ #
118
+ # @return [String]
119
+ required :source_url, String, api_name: :sourceUrl
120
+
108
121
  # @!attribute status_code
109
122
  # HTTP status code of the response
110
123
  #
@@ -118,27 +131,247 @@ module ContextDev
118
131
  required :success, ContextDev::Internal::Type::Boolean
119
132
 
120
133
  # @!attribute title
121
- # The page's <title> content (empty string if unavailable)
134
+ # Best page title extracted from the page (empty string if unavailable).
122
135
  #
123
136
  # @return [String]
124
137
  required :title, String
125
138
 
126
139
  # @!attribute url
127
- # The URL that was fetched
140
+ # The crawl URL fetched for this page.
128
141
  #
129
142
  # @return [String]
130
143
  required :url, String
131
144
 
132
- # @!method initialize(crawl_depth:, status_code:, success:, title:, url:)
145
+ # @!attribute additional_meta
146
+ # Additional non-social meta tags not promoted to top-level metadata fields.
147
+ #
148
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
149
+ optional :additional_meta,
150
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::AdditionalMeta] },
151
+ api_name: :additionalMeta
152
+
153
+ # @!attribute alternates
154
+ # Resolved alternate links from link rel=alternate tags.
155
+ #
156
+ # @return [Array<ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::Alternate>, nil]
157
+ optional :alternates,
158
+ -> { ContextDev::Internal::Type::ArrayOf[ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::Alternate] }
159
+
160
+ # @!attribute author
161
+ # Author metadata, when present.
162
+ #
163
+ # @return [String, nil]
164
+ optional :author, String
165
+
166
+ # @!attribute canonical_url
167
+ # Resolved canonical URL, when present.
168
+ #
169
+ # @return [String, nil]
170
+ optional :canonical_url, String, api_name: :canonicalUrl
171
+
172
+ # @!attribute description
173
+ # Best description extracted from standard, Open Graph, or Twitter metadata.
174
+ #
175
+ # @return [String, nil]
176
+ optional :description, String
177
+
178
+ # @!attribute favicon
179
+ # Resolved favicon URL, when present.
180
+ #
181
+ # @return [String, nil]
182
+ optional :favicon, String
183
+
184
+ # @!attribute image
185
+ # Primary resolved preview image from Open Graph, Twitter, or image metadata.
186
+ #
187
+ # @return [String, nil]
188
+ optional :image, String
189
+
190
+ # @!attribute json_ld
191
+ # JSON-LD structured data blocks parsed from the page.
192
+ #
193
+ # @return [Array<Hash{Symbol=>Object}>, nil]
194
+ optional :json_ld,
195
+ ContextDev::Internal::Type::ArrayOf[ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]],
196
+ api_name: :jsonLd
197
+
198
+ # @!attribute keywords
199
+ # Keywords extracted from the page's keywords meta tag.
200
+ #
201
+ # @return [Array<String>, nil]
202
+ optional :keywords, ContextDev::Internal::Type::ArrayOf[String]
203
+
204
+ # @!attribute language
205
+ # Language extracted from html lang or language meta tags.
206
+ #
207
+ # @return [String, nil]
208
+ optional :language, String
209
+
210
+ # @!attribute modified_time
211
+ # Modified timestamp/date from page metadata, when present.
212
+ #
213
+ # @return [String, nil]
214
+ optional :modified_time, String, api_name: :modifiedTime
215
+
216
+ # @!attribute open_graph
217
+ # Open Graph metadata with the og: prefix removed and keys camel-cased.
218
+ #
219
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
220
+ optional :open_graph,
221
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::OpenGraph] },
222
+ api_name: :openGraph
223
+
224
+ # @!attribute published_time
225
+ # Published timestamp/date from page metadata, when present.
226
+ #
227
+ # @return [String, nil]
228
+ optional :published_time, String, api_name: :publishedTime
229
+
230
+ # @!attribute robots
231
+ # Robots meta directive, when present.
232
+ #
233
+ # @return [String, nil]
234
+ optional :robots, String
235
+
236
+ # @!attribute site_name
237
+ # Site or application name from page metadata.
238
+ #
239
+ # @return [String, nil]
240
+ optional :site_name, String, api_name: :siteName
241
+
242
+ # @!attribute twitter
243
+ # Twitter card metadata with the twitter: prefix removed and keys camel-cased.
244
+ #
245
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
246
+ optional :twitter,
247
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::Twitter] }
248
+
249
+ # @!method initialize(crawl_depth:, final_url:, source_url:, status_code:, success:, title:, url:, additional_meta: nil, alternates: nil, author: nil, canonical_url: nil, description: nil, favicon: nil, image: nil, json_ld: nil, keywords: nil, language: nil, modified_time: nil, open_graph: nil, published_time: nil, robots: nil, site_name: nil, twitter: nil)
250
+ # Some parameter documentations has been truncated, see
251
+ # {ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata} for more details.
252
+ #
133
253
  # @param crawl_depth [Integer] Depth relative to the start URL. 0 = start URL, 1 = one link away.
134
254
  #
255
+ # @param final_url [String] Final URL scraped after redirects or scraper fallback, when known. Falls back to
256
+ #
257
+ # @param source_url [String] Original URL requested by the caller.
258
+ #
135
259
  # @param status_code [Integer] HTTP status code of the response
136
260
  #
137
261
  # @param success [Boolean] true if the page was fetched and parsed successfully
138
262
  #
139
- # @param title [String] The page's <title> content (empty string if unavailable)
263
+ # @param title [String] Best page title extracted from the page (empty string if unavailable).
264
+ #
265
+ # @param url [String] The crawl URL fetched for this page.
266
+ #
267
+ # @param additional_meta [Hash{Symbol=>String, Array<String>}] Additional non-social meta tags not promoted to top-level metadata fields.
268
+ #
269
+ # @param alternates [Array<ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::Alternate>] Resolved alternate links from link rel=alternate tags.
270
+ #
271
+ # @param author [String] Author metadata, when present.
272
+ #
273
+ # @param canonical_url [String] Resolved canonical URL, when present.
274
+ #
275
+ # @param description [String] Best description extracted from standard, Open Graph, or Twitter metadata.
276
+ #
277
+ # @param favicon [String] Resolved favicon URL, when present.
278
+ #
279
+ # @param image [String] Primary resolved preview image from Open Graph, Twitter, or image metadata.
140
280
  #
141
- # @param url [String] The URL that was fetched
281
+ # @param json_ld [Array<Hash{Symbol=>Object}>] JSON-LD structured data blocks parsed from the page.
282
+ #
283
+ # @param keywords [Array<String>] Keywords extracted from the page's keywords meta tag.
284
+ #
285
+ # @param language [String] Language extracted from html lang or language meta tags.
286
+ #
287
+ # @param modified_time [String] Modified timestamp/date from page metadata, when present.
288
+ #
289
+ # @param open_graph [Hash{Symbol=>String, Array<String>}] Open Graph metadata with the og: prefix removed and keys camel-cased.
290
+ #
291
+ # @param published_time [String] Published timestamp/date from page metadata, when present.
292
+ #
293
+ # @param robots [String] Robots meta directive, when present.
294
+ #
295
+ # @param site_name [String] Site or application name from page metadata.
296
+ #
297
+ # @param twitter [Hash{Symbol=>String, Array<String>}] Twitter card metadata with the twitter: prefix removed and keys camel-cased.
298
+
299
+ module AdditionalMeta
300
+ extend ContextDev::Internal::Type::Union
301
+
302
+ variant String
303
+
304
+ variant -> { ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::AdditionalMeta::StringArray }
305
+
306
+ # @!method self.variants
307
+ # @return [Array(String, Array<String>)]
308
+
309
+ # @type [ContextDev::Internal::Type::Converter]
310
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
311
+ end
312
+
313
+ class Alternate < ContextDev::Internal::Type::BaseModel
314
+ # @!attribute href
315
+ # Resolved alternate URL.
316
+ #
317
+ # @return [String]
318
+ required :href, String
319
+
320
+ # @!attribute hreflang
321
+ # Language or locale for the alternate URL, when present.
322
+ #
323
+ # @return [String, nil]
324
+ optional :hreflang, String
325
+
326
+ # @!attribute title
327
+ # Alternate resource title, when present.
328
+ #
329
+ # @return [String, nil]
330
+ optional :title, String
331
+
332
+ # @!attribute type
333
+ # Alternate resource MIME type, when present.
334
+ #
335
+ # @return [String, nil]
336
+ optional :type, String
337
+
338
+ # @!method initialize(href:, hreflang: nil, title: nil, type: nil)
339
+ # @param href [String] Resolved alternate URL.
340
+ #
341
+ # @param hreflang [String] Language or locale for the alternate URL, when present.
342
+ #
343
+ # @param title [String] Alternate resource title, when present.
344
+ #
345
+ # @param type [String] Alternate resource MIME type, when present.
346
+ end
347
+
348
+ module OpenGraph
349
+ extend ContextDev::Internal::Type::Union
350
+
351
+ variant String
352
+
353
+ variant -> { ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::OpenGraph::StringArray }
354
+
355
+ # @!method self.variants
356
+ # @return [Array(String, Array<String>)]
357
+
358
+ # @type [ContextDev::Internal::Type::Converter]
359
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
360
+ end
361
+
362
+ module Twitter
363
+ extend ContextDev::Internal::Type::Union
364
+
365
+ variant String
366
+
367
+ variant -> { ContextDev::Models::WebWebCrawlMdResponse::Result::Metadata::Twitter::StringArray }
368
+
369
+ # @!method self.variants
370
+ # @return [Array(String, Array<String>)]
371
+
372
+ # @type [ContextDev::Internal::Type::Converter]
373
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
374
+ end
142
375
  end
143
376
  end
144
377
 
@@ -12,6 +12,12 @@ module ContextDev
12
12
  # @return [String]
13
13
  required :html, String
14
14
 
15
+ # @!attribute metadata
16
+ # Metadata extracted from the scraped page HTML.
17
+ #
18
+ # @return [ContextDev::Models::WebWebScrapeHTMLResponse::Metadata]
19
+ required :metadata, -> { ContextDev::Models::WebWebScrapeHTMLResponse::Metadata }
20
+
15
21
  # @!attribute success
16
22
  # Indicates success
17
23
  #
@@ -38,12 +44,14 @@ module ContextDev
38
44
  # @return [ContextDev::Models::WebWebScrapeHTMLResponse::KeyMetadata, nil]
39
45
  optional :key_metadata, -> { ContextDev::Models::WebWebScrapeHTMLResponse::KeyMetadata }
40
46
 
41
- # @!method initialize(html:, success:, type:, url:, key_metadata: nil)
47
+ # @!method initialize(html:, metadata:, success:, type:, url:, key_metadata: nil)
42
48
  # Some parameter documentations has been truncated, see
43
49
  # {ContextDev::Models::WebWebScrapeHTMLResponse} for more details.
44
50
  #
45
51
  # @param html [String] The scraped content of the page. For normal pages this is the raw HTML. When the
46
52
  #
53
+ # @param metadata [ContextDev::Models::WebWebScrapeHTMLResponse::Metadata] Metadata extracted from the scraped page HTML.
54
+ #
47
55
  # @param success [Boolean, ContextDev::Models::WebWebScrapeHTMLResponse::Success] Indicates success
48
56
  #
49
57
  # @param type [Symbol, ContextDev::Models::WebWebScrapeHTMLResponse::Type] Detected content type of the returned `html` field. Sitemaps and feeds are surfa
@@ -52,6 +60,253 @@ module ContextDev
52
60
  #
53
61
  # @param key_metadata [ContextDev::Models::WebWebScrapeHTMLResponse::KeyMetadata] Metadata about the API key used for the request. Included in every response when
54
62
 
63
+ # @see ContextDev::Models::WebWebScrapeHTMLResponse#metadata
64
+ class Metadata < ContextDev::Internal::Type::BaseModel
65
+ # @!attribute final_url
66
+ # Final URL scraped after redirects or scraper fallback, when known. Falls back to
67
+ # sourceUrl when unavailable.
68
+ #
69
+ # @return [String]
70
+ required :final_url, String, api_name: :finalUrl
71
+
72
+ # @!attribute source_url
73
+ # Original URL requested by the caller.
74
+ #
75
+ # @return [String]
76
+ required :source_url, String, api_name: :sourceUrl
77
+
78
+ # @!attribute additional_meta
79
+ # Additional non-social meta tags not promoted to top-level metadata fields.
80
+ #
81
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
82
+ optional :additional_meta,
83
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::AdditionalMeta] },
84
+ api_name: :additionalMeta
85
+
86
+ # @!attribute alternates
87
+ # Resolved alternate links from link rel=alternate tags.
88
+ #
89
+ # @return [Array<ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::Alternate>, nil]
90
+ optional :alternates,
91
+ -> { ContextDev::Internal::Type::ArrayOf[ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::Alternate] }
92
+
93
+ # @!attribute author
94
+ # Author metadata, when present.
95
+ #
96
+ # @return [String, nil]
97
+ optional :author, String
98
+
99
+ # @!attribute canonical_url
100
+ # Resolved canonical URL, when present.
101
+ #
102
+ # @return [String, nil]
103
+ optional :canonical_url, String, api_name: :canonicalUrl
104
+
105
+ # @!attribute description
106
+ # Best description extracted from standard, Open Graph, or Twitter metadata.
107
+ #
108
+ # @return [String, nil]
109
+ optional :description, String
110
+
111
+ # @!attribute favicon
112
+ # Resolved favicon URL, when present.
113
+ #
114
+ # @return [String, nil]
115
+ optional :favicon, String
116
+
117
+ # @!attribute image
118
+ # Primary resolved preview image from Open Graph, Twitter, or image metadata.
119
+ #
120
+ # @return [String, nil]
121
+ optional :image, String
122
+
123
+ # @!attribute json_ld
124
+ # JSON-LD structured data blocks parsed from the page.
125
+ #
126
+ # @return [Array<Hash{Symbol=>Object}>, nil]
127
+ optional :json_ld,
128
+ ContextDev::Internal::Type::ArrayOf[ContextDev::Internal::Type::HashOf[ContextDev::Internal::Type::Unknown]],
129
+ api_name: :jsonLd
130
+
131
+ # @!attribute keywords
132
+ # Keywords extracted from the page's keywords meta tag.
133
+ #
134
+ # @return [Array<String>, nil]
135
+ optional :keywords, ContextDev::Internal::Type::ArrayOf[String]
136
+
137
+ # @!attribute language
138
+ # Language extracted from html lang or language meta tags.
139
+ #
140
+ # @return [String, nil]
141
+ optional :language, String
142
+
143
+ # @!attribute modified_time
144
+ # Modified timestamp/date from page metadata, when present.
145
+ #
146
+ # @return [String, nil]
147
+ optional :modified_time, String, api_name: :modifiedTime
148
+
149
+ # @!attribute open_graph
150
+ # Open Graph metadata with the og: prefix removed and keys camel-cased.
151
+ #
152
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
153
+ optional :open_graph,
154
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::OpenGraph] },
155
+ api_name: :openGraph
156
+
157
+ # @!attribute published_time
158
+ # Published timestamp/date from page metadata, when present.
159
+ #
160
+ # @return [String, nil]
161
+ optional :published_time, String, api_name: :publishedTime
162
+
163
+ # @!attribute robots
164
+ # Robots meta directive, when present.
165
+ #
166
+ # @return [String, nil]
167
+ optional :robots, String
168
+
169
+ # @!attribute site_name
170
+ # Site or application name from page metadata.
171
+ #
172
+ # @return [String, nil]
173
+ optional :site_name, String, api_name: :siteName
174
+
175
+ # @!attribute title
176
+ # Best title extracted from the page.
177
+ #
178
+ # @return [String, nil]
179
+ optional :title, String
180
+
181
+ # @!attribute twitter
182
+ # Twitter card metadata with the twitter: prefix removed and keys camel-cased.
183
+ #
184
+ # @return [Hash{Symbol=>String, Array<String>}, nil]
185
+ optional :twitter,
186
+ -> { ContextDev::Internal::Type::HashOf[union: ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::Twitter] }
187
+
188
+ # @!method initialize(final_url:, source_url:, additional_meta: nil, alternates: nil, author: nil, canonical_url: nil, description: nil, favicon: nil, image: nil, json_ld: nil, keywords: nil, language: nil, modified_time: nil, open_graph: nil, published_time: nil, robots: nil, site_name: nil, title: nil, twitter: nil)
189
+ # Some parameter documentations has been truncated, see
190
+ # {ContextDev::Models::WebWebScrapeHTMLResponse::Metadata} for more details.
191
+ #
192
+ # Metadata extracted from the scraped page HTML.
193
+ #
194
+ # @param final_url [String] Final URL scraped after redirects or scraper fallback, when known. Falls back to
195
+ #
196
+ # @param source_url [String] Original URL requested by the caller.
197
+ #
198
+ # @param additional_meta [Hash{Symbol=>String, Array<String>}] Additional non-social meta tags not promoted to top-level metadata fields.
199
+ #
200
+ # @param alternates [Array<ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::Alternate>] Resolved alternate links from link rel=alternate tags.
201
+ #
202
+ # @param author [String] Author metadata, when present.
203
+ #
204
+ # @param canonical_url [String] Resolved canonical URL, when present.
205
+ #
206
+ # @param description [String] Best description extracted from standard, Open Graph, or Twitter metadata.
207
+ #
208
+ # @param favicon [String] Resolved favicon URL, when present.
209
+ #
210
+ # @param image [String] Primary resolved preview image from Open Graph, Twitter, or image metadata.
211
+ #
212
+ # @param json_ld [Array<Hash{Symbol=>Object}>] JSON-LD structured data blocks parsed from the page.
213
+ #
214
+ # @param keywords [Array<String>] Keywords extracted from the page's keywords meta tag.
215
+ #
216
+ # @param language [String] Language extracted from html lang or language meta tags.
217
+ #
218
+ # @param modified_time [String] Modified timestamp/date from page metadata, when present.
219
+ #
220
+ # @param open_graph [Hash{Symbol=>String, Array<String>}] Open Graph metadata with the og: prefix removed and keys camel-cased.
221
+ #
222
+ # @param published_time [String] Published timestamp/date from page metadata, when present.
223
+ #
224
+ # @param robots [String] Robots meta directive, when present.
225
+ #
226
+ # @param site_name [String] Site or application name from page metadata.
227
+ #
228
+ # @param title [String] Best title extracted from the page.
229
+ #
230
+ # @param twitter [Hash{Symbol=>String, Array<String>}] Twitter card metadata with the twitter: prefix removed and keys camel-cased.
231
+
232
+ module AdditionalMeta
233
+ extend ContextDev::Internal::Type::Union
234
+
235
+ variant String
236
+
237
+ variant -> { ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::AdditionalMeta::StringArray }
238
+
239
+ # @!method self.variants
240
+ # @return [Array(String, Array<String>)]
241
+
242
+ # @type [ContextDev::Internal::Type::Converter]
243
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
244
+ end
245
+
246
+ class Alternate < ContextDev::Internal::Type::BaseModel
247
+ # @!attribute href
248
+ # Resolved alternate URL.
249
+ #
250
+ # @return [String]
251
+ required :href, String
252
+
253
+ # @!attribute hreflang
254
+ # Language or locale for the alternate URL, when present.
255
+ #
256
+ # @return [String, nil]
257
+ optional :hreflang, String
258
+
259
+ # @!attribute title
260
+ # Alternate resource title, when present.
261
+ #
262
+ # @return [String, nil]
263
+ optional :title, String
264
+
265
+ # @!attribute type
266
+ # Alternate resource MIME type, when present.
267
+ #
268
+ # @return [String, nil]
269
+ optional :type, String
270
+
271
+ # @!method initialize(href:, hreflang: nil, title: nil, type: nil)
272
+ # @param href [String] Resolved alternate URL.
273
+ #
274
+ # @param hreflang [String] Language or locale for the alternate URL, when present.
275
+ #
276
+ # @param title [String] Alternate resource title, when present.
277
+ #
278
+ # @param type [String] Alternate resource MIME type, when present.
279
+ end
280
+
281
+ module OpenGraph
282
+ extend ContextDev::Internal::Type::Union
283
+
284
+ variant String
285
+
286
+ variant -> { ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::OpenGraph::StringArray }
287
+
288
+ # @!method self.variants
289
+ # @return [Array(String, Array<String>)]
290
+
291
+ # @type [ContextDev::Internal::Type::Converter]
292
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
293
+ end
294
+
295
+ module Twitter
296
+ extend ContextDev::Internal::Type::Union
297
+
298
+ variant String
299
+
300
+ variant -> { ContextDev::Models::WebWebScrapeHTMLResponse::Metadata::Twitter::StringArray }
301
+
302
+ # @!method self.variants
303
+ # @return [Array(String, Array<String>)]
304
+
305
+ # @type [ContextDev::Internal::Type::Converter]
306
+ StringArray = ContextDev::Internal::Type::ArrayOf[String]
307
+ end
308
+ end
309
+
55
310
  # Indicates success
56
311
  #
57
312
  # @see ContextDev::Models::WebWebScrapeHTMLResponse#success
@@ -79,6 +334,8 @@ module ContextDev
79
334
  MARKDOWN = :markdown
80
335
  SVG = :svg
81
336
  PDF = :pdf
337
+ DOCX = :docx
338
+ DOC = :doc
82
339
 
83
340
  # @!method self.values
84
341
  # @return [Array<Symbol>]