Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
41491c1
feature(api): add support for v2 endpoint
pibahamondesw Aug 28, 2025
96bbb89
feature(entity): Add entity resource
pibahamondesw Aug 28, 2025
9f09bf9
feature(entities): Add entities endpoints
pibahamondesw Aug 28, 2025
1133e61
feature(entity): Add refresh method to entity
pibahamondesw Aug 28, 2025
bcf090a
feature(entities): Add readme docs for entity
pibahamondesw Aug 28, 2025
11163b6
feature(client): Add post requests
pibahamondesw Aug 28, 2025
711d9f4
refactor(movements): Move existing accounts to movements namespace
pibahamondesw Aug 28, 2025
23685d5
refactor(entity): Move entities to Transfers folder
pibahamondesw Aug 28, 2025
8604d26
refactor(clients): Refactor Clients to have separate clients for Move…
pibahamondesw Aug 28, 2025
7ac18ef
refactor(balance): Move balance to Movements namespace
pibahamondesw Aug 28, 2025
0fc1f9a
refactor(institution): Move Institutions to Movements namespace
pibahamondesw Aug 28, 2025
83f3369
refactor(links): Move links to Movements namespace
pibahamondesw Aug 28, 2025
4e7fd8c
refactor(movements): Move movements to Movements namespace
pibahamondesw Aug 28, 2025
797ad99
refactor(transfer-accounts): Move TransferAccounts to Movements names…
pibahamondesw Aug 28, 2025
b0e8fc6
refactor(fintoc): Restrutcture entire folder structure to have better…
pibahamondesw Aug 28, 2025
0797291
refactor(transfers-client): Update spec to mock api response rather t…
pibahamondesw Aug 29, 2025
d7181f6
fix(movements-http-mocks): Move mocks to correct folder (and delete d…
pibahamondesw Aug 29, 2025
9ce4751
fix(movements): Fix movements comparison
pibahamondesw Aug 29, 2025
fed7f3a
feature(base-client): Add patch request method
pibahamondesw Aug 29, 2025
8572aaf
feature(accounts): Create transfers account resource
pibahamondesw Aug 29, 2025
8d4ad50
feature(accounts): Add accounts methods to Transfers client
pibahamondesw Aug 29, 2025
05ea1b9
refactor(client): Add comment to Fintoc::Client to make sure that the…
pibahamondesw Aug 29, 2025
4a48e07
refactor(entitities): Remove unnecessary entities array conversion
pibahamondesw Aug 29, 2025
9ece3dd
feature(accounts): Add refresh method to accounts
pibahamondesw Aug 29, 2025
4d3ab3e
feature(accounts): Add update method for accounts
pibahamondesw Aug 29, 2025
0a2446b
refactor(client): Add comment indicating that Client is only kept for…
pibahamondesw Aug 29, 2025
d56fcf2
refactor(accounts): Configure money-rails gem instead of custom forma…
pibahamondesw Aug 29, 2025
ebb922b
refactor(resources): Prefer explicit refreshing of resource values
pibahamondesw Aug 29, 2025
0531ad1
feature(account-numbers): Add account numbers transfer resource
pibahamondesw Sep 1, 2025
10a075a
feature(account-numbers): Add account numbers methods
pibahamondesw Sep 1, 2025
9735e0b
feature(account-number): Add refresh method to account numbers
pibahamondesw Sep 1, 2025
f890227
feature(account-numbers): Add update method to account numbers
pibahamondesw Sep 1, 2025
bd2e408
refactor(resources): Do not refresh using initialize as it returns a …
pibahamondesw Sep 1, 2025
a658fe2
feature(transfers): Add transfers resources
pibahamondesw Sep 1, 2025
8c4162c
feature(jws): Add JWS private key to request args for use of transfer…
pibahamondesw Sep 2, 2025
2759279
feature(transfers): Add transfers methods
pibahamondesw Sep 2, 2025
be96627
feature(transfers): Add refresh method to transfers
pibahamondesw Sep 2, 2025
8043793
feature(transfer): Add return_transfer method to transfer
pibahamondesw Sep 2, 2025
3cc388f
refactor(client/jws): Move jws condition to separate method
pibahamondesw Sep 3, 2025
908a652
feature(simulate): Implement simulate methods
pibahamondesw Sep 3, 2025
6870fdd
feature(account/simulate): Use simulate_receive_transfer as isntance …
pibahamondesw Sep 3, 2025
37a92f7
feature(account-number/simulate): Use simulate_receive_transfer as is…
pibahamondesw Sep 3, 2025
5342981
feature(simulate): Only allow simulating inbound transfers on test mode
pibahamondesw Sep 3, 2025
3d4824b
refactor(transfers-methods/spec): Better mocks for unit tests of methods
pibahamondesw Sep 3, 2025
fd1e5b4
feature(account-verifications): Add AccountVerification resource
pibahamondesw Sep 3, 2025
ab09474
feature(account-verifications): Add account verification methods
pibahamondesw Sep 4, 2025
d940e9a
feature(account-verifications): add refresh methods to account verifi…
pibahamondesw Sep 4, 2025
d92b874
refactor(transfers): Remove unnecessary inclusions of Utils
pibahamondesw Sep 4, 2025
d413acc
refactor(transfer/refresh-resources): Use ArgumentError for resfresh_…
pibahamondesw Sep 4, 2025
5f358ba
refactor(errors): Update errors url ref
pibahamondesw Sep 4, 2025
8d44fd5
feature(errors): Update list of possible errors
pibahamondesw Sep 4, 2025
b4796c1
feature(docs): Update readme docs to include new methods and changes …
pibahamondesw Sep 4, 2025
eae2332
refactor(client): Use managers instead of methods to access all api m…
pibahamondesw Sep 5, 2025
51f359f
fix(readme): Fix typo
pibahamondesw Sep 5, 2025
8bca17f
refactor(client): Prefer having v1/v2 clients instead of movements/tr…
pibahamondesw Sep 5, 2025
4b440cb
fix(readme): Fix readme client
pibahamondesw Sep 5, 2025
9b4a616
feat: add webhook signature module
dannyfuf Sep 5, 2025
940ac16
feat: add webhook signature error
dannyfuf Sep 5, 2025
bc67b4f
feat: include webhook signature module to fintoc
dannyfuf Sep 5, 2025
e6c780e
refactor(errors): Remove redundant to_s at Errors
pibahamondesw Sep 5, 2025
4c7ce5a
refactor(v1/accounts): Move Headers to frozen constant
pibahamondesw Sep 5, 2025
a42299b
fix(v1/link): Fix call to delete
pibahamondesw Sep 5, 2025
b4d1349
refactor(fintoc/version): Move version spec to better folder
pibahamondesw Sep 5, 2025
0595796
feature(spec): Increase spec coverage
pibahamondesw Sep 5, 2025
5fc4850
fix(transfers-manager): Fix mock of transfers return in spec
pibahamondesw Sep 5, 2025
0779de4
fix(base-client): Invert visible part and hidden part of key
pibahamondesw Sep 5, 2025
d5f0809
feature(account/spec): Add missing spec for update_balance method of …
pibahamondesw Sep 5, 2025
212d42a
feature(spec/link): Add missing spec for update_accounts of V1::Link
pibahamondesw Sep 5, 2025
c4838d8
feature(simplecov): Add simplecov gem
pibahamondesw Sep 5, 2025
77cae8d
feature(simplecov): Add simplecov config
pibahamondesw Sep 5, 2025
4227d6a
feature(ci/simplecov): Add coverage requirement to CI
pibahamondesw Sep 5, 2025
020960e
feature(version): Bump version to 1.0.0 and update changelog
pibahamondesw Sep 5, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,4 @@ jobs:
bundler-cache: true

- name: Run tests
run: bundle exec rspec
run: COVERAGE=true bundle exec rspec
43 changes: 38 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,45 @@
# Changelog

## 0.2.0 - 2025-08-26
## 1.0.0 - 2025-09-05

* Update linting rules and fix linting issues
* Update CI flow
* Update gems and support only Ruby versions that haven't reached EOL
* Update README
### 🚀 New Features

- **New Client Architecture**: Restructured client to distinguish between API versions
- Movements API now accessible via `Fintoc::V1::Client`
- Transfers API accessible via `Fintoc::V2::Client`
- Unified client interface with `Fintoc::Client` providing access to both versions
- Backward compatibility maintained for existing method signatures

- **V2 Client - Transfers API Implementation**: Partial implementation of Transfers API endpoints in `Fintoc::V2::Client`
- **Entities**: List and retrieve business entities
- **Transfer Accounts**: Create, read, update, and list transfer accounts
- **Account Numbers**: Manage account numbers/CLABEs
- **Transfers**: Create, retrieve, list, and return transfers
- **Simulation**: Simulate receiving transfers for testing
- **Account Verifications**: Verify account numbers
- **Movements**: TODO! Not yet implemented

### 🧪 Testing & Quality

- **100% Line Coverage**: Achieved full line coverage using SimpleCov gem, increasing the spec coverage and testing all new code.
- Configured with `minimum_coverage 100` and `minimum_coverage_by_file 100`
- Uses `simplecov_text_formatter` and `simplecov_linter_formatter` for reporting

- **Robust CI Pipeline**: Enhanced GitHub Actions workflow for comprehensive testing
- **Linting**: Dedicated RuboCop job for code quality enforcement
- **Multi-version Testing**: Tests against all currently supported Ruby versions (3.2, 3.3, and 3.4) for version compatibility
- **Coverage Integration**: Automated coverage reporting in CI pipeline

### Others

- **Money-Rails Integration**: Added `money-rails` gem for proper currency handling
- **Comprehensive README Update**: Extensively updated documentation with usage examples and development instructions
- **Improved Error Handling**: Better error management across API versions
- **JWS Support**: JSON Web Signature support for secure V2 API operations
- **HMac Signature verification**: Added the `Fintoc::WebhookSignature` class for easing webhook signature verification

## 0.1.0 - 2021-01-18

Initial version

* Up to date with the [2020-11-17](https://docs.fintoc.com/docs/api-changelog#2020-11-17) API version
26 changes: 17 additions & 9 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,20 @@ source 'https://rubygems.org'
gemspec

# Development dependencies
gem 'rexml' # Required for webmock in Ruby 3.0+
gem 'rspec', '~> 3.0'
gem 'rubocop', '~> 1.80'
gem 'rubocop-capybara', '~> 2.22', '>= 2.22.1'
gem 'rubocop-performance', '~> 1.25'
gem 'rubocop-rails', '~> 2.33', '>= 2.33.3'
gem 'rubocop-rspec', '~> 3.6'
gem 'vcr', '~> 6.3'
gem 'webmock'
group :development do
gem 'rubocop', '~> 1.80'
gem 'rubocop-capybara', '~> 2.22', '>= 2.22.1'
gem 'rubocop-performance', '~> 1.25'
gem 'rubocop-rails', '~> 2.33', '>= 2.33.3'
gem 'rubocop-rspec', '~> 3.6'
end

group :test do
gem 'rexml' # Required for webmock in Ruby 3.0+
gem 'rspec', '~> 3.0'
gem 'simplecov', '~> 0.21'
gem 'simplecov_linter_formatter'
gem 'simplecov_text_formatter'
gem 'vcr', '~> 6.3'
gem 'webmock'
end
112 changes: 106 additions & 6 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,13 +1,30 @@
PATH
remote: .
specs:
fintoc (0.2.0)
fintoc (1.0.0)
http
money-rails
tabulate

GEM
remote: https://rubygems.org/
specs:
actionpack (8.0.2.1)
actionview (= 8.0.2.1)
activesupport (= 8.0.2.1)
nokogiri (>= 1.8.5)
rack (>= 2.2.4)
rack-session (>= 1.0.1)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
useragent (~> 0.16)
actionview (8.0.2.1)
activesupport (= 8.0.2.1)
builder (~> 3.1)
erubi (~> 1.11)
rails-dom-testing (~> 2.2)
rails-html-sanitizer (~> 1.6)
activesupport (8.0.2.1)
base64
benchmark (>= 0.3)
Expand All @@ -27,22 +44,26 @@ GEM
base64 (0.3.0)
benchmark (0.4.1)
bigdecimal (3.2.2)
builder (3.3.0)
concurrent-ruby (1.3.5)
connection_pool (2.5.3)
crack (1.0.0)
bigdecimal
rexml
crass (1.0.6)
date (3.4.1)
diff-lcs (1.6.2)
docile (1.4.1)
domain_name (0.6.20240107)
drb (2.2.3)
erb (5.0.2)
erubi (1.13.1)
ffi (1.17.2)
ffi (1.17.2-aarch64-linux-gnu)
ffi (1.17.2-aarch64-linux-musl)
ffi (1.17.2-arm-linux-gnu)
ffi (1.17.2-arm-linux-musl)
ffi (1.17.2-arm64-darwin)
ffi (1.17.2-x86-linux-gnu)
ffi (1.17.2-x86-linux-musl)
ffi (1.17.2-x86_64-darwin)
ffi (1.17.2-x86_64-linux-gnu)
ffi (1.17.2-x86_64-linux-musl)
Expand All @@ -60,25 +81,91 @@ GEM
http-form_data (2.3.0)
i18n (1.14.7)
concurrent-ruby (~> 1.0)
io-console (0.8.1)
irb (1.15.2)
pp (>= 0.6.0)
rdoc (>= 4.0.0)
reline (>= 0.4.2)
json (2.13.2)
language_server-protocol (3.17.0.5)
lint_roller (1.1.0)
llhttp-ffi (0.5.1)
ffi-compiler (~> 1.0)
rake (~> 13.0)
logger (1.7.0)
loofah (2.24.1)
crass (~> 1.0.2)
nokogiri (>= 1.12.0)
minitest (5.25.5)
monetize (1.13.0)
money (~> 6.12)
money (6.19.0)
i18n (>= 0.6.4, <= 2)
money-rails (1.15.0)
activesupport (>= 3.0)
monetize (~> 1.9)
money (~> 6.13)
railties (>= 3.0)
nokogiri (1.18.9-aarch64-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-aarch64-linux-musl)
racc (~> 1.4)
nokogiri (1.18.9-arm-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-arm-linux-musl)
racc (~> 1.4)
nokogiri (1.18.9-arm64-darwin)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-darwin)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-linux-gnu)
racc (~> 1.4)
nokogiri (1.18.9-x86_64-linux-musl)
racc (~> 1.4)
parallel (1.27.0)
parser (3.3.9.0)
ast (~> 2.4.1)
racc
pp (0.6.2)
prettyprint
prettyprint (0.2.0)
prism (1.4.0)
psych (5.2.6)
date
stringio
public_suffix (6.0.2)
racc (1.8.1)
rack (3.2.0)
rack-session (2.1.1)
base64 (>= 0.1.0)
rack (>= 3.0.0)
rack-test (2.2.0)
rack (>= 1.3)
rackup (2.2.1)
rack (>= 3)
rails-dom-testing (2.3.0)
activesupport (>= 5.0.0)
minitest
nokogiri (>= 1.6)
rails-html-sanitizer (1.6.2)
loofah (~> 2.21)
nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0)
railties (8.0.2.1)
actionpack (= 8.0.2.1)
activesupport (= 8.0.2.1)
irb (~> 1.13)
rackup (>= 1.0.0)
rake (>= 12.2)
thor (~> 1.0, >= 1.2.2)
zeitwerk (~> 2.6)
rainbow (3.1.1)
rake (13.3.0)
rdoc (6.14.2)
erb
psych (>= 4.0.0)
regexp_parser (2.11.2)
reline (0.6.2)
io-console (~> 0.5)
rexml (3.4.2)
rspec (3.13.1)
rspec-core (~> 3.13.0)
Expand Down Expand Up @@ -125,29 +212,39 @@ GEM
rubocop (~> 1.72, >= 1.72.1)
ruby-progressbar (1.13.0)
securerandom (0.4.1)
simplecov (0.22.0)
docile (~> 1.1)
simplecov-html (~> 0.11)
simplecov_json_formatter (~> 0.1)
simplecov-html (0.13.2)
simplecov_json_formatter (0.1.4)
simplecov_linter_formatter (0.2.0)
rainbow
simplecov_text_formatter (0.1.0)
stringio (3.1.7)
tabulate (0.1.2)
thor (1.4.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unicode-display_width (3.1.5)
unicode-emoji (~> 4.0, >= 4.0.4)
unicode-emoji (4.0.4)
uri (1.0.3)
useragent (0.16.11)
vcr (6.3.1)
base64
webmock (3.25.1)
addressable (>= 2.8.0)
crack (>= 0.3.2)
hashdiff (>= 0.4.0, < 2.0.0)
zeitwerk (2.7.3)

PLATFORMS
aarch64-linux-gnu
aarch64-linux-musl
arm-linux-gnu
arm-linux-musl
arm64-darwin
ruby
x86-linux-gnu
x86-linux-musl
x86_64-darwin
x86_64-linux
x86_64-linux-gnu
Expand All @@ -162,6 +259,9 @@ DEPENDENCIES
rubocop-performance (~> 1.25)
rubocop-rails (~> 2.33, >= 2.33.3)
rubocop-rspec (~> 3.6)
simplecov (~> 0.21)
simplecov_linter_formatter
simplecov_text_formatter
vcr (~> 6.3)
webmock

Expand Down
Loading