context.dev 2.17.1 → 2.19.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 +33 -0
- data/README.md +1 -1
- data/lib/context_dev/client.rb +0 -4
- data/lib/context_dev/models/industry_retrieve_naics_params.rb +28 -1
- data/lib/context_dev/models/industry_retrieve_sic_params.rb +28 -1
- data/lib/context_dev/models/monitor_retrieve_run_params.rb +26 -0
- data/lib/context_dev/models/monitor_retrieve_run_response.rb +232 -0
- data/lib/context_dev/models/monitor_rotate_webhook_secret_params.rb +20 -0
- data/lib/context_dev/models/monitor_rotate_webhook_secret_response.rb +765 -0
- data/lib/context_dev/models/parse_handle_params.rb +8 -6
- data/lib/context_dev/models/person_enrich_params.rb +28 -1
- data/lib/context_dev/models/web_answers_params.rb +28 -1
- data/lib/context_dev/models/web_extract_competitors_params.rb +28 -1
- data/lib/context_dev/models/web_extract_styleguide_params.rb +30 -3
- data/lib/context_dev/models/{web_web_scrape_sitemap_params.rb → web_map_urls_params.rb} +22 -20
- data/lib/context_dev/models/web_map_urls_response.rb +123 -0
- data/lib/context_dev/models/web_scrape_params.rb +906 -0
- data/lib/context_dev/models/web_scrape_response.rb +659 -0
- data/lib/context_dev/models/web_screenshot_params.rb +25 -9
- data/lib/context_dev/models/web_screenshot_response.rb +3 -3
- data/lib/context_dev/models/web_search_params.rb +30 -3
- data/lib/context_dev/models.rb +8 -20
- data/lib/context_dev/resources/brand.rb +0 -36
- data/lib/context_dev/resources/industry.rb +6 -2
- data/lib/context_dev/resources/monitors.rb +47 -0
- data/lib/context_dev/resources/people.rb +3 -1
- data/lib/context_dev/resources/web.rb +116 -413
- data/lib/context_dev/version.rb +1 -1
- data/lib/context_dev.rb +8 -21
- data/rbi/context_dev/client.rbi +0 -3
- data/rbi/context_dev/models/industry_retrieve_naics_params.rbi +59 -0
- data/rbi/context_dev/models/industry_retrieve_sic_params.rbi +57 -0
- data/rbi/context_dev/models/monitor_retrieve_run_params.rbi +46 -0
- data/rbi/context_dev/models/monitor_retrieve_run_response.rbi +452 -0
- data/rbi/context_dev/models/monitor_rotate_webhook_secret_params.rbi +38 -0
- data/rbi/context_dev/models/monitor_rotate_webhook_secret_response.rbi +1367 -0
- data/rbi/context_dev/models/parse_handle_params.rbi +12 -9
- data/rbi/context_dev/models/person_enrich_params.rbi +45 -0
- data/rbi/context_dev/models/web_answers_params.rbi +45 -0
- data/rbi/context_dev/models/web_extract_competitors_params.rbi +59 -0
- data/rbi/context_dev/models/web_extract_styleguide_params.rbi +62 -3
- data/rbi/context_dev/models/{web_web_scrape_sitemap_params.rbi → web_map_urls_params.rbi} +35 -54
- data/rbi/context_dev/models/web_map_urls_response.rbi +226 -0
- data/rbi/context_dev/models/web_scrape_params.rbi +2000 -0
- data/rbi/context_dev/models/{web_web_scrape_html_response.rbi → web_scrape_response.rbi} +550 -418
- data/rbi/context_dev/models/web_screenshot_params.rbi +38 -12
- data/rbi/context_dev/models/web_screenshot_response.rbi +4 -4
- data/rbi/context_dev/models/web_search_params.rbi +48 -3
- data/rbi/context_dev/models.rbi +9 -21
- data/rbi/context_dev/resources/brand.rbi +0 -35
- data/rbi/context_dev/resources/industry.rbi +14 -0
- data/rbi/context_dev/resources/monitors.rbi +24 -0
- data/rbi/context_dev/resources/parse.rbi +4 -4
- data/rbi/context_dev/resources/people.rbi +7 -0
- data/rbi/context_dev/resources/web.rbi +166 -533
- data/sig/context_dev/client.rbs +0 -2
- data/sig/context_dev/models/industry_retrieve_naics_params.rbs +21 -1
- data/sig/context_dev/models/industry_retrieve_sic_params.rbs +21 -1
- data/sig/context_dev/models/monitor_retrieve_run_params.rbs +28 -0
- data/sig/context_dev/models/monitor_retrieve_run_response.rbs +182 -0
- data/sig/context_dev/models/monitor_rotate_webhook_secret_params.rbs +23 -0
- data/sig/context_dev/models/monitor_rotate_webhook_secret_response.rbs +545 -0
- data/sig/context_dev/models/person_enrich_params.rbs +21 -1
- data/sig/context_dev/models/web_answers_params.rbs +21 -1
- data/sig/context_dev/models/web_extract_competitors_params.rbs +21 -1
- data/sig/context_dev/models/web_extract_styleguide_params.rbs +21 -1
- data/sig/context_dev/models/{web_web_scrape_sitemap_params.rbs → web_map_urls_params.rbs} +22 -22
- data/sig/context_dev/models/web_map_urls_response.rbs +125 -0
- data/sig/context_dev/models/web_scrape_params.rbs +834 -0
- data/sig/context_dev/models/web_scrape_response.rbs +552 -0
- data/sig/context_dev/models/web_screenshot_params.rbs +7 -0
- data/sig/context_dev/models/web_search_params.rbs +21 -1
- data/sig/context_dev/models.rbs +8 -20
- data/sig/context_dev/resources/brand.rbs +0 -9
- data/sig/context_dev/resources/industry.rbs +2 -0
- data/sig/context_dev/resources/monitors.rbs +11 -0
- data/sig/context_dev/resources/people.rbs +1 -0
- data/sig/context_dev/resources/web.rbs +34 -108
- metadata +26 -65
- data/lib/context_dev/models/ai_extract_product_params.rb +0 -98
- data/lib/context_dev/models/ai_extract_product_response.rb +0 -352
- data/lib/context_dev/models/ai_extract_products_params.rb +0 -233
- data/lib/context_dev/models/ai_extract_products_response.rb +0 -320
- data/lib/context_dev/models/brand_retrieve_simplified_params.rb +0 -120
- data/lib/context_dev/models/brand_retrieve_simplified_response.rb +0 -441
- data/lib/context_dev/models/web_extract_fonts_params.rb +0 -114
- data/lib/context_dev/models/web_extract_fonts_response.rb +0 -291
- data/lib/context_dev/models/web_extract_params.rb +0 -392
- data/lib/context_dev/models/web_extract_response.rb +0 -287
- data/lib/context_dev/models/web_web_scrape_bytes_params.rb +0 -344
- data/lib/context_dev/models/web_web_scrape_bytes_response.rb +0 -135
- data/lib/context_dev/models/web_web_scrape_html_params.rb +0 -633
- data/lib/context_dev/models/web_web_scrape_html_response.rb +0 -588
- data/lib/context_dev/models/web_web_scrape_images_params.rb +0 -346
- data/lib/context_dev/models/web_web_scrape_images_response.rb +0 -409
- data/lib/context_dev/models/web_web_scrape_md_params.rb +0 -668
- data/lib/context_dev/models/web_web_scrape_md_response.rb +0 -567
- data/lib/context_dev/models/web_web_scrape_sitemap_response.rb +0 -144
- data/lib/context_dev/resources/ai.rb +0 -69
- data/rbi/context_dev/models/ai_extract_product_params.rbi +0 -199
- data/rbi/context_dev/models/ai_extract_product_response.rbi +0 -696
- data/rbi/context_dev/models/ai_extract_products_params.rbi +0 -490
- data/rbi/context_dev/models/ai_extract_products_response.rbi +0 -623
- data/rbi/context_dev/models/brand_retrieve_simplified_params.rbi +0 -256
- data/rbi/context_dev/models/brand_retrieve_simplified_response.rbi +0 -1040
- data/rbi/context_dev/models/web_extract_fonts_params.rbi +0 -223
- data/rbi/context_dev/models/web_extract_fonts_response.rbi +0 -563
- data/rbi/context_dev/models/web_extract_params.rbi +0 -736
- data/rbi/context_dev/models/web_extract_response.rbi +0 -512
- data/rbi/context_dev/models/web_web_scrape_bytes_params.rbi +0 -699
- data/rbi/context_dev/models/web_web_scrape_bytes_response.rbi +0 -238
- data/rbi/context_dev/models/web_web_scrape_html_params.rbi +0 -1217
- data/rbi/context_dev/models/web_web_scrape_images_params.rbi +0 -671
- data/rbi/context_dev/models/web_web_scrape_images_response.rbi +0 -910
- data/rbi/context_dev/models/web_web_scrape_md_params.rbi +0 -1049
- data/rbi/context_dev/models/web_web_scrape_md_response.rbi +0 -1088
- data/rbi/context_dev/models/web_web_scrape_sitemap_response.rbi +0 -258
- data/rbi/context_dev/resources/ai.rbi +0 -56
- data/sig/context_dev/models/ai_extract_product_params.rbs +0 -86
- data/sig/context_dev/models/ai_extract_product_response.rbs +0 -273
- data/sig/context_dev/models/ai_extract_products_params.rbs +0 -202
- data/sig/context_dev/models/ai_extract_products_response.rbs +0 -252
- data/sig/context_dev/models/brand_retrieve_simplified_params.rbs +0 -104
- data/sig/context_dev/models/brand_retrieve_simplified_response.rbs +0 -413
- data/sig/context_dev/models/web_extract_fonts_params.rbs +0 -93
- data/sig/context_dev/models/web_extract_fonts_response.rbs +0 -230
- data/sig/context_dev/models/web_extract_params.rbs +0 -304
- data/sig/context_dev/models/web_extract_response.rbs +0 -239
- data/sig/context_dev/models/web_web_scrape_bytes_params.rbs +0 -531
- data/sig/context_dev/models/web_web_scrape_bytes_response.rbs +0 -108
- data/sig/context_dev/models/web_web_scrape_html_params.rbs +0 -730
- data/sig/context_dev/models/web_web_scrape_html_response.rbs +0 -495
- data/sig/context_dev/models/web_web_scrape_images_params.rbs +0 -261
- data/sig/context_dev/models/web_web_scrape_images_response.rbs +0 -371
- data/sig/context_dev/models/web_web_scrape_md_params.rbs +0 -758
- data/sig/context_dev/models/web_web_scrape_md_response.rbs +0 -465
- data/sig/context_dev/models/web_web_scrape_sitemap_response.rbs +0 -117
- data/sig/context_dev/resources/ai.rbs +0 -20
|
@@ -74,9 +74,10 @@ module ContextDev
|
|
|
74
74
|
|
|
75
75
|
# @!attribute zdr
|
|
76
76
|
# Set to enabled to bypass shared caches and omit request and response content
|
|
77
|
-
# from retained usage logs.
|
|
78
|
-
#
|
|
79
|
-
#
|
|
77
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
78
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
79
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
80
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
80
81
|
#
|
|
81
82
|
# @return [Symbol, ContextDev::Models::ParseHandleParams::Zdr, nil]
|
|
82
83
|
optional :zdr, enum: -> { ContextDev::ParseHandleParams::Zdr }
|
|
@@ -215,9 +216,10 @@ module ContextDev
|
|
|
215
216
|
end
|
|
216
217
|
|
|
217
218
|
# Set to enabled to bypass shared caches and omit request and response content
|
|
218
|
-
# from retained usage logs.
|
|
219
|
-
#
|
|
220
|
-
#
|
|
219
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
220
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
221
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
222
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
221
223
|
module Zdr
|
|
222
224
|
extend ContextDev::Internal::Type::Enum
|
|
223
225
|
|
|
@@ -51,7 +51,17 @@ module ContextDev
|
|
|
51
51
|
# @return [ContextDev::Models::PersonEnrichParams::TimeoutOpts, nil]
|
|
52
52
|
optional :timeout_opts, -> { ContextDev::PersonEnrichParams::TimeoutOpts }, api_name: :timeoutOpts
|
|
53
53
|
|
|
54
|
-
# @!
|
|
54
|
+
# @!attribute zdr
|
|
55
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
56
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
57
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
58
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
59
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
60
|
+
#
|
|
61
|
+
# @return [Symbol, ContextDev::Models::PersonEnrichParams::Zdr, nil]
|
|
62
|
+
optional :zdr, enum: -> { ContextDev::PersonEnrichParams::Zdr }
|
|
63
|
+
|
|
64
|
+
# @!method initialize(company: nil, education: nil, email: nil, location: nil, name: nil, social_urls: nil, tags: nil, timeout_opts: nil, zdr: nil, request_options: {})
|
|
55
65
|
# Some parameter documentations has been truncated, see
|
|
56
66
|
# {ContextDev::Models::PersonEnrichParams} for more details.
|
|
57
67
|
#
|
|
@@ -71,6 +81,8 @@ module ContextDev
|
|
|
71
81
|
#
|
|
72
82
|
# @param timeout_opts [ContextDev::Models::PersonEnrichParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
|
|
73
83
|
#
|
|
84
|
+
# @param zdr [Symbol, ContextDev::Models::PersonEnrichParams::Zdr] Set to enabled to bypass shared caches and omit request and response content fro
|
|
85
|
+
#
|
|
74
86
|
# @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
|
|
75
87
|
|
|
76
88
|
class Company < ContextDev::Internal::Type::BaseModel
|
|
@@ -216,6 +228,21 @@ module ContextDev
|
|
|
216
228
|
# @return [Array<Symbol>]
|
|
217
229
|
end
|
|
218
230
|
end
|
|
231
|
+
|
|
232
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
233
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
234
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
235
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
236
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
237
|
+
module Zdr
|
|
238
|
+
extend ContextDev::Internal::Type::Enum
|
|
239
|
+
|
|
240
|
+
ENABLED = :enabled
|
|
241
|
+
DISABLED = :disabled
|
|
242
|
+
|
|
243
|
+
# @!method self.values
|
|
244
|
+
# @return [Array<Symbol>]
|
|
245
|
+
end
|
|
219
246
|
end
|
|
220
247
|
end
|
|
221
248
|
end
|
|
@@ -46,7 +46,17 @@ module ContextDev
|
|
|
46
46
|
# @return [ContextDev::Models::WebAnswersParams::TimeoutOpts, nil]
|
|
47
47
|
optional :timeout_opts, -> { ContextDev::WebAnswersParams::TimeoutOpts }, api_name: :timeoutOpts
|
|
48
48
|
|
|
49
|
-
# @!
|
|
49
|
+
# @!attribute zdr
|
|
50
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
51
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
52
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
53
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
54
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
55
|
+
#
|
|
56
|
+
# @return [Symbol, ContextDev::Models::WebAnswersParams::Zdr, nil]
|
|
57
|
+
optional :zdr, enum: -> { ContextDev::WebAnswersParams::Zdr }
|
|
58
|
+
|
|
59
|
+
# @!method initialize(task:, json_format: nil, mode: nil, tags: nil, timeout_opts: nil, zdr: nil, request_options: {})
|
|
50
60
|
# Some parameter documentations has been truncated, see
|
|
51
61
|
# {ContextDev::Models::WebAnswersParams} for more details.
|
|
52
62
|
#
|
|
@@ -60,6 +70,8 @@ module ContextDev
|
|
|
60
70
|
#
|
|
61
71
|
# @param timeout_opts [ContextDev::Models::WebAnswersParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
|
|
62
72
|
#
|
|
73
|
+
# @param zdr [Symbol, ContextDev::Models::WebAnswersParams::Zdr] Set to enabled to bypass shared caches and omit request and response content fro
|
|
74
|
+
#
|
|
63
75
|
# @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
|
|
64
76
|
|
|
65
77
|
# Research level: fast uses a smaller model and research budget for 10 credits;
|
|
@@ -119,6 +131,21 @@ module ContextDev
|
|
|
119
131
|
# @return [Array<Symbol>]
|
|
120
132
|
end
|
|
121
133
|
end
|
|
134
|
+
|
|
135
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
136
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
137
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
138
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
139
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
140
|
+
module Zdr
|
|
141
|
+
extend ContextDev::Internal::Type::Enum
|
|
142
|
+
|
|
143
|
+
ENABLED = :enabled
|
|
144
|
+
DISABLED = :disabled
|
|
145
|
+
|
|
146
|
+
# @!method self.values
|
|
147
|
+
# @return [Array<Symbol>]
|
|
148
|
+
end
|
|
122
149
|
end
|
|
123
150
|
end
|
|
124
151
|
end
|
|
@@ -35,7 +35,17 @@ module ContextDev
|
|
|
35
35
|
# @return [ContextDev::Models::WebExtractCompetitorsParams::TimeoutOpts, nil]
|
|
36
36
|
optional :timeout_opts, -> { ContextDev::WebExtractCompetitorsParams::TimeoutOpts }
|
|
37
37
|
|
|
38
|
-
# @!
|
|
38
|
+
# @!attribute zdr
|
|
39
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
40
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
41
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
42
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
43
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
44
|
+
#
|
|
45
|
+
# @return [Symbol, ContextDev::Models::WebExtractCompetitorsParams::Zdr, nil]
|
|
46
|
+
optional :zdr, enum: -> { ContextDev::WebExtractCompetitorsParams::Zdr }
|
|
47
|
+
|
|
48
|
+
# @!method initialize(domain:, num_competitors: nil, tags: nil, timeout_opts: nil, zdr: nil, request_options: {})
|
|
39
49
|
# Some parameter documentations has been truncated, see
|
|
40
50
|
# {ContextDev::Models::WebExtractCompetitorsParams} for more details.
|
|
41
51
|
#
|
|
@@ -47,6 +57,8 @@ module ContextDev
|
|
|
47
57
|
#
|
|
48
58
|
# @param timeout_opts [ContextDev::Models::WebExtractCompetitorsParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
|
|
49
59
|
#
|
|
60
|
+
# @param zdr [Symbol, ContextDev::Models::WebExtractCompetitorsParams::Zdr] Set to enabled to bypass shared caches and omit request and response content fro
|
|
61
|
+
#
|
|
50
62
|
# @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
|
|
51
63
|
|
|
52
64
|
class TimeoutOpts < ContextDev::Internal::Type::BaseModel
|
|
@@ -93,6 +105,21 @@ module ContextDev
|
|
|
93
105
|
# @return [Array<Symbol>]
|
|
94
106
|
end
|
|
95
107
|
end
|
|
108
|
+
|
|
109
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
110
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
111
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
112
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
113
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
114
|
+
module Zdr
|
|
115
|
+
extend ContextDev::Internal::Type::Enum
|
|
116
|
+
|
|
117
|
+
ENABLED = :enabled
|
|
118
|
+
DISABLED = :disabled
|
|
119
|
+
|
|
120
|
+
# @!method self.values
|
|
121
|
+
# @return [Array<Symbol>]
|
|
122
|
+
end
|
|
96
123
|
end
|
|
97
124
|
end
|
|
98
125
|
end
|
|
@@ -55,7 +55,17 @@ module ContextDev
|
|
|
55
55
|
# @return [ContextDev::Models::WebExtractStyleguideParams::TimeoutOpts, nil]
|
|
56
56
|
optional :timeout_opts, -> { ContextDev::WebExtractStyleguideParams::TimeoutOpts }
|
|
57
57
|
|
|
58
|
-
# @!
|
|
58
|
+
# @!attribute zdr
|
|
59
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
60
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
61
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
62
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
63
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
64
|
+
#
|
|
65
|
+
# @return [Symbol, ContextDev::Models::WebExtractStyleguideParams::Zdr, nil]
|
|
66
|
+
optional :zdr, enum: -> { ContextDev::WebExtractStyleguideParams::Zdr }
|
|
67
|
+
|
|
68
|
+
# @!method initialize(color_scheme: nil, direct_url: nil, domain: nil, max_age_ms: nil, tags: nil, timeout_opts: nil, zdr: nil, request_options: {})
|
|
59
69
|
# Some parameter documentations has been truncated, see
|
|
60
70
|
# {ContextDev::Models::WebExtractStyleguideParams} for more details.
|
|
61
71
|
#
|
|
@@ -71,6 +81,8 @@ module ContextDev
|
|
|
71
81
|
#
|
|
72
82
|
# @param timeout_opts [ContextDev::Models::WebExtractStyleguideParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
|
|
73
83
|
#
|
|
84
|
+
# @param zdr [Symbol, ContextDev::Models::WebExtractStyleguideParams::Zdr] Set to enabled to bypass shared caches and omit request and response content fro
|
|
85
|
+
#
|
|
74
86
|
# @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
|
|
75
87
|
|
|
76
88
|
# Optional browser color scheme to emulate for websites that respond to
|
|
@@ -97,7 +109,7 @@ module ContextDev
|
|
|
97
109
|
# credits. "return-partial" returns usable results collected so far; if none are
|
|
98
110
|
# available, the request still fails without charging credits. Partial results are
|
|
99
111
|
# not cached as complete results. "return-partial" requires milliseconds of at
|
|
100
|
-
# least
|
|
112
|
+
# least 5000.
|
|
101
113
|
#
|
|
102
114
|
# @return [Symbol, ContextDev::Models::WebExtractStyleguideParams::TimeoutOpts::Behavior, nil]
|
|
103
115
|
optional :behavior, enum: -> { ContextDev::WebExtractStyleguideParams::TimeoutOpts::Behavior }
|
|
@@ -118,7 +130,7 @@ module ContextDev
|
|
|
118
130
|
# credits. "return-partial" returns usable results collected so far; if none are
|
|
119
131
|
# available, the request still fails without charging credits. Partial results are
|
|
120
132
|
# not cached as complete results. "return-partial" requires milliseconds of at
|
|
121
|
-
# least
|
|
133
|
+
# least 5000.
|
|
122
134
|
#
|
|
123
135
|
# @see ContextDev::Models::WebExtractStyleguideParams::TimeoutOpts#behavior
|
|
124
136
|
module Behavior
|
|
@@ -131,6 +143,21 @@ module ContextDev
|
|
|
131
143
|
# @return [Array<Symbol>]
|
|
132
144
|
end
|
|
133
145
|
end
|
|
146
|
+
|
|
147
|
+
# Set to enabled to bypass shared caches and omit request and response content
|
|
148
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
149
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
150
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
151
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
152
|
+
module Zdr
|
|
153
|
+
extend ContextDev::Internal::Type::Enum
|
|
154
|
+
|
|
155
|
+
ENABLED = :enabled
|
|
156
|
+
DISABLED = :disabled
|
|
157
|
+
|
|
158
|
+
# @!method self.values
|
|
159
|
+
# @return [Array<Symbol>]
|
|
160
|
+
end
|
|
134
161
|
end
|
|
135
162
|
end
|
|
136
163
|
end
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
module ContextDev
|
|
4
4
|
module Models
|
|
5
|
-
# @see ContextDev::Resources::Web#
|
|
6
|
-
class
|
|
5
|
+
# @see ContextDev::Resources::Web#map_urls
|
|
6
|
+
class WebMapURLsParams < ContextDev::Internal::Type::BaseModel
|
|
7
7
|
extend ContextDev::Internal::Type::RequestParameters::Converter
|
|
8
8
|
include ContextDev::Internal::Type::RequestParameters
|
|
9
9
|
|
|
@@ -62,8 +62,8 @@ module ContextDev
|
|
|
62
62
|
# timeoutOpts[milliseconds]=30000&timeoutOpts[behavior]=fail or a JSON-encoded
|
|
63
63
|
# timeoutOpts object.
|
|
64
64
|
#
|
|
65
|
-
# @return [ContextDev::Models::
|
|
66
|
-
optional :timeout_opts, -> { ContextDev::
|
|
65
|
+
# @return [ContextDev::Models::WebMapURLsParams::TimeoutOpts, nil]
|
|
66
|
+
optional :timeout_opts, -> { ContextDev::WebMapURLsParams::TimeoutOpts }
|
|
67
67
|
|
|
68
68
|
# @!attribute url_regex
|
|
69
69
|
# Optional RE2-compatible regex pattern. Only URLs matching this pattern are
|
|
@@ -74,16 +74,17 @@ module ContextDev
|
|
|
74
74
|
|
|
75
75
|
# @!attribute zdr
|
|
76
76
|
# Set to enabled to bypass shared caches and omit request and response content
|
|
77
|
-
# from retained usage logs.
|
|
78
|
-
#
|
|
79
|
-
#
|
|
77
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
78
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
79
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
80
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
80
81
|
#
|
|
81
|
-
# @return [Symbol, ContextDev::Models::
|
|
82
|
-
optional :zdr, enum: -> { ContextDev::
|
|
82
|
+
# @return [Symbol, ContextDev::Models::WebMapURLsParams::Zdr, nil]
|
|
83
|
+
optional :zdr, enum: -> { ContextDev::WebMapURLsParams::Zdr }
|
|
83
84
|
|
|
84
85
|
# @!method initialize(domain:, headers: nil, include_subdomains: nil, max_links: nil, search: nil, sitemap_url: nil, tags: nil, timeout_opts: nil, url_regex: nil, zdr: nil, request_options: {})
|
|
85
86
|
# Some parameter documentations has been truncated, see
|
|
86
|
-
# {ContextDev::Models::
|
|
87
|
+
# {ContextDev::Models::WebMapURLsParams} for more details.
|
|
87
88
|
#
|
|
88
89
|
# @param domain [String] Domain to build a sitemap for
|
|
89
90
|
#
|
|
@@ -99,11 +100,11 @@ module ContextDev
|
|
|
99
100
|
#
|
|
100
101
|
# @param tags [Array<String>] Comma-separated tags for tracking request usage. Up to 20 tags, each 1-50 charac
|
|
101
102
|
#
|
|
102
|
-
# @param timeout_opts [ContextDev::Models::
|
|
103
|
+
# @param timeout_opts [ContextDev::Models::WebMapURLsParams::TimeoutOpts] Optional request deadline and behavior on timeout. For GET requests, use timeout
|
|
103
104
|
#
|
|
104
105
|
# @param url_regex [String] Optional RE2-compatible regex pattern. Only URLs matching this pattern are retur
|
|
105
106
|
#
|
|
106
|
-
# @param zdr [Symbol, ContextDev::Models::
|
|
107
|
+
# @param zdr [Symbol, ContextDev::Models::WebMapURLsParams::Zdr] Set to enabled to bypass shared caches and omit request and response content fro
|
|
107
108
|
#
|
|
108
109
|
# @param request_options [ContextDev::RequestOptions, Hash{Symbol=>Object}]
|
|
109
110
|
|
|
@@ -120,12 +121,12 @@ module ContextDev
|
|
|
120
121
|
# available, the request still fails without charging credits. Partial results are
|
|
121
122
|
# not cached as complete results.
|
|
122
123
|
#
|
|
123
|
-
# @return [Symbol, ContextDev::Models::
|
|
124
|
-
optional :behavior, enum: -> { ContextDev::
|
|
124
|
+
# @return [Symbol, ContextDev::Models::WebMapURLsParams::TimeoutOpts::Behavior, nil]
|
|
125
|
+
optional :behavior, enum: -> { ContextDev::WebMapURLsParams::TimeoutOpts::Behavior }
|
|
125
126
|
|
|
126
127
|
# @!method initialize(milliseconds:, behavior: nil)
|
|
127
128
|
# Some parameter documentations has been truncated, see
|
|
128
|
-
# {ContextDev::Models::
|
|
129
|
+
# {ContextDev::Models::WebMapURLsParams::TimeoutOpts} for more details.
|
|
129
130
|
#
|
|
130
131
|
# Optional request deadline and behavior on timeout. For GET requests, use
|
|
131
132
|
# timeoutOpts[milliseconds]=30000&timeoutOpts[behavior]=fail or a JSON-encoded
|
|
@@ -133,14 +134,14 @@ module ContextDev
|
|
|
133
134
|
#
|
|
134
135
|
# @param milliseconds [Integer] Request deadline in milliseconds. Maximum: 300000 (5 minutes).
|
|
135
136
|
#
|
|
136
|
-
# @param behavior [Symbol, ContextDev::Models::
|
|
137
|
+
# @param behavior [Symbol, ContextDev::Models::WebMapURLsParams::TimeoutOpts::Behavior] What to do at the deadline. "fail" returns 408 REQUEST_TIMEOUT without charging
|
|
137
138
|
|
|
138
139
|
# What to do at the deadline. "fail" returns 408 REQUEST_TIMEOUT without charging
|
|
139
140
|
# credits. "return-partial" returns usable results collected so far; if none are
|
|
140
141
|
# available, the request still fails without charging credits. Partial results are
|
|
141
142
|
# not cached as complete results.
|
|
142
143
|
#
|
|
143
|
-
# @see ContextDev::Models::
|
|
144
|
+
# @see ContextDev::Models::WebMapURLsParams::TimeoutOpts#behavior
|
|
144
145
|
module Behavior
|
|
145
146
|
extend ContextDev::Internal::Type::Enum
|
|
146
147
|
|
|
@@ -153,9 +154,10 @@ module ContextDev
|
|
|
153
154
|
end
|
|
154
155
|
|
|
155
156
|
# Set to enabled to bypass shared caches and omit request and response content
|
|
156
|
-
# from retained usage logs.
|
|
157
|
-
#
|
|
158
|
-
#
|
|
157
|
+
# from retained usage logs. Asset uploads are skipped, so hosted image URLs are
|
|
158
|
+
# omitted. Requires zero data retention to be enabled for your organization
|
|
159
|
+
# (contact support@context.dev), otherwise the request fails with ZDR_NOT_ENABLED.
|
|
160
|
+
# Successful ZDR responses include X-Context-ZDR: true.
|
|
159
161
|
module Zdr
|
|
160
162
|
extend ContextDev::Internal::Type::Enum
|
|
161
163
|
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module ContextDev
|
|
4
|
+
module Models
|
|
5
|
+
# @see ContextDev::Resources::Web#map_urls
|
|
6
|
+
class WebMapURLsResponse < ContextDev::Internal::Type::BaseModel
|
|
7
|
+
# @!attribute domain
|
|
8
|
+
#
|
|
9
|
+
# @return [String]
|
|
10
|
+
required :domain, String
|
|
11
|
+
|
|
12
|
+
# @!attribute request_id
|
|
13
|
+
# Unique id of this API call, also sent in the X-Request-Id response header. Quote
|
|
14
|
+
# it when contacting support about a failed request.
|
|
15
|
+
#
|
|
16
|
+
# @return [String]
|
|
17
|
+
required :request_id, String
|
|
18
|
+
|
|
19
|
+
# @!attribute success
|
|
20
|
+
#
|
|
21
|
+
# @return [Boolean, ContextDev::Models::WebMapURLsResponse::Success]
|
|
22
|
+
required :success, enum: -> { ContextDev::Models::WebMapURLsResponse::Success }
|
|
23
|
+
|
|
24
|
+
# @!attribute urls
|
|
25
|
+
#
|
|
26
|
+
# @return [Array<ContextDev::Models::WebMapURLsResponse::URL>]
|
|
27
|
+
required :urls, -> { ContextDev::Internal::Type::ArrayOf[ContextDev::Models::WebMapURLsResponse::URL] }
|
|
28
|
+
|
|
29
|
+
# @!attribute key_metadata
|
|
30
|
+
# Credit usage, included whenever a valid API key is provided.
|
|
31
|
+
#
|
|
32
|
+
# @return [ContextDev::Models::WebMapURLsResponse::KeyMetadata, nil]
|
|
33
|
+
optional :key_metadata, -> { ContextDev::Models::WebMapURLsResponse::KeyMetadata }
|
|
34
|
+
|
|
35
|
+
# @!attribute partial
|
|
36
|
+
#
|
|
37
|
+
# @return [Boolean, nil]
|
|
38
|
+
optional :partial, ContextDev::Internal::Type::Boolean
|
|
39
|
+
|
|
40
|
+
# @!method initialize(domain:, request_id:, success:, urls:, key_metadata: nil, partial: nil)
|
|
41
|
+
# Some parameter documentations has been truncated, see
|
|
42
|
+
# {ContextDev::Models::WebMapURLsResponse} for more details.
|
|
43
|
+
#
|
|
44
|
+
# @param domain [String]
|
|
45
|
+
#
|
|
46
|
+
# @param request_id [String] Unique id of this API call, also sent in the X-Request-Id response header. Quote
|
|
47
|
+
#
|
|
48
|
+
# @param success [Boolean, ContextDev::Models::WebMapURLsResponse::Success]
|
|
49
|
+
#
|
|
50
|
+
# @param urls [Array<ContextDev::Models::WebMapURLsResponse::URL>]
|
|
51
|
+
#
|
|
52
|
+
# @param key_metadata [ContextDev::Models::WebMapURLsResponse::KeyMetadata] Credit usage, included whenever a valid API key is provided.
|
|
53
|
+
#
|
|
54
|
+
# @param partial [Boolean]
|
|
55
|
+
|
|
56
|
+
# @see ContextDev::Models::WebMapURLsResponse#success
|
|
57
|
+
module Success
|
|
58
|
+
extend ContextDev::Internal::Type::Enum
|
|
59
|
+
|
|
60
|
+
TRUE = true
|
|
61
|
+
|
|
62
|
+
# @!method self.values
|
|
63
|
+
# @return [Array<Boolean>]
|
|
64
|
+
end
|
|
65
|
+
|
|
66
|
+
class URL < ContextDev::Internal::Type::BaseModel
|
|
67
|
+
# @!attribute url
|
|
68
|
+
#
|
|
69
|
+
# @return [String]
|
|
70
|
+
required :url, String
|
|
71
|
+
|
|
72
|
+
# @!attribute description
|
|
73
|
+
#
|
|
74
|
+
# @return [String, nil]
|
|
75
|
+
optional :description, String
|
|
76
|
+
|
|
77
|
+
# @!attribute keywords
|
|
78
|
+
#
|
|
79
|
+
# @return [Array<String>, nil]
|
|
80
|
+
optional :keywords, ContextDev::Internal::Type::ArrayOf[String]
|
|
81
|
+
|
|
82
|
+
# @!attribute language
|
|
83
|
+
#
|
|
84
|
+
# @return [String, nil]
|
|
85
|
+
optional :language, String
|
|
86
|
+
|
|
87
|
+
# @!attribute title
|
|
88
|
+
#
|
|
89
|
+
# @return [String, nil]
|
|
90
|
+
optional :title, String
|
|
91
|
+
|
|
92
|
+
# @!method initialize(url:, description: nil, keywords: nil, language: nil, title: nil)
|
|
93
|
+
# @param url [String]
|
|
94
|
+
# @param description [String]
|
|
95
|
+
# @param keywords [Array<String>]
|
|
96
|
+
# @param language [String]
|
|
97
|
+
# @param title [String]
|
|
98
|
+
end
|
|
99
|
+
|
|
100
|
+
# @see ContextDev::Models::WebMapURLsResponse#key_metadata
|
|
101
|
+
class KeyMetadata < ContextDev::Internal::Type::BaseModel
|
|
102
|
+
# @!attribute credits_consumed
|
|
103
|
+
# Credits used by this request.
|
|
104
|
+
#
|
|
105
|
+
# @return [Integer]
|
|
106
|
+
required :credits_consumed, Integer
|
|
107
|
+
|
|
108
|
+
# @!attribute credits_remaining
|
|
109
|
+
# Credits remaining for your organization.
|
|
110
|
+
#
|
|
111
|
+
# @return [Integer]
|
|
112
|
+
required :credits_remaining, Integer
|
|
113
|
+
|
|
114
|
+
# @!method initialize(credits_consumed:, credits_remaining:)
|
|
115
|
+
# Credit usage, included whenever a valid API key is provided.
|
|
116
|
+
#
|
|
117
|
+
# @param credits_consumed [Integer] Credits used by this request.
|
|
118
|
+
#
|
|
119
|
+
# @param credits_remaining [Integer] Credits remaining for your organization.
|
|
120
|
+
end
|
|
121
|
+
end
|
|
122
|
+
end
|
|
123
|
+
end
|