multiwoven-integrations 0.13.1 → 0.13.2
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7f20d31c38b9e0f1311379e2d2b5f6637b2d5241abe6e0504ed0b448eb044909
|
4
|
+
data.tar.gz: 40f8da2f352ffbbbadee190efd5db47e89008e15d95165f7d7b9cba6d64574ce
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cd8d4130999ac7759f1bd8aefa1430ab9d8d2c3bd3a96c392896461ef46e64ac987546d523fd4d4e1851a337ed04e598e0f00ee480c2ce355fa8faaae8855707
|
7
|
+
data.tar.gz: 064f797d1d1bd3b5290a58325b8c75a8961b4341217a93f6f17ab91403de4f16143f90243f8519abda0b2c04304fe97aee0c89450b853ff1ea956a635e3efc0b
|
@@ -4,10 +4,15 @@ module Multiwoven
|
|
4
4
|
module Integrations::Core
|
5
5
|
class HttpClient
|
6
6
|
class << self
|
7
|
-
def request(url, method, payload: nil, headers: {})
|
7
|
+
def request(url, method, payload: nil, headers: {}, config: {})
|
8
8
|
uri = URI(url)
|
9
9
|
http = Net::HTTP.new(uri.host, uri.port)
|
10
10
|
http.use_ssl = (uri.scheme == "https")
|
11
|
+
|
12
|
+
# Set timeout if provided
|
13
|
+
http.open_timeout = config[:timeout] if config[:timeout]
|
14
|
+
http.read_timeout = config[:timeout] if config[:timeout]
|
15
|
+
|
11
16
|
request = build_request(method, uri, payload, headers)
|
12
17
|
http.request(request)
|
13
18
|
end
|