capistrano-data_plane_api 0.1.4 → 0.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/.rubocop.yml +5 -2
- data/.ruby-version +1 -1
- data/CHANGELOG.md +6 -0
- data/Gemfile +7 -4
- data/Gemfile.lock +108 -69
- data/README.md +5 -0
- data/capistrano-data_plane_api.gemspec +5 -2
- data/exe/cap_data_plane_api +3 -2
- data/lib/capistrano/data_plane_api/configuration/backend.rb +2 -0
- data/lib/capistrano/data_plane_api/configuration/server.rb +4 -2
- data/lib/capistrano/data_plane_api/configuration/symbol.rb +2 -0
- data/lib/capistrano/data_plane_api/configuration.rb +3 -3
- data/lib/capistrano/data_plane_api/deploy/args.rb +71 -40
- data/lib/capistrano/data_plane_api/deploy/deployment_stats.rb +29 -25
- data/lib/capistrano/data_plane_api/deploy/group.rb +33 -24
- data/lib/capistrano/data_plane_api/deploy/helper.rb +3 -5
- data/lib/capistrano/data_plane_api/deploy/server_stats.rb +60 -43
- data/lib/capistrano/data_plane_api/deploy.rb +3 -2
- data/lib/capistrano/data_plane_api/diggable.rb +5 -2
- data/lib/capistrano/data_plane_api/equatable.rb +4 -2
- data/lib/capistrano/data_plane_api/helper.rb +31 -27
- data/lib/capistrano/data_plane_api/hooks.rb +1 -0
- data/lib/capistrano/data_plane_api/show_state.rb +15 -12
- data/lib/capistrano/data_plane_api/tasks.rb +26 -2
- data/lib/capistrano/data_plane_api/terminal_print_loop.rb +7 -4
- data/lib/capistrano/data_plane_api/type.rb +9 -5
- data/lib/capistrano/data_plane_api/version.rb +2 -2
- data/lib/capistrano/data_plane_api.rb +96 -74
- data/lib/capistrano-data_plane_api.rb +4 -0
- data/rbi/capistrano-data_plane_api.rbi +283 -0
- data/sorbet/config +6 -0
- data/sorbet/rbi/annotations/.gitattributes +1 -0
- data/sorbet/rbi/annotations/faraday.rbi +17 -0
- data/sorbet/rbi/annotations/minitest.rbi +119 -0
- data/sorbet/rbi/annotations/rainbow.rbi +269 -0
- data/sorbet/rbi/annotations/webmock.rbi +9 -0
- data/sorbet/rbi/dsl/.gitattributes +1 -0
- data/sorbet/rbi/dsl/capistrano/data_plane_api/configuration/backend.rbi +50 -0
- data/sorbet/rbi/dsl/capistrano/data_plane_api/configuration/server.rbi +24 -0
- data/sorbet/rbi/dsl/capistrano/data_plane_api/configuration.rbi +52 -0
- data/sorbet/rbi/dsl/capistrano/data_plane_api/type.rbi +12 -0
- data/sorbet/rbi/gems/.gitattributes +1 -0
- data/sorbet/rbi/gems/addressable@2.8.7.rbi +1994 -0
- data/sorbet/rbi/gems/ast@2.4.3.rbi +585 -0
- data/sorbet/rbi/gems/base64@0.2.0.rbi +509 -0
- data/sorbet/rbi/gems/bigdecimal@3.1.9.rbi +8 -0
- data/sorbet/rbi/gems/booleans@0.1.3.rbi +28 -0
- data/sorbet/rbi/gems/byebug@12.0.0.rbi +37 -0
- data/sorbet/rbi/gems/crack@1.0.0.rbi +145 -0
- data/sorbet/rbi/gems/data_plane_api@0.2.0.rbi +238 -0
- data/sorbet/rbi/gems/faraday-net_http@3.4.0.rbi +147 -0
- data/sorbet/rbi/gems/faraday@2.13.0.rbi +2974 -0
- data/sorbet/rbi/gems/hashdiff@1.1.2.rbi +353 -0
- data/sorbet/rbi/gems/json@2.10.2.rbi +2113 -0
- data/sorbet/rbi/gems/lint_roller@1.1.0.rbi +240 -0
- data/sorbet/rbi/gems/logger@1.7.0.rbi +963 -0
- data/sorbet/rbi/gems/minitest@5.25.5.rbi +1547 -0
- data/sorbet/rbi/gems/net-http@0.6.0.rbi +4247 -0
- data/sorbet/rbi/gems/parallel@1.26.3.rbi +291 -0
- data/sorbet/rbi/gems/pastel@0.8.0.rbi +733 -0
- data/sorbet/rbi/gems/public_suffix@6.0.1.rbi +936 -0
- data/sorbet/rbi/gems/racc@1.8.1.rbi +160 -0
- data/sorbet/rbi/gems/rainbow@3.1.1.rbi +404 -0
- data/sorbet/rbi/gems/rake@13.0.6.rbi +3030 -0
- data/sorbet/rbi/gems/rexml@3.4.1.rbi +5346 -0
- data/sorbet/rbi/gems/rubocop-espago@1.1.8.rbi +9 -0
- data/sorbet/rbi/gems/ruby-progressbar@1.13.0.rbi +1318 -0
- data/sorbet/rbi/gems/shale-builder@0.2.4.rbi +9 -0
- data/sorbet/rbi/gems/shale@1.2.2.rbi +2323 -0
- data/sorbet/rbi/gems/shoulda-context@2.0.0.rbi +563 -0
- data/sorbet/rbi/gems/strings-ansi@0.2.0.rbi +178 -0
- data/sorbet/rbi/gems/strings@0.2.1.rbi +830 -0
- data/sorbet/rbi/gems/thor@1.2.1.rbi +3957 -0
- data/sorbet/rbi/gems/tty-box@0.7.0.rbi +593 -0
- data/sorbet/rbi/gems/tty-color@0.6.0.rbi +241 -0
- data/sorbet/rbi/gems/tty-cursor@0.7.1.rbi +443 -0
- data/sorbet/rbi/gems/unicode-display_width@2.6.0.rbi +66 -0
- data/sorbet/rbi/gems/unicode_utils@1.4.0.rbi +184 -0
- data/sorbet/rbi/gems/uri@1.0.3.rbi +2349 -0
- data/sorbet/rbi/gems/vcr@6.3.1.rbi +3040 -0
- data/sorbet/rbi/gems/webmock@3.25.1.rbi +1792 -0
- data/sorbet/rbi/shims/gems/faraday.rbi +21 -0
- data/sorbet/rbi/shims/gems/shoulda-context@2.0.0.rbi +15 -0
- data/sorbet/rbi/todo.rbi +7 -0
- data/sorbet/tapioca/config.yml +28 -0
- data/sorbet/tapioca/extensions/load_gem.rb +1 -0
- data/sorbet/tapioca/require.rb +4 -0
- data/templates/bin/deploy.rb +1 -0
- metadata +106 -8
@@ -0,0 +1,2974 @@
|
|
1
|
+
# typed: true
|
2
|
+
|
3
|
+
# DO NOT EDIT MANUALLY
|
4
|
+
# This is an autogenerated file for types exported from the `faraday` gem.
|
5
|
+
# Please instead update this file by running `bin/tapioca gem faraday`.
|
6
|
+
|
7
|
+
|
8
|
+
# conn.get '/'
|
9
|
+
#
|
10
|
+
# source://faraday//lib/faraday/version.rb#3
|
11
|
+
module Faraday
|
12
|
+
class << self
|
13
|
+
# @overload default_adapter
|
14
|
+
# @overload default_adapter=
|
15
|
+
#
|
16
|
+
# source://faraday//lib/faraday.rb#55
|
17
|
+
def default_adapter; end
|
18
|
+
|
19
|
+
# Documented elsewhere, see default_adapter reader
|
20
|
+
#
|
21
|
+
# source://faraday//lib/faraday.rb#102
|
22
|
+
def default_adapter=(adapter); end
|
23
|
+
|
24
|
+
# Option for the default_adapter
|
25
|
+
# @return [Hash] default_adapter options
|
26
|
+
#
|
27
|
+
# source://faraday//lib/faraday.rb#59
|
28
|
+
def default_adapter_options; end
|
29
|
+
|
30
|
+
# Option for the default_adapter
|
31
|
+
# @return [Hash] default_adapter options
|
32
|
+
#
|
33
|
+
# source://faraday//lib/faraday.rb#59
|
34
|
+
def default_adapter_options=(_arg0); end
|
35
|
+
|
36
|
+
# @overload default_connection
|
37
|
+
# @overload default_connection=
|
38
|
+
#
|
39
|
+
# source://faraday//lib/faraday.rb#120
|
40
|
+
def default_connection; end
|
41
|
+
|
42
|
+
# Documented below, see default_connection
|
43
|
+
#
|
44
|
+
# source://faraday//lib/faraday.rb#62
|
45
|
+
def default_connection=(_arg0); end
|
46
|
+
|
47
|
+
# Gets the default connection options used when calling {Faraday#new}.
|
48
|
+
#
|
49
|
+
# @return [Faraday::ConnectionOptions]
|
50
|
+
#
|
51
|
+
# source://faraday//lib/faraday.rb#127
|
52
|
+
def default_connection_options; end
|
53
|
+
|
54
|
+
# Sets the default options used when calling {Faraday#new}.
|
55
|
+
#
|
56
|
+
# @param options [Hash, Faraday::ConnectionOptions]
|
57
|
+
#
|
58
|
+
# source://faraday//lib/faraday.rb#134
|
59
|
+
def default_connection_options=(options); end
|
60
|
+
|
61
|
+
# Tells Faraday to ignore the environment proxy (http_proxy).
|
62
|
+
# Defaults to `false`.
|
63
|
+
#
|
64
|
+
# @return [Boolean]
|
65
|
+
#
|
66
|
+
# source://faraday//lib/faraday.rb#67
|
67
|
+
def ignore_env_proxy; end
|
68
|
+
|
69
|
+
# Tells Faraday to ignore the environment proxy (http_proxy).
|
70
|
+
# Defaults to `false`.
|
71
|
+
#
|
72
|
+
# @return [Boolean]
|
73
|
+
#
|
74
|
+
# source://faraday//lib/faraday.rb#67
|
75
|
+
def ignore_env_proxy=(_arg0); end
|
76
|
+
|
77
|
+
# Gets or sets the path that the Faraday libs are loaded from.
|
78
|
+
#
|
79
|
+
# @return [String]
|
80
|
+
#
|
81
|
+
# source://faraday//lib/faraday.rb#46
|
82
|
+
def lib_path; end
|
83
|
+
|
84
|
+
# Gets or sets the path that the Faraday libs are loaded from.
|
85
|
+
#
|
86
|
+
# @return [String]
|
87
|
+
#
|
88
|
+
# source://faraday//lib/faraday.rb#46
|
89
|
+
def lib_path=(_arg0); end
|
90
|
+
|
91
|
+
# Initializes a new {Connection}.
|
92
|
+
#
|
93
|
+
# @example With an URL argument
|
94
|
+
# Faraday.new 'http://faraday.com'
|
95
|
+
# # => Faraday::Connection to http://faraday.com
|
96
|
+
# @example With everything in an options hash
|
97
|
+
# Faraday.new url: 'http://faraday.com',
|
98
|
+
# params: { page: 1 }
|
99
|
+
# # => Faraday::Connection to http://faraday.com?page=1
|
100
|
+
# @example With an URL argument and an options hash
|
101
|
+
# Faraday.new 'http://faraday.com', params: { page: 1 }
|
102
|
+
# # => Faraday::Connection to http://faraday.com?page=1
|
103
|
+
# @option options
|
104
|
+
# @option options
|
105
|
+
# @option options
|
106
|
+
# @option options
|
107
|
+
# @option options
|
108
|
+
# @option options
|
109
|
+
# @param url [String, Hash] The optional String base URL to use as a prefix
|
110
|
+
# for all requests. Can also be the options Hash. Any of these
|
111
|
+
# values will be set on every request made, unless overridden
|
112
|
+
# for a specific request.
|
113
|
+
# @param options [Hash]
|
114
|
+
# @return [Faraday::Connection]
|
115
|
+
#
|
116
|
+
# source://faraday//lib/faraday.rb#96
|
117
|
+
def new(url = T.unsafe(nil), options = T.unsafe(nil), &block); end
|
118
|
+
|
119
|
+
# @return [Boolean]
|
120
|
+
#
|
121
|
+
# source://faraday//lib/faraday.rb#107
|
122
|
+
def respond_to_missing?(symbol, include_private = T.unsafe(nil)); end
|
123
|
+
|
124
|
+
# The root path that Faraday is being loaded from.
|
125
|
+
#
|
126
|
+
# This is the root from where the libraries are auto-loaded.
|
127
|
+
#
|
128
|
+
# @return [String]
|
129
|
+
#
|
130
|
+
# source://faraday//lib/faraday.rb#42
|
131
|
+
def root_path; end
|
132
|
+
|
133
|
+
# The root path that Faraday is being loaded from.
|
134
|
+
#
|
135
|
+
# This is the root from where the libraries are auto-loaded.
|
136
|
+
#
|
137
|
+
# @return [String]
|
138
|
+
#
|
139
|
+
# source://faraday//lib/faraday.rb#42
|
140
|
+
def root_path=(_arg0); end
|
141
|
+
|
142
|
+
private
|
143
|
+
|
144
|
+
# Internal: Proxies method calls on the Faraday constant to
|
145
|
+
# .default_connection.
|
146
|
+
#
|
147
|
+
# source://faraday//lib/faraday.rb#143
|
148
|
+
def method_missing(name, *args, &block); end
|
149
|
+
end
|
150
|
+
end
|
151
|
+
|
152
|
+
# Base class for all Faraday adapters. Adapters are
|
153
|
+
# responsible for fulfilling a Faraday request.
|
154
|
+
#
|
155
|
+
# source://faraday//lib/faraday/adapter.rb#6
|
156
|
+
class Faraday::Adapter
|
157
|
+
extend ::Faraday::MiddlewareRegistry
|
158
|
+
extend ::Faraday::Adapter::Parallelism
|
159
|
+
|
160
|
+
# @return [Adapter] a new instance of Adapter
|
161
|
+
#
|
162
|
+
# source://faraday//lib/faraday/adapter.rb#28
|
163
|
+
def initialize(_app = T.unsafe(nil), opts = T.unsafe(nil), &block); end
|
164
|
+
|
165
|
+
# source://faraday//lib/faraday/adapter.rb#55
|
166
|
+
def call(env); end
|
167
|
+
|
168
|
+
# Close any persistent connections. The adapter should still be usable
|
169
|
+
# after calling close.
|
170
|
+
#
|
171
|
+
# source://faraday//lib/faraday/adapter.rb#50
|
172
|
+
def close; end
|
173
|
+
|
174
|
+
# Yields or returns an adapter's configured connection. Depends on
|
175
|
+
# #build_connection being defined on this adapter.
|
176
|
+
#
|
177
|
+
# @param env [Faraday::Env, Hash] The env object for a faraday request.
|
178
|
+
# @return The return value of the given block, or the HTTP connection object
|
179
|
+
# if no block is given.
|
180
|
+
# @yield [conn]
|
181
|
+
#
|
182
|
+
# source://faraday//lib/faraday/adapter.rb#41
|
183
|
+
def connection(env); end
|
184
|
+
|
185
|
+
private
|
186
|
+
|
187
|
+
# Fetches either a read, write, or open timeout setting. Defaults to the
|
188
|
+
# :timeout value if a more specific one is not given.
|
189
|
+
#
|
190
|
+
# @param type [Symbol] Describes which timeout setting to get: :read,
|
191
|
+
# :write, or :open.
|
192
|
+
# @param options [Hash] Hash containing Symbol keys like :timeout,
|
193
|
+
# :read_timeout, :write_timeout, or :open_timeout
|
194
|
+
# @return [Integer, nil] Timeout duration in seconds, or nil if no timeout
|
195
|
+
# has been set.
|
196
|
+
#
|
197
|
+
# source://faraday//lib/faraday/adapter.rb#85
|
198
|
+
def request_timeout(type, options); end
|
199
|
+
|
200
|
+
# source://faraday//lib/faraday/adapter.rb#62
|
201
|
+
def save_response(env, status, body, headers = T.unsafe(nil), reason_phrase = T.unsafe(nil), finished: T.unsafe(nil)); end
|
202
|
+
end
|
203
|
+
|
204
|
+
# source://faraday//lib/faraday/adapter.rb#9
|
205
|
+
Faraday::Adapter::CONTENT_LENGTH = T.let(T.unsafe(nil), String)
|
206
|
+
|
207
|
+
# This module marks an Adapter as supporting parallel requests.
|
208
|
+
#
|
209
|
+
# source://faraday//lib/faraday/adapter.rb#12
|
210
|
+
module Faraday::Adapter::Parallelism
|
211
|
+
# source://faraday//lib/faraday/adapter.rb#19
|
212
|
+
def inherited(subclass); end
|
213
|
+
|
214
|
+
# Sets the attribute supports_parallel
|
215
|
+
#
|
216
|
+
# @param value the value to set the attribute supports_parallel to.
|
217
|
+
#
|
218
|
+
# source://faraday//lib/faraday/adapter.rb#13
|
219
|
+
def supports_parallel=(_arg0); end
|
220
|
+
|
221
|
+
# @return [Boolean]
|
222
|
+
#
|
223
|
+
# source://faraday//lib/faraday/adapter.rb#15
|
224
|
+
def supports_parallel?; end
|
225
|
+
end
|
226
|
+
|
227
|
+
# source://faraday//lib/faraday/adapter.rb#93
|
228
|
+
Faraday::Adapter::TIMEOUT_KEYS = T.let(T.unsafe(nil), Hash)
|
229
|
+
|
230
|
+
# @example
|
231
|
+
# test = Faraday::Connection.new do
|
232
|
+
# use Faraday::Adapter::Test do |stub|
|
233
|
+
# # Define matcher to match the request
|
234
|
+
# stub.get '/resource.json' do
|
235
|
+
# # return static content
|
236
|
+
# [200, {'Content-Type' => 'application/json'}, 'hi world']
|
237
|
+
# end
|
238
|
+
#
|
239
|
+
# # response with content generated based on request
|
240
|
+
# stub.get '/showget' do |env|
|
241
|
+
# [200, {'Content-Type' => 'text/plain'}, env[:method].to_s]
|
242
|
+
# end
|
243
|
+
#
|
244
|
+
# # A regular expression can be used as matching filter
|
245
|
+
# stub.get /\A\/items\/(\d+)\z/ do |env, meta|
|
246
|
+
# # in case regular expression is used, an instance of MatchData
|
247
|
+
# # can be received
|
248
|
+
# [200,
|
249
|
+
# {'Content-Type' => 'text/plain'},
|
250
|
+
# "showing item: #{meta[:match_data][1]}"
|
251
|
+
# ]
|
252
|
+
# end
|
253
|
+
#
|
254
|
+
# # Test the request body is the same as the stubbed body
|
255
|
+
# stub.post('/bar', 'name=YK&word=call') { [200, {}, ''] }
|
256
|
+
#
|
257
|
+
# # You can pass a proc as a stubbed body and check the request body in your way.
|
258
|
+
# # In this case, the proc should return true or false.
|
259
|
+
# stub.post('/foo', ->(request_body) do
|
260
|
+
# JSON.parse(request_body).slice('name') == { 'name' => 'YK' } }) { [200, {}, '']
|
261
|
+
# end
|
262
|
+
#
|
263
|
+
# # You can set strict_mode to exactly match the stubbed requests.
|
264
|
+
# stub.strict_mode = true
|
265
|
+
# end
|
266
|
+
# end
|
267
|
+
#
|
268
|
+
# resp = test.get '/resource.json'
|
269
|
+
# resp.body # => 'hi world'
|
270
|
+
#
|
271
|
+
# resp = test.get '/showget'
|
272
|
+
# resp.body # => 'get'
|
273
|
+
#
|
274
|
+
# resp = test.get '/items/1'
|
275
|
+
# resp.body # => 'showing item: 1'
|
276
|
+
#
|
277
|
+
# resp = test.get '/items/2'
|
278
|
+
# resp.body # => 'showing item: 2'
|
279
|
+
#
|
280
|
+
# resp = test.post '/bar', 'name=YK&word=call'
|
281
|
+
# resp.status # => 200
|
282
|
+
#
|
283
|
+
# resp = test.post '/foo', JSON.dump(name: 'YK', created_at: Time.now)
|
284
|
+
# resp.status # => 200
|
285
|
+
#
|
286
|
+
# source://faraday//lib/faraday/adapter/test.rb#62
|
287
|
+
class Faraday::Adapter::Test < ::Faraday::Adapter
|
288
|
+
# @return [Test] a new instance of Test
|
289
|
+
#
|
290
|
+
# source://faraday//lib/faraday/adapter/test.rb#258
|
291
|
+
def initialize(app, stubs = T.unsafe(nil), &block); end
|
292
|
+
|
293
|
+
# @param env [Faraday::Env]
|
294
|
+
#
|
295
|
+
# source://faraday//lib/faraday/adapter/test.rb#269
|
296
|
+
def call(env); end
|
297
|
+
|
298
|
+
# @yield [stubs]
|
299
|
+
#
|
300
|
+
# source://faraday//lib/faraday/adapter/test.rb#264
|
301
|
+
def configure; end
|
302
|
+
|
303
|
+
# Returns the value of attribute stubs.
|
304
|
+
#
|
305
|
+
# source://faraday//lib/faraday/adapter/test.rb#63
|
306
|
+
def stubs; end
|
307
|
+
|
308
|
+
# Sets the attribute stubs
|
309
|
+
#
|
310
|
+
# @param value the value to set the attribute stubs to.
|
311
|
+
#
|
312
|
+
# source://faraday//lib/faraday/adapter/test.rb#63
|
313
|
+
def stubs=(_arg0); end
|
314
|
+
end
|
315
|
+
|
316
|
+
# Stub request
|
317
|
+
#
|
318
|
+
# source://faraday//lib/faraday/adapter/test.rb#187
|
319
|
+
class Faraday::Adapter::Test::Stub < ::Struct
|
320
|
+
# Returns the value of attribute block
|
321
|
+
#
|
322
|
+
# @return [Object] the current value of block
|
323
|
+
def block; end
|
324
|
+
|
325
|
+
# Sets the attribute block
|
326
|
+
#
|
327
|
+
# @param value [Object] the value to set the attribute block to.
|
328
|
+
# @return [Object] the newly set value
|
329
|
+
def block=(_); end
|
330
|
+
|
331
|
+
# Returns the value of attribute body
|
332
|
+
#
|
333
|
+
# @return [Object] the current value of body
|
334
|
+
def body; end
|
335
|
+
|
336
|
+
# Sets the attribute body
|
337
|
+
#
|
338
|
+
# @param value [Object] the value to set the attribute body to.
|
339
|
+
# @return [Object] the newly set value
|
340
|
+
def body=(_); end
|
341
|
+
|
342
|
+
# @return [Boolean]
|
343
|
+
#
|
344
|
+
# source://faraday//lib/faraday/adapter/test.rb#242
|
345
|
+
def body_match?(request_body); end
|
346
|
+
|
347
|
+
# Returns the value of attribute headers
|
348
|
+
#
|
349
|
+
# @return [Object] the current value of headers
|
350
|
+
def headers; end
|
351
|
+
|
352
|
+
# Sets the attribute headers
|
353
|
+
#
|
354
|
+
# @param value [Object] the value to set the attribute headers to.
|
355
|
+
# @return [Object] the newly set value
|
356
|
+
def headers=(_); end
|
357
|
+
|
358
|
+
# @return [Boolean]
|
359
|
+
#
|
360
|
+
# source://faraday//lib/faraday/adapter/test.rb#227
|
361
|
+
def headers_match?(request_headers); end
|
362
|
+
|
363
|
+
# Returns the value of attribute host
|
364
|
+
#
|
365
|
+
# @return [Object] the current value of host
|
366
|
+
def host; end
|
367
|
+
|
368
|
+
# Sets the attribute host
|
369
|
+
#
|
370
|
+
# @param value [Object] the value to set the attribute host to.
|
371
|
+
# @return [Object] the newly set value
|
372
|
+
def host=(_); end
|
373
|
+
|
374
|
+
# @param env [Faraday::Env]
|
375
|
+
# @return [Boolean]
|
376
|
+
#
|
377
|
+
# source://faraday//lib/faraday/adapter/test.rb#189
|
378
|
+
def matches?(env); end
|
379
|
+
|
380
|
+
# @param env [Faraday::Env]
|
381
|
+
# @return [Boolean]
|
382
|
+
#
|
383
|
+
# source://faraday//lib/faraday/adapter/test.rb#214
|
384
|
+
def params_match?(env); end
|
385
|
+
|
386
|
+
# Returns the value of attribute path
|
387
|
+
#
|
388
|
+
# @return [Object] the current value of path
|
389
|
+
def path; end
|
390
|
+
|
391
|
+
# Sets the attribute path
|
392
|
+
#
|
393
|
+
# @param value [Object] the value to set the attribute path to.
|
394
|
+
# @return [Object] the newly set value
|
395
|
+
def path=(_); end
|
396
|
+
|
397
|
+
# @return [Boolean]
|
398
|
+
#
|
399
|
+
# source://faraday//lib/faraday/adapter/test.rb#205
|
400
|
+
def path_match?(request_path, meta); end
|
401
|
+
|
402
|
+
# Returns the value of attribute query
|
403
|
+
#
|
404
|
+
# @return [Object] the current value of query
|
405
|
+
def query; end
|
406
|
+
|
407
|
+
# Sets the attribute query
|
408
|
+
#
|
409
|
+
# @param value [Object] the value to set the attribute query to.
|
410
|
+
# @return [Object] the newly set value
|
411
|
+
def query=(_); end
|
412
|
+
|
413
|
+
# Returns the value of attribute strict_mode
|
414
|
+
#
|
415
|
+
# @return [Object] the current value of strict_mode
|
416
|
+
def strict_mode; end
|
417
|
+
|
418
|
+
# Sets the attribute strict_mode
|
419
|
+
#
|
420
|
+
# @param value [Object] the value to set the attribute strict_mode to.
|
421
|
+
# @return [Object] the newly set value
|
422
|
+
def strict_mode=(_); end
|
423
|
+
|
424
|
+
# source://faraday//lib/faraday/adapter/test.rb#253
|
425
|
+
def to_s; end
|
426
|
+
|
427
|
+
class << self
|
428
|
+
def [](*_arg0); end
|
429
|
+
def inspect; end
|
430
|
+
def keyword_init?; end
|
431
|
+
def members; end
|
432
|
+
def new(*_arg0); end
|
433
|
+
end
|
434
|
+
end
|
435
|
+
|
436
|
+
# A stack of Stubs
|
437
|
+
#
|
438
|
+
# source://faraday//lib/faraday/adapter/test.rb#66
|
439
|
+
class Faraday::Adapter::Test::Stubs
|
440
|
+
# @return [Stubs] a new instance of Stubs
|
441
|
+
# @yield [_self]
|
442
|
+
# @yieldparam _self [Faraday::Adapter::Test::Stubs] the object that the method was called on
|
443
|
+
#
|
444
|
+
# source://faraday//lib/faraday/adapter/test.rb#70
|
445
|
+
def initialize(strict_mode: T.unsafe(nil)); end
|
446
|
+
|
447
|
+
# source://faraday//lib/faraday/adapter/test.rb#122
|
448
|
+
def delete(path, headers = T.unsafe(nil), &block); end
|
449
|
+
|
450
|
+
# @return [Boolean]
|
451
|
+
#
|
452
|
+
# source://faraday//lib/faraday/adapter/test.rb#79
|
453
|
+
def empty?; end
|
454
|
+
|
455
|
+
# source://faraday//lib/faraday/adapter/test.rb#102
|
456
|
+
def get(path, headers = T.unsafe(nil), &block); end
|
457
|
+
|
458
|
+
# source://faraday//lib/faraday/adapter/test.rb#106
|
459
|
+
def head(path, headers = T.unsafe(nil), &block); end
|
460
|
+
|
461
|
+
# @param env [Faraday::Env]
|
462
|
+
#
|
463
|
+
# source://faraday//lib/faraday/adapter/test.rb#84
|
464
|
+
def match(env); end
|
465
|
+
|
466
|
+
# source://faraday//lib/faraday/adapter/test.rb#126
|
467
|
+
def options(path, headers = T.unsafe(nil), &block); end
|
468
|
+
|
469
|
+
# source://faraday//lib/faraday/adapter/test.rb#118
|
470
|
+
def patch(path, body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
471
|
+
|
472
|
+
# source://faraday//lib/faraday/adapter/test.rb#110
|
473
|
+
def post(path, body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
474
|
+
|
475
|
+
# source://faraday//lib/faraday/adapter/test.rb#114
|
476
|
+
def put(path, body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
477
|
+
|
478
|
+
# Set strict_mode. If the value is true, this adapter tries to find matched requests strictly,
|
479
|
+
# which means that all of a path, parameters, and headers must be the same as an actual request.
|
480
|
+
#
|
481
|
+
# source://faraday//lib/faraday/adapter/test.rb#147
|
482
|
+
def strict_mode=(value); end
|
483
|
+
|
484
|
+
# Raises an error if any of the stubbed calls have not been made.
|
485
|
+
#
|
486
|
+
# source://faraday//lib/faraday/adapter/test.rb#131
|
487
|
+
def verify_stubbed_calls; end
|
488
|
+
|
489
|
+
protected
|
490
|
+
|
491
|
+
# @param stack [Hash]
|
492
|
+
# @param env [Faraday::Env]
|
493
|
+
# @return [Boolean]
|
494
|
+
#
|
495
|
+
# source://faraday//lib/faraday/adapter/test.rb#177
|
496
|
+
def matches?(stack, env); end
|
497
|
+
|
498
|
+
# source://faraday//lib/faraday/adapter/test.rb#158
|
499
|
+
def new_stub(request_method, path, headers = T.unsafe(nil), body = T.unsafe(nil), &block); end
|
500
|
+
end
|
501
|
+
|
502
|
+
# source://faraday//lib/faraday/adapter/test.rb#67
|
503
|
+
class Faraday::Adapter::Test::Stubs::NotFound < ::StandardError; end
|
504
|
+
|
505
|
+
# AdapterRegistry registers adapter class names so they can be looked up by a
|
506
|
+
# String or Symbol name.
|
507
|
+
#
|
508
|
+
# source://faraday//lib/faraday/adapter_registry.rb#8
|
509
|
+
class Faraday::AdapterRegistry
|
510
|
+
# @return [AdapterRegistry] a new instance of AdapterRegistry
|
511
|
+
#
|
512
|
+
# source://faraday//lib/faraday/adapter_registry.rb#9
|
513
|
+
def initialize; end
|
514
|
+
|
515
|
+
# source://faraday//lib/faraday/adapter_registry.rb#14
|
516
|
+
def get(name); end
|
517
|
+
|
518
|
+
# source://faraday//lib/faraday/adapter_registry.rb#23
|
519
|
+
def set(klass, name = T.unsafe(nil)); end
|
520
|
+
end
|
521
|
+
|
522
|
+
# Raised by Faraday::Response::RaiseError in case of a 400 response.
|
523
|
+
#
|
524
|
+
# source://faraday//lib/faraday/error.rb#96
|
525
|
+
class Faraday::BadRequestError < ::Faraday::ClientError; end
|
526
|
+
|
527
|
+
# source://faraday//lib/faraday.rb#34
|
528
|
+
Faraday::CONTENT_TYPE = T.let(T.unsafe(nil), String)
|
529
|
+
|
530
|
+
# Faraday client error class. Represents 4xx status responses.
|
531
|
+
#
|
532
|
+
# source://faraday//lib/faraday/error.rb#92
|
533
|
+
class Faraday::ClientError < ::Faraday::Error; end
|
534
|
+
|
535
|
+
# Raised by Faraday::Response::RaiseError in case of a 409 response.
|
536
|
+
#
|
537
|
+
# source://faraday//lib/faraday/error.rb#120
|
538
|
+
class Faraday::ConflictError < ::Faraday::ClientError; end
|
539
|
+
|
540
|
+
# Connection objects manage the default properties and the middleware
|
541
|
+
# stack for fulfilling an HTTP request.
|
542
|
+
#
|
543
|
+
# @example
|
544
|
+
#
|
545
|
+
# conn = Faraday::Connection.new 'http://httpbingo.org'
|
546
|
+
#
|
547
|
+
# # GET http://httpbingo.org/nigiri
|
548
|
+
# conn.get 'nigiri'
|
549
|
+
# # => #<Faraday::Response>
|
550
|
+
#
|
551
|
+
# source://faraday//lib/faraday/connection.rb#15
|
552
|
+
class Faraday::Connection
|
553
|
+
extend ::Forwardable
|
554
|
+
|
555
|
+
# Initializes a new Faraday::Connection.
|
556
|
+
#
|
557
|
+
# @option options
|
558
|
+
# @option options
|
559
|
+
# @option options
|
560
|
+
# @option options
|
561
|
+
# @option options
|
562
|
+
# @option options
|
563
|
+
# @option options
|
564
|
+
# @option options
|
565
|
+
# @option options
|
566
|
+
# @param url [URI, String] URI or String base URL to use as a prefix for all
|
567
|
+
# requests (optional).
|
568
|
+
# @param options [Hash, Faraday::ConnectionOptions]
|
569
|
+
# @return [Connection] a new instance of Connection
|
570
|
+
# @yield [self] after all setup has been done
|
571
|
+
#
|
572
|
+
# source://faraday//lib/faraday/connection.rb#63
|
573
|
+
def initialize(url = T.unsafe(nil), options = T.unsafe(nil)); end
|
574
|
+
|
575
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
576
|
+
def adapter(*args, **_arg1, &block); end
|
577
|
+
|
578
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
579
|
+
def app(*args, **_arg1, &block); end
|
580
|
+
|
581
|
+
# Build an absolute URL based on url_prefix.
|
582
|
+
#
|
583
|
+
# of the resulting url (default: nil).
|
584
|
+
#
|
585
|
+
# @param url [String, URI, nil]
|
586
|
+
# @param params [Faraday::Utils::ParamsHash] A Faraday::Utils::ParamsHash to
|
587
|
+
# replace the query values
|
588
|
+
# @return [URI]
|
589
|
+
#
|
590
|
+
# source://faraday//lib/faraday/connection.rb#478
|
591
|
+
def build_exclusive_url(url = T.unsafe(nil), params = T.unsafe(nil), params_encoder = T.unsafe(nil)); end
|
592
|
+
|
593
|
+
# Creates and configures the request object.
|
594
|
+
#
|
595
|
+
# @param method [Symbol]
|
596
|
+
# @return [Faraday::Request]
|
597
|
+
# @yield [Faraday::Request] if block given
|
598
|
+
#
|
599
|
+
# source://faraday//lib/faraday/connection.rb#461
|
600
|
+
def build_request(method); end
|
601
|
+
|
602
|
+
# Takes a relative url for a request and combines it with the defaults
|
603
|
+
# set on the connection instance.
|
604
|
+
#
|
605
|
+
# @example
|
606
|
+
# conn = Faraday::Connection.new { ... }
|
607
|
+
# conn.url_prefix = "https://httpbingo.org/api?token=abc"
|
608
|
+
# conn.scheme # => https
|
609
|
+
# conn.path_prefix # => "/api"
|
610
|
+
#
|
611
|
+
# conn.build_url("nigiri?page=2")
|
612
|
+
# # => https://httpbingo.org/api/nigiri?token=abc&page=2
|
613
|
+
#
|
614
|
+
# conn.build_url("nigiri", page: 2)
|
615
|
+
# # => https://httpbingo.org/api/nigiri?token=abc&page=2
|
616
|
+
# @param url [String, URI, nil]
|
617
|
+
# @param extra_params [Hash]
|
618
|
+
#
|
619
|
+
# source://faraday//lib/faraday/connection.rb#415
|
620
|
+
def build_url(url = T.unsafe(nil), extra_params = T.unsafe(nil)); end
|
621
|
+
|
622
|
+
# @return [Faraday::RackBuilder] Builder for this Connection.
|
623
|
+
#
|
624
|
+
# source://faraday//lib/faraday/connection.rb#31
|
625
|
+
def builder; end
|
626
|
+
|
627
|
+
# Closes the underlying resources and/or connections. In the case of
|
628
|
+
# persistent connections, this closes all currently open connections
|
629
|
+
# but does not prevent new connections from being made.
|
630
|
+
#
|
631
|
+
# source://faraday//lib/faraday/connection.rb#125
|
632
|
+
def close; end
|
633
|
+
|
634
|
+
# Check if the adapter is parallel-capable.
|
635
|
+
#
|
636
|
+
# @api private
|
637
|
+
# @return [Object, nil] a parallel manager or nil if yielded
|
638
|
+
# @yield if the adapter isn't parallel-capable, or if no adapter is set yet.
|
639
|
+
#
|
640
|
+
# source://faraday//lib/faraday/connection.rb#291
|
641
|
+
def default_parallel_manager; end
|
642
|
+
|
643
|
+
# Sets the default parallel manager for this connection.
|
644
|
+
#
|
645
|
+
# source://faraday//lib/faraday/connection.rb#40
|
646
|
+
def default_parallel_manager=(_arg0); end
|
647
|
+
|
648
|
+
# source://faraday//lib/faraday/connection.rb#199
|
649
|
+
def delete(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
650
|
+
|
651
|
+
# Creates a duplicate of this Faraday::Connection.
|
652
|
+
#
|
653
|
+
# @api private
|
654
|
+
# @return [Faraday::Connection]
|
655
|
+
#
|
656
|
+
# source://faraday//lib/faraday/connection.rb#499
|
657
|
+
def dup; end
|
658
|
+
|
659
|
+
# source://faraday//lib/faraday/connection.rb#542
|
660
|
+
def find_default_proxy; end
|
661
|
+
|
662
|
+
# source://faraday//lib/faraday/connection.rb#199
|
663
|
+
def get(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
664
|
+
|
665
|
+
# source://faraday//lib/faraday/connection.rb#199
|
666
|
+
def head(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
667
|
+
|
668
|
+
# @return [Hash] unencoded HTTP header key/value pairs.
|
669
|
+
#
|
670
|
+
# source://faraday//lib/faraday/connection.rb#24
|
671
|
+
def headers; end
|
672
|
+
|
673
|
+
# Sets the Hash of unencoded HTTP header key/value pairs.
|
674
|
+
#
|
675
|
+
# @param hash [Hash]
|
676
|
+
#
|
677
|
+
# source://faraday//lib/faraday/connection.rb#114
|
678
|
+
def headers=(hash); end
|
679
|
+
|
680
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
681
|
+
def host(*args, **_arg1, &block); end
|
682
|
+
|
683
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
684
|
+
def host=(*args, **_arg1, &block); end
|
685
|
+
|
686
|
+
# Sets up the parallel manager to make a set of requests.
|
687
|
+
#
|
688
|
+
# @param manager [Object] The parallel manager that this Connection's
|
689
|
+
# Adapter uses.
|
690
|
+
# @return [void]
|
691
|
+
# @yield a block to execute multiple requests.
|
692
|
+
#
|
693
|
+
# source://faraday//lib/faraday/connection.rb#317
|
694
|
+
def in_parallel(manager = T.unsafe(nil), &block); end
|
695
|
+
|
696
|
+
# Determine if this Faraday::Connection can make parallel requests.
|
697
|
+
#
|
698
|
+
# @return [Boolean]
|
699
|
+
#
|
700
|
+
# source://faraday//lib/faraday/connection.rb#306
|
701
|
+
def in_parallel?; end
|
702
|
+
|
703
|
+
# source://faraday//lib/faraday/connection.rb#96
|
704
|
+
def initialize_proxy(url, options); end
|
705
|
+
|
706
|
+
# @example
|
707
|
+
# conn.options '/items/1'
|
708
|
+
# @overload options
|
709
|
+
# @overload options
|
710
|
+
# @return [Faraday::Response]
|
711
|
+
# @yield [Faraday::Request] for further request customizations
|
712
|
+
#
|
713
|
+
# source://faraday//lib/faraday/connection.rb#222
|
714
|
+
def options(*args); end
|
715
|
+
|
716
|
+
# @return [Object] the parallel manager for this Connection.
|
717
|
+
#
|
718
|
+
# source://faraday//lib/faraday/connection.rb#37
|
719
|
+
def parallel_manager; end
|
720
|
+
|
721
|
+
# @return [Hash] URI query unencoded key/value pairs.
|
722
|
+
#
|
723
|
+
# source://faraday//lib/faraday/connection.rb#21
|
724
|
+
def params; end
|
725
|
+
|
726
|
+
# Sets the Hash of URI query unencoded key/value pairs.
|
727
|
+
#
|
728
|
+
# @param hash [Hash]
|
729
|
+
#
|
730
|
+
# source://faraday//lib/faraday/connection.rb#108
|
731
|
+
def params=(hash); end
|
732
|
+
|
733
|
+
# source://faraday//lib/faraday/connection.rb#279
|
734
|
+
def patch(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
735
|
+
|
736
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
737
|
+
def path_prefix(*args, **_arg1, &block); end
|
738
|
+
|
739
|
+
# Sets the path prefix and ensures that it always has a leading
|
740
|
+
# slash.
|
741
|
+
#
|
742
|
+
# @param value [String]
|
743
|
+
# @return [String] the new path prefix
|
744
|
+
#
|
745
|
+
# source://faraday//lib/faraday/connection.rb#390
|
746
|
+
def path_prefix=(value); end
|
747
|
+
|
748
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
749
|
+
def port(*args, **_arg1, &block); end
|
750
|
+
|
751
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
752
|
+
def port=(*args, **_arg1, &block); end
|
753
|
+
|
754
|
+
# source://faraday//lib/faraday/connection.rb#279
|
755
|
+
def post(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
756
|
+
|
757
|
+
# @return [Hash] proxy options.
|
758
|
+
#
|
759
|
+
# source://faraday//lib/faraday/connection.rb#43
|
760
|
+
def proxy; end
|
761
|
+
|
762
|
+
# Sets the Hash proxy options.
|
763
|
+
#
|
764
|
+
# @param new_value [Object]
|
765
|
+
#
|
766
|
+
# source://faraday//lib/faraday/connection.rb#341
|
767
|
+
def proxy=(new_value); end
|
768
|
+
|
769
|
+
# source://faraday//lib/faraday/connection.rb#550
|
770
|
+
def proxy_for_request(url); end
|
771
|
+
|
772
|
+
# source://faraday//lib/faraday/connection.rb#522
|
773
|
+
def proxy_from_env(url); end
|
774
|
+
|
775
|
+
# source://faraday//lib/faraday/connection.rb#279
|
776
|
+
def put(url = T.unsafe(nil), body = T.unsafe(nil), headers = T.unsafe(nil), &block); end
|
777
|
+
|
778
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
779
|
+
def request(*args, **_arg1, &block); end
|
780
|
+
|
781
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
782
|
+
def response(*args, **_arg1, &block); end
|
783
|
+
|
784
|
+
# Builds and runs the Faraday::Request.
|
785
|
+
#
|
786
|
+
# @param method [Symbol] HTTP method.
|
787
|
+
# @param url [String, URI, nil] String or URI to access.
|
788
|
+
# @param body [String, Hash, Array, nil] The request body that will eventually be converted to
|
789
|
+
# a string; middlewares can be used to support more complex types.
|
790
|
+
# @param headers [Hash, nil] unencoded HTTP header key/value pairs.
|
791
|
+
# @return [Faraday::Response]
|
792
|
+
#
|
793
|
+
# source://faraday//lib/faraday/connection.rb#439
|
794
|
+
def run_request(method, url, body, headers); end
|
795
|
+
|
796
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
797
|
+
def scheme(*args, **_arg1, &block); end
|
798
|
+
|
799
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
800
|
+
def scheme=(*args, **_arg1, &block); end
|
801
|
+
|
802
|
+
# source://faraday//lib/faraday/connection.rb#379
|
803
|
+
def set_basic_auth(user, password); end
|
804
|
+
|
805
|
+
# @return [Hash] SSL options.
|
806
|
+
#
|
807
|
+
# source://faraday//lib/faraday/connection.rb#34
|
808
|
+
def ssl; end
|
809
|
+
|
810
|
+
# @return [Boolean]
|
811
|
+
#
|
812
|
+
# source://faraday//lib/faraday/connection.rb#560
|
813
|
+
def support_parallel?(adapter); end
|
814
|
+
|
815
|
+
# source://faraday//lib/faraday/connection.rb#199
|
816
|
+
def trace(url = T.unsafe(nil), params = T.unsafe(nil), headers = T.unsafe(nil)); end
|
817
|
+
|
818
|
+
# @return [String] a URI with the prefix used for all requests from this
|
819
|
+
# Connection. This includes a default host name, scheme, port, and path.
|
820
|
+
#
|
821
|
+
# source://faraday//lib/faraday/connection.rb#28
|
822
|
+
def url_prefix; end
|
823
|
+
|
824
|
+
# Parses the given URL with URI and stores the individual
|
825
|
+
# components in this connection. These components serve as defaults for
|
826
|
+
# requests made by this connection.
|
827
|
+
#
|
828
|
+
# @example
|
829
|
+
#
|
830
|
+
# conn = Faraday::Connection.new { ... }
|
831
|
+
# conn.url_prefix = "https://httpbingo.org/api"
|
832
|
+
# conn.scheme # => https
|
833
|
+
# conn.path_prefix # => "/api"
|
834
|
+
#
|
835
|
+
# conn.get("nigiri?page=2") # accesses https://httpbingo.org/api/nigiri
|
836
|
+
# @param url [String, URI]
|
837
|
+
# @param encoder [Object]
|
838
|
+
#
|
839
|
+
# source://faraday//lib/faraday/connection.rb#364
|
840
|
+
def url_prefix=(url, encoder = T.unsafe(nil)); end
|
841
|
+
|
842
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
843
|
+
def use(*args, **_arg1, &block); end
|
844
|
+
|
845
|
+
# Yields username and password extracted from a URI if they both exist.
|
846
|
+
#
|
847
|
+
# @api private
|
848
|
+
# @param uri [URI]
|
849
|
+
# @return [void]
|
850
|
+
# @yield [username, password] any username and password
|
851
|
+
# @yieldparam username [String] any username from URI
|
852
|
+
# @yieldparam password [String] any password from URI
|
853
|
+
#
|
854
|
+
# source://faraday//lib/faraday/connection.rb#516
|
855
|
+
def with_uri_credentials(uri); end
|
856
|
+
end
|
857
|
+
|
858
|
+
# A Set of allowed HTTP verbs.
|
859
|
+
#
|
860
|
+
# source://faraday//lib/faraday/connection.rb#17
|
861
|
+
Faraday::Connection::METHODS = T.let(T.unsafe(nil), Set)
|
862
|
+
|
863
|
+
# source://faraday//lib/faraday/connection.rb#18
|
864
|
+
Faraday::Connection::USER_AGENT = T.let(T.unsafe(nil), String)
|
865
|
+
|
866
|
+
# A unified error for failed connections.
|
867
|
+
#
|
868
|
+
# source://faraday//lib/faraday/error.rb#151
|
869
|
+
class Faraday::ConnectionFailed < ::Faraday::Error; end
|
870
|
+
|
871
|
+
# ConnectionOptions contains the configurable properties for a Faraday
|
872
|
+
# connection object.
|
873
|
+
#
|
874
|
+
# source://faraday//lib/faraday/options/connection_options.rb#8
|
875
|
+
class Faraday::ConnectionOptions < ::Faraday::Options
|
876
|
+
def builder; end
|
877
|
+
def builder=(_); end
|
878
|
+
|
879
|
+
# source://faraday//lib/faraday/options.rb#178
|
880
|
+
def builder_class; end
|
881
|
+
|
882
|
+
def builder_class=(_); end
|
883
|
+
def headers; end
|
884
|
+
def headers=(_); end
|
885
|
+
|
886
|
+
# source://faraday//lib/faraday/options/connection_options.rb#19
|
887
|
+
def new_builder(block); end
|
888
|
+
|
889
|
+
def parallel_manager; end
|
890
|
+
def parallel_manager=(_); end
|
891
|
+
def params; end
|
892
|
+
def params=(_); end
|
893
|
+
def proxy; end
|
894
|
+
def proxy=(_); end
|
895
|
+
|
896
|
+
# source://faraday//lib/faraday/options.rb#178
|
897
|
+
def request; end
|
898
|
+
|
899
|
+
def request=(_); end
|
900
|
+
|
901
|
+
# source://faraday//lib/faraday/options.rb#178
|
902
|
+
def ssl; end
|
903
|
+
|
904
|
+
def ssl=(_); end
|
905
|
+
def url; end
|
906
|
+
def url=(_); end
|
907
|
+
|
908
|
+
class << self
|
909
|
+
def [](*_arg0); end
|
910
|
+
def inspect; end
|
911
|
+
def keyword_init?; end
|
912
|
+
def members; end
|
913
|
+
def new(*_arg0); end
|
914
|
+
end
|
915
|
+
end
|
916
|
+
|
917
|
+
# Sub-module for decoding query-string into parameters.
|
918
|
+
#
|
919
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#81
|
920
|
+
module Faraday::DecodeMethods
|
921
|
+
# @param query [nil, String]
|
922
|
+
# @raise [TypeError] if the nesting is incorrect
|
923
|
+
# @return [Array<Array, String>] the decoded params
|
924
|
+
#
|
925
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#87
|
926
|
+
def decode(query); end
|
927
|
+
|
928
|
+
protected
|
929
|
+
|
930
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#144
|
931
|
+
def add_to_context(is_array, context, value, subkey); end
|
932
|
+
|
933
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#107
|
934
|
+
def decode_pair(key, value, context); end
|
935
|
+
|
936
|
+
# Internal: convert a nested hash with purely numeric keys into an array.
|
937
|
+
# FIXME: this is not compatible with Rack::Utils.parse_nested_query
|
938
|
+
#
|
939
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#151
|
940
|
+
def dehash(hash, depth); end
|
941
|
+
|
942
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#139
|
943
|
+
def match_context(context, subkey); end
|
944
|
+
|
945
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#129
|
946
|
+
def new_context(subkey, is_array, context); end
|
947
|
+
|
948
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#119
|
949
|
+
def prepare_context(context, subkey, is_array, last_subkey); end
|
950
|
+
end
|
951
|
+
|
952
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#105
|
953
|
+
Faraday::DecodeMethods::SUBKEYS_REGEX = T.let(T.unsafe(nil), Regexp)
|
954
|
+
|
955
|
+
# Sub-module for encoding parameters into query-string.
|
956
|
+
#
|
957
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#5
|
958
|
+
module Faraday::EncodeMethods
|
959
|
+
# @param params [nil, Array, #to_hash] parameters to be encoded
|
960
|
+
# @raise [TypeError] if params can not be converted to a Hash
|
961
|
+
# @return [String] the encoded params
|
962
|
+
#
|
963
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#11
|
964
|
+
def encode(params); end
|
965
|
+
|
966
|
+
protected
|
967
|
+
|
968
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#64
|
969
|
+
def encode_array(parent, value); end
|
970
|
+
|
971
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#53
|
972
|
+
def encode_hash(parent, value); end
|
973
|
+
|
974
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#40
|
975
|
+
def encode_pair(parent, value); end
|
976
|
+
end
|
977
|
+
|
978
|
+
# source://faraday//lib/faraday/options/env.rb#57
|
979
|
+
class Faraday::Env < ::Faraday::Options
|
980
|
+
extend ::Forwardable
|
981
|
+
|
982
|
+
# source://faraday//lib/faraday/options/env.rb#89
|
983
|
+
def [](key); end
|
984
|
+
|
985
|
+
# source://faraday//lib/faraday/options/env.rb#101
|
986
|
+
def []=(key, value); end
|
987
|
+
|
988
|
+
# string.
|
989
|
+
#
|
990
|
+
# @return [String] The request body that will eventually be converted to a
|
991
|
+
#
|
992
|
+
# source://faraday//lib/faraday/options/env.rb#118
|
993
|
+
def body; end
|
994
|
+
|
995
|
+
# string.
|
996
|
+
#
|
997
|
+
# @return [String] The request body that will eventually be converted to a
|
998
|
+
#
|
999
|
+
# source://faraday//lib/faraday/options/env.rb#122
|
1000
|
+
def body=(value); end
|
1001
|
+
|
1002
|
+
# source://faraday//lib/faraday/options/env.rb#138
|
1003
|
+
def clear_body; end
|
1004
|
+
|
1005
|
+
# source://faraday//lib/faraday/options/env.rb#114
|
1006
|
+
def current_body; end
|
1007
|
+
|
1008
|
+
# source://faraday//lib/faraday/options/env.rb#184
|
1009
|
+
def custom_members; end
|
1010
|
+
|
1011
|
+
# source://faraday//lib/faraday/options/env.rb#190
|
1012
|
+
def in_member_set?(key); end
|
1013
|
+
|
1014
|
+
# source://faraday//lib/faraday/options/env.rb#154
|
1015
|
+
def inspect; end
|
1016
|
+
|
1017
|
+
# @return [Symbol] HTTP method (`:get`, `:post`)
|
1018
|
+
def method; end
|
1019
|
+
|
1020
|
+
# @return [Symbol] HTTP method (`:get`, `:post`)
|
1021
|
+
def method=(_); end
|
1022
|
+
|
1023
|
+
# source://faraday//lib/faraday/options/env.rb#133
|
1024
|
+
def needs_body?; end
|
1025
|
+
|
1026
|
+
# source://faraday//lib/faraday/options/env.rb#150
|
1027
|
+
def parallel?; end
|
1028
|
+
|
1029
|
+
# @return [Object] sent if the connection is in parallel mode
|
1030
|
+
def parallel_manager; end
|
1031
|
+
|
1032
|
+
# @return [Object] sent if the connection is in parallel mode
|
1033
|
+
def parallel_manager=(_); end
|
1034
|
+
|
1035
|
+
# @return [Hash]
|
1036
|
+
def params; end
|
1037
|
+
|
1038
|
+
# @return [Hash]
|
1039
|
+
def params=(_); end
|
1040
|
+
|
1041
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1042
|
+
def params_encoder(*args, **_arg1, &block); end
|
1043
|
+
|
1044
|
+
# source://faraday//lib/faraday/options/env.rb#145
|
1045
|
+
def parse_body?; end
|
1046
|
+
|
1047
|
+
# @return [String]
|
1048
|
+
def reason_phrase; end
|
1049
|
+
|
1050
|
+
# @return [String]
|
1051
|
+
def reason_phrase=(_); end
|
1052
|
+
|
1053
|
+
# Options for configuring the request.
|
1054
|
+
#
|
1055
|
+
# - `:timeout` - time limit for the entire request (Integer in
|
1056
|
+
# seconds)
|
1057
|
+
# - `:open_timeout` - time limit for just the connection phase (e.g.
|
1058
|
+
# handshake) (Integer in seconds)
|
1059
|
+
# - `:read_timeout` - time limit for the first response byte received from
|
1060
|
+
# the server (Integer in seconds)
|
1061
|
+
# - `:write_timeout` - time limit for the client to send the request to the
|
1062
|
+
# server (Integer in seconds)
|
1063
|
+
# - `:on_data` - Proc for streaming
|
1064
|
+
# - `:proxy` - Hash of proxy options
|
1065
|
+
# - `:uri` - Proxy server URI
|
1066
|
+
# - `:user` - Proxy server username
|
1067
|
+
# - `:password` - Proxy server password
|
1068
|
+
#
|
1069
|
+
# @return [Hash] options for configuring the request.
|
1070
|
+
def request; end
|
1071
|
+
|
1072
|
+
# Options for configuring the request.
|
1073
|
+
#
|
1074
|
+
# - `:timeout` - time limit for the entire request (Integer in
|
1075
|
+
# seconds)
|
1076
|
+
# - `:open_timeout` - time limit for just the connection phase (e.g.
|
1077
|
+
# handshake) (Integer in seconds)
|
1078
|
+
# - `:read_timeout` - time limit for the first response byte received from
|
1079
|
+
# the server (Integer in seconds)
|
1080
|
+
# - `:write_timeout` - time limit for the client to send the request to the
|
1081
|
+
# server (Integer in seconds)
|
1082
|
+
# - `:on_data` - Proc for streaming
|
1083
|
+
# - `:proxy` - Hash of proxy options
|
1084
|
+
# - `:uri` - Proxy server URI
|
1085
|
+
# - `:user` - Proxy server username
|
1086
|
+
# - `:password` - Proxy server password
|
1087
|
+
#
|
1088
|
+
# @return [Hash] options for configuring the request.
|
1089
|
+
def request=(_); end
|
1090
|
+
|
1091
|
+
def request_body; end
|
1092
|
+
def request_body=(_); end
|
1093
|
+
|
1094
|
+
# @return [Hash] HTTP Headers to be sent to the server.
|
1095
|
+
def request_headers; end
|
1096
|
+
|
1097
|
+
# @return [Hash] HTTP Headers to be sent to the server.
|
1098
|
+
def request_headers=(_); end
|
1099
|
+
|
1100
|
+
# @return [Response]
|
1101
|
+
def response; end
|
1102
|
+
|
1103
|
+
# @return [Response]
|
1104
|
+
def response=(_); end
|
1105
|
+
|
1106
|
+
def response_body; end
|
1107
|
+
def response_body=(_); end
|
1108
|
+
|
1109
|
+
# @return [Hash] HTTP headers from the server
|
1110
|
+
def response_headers; end
|
1111
|
+
|
1112
|
+
# @return [Hash] HTTP headers from the server
|
1113
|
+
def response_headers=(_); end
|
1114
|
+
|
1115
|
+
# @return [Hash] options for configuring SSL requests
|
1116
|
+
def ssl; end
|
1117
|
+
|
1118
|
+
# @return [Hash] options for configuring SSL requests
|
1119
|
+
def ssl=(_); end
|
1120
|
+
|
1121
|
+
# @return [Integer] HTTP response status code
|
1122
|
+
def status; end
|
1123
|
+
|
1124
|
+
# @return [Integer] HTTP response status code
|
1125
|
+
def status=(_); end
|
1126
|
+
|
1127
|
+
# source://faraday//lib/faraday/options/env.rb#169
|
1128
|
+
def stream_response(&block); end
|
1129
|
+
|
1130
|
+
# source://faraday//lib/faraday/options/env.rb#165
|
1131
|
+
def stream_response?; end
|
1132
|
+
|
1133
|
+
# source://faraday//lib/faraday/options/env.rb#127
|
1134
|
+
def success?; end
|
1135
|
+
|
1136
|
+
# @return [URI] URI instance for the current request.
|
1137
|
+
def url; end
|
1138
|
+
|
1139
|
+
# @return [URI] URI instance for the current request.
|
1140
|
+
def url=(_); end
|
1141
|
+
|
1142
|
+
class << self
|
1143
|
+
def [](*_arg0); end
|
1144
|
+
|
1145
|
+
# source://faraday//lib/faraday/options/env.rb#80
|
1146
|
+
def from(value); end
|
1147
|
+
|
1148
|
+
def inspect; end
|
1149
|
+
def keyword_init?; end
|
1150
|
+
|
1151
|
+
# source://faraday//lib/faraday/options/env.rb#200
|
1152
|
+
def member_set; end
|
1153
|
+
|
1154
|
+
def members; end
|
1155
|
+
def new(*_arg0); end
|
1156
|
+
end
|
1157
|
+
end
|
1158
|
+
|
1159
|
+
# source://faraday//lib/faraday/options/env.rb#61
|
1160
|
+
Faraday::Env::ContentLength = T.let(T.unsafe(nil), String)
|
1161
|
+
|
1162
|
+
# source://faraday//lib/faraday/options/env.rb#67
|
1163
|
+
Faraday::Env::MethodsWithBodies = T.let(T.unsafe(nil), Set)
|
1164
|
+
|
1165
|
+
# source://faraday//lib/faraday/options/env.rb#62
|
1166
|
+
Faraday::Env::StatusesWithoutBody = T.let(T.unsafe(nil), Set)
|
1167
|
+
|
1168
|
+
# source://faraday//lib/faraday/options/env.rb#63
|
1169
|
+
Faraday::Env::SuccessfulStatuses = T.let(T.unsafe(nil), Range)
|
1170
|
+
|
1171
|
+
# Faraday error base class.
|
1172
|
+
#
|
1173
|
+
# source://faraday//lib/faraday/error.rb#6
|
1174
|
+
class Faraday::Error < ::StandardError
|
1175
|
+
# @return [Error] a new instance of Error
|
1176
|
+
#
|
1177
|
+
# source://faraday//lib/faraday/error.rb#9
|
1178
|
+
def initialize(exc = T.unsafe(nil), response = T.unsafe(nil)); end
|
1179
|
+
|
1180
|
+
# source://faraday//lib/faraday/error.rb#15
|
1181
|
+
def backtrace; end
|
1182
|
+
|
1183
|
+
# source://faraday//lib/faraday/error.rb#23
|
1184
|
+
def inspect; end
|
1185
|
+
|
1186
|
+
# Returns the value of attribute response.
|
1187
|
+
#
|
1188
|
+
# source://faraday//lib/faraday/error.rb#7
|
1189
|
+
def response; end
|
1190
|
+
|
1191
|
+
# source://faraday//lib/faraday/error.rb#43
|
1192
|
+
def response_body; end
|
1193
|
+
|
1194
|
+
# source://faraday//lib/faraday/error.rb#37
|
1195
|
+
def response_headers; end
|
1196
|
+
|
1197
|
+
# source://faraday//lib/faraday/error.rb#31
|
1198
|
+
def response_status; end
|
1199
|
+
|
1200
|
+
# Returns the value of attribute wrapped_exception.
|
1201
|
+
#
|
1202
|
+
# source://faraday//lib/faraday/error.rb#7
|
1203
|
+
def wrapped_exception; end
|
1204
|
+
|
1205
|
+
protected
|
1206
|
+
|
1207
|
+
# Pulls out potential parent exception and response hash.
|
1208
|
+
#
|
1209
|
+
# source://faraday//lib/faraday/error.rb#81
|
1210
|
+
def exc_msg_and_response(exc, response = T.unsafe(nil)); end
|
1211
|
+
|
1212
|
+
# Pulls out potential parent exception and response hash, storing them in
|
1213
|
+
# instance variables.
|
1214
|
+
# exc - Either an Exception, a string message, or a response hash.
|
1215
|
+
# response - Hash
|
1216
|
+
# :status - Optional integer HTTP response status
|
1217
|
+
# :headers - String key/value hash of HTTP response header
|
1218
|
+
# values.
|
1219
|
+
# :body - Optional string HTTP response body.
|
1220
|
+
# :request - Hash
|
1221
|
+
# :method - Symbol with the request HTTP method.
|
1222
|
+
# :url - URI object with the url requested.
|
1223
|
+
# :url_path - String with the url path requested.
|
1224
|
+
# :params - String key/value hash of query params
|
1225
|
+
# present in the request.
|
1226
|
+
# :headers - String key/value hash of HTTP request
|
1227
|
+
# header values.
|
1228
|
+
# :body - String HTTP request body.
|
1229
|
+
#
|
1230
|
+
# If a subclass has to call this, then it should pass a string message
|
1231
|
+
# to `super`. See NilStatusError.
|
1232
|
+
#
|
1233
|
+
# source://faraday//lib/faraday/error.rb#71
|
1234
|
+
def exc_msg_and_response!(exc, response = T.unsafe(nil)); end
|
1235
|
+
end
|
1236
|
+
|
1237
|
+
# FlatParamsEncoder manages URI params as a flat hash. Any Array values repeat
|
1238
|
+
# the parameter multiple times.
|
1239
|
+
#
|
1240
|
+
# source://faraday//lib/faraday/encoders/flat_params_encoder.rb#6
|
1241
|
+
module Faraday::FlatParamsEncoder
|
1242
|
+
class << self
|
1243
|
+
# Decode converts the given URI querystring into a hash.
|
1244
|
+
#
|
1245
|
+
# @example
|
1246
|
+
#
|
1247
|
+
# decode('a=one&a=two&a=three&b=true&c=C')
|
1248
|
+
# # => {"a"=>["one", "two", "three"], "b"=>"true", "c"=>"C"}
|
1249
|
+
# @param query [String] query arguments to parse.
|
1250
|
+
# @return [Hash] parsed keys and value strings from the querystring.
|
1251
|
+
#
|
1252
|
+
# source://faraday//lib/faraday/encoders/flat_params_encoder.rb#74
|
1253
|
+
def decode(query); end
|
1254
|
+
|
1255
|
+
# Encode converts the given param into a URI querystring. Keys and values
|
1256
|
+
# will converted to strings and appropriately escaped for the URI.
|
1257
|
+
#
|
1258
|
+
# @example
|
1259
|
+
#
|
1260
|
+
# encode({a: %w[one two three], b: true, c: "C"})
|
1261
|
+
# # => 'a=one&a=two&a=three&b=true&c=C'
|
1262
|
+
# @param params [Hash] query arguments to convert.
|
1263
|
+
# @return [String] the URI querystring (without the leading '?')
|
1264
|
+
#
|
1265
|
+
# source://faraday//lib/faraday/encoders/flat_params_encoder.rb#23
|
1266
|
+
def encode(params); end
|
1267
|
+
|
1268
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1269
|
+
def escape(*args, **_arg1, &block); end
|
1270
|
+
|
1271
|
+
# Returns the value of attribute sort_params.
|
1272
|
+
#
|
1273
|
+
# source://faraday//lib/faraday/encoders/flat_params_encoder.rb#99
|
1274
|
+
def sort_params; end
|
1275
|
+
|
1276
|
+
# Sets the attribute sort_params
|
1277
|
+
#
|
1278
|
+
# @param value the value to set the attribute sort_params to.
|
1279
|
+
#
|
1280
|
+
# source://faraday//lib/faraday/encoders/flat_params_encoder.rb#99
|
1281
|
+
def sort_params=(_arg0); end
|
1282
|
+
|
1283
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1284
|
+
def unescape(*args, **_arg1, &block); end
|
1285
|
+
end
|
1286
|
+
end
|
1287
|
+
|
1288
|
+
# Raised by Faraday::Response::RaiseError in case of a 403 response.
|
1289
|
+
#
|
1290
|
+
# source://faraday//lib/faraday/error.rb#104
|
1291
|
+
class Faraday::ForbiddenError < ::Faraday::ClientError; end
|
1292
|
+
|
1293
|
+
# Raised by Faraday::Middleware and subclasses when invalid default_options are used
|
1294
|
+
#
|
1295
|
+
# source://faraday//lib/faraday/error.rb#163
|
1296
|
+
class Faraday::InitializationError < ::Faraday::Error; end
|
1297
|
+
|
1298
|
+
# source://faraday//lib/faraday/logging/formatter.rb#6
|
1299
|
+
module Faraday::Logging; end
|
1300
|
+
|
1301
|
+
# Serves as an integration point to customize logging
|
1302
|
+
#
|
1303
|
+
# source://faraday//lib/faraday/logging/formatter.rb#8
|
1304
|
+
class Faraday::Logging::Formatter
|
1305
|
+
extend ::Forwardable
|
1306
|
+
|
1307
|
+
# @return [Formatter] a new instance of Formatter
|
1308
|
+
#
|
1309
|
+
# source://faraday//lib/faraday/logging/formatter.rb#14
|
1310
|
+
def initialize(logger:, options:); end
|
1311
|
+
|
1312
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1313
|
+
def debug(*args, **_arg1, &block); end
|
1314
|
+
|
1315
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1316
|
+
def error(*args, **_arg1, &block); end
|
1317
|
+
|
1318
|
+
# source://faraday//lib/faraday/logging/formatter.rb#41
|
1319
|
+
def exception(exc); end
|
1320
|
+
|
1321
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1322
|
+
def fatal(*args, **_arg1, &block); end
|
1323
|
+
|
1324
|
+
# source://faraday//lib/faraday/logging/formatter.rb#52
|
1325
|
+
def filter(filter_word, filter_replacement); end
|
1326
|
+
|
1327
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1328
|
+
def info(*args, **_arg1, &block); end
|
1329
|
+
|
1330
|
+
# source://faraday//lib/faraday/logging/formatter.rb#25
|
1331
|
+
def request(env); end
|
1332
|
+
|
1333
|
+
# source://faraday//lib/faraday/logging/formatter.rb#34
|
1334
|
+
def response(env); end
|
1335
|
+
|
1336
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1337
|
+
def warn(*args, **_arg1, &block); end
|
1338
|
+
|
1339
|
+
private
|
1340
|
+
|
1341
|
+
# source://faraday//lib/faraday/logging/formatter.rb#98
|
1342
|
+
def apply_filters(output); end
|
1343
|
+
|
1344
|
+
# source://faraday//lib/faraday/logging/formatter.rb#64
|
1345
|
+
def dump_body(body); end
|
1346
|
+
|
1347
|
+
# source://faraday//lib/faraday/logging/formatter.rb#58
|
1348
|
+
def dump_headers(headers); end
|
1349
|
+
|
1350
|
+
# source://faraday//lib/faraday/logging/formatter.rb#113
|
1351
|
+
def log_body(type, body); end
|
1352
|
+
|
1353
|
+
# @return [Boolean]
|
1354
|
+
#
|
1355
|
+
# source://faraday//lib/faraday/logging/formatter.rb#85
|
1356
|
+
def log_body?(type); end
|
1357
|
+
|
1358
|
+
# @return [Boolean]
|
1359
|
+
#
|
1360
|
+
# source://faraday//lib/faraday/logging/formatter.rb#94
|
1361
|
+
def log_errors?; end
|
1362
|
+
|
1363
|
+
# source://faraday//lib/faraday/logging/formatter.rb#109
|
1364
|
+
def log_headers(type, headers); end
|
1365
|
+
|
1366
|
+
# @return [Boolean]
|
1367
|
+
#
|
1368
|
+
# source://faraday//lib/faraday/logging/formatter.rb#76
|
1369
|
+
def log_headers?(type); end
|
1370
|
+
|
1371
|
+
# source://faraday//lib/faraday/logging/formatter.rb#105
|
1372
|
+
def log_level; end
|
1373
|
+
|
1374
|
+
# source://faraday//lib/faraday/logging/formatter.rb#72
|
1375
|
+
def pretty_inspect(body); end
|
1376
|
+
end
|
1377
|
+
|
1378
|
+
# source://faraday//lib/faraday/logging/formatter.rb#11
|
1379
|
+
Faraday::Logging::Formatter::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash)
|
1380
|
+
|
1381
|
+
# source://faraday//lib/faraday/methods.rb#5
|
1382
|
+
Faraday::METHODS_WITH_BODY = T.let(T.unsafe(nil), Array)
|
1383
|
+
|
1384
|
+
# source://faraday//lib/faraday/methods.rb#4
|
1385
|
+
Faraday::METHODS_WITH_QUERY = T.let(T.unsafe(nil), Array)
|
1386
|
+
|
1387
|
+
# Middleware is the basic base class of any Faraday middleware.
|
1388
|
+
#
|
1389
|
+
# source://faraday//lib/faraday/middleware.rb#7
|
1390
|
+
class Faraday::Middleware
|
1391
|
+
extend ::Faraday::MiddlewareRegistry
|
1392
|
+
|
1393
|
+
# @return [Middleware] a new instance of Middleware
|
1394
|
+
#
|
1395
|
+
# source://faraday//lib/faraday/middleware.rb#15
|
1396
|
+
def initialize(app = T.unsafe(nil), options = T.unsafe(nil)); end
|
1397
|
+
|
1398
|
+
# Returns the value of attribute app.
|
1399
|
+
#
|
1400
|
+
# source://faraday//lib/faraday/middleware.rb#10
|
1401
|
+
def app; end
|
1402
|
+
|
1403
|
+
# source://faraday//lib/faraday/middleware.rb#54
|
1404
|
+
def call(env); end
|
1405
|
+
|
1406
|
+
# source://faraday//lib/faraday/middleware.rb#64
|
1407
|
+
def close; end
|
1408
|
+
|
1409
|
+
# Returns the value of attribute options.
|
1410
|
+
#
|
1411
|
+
# source://faraday//lib/faraday/middleware.rb#10
|
1412
|
+
def options; end
|
1413
|
+
|
1414
|
+
class << self
|
1415
|
+
# default_options attr_reader that initializes class instance variable
|
1416
|
+
# with the values of any Faraday::Middleware defaults, and merges with
|
1417
|
+
# subclass defaults
|
1418
|
+
#
|
1419
|
+
# source://faraday//lib/faraday/middleware.rb#39
|
1420
|
+
def default_options; end
|
1421
|
+
|
1422
|
+
# Faraday::Middleware::default_options= allows user to set default options at the Faraday::Middleware
|
1423
|
+
# class level.
|
1424
|
+
#
|
1425
|
+
# my_app/config/initializers/my_faraday_middleware.rb
|
1426
|
+
#
|
1427
|
+
# Faraday::Response::RaiseError.default_options = { include_request: false }
|
1428
|
+
#
|
1429
|
+
# @example Set the Faraday::Response::RaiseError option, `include_request` to `false`
|
1430
|
+
#
|
1431
|
+
# source://faraday//lib/faraday/middleware.rb#29
|
1432
|
+
def default_options=(options = T.unsafe(nil)); end
|
1433
|
+
|
1434
|
+
private
|
1435
|
+
|
1436
|
+
# @raise [Faraday::InitializationError]
|
1437
|
+
#
|
1438
|
+
# source://faraday//lib/faraday/middleware.rb#45
|
1439
|
+
def validate_default_options(options); end
|
1440
|
+
end
|
1441
|
+
end
|
1442
|
+
|
1443
|
+
# source://faraday//lib/faraday/middleware.rb#12
|
1444
|
+
Faraday::Middleware::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash)
|
1445
|
+
|
1446
|
+
# source://faraday//lib/faraday/middleware.rb#13
|
1447
|
+
Faraday::Middleware::LOCK = T.let(T.unsafe(nil), Thread::Mutex)
|
1448
|
+
|
1449
|
+
# Adds the ability for other modules to register and lookup
|
1450
|
+
# middleware classes.
|
1451
|
+
#
|
1452
|
+
# source://faraday//lib/faraday/middleware_registry.rb#8
|
1453
|
+
module Faraday::MiddlewareRegistry
|
1454
|
+
# Lookup middleware class with a registered Symbol shortcut.
|
1455
|
+
#
|
1456
|
+
# @example
|
1457
|
+
#
|
1458
|
+
# module Faraday
|
1459
|
+
# class Whatever < Middleware
|
1460
|
+
# register_middleware(foo: Whatever)
|
1461
|
+
# end
|
1462
|
+
# end
|
1463
|
+
#
|
1464
|
+
# Faraday::Middleware.lookup_middleware(:foo)
|
1465
|
+
# # => Faraday::Whatever
|
1466
|
+
# @param key [Symbol] key for the registered middleware.
|
1467
|
+
# @raise [Faraday::Error] if given key is not registered
|
1468
|
+
# @return [Class] a middleware Class.
|
1469
|
+
#
|
1470
|
+
# source://faraday//lib/faraday/middleware_registry.rb#55
|
1471
|
+
def lookup_middleware(key); end
|
1472
|
+
|
1473
|
+
# Register middleware class(es) on the current module.
|
1474
|
+
#
|
1475
|
+
# @example Lookup by a constant
|
1476
|
+
#
|
1477
|
+
# module Faraday
|
1478
|
+
# class Whatever < Middleware
|
1479
|
+
# # Middleware looked up by :foo returns Faraday::Whatever::Foo.
|
1480
|
+
# register_middleware(foo: Whatever)
|
1481
|
+
# end
|
1482
|
+
# end
|
1483
|
+
# @param mappings [Hash] Middleware mappings from a lookup symbol to a middleware class.
|
1484
|
+
# @return [void]
|
1485
|
+
#
|
1486
|
+
# source://faraday//lib/faraday/middleware_registry.rb#26
|
1487
|
+
def register_middleware(**mappings); end
|
1488
|
+
|
1489
|
+
# source://faraday//lib/faraday/middleware_registry.rb#9
|
1490
|
+
def registered_middleware; end
|
1491
|
+
|
1492
|
+
# Unregister a previously registered middleware class.
|
1493
|
+
#
|
1494
|
+
# @param key [Symbol] key for the registered middleware.
|
1495
|
+
#
|
1496
|
+
# source://faraday//lib/faraday/middleware_registry.rb#35
|
1497
|
+
def unregister_middleware(key); end
|
1498
|
+
|
1499
|
+
private
|
1500
|
+
|
1501
|
+
# source://faraday//lib/faraday/middleware_registry.rb#67
|
1502
|
+
def load_middleware(key); end
|
1503
|
+
|
1504
|
+
# source://faraday//lib/faraday/middleware_registry.rb#62
|
1505
|
+
def middleware_mutex(&block); end
|
1506
|
+
end
|
1507
|
+
|
1508
|
+
# This is the default encoder for Faraday requests.
|
1509
|
+
# Using this encoder, parameters will be encoded respecting their structure,
|
1510
|
+
# so you can send objects such as Arrays or Hashes as parameters
|
1511
|
+
# for your requests.
|
1512
|
+
#
|
1513
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#168
|
1514
|
+
module Faraday::NestedParamsEncoder
|
1515
|
+
extend ::Faraday::EncodeMethods
|
1516
|
+
extend ::Faraday::DecodeMethods
|
1517
|
+
|
1518
|
+
class << self
|
1519
|
+
# Returns the value of attribute array_indices.
|
1520
|
+
#
|
1521
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#170
|
1522
|
+
def array_indices; end
|
1523
|
+
|
1524
|
+
# Sets the attribute array_indices
|
1525
|
+
#
|
1526
|
+
# @param value the value to set the attribute array_indices to.
|
1527
|
+
#
|
1528
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#170
|
1529
|
+
def array_indices=(_arg0); end
|
1530
|
+
|
1531
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1532
|
+
def escape(*args, **_arg1, &block); end
|
1533
|
+
|
1534
|
+
# Returns the value of attribute sort_params.
|
1535
|
+
#
|
1536
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#170
|
1537
|
+
def sort_params; end
|
1538
|
+
|
1539
|
+
# Sets the attribute sort_params
|
1540
|
+
#
|
1541
|
+
# @param value the value to set the attribute sort_params to.
|
1542
|
+
#
|
1543
|
+
# source://faraday//lib/faraday/encoders/nested_params_encoder.rb#170
|
1544
|
+
def sort_params=(_arg0); end
|
1545
|
+
|
1546
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1547
|
+
def unescape(*args, **_arg1, &block); end
|
1548
|
+
end
|
1549
|
+
end
|
1550
|
+
|
1551
|
+
# Raised by Faraday::Response::RaiseError in case of a nil status in response.
|
1552
|
+
#
|
1553
|
+
# source://faraday//lib/faraday/error.rb#143
|
1554
|
+
class Faraday::NilStatusError < ::Faraday::ServerError
|
1555
|
+
# @return [NilStatusError] a new instance of NilStatusError
|
1556
|
+
#
|
1557
|
+
# source://faraday//lib/faraday/error.rb#144
|
1558
|
+
def initialize(exc, response = T.unsafe(nil)); end
|
1559
|
+
end
|
1560
|
+
|
1561
|
+
# Subclasses Struct with some special helpers for converting from a Hash to
|
1562
|
+
# a Struct.
|
1563
|
+
#
|
1564
|
+
# source://faraday//lib/faraday/options.rb#6
|
1565
|
+
class Faraday::Options < ::Struct
|
1566
|
+
# source://faraday//lib/faraday/options.rb#186
|
1567
|
+
def [](key); end
|
1568
|
+
|
1569
|
+
# Public
|
1570
|
+
#
|
1571
|
+
# source://faraday//lib/faraday/options.rb#46
|
1572
|
+
def clear; end
|
1573
|
+
|
1574
|
+
# Public
|
1575
|
+
#
|
1576
|
+
# source://faraday//lib/faraday/options.rb#71
|
1577
|
+
def deep_dup; end
|
1578
|
+
|
1579
|
+
# Public
|
1580
|
+
#
|
1581
|
+
# source://faraday//lib/faraday/options.rb#39
|
1582
|
+
def delete(key); end
|
1583
|
+
|
1584
|
+
# Public
|
1585
|
+
#
|
1586
|
+
# source://faraday//lib/faraday/options.rb#13
|
1587
|
+
def each; end
|
1588
|
+
|
1589
|
+
# Public
|
1590
|
+
#
|
1591
|
+
# source://faraday//lib/faraday/options.rb#106
|
1592
|
+
def each_key(&block); end
|
1593
|
+
|
1594
|
+
# Public
|
1595
|
+
#
|
1596
|
+
# source://faraday//lib/faraday/options.rb#120
|
1597
|
+
def each_value(&block); end
|
1598
|
+
|
1599
|
+
# Public
|
1600
|
+
#
|
1601
|
+
# @return [Boolean]
|
1602
|
+
#
|
1603
|
+
# source://faraday//lib/faraday/options.rb#101
|
1604
|
+
def empty?; end
|
1605
|
+
|
1606
|
+
# Public
|
1607
|
+
#
|
1608
|
+
# source://faraday//lib/faraday/options.rb#76
|
1609
|
+
def fetch(key, *args); end
|
1610
|
+
|
1611
|
+
# Public
|
1612
|
+
#
|
1613
|
+
# @return [Boolean]
|
1614
|
+
#
|
1615
|
+
# source://faraday//lib/faraday/options.rb#113
|
1616
|
+
def has_key?(key); end
|
1617
|
+
|
1618
|
+
# Public
|
1619
|
+
#
|
1620
|
+
# @return [Boolean]
|
1621
|
+
#
|
1622
|
+
# source://faraday//lib/faraday/options.rb#127
|
1623
|
+
def has_value?(value); end
|
1624
|
+
|
1625
|
+
# Internal
|
1626
|
+
#
|
1627
|
+
# source://faraday//lib/faraday/options.rb#144
|
1628
|
+
def inspect; end
|
1629
|
+
|
1630
|
+
# Public
|
1631
|
+
#
|
1632
|
+
# @return [Boolean]
|
1633
|
+
#
|
1634
|
+
# source://faraday//lib/faraday/options.rb#113
|
1635
|
+
def key?(key); end
|
1636
|
+
|
1637
|
+
# Public
|
1638
|
+
#
|
1639
|
+
# source://faraday//lib/faraday/options.rb#96
|
1640
|
+
def keys; end
|
1641
|
+
|
1642
|
+
# Public
|
1643
|
+
#
|
1644
|
+
# source://faraday//lib/faraday/options.rb#66
|
1645
|
+
def merge(other); end
|
1646
|
+
|
1647
|
+
# Public
|
1648
|
+
#
|
1649
|
+
# source://faraday//lib/faraday/options.rb#51
|
1650
|
+
def merge!(other); end
|
1651
|
+
|
1652
|
+
# source://faraday//lib/faraday/options.rb#195
|
1653
|
+
def symbolized_key_set; end
|
1654
|
+
|
1655
|
+
# Public
|
1656
|
+
#
|
1657
|
+
# source://faraday//lib/faraday/options.rb#134
|
1658
|
+
def to_hash; end
|
1659
|
+
|
1660
|
+
# Public
|
1661
|
+
#
|
1662
|
+
# source://faraday//lib/faraday/options.rb#22
|
1663
|
+
def update(obj); end
|
1664
|
+
|
1665
|
+
# Public
|
1666
|
+
#
|
1667
|
+
# @return [Boolean]
|
1668
|
+
#
|
1669
|
+
# source://faraday//lib/faraday/options.rb#127
|
1670
|
+
def value?(value); end
|
1671
|
+
|
1672
|
+
# Public
|
1673
|
+
#
|
1674
|
+
# source://faraday//lib/faraday/options.rb#91
|
1675
|
+
def values_at(*keys); end
|
1676
|
+
|
1677
|
+
class << self
|
1678
|
+
# Internal
|
1679
|
+
#
|
1680
|
+
# source://faraday//lib/faraday/options.rb#166
|
1681
|
+
def attribute_options; end
|
1682
|
+
|
1683
|
+
# source://faraday//lib/faraday/options.rb#205
|
1684
|
+
def fetch_error_class; end
|
1685
|
+
|
1686
|
+
# Public
|
1687
|
+
#
|
1688
|
+
# source://faraday//lib/faraday/options.rb#8
|
1689
|
+
def from(value); end
|
1690
|
+
|
1691
|
+
# @private
|
1692
|
+
#
|
1693
|
+
# source://faraday//lib/faraday/options.rb#199
|
1694
|
+
def inherited(subclass); end
|
1695
|
+
|
1696
|
+
# source://faraday//lib/faraday/options.rb#170
|
1697
|
+
def memoized(key, &block); end
|
1698
|
+
|
1699
|
+
# source://faraday//lib/faraday/options.rb#182
|
1700
|
+
def memoized_attributes; end
|
1701
|
+
|
1702
|
+
# Internal
|
1703
|
+
#
|
1704
|
+
# source://faraday//lib/faraday/options.rb#156
|
1705
|
+
def options(mapping); end
|
1706
|
+
|
1707
|
+
# Internal
|
1708
|
+
#
|
1709
|
+
# source://faraday//lib/faraday/options.rb#161
|
1710
|
+
def options_for(key); end
|
1711
|
+
end
|
1712
|
+
end
|
1713
|
+
|
1714
|
+
# Raised by middlewares that parse the response, like the JSON response middleware.
|
1715
|
+
#
|
1716
|
+
# source://faraday//lib/faraday/error.rb#159
|
1717
|
+
class Faraday::ParsingError < ::Faraday::Error; end
|
1718
|
+
|
1719
|
+
# Raised by Faraday::Response::RaiseError in case of a 407 response.
|
1720
|
+
#
|
1721
|
+
# source://faraday//lib/faraday/error.rb#112
|
1722
|
+
class Faraday::ProxyAuthError < ::Faraday::ClientError; end
|
1723
|
+
|
1724
|
+
# ProxyOptions contains the configurable properties for the proxy
|
1725
|
+
# configuration used when making an HTTP request.
|
1726
|
+
#
|
1727
|
+
# source://faraday//lib/faraday/options/proxy_options.rb#8
|
1728
|
+
class Faraday::ProxyOptions < ::Faraday::Options
|
1729
|
+
extend ::Forwardable
|
1730
|
+
|
1731
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1732
|
+
def host(*args, **_arg1, &block); end
|
1733
|
+
|
1734
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1735
|
+
def host=(*args, **_arg1, &block); end
|
1736
|
+
|
1737
|
+
# source://faraday//lib/faraday/options.rb#178
|
1738
|
+
def password; end
|
1739
|
+
|
1740
|
+
def password=(_); end
|
1741
|
+
|
1742
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1743
|
+
def path(*args, **_arg1, &block); end
|
1744
|
+
|
1745
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1746
|
+
def path=(*args, **_arg1, &block); end
|
1747
|
+
|
1748
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1749
|
+
def port(*args, **_arg1, &block); end
|
1750
|
+
|
1751
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1752
|
+
def port=(*args, **_arg1, &block); end
|
1753
|
+
|
1754
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1755
|
+
def scheme(*args, **_arg1, &block); end
|
1756
|
+
|
1757
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
1758
|
+
def scheme=(*args, **_arg1, &block); end
|
1759
|
+
|
1760
|
+
def uri; end
|
1761
|
+
def uri=(_); end
|
1762
|
+
|
1763
|
+
# source://faraday//lib/faraday/options.rb#178
|
1764
|
+
def user; end
|
1765
|
+
|
1766
|
+
def user=(_); end
|
1767
|
+
|
1768
|
+
class << self
|
1769
|
+
def [](*_arg0); end
|
1770
|
+
|
1771
|
+
# source://faraday//lib/faraday/options/proxy_options.rb#13
|
1772
|
+
def from(value); end
|
1773
|
+
|
1774
|
+
def inspect; end
|
1775
|
+
def keyword_init?; end
|
1776
|
+
def members; end
|
1777
|
+
def new(*_arg0); end
|
1778
|
+
end
|
1779
|
+
end
|
1780
|
+
|
1781
|
+
# A Builder that processes requests into responses by passing through an inner
|
1782
|
+
# middleware stack (heavily inspired by Rack).
|
1783
|
+
#
|
1784
|
+
# @example
|
1785
|
+
# Faraday::Connection.new(url: 'http://httpbingo.org') do |builder|
|
1786
|
+
# builder.request :url_encoded # Faraday::Request::UrlEncoded
|
1787
|
+
# builder.adapter :net_http # Faraday::Adapter::NetHttp
|
1788
|
+
# end
|
1789
|
+
#
|
1790
|
+
# source://faraday//lib/faraday/rack_builder.rb#14
|
1791
|
+
class Faraday::RackBuilder
|
1792
|
+
# @return [RackBuilder] a new instance of RackBuilder
|
1793
|
+
#
|
1794
|
+
# source://faraday//lib/faraday/rack_builder.rb#61
|
1795
|
+
def initialize(&block); end
|
1796
|
+
|
1797
|
+
# source://faraday//lib/faraday/rack_builder.rb#179
|
1798
|
+
def ==(other); end
|
1799
|
+
|
1800
|
+
# source://faraday//lib/faraday/rack_builder.rb#79
|
1801
|
+
def [](idx); end
|
1802
|
+
|
1803
|
+
# source://faraday//lib/faraday/rack_builder.rb#110
|
1804
|
+
def adapter(klass = T.unsafe(nil), *args, **kwargs, &block); end
|
1805
|
+
|
1806
|
+
# The "rack app" wrapped in middleware. All requests are sent here.
|
1807
|
+
#
|
1808
|
+
# The builder is responsible for creating the app object. After this,
|
1809
|
+
# the builder gets locked to ensure no further modifications are made
|
1810
|
+
# to the middleware stack.
|
1811
|
+
#
|
1812
|
+
# Returns an object that responds to `call` and returns a Response.
|
1813
|
+
#
|
1814
|
+
# source://faraday//lib/faraday/rack_builder.rb#163
|
1815
|
+
def app; end
|
1816
|
+
|
1817
|
+
# source://faraday//lib/faraday/rack_builder.rb#73
|
1818
|
+
def build; end
|
1819
|
+
|
1820
|
+
# ENV Keys
|
1821
|
+
# :http_method - a symbolized request HTTP method (:get, :post)
|
1822
|
+
# :body - the request body that will eventually be converted to a string.
|
1823
|
+
# :url - URI instance for the current request.
|
1824
|
+
# :status - HTTP response status code
|
1825
|
+
# :request_headers - hash of HTTP Headers to be sent to the server
|
1826
|
+
# :response_headers - Hash of HTTP headers from the server
|
1827
|
+
# :parallel_manager - sent if the connection is in parallel mode
|
1828
|
+
# :request - Hash of options for configuring the request.
|
1829
|
+
# :timeout - open/read timeout Integer in seconds
|
1830
|
+
# :open_timeout - read timeout Integer in seconds
|
1831
|
+
# :proxy - Hash of proxy options
|
1832
|
+
# :uri - Proxy Server URI
|
1833
|
+
# :user - Proxy server username
|
1834
|
+
# :password - Proxy server password
|
1835
|
+
# :ssl - Hash of options for configuring SSL requests.
|
1836
|
+
#
|
1837
|
+
# source://faraday//lib/faraday/rack_builder.rb#201
|
1838
|
+
def build_env(connection, request); end
|
1839
|
+
|
1840
|
+
# Processes a Request into a Response by passing it through this Builder's
|
1841
|
+
# middleware stack.
|
1842
|
+
#
|
1843
|
+
# @param connection [Faraday::Connection]
|
1844
|
+
# @param request [Faraday::Request]
|
1845
|
+
# @return [Faraday::Response]
|
1846
|
+
#
|
1847
|
+
# source://faraday//lib/faraday/rack_builder.rb#152
|
1848
|
+
def build_response(connection, request); end
|
1849
|
+
|
1850
|
+
# source://faraday//lib/faraday/rack_builder.rb#140
|
1851
|
+
def delete(handler); end
|
1852
|
+
|
1853
|
+
# Returns the value of attribute handlers.
|
1854
|
+
#
|
1855
|
+
# source://faraday//lib/faraday/rack_builder.rb#18
|
1856
|
+
def handlers; end
|
1857
|
+
|
1858
|
+
# Sets the attribute handlers
|
1859
|
+
#
|
1860
|
+
# @param value the value to set the attribute handlers to.
|
1861
|
+
#
|
1862
|
+
# source://faraday//lib/faraday/rack_builder.rb#18
|
1863
|
+
def handlers=(_arg0); end
|
1864
|
+
|
1865
|
+
# methods to push onto the various positions in the stack:
|
1866
|
+
#
|
1867
|
+
# source://faraday//lib/faraday/rack_builder.rb#119
|
1868
|
+
def insert(index, *_arg1, **_arg2, &_arg3); end
|
1869
|
+
|
1870
|
+
# source://faraday//lib/faraday/rack_builder.rb#128
|
1871
|
+
def insert_after(index, *_arg1, **_arg2, &_arg3); end
|
1872
|
+
|
1873
|
+
# methods to push onto the various positions in the stack:
|
1874
|
+
#
|
1875
|
+
# source://faraday//lib/faraday/rack_builder.rb#119
|
1876
|
+
def insert_before(index, *_arg1, **_arg2, &_arg3); end
|
1877
|
+
|
1878
|
+
# Locks the middleware stack to ensure no further modifications are made.
|
1879
|
+
#
|
1880
|
+
# source://faraday//lib/faraday/rack_builder.rb#84
|
1881
|
+
def lock!; end
|
1882
|
+
|
1883
|
+
# @return [Boolean]
|
1884
|
+
#
|
1885
|
+
# source://faraday//lib/faraday/rack_builder.rb#88
|
1886
|
+
def locked?; end
|
1887
|
+
|
1888
|
+
# source://faraday//lib/faraday/rack_builder.rb#102
|
1889
|
+
def request(key, *_arg1, **_arg2, &_arg3); end
|
1890
|
+
|
1891
|
+
# source://faraday//lib/faraday/rack_builder.rb#106
|
1892
|
+
def response(*_arg0, **_arg1, &_arg2); end
|
1893
|
+
|
1894
|
+
# source://faraday//lib/faraday/rack_builder.rb#133
|
1895
|
+
def swap(index, *_arg1, **_arg2, &_arg3); end
|
1896
|
+
|
1897
|
+
# source://faraday//lib/faraday/rack_builder.rb#171
|
1898
|
+
def to_app; end
|
1899
|
+
|
1900
|
+
# source://faraday//lib/faraday/rack_builder.rb#92
|
1901
|
+
def use(klass, *_arg1, **_arg2, &_arg3); end
|
1902
|
+
|
1903
|
+
private
|
1904
|
+
|
1905
|
+
# @return [Boolean]
|
1906
|
+
#
|
1907
|
+
# source://faraday//lib/faraday/rack_builder.rb#233
|
1908
|
+
def adapter_set?; end
|
1909
|
+
|
1910
|
+
# source://faraday//lib/faraday/rack_builder.rb#245
|
1911
|
+
def assert_index(index); end
|
1912
|
+
|
1913
|
+
# @raise [MISSING_ADAPTER_ERROR]
|
1914
|
+
#
|
1915
|
+
# source://faraday//lib/faraday/rack_builder.rb#229
|
1916
|
+
def ensure_adapter!; end
|
1917
|
+
|
1918
|
+
# source://faraday//lib/faraday/rack_builder.rb#67
|
1919
|
+
def initialize_dup(original); end
|
1920
|
+
|
1921
|
+
# @return [Boolean]
|
1922
|
+
#
|
1923
|
+
# source://faraday//lib/faraday/rack_builder.rb#237
|
1924
|
+
def is_adapter?(klass); end
|
1925
|
+
|
1926
|
+
# source://faraday//lib/faraday/rack_builder.rb#223
|
1927
|
+
def raise_if_adapter(klass); end
|
1928
|
+
|
1929
|
+
# @raise [StackLocked]
|
1930
|
+
#
|
1931
|
+
# source://faraday//lib/faraday/rack_builder.rb#219
|
1932
|
+
def raise_if_locked; end
|
1933
|
+
|
1934
|
+
# source://faraday//lib/faraday/rack_builder.rb#241
|
1935
|
+
def use_symbol(mod, key, *_arg2, **_arg3, &_arg4); end
|
1936
|
+
end
|
1937
|
+
|
1938
|
+
# borrowed from ActiveSupport::Dependencies::Reference &
|
1939
|
+
# ActionDispatch::MiddlewareStack::Middleware
|
1940
|
+
#
|
1941
|
+
# source://faraday//lib/faraday/rack_builder.rb#25
|
1942
|
+
class Faraday::RackBuilder::Handler
|
1943
|
+
# @return [Handler] a new instance of Handler
|
1944
|
+
#
|
1945
|
+
# source://faraday//lib/faraday/rack_builder.rb#30
|
1946
|
+
def initialize(klass, *args, **kwargs, &block); end
|
1947
|
+
|
1948
|
+
# source://faraday//lib/faraday/rack_builder.rb#46
|
1949
|
+
def ==(other); end
|
1950
|
+
|
1951
|
+
# source://faraday//lib/faraday/rack_builder.rb#56
|
1952
|
+
def build(app = T.unsafe(nil)); end
|
1953
|
+
|
1954
|
+
# source://faraday//lib/faraday/rack_builder.rb#42
|
1955
|
+
def inspect; end
|
1956
|
+
|
1957
|
+
# source://faraday//lib/faraday/rack_builder.rb#38
|
1958
|
+
def klass; end
|
1959
|
+
|
1960
|
+
# Returns the value of attribute name.
|
1961
|
+
#
|
1962
|
+
# source://faraday//lib/faraday/rack_builder.rb#28
|
1963
|
+
def name; end
|
1964
|
+
end
|
1965
|
+
|
1966
|
+
# source://faraday//lib/faraday/rack_builder.rb#26
|
1967
|
+
Faraday::RackBuilder::Handler::REGISTRY = T.let(T.unsafe(nil), Faraday::AdapterRegistry)
|
1968
|
+
|
1969
|
+
# source://faraday//lib/faraday/rack_builder.rb#214
|
1970
|
+
Faraday::RackBuilder::LOCK_ERR = T.let(T.unsafe(nil), String)
|
1971
|
+
|
1972
|
+
# source://faraday//lib/faraday/rack_builder.rb#215
|
1973
|
+
Faraday::RackBuilder::MISSING_ADAPTER_ERROR = T.let(T.unsafe(nil), String)
|
1974
|
+
|
1975
|
+
# Used to detect missing arguments
|
1976
|
+
#
|
1977
|
+
# source://faraday//lib/faraday/rack_builder.rb#16
|
1978
|
+
Faraday::RackBuilder::NO_ARGUMENT = T.let(T.unsafe(nil), Object)
|
1979
|
+
|
1980
|
+
# Error raised when trying to modify the stack after calling `lock!`
|
1981
|
+
#
|
1982
|
+
# source://faraday//lib/faraday/rack_builder.rb#21
|
1983
|
+
class Faraday::RackBuilder::StackLocked < ::RuntimeError; end
|
1984
|
+
|
1985
|
+
# Used to setup URLs, params, headers, and the request body in a sane manner.
|
1986
|
+
#
|
1987
|
+
# @example
|
1988
|
+
# @connection.post do |req|
|
1989
|
+
# req.url 'http://localhost', 'a' => '1' # 'http://localhost?a=1'
|
1990
|
+
# req.headers['b'] = '2' # Header
|
1991
|
+
# req.params['c'] = '3' # GET Param
|
1992
|
+
# req['b'] = '2' # also Header
|
1993
|
+
# req.body = 'abc'
|
1994
|
+
# end
|
1995
|
+
#
|
1996
|
+
# source://faraday//lib/faraday/request.rb#27
|
1997
|
+
class Faraday::Request < ::Struct
|
1998
|
+
extend ::Faraday::MiddlewareRegistry
|
1999
|
+
|
2000
|
+
# @param key [Object] key to look up in headers
|
2001
|
+
# @return [Object] value of the given header name
|
2002
|
+
#
|
2003
|
+
# source://faraday//lib/faraday/request.rb#92
|
2004
|
+
def [](key); end
|
2005
|
+
|
2006
|
+
# @param key [Object] key of header to write
|
2007
|
+
# @param value [Object] value of header
|
2008
|
+
#
|
2009
|
+
# source://faraday//lib/faraday/request.rb#98
|
2010
|
+
def []=(key, value); end
|
2011
|
+
|
2012
|
+
# @return [String] body
|
2013
|
+
def body; end
|
2014
|
+
|
2015
|
+
# @return [String] body
|
2016
|
+
def body=(_); end
|
2017
|
+
|
2018
|
+
# @return [Faraday::Utils::Headers] headers
|
2019
|
+
def headers; end
|
2020
|
+
|
2021
|
+
# Replace request headers, preserving the existing hash type.
|
2022
|
+
#
|
2023
|
+
# @param hash [Hash] new headers
|
2024
|
+
#
|
2025
|
+
# source://faraday//lib/faraday/request.rb#61
|
2026
|
+
def headers=(hash); end
|
2027
|
+
|
2028
|
+
# @return [Symbol] the HTTP method of the Request
|
2029
|
+
def http_method; end
|
2030
|
+
|
2031
|
+
# @return [Symbol] the HTTP method of the Request
|
2032
|
+
def http_method=(_); end
|
2033
|
+
|
2034
|
+
# Marshal serialization support.
|
2035
|
+
#
|
2036
|
+
# @return [Hash] the hash ready to be serialized in Marshal.
|
2037
|
+
#
|
2038
|
+
# source://faraday//lib/faraday/request.rb#105
|
2039
|
+
def marshal_dump; end
|
2040
|
+
|
2041
|
+
# Marshal serialization support.
|
2042
|
+
# Restores the instance variables according to the +serialised+.
|
2043
|
+
#
|
2044
|
+
# @param serialised [Hash] the serialised object.
|
2045
|
+
#
|
2046
|
+
# source://faraday//lib/faraday/request.rb#119
|
2047
|
+
def marshal_load(serialised); end
|
2048
|
+
|
2049
|
+
# @return [RequestOptions] options
|
2050
|
+
def options; end
|
2051
|
+
|
2052
|
+
# @return [RequestOptions] options
|
2053
|
+
def options=(_); end
|
2054
|
+
|
2055
|
+
# @return [Hash] query parameters
|
2056
|
+
def params; end
|
2057
|
+
|
2058
|
+
# Replace params, preserving the existing hash type.
|
2059
|
+
#
|
2060
|
+
# @param hash [Hash] new params
|
2061
|
+
#
|
2062
|
+
# source://faraday//lib/faraday/request.rb#49
|
2063
|
+
def params=(hash); end
|
2064
|
+
|
2065
|
+
# @return [URI, String] the path
|
2066
|
+
def path; end
|
2067
|
+
|
2068
|
+
# @return [URI, String] the path
|
2069
|
+
def path=(_); end
|
2070
|
+
|
2071
|
+
# @return [Env] the Env for this Request
|
2072
|
+
#
|
2073
|
+
# source://faraday//lib/faraday/request.rb#129
|
2074
|
+
def to_env(connection); end
|
2075
|
+
|
2076
|
+
# Update path and params.
|
2077
|
+
#
|
2078
|
+
# @param path [URI, String]
|
2079
|
+
# @param params [Hash, nil]
|
2080
|
+
# @return [void]
|
2081
|
+
#
|
2082
|
+
# source://faraday//lib/faraday/request.rb#74
|
2083
|
+
def url(path, params = T.unsafe(nil)); end
|
2084
|
+
|
2085
|
+
private
|
2086
|
+
|
2087
|
+
def member_get(_arg0); end
|
2088
|
+
def member_set(_arg0, _arg1); end
|
2089
|
+
|
2090
|
+
class << self
|
2091
|
+
def [](*_arg0); end
|
2092
|
+
|
2093
|
+
# @param request_method [String]
|
2094
|
+
# @return [Request]
|
2095
|
+
# @yield [request] for block customization, if block given
|
2096
|
+
# @yieldparam request [Request]
|
2097
|
+
#
|
2098
|
+
# source://faraday//lib/faraday/request.rb#39
|
2099
|
+
def create(request_method); end
|
2100
|
+
|
2101
|
+
def inspect; end
|
2102
|
+
def keyword_init?; end
|
2103
|
+
def members; end
|
2104
|
+
def new(*_arg0); end
|
2105
|
+
end
|
2106
|
+
end
|
2107
|
+
|
2108
|
+
# Request middleware for the Authorization HTTP header
|
2109
|
+
#
|
2110
|
+
# source://faraday//lib/faraday/request/authorization.rb#6
|
2111
|
+
class Faraday::Request::Authorization < ::Faraday::Middleware
|
2112
|
+
# @param app [#call]
|
2113
|
+
# @param type [String, Symbol] Type of Authorization
|
2114
|
+
# @param params [Array<String, Proc, #call>] parameters to build the Authorization header.
|
2115
|
+
# If the type is `:basic`, then these can be a login and password pair.
|
2116
|
+
# Otherwise, a single value is expected that will be appended after the type.
|
2117
|
+
# This value can be a proc or an object responding to `.call`, in which case
|
2118
|
+
# it will be invoked on each request.
|
2119
|
+
# @return [Authorization] a new instance of Authorization
|
2120
|
+
#
|
2121
|
+
# source://faraday//lib/faraday/request/authorization.rb#16
|
2122
|
+
def initialize(app, type, *params); end
|
2123
|
+
|
2124
|
+
# @param env [Faraday::Env]
|
2125
|
+
#
|
2126
|
+
# source://faraday//lib/faraday/request/authorization.rb#23
|
2127
|
+
def on_request(env); end
|
2128
|
+
|
2129
|
+
private
|
2130
|
+
|
2131
|
+
# @param type [String, Symbol]
|
2132
|
+
# @param env [Faraday::Env]
|
2133
|
+
# @param params [Array]
|
2134
|
+
# @return [String] a header value
|
2135
|
+
#
|
2136
|
+
# source://faraday//lib/faraday/request/authorization.rb#35
|
2137
|
+
def header_from(type, env, *params); end
|
2138
|
+
end
|
2139
|
+
|
2140
|
+
# source://faraday//lib/faraday/request/authorization.rb#7
|
2141
|
+
Faraday::Request::Authorization::KEY = T.let(T.unsafe(nil), String)
|
2142
|
+
|
2143
|
+
# Middleware for instrumenting Requests.
|
2144
|
+
#
|
2145
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#6
|
2146
|
+
class Faraday::Request::Instrumentation < ::Faraday::Middleware
|
2147
|
+
# Instruments requests using Active Support.
|
2148
|
+
#
|
2149
|
+
# Measures time spent only for synchronous requests.
|
2150
|
+
#
|
2151
|
+
# @example Using ActiveSupport::Notifications to measure time spent
|
2152
|
+
# for Faraday requests.
|
2153
|
+
# ActiveSupport::Notifications
|
2154
|
+
# .subscribe('request.faraday') do |name, starts, ends, _, env|
|
2155
|
+
# url = env[:url]
|
2156
|
+
# http_method = env[:method].to_s.upcase
|
2157
|
+
# duration = ends - starts
|
2158
|
+
# $stderr.puts '[%s] %s %s (%.3f s)' %
|
2159
|
+
# [url.host, http_method, url.request_uri, duration]
|
2160
|
+
# end
|
2161
|
+
# @option options
|
2162
|
+
# @option options
|
2163
|
+
# @param app [#call]
|
2164
|
+
# @param options [nil, Hash] Options hash
|
2165
|
+
# @return [Instrumentation] a new instance of Instrumentation
|
2166
|
+
#
|
2167
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#42
|
2168
|
+
def initialize(app, options = T.unsafe(nil)); end
|
2169
|
+
|
2170
|
+
# @param env [Faraday::Env]
|
2171
|
+
#
|
2172
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#49
|
2173
|
+
def call(env); end
|
2174
|
+
end
|
2175
|
+
|
2176
|
+
# Options class used in Request::Instrumentation class.
|
2177
|
+
#
|
2178
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#8
|
2179
|
+
class Faraday::Request::Instrumentation::Options < ::Faraday::Options
|
2180
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#17
|
2181
|
+
def instrumenter; end
|
2182
|
+
|
2183
|
+
def instrumenter=(_); end
|
2184
|
+
|
2185
|
+
# source://faraday//lib/faraday/request/instrumentation.rb#11
|
2186
|
+
def name; end
|
2187
|
+
|
2188
|
+
def name=(_); end
|
2189
|
+
|
2190
|
+
class << self
|
2191
|
+
def [](*_arg0); end
|
2192
|
+
def inspect; end
|
2193
|
+
def keyword_init?; end
|
2194
|
+
def members; end
|
2195
|
+
def new(*_arg0); end
|
2196
|
+
end
|
2197
|
+
end
|
2198
|
+
|
2199
|
+
# Request middleware that encodes the body as JSON.
|
2200
|
+
#
|
2201
|
+
# Processes only requests with matching Content-type or those without a type.
|
2202
|
+
# If a request doesn't have a type but has a body, it sets the Content-type
|
2203
|
+
# to JSON MIME-type.
|
2204
|
+
#
|
2205
|
+
# Doesn't try to encode bodies that already are in string form.
|
2206
|
+
#
|
2207
|
+
# source://faraday//lib/faraday/request/json.rb#14
|
2208
|
+
class Faraday::Request::Json < ::Faraday::Middleware
|
2209
|
+
# source://faraday//lib/faraday/request/json.rb#18
|
2210
|
+
def on_request(env); end
|
2211
|
+
|
2212
|
+
private
|
2213
|
+
|
2214
|
+
# @return [Boolean]
|
2215
|
+
#
|
2216
|
+
# source://faraday//lib/faraday/request/json.rb#48
|
2217
|
+
def body?(env); end
|
2218
|
+
|
2219
|
+
# source://faraday//lib/faraday/request/json.rb#26
|
2220
|
+
def encode(data); end
|
2221
|
+
|
2222
|
+
# @yield []
|
2223
|
+
#
|
2224
|
+
# source://faraday//lib/faraday/request/json.rb#36
|
2225
|
+
def match_content_type(env); end
|
2226
|
+
|
2227
|
+
# @return [Boolean]
|
2228
|
+
#
|
2229
|
+
# source://faraday//lib/faraday/request/json.rb#43
|
2230
|
+
def process_request?(env); end
|
2231
|
+
|
2232
|
+
# source://faraday//lib/faraday/request/json.rb#61
|
2233
|
+
def request_type(env); end
|
2234
|
+
end
|
2235
|
+
|
2236
|
+
# source://faraday//lib/faraday/request/json.rb#15
|
2237
|
+
Faraday::Request::Json::MIME_TYPE = T.let(T.unsafe(nil), String)
|
2238
|
+
|
2239
|
+
# source://faraday//lib/faraday/request/json.rb#16
|
2240
|
+
Faraday::Request::Json::MIME_TYPE_REGEX = T.let(T.unsafe(nil), Regexp)
|
2241
|
+
|
2242
|
+
# Middleware for supporting urlencoded requests.
|
2243
|
+
#
|
2244
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#6
|
2245
|
+
class Faraday::Request::UrlEncoded < ::Faraday::Middleware
|
2246
|
+
# Encodes as "application/x-www-form-urlencoded" if not already encoded or
|
2247
|
+
# of another type.
|
2248
|
+
#
|
2249
|
+
# @param env [Faraday::Env]
|
2250
|
+
#
|
2251
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#20
|
2252
|
+
def call(env); end
|
2253
|
+
|
2254
|
+
# @param env [Faraday::Env]
|
2255
|
+
# @yield [request_body] Body of the request
|
2256
|
+
#
|
2257
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#30
|
2258
|
+
def match_content_type(env); end
|
2259
|
+
|
2260
|
+
# @param env [Faraday::Env]
|
2261
|
+
# @return [Boolean] True if the request has a body and its Content-Type is
|
2262
|
+
# urlencoded.
|
2263
|
+
#
|
2264
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#43
|
2265
|
+
def process_request?(env); end
|
2266
|
+
|
2267
|
+
# @param env [Faraday::Env]
|
2268
|
+
# @return [String]
|
2269
|
+
#
|
2270
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#51
|
2271
|
+
def request_type(env); end
|
2272
|
+
|
2273
|
+
class << self
|
2274
|
+
# Returns the value of attribute mime_type.
|
2275
|
+
#
|
2276
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#12
|
2277
|
+
def mime_type; end
|
2278
|
+
|
2279
|
+
# Sets the attribute mime_type
|
2280
|
+
#
|
2281
|
+
# @param value the value to set the attribute mime_type to.
|
2282
|
+
#
|
2283
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#12
|
2284
|
+
def mime_type=(_arg0); end
|
2285
|
+
end
|
2286
|
+
end
|
2287
|
+
|
2288
|
+
# source://faraday//lib/faraday/request/url_encoded.rb#8
|
2289
|
+
Faraday::Request::UrlEncoded::CONTENT_TYPE = T.let(T.unsafe(nil), String)
|
2290
|
+
|
2291
|
+
# RequestOptions contains the configurable properties for a Faraday request.
|
2292
|
+
#
|
2293
|
+
# source://faraday//lib/faraday/options/request_options.rb#7
|
2294
|
+
class Faraday::RequestOptions < ::Faraday::Options
|
2295
|
+
# source://faraday//lib/faraday/options/request_options.rb#11
|
2296
|
+
def []=(key, value); end
|
2297
|
+
|
2298
|
+
def bind; end
|
2299
|
+
def bind=(_); end
|
2300
|
+
def boundary; end
|
2301
|
+
def boundary=(_); end
|
2302
|
+
def context; end
|
2303
|
+
def context=(_); end
|
2304
|
+
def oauth; end
|
2305
|
+
def oauth=(_); end
|
2306
|
+
def on_data; end
|
2307
|
+
def on_data=(_); end
|
2308
|
+
def open_timeout; end
|
2309
|
+
def open_timeout=(_); end
|
2310
|
+
def params_encoder; end
|
2311
|
+
def params_encoder=(_); end
|
2312
|
+
def proxy; end
|
2313
|
+
def proxy=(_); end
|
2314
|
+
def read_timeout; end
|
2315
|
+
def read_timeout=(_); end
|
2316
|
+
|
2317
|
+
# source://faraday//lib/faraday/options/request_options.rb#19
|
2318
|
+
def stream_response?; end
|
2319
|
+
|
2320
|
+
def timeout; end
|
2321
|
+
def timeout=(_); end
|
2322
|
+
def write_timeout; end
|
2323
|
+
def write_timeout=(_); end
|
2324
|
+
|
2325
|
+
class << self
|
2326
|
+
def [](*_arg0); end
|
2327
|
+
def inspect; end
|
2328
|
+
def keyword_init?; end
|
2329
|
+
def members; end
|
2330
|
+
def new(*_arg0); end
|
2331
|
+
end
|
2332
|
+
end
|
2333
|
+
|
2334
|
+
# Raised by Faraday::Response::RaiseError in case of a 408 response.
|
2335
|
+
#
|
2336
|
+
# source://faraday//lib/faraday/error.rb#116
|
2337
|
+
class Faraday::RequestTimeoutError < ::Faraday::ClientError; end
|
2338
|
+
|
2339
|
+
# Raised by Faraday::Response::RaiseError in case of a 404 response.
|
2340
|
+
#
|
2341
|
+
# source://faraday//lib/faraday/error.rb#108
|
2342
|
+
class Faraday::ResourceNotFound < ::Faraday::ClientError; end
|
2343
|
+
|
2344
|
+
# Response represents an HTTP response from making an HTTP request.
|
2345
|
+
#
|
2346
|
+
# source://faraday//lib/faraday/response.rb#7
|
2347
|
+
class Faraday::Response
|
2348
|
+
extend ::Forwardable
|
2349
|
+
extend ::Faraday::MiddlewareRegistry
|
2350
|
+
|
2351
|
+
# @return [Response] a new instance of Response
|
2352
|
+
#
|
2353
|
+
# source://faraday//lib/faraday/response.rb#11
|
2354
|
+
def initialize(env = T.unsafe(nil)); end
|
2355
|
+
|
2356
|
+
# source://forwardable/1.3.3/forwardable.rb#231
|
2357
|
+
def [](*args, **_arg1, &block); end
|
2358
|
+
|
2359
|
+
# Expand the env with more properties, without overriding existing ones.
|
2360
|
+
# Useful for applying request params after restoring a marshalled Response.
|
2361
|
+
#
|
2362
|
+
# source://faraday//lib/faraday/response.rb#80
|
2363
|
+
def apply_request(request_env); end
|
2364
|
+
|
2365
|
+
# source://faraday//lib/faraday/response.rb#32
|
2366
|
+
def body; end
|
2367
|
+
|
2368
|
+
# Returns the value of attribute env.
|
2369
|
+
#
|
2370
|
+
# source://faraday//lib/faraday/response.rb#16
|
2371
|
+
def env; end
|
2372
|
+
|
2373
|
+
# source://faraday//lib/faraday/response.rb#49
|
2374
|
+
def finish(env); end
|
2375
|
+
|
2376
|
+
# @return [Boolean]
|
2377
|
+
#
|
2378
|
+
# source://faraday//lib/faraday/response.rb#36
|
2379
|
+
def finished?; end
|
2380
|
+
|
2381
|
+
# source://faraday//lib/faraday/response.rb#26
|
2382
|
+
def headers; end
|
2383
|
+
|
2384
|
+
# because @on_complete_callbacks cannot be marshalled
|
2385
|
+
#
|
2386
|
+
# source://faraday//lib/faraday/response.rb#70
|
2387
|
+
def marshal_dump; end
|
2388
|
+
|
2389
|
+
# source://faraday//lib/faraday/response.rb#74
|
2390
|
+
def marshal_load(env); end
|
2391
|
+
|
2392
|
+
# source://faraday//lib/faraday/response.rb#40
|
2393
|
+
def on_complete(&block); end
|
2394
|
+
|
2395
|
+
# source://faraday//lib/faraday/response.rb#22
|
2396
|
+
def reason_phrase; end
|
2397
|
+
|
2398
|
+
# source://faraday//lib/faraday/response.rb#18
|
2399
|
+
def status; end
|
2400
|
+
|
2401
|
+
# @return [Boolean]
|
2402
|
+
#
|
2403
|
+
# source://faraday//lib/faraday/response.rb#57
|
2404
|
+
def success?; end
|
2405
|
+
|
2406
|
+
# source://faraday//lib/faraday/response.rb#61
|
2407
|
+
def to_hash; end
|
2408
|
+
end
|
2409
|
+
|
2410
|
+
# Parse response bodies as JSON.
|
2411
|
+
#
|
2412
|
+
# source://faraday//lib/faraday/response/json.rb#8
|
2413
|
+
class Faraday::Response::Json < ::Faraday::Middleware
|
2414
|
+
# @return [Json] a new instance of Json
|
2415
|
+
#
|
2416
|
+
# source://faraday//lib/faraday/response/json.rb#9
|
2417
|
+
def initialize(app = T.unsafe(nil), parser_options: T.unsafe(nil), content_type: T.unsafe(nil), preserve_raw: T.unsafe(nil)); end
|
2418
|
+
|
2419
|
+
# source://faraday//lib/faraday/response/json.rb#18
|
2420
|
+
def on_complete(env); end
|
2421
|
+
|
2422
|
+
private
|
2423
|
+
|
2424
|
+
# source://faraday//lib/faraday/response/json.rb#31
|
2425
|
+
def parse(body); end
|
2426
|
+
|
2427
|
+
# @return [Boolean]
|
2428
|
+
#
|
2429
|
+
# source://faraday//lib/faraday/response/json.rb#39
|
2430
|
+
def parse_response?(env); end
|
2431
|
+
|
2432
|
+
# source://faraday//lib/faraday/response/json.rb#57
|
2433
|
+
def process_parser_options; end
|
2434
|
+
|
2435
|
+
# source://faraday//lib/faraday/response/json.rb#24
|
2436
|
+
def process_response(env); end
|
2437
|
+
|
2438
|
+
# @return [Boolean]
|
2439
|
+
#
|
2440
|
+
# source://faraday//lib/faraday/response/json.rb#44
|
2441
|
+
def process_response_type?(env); end
|
2442
|
+
|
2443
|
+
# source://faraday//lib/faraday/response/json.rb#51
|
2444
|
+
def response_type(env); end
|
2445
|
+
end
|
2446
|
+
|
2447
|
+
# Logger is a middleware that logs internal events in the HTTP request
|
2448
|
+
# lifecycle to a given Logger object. By default, this logs to STDOUT. See
|
2449
|
+
# Faraday::Logging::Formatter to see specifically what is logged.
|
2450
|
+
#
|
2451
|
+
# source://faraday//lib/faraday/response/logger.rb#12
|
2452
|
+
class Faraday::Response::Logger < ::Faraday::Middleware
|
2453
|
+
# @return [Logger] a new instance of Logger
|
2454
|
+
# @yield [@formatter]
|
2455
|
+
#
|
2456
|
+
# source://faraday//lib/faraday/response/logger.rb#13
|
2457
|
+
def initialize(app, logger = T.unsafe(nil), options = T.unsafe(nil)); end
|
2458
|
+
|
2459
|
+
# source://faraday//lib/faraday/response/logger.rb#21
|
2460
|
+
def call(env); end
|
2461
|
+
|
2462
|
+
# source://faraday//lib/faraday/response/logger.rb#26
|
2463
|
+
def on_complete(env); end
|
2464
|
+
|
2465
|
+
# source://faraday//lib/faraday/response/logger.rb#30
|
2466
|
+
def on_error(exc); end
|
2467
|
+
end
|
2468
|
+
|
2469
|
+
# RaiseError is a Faraday middleware that raises exceptions on common HTTP
|
2470
|
+
# client or server error responses.
|
2471
|
+
#
|
2472
|
+
# source://faraday//lib/faraday/response/raise_error.rb#7
|
2473
|
+
class Faraday::Response::RaiseError < ::Faraday::Middleware
|
2474
|
+
# source://faraday//lib/faraday/response/raise_error.rb#25
|
2475
|
+
def on_complete(env); end
|
2476
|
+
|
2477
|
+
# source://faraday//lib/faraday/response/raise_error.rb#75
|
2478
|
+
def query_params(env); end
|
2479
|
+
|
2480
|
+
# Returns a hash of response data with the following keys:
|
2481
|
+
# - status
|
2482
|
+
# - headers
|
2483
|
+
# - body
|
2484
|
+
# - request
|
2485
|
+
#
|
2486
|
+
# The `request` key is omitted when the middleware is explicitly
|
2487
|
+
# configured with the option `include_request: false`.
|
2488
|
+
#
|
2489
|
+
# source://faraday//lib/faraday/response/raise_error.rb#52
|
2490
|
+
def response_values(env); end
|
2491
|
+
end
|
2492
|
+
|
2493
|
+
# source://faraday//lib/faraday/response/raise_error.rb#9
|
2494
|
+
Faraday::Response::RaiseError::ClientErrorStatuses = T.let(T.unsafe(nil), Range)
|
2495
|
+
|
2496
|
+
# source://faraday//lib/faraday/response/raise_error.rb#11
|
2497
|
+
Faraday::Response::RaiseError::ClientErrorStatusesWithCustomExceptions = T.let(T.unsafe(nil), Hash)
|
2498
|
+
|
2499
|
+
# source://faraday//lib/faraday/response/raise_error.rb#23
|
2500
|
+
Faraday::Response::RaiseError::DEFAULT_OPTIONS = T.let(T.unsafe(nil), Hash)
|
2501
|
+
|
2502
|
+
# source://faraday//lib/faraday/response/raise_error.rb#10
|
2503
|
+
Faraday::Response::RaiseError::ServerErrorStatuses = T.let(T.unsafe(nil), Range)
|
2504
|
+
|
2505
|
+
# A unified client error for SSL errors.
|
2506
|
+
#
|
2507
|
+
# source://faraday//lib/faraday/error.rb#155
|
2508
|
+
class Faraday::SSLError < ::Faraday::Error; end
|
2509
|
+
|
2510
|
+
# SSL-related options.
|
2511
|
+
#
|
2512
|
+
# source://faraday//lib/faraday/options/ssl_options.rb#56
|
2513
|
+
class Faraday::SSLOptions < ::Faraday::Options
|
2514
|
+
# @return [String] CA file
|
2515
|
+
def ca_file; end
|
2516
|
+
|
2517
|
+
# @return [String] CA file
|
2518
|
+
def ca_file=(_); end
|
2519
|
+
|
2520
|
+
# @return [String] CA path
|
2521
|
+
def ca_path; end
|
2522
|
+
|
2523
|
+
# @return [String] CA path
|
2524
|
+
def ca_path=(_); end
|
2525
|
+
|
2526
|
+
# @return [OpenSSL::X509::Store] certificate store
|
2527
|
+
def cert_store; end
|
2528
|
+
|
2529
|
+
# @return [OpenSSL::X509::Store] certificate store
|
2530
|
+
def cert_store=(_); end
|
2531
|
+
|
2532
|
+
# @return [OpenSSL::X509::Certificate] certificate (Excon only)
|
2533
|
+
def certificate; end
|
2534
|
+
|
2535
|
+
# @return [OpenSSL::X509::Certificate] certificate (Excon only)
|
2536
|
+
def certificate=(_); end
|
2537
|
+
|
2538
|
+
# @return [String] cipher list in OpenSSL format (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-ciphers-3D)
|
2539
|
+
def ciphers; end
|
2540
|
+
|
2541
|
+
# @return [String] cipher list in OpenSSL format (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-ciphers-3D)
|
2542
|
+
def ciphers=(_); end
|
2543
|
+
|
2544
|
+
# @return [String, OpenSSL::X509::Certificate] client certificate
|
2545
|
+
def client_cert; end
|
2546
|
+
|
2547
|
+
# @return [String, OpenSSL::X509::Certificate] client certificate
|
2548
|
+
def client_cert=(_); end
|
2549
|
+
|
2550
|
+
# @return [String, OpenSSL::PKey::RSA, OpenSSL::PKey::DSA] client key
|
2551
|
+
def client_key; end
|
2552
|
+
|
2553
|
+
# @return [String, OpenSSL::PKey::RSA, OpenSSL::PKey::DSA] client key
|
2554
|
+
def client_key=(_); end
|
2555
|
+
|
2556
|
+
# source://faraday//lib/faraday/options/ssl_options.rb#67
|
2557
|
+
def disable?; end
|
2558
|
+
|
2559
|
+
# @return [String] Server hostname used for SNI (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLSocket.html#method-i-hostname-3D)
|
2560
|
+
def hostname; end
|
2561
|
+
|
2562
|
+
# @return [String] Server hostname used for SNI (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLSocket.html#method-i-hostname-3D)
|
2563
|
+
def hostname=(_); end
|
2564
|
+
|
2565
|
+
# @return [String, Symbol] maximum SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-max_version-3D)
|
2566
|
+
def max_version; end
|
2567
|
+
|
2568
|
+
# @return [String, Symbol] maximum SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-max_version-3D)
|
2569
|
+
def max_version=(_); end
|
2570
|
+
|
2571
|
+
# @return [String, Symbol] minimum SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-min_version-3D)
|
2572
|
+
def min_version; end
|
2573
|
+
|
2574
|
+
# @return [String, Symbol] minimum SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-min_version-3D)
|
2575
|
+
def min_version=(_); end
|
2576
|
+
|
2577
|
+
# @return [OpenSSL::PKey::RSA, OpenSSL::PKey::DSA] private key (Excon only)
|
2578
|
+
def private_key; end
|
2579
|
+
|
2580
|
+
# @return [OpenSSL::PKey::RSA, OpenSSL::PKey::DSA] private key (Excon only)
|
2581
|
+
def private_key=(_); end
|
2582
|
+
|
2583
|
+
# @return [Boolean] whether to verify SSL certificates or not
|
2584
|
+
def verify; end
|
2585
|
+
|
2586
|
+
# @return [Boolean] whether to verify SSL certificates or not
|
2587
|
+
def verify=(_); end
|
2588
|
+
|
2589
|
+
# source://faraday//lib/faraday/options/ssl_options.rb#62
|
2590
|
+
def verify?; end
|
2591
|
+
|
2592
|
+
# @return [Integer] maximum depth for the certificate chain verification
|
2593
|
+
def verify_depth; end
|
2594
|
+
|
2595
|
+
# @return [Integer] maximum depth for the certificate chain verification
|
2596
|
+
def verify_depth=(_); end
|
2597
|
+
|
2598
|
+
# @return [Boolean] whether to enable hostname verification on server certificates
|
2599
|
+
# during the handshake or not (see https://github.com/ruby/openssl/pull/60)
|
2600
|
+
def verify_hostname; end
|
2601
|
+
|
2602
|
+
# @return [Boolean] whether to enable hostname verification on server certificates
|
2603
|
+
# during the handshake or not (see https://github.com/ruby/openssl/pull/60)
|
2604
|
+
def verify_hostname=(_); end
|
2605
|
+
|
2606
|
+
# source://faraday//lib/faraday/options/ssl_options.rb#72
|
2607
|
+
def verify_hostname?; end
|
2608
|
+
|
2609
|
+
# @return [Integer] Any `OpenSSL::SSL::` constant (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL.html)
|
2610
|
+
def verify_mode; end
|
2611
|
+
|
2612
|
+
# @return [Integer] Any `OpenSSL::SSL::` constant (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL.html)
|
2613
|
+
def verify_mode=(_); end
|
2614
|
+
|
2615
|
+
# @return [String, Symbol] SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-ssl_version-3D)
|
2616
|
+
def version; end
|
2617
|
+
|
2618
|
+
# @return [String, Symbol] SSL version (see https://ruby-doc.org/stdlib-2.5.1/libdoc/openssl/rdoc/OpenSSL/SSL/SSLContext.html#method-i-ssl_version-3D)
|
2619
|
+
def version=(_); end
|
2620
|
+
|
2621
|
+
class << self
|
2622
|
+
def [](*_arg0); end
|
2623
|
+
def inspect; end
|
2624
|
+
def keyword_init?; end
|
2625
|
+
def members; end
|
2626
|
+
def new(*_arg0); end
|
2627
|
+
end
|
2628
|
+
end
|
2629
|
+
|
2630
|
+
# Faraday server error class. Represents 5xx status responses.
|
2631
|
+
#
|
2632
|
+
# source://faraday//lib/faraday/error.rb#132
|
2633
|
+
class Faraday::ServerError < ::Faraday::Error; end
|
2634
|
+
|
2635
|
+
# A unified client error for timeouts.
|
2636
|
+
#
|
2637
|
+
# source://faraday//lib/faraday/error.rb#136
|
2638
|
+
class Faraday::TimeoutError < ::Faraday::ServerError
|
2639
|
+
# @return [TimeoutError] a new instance of TimeoutError
|
2640
|
+
#
|
2641
|
+
# source://faraday//lib/faraday/error.rb#137
|
2642
|
+
def initialize(exc = T.unsafe(nil), response = T.unsafe(nil)); end
|
2643
|
+
end
|
2644
|
+
|
2645
|
+
# Raised by Faraday::Response::RaiseError in case of a 429 response.
|
2646
|
+
#
|
2647
|
+
# source://faraday//lib/faraday/error.rb#128
|
2648
|
+
class Faraday::TooManyRequestsError < ::Faraday::ClientError; end
|
2649
|
+
|
2650
|
+
# Raised by Faraday::Response::RaiseError in case of a 401 response.
|
2651
|
+
#
|
2652
|
+
# source://faraday//lib/faraday/error.rb#100
|
2653
|
+
class Faraday::UnauthorizedError < ::Faraday::ClientError; end
|
2654
|
+
|
2655
|
+
# Raised by Faraday::Response::RaiseError in case of a 422 response.
|
2656
|
+
#
|
2657
|
+
# source://faraday//lib/faraday/error.rb#124
|
2658
|
+
class Faraday::UnprocessableEntityError < ::Faraday::ClientError; end
|
2659
|
+
|
2660
|
+
# Utils contains various static helper methods.
|
2661
|
+
#
|
2662
|
+
# source://faraday//lib/faraday/utils/headers.rb#4
|
2663
|
+
module Faraday::Utils
|
2664
|
+
private
|
2665
|
+
|
2666
|
+
# Normalize URI() behavior across Ruby versions
|
2667
|
+
#
|
2668
|
+
# url - A String or URI.
|
2669
|
+
#
|
2670
|
+
# Returns a parsed URI.
|
2671
|
+
#
|
2672
|
+
# source://faraday//lib/faraday/utils.rb#70
|
2673
|
+
def URI(url); end
|
2674
|
+
|
2675
|
+
# source://faraday//lib/faraday/utils.rb#55
|
2676
|
+
def basic_header_from(login, pass); end
|
2677
|
+
|
2678
|
+
# source://faraday//lib/faraday/utils.rb#16
|
2679
|
+
def build_nested_query(params); end
|
2680
|
+
|
2681
|
+
# source://faraday//lib/faraday/utils.rb#12
|
2682
|
+
def build_query(params); end
|
2683
|
+
|
2684
|
+
# Recursive hash merge
|
2685
|
+
#
|
2686
|
+
# source://faraday//lib/faraday/utils.rb#113
|
2687
|
+
def deep_merge(source, hash); end
|
2688
|
+
|
2689
|
+
# Recursive hash update
|
2690
|
+
#
|
2691
|
+
# source://faraday//lib/faraday/utils.rb#101
|
2692
|
+
def deep_merge!(target, hash); end
|
2693
|
+
|
2694
|
+
# source://faraday//lib/faraday/utils.rb#51
|
2695
|
+
def default_params_encoder; end
|
2696
|
+
|
2697
|
+
# source://faraday//lib/faraday/utils.rb#20
|
2698
|
+
def default_space_encoding; end
|
2699
|
+
|
2700
|
+
# source://faraday//lib/faraday/utils.rb#80
|
2701
|
+
def default_uri_parser; end
|
2702
|
+
|
2703
|
+
# source://faraday//lib/faraday/utils.rb#84
|
2704
|
+
def default_uri_parser=(parser); end
|
2705
|
+
|
2706
|
+
# source://faraday//lib/faraday/utils.rb#30
|
2707
|
+
def escape(str); end
|
2708
|
+
|
2709
|
+
# Receives a String or URI and returns just
|
2710
|
+
# the path with the query string sorted.
|
2711
|
+
#
|
2712
|
+
# source://faraday//lib/faraday/utils.rb#94
|
2713
|
+
def normalize_path(url); end
|
2714
|
+
|
2715
|
+
# source://faraday//lib/faraday/utils.rb#47
|
2716
|
+
def parse_nested_query(query); end
|
2717
|
+
|
2718
|
+
# Adapted from Rack
|
2719
|
+
#
|
2720
|
+
# source://faraday//lib/faraday/utils.rb#43
|
2721
|
+
def parse_query(query); end
|
2722
|
+
|
2723
|
+
# source://faraday//lib/faraday/utils.rb#117
|
2724
|
+
def sort_query_params(query); end
|
2725
|
+
|
2726
|
+
# source://faraday//lib/faraday/utils.rb#36
|
2727
|
+
def unescape(str); end
|
2728
|
+
|
2729
|
+
class << self
|
2730
|
+
# Normalize URI() behavior across Ruby versions
|
2731
|
+
#
|
2732
|
+
# url - A String or URI.
|
2733
|
+
#
|
2734
|
+
# Returns a parsed URI.
|
2735
|
+
#
|
2736
|
+
# source://faraday//lib/faraday/utils.rb#70
|
2737
|
+
def URI(url); end
|
2738
|
+
|
2739
|
+
# source://faraday//lib/faraday/utils.rb#55
|
2740
|
+
def basic_header_from(login, pass); end
|
2741
|
+
|
2742
|
+
# source://faraday//lib/faraday/utils.rb#16
|
2743
|
+
def build_nested_query(params); end
|
2744
|
+
|
2745
|
+
# source://faraday//lib/faraday/utils.rb#12
|
2746
|
+
def build_query(params); end
|
2747
|
+
|
2748
|
+
# Recursive hash merge
|
2749
|
+
#
|
2750
|
+
# source://faraday//lib/faraday/utils.rb#113
|
2751
|
+
def deep_merge(source, hash); end
|
2752
|
+
|
2753
|
+
# Recursive hash update
|
2754
|
+
#
|
2755
|
+
# source://faraday//lib/faraday/utils.rb#101
|
2756
|
+
def deep_merge!(target, hash); end
|
2757
|
+
|
2758
|
+
# source://faraday//lib/faraday/utils.rb#51
|
2759
|
+
def default_params_encoder; end
|
2760
|
+
|
2761
|
+
# Sets the attribute default_params_encoder
|
2762
|
+
#
|
2763
|
+
# @param value the value to set the attribute default_params_encoder to.
|
2764
|
+
#
|
2765
|
+
# source://faraday//lib/faraday/utils.rb#62
|
2766
|
+
def default_params_encoder=(_arg0); end
|
2767
|
+
|
2768
|
+
# source://faraday//lib/faraday/utils.rb#20
|
2769
|
+
def default_space_encoding; end
|
2770
|
+
|
2771
|
+
# Sets the attribute default_space_encoding
|
2772
|
+
#
|
2773
|
+
# @param value the value to set the attribute default_space_encoding to.
|
2774
|
+
#
|
2775
|
+
# source://faraday//lib/faraday/utils.rb#25
|
2776
|
+
def default_space_encoding=(_arg0); end
|
2777
|
+
|
2778
|
+
# source://faraday//lib/faraday/utils.rb#80
|
2779
|
+
def default_uri_parser; end
|
2780
|
+
|
2781
|
+
# source://faraday//lib/faraday/utils.rb#84
|
2782
|
+
def default_uri_parser=(parser); end
|
2783
|
+
|
2784
|
+
# source://faraday//lib/faraday/utils.rb#30
|
2785
|
+
def escape(str); end
|
2786
|
+
|
2787
|
+
# Receives a String or URI and returns just
|
2788
|
+
# the path with the query string sorted.
|
2789
|
+
#
|
2790
|
+
# source://faraday//lib/faraday/utils.rb#94
|
2791
|
+
def normalize_path(url); end
|
2792
|
+
|
2793
|
+
# source://faraday//lib/faraday/utils.rb#47
|
2794
|
+
def parse_nested_query(query); end
|
2795
|
+
|
2796
|
+
# Adapted from Rack
|
2797
|
+
#
|
2798
|
+
# source://faraday//lib/faraday/utils.rb#43
|
2799
|
+
def parse_query(query); end
|
2800
|
+
|
2801
|
+
# source://faraday//lib/faraday/utils.rb#117
|
2802
|
+
def sort_query_params(query); end
|
2803
|
+
|
2804
|
+
# source://faraday//lib/faraday/utils.rb#36
|
2805
|
+
def unescape(str); end
|
2806
|
+
end
|
2807
|
+
end
|
2808
|
+
|
2809
|
+
# source://faraday//lib/faraday/utils.rb#40
|
2810
|
+
Faraday::Utils::DEFAULT_SEP = T.let(T.unsafe(nil), Regexp)
|
2811
|
+
|
2812
|
+
# source://faraday//lib/faraday/utils.rb#28
|
2813
|
+
Faraday::Utils::ESCAPE_RE = T.let(T.unsafe(nil), Regexp)
|
2814
|
+
|
2815
|
+
# A case-insensitive Hash that preserves the original case of a header
|
2816
|
+
# when set.
|
2817
|
+
#
|
2818
|
+
# Adapted from Rack::Utils::HeaderHash
|
2819
|
+
#
|
2820
|
+
# source://faraday//lib/faraday/utils/headers.rb#9
|
2821
|
+
class Faraday::Utils::Headers < ::Hash
|
2822
|
+
# @return [Headers] a new instance of Headers
|
2823
|
+
#
|
2824
|
+
# source://faraday//lib/faraday/utils/headers.rb#20
|
2825
|
+
def initialize(hash = T.unsafe(nil)); end
|
2826
|
+
|
2827
|
+
# source://faraday//lib/faraday/utils/headers.rb#52
|
2828
|
+
def [](key); end
|
2829
|
+
|
2830
|
+
# source://faraday//lib/faraday/utils/headers.rb#57
|
2831
|
+
def []=(key, val); end
|
2832
|
+
|
2833
|
+
# source://faraday//lib/faraday/utils/headers.rb#71
|
2834
|
+
def delete(key); end
|
2835
|
+
|
2836
|
+
# source://faraday//lib/faraday/utils/headers.rb#80
|
2837
|
+
def dig(key, *rest); end
|
2838
|
+
|
2839
|
+
# source://faraday//lib/faraday/utils/headers.rb#65
|
2840
|
+
def fetch(key, *_arg1, **_arg2, &_arg3); end
|
2841
|
+
|
2842
|
+
# @return [Boolean]
|
2843
|
+
#
|
2844
|
+
# source://faraday//lib/faraday/utils/headers.rb#86
|
2845
|
+
def has_key?(key); end
|
2846
|
+
|
2847
|
+
# @return [Boolean]
|
2848
|
+
#
|
2849
|
+
# source://faraday//lib/faraday/utils/headers.rb#86
|
2850
|
+
def include?(key); end
|
2851
|
+
|
2852
|
+
# source://faraday//lib/faraday/utils/headers.rb#26
|
2853
|
+
def initialize_names; end
|
2854
|
+
|
2855
|
+
# @return [Boolean]
|
2856
|
+
#
|
2857
|
+
# source://faraday//lib/faraday/utils/headers.rb#86
|
2858
|
+
def key?(key); end
|
2859
|
+
|
2860
|
+
# @return [Boolean]
|
2861
|
+
#
|
2862
|
+
# source://faraday//lib/faraday/utils/headers.rb#86
|
2863
|
+
def member?(key); end
|
2864
|
+
|
2865
|
+
# source://faraday//lib/faraday/utils/headers.rb#101
|
2866
|
+
def merge(other); end
|
2867
|
+
|
2868
|
+
# source://faraday//lib/faraday/utils/headers.rb#94
|
2869
|
+
def merge!(other); end
|
2870
|
+
|
2871
|
+
# source://faraday//lib/faraday/utils/headers.rb#117
|
2872
|
+
def parse(header_string); end
|
2873
|
+
|
2874
|
+
# source://faraday//lib/faraday/utils/headers.rb#106
|
2875
|
+
def replace(other); end
|
2876
|
+
|
2877
|
+
# source://faraday//lib/faraday/utils/headers.rb#113
|
2878
|
+
def to_hash; end
|
2879
|
+
|
2880
|
+
# source://faraday//lib/faraday/utils/headers.rb#94
|
2881
|
+
def update(other); end
|
2882
|
+
|
2883
|
+
protected
|
2884
|
+
|
2885
|
+
# Returns the value of attribute names.
|
2886
|
+
#
|
2887
|
+
# source://faraday//lib/faraday/utils/headers.rb#135
|
2888
|
+
def names; end
|
2889
|
+
|
2890
|
+
private
|
2891
|
+
|
2892
|
+
# Join multiple values with a comma.
|
2893
|
+
#
|
2894
|
+
# source://faraday//lib/faraday/utils/headers.rb#140
|
2895
|
+
def add_parsed(key, value); end
|
2896
|
+
|
2897
|
+
# on dup/clone, we need to duplicate @names hash
|
2898
|
+
#
|
2899
|
+
# source://faraday//lib/faraday/utils/headers.rb#31
|
2900
|
+
def initialize_copy(other); end
|
2901
|
+
|
2902
|
+
class << self
|
2903
|
+
# source://faraday//lib/faraday/utils/headers.rb#14
|
2904
|
+
def allocate; end
|
2905
|
+
|
2906
|
+
# source://faraday//lib/faraday/utils/headers.rb#10
|
2907
|
+
def from(value); end
|
2908
|
+
end
|
2909
|
+
end
|
2910
|
+
|
2911
|
+
# symbol -> string mapper + cache
|
2912
|
+
#
|
2913
|
+
# source://faraday//lib/faraday/utils/headers.rb#40
|
2914
|
+
Faraday::Utils::Headers::KeyMap = T.let(T.unsafe(nil), Hash)
|
2915
|
+
|
2916
|
+
# A hash with stringified keys.
|
2917
|
+
#
|
2918
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#6
|
2919
|
+
class Faraday::Utils::ParamsHash < ::Hash
|
2920
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#7
|
2921
|
+
def [](key); end
|
2922
|
+
|
2923
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#11
|
2924
|
+
def []=(key, value); end
|
2925
|
+
|
2926
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#15
|
2927
|
+
def delete(key); end
|
2928
|
+
|
2929
|
+
# @return [Boolean]
|
2930
|
+
#
|
2931
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#19
|
2932
|
+
def has_key?(key); end
|
2933
|
+
|
2934
|
+
# @return [Boolean]
|
2935
|
+
#
|
2936
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#19
|
2937
|
+
def include?(key); end
|
2938
|
+
|
2939
|
+
# @return [Boolean]
|
2940
|
+
#
|
2941
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#19
|
2942
|
+
def key?(key); end
|
2943
|
+
|
2944
|
+
# @return [Boolean]
|
2945
|
+
#
|
2946
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#19
|
2947
|
+
def member?(key); end
|
2948
|
+
|
2949
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#35
|
2950
|
+
def merge(params); end
|
2951
|
+
|
2952
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#27
|
2953
|
+
def merge!(params); end
|
2954
|
+
|
2955
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#44
|
2956
|
+
def merge_query(query, encoder = T.unsafe(nil)); end
|
2957
|
+
|
2958
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#39
|
2959
|
+
def replace(other); end
|
2960
|
+
|
2961
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#50
|
2962
|
+
def to_query(encoder = T.unsafe(nil)); end
|
2963
|
+
|
2964
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#27
|
2965
|
+
def update(params); end
|
2966
|
+
|
2967
|
+
private
|
2968
|
+
|
2969
|
+
# source://faraday//lib/faraday/utils/params_hash.rb#56
|
2970
|
+
def convert_key(key); end
|
2971
|
+
end
|
2972
|
+
|
2973
|
+
# source://faraday//lib/faraday/version.rb#4
|
2974
|
+
Faraday::VERSION = T.let(T.unsafe(nil), String)
|