context.dev 2.10.0 → 2.12.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 +21 -0
- data/README.md +1 -1
- data/lib/context_dev/models/ai_extract_product_response.rb +48 -1
- data/lib/context_dev/models/ai_extract_products_response.rb +48 -1
- data/lib/context_dev/models/brand_retrieve_response.rb +29 -1
- data/lib/context_dev/models/brand_retrieve_simplified_response.rb +30 -1
- data/lib/context_dev/models/news_search_params.rb +1 -0
- data/lib/context_dev/models/news_search_response.rb +68 -22
- data/lib/context_dev/models/web_extract_params.rb +169 -6
- data/lib/context_dev/models/web_extract_response.rb +85 -1
- data/lib/context_dev/models/web_screenshot_params.rb +13 -1
- data/lib/context_dev/models/web_web_crawl_md_params.rb +7 -5
- data/lib/context_dev/models/web_web_scrape_html_params.rb +99 -3
- data/lib/context_dev/models/web_web_scrape_images_params.rb +99 -3
- data/lib/context_dev/models/web_web_scrape_images_response.rb +85 -1
- data/lib/context_dev/models/web_web_scrape_md_params.rb +99 -3
- data/lib/context_dev/resources/web.rb +13 -8
- data/lib/context_dev/version.rb +1 -1
- data/rbi/context_dev/models/ai_extract_product_response.rbi +99 -0
- data/rbi/context_dev/models/ai_extract_products_response.rbi +99 -0
- data/rbi/context_dev/models/brand_retrieve_response.rbi +80 -3
- data/rbi/context_dev/models/brand_retrieve_simplified_response.rbi +80 -3
- data/rbi/context_dev/models/news_search_params.rbi +5 -0
- data/rbi/context_dev/models/news_search_response.rbi +70 -4
- data/rbi/context_dev/models/web_extract_params.rbi +353 -8
- data/rbi/context_dev/models/web_extract_response.rbi +172 -3
- data/rbi/context_dev/models/web_screenshot_params.rbi +19 -0
- data/rbi/context_dev/models/web_web_crawl_md_params.rbi +10 -6
- data/rbi/context_dev/models/web_web_scrape_html_params.rbi +218 -4
- data/rbi/context_dev/models/web_web_scrape_images_params.rbi +218 -4
- data/rbi/context_dev/models/web_web_scrape_images_response.rbi +169 -0
- data/rbi/context_dev/models/web_web_scrape_md_params.rbi +218 -4
- data/rbi/context_dev/resources/web.rbi +38 -10
- data/sig/context_dev/models/ai_extract_product_response.rbs +40 -0
- data/sig/context_dev/models/ai_extract_products_response.rbs +40 -0
- data/sig/context_dev/models/brand_retrieve_response.rbs +33 -3
- data/sig/context_dev/models/brand_retrieve_simplified_response.rbs +33 -3
- data/sig/context_dev/models/news_search_params.rbs +2 -0
- data/sig/context_dev/models/web_extract_params.rbs +117 -0
- data/sig/context_dev/models/web_extract_response.rbs +81 -3
- data/sig/context_dev/models/web_screenshot_params.rbs +7 -0
- data/sig/context_dev/models/web_web_scrape_html_params.rbs +74 -0
- data/sig/context_dev/models/web_web_scrape_images_params.rbs +74 -0
- data/sig/context_dev/models/web_web_scrape_images_response.rbs +78 -0
- data/sig/context_dev/models/web_web_scrape_md_params.rbs +74 -0
- data/sig/context_dev/resources/web.rbs +2 -0
- metadata +2 -2
|
@@ -57,12 +57,15 @@ module ContextDev
|
|
|
57
57
|
sku: String?,
|
|
58
58
|
tags: ::Array[String],
|
|
59
59
|
target_audience: ::Array[String],
|
|
60
|
+
availability: ContextDev::Models::AIExtractProductsResponse::Product::availability?,
|
|
60
61
|
billing_frequency: ContextDev::Models::AIExtractProductsResponse::Product::billing_frequency?,
|
|
61
62
|
category: String?,
|
|
62
63
|
currency: String?,
|
|
64
|
+
dimensions: ::Array[String],
|
|
63
65
|
image_url: String?,
|
|
64
66
|
price: Float?,
|
|
65
67
|
pricing_model: ContextDev::Models::AIExtractProductsResponse::Product::pricing_model?,
|
|
68
|
+
regular_price: Float?,
|
|
66
69
|
url: String?
|
|
67
70
|
}
|
|
68
71
|
|
|
@@ -81,18 +84,26 @@ module ContextDev
|
|
|
81
84
|
|
|
82
85
|
attr_accessor target_audience: ::Array[String]
|
|
83
86
|
|
|
87
|
+
attr_accessor availability: ContextDev::Models::AIExtractProductsResponse::Product::availability?
|
|
88
|
+
|
|
84
89
|
attr_accessor billing_frequency: ContextDev::Models::AIExtractProductsResponse::Product::billing_frequency?
|
|
85
90
|
|
|
86
91
|
attr_accessor category: String?
|
|
87
92
|
|
|
88
93
|
attr_accessor currency: String?
|
|
89
94
|
|
|
95
|
+
attr_reader dimensions: ::Array[String]?
|
|
96
|
+
|
|
97
|
+
def dimensions=: (::Array[String]) -> ::Array[String]
|
|
98
|
+
|
|
90
99
|
attr_accessor image_url: String?
|
|
91
100
|
|
|
92
101
|
attr_accessor price: Float?
|
|
93
102
|
|
|
94
103
|
attr_accessor pricing_model: ContextDev::Models::AIExtractProductsResponse::Product::pricing_model?
|
|
95
104
|
|
|
105
|
+
attr_accessor regular_price: Float?
|
|
106
|
+
|
|
96
107
|
attr_accessor url: String?
|
|
97
108
|
|
|
98
109
|
def initialize: (
|
|
@@ -103,12 +114,15 @@ module ContextDev
|
|
|
103
114
|
sku: String?,
|
|
104
115
|
tags: ::Array[String],
|
|
105
116
|
target_audience: ::Array[String],
|
|
117
|
+
?availability: ContextDev::Models::AIExtractProductsResponse::Product::availability?,
|
|
106
118
|
?billing_frequency: ContextDev::Models::AIExtractProductsResponse::Product::billing_frequency?,
|
|
107
119
|
?category: String?,
|
|
108
120
|
?currency: String?,
|
|
121
|
+
?dimensions: ::Array[String],
|
|
109
122
|
?image_url: String?,
|
|
110
123
|
?price: Float?,
|
|
111
124
|
?pricing_model: ContextDev::Models::AIExtractProductsResponse::Product::pricing_model?,
|
|
125
|
+
?regular_price: Float?,
|
|
112
126
|
?url: String?
|
|
113
127
|
) -> void
|
|
114
128
|
|
|
@@ -120,15 +134,41 @@ module ContextDev
|
|
|
120
134
|
sku: String?,
|
|
121
135
|
tags: ::Array[String],
|
|
122
136
|
target_audience: ::Array[String],
|
|
137
|
+
availability: ContextDev::Models::AIExtractProductsResponse::Product::availability?,
|
|
123
138
|
billing_frequency: ContextDev::Models::AIExtractProductsResponse::Product::billing_frequency?,
|
|
124
139
|
category: String?,
|
|
125
140
|
currency: String?,
|
|
141
|
+
dimensions: ::Array[String],
|
|
126
142
|
image_url: String?,
|
|
127
143
|
price: Float?,
|
|
128
144
|
pricing_model: ContextDev::Models::AIExtractProductsResponse::Product::pricing_model?,
|
|
145
|
+
regular_price: Float?,
|
|
129
146
|
url: String?
|
|
130
147
|
}
|
|
131
148
|
|
|
149
|
+
type availability =
|
|
150
|
+
:in_stock
|
|
151
|
+
| :out_of_stock
|
|
152
|
+
| :limited_availability
|
|
153
|
+
| :preorder
|
|
154
|
+
| :backorder
|
|
155
|
+
| :made_to_order
|
|
156
|
+
| :discontinued
|
|
157
|
+
|
|
158
|
+
module Availability
|
|
159
|
+
extend ContextDev::Internal::Type::Enum
|
|
160
|
+
|
|
161
|
+
IN_STOCK: :in_stock
|
|
162
|
+
OUT_OF_STOCK: :out_of_stock
|
|
163
|
+
LIMITED_AVAILABILITY: :limited_availability
|
|
164
|
+
PREORDER: :preorder
|
|
165
|
+
BACKORDER: :backorder
|
|
166
|
+
MADE_TO_ORDER: :made_to_order
|
|
167
|
+
DISCONTINUED: :discontinued
|
|
168
|
+
|
|
169
|
+
def self?.values: -> ::Array[ContextDev::Models::AIExtractProductsResponse::Product::availability]
|
|
170
|
+
end
|
|
171
|
+
|
|
132
172
|
type billing_frequency = :monthly | :yearly | :one_time | :usage_based
|
|
133
173
|
|
|
134
174
|
module BillingFrequency
|
|
@@ -332,7 +332,12 @@ module ContextDev
|
|
|
332
332
|
end
|
|
333
333
|
end
|
|
334
334
|
|
|
335
|
-
type color =
|
|
335
|
+
type color =
|
|
336
|
+
{
|
|
337
|
+
hex: String,
|
|
338
|
+
name: String,
|
|
339
|
+
source: ContextDev::Models::BrandRetrieveResponse::Brand::Color::source
|
|
340
|
+
}
|
|
336
341
|
|
|
337
342
|
class Color < ContextDev::Internal::Type::BaseModel
|
|
338
343
|
attr_reader hex: String?
|
|
@@ -343,9 +348,34 @@ module ContextDev
|
|
|
343
348
|
|
|
344
349
|
def name=: (String) -> String
|
|
345
350
|
|
|
346
|
-
|
|
351
|
+
attr_reader source: ContextDev::Models::BrandRetrieveResponse::Brand::Color::source?
|
|
352
|
+
|
|
353
|
+
def source=: (
|
|
354
|
+
ContextDev::Models::BrandRetrieveResponse::Brand::Color::source
|
|
355
|
+
) -> ContextDev::Models::BrandRetrieveResponse::Brand::Color::source
|
|
356
|
+
|
|
357
|
+
def initialize: (
|
|
358
|
+
?hex: String,
|
|
359
|
+
?name: String,
|
|
360
|
+
?source: ContextDev::Models::BrandRetrieveResponse::Brand::Color::source
|
|
361
|
+
) -> void
|
|
347
362
|
|
|
348
|
-
def to_hash: -> {
|
|
363
|
+
def to_hash: -> {
|
|
364
|
+
hex: String,
|
|
365
|
+
name: String,
|
|
366
|
+
source: ContextDev::Models::BrandRetrieveResponse::Brand::Color::source
|
|
367
|
+
}
|
|
368
|
+
|
|
369
|
+
type source = :site | :logo
|
|
370
|
+
|
|
371
|
+
module Source
|
|
372
|
+
extend ContextDev::Internal::Type::Enum
|
|
373
|
+
|
|
374
|
+
SITE: :site
|
|
375
|
+
LOGO: :logo
|
|
376
|
+
|
|
377
|
+
def self?.values: -> ::Array[ContextDev::Models::BrandRetrieveResponse::Brand::Color::source]
|
|
378
|
+
end
|
|
349
379
|
end
|
|
350
380
|
|
|
351
381
|
type employees =
|
|
@@ -177,7 +177,12 @@ module ContextDev
|
|
|
177
177
|
end
|
|
178
178
|
end
|
|
179
179
|
|
|
180
|
-
type color =
|
|
180
|
+
type color =
|
|
181
|
+
{
|
|
182
|
+
hex: String,
|
|
183
|
+
name: String,
|
|
184
|
+
source: ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source
|
|
185
|
+
}
|
|
181
186
|
|
|
182
187
|
class Color < ContextDev::Internal::Type::BaseModel
|
|
183
188
|
attr_reader hex: String?
|
|
@@ -188,9 +193,34 @@ module ContextDev
|
|
|
188
193
|
|
|
189
194
|
def name=: (String) -> String
|
|
190
195
|
|
|
191
|
-
|
|
196
|
+
attr_reader source: ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source?
|
|
197
|
+
|
|
198
|
+
def source=: (
|
|
199
|
+
ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source
|
|
200
|
+
) -> ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source
|
|
201
|
+
|
|
202
|
+
def initialize: (
|
|
203
|
+
?hex: String,
|
|
204
|
+
?name: String,
|
|
205
|
+
?source: ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source
|
|
206
|
+
) -> void
|
|
192
207
|
|
|
193
|
-
def to_hash: -> {
|
|
208
|
+
def to_hash: -> {
|
|
209
|
+
hex: String,
|
|
210
|
+
name: String,
|
|
211
|
+
source: ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
type source = :site | :logo
|
|
215
|
+
|
|
216
|
+
module Source
|
|
217
|
+
extend ContextDev::Internal::Type::Enum
|
|
218
|
+
|
|
219
|
+
SITE: :site
|
|
220
|
+
LOGO: :logo
|
|
221
|
+
|
|
222
|
+
def self?.values: -> ::Array[ContextDev::Models::BrandRetrieveSimplifiedResponse::Brand::Color::source]
|
|
223
|
+
end
|
|
194
224
|
end
|
|
195
225
|
|
|
196
226
|
type logo =
|
|
@@ -4,6 +4,7 @@ module ContextDev
|
|
|
4
4
|
{
|
|
5
5
|
schema: ::Hash[Symbol, top],
|
|
6
6
|
url: String,
|
|
7
|
+
actions: ::Array[ContextDev::Models::WebExtractParams::action],
|
|
7
8
|
fact_check: bool,
|
|
8
9
|
follow_subdomains: bool,
|
|
9
10
|
include_frames: bool,
|
|
@@ -28,6 +29,12 @@ module ContextDev
|
|
|
28
29
|
|
|
29
30
|
attr_accessor url: String
|
|
30
31
|
|
|
32
|
+
attr_reader actions: ::Array[ContextDev::Models::WebExtractParams::action]?
|
|
33
|
+
|
|
34
|
+
def actions=: (
|
|
35
|
+
::Array[ContextDev::Models::WebExtractParams::action]
|
|
36
|
+
) -> ::Array[ContextDev::Models::WebExtractParams::action]
|
|
37
|
+
|
|
31
38
|
attr_reader fact_check: bool?
|
|
32
39
|
|
|
33
40
|
def fact_check=: (bool) -> bool
|
|
@@ -85,6 +92,7 @@ module ContextDev
|
|
|
85
92
|
def initialize: (
|
|
86
93
|
schema: ::Hash[Symbol, top],
|
|
87
94
|
url: String,
|
|
95
|
+
?actions: ::Array[ContextDev::Models::WebExtractParams::action],
|
|
88
96
|
?fact_check: bool,
|
|
89
97
|
?follow_subdomains: bool,
|
|
90
98
|
?include_frames: bool,
|
|
@@ -104,6 +112,7 @@ module ContextDev
|
|
|
104
112
|
def to_hash: -> {
|
|
105
113
|
schema: ::Hash[Symbol, top],
|
|
106
114
|
url: String,
|
|
115
|
+
actions: ::Array[ContextDev::Models::WebExtractParams::action],
|
|
107
116
|
fact_check: bool,
|
|
108
117
|
follow_subdomains: bool,
|
|
109
118
|
include_frames: bool,
|
|
@@ -120,6 +129,114 @@ module ContextDev
|
|
|
120
129
|
request_options: ContextDev::RequestOptions
|
|
121
130
|
}
|
|
122
131
|
|
|
132
|
+
type action =
|
|
133
|
+
ContextDev::WebExtractParams::Action::Wait
|
|
134
|
+
| ContextDev::WebExtractParams::Action::Perform
|
|
135
|
+
| ContextDev::WebExtractParams::Action::Scroll
|
|
136
|
+
|
|
137
|
+
module Action
|
|
138
|
+
extend ContextDev::Internal::Type::Union
|
|
139
|
+
|
|
140
|
+
type wait = { do_: :wait, time_ms: Integer }
|
|
141
|
+
|
|
142
|
+
class Wait < ContextDev::Internal::Type::BaseModel
|
|
143
|
+
attr_accessor do_: :wait
|
|
144
|
+
|
|
145
|
+
attr_accessor time_ms: Integer
|
|
146
|
+
|
|
147
|
+
def initialize: (time_ms: Integer, ?do_: :wait) -> void
|
|
148
|
+
|
|
149
|
+
def to_hash: -> { do_: :wait, time_ms: Integer }
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
type perform = { action: String, do_: :perform }
|
|
153
|
+
|
|
154
|
+
class Perform < ContextDev::Internal::Type::BaseModel
|
|
155
|
+
attr_accessor action: String
|
|
156
|
+
|
|
157
|
+
attr_accessor do_: :perform
|
|
158
|
+
|
|
159
|
+
def initialize: (action: String, ?do_: :perform) -> void
|
|
160
|
+
|
|
161
|
+
def to_hash: -> { action: String, do_: :perform }
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
type scroll =
|
|
165
|
+
{
|
|
166
|
+
do_: :scroll,
|
|
167
|
+
amount: ContextDev::Models::WebExtractParams::Action::Scroll::amount,
|
|
168
|
+
container: String,
|
|
169
|
+
direction: ContextDev::Models::WebExtractParams::Action::Scroll::direction,
|
|
170
|
+
max_scrolls: Integer
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
class Scroll < ContextDev::Internal::Type::BaseModel
|
|
174
|
+
attr_accessor do_: :scroll
|
|
175
|
+
|
|
176
|
+
attr_reader amount: ContextDev::Models::WebExtractParams::Action::Scroll::amount?
|
|
177
|
+
|
|
178
|
+
def amount=: (
|
|
179
|
+
ContextDev::Models::WebExtractParams::Action::Scroll::amount
|
|
180
|
+
) -> ContextDev::Models::WebExtractParams::Action::Scroll::amount
|
|
181
|
+
|
|
182
|
+
attr_reader container: String?
|
|
183
|
+
|
|
184
|
+
def container=: (String) -> String
|
|
185
|
+
|
|
186
|
+
attr_reader direction: ContextDev::Models::WebExtractParams::Action::Scroll::direction?
|
|
187
|
+
|
|
188
|
+
def direction=: (
|
|
189
|
+
ContextDev::Models::WebExtractParams::Action::Scroll::direction
|
|
190
|
+
) -> ContextDev::Models::WebExtractParams::Action::Scroll::direction
|
|
191
|
+
|
|
192
|
+
attr_reader max_scrolls: Integer?
|
|
193
|
+
|
|
194
|
+
def max_scrolls=: (Integer) -> Integer
|
|
195
|
+
|
|
196
|
+
def initialize: (
|
|
197
|
+
?amount: ContextDev::Models::WebExtractParams::Action::Scroll::amount,
|
|
198
|
+
?container: String,
|
|
199
|
+
?direction: ContextDev::Models::WebExtractParams::Action::Scroll::direction,
|
|
200
|
+
?max_scrolls: Integer,
|
|
201
|
+
?do_: :scroll
|
|
202
|
+
) -> void
|
|
203
|
+
|
|
204
|
+
def to_hash: -> {
|
|
205
|
+
do_: :scroll,
|
|
206
|
+
amount: ContextDev::Models::WebExtractParams::Action::Scroll::amount,
|
|
207
|
+
container: String,
|
|
208
|
+
direction: ContextDev::Models::WebExtractParams::Action::Scroll::direction,
|
|
209
|
+
max_scrolls: Integer
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
type amount = Integer | :viewport | :max
|
|
213
|
+
|
|
214
|
+
module Amount
|
|
215
|
+
extend ContextDev::Internal::Type::Union
|
|
216
|
+
|
|
217
|
+
def self?.variants: -> ::Array[ContextDev::Models::WebExtractParams::Action::Scroll::amount]
|
|
218
|
+
|
|
219
|
+
VIEWPORT: :viewport
|
|
220
|
+
MAX: :max
|
|
221
|
+
end
|
|
222
|
+
|
|
223
|
+
type direction = :up | :down | :left | :right
|
|
224
|
+
|
|
225
|
+
module Direction
|
|
226
|
+
extend ContextDev::Internal::Type::Enum
|
|
227
|
+
|
|
228
|
+
UP: :up
|
|
229
|
+
DOWN: :down
|
|
230
|
+
LEFT: :left
|
|
231
|
+
RIGHT: :right
|
|
232
|
+
|
|
233
|
+
def self?.values: -> ::Array[ContextDev::Models::WebExtractParams::Action::Scroll::direction]
|
|
234
|
+
end
|
|
235
|
+
end
|
|
236
|
+
|
|
237
|
+
def self?.variants: -> ::Array[ContextDev::Models::WebExtractParams::action]
|
|
238
|
+
end
|
|
239
|
+
|
|
123
240
|
type pdf = { end_: Integer, should_parse: bool, start: Integer }
|
|
124
241
|
|
|
125
242
|
class Pdf < ContextDev::Internal::Type::BaseModel
|
|
@@ -52,7 +52,8 @@ module ContextDev
|
|
|
52
52
|
num_failed: Integer,
|
|
53
53
|
num_skipped: Integer,
|
|
54
54
|
num_succeeded: Integer,
|
|
55
|
-
num_urls: Integer
|
|
55
|
+
num_urls: Integer,
|
|
56
|
+
actions_applied: ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]
|
|
56
57
|
}
|
|
57
58
|
|
|
58
59
|
class Metadata < ContextDev::Internal::Type::BaseModel
|
|
@@ -68,13 +69,20 @@ module ContextDev
|
|
|
68
69
|
|
|
69
70
|
attr_accessor num_urls: Integer
|
|
70
71
|
|
|
72
|
+
attr_reader actions_applied: ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]?
|
|
73
|
+
|
|
74
|
+
def actions_applied=: (
|
|
75
|
+
::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]
|
|
76
|
+
) -> ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]
|
|
77
|
+
|
|
71
78
|
def initialize: (
|
|
72
79
|
max_crawl_depth: Integer,
|
|
73
80
|
num_blocked: Integer,
|
|
74
81
|
num_failed: Integer,
|
|
75
82
|
num_skipped: Integer,
|
|
76
83
|
num_succeeded: Integer,
|
|
77
|
-
num_urls: Integer
|
|
84
|
+
num_urls: Integer,
|
|
85
|
+
?actions_applied: ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]
|
|
78
86
|
) -> void
|
|
79
87
|
|
|
80
88
|
def to_hash: -> {
|
|
@@ -83,8 +91,78 @@ module ContextDev
|
|
|
83
91
|
num_failed: Integer,
|
|
84
92
|
num_skipped: Integer,
|
|
85
93
|
num_succeeded: Integer,
|
|
86
|
-
num_urls: Integer
|
|
94
|
+
num_urls: Integer,
|
|
95
|
+
actions_applied: ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied]
|
|
87
96
|
}
|
|
97
|
+
|
|
98
|
+
type actions_applied =
|
|
99
|
+
{
|
|
100
|
+
instruction: String,
|
|
101
|
+
status: ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied::status,
|
|
102
|
+
completion_evidence: String,
|
|
103
|
+
duration_ms: Float,
|
|
104
|
+
error: String,
|
|
105
|
+
method_: String,
|
|
106
|
+
target_description: String
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
class ActionsApplied < ContextDev::Internal::Type::BaseModel
|
|
110
|
+
attr_accessor instruction: String
|
|
111
|
+
|
|
112
|
+
attr_accessor status: ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied::status
|
|
113
|
+
|
|
114
|
+
attr_reader completion_evidence: String?
|
|
115
|
+
|
|
116
|
+
def completion_evidence=: (String) -> String
|
|
117
|
+
|
|
118
|
+
attr_reader duration_ms: Float?
|
|
119
|
+
|
|
120
|
+
def duration_ms=: (Float) -> Float
|
|
121
|
+
|
|
122
|
+
attr_reader error: String?
|
|
123
|
+
|
|
124
|
+
def error=: (String) -> String
|
|
125
|
+
|
|
126
|
+
attr_reader method_: String?
|
|
127
|
+
|
|
128
|
+
def method_=: (String) -> String
|
|
129
|
+
|
|
130
|
+
attr_reader target_description: String?
|
|
131
|
+
|
|
132
|
+
def target_description=: (String) -> String
|
|
133
|
+
|
|
134
|
+
def initialize: (
|
|
135
|
+
instruction: String,
|
|
136
|
+
status: ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied::status,
|
|
137
|
+
?completion_evidence: String,
|
|
138
|
+
?duration_ms: Float,
|
|
139
|
+
?error: String,
|
|
140
|
+
?method_: String,
|
|
141
|
+
?target_description: String
|
|
142
|
+
) -> void
|
|
143
|
+
|
|
144
|
+
def to_hash: -> {
|
|
145
|
+
instruction: String,
|
|
146
|
+
status: ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied::status,
|
|
147
|
+
completion_evidence: String,
|
|
148
|
+
duration_ms: Float,
|
|
149
|
+
error: String,
|
|
150
|
+
method_: String,
|
|
151
|
+
target_description: String
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
type status = :applied | :failed | :skipped
|
|
155
|
+
|
|
156
|
+
module Status
|
|
157
|
+
extend ContextDev::Internal::Type::Enum
|
|
158
|
+
|
|
159
|
+
APPLIED: :applied
|
|
160
|
+
FAILED: :failed
|
|
161
|
+
SKIPPED: :skipped
|
|
162
|
+
|
|
163
|
+
def self?.values: -> ::Array[ContextDev::Models::WebExtractResponse::Metadata::ActionsApplied::status]
|
|
164
|
+
end
|
|
165
|
+
end
|
|
88
166
|
end
|
|
89
167
|
|
|
90
168
|
type key_metadata =
|
|
@@ -2,6 +2,7 @@ module ContextDev
|
|
|
2
2
|
module Models
|
|
3
3
|
type web_screenshot_params =
|
|
4
4
|
{
|
|
5
|
+
clear_popups: bool,
|
|
5
6
|
color_scheme: ContextDev::Models::WebScreenshotParams::color_scheme,
|
|
6
7
|
country: ContextDev::Models::WebScreenshotParams::country,
|
|
7
8
|
direct_url: String,
|
|
@@ -23,6 +24,10 @@ module ContextDev
|
|
|
23
24
|
extend ContextDev::Internal::Type::RequestParameters::Converter
|
|
24
25
|
include ContextDev::Internal::Type::RequestParameters
|
|
25
26
|
|
|
27
|
+
attr_reader clear_popups: bool?
|
|
28
|
+
|
|
29
|
+
def clear_popups=: (bool) -> bool
|
|
30
|
+
|
|
26
31
|
attr_reader color_scheme: ContextDev::Models::WebScreenshotParams::color_scheme?
|
|
27
32
|
|
|
28
33
|
def color_scheme=: (
|
|
@@ -86,6 +91,7 @@ module ContextDev
|
|
|
86
91
|
) -> ContextDev::Models::WebScreenshotParams::zdr
|
|
87
92
|
|
|
88
93
|
def initialize: (
|
|
94
|
+
?clear_popups: bool,
|
|
89
95
|
?color_scheme: ContextDev::Models::WebScreenshotParams::color_scheme,
|
|
90
96
|
?country: ContextDev::Models::WebScreenshotParams::country,
|
|
91
97
|
?direct_url: String,
|
|
@@ -104,6 +110,7 @@ module ContextDev
|
|
|
104
110
|
) -> void
|
|
105
111
|
|
|
106
112
|
def to_hash: -> {
|
|
113
|
+
clear_popups: bool,
|
|
107
114
|
color_scheme: ContextDev::Models::WebScreenshotParams::color_scheme,
|
|
108
115
|
country: ContextDev::Models::WebScreenshotParams::country,
|
|
109
116
|
direct_url: String,
|
|
@@ -119,6 +119,7 @@ module ContextDev
|
|
|
119
119
|
type action =
|
|
120
120
|
ContextDev::WebWebScrapeHTMLParams::Action::Wait
|
|
121
121
|
| ContextDev::WebWebScrapeHTMLParams::Action::Perform
|
|
122
|
+
| ContextDev::WebWebScrapeHTMLParams::Action::Scroll
|
|
122
123
|
|
|
123
124
|
module Action
|
|
124
125
|
extend ContextDev::Internal::Type::Union
|
|
@@ -147,6 +148,79 @@ module ContextDev
|
|
|
147
148
|
def to_hash: -> { action: String, do_: :perform }
|
|
148
149
|
end
|
|
149
150
|
|
|
151
|
+
type scroll =
|
|
152
|
+
{
|
|
153
|
+
do_: :scroll,
|
|
154
|
+
amount: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount,
|
|
155
|
+
container: String,
|
|
156
|
+
direction: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction,
|
|
157
|
+
max_scrolls: Integer
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
class Scroll < ContextDev::Internal::Type::BaseModel
|
|
161
|
+
attr_accessor do_: :scroll
|
|
162
|
+
|
|
163
|
+
attr_reader amount: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount?
|
|
164
|
+
|
|
165
|
+
def amount=: (
|
|
166
|
+
ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount
|
|
167
|
+
) -> ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount
|
|
168
|
+
|
|
169
|
+
attr_reader container: String?
|
|
170
|
+
|
|
171
|
+
def container=: (String) -> String
|
|
172
|
+
|
|
173
|
+
attr_reader direction: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction?
|
|
174
|
+
|
|
175
|
+
def direction=: (
|
|
176
|
+
ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction
|
|
177
|
+
) -> ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction
|
|
178
|
+
|
|
179
|
+
attr_reader max_scrolls: Integer?
|
|
180
|
+
|
|
181
|
+
def max_scrolls=: (Integer) -> Integer
|
|
182
|
+
|
|
183
|
+
def initialize: (
|
|
184
|
+
?amount: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount,
|
|
185
|
+
?container: String,
|
|
186
|
+
?direction: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction,
|
|
187
|
+
?max_scrolls: Integer,
|
|
188
|
+
?do_: :scroll
|
|
189
|
+
) -> void
|
|
190
|
+
|
|
191
|
+
def to_hash: -> {
|
|
192
|
+
do_: :scroll,
|
|
193
|
+
amount: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount,
|
|
194
|
+
container: String,
|
|
195
|
+
direction: ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction,
|
|
196
|
+
max_scrolls: Integer
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
type amount = Integer | :viewport | :max
|
|
200
|
+
|
|
201
|
+
module Amount
|
|
202
|
+
extend ContextDev::Internal::Type::Union
|
|
203
|
+
|
|
204
|
+
def self?.variants: -> ::Array[ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::amount]
|
|
205
|
+
|
|
206
|
+
VIEWPORT: :viewport
|
|
207
|
+
MAX: :max
|
|
208
|
+
end
|
|
209
|
+
|
|
210
|
+
type direction = :up | :down | :left | :right
|
|
211
|
+
|
|
212
|
+
module Direction
|
|
213
|
+
extend ContextDev::Internal::Type::Enum
|
|
214
|
+
|
|
215
|
+
UP: :up
|
|
216
|
+
DOWN: :down
|
|
217
|
+
LEFT: :left
|
|
218
|
+
RIGHT: :right
|
|
219
|
+
|
|
220
|
+
def self?.values: -> ::Array[ContextDev::Models::WebWebScrapeHTMLParams::Action::Scroll::direction]
|
|
221
|
+
end
|
|
222
|
+
end
|
|
223
|
+
|
|
150
224
|
def self?.variants: -> ::Array[ContextDev::Models::WebWebScrapeHTMLParams::action]
|
|
151
225
|
end
|
|
152
226
|
|
|
@@ -73,6 +73,7 @@ module ContextDev
|
|
|
73
73
|
type action =
|
|
74
74
|
ContextDev::WebWebScrapeImagesParams::Action::Wait
|
|
75
75
|
| ContextDev::WebWebScrapeImagesParams::Action::Perform
|
|
76
|
+
| ContextDev::WebWebScrapeImagesParams::Action::Scroll
|
|
76
77
|
|
|
77
78
|
module Action
|
|
78
79
|
extend ContextDev::Internal::Type::Union
|
|
@@ -101,6 +102,79 @@ module ContextDev
|
|
|
101
102
|
def to_hash: -> { action: String, do_: :perform }
|
|
102
103
|
end
|
|
103
104
|
|
|
105
|
+
type scroll =
|
|
106
|
+
{
|
|
107
|
+
do_: :scroll,
|
|
108
|
+
amount: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount,
|
|
109
|
+
container: String,
|
|
110
|
+
direction: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction,
|
|
111
|
+
max_scrolls: Integer
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
class Scroll < ContextDev::Internal::Type::BaseModel
|
|
115
|
+
attr_accessor do_: :scroll
|
|
116
|
+
|
|
117
|
+
attr_reader amount: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount?
|
|
118
|
+
|
|
119
|
+
def amount=: (
|
|
120
|
+
ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount
|
|
121
|
+
) -> ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount
|
|
122
|
+
|
|
123
|
+
attr_reader container: String?
|
|
124
|
+
|
|
125
|
+
def container=: (String) -> String
|
|
126
|
+
|
|
127
|
+
attr_reader direction: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction?
|
|
128
|
+
|
|
129
|
+
def direction=: (
|
|
130
|
+
ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction
|
|
131
|
+
) -> ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction
|
|
132
|
+
|
|
133
|
+
attr_reader max_scrolls: Integer?
|
|
134
|
+
|
|
135
|
+
def max_scrolls=: (Integer) -> Integer
|
|
136
|
+
|
|
137
|
+
def initialize: (
|
|
138
|
+
?amount: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount,
|
|
139
|
+
?container: String,
|
|
140
|
+
?direction: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction,
|
|
141
|
+
?max_scrolls: Integer,
|
|
142
|
+
?do_: :scroll
|
|
143
|
+
) -> void
|
|
144
|
+
|
|
145
|
+
def to_hash: -> {
|
|
146
|
+
do_: :scroll,
|
|
147
|
+
amount: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount,
|
|
148
|
+
container: String,
|
|
149
|
+
direction: ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction,
|
|
150
|
+
max_scrolls: Integer
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
type amount = Integer | :viewport | :max
|
|
154
|
+
|
|
155
|
+
module Amount
|
|
156
|
+
extend ContextDev::Internal::Type::Union
|
|
157
|
+
|
|
158
|
+
def self?.variants: -> ::Array[ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::amount]
|
|
159
|
+
|
|
160
|
+
VIEWPORT: :viewport
|
|
161
|
+
MAX: :max
|
|
162
|
+
end
|
|
163
|
+
|
|
164
|
+
type direction = :up | :down | :left | :right
|
|
165
|
+
|
|
166
|
+
module Direction
|
|
167
|
+
extend ContextDev::Internal::Type::Enum
|
|
168
|
+
|
|
169
|
+
UP: :up
|
|
170
|
+
DOWN: :down
|
|
171
|
+
LEFT: :left
|
|
172
|
+
RIGHT: :right
|
|
173
|
+
|
|
174
|
+
def self?.values: -> ::Array[ContextDev::Models::WebWebScrapeImagesParams::Action::Scroll::direction]
|
|
175
|
+
end
|
|
176
|
+
end
|
|
177
|
+
|
|
104
178
|
def self?.variants: -> ::Array[ContextDev::Models::WebWebScrapeImagesParams::action]
|
|
105
179
|
end
|
|
106
180
|
|