ravelin 0.1.45 → 0.1.47
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ravelin/client.rb +8 -3
- data/lib/ravelin/payment_methods.rb +1 -1
- data/lib/ravelin/version.rb +1 -1
- metadata +20 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3c658a67cc9147a5494723b434bfedfe44f9ed7afc3ec3ecacf669f2f657f3da
|
4
|
+
data.tar.gz: 380067a9cd40b0d7acc00d924d249f1cb0f24ea15c6ed0a108b138dde6950f94
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fe1cd7ed644cd7d92b899197d2a7c4d0204c784eb57cb02fca8e299492c3b27cd3ebde4920b65ac7bd12b4e5d48e4ac67b89eb9f091778896f882e94cd6ab394
|
7
|
+
data.tar.gz: 192540941b834e6391899dc6723b7ae2c5ae384a22d57b5a2a1650ded9c47f5f3647cef137f211d329faee4c2e0261e32df13a2a7defa28aa50b98a7019c075e
|
data/lib/ravelin/client.rb
CHANGED
@@ -27,11 +27,12 @@ module Ravelin
|
|
27
27
|
|
28
28
|
def send_event(**args)
|
29
29
|
score = args.delete(:score)
|
30
|
+
headers = args.delete(:headers)
|
30
31
|
event = Event.new(**args)
|
31
32
|
|
32
33
|
score_param = score ? "?score=true" : nil
|
33
34
|
|
34
|
-
post("#{@url_prefix}/v#{@api_version}/#{event.name}#{score_param}", event.serializable_hash)
|
35
|
+
post("#{@url_prefix}/v#{@api_version}/#{event.name}#{score_param}", event.serializable_hash, headers)
|
35
36
|
end
|
36
37
|
|
37
38
|
def send_backfill_event(**args)
|
@@ -67,8 +68,12 @@ module Ravelin
|
|
67
68
|
|
68
69
|
private
|
69
70
|
|
70
|
-
def post(url, payload)
|
71
|
-
response = @connection.post(url, payload.to_json)
|
71
|
+
def post(url, payload, headers = {})
|
72
|
+
response = @connection.post(url, payload.to_json) do |request|
|
73
|
+
headers&.each { |key, value|
|
74
|
+
request.headers[key] = value
|
75
|
+
}
|
76
|
+
end
|
72
77
|
|
73
78
|
if response.success?
|
74
79
|
Response.new(response)
|
data/lib/ravelin/version.rb
CHANGED
metadata
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ravelin
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.47
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Sam Levy
|
8
8
|
- Tommy Palmer
|
9
9
|
- Gurkan Oluc
|
10
10
|
- Mathilda Thompson
|
11
|
-
autorequire:
|
11
|
+
autorequire:
|
12
12
|
bindir: exe
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2024-04-18 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: faraday
|
@@ -97,6 +97,20 @@ dependencies:
|
|
97
97
|
- - "~>"
|
98
98
|
- !ruby/object:Gem::Version
|
99
99
|
version: '3.18'
|
100
|
+
- !ruby/object:Gem::Dependency
|
101
|
+
name: public_suffix
|
102
|
+
requirement: !ruby/object:Gem::Requirement
|
103
|
+
requirements:
|
104
|
+
- - "~>"
|
105
|
+
- !ruby/object:Gem::Version
|
106
|
+
version: '4.0'
|
107
|
+
type: :development
|
108
|
+
prerelease: false
|
109
|
+
version_requirements: !ruby/object:Gem::Requirement
|
110
|
+
requirements:
|
111
|
+
- - "~>"
|
112
|
+
- !ruby/object:Gem::Version
|
113
|
+
version: '4.0'
|
100
114
|
description: Ravelin is a fraud detection tool. See https://www.ravelin.com for details.
|
101
115
|
email:
|
102
116
|
- sam.levy@deliveroo.co.uk
|
@@ -149,7 +163,7 @@ homepage: https://developer.ravelin.com
|
|
149
163
|
licenses:
|
150
164
|
- MIT
|
151
165
|
metadata: {}
|
152
|
-
post_install_message:
|
166
|
+
post_install_message:
|
153
167
|
rdoc_options: []
|
154
168
|
require_paths:
|
155
169
|
- lib
|
@@ -164,8 +178,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
164
178
|
- !ruby/object:Gem::Version
|
165
179
|
version: '0'
|
166
180
|
requirements: []
|
167
|
-
rubygems_version: 3.
|
168
|
-
signing_key:
|
181
|
+
rubygems_version: 3.0.9
|
182
|
+
signing_key:
|
169
183
|
specification_version: 4
|
170
184
|
summary: Ruby bindings for the Ravelin API
|
171
185
|
test_files: []
|