finix 0.16 → 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -13
- data/.circleci/config.yml +22 -0
- data/.ruby-version +1 -1
- data/Gemfile +2 -10
- data/Rakefile +0 -16
- data/finix.gemspec +3 -12
- data/lib/finix.rb +5 -3
- data/lib/finix/hal_resource.rb +10 -3
- data/lib/finix/indifferent_hash.rb +16 -3
- data/lib/finix/pagination.rb +58 -24
- data/lib/finix/resources.rb +3 -0
- data/lib/finix/resources/fee_profile.rb +8 -0
- data/lib/finix/resources/hypermedia.rb +2 -2
- data/lib/finix/resources/merchant_profile.rb +8 -0
- data/lib/finix/resources/payment_instrument.rb +2 -2
- data/lib/finix/resources/resource.rb +14 -8
- data/lib/finix/resources/risk_profile.rb +8 -0
- data/lib/finix/resources/transfer.rb +4 -3
- data/lib/finix/resources/user.rb +3 -0
- data/lib/finix/version.rb +1 -1
- metadata +22 -61
- data/circle.yml +0 -32
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
MjAwOWU5OGM0MzA0ODBjZTQyY2Q5MTIxZWM5MzA5ZWZjZjU2ODI1ZA==
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: b2113c64b98a0f7729b214378351c869b439939316fb7434e68ae6fce4e37615
|
4
|
+
data.tar.gz: 4455191f1ff93fa1c75113b2a5f8bd06ef6398d29f38fd651244c744d63fb47d
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
YmNlNDkyYmNjYjBhMTQ3YWQ3NTkxMmY2NDBiZDIxNmNkMmI5YzZlMmIzNDdl
|
11
|
-
Y2RlM2NjN2EzNDBiNzg5NWViMjM0OTU1NDE3NDYwYTkxZDI5NTA=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
MDRhNGViY2QxNmViYTAxNmM1ZDc1ZTA0YWQ0NmM3YzhlNTY4OGVkYmRiNjU5
|
14
|
-
MTIyZTI5OTVkMTlmOGE0YWViZDU0NWNlYzJkMjY0ZTIyMThkYmMwOTliOTYx
|
15
|
-
NWJkZTYwY2VmZjVlNGFjZDM1MmRiZWU4OTQzNTU4YmIyNTdmZWU=
|
6
|
+
metadata.gz: d7cafefb9e31ce6e4d1df5dd354b1460f7516db83d1eccc0694fcc0eb963cc903112b0ef0b5d149bd30531b7a3764ae8271cb7af6dafb2a01aec9eb86124619c
|
7
|
+
data.tar.gz: 26c164b5dad922de5a1cf3c2d8dff27af487e54de2a34b9e4a13c14689f042e876bb2812a1bf26077c1d5fde3dd0b09fec38a7faca7ee7e5385718072f6d3733
|
@@ -0,0 +1,22 @@
|
|
1
|
+
version: 2.1
|
2
|
+
jobs:
|
3
|
+
rspec_tests:
|
4
|
+
working_directory: ~/workspace
|
5
|
+
docker:
|
6
|
+
- image: circleci/ruby:2.7
|
7
|
+
steps:
|
8
|
+
- checkout
|
9
|
+
- restore_cache:
|
10
|
+
keys:
|
11
|
+
- v1-dep-{{checksum "Gemfile.lock"}}
|
12
|
+
- run: 'bundle check --path=vendor/bundle || bundle install --path=vendor/bundle --jobs=4 --retry=3'
|
13
|
+
- save_cache:
|
14
|
+
key: v1-dep-{{checksum "Gemfile.lock"}}
|
15
|
+
paths:
|
16
|
+
- vendor/bundle
|
17
|
+
- ~/.bundle
|
18
|
+
- run: bundle exec rspec --format documentation
|
19
|
+
workflows:
|
20
|
+
test:
|
21
|
+
jobs:
|
22
|
+
- rspec_tests
|
data/.ruby-version
CHANGED
@@ -1 +1 @@
|
|
1
|
-
|
1
|
+
ruby-2.7
|
data/Gemfile
CHANGED
@@ -1,17 +1,9 @@
|
|
1
1
|
source 'https://rubygems.org'
|
2
2
|
|
3
|
-
gem 'rake', '~>
|
3
|
+
gem 'rake', '~> 13.0.1'
|
4
4
|
|
5
5
|
group :test do
|
6
|
-
gem 'minitest', '~> 5.10.1'
|
7
|
-
gem 'minitest-reporters', '~> 1.1.13'
|
8
|
-
gem 'vcr', '~> 3.0.3'
|
9
6
|
gem 'rspec', '~> 3.5.0'
|
10
|
-
gem 'dotenv', '~> 2.1.1'
|
11
|
-
|
12
|
-
if RUBY_VERSION >= '2.0'
|
13
|
-
gem 'byebug', '~> 9.0.6'
|
14
|
-
end
|
15
7
|
end
|
16
8
|
|
17
|
-
gemspec
|
9
|
+
gemspec
|
data/Rakefile
CHANGED
@@ -3,19 +3,3 @@ require 'bundler/gem_tasks'
|
|
3
3
|
require 'rake/testtask'
|
4
4
|
require 'rspec/core/rake_task'
|
5
5
|
require 'logger'
|
6
|
-
require_relative 'test/test_it'
|
7
|
-
require_relative 'test/helper_test'
|
8
|
-
|
9
|
-
desc 'Run test suite'
|
10
|
-
Rake::TestTask.new do |t|
|
11
|
-
Finix::FinixTest.logger = Logger.new STDOUT
|
12
|
-
Finix::FinixTest.logger.level = Logger::ERROR
|
13
|
-
t.pattern ='test/**/test_*.rb'
|
14
|
-
end
|
15
|
-
|
16
|
-
desc 'Run rspec suite'
|
17
|
-
RSpec::Core::RakeTask.new(:spec) do |t|
|
18
|
-
t.pattern = Dir.glob('spec/**/*_spec.rb')
|
19
|
-
end
|
20
|
-
|
21
|
-
task testit: [:test, :spec]
|
data/finix.gemspec
CHANGED
@@ -5,7 +5,7 @@ require 'finix/version'
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |spec|
|
7
7
|
spec.name = 'finix'
|
8
|
-
spec.required_ruby_version = '>=
|
8
|
+
spec.required_ruby_version = '>= 2.0'
|
9
9
|
spec.version = Finix::VERSION
|
10
10
|
spec.authors = ['finix-payments']
|
11
11
|
spec.email = ['support@finixpayments.com']
|
@@ -22,15 +22,6 @@ Gem::Specification.new do |spec|
|
|
22
22
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
23
23
|
spec.require_paths = ['lib']
|
24
24
|
|
25
|
-
spec.add_dependency('faraday', '~> 0.
|
26
|
-
spec.add_dependency('faraday_middleware', '~> 0.
|
27
|
-
|
28
|
-
if RUBY_VERSION >= '2.0'
|
29
|
-
spec.add_dependency('json', '~> 2.0.2')
|
30
|
-
spec.add_dependency('addressable', '~> 2.5.0')
|
31
|
-
else
|
32
|
-
spec.add_dependency('public_suffix', '~> 1.4.6')
|
33
|
-
spec.add_dependency('json', '~> 1.8')
|
34
|
-
spec.add_dependency('addressable', '~> 2.3')
|
35
|
-
end
|
25
|
+
spec.add_dependency('faraday', '~> 1.0.1')
|
26
|
+
spec.add_dependency('faraday_middleware', '~> 1.0.0')
|
36
27
|
end
|
data/lib/finix.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
require_relative 'finix/version' unless defined? Finix::VERSION
|
2
|
-
require_relative
|
3
|
-
require_relative
|
2
|
+
require_relative 'finix/client'
|
3
|
+
require_relative 'finix/errors'
|
4
4
|
|
5
5
|
module Finix
|
6
6
|
|
@@ -43,7 +43,8 @@ module Finix
|
|
43
43
|
end
|
44
44
|
|
45
45
|
def get_href(cls)
|
46
|
-
href = hypermedia_registry.key(cls)
|
46
|
+
href = (not cls.nil? and not cls.hypermedia_types.nil?) ? cls.hypermedia_types.last : hypermedia_registry.key(cls)
|
47
|
+
|
47
48
|
sps = cls
|
48
49
|
while href.nil?
|
49
50
|
sps = sps.superclass
|
@@ -65,6 +66,7 @@ module Finix
|
|
65
66
|
|
66
67
|
def find_resource_cls(resource, attributes={})
|
67
68
|
cls = hypermedia_registry[resource]
|
69
|
+
# cls = hypermedia_registry["__stub__#{resource}"] if cls.nil?
|
68
70
|
cls = cls.send :hypermedia_subtype, attributes if not cls.nil? and cls.respond_to?(:hypermedia_subtype)
|
69
71
|
cls
|
70
72
|
end
|
data/lib/finix/hal_resource.rb
CHANGED
@@ -5,7 +5,9 @@ module Finix
|
|
5
5
|
attr_accessor :attributes
|
6
6
|
|
7
7
|
def method_missing(method, *args, &block)
|
8
|
-
|
8
|
+
attributes = [@attributes]
|
9
|
+
attributes << @attributes['page'] unless @attributes['page'].nil?
|
10
|
+
attributes.each do |attrs|
|
9
11
|
if attrs.has_key?(method.to_s)
|
10
12
|
return attrs[method.to_s]
|
11
13
|
end
|
@@ -28,11 +30,13 @@ module Finix
|
|
28
30
|
def load_page_from_response!(response)
|
29
31
|
body = Finix::Utils.indifferent_read_access response.body
|
30
32
|
|
31
|
-
|
33
|
+
hash_class = Finix::Utils.eval_class(self, IndifferentHash)
|
34
|
+
@hyperlinks = hash_class.new
|
32
35
|
links = body.delete('_links')
|
33
36
|
links.each { |key, link| @hyperlinks[key.to_sym] = link[:href] } unless links.nil?
|
34
37
|
|
35
|
-
|
38
|
+
page = body.delete('page')
|
39
|
+
@attributes = {'items' => [], 'page' => hash_class.new(page)} # clear attributes
|
36
40
|
if body.has_key? '_embedded'
|
37
41
|
resource_name, resources = body.delete('_embedded').first
|
38
42
|
@resource_class = Finix.from_hypermedia_registry resource_name
|
@@ -41,6 +45,9 @@ module Finix
|
|
41
45
|
cls.construct_from_response attrs
|
42
46
|
end
|
43
47
|
end
|
48
|
+
|
49
|
+
@attributes.merge! body
|
44
50
|
end
|
45
51
|
end
|
46
52
|
end
|
53
|
+
|
@@ -1,12 +1,25 @@
|
|
1
1
|
module Finix
|
2
2
|
class IndifferentHash < ::Hash
|
3
|
+
|
4
|
+
def initialize(*args)
|
5
|
+
original_hash = args.slice!(0) || {}
|
6
|
+
self.merge!(original_hash)
|
7
|
+
end
|
8
|
+
|
3
9
|
def method_missing(method, *args, &block)
|
4
10
|
if self.has_key? "#{method}"
|
5
11
|
value = self["#{method}"]
|
6
|
-
|
7
|
-
|
8
|
-
|
12
|
+
return value.call(*args) if value.respond_to? :call
|
13
|
+
return value
|
14
|
+
end
|
15
|
+
end
|
16
|
+
|
17
|
+
def count(*args)
|
18
|
+
if self.has_key? 'count'
|
19
|
+
raise Exception.new 'Unsupported block_given exception' if block_given?
|
20
|
+
return self.send :method_missing, :count, *args
|
9
21
|
end
|
22
|
+
super(*args)
|
10
23
|
end
|
11
24
|
end
|
12
25
|
end
|
data/lib/finix/pagination.rb
CHANGED
@@ -32,7 +32,7 @@ module Finix
|
|
32
32
|
|
33
33
|
def each
|
34
34
|
return enum_for :each unless block_given?
|
35
|
-
|
35
|
+
fetch :first
|
36
36
|
loop do
|
37
37
|
items.each { |item| yield item }
|
38
38
|
fetch :next
|
@@ -41,8 +41,10 @@ module Finix
|
|
41
41
|
|
42
42
|
def count(*args)
|
43
43
|
refresh # always refresh to get last items
|
44
|
-
|
45
|
-
self.send
|
44
|
+
|
45
|
+
cnt = (block_given?) ? super(*args) : self.send(:method_missing, :count, args)
|
46
|
+
cnt = 0 if cnt.nil?
|
47
|
+
cnt
|
46
48
|
end
|
47
49
|
|
48
50
|
def fetch(scope = nil) # :next, :last, :first, :prev, :self
|
@@ -54,8 +56,18 @@ module Finix
|
|
54
56
|
|
55
57
|
scope = :self if scope.nil?
|
56
58
|
scope = scope.to_s.to_sym unless scope.nil?
|
57
|
-
|
58
|
-
|
59
|
+
|
60
|
+
href = @hyperlinks[scope]
|
61
|
+
unless href
|
62
|
+
if scope == :first
|
63
|
+
@attributes['page']['offset'] = 0 unless @attributes['page']['offset'].nil?
|
64
|
+
href = @hyperlinks[:self]
|
65
|
+
href = href[/[^\?]+/]
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
if href
|
70
|
+
load_from href, opts
|
59
71
|
return self.items
|
60
72
|
end
|
61
73
|
|
@@ -69,6 +81,9 @@ module Finix
|
|
69
81
|
self
|
70
82
|
end
|
71
83
|
|
84
|
+
alias load! refresh
|
85
|
+
alias retrieve refresh
|
86
|
+
|
72
87
|
def create(attrs={})
|
73
88
|
attrs = attrs.attributes if attrs.is_a?(Resource)
|
74
89
|
attrs = Finix::Utils.indifferent_read_access attrs
|
@@ -80,13 +95,47 @@ module Finix
|
|
80
95
|
@resource_class.new(attrs).save
|
81
96
|
end
|
82
97
|
|
83
|
-
|
98
|
+
def next_page
|
99
|
+
fetch :next
|
100
|
+
self
|
101
|
+
end
|
102
|
+
|
103
|
+
def previous_page
|
104
|
+
fetch :prev
|
105
|
+
self
|
106
|
+
end
|
84
107
|
|
85
|
-
def
|
86
|
-
|
87
|
-
|
108
|
+
def last_page
|
109
|
+
fetch :last
|
110
|
+
self
|
88
111
|
end
|
89
112
|
|
113
|
+
def first_page
|
114
|
+
fetch :first
|
115
|
+
self
|
116
|
+
end
|
117
|
+
|
118
|
+
def total
|
119
|
+
# refresh unless loaded
|
120
|
+
self.page.count
|
121
|
+
end
|
122
|
+
|
123
|
+
def num_pages
|
124
|
+
num = total / limit
|
125
|
+
num += 1 if total % limit > 0
|
126
|
+
num
|
127
|
+
end
|
128
|
+
|
129
|
+
def loaded
|
130
|
+
not self.items.nil?
|
131
|
+
end
|
132
|
+
|
133
|
+
private
|
134
|
+
|
135
|
+
# def current_page
|
136
|
+
# (offset / limit) + 1
|
137
|
+
# end
|
138
|
+
|
90
139
|
def extract_opts(opts={})
|
91
140
|
opts = Finix::Utils.indifferent_read_access opts
|
92
141
|
limit = opts.delete('limit')
|
@@ -125,21 +174,6 @@ module Finix
|
|
125
174
|
|
126
175
|
response = Finix.get parsed_url.to_s, params
|
127
176
|
load_page_from_response! response
|
128
|
-
# body = Finix::Utils.indifferent_read_access response.body
|
129
|
-
#
|
130
|
-
# @hyperlinks = Finix::Utils.eval_class(self, IndifferentHash).new
|
131
|
-
# links = body.delete('_links')
|
132
|
-
# links.each { |key, link| @hyperlinks[key.to_sym] = link[:href] }
|
133
|
-
#
|
134
|
-
# @attributes = {'items' => [], 'page' => body.delete('page')} # clear attributes
|
135
|
-
# if body.has_key? '_embedded'
|
136
|
-
# resource_name, resources = body.delete('_embedded').first
|
137
|
-
# @resource_class = Finix.from_hypermedia_registry resource_name
|
138
|
-
# @attributes['items'] = resources.map do |attrs|
|
139
|
-
# cls = Finix.from_hypermedia_registry resource_name, attrs
|
140
|
-
# cls.construct_from_response attrs
|
141
|
-
# end
|
142
|
-
# end
|
143
177
|
end
|
144
178
|
|
145
179
|
# Stolen from Mongrel, with some small modifications:
|
data/lib/finix/resources.rb
CHANGED
@@ -8,6 +8,9 @@ require 'finix/resources/identity'
|
|
8
8
|
require 'finix/resources/processor'
|
9
9
|
require 'finix/resources/token'
|
10
10
|
require 'finix/resources/merchant'
|
11
|
+
require 'finix/resources/merchant_profile'
|
12
|
+
require 'finix/resources/risk_profile'
|
13
|
+
require 'finix/resources/fee_profile'
|
11
14
|
require 'finix/resources/payment_instrument'
|
12
15
|
require 'finix/resources/payment_card'
|
13
16
|
require 'finix/resources/bank_account'
|
@@ -11,7 +11,7 @@ module Finix
|
|
11
11
|
def define_hypermedia_types(types)
|
12
12
|
@hypermedia_types = types.map! do |t|
|
13
13
|
t.to_s
|
14
|
-
end.sort
|
14
|
+
end.sort!
|
15
15
|
|
16
16
|
@hypermedia_types.each do |type|
|
17
17
|
Finix.hypermedia_registry[type] = self
|
@@ -23,4 +23,4 @@ module Finix
|
|
23
23
|
|
24
24
|
end
|
25
25
|
|
26
|
-
end
|
26
|
+
end
|
@@ -11,9 +11,9 @@ module Finix
|
|
11
11
|
unless response.nil?
|
12
12
|
type = response['instrument_type'] || response['type']
|
13
13
|
if type == 'PAYMENT_CARD'
|
14
|
-
name = self.name.sub
|
14
|
+
name = self.name.sub 'PaymentInstrument', 'PaymentCard'
|
15
15
|
elsif type == 'BANK_ACCOUNT'
|
16
|
-
name = self.name.sub
|
16
|
+
name = self.name.sub 'PaymentInstrument', 'BankAccount'
|
17
17
|
end
|
18
18
|
return self.instance_eval name unless name.nil?
|
19
19
|
end
|
@@ -1,14 +1,10 @@
|
|
1
|
-
require 'addressable/template'
|
2
|
-
|
3
1
|
require_relative '../utils'
|
4
2
|
require_relative '../hal_resource'
|
5
3
|
require_relative '../pagination'
|
6
4
|
require_relative '../indifferent_hash'
|
7
5
|
|
8
6
|
module Finix
|
9
|
-
|
10
7
|
module Resource
|
11
|
-
|
12
8
|
include HalResource
|
13
9
|
|
14
10
|
def initialize(*args)
|
@@ -117,7 +113,8 @@ module Finix
|
|
117
113
|
|
118
114
|
def fetch(*arguments)
|
119
115
|
if arguments.nil? or arguments.empty? or arguments[0].nil? or arguments[0].to_s.empty?
|
120
|
-
href = Finix.
|
116
|
+
href = Finix.get_href self
|
117
|
+
# href = Finix.hypermedia_registry.key(self)
|
121
118
|
return Finix::Utils.eval_class(self, Pagination).new :href => href
|
122
119
|
end
|
123
120
|
|
@@ -140,15 +137,24 @@ module Finix
|
|
140
137
|
end
|
141
138
|
|
142
139
|
def pagination(*args)
|
143
|
-
href = Finix.
|
140
|
+
href = Finix.get_href self
|
141
|
+
# href = Finix.hypermedia_registry.key(self)
|
144
142
|
opts = args.slice!(0) || {}
|
145
143
|
opts[:href] = href
|
146
144
|
Finix::Utils.eval_class(self, Pagination).new opts
|
147
145
|
end
|
148
146
|
|
149
147
|
alias find fetch
|
150
|
-
alias retrieve fetch
|
151
|
-
end
|
152
148
|
|
149
|
+
def retrieve(*args)
|
150
|
+
pager_or_resource = fetch *args
|
151
|
+
|
152
|
+
if pager_or_resource.is_a? Pagination
|
153
|
+
pager_or_resource.load! unless pager_or_resource.loaded
|
154
|
+
end
|
155
|
+
|
156
|
+
pager_or_resource
|
157
|
+
end
|
158
|
+
end
|
153
159
|
end
|
154
160
|
end
|
@@ -3,10 +3,11 @@ module Finix
|
|
3
3
|
include Finix::Resource
|
4
4
|
include Finix::HypermediaRegistry
|
5
5
|
|
6
|
-
define_hypermedia_types [:transfers]
|
6
|
+
define_hypermedia_types [:transfers, :funding_transfers, :fees]
|
7
7
|
|
8
|
-
def reverse(
|
9
|
-
|
8
|
+
def reverse(args=0)
|
9
|
+
atts = args.is_a?(Hash) ? {}.merge(args) : {:refund_amount => args}
|
10
|
+
self.reversals.create atts
|
10
11
|
end
|
11
12
|
end
|
12
13
|
end
|
data/lib/finix/resources/user.rb
CHANGED
data/lib/finix/version.rb
CHANGED
metadata
CHANGED
@@ -1,85 +1,43 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: finix
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- finix-payments
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-10-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - ~>
|
17
|
+
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 1.0.1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - ~>
|
24
|
+
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.
|
26
|
+
version: 1.0.1
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: faraday_middleware
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - ~>
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.
|
33
|
+
version: 1.0.0
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - ~>
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 0.
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: public_suffix
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - ~>
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: 1.4.6
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - ~>
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: 1.4.6
|
55
|
-
- !ruby/object:Gem::Dependency
|
56
|
-
name: json
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
58
|
-
requirements:
|
59
|
-
- - ~>
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
version: '1.8'
|
62
|
-
type: :runtime
|
63
|
-
prerelease: false
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
65
|
-
requirements:
|
66
|
-
- - ~>
|
67
|
-
- !ruby/object:Gem::Version
|
68
|
-
version: '1.8'
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: addressable
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
72
|
-
requirements:
|
73
|
-
- - ~>
|
74
|
-
- !ruby/object:Gem::Version
|
75
|
-
version: '2.3'
|
76
|
-
type: :runtime
|
77
|
-
prerelease: false
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
79
|
-
requirements:
|
80
|
-
- - ~>
|
81
|
-
- !ruby/object:Gem::Version
|
82
|
-
version: '2.3'
|
40
|
+
version: 1.0.0
|
83
41
|
description: Finix Ruby Client
|
84
42
|
email:
|
85
43
|
- support@finixpayments.com
|
@@ -87,15 +45,15 @@ executables: []
|
|
87
45
|
extensions: []
|
88
46
|
extra_rdoc_files: []
|
89
47
|
files:
|
90
|
-
- .
|
91
|
-
- .
|
92
|
-
- .
|
93
|
-
- .ruby-
|
48
|
+
- ".circleci/config.yml"
|
49
|
+
- ".gitignore"
|
50
|
+
- ".rspec"
|
51
|
+
- ".ruby-gemset"
|
52
|
+
- ".ruby-version"
|
94
53
|
- Gemfile
|
95
54
|
- LICENSE.txt
|
96
55
|
- README.md
|
97
56
|
- Rakefile
|
98
|
-
- circle.yml
|
99
57
|
- finix.gemspec
|
100
58
|
- lib/finix.rb
|
101
59
|
- lib/finix/client.rb
|
@@ -110,14 +68,17 @@ files:
|
|
110
68
|
- lib/finix/resources/dispute.rb
|
111
69
|
- lib/finix/resources/error.rb
|
112
70
|
- lib/finix/resources/evidence.rb
|
71
|
+
- lib/finix/resources/fee_profile.rb
|
113
72
|
- lib/finix/resources/hypermedia.rb
|
114
73
|
- lib/finix/resources/identity.rb
|
115
74
|
- lib/finix/resources/merchant.rb
|
75
|
+
- lib/finix/resources/merchant_profile.rb
|
116
76
|
- lib/finix/resources/payment_card.rb
|
117
77
|
- lib/finix/resources/payment_instrument.rb
|
118
78
|
- lib/finix/resources/processor.rb
|
119
79
|
- lib/finix/resources/refund.rb
|
120
80
|
- lib/finix/resources/resource.rb
|
81
|
+
- lib/finix/resources/risk_profile.rb
|
121
82
|
- lib/finix/resources/settlement.rb
|
122
83
|
- lib/finix/resources/token.rb
|
123
84
|
- lib/finix/resources/transfer.rb
|
@@ -139,17 +100,17 @@ require_paths:
|
|
139
100
|
- lib
|
140
101
|
required_ruby_version: !ruby/object:Gem::Requirement
|
141
102
|
requirements:
|
142
|
-
- -
|
103
|
+
- - ">="
|
143
104
|
- !ruby/object:Gem::Version
|
144
|
-
version: '
|
105
|
+
version: '2.0'
|
145
106
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
146
107
|
requirements:
|
147
|
-
- -
|
108
|
+
- - ">="
|
148
109
|
- !ruby/object:Gem::Version
|
149
110
|
version: '0'
|
150
111
|
requirements: []
|
151
112
|
rubyforge_project:
|
152
|
-
rubygems_version: 2.
|
113
|
+
rubygems_version: 2.7.10
|
153
114
|
signing_key:
|
154
115
|
specification_version: 4
|
155
116
|
summary: Finix Ruby Client
|
data/circle.yml
DELETED
@@ -1,32 +0,0 @@
|
|
1
|
-
machine:
|
2
|
-
ruby:
|
3
|
-
version: 1.9.3
|
4
|
-
|
5
|
-
environment:
|
6
|
-
RUBY_VERSIONS: 1.9.3,2.0.0,2.1.10,2.2.5,2.2.6,2.3.1,2.3.3,2.4.0
|
7
|
-
PROCESSING_URL: https://api-staging.finix.io/
|
8
|
-
|
9
|
-
dependencies:
|
10
|
-
override:
|
11
|
-
- rvm get head
|
12
|
-
- rvm install $RUBY_VERSIONS
|
13
|
-
- rvm $RUBY_VERSIONS --verbose do gem install bundler
|
14
|
-
- rvm $RUBY_VERSIONS --verbose do bundle install
|
15
|
-
|
16
|
-
test:
|
17
|
-
override:
|
18
|
-
- rvm $RUBY_VERSIONS --verbose do bundle exec rake testit
|
19
|
-
|
20
|
-
post:
|
21
|
-
- cp -Rf .report/ $CIRCLE_ARTIFACTS
|
22
|
-
|
23
|
-
deployment:
|
24
|
-
release:
|
25
|
-
tag: /v[0-9]+(\.[0-9]+)*/
|
26
|
-
owner: finix-payments
|
27
|
-
commands:
|
28
|
-
- |
|
29
|
-
curl -u ${rubygems_user}:${rubygems_password} https://rubygems.org/api/v1/api_key.yaml > ~/.gem/credentials
|
30
|
-
- chmod 0600 ~/.gem/credentials
|
31
|
-
- gem build *.gemspec
|
32
|
-
- gem push *.gem
|