masspay_ruby_sdk 1.0.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.
Files changed (119) hide show
  1. checksums.yaml +7 -0
  2. data/CHANGELOG.md +8 -0
  3. data/CONTRIBUTING.md +13 -0
  4. data/Gemfile +9 -0
  5. data/README.md +197 -0
  6. data/Rakefile +10 -0
  7. data/docs/AccountApi.md +150 -0
  8. data/docs/ApiResponse.md +22 -0
  9. data/docs/AttrTxn.md +20 -0
  10. data/docs/AttrValue.md +20 -0
  11. data/docs/AttrVelocityRequestInner.md +20 -0
  12. data/docs/AttributeApi.md +168 -0
  13. data/docs/AttrsRequirement.md +36 -0
  14. data/docs/AutopayResp.md +22 -0
  15. data/docs/AutopayRule.md +20 -0
  16. data/docs/AvailableBalanceTxnResp.md +22 -0
  17. data/docs/CardApi.md +160 -0
  18. data/docs/CatalogApi.md +469 -0
  19. data/docs/CompaniesResp.md +18 -0
  20. data/docs/Company.md +26 -0
  21. data/docs/Country.md +22 -0
  22. data/docs/Exception.md +20 -0
  23. data/docs/FoundUser.md +24 -0
  24. data/docs/GetAccountStatement200Response.md +18 -0
  25. data/docs/GetTransactionConfirmationDetails200Response.md +18 -0
  26. data/docs/GetUserAgreement200Response.md +26 -0
  27. data/docs/GetUserAgreementsNames200ResponseInner.md +24 -0
  28. data/docs/GetUserUserTokenKycAu10tix200Response.md +18 -0
  29. data/docs/GetUserUserTokenKycVeriff200Response.md +18 -0
  30. data/docs/GetWalletCardInfo200Response.md +30 -0
  31. data/docs/IDUpload.md +20 -0
  32. data/docs/KYCApi.md +305 -0
  33. data/docs/LoadApi.md +621 -0
  34. data/docs/LoadTxn.md +32 -0
  35. data/docs/LoadTxnResp.md +20 -0
  36. data/docs/Loads.md +36 -0
  37. data/docs/PayoutApi.md +403 -0
  38. data/docs/PayoutTxn.md +36 -0
  39. data/docs/PayoutTxnCommitResp.md +24 -0
  40. data/docs/PayoutTxnResp.md +60 -0
  41. data/docs/ResendBalanceNotification200Response.md +18 -0
  42. data/docs/Service.md +22 -0
  43. data/docs/ServicePayersInner.md +38 -0
  44. data/docs/ServicePayersInnerExchangeRateInner.md +20 -0
  45. data/docs/SpendBackApi.md +161 -0
  46. data/docs/SpendBackTxn.md +28 -0
  47. data/docs/SpendBackTxnResp.md +22 -0
  48. data/docs/SpendBacks.md +34 -0
  49. data/docs/StoredUser.md +56 -0
  50. data/docs/TaxApi.md +81 -0
  51. data/docs/TaxYearUserResp.md +48 -0
  52. data/docs/TxnHistoryResp.md +52 -0
  53. data/docs/UpdateUser.md +52 -0
  54. data/docs/User.md +50 -0
  55. data/docs/UserApi.md +403 -0
  56. data/docs/WalletApi.md +463 -0
  57. data/docs/WalletTxnResp.md +34 -0
  58. data/docs/logo.webp +0 -0
  59. data/lib/masspay_ruby_sdk/api/account_api.rb +149 -0
  60. data/lib/masspay_ruby_sdk/api/attribute_api.rb +214 -0
  61. data/lib/masspay_ruby_sdk/api/card_api.rb +174 -0
  62. data/lib/masspay_ruby_sdk/api/catalog_api.rb +443 -0
  63. data/lib/masspay_ruby_sdk/api/kyc_api.rb +290 -0
  64. data/lib/masspay_ruby_sdk/api/load_api.rb +598 -0
  65. data/lib/masspay_ruby_sdk/api/payout_api.rb +397 -0
  66. data/lib/masspay_ruby_sdk/api/spend_back_api.rb +160 -0
  67. data/lib/masspay_ruby_sdk/api/tax_api.rb +82 -0
  68. data/lib/masspay_ruby_sdk/api/user_api.rb +418 -0
  69. data/lib/masspay_ruby_sdk/api/wallet_api.rb +461 -0
  70. data/lib/masspay_ruby_sdk/api_client.rb +391 -0
  71. data/lib/masspay_ruby_sdk/api_error.rb +57 -0
  72. data/lib/masspay_ruby_sdk/configuration.rb +315 -0
  73. data/lib/masspay_ruby_sdk/models/api_response.rb +236 -0
  74. data/lib/masspay_ruby_sdk/models/attr_txn.rb +235 -0
  75. data/lib/masspay_ruby_sdk/models/attr_value.rb +239 -0
  76. data/lib/masspay_ruby_sdk/models/attr_velocity_request_inner.rb +273 -0
  77. data/lib/masspay_ruby_sdk/models/attrs_requirement.rb +372 -0
  78. data/lib/masspay_ruby_sdk/models/autopay_resp.rb +256 -0
  79. data/lib/masspay_ruby_sdk/models/autopay_rule.rb +241 -0
  80. data/lib/masspay_ruby_sdk/models/available_balance_txn_resp.rb +254 -0
  81. data/lib/masspay_ruby_sdk/models/companies_resp.rb +225 -0
  82. data/lib/masspay_ruby_sdk/models/company.rb +285 -0
  83. data/lib/masspay_ruby_sdk/models/country.rb +296 -0
  84. data/lib/masspay_ruby_sdk/models/exception.rb +241 -0
  85. data/lib/masspay_ruby_sdk/models/found_user.rb +270 -0
  86. data/lib/masspay_ruby_sdk/models/get_account_statement200_response.rb +225 -0
  87. data/lib/masspay_ruby_sdk/models/get_transaction_confirmation_details200_response.rb +218 -0
  88. data/lib/masspay_ruby_sdk/models/get_user_agreement200_response.rb +280 -0
  89. data/lib/masspay_ruby_sdk/models/get_user_agreements_names200_response_inner.rb +270 -0
  90. data/lib/masspay_ruby_sdk/models/get_user_user_token_kyc_au10tix200_response.rb +224 -0
  91. data/lib/masspay_ruby_sdk/models/get_user_user_token_kyc_veriff200_response.rb +224 -0
  92. data/lib/masspay_ruby_sdk/models/get_wallet_card_info200_response.rb +460 -0
  93. data/lib/masspay_ruby_sdk/models/id_upload.rb +273 -0
  94. data/lib/masspay_ruby_sdk/models/load_txn.rb +321 -0
  95. data/lib/masspay_ruby_sdk/models/load_txn_resp.rb +273 -0
  96. data/lib/masspay_ruby_sdk/models/loads.rb +388 -0
  97. data/lib/masspay_ruby_sdk/models/payout_txn.rb +328 -0
  98. data/lib/masspay_ruby_sdk/models/payout_txn_commit_resp.rb +293 -0
  99. data/lib/masspay_ruby_sdk/models/payout_txn_resp.rb +613 -0
  100. data/lib/masspay_ruby_sdk/models/resend_balance_notification200_response.rb +225 -0
  101. data/lib/masspay_ruby_sdk/models/service.rb +318 -0
  102. data/lib/masspay_ruby_sdk/models/service_payers_inner.rb +373 -0
  103. data/lib/masspay_ruby_sdk/models/service_payers_inner_exchange_rate_inner.rb +239 -0
  104. data/lib/masspay_ruby_sdk/models/spend_back_txn.rb +325 -0
  105. data/lib/masspay_ruby_sdk/models/spend_back_txn_resp.rb +307 -0
  106. data/lib/masspay_ruby_sdk/models/spend_backs.rb +340 -0
  107. data/lib/masspay_ruby_sdk/models/stored_user.rb +500 -0
  108. data/lib/masspay_ruby_sdk/models/tax_year_user_resp.rb +388 -0
  109. data/lib/masspay_ruby_sdk/models/txn_history_resp.rb +571 -0
  110. data/lib/masspay_ruby_sdk/models/update_user.rb +490 -0
  111. data/lib/masspay_ruby_sdk/models/user.rb +423 -0
  112. data/lib/masspay_ruby_sdk/models/wallet_txn_resp.rb +375 -0
  113. data/lib/masspay_ruby_sdk/version.rb +14 -0
  114. data/lib/masspay_ruby_sdk.rb +89 -0
  115. data/masspay_ruby_sdk.gemspec +37 -0
  116. data/spec/api_client_spec.rb +227 -0
  117. data/spec/configuration_spec.rb +41 -0
  118. data/spec/spec_helper.rb +110 -0
  119. metadata +203 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: b6a9546ea765d92fd6152037cafacd6126ed8a13867fea49bed5f19a6c18d614
4
+ data.tar.gz: 8c843b6d6bbbff4d53486f9173f1f26fefe42569742077d8b91c3bb63c218f28
5
+ SHA512:
6
+ metadata.gz: aa9b2ad6093a093a6cdc8f0072a058b1017cde4a7416e1e5a29b0a75d4aabf78b22300c1cc08b3687d6af4b29793fda6ccf9a9aa9d723fccd388ff932c56c44b
7
+ data.tar.gz: 90c7318ec73feaa01bd585b9681f1037d911470ad256838415415540dd10daaaf331b3717ed7cb97f18e2d2403592fa7d98e49d1e1c08b16a9fbc723422616e0
data/CHANGELOG.md ADDED
@@ -0,0 +1,8 @@
1
+ # Changelog
2
+
3
+ ## 1.0.0 (2023-11-15)
4
+
5
+
6
+ ### Features
7
+
8
+ * update SDK according to newest OAS ([84af46c](https://github.com/masspayio/masspay-ruby-sdk/commit/84af46ca1fcf247048e50f6df170cd86f4594184))
data/CONTRIBUTING.md ADDED
@@ -0,0 +1,13 @@
1
+ # Contributing
2
+
3
+ ## Release new version
4
+
5
+ All commit messages have to be in the format of the [conventionalcommits.org](https://conventionalcommits.org) specification.
6
+
7
+ 1. Make sure your are on the `main` branch.
8
+ 2. Make sure you have committed everything and your code is working.
9
+ 3. Run `npx standard-version`
10
+ 4. Push your changes to the repository and the `main` branch.
11
+ 5. The Github Action will automatically release a new version to rubygems.org (https://rubygems.org/gems/masspay_ruby_sdk).
12
+
13
+ For more detailed instructions read [standard-version documentation](https://github.com/conventional-changelog/standard-version).
data/Gemfile ADDED
@@ -0,0 +1,9 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gemspec
4
+
5
+ group :development, :test do
6
+ gem 'rake', '~> 13.0.1'
7
+ gem 'pry-byebug'
8
+ gem 'rubocop', '~> 0.66.0'
9
+ end
data/README.md ADDED
@@ -0,0 +1,197 @@
1
+ <img src="./docs/logo.webp" width="200" />
2
+
3
+ # masspay_ruby_sdk ![Gem](https://img.shields.io/gem/v/masspay_ruby_sdk) ![Ruby](https://img.shields.io/badge/ruby->=%202.7-blue)
4
+
5
+ MassPayRubySdk - the Ruby gem for the MassPay API
6
+
7
+ MassPay API
8
+
9
+ - API version: 0.1.4
10
+ - Package version: 1.0.0
11
+
12
+ For more information, please visit [https://www.masspay.io](https://www.masspay.io)
13
+
14
+ ## Installation
15
+
16
+ ### Bundler
17
+
18
+ ```shell
19
+ bundle add masspay_ruby_sdk
20
+ ```
21
+
22
+ ### Global Installation
23
+
24
+ ```shell
25
+ gem install masspay_ruby_sdk
26
+ ```
27
+
28
+ ## Getting Started
29
+
30
+ Please follow the [installation](#installation) procedure and then run the following code:
31
+
32
+ ### Ruby
33
+
34
+ ```ruby
35
+ # Load the gem
36
+ require 'masspay_ruby_sdk'
37
+
38
+ # Setup authorization
39
+ MassPayRubySdk.configure do |config|
40
+ # Configure API key authorization: AUTHORIZER_NAME
41
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
42
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
43
+ config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
44
+ end
45
+
46
+ api_instance = MassPayRubySdk::AccountApi.new
47
+
48
+ begin
49
+ #Get current available balance
50
+ result = api_instance.get_account_balance
51
+ p result
52
+ rescue MassPayRubySdk::ApiError => e
53
+ puts "Exception when calling AccountApi->get_account_balance: #{e}"
54
+ end
55
+
56
+ ```
57
+
58
+ ### Rails
59
+
60
+ Create a file `config/initializers/masspay_ruby_sdk.rb` with the following content:
61
+
62
+ ```ruby
63
+
64
+ # Setup authorization
65
+ MassPayRubySdk.configure do |config|
66
+ # Configure API key authorization: AUTHORIZER_NAME
67
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
68
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
69
+ config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
70
+ end
71
+ ```
72
+
73
+ Then call the API:
74
+
75
+ ```ruby
76
+ api_instance = MassPayRubySdk::AccountApi.new
77
+
78
+ begin
79
+ #Get current available balance
80
+ result = api_instance.get_account_balance
81
+ p result
82
+ rescue MassPayRubySdk::ApiError => e
83
+ puts "Exception when calling AccountApi->get_account_balance: #{e}"
84
+ end
85
+
86
+ ```
87
+
88
+ ## Documentation for API Endpoints
89
+
90
+ All URIs are relative to *https://api.masspay.io/v0.1.4*
91
+
92
+ Class | Method | HTTP request | Description
93
+ ------------ | ------------- | ------------- | -------------
94
+ *MassPayRubySdk::AccountApi* | [**get_account_balance**](docs/AccountApi.md#get_account_balance) | **GET** /account/balance | Get current available balance
95
+ *MassPayRubySdk::AccountApi* | [**get_account_statement**](docs/AccountApi.md#get_account_statement) | **GET** /account/statement | Get certified account statement
96
+ *MassPayRubySdk::AttributeApi* | [**get_attrs**](docs/AttributeApi.md#get_attrs) | **GET** /attribute/{user_token}/{destination_token}/{currency} | Get user attributes for destination_token
97
+ *MassPayRubySdk::AttributeApi* | [**store_attrs**](docs/AttributeApi.md#store_attrs) | **POST** /attribute/{user_token}/{destination_token}/{currency} | Store user attributes
98
+ *MassPayRubySdk::CardApi* | [**get_wallet_card_info**](docs/CardApi.md#get_wallet_card_info) | **GET** /wallet/{user_token}/{wallet_token}/card | Get MassPay Card Information
99
+ *MassPayRubySdk::CardApi* | [**update_wallet_card_info**](docs/CardApi.md#update_wallet_card_info) | **PUT** /wallet/{user_token}/{wallet_token}/card | Update MassPay Card Information
100
+ *MassPayRubySdk::CatalogApi* | [**get_cheapest_country_services**](docs/CatalogApi.md#get_cheapest_country_services) | **GET** /country/{country_code}/cheapest | Gets a list of Companies and their cheapest service offerings for the given country code.
101
+ *MassPayRubySdk::CatalogApi* | [**get_country_list**](docs/CatalogApi.md#get_country_list) | **GET** /country/list | Gets a list of countries where services offered.
102
+ *MassPayRubySdk::CatalogApi* | [**get_country_services**](docs/CatalogApi.md#get_country_services) | **GET** /country/{country_code} | Gets a list of Companies and their service offerings for the given country code.
103
+ *MassPayRubySdk::CatalogApi* | [**get_destination_token_alternatives**](docs/CatalogApi.md#get_destination_token_alternatives) | **GET** /service/{destination_token}/alternatives | Returns list of alternative service to a provided service
104
+ *MassPayRubySdk::CatalogApi* | [**get_user_agreement**](docs/CatalogApi.md#get_user_agreement) | **GET** /user-agreements | Get User Agreement
105
+ *MassPayRubySdk::CatalogApi* | [**get_user_agreements_names**](docs/CatalogApi.md#get_user_agreements_names) | **OPTIONS** /user-agreements | Get Available User Agreements
106
+ *MassPayRubySdk::KYCApi* | [**find_attributes_velocity**](docs/KYCApi.md#find_attributes_velocity) | **POST** /attribute/{user_token}/velocity | Attributes velocity check
107
+ *MassPayRubySdk::KYCApi* | [**get_user_user_token_kyc_au10tix**](docs/KYCApi.md#get_user_user_token_kyc_au10tix) | **GET** /user/{user_token}/kyc/au10tix | Get an Au10tix session link
108
+ *MassPayRubySdk::KYCApi* | [**get_user_user_token_kyc_veriff**](docs/KYCApi.md#get_user_user_token_kyc_veriff) | **GET** /user/{user_token}/kyc/veriff | Get a Veriff session link
109
+ *MassPayRubySdk::KYCApi* | [**upload_id_photos**](docs/KYCApi.md#upload_id_photos) | **POST** /user/{user_token}/kyc/id | Upload ID Photos
110
+ *MassPayRubySdk::LoadApi* | [**cancel_user_load**](docs/LoadApi.md#cancel_user_load) | **DELETE** /load/{user_token} | Reverse a user load
111
+ *MassPayRubySdk::LoadApi* | [**create_autopay_rule**](docs/LoadApi.md#create_autopay_rule) | **POST** /wallet/{user_token}/{wallet_token}/autopay | Add autopay rule
112
+ *MassPayRubySdk::LoadApi* | [**delete_autopay_rule**](docs/LoadApi.md#delete_autopay_rule) | **DELETE** /wallet/{user_token}/{wallet_token}/autopay | Delete autopay rule
113
+ *MassPayRubySdk::LoadApi* | [**get_autopay_rules**](docs/LoadApi.md#get_autopay_rules) | **GET** /wallet/{user_token}/{wallet_token}/autopay | Get all autopay rules
114
+ *MassPayRubySdk::LoadApi* | [**get_user_loads_by_token**](docs/LoadApi.md#get_user_loads_by_token) | **GET** /load/{user_token} | Get history of loads by user token
115
+ *MassPayRubySdk::LoadApi* | [**load_user**](docs/LoadApi.md#load_user) | **POST** /load/{user_token} | Initiate a load transaction
116
+ *MassPayRubySdk::LoadApi* | [**load_user_token_put**](docs/LoadApi.md#load_user_token_put) | **PUT** /load/{user_token} | Resend Load Notification
117
+ *MassPayRubySdk::LoadApi* | [**resend_balance_notification**](docs/LoadApi.md#resend_balance_notification) | **PUT** /wallet/{user_token} | Resend Balance Notification
118
+ *MassPayRubySdk::PayoutApi* | [**commit_payout_txn**](docs/PayoutApi.md#commit_payout_txn) | **PUT** /payout/{user_token}/{payout_token} | Commit payout transaction
119
+ *MassPayRubySdk::PayoutApi* | [**get_payout_status**](docs/PayoutApi.md#get_payout_status) | **GET** /payout/{user_token}/{payout_token} | Get status of a payout by payout token
120
+ *MassPayRubySdk::PayoutApi* | [**get_transaction_confirmation_details**](docs/PayoutApi.md#get_transaction_confirmation_details) | **PATCH** /payout/{user_token}/{payout_token} | Get transaction confirmation details
121
+ *MassPayRubySdk::PayoutApi* | [**get_user_payouts_by_token**](docs/PayoutApi.md#get_user_payouts_by_token) | **GET** /payout/{user_token} | Get history of payouts by user token
122
+ *MassPayRubySdk::PayoutApi* | [**initiate_payout**](docs/PayoutApi.md#initiate_payout) | **POST** /payout/{user_token} | Initiate a payout transaction
123
+ *MassPayRubySdk::SpendBackApi* | [**get_user_spendbacks_by_token**](docs/SpendBackApi.md#get_user_spendbacks_by_token) | **GET** /spendback/{user_token} | Get history of spend backs by user token
124
+ *MassPayRubySdk::SpendBackApi* | [**initiate_spendback**](docs/SpendBackApi.md#initiate_spendback) | **POST** /spendback/{user_token} | Initiate a spend back transaction
125
+ *MassPayRubySdk::TaxApi* | [**get_tax_users**](docs/TaxApi.md#get_tax_users) | **GET** /tax | Get List Of Users Annual Balance
126
+ *MassPayRubySdk::UserApi* | [**create_user**](docs/UserApi.md#create_user) | **POST** /user | Create a user
127
+ *MassPayRubySdk::UserApi* | [**get_user_by_token**](docs/UserApi.md#get_user_by_token) | **GET** /user/{user_token} | Get user by user token
128
+ *MassPayRubySdk::UserApi* | [**get_user_history**](docs/UserApi.md#get_user_history) | **GET** /user/{user_token}/history | Transactions history
129
+ *MassPayRubySdk::UserApi* | [**update_user**](docs/UserApi.md#update_user) | **PUT** /user/{user_token} | Updated user
130
+ *MassPayRubySdk::UserApi* | [**user_lookup**](docs/UserApi.md#user_lookup) | **GET** /user/lookup | Lookup an existing user
131
+ *MassPayRubySdk::WalletApi* | [**create_autopay_rule**](docs/WalletApi.md#create_autopay_rule) | **POST** /wallet/{user_token}/{wallet_token}/autopay | Add autopay rule
132
+ *MassPayRubySdk::WalletApi* | [**delete_autopay_rule**](docs/WalletApi.md#delete_autopay_rule) | **DELETE** /wallet/{user_token}/{wallet_token}/autopay | Delete autopay rule
133
+ *MassPayRubySdk::WalletApi* | [**get_autopay_rules**](docs/WalletApi.md#get_autopay_rules) | **GET** /wallet/{user_token}/{wallet_token}/autopay | Get all autopay rules
134
+ *MassPayRubySdk::WalletApi* | [**get_wallet**](docs/WalletApi.md#get_wallet) | **GET** /wallet/{user_token} | Retrieve all available wallets for a user
135
+ *MassPayRubySdk::WalletApi* | [**get_wallet_card_info**](docs/WalletApi.md#get_wallet_card_info) | **GET** /wallet/{user_token}/{wallet_token}/card | Get MassPay Card Information
136
+ *MassPayRubySdk::WalletApi* | [**update_wallet_card_info**](docs/WalletApi.md#update_wallet_card_info) | **PUT** /wallet/{user_token}/{wallet_token}/card | Update MassPay Card Information
137
+
138
+
139
+ ## Documentation for Models
140
+
141
+ - [MassPayRubySdk::ApiResponse](docs/ApiResponse.md)
142
+ - [MassPayRubySdk::AttrTxn](docs/AttrTxn.md)
143
+ - [MassPayRubySdk::AttrValue](docs/AttrValue.md)
144
+ - [MassPayRubySdk::AttrVelocityRequestInner](docs/AttrVelocityRequestInner.md)
145
+ - [MassPayRubySdk::AttrsRequirement](docs/AttrsRequirement.md)
146
+ - [MassPayRubySdk::AutopayResp](docs/AutopayResp.md)
147
+ - [MassPayRubySdk::AutopayRule](docs/AutopayRule.md)
148
+ - [MassPayRubySdk::AvailableBalanceTxnResp](docs/AvailableBalanceTxnResp.md)
149
+ - [MassPayRubySdk::CompaniesResp](docs/CompaniesResp.md)
150
+ - [MassPayRubySdk::Company](docs/Company.md)
151
+ - [MassPayRubySdk::Country](docs/Country.md)
152
+ - [MassPayRubySdk::Exception](docs/Exception.md)
153
+ - [MassPayRubySdk::FoundUser](docs/FoundUser.md)
154
+ - [MassPayRubySdk::GetAccountStatement200Response](docs/GetAccountStatement200Response.md)
155
+ - [MassPayRubySdk::GetTransactionConfirmationDetails200Response](docs/GetTransactionConfirmationDetails200Response.md)
156
+ - [MassPayRubySdk::GetUserAgreement200Response](docs/GetUserAgreement200Response.md)
157
+ - [MassPayRubySdk::GetUserAgreementsNames200ResponseInner](docs/GetUserAgreementsNames200ResponseInner.md)
158
+ - [MassPayRubySdk::GetUserUserTokenKycAu10tix200Response](docs/GetUserUserTokenKycAu10tix200Response.md)
159
+ - [MassPayRubySdk::GetUserUserTokenKycVeriff200Response](docs/GetUserUserTokenKycVeriff200Response.md)
160
+ - [MassPayRubySdk::GetWalletCardInfo200Response](docs/GetWalletCardInfo200Response.md)
161
+ - [MassPayRubySdk::IDUpload](docs/IDUpload.md)
162
+ - [MassPayRubySdk::LoadTxn](docs/LoadTxn.md)
163
+ - [MassPayRubySdk::LoadTxnResp](docs/LoadTxnResp.md)
164
+ - [MassPayRubySdk::Loads](docs/Loads.md)
165
+ - [MassPayRubySdk::PayoutTxn](docs/PayoutTxn.md)
166
+ - [MassPayRubySdk::PayoutTxnCommitResp](docs/PayoutTxnCommitResp.md)
167
+ - [MassPayRubySdk::PayoutTxnResp](docs/PayoutTxnResp.md)
168
+ - [MassPayRubySdk::ResendBalanceNotification200Response](docs/ResendBalanceNotification200Response.md)
169
+ - [MassPayRubySdk::Service](docs/Service.md)
170
+ - [MassPayRubySdk::ServicePayersInner](docs/ServicePayersInner.md)
171
+ - [MassPayRubySdk::ServicePayersInnerExchangeRateInner](docs/ServicePayersInnerExchangeRateInner.md)
172
+ - [MassPayRubySdk::SpendBackTxn](docs/SpendBackTxn.md)
173
+ - [MassPayRubySdk::SpendBackTxnResp](docs/SpendBackTxnResp.md)
174
+ - [MassPayRubySdk::SpendBacks](docs/SpendBacks.md)
175
+ - [MassPayRubySdk::StoredUser](docs/StoredUser.md)
176
+ - [MassPayRubySdk::TaxYearUserResp](docs/TaxYearUserResp.md)
177
+ - [MassPayRubySdk::TxnHistoryResp](docs/TxnHistoryResp.md)
178
+ - [MassPayRubySdk::UpdateUser](docs/UpdateUser.md)
179
+ - [MassPayRubySdk::User](docs/User.md)
180
+ - [MassPayRubySdk::WalletTxnResp](docs/WalletTxnResp.md)
181
+
182
+
183
+ ## Documentation for Authorization
184
+
185
+
186
+ ### AUTHORIZER_NAME
187
+
188
+
189
+ - **Type**: API key
190
+ - **API key parameter name**: Authorization
191
+ - **Location**: HTTP header
192
+
193
+
194
+ ## Author
195
+
196
+ info@masspay.io
197
+
data/Rakefile ADDED
@@ -0,0 +1,10 @@
1
+ require "bundler/gem_tasks"
2
+
3
+ begin
4
+ require 'rspec/core/rake_task'
5
+
6
+ RSpec::Core::RakeTask.new(:spec)
7
+ task default: :spec
8
+ rescue LoadError
9
+ # no rspec available
10
+ end
@@ -0,0 +1,150 @@
1
+ # MassPayRubySdk::AccountApi
2
+
3
+ All URIs are relative to *https://api.masspay.io/v0.1.4*
4
+
5
+ | Method | HTTP request | Description |
6
+ | ------ | ------------ | ----------- |
7
+ | [**get_account_balance**](AccountApi.md#get_account_balance) | **GET** /account/balance | Get current available balance |
8
+ | [**get_account_statement**](AccountApi.md#get_account_statement) | **GET** /account/statement | Get certified account statement |
9
+
10
+
11
+ ## get_account_balance
12
+
13
+ > <Array<AvailableBalanceTxnResp>> get_account_balance
14
+
15
+ Get current available balance
16
+
17
+ This **GET** endpoint is used to retrieve the current available balance for the MassPay account. <br> You can use this endpoint to obtain information about the current balance in your account. <br> There are no required parameters needed to access this endpoint. <br> The response will include a JSON objects containing details for the current available balance, including the token, balance and `currency_code`.
18
+
19
+ ### Examples
20
+
21
+ ```ruby
22
+ require 'time'
23
+ require 'masspay_ruby_sdk'
24
+ # setup authorization
25
+ MassPayRubySdk.configure do |config|
26
+ # Configure API key authorization: AUTHORIZER_NAME
27
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
28
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
29
+ # config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
30
+ end
31
+
32
+ api_instance = MassPayRubySdk::AccountApi.new
33
+
34
+ begin
35
+ # Get current available balance
36
+ result = api_instance.get_account_balance
37
+ p result
38
+ rescue MassPayRubySdk::ApiError => e
39
+ puts "Error when calling AccountApi->get_account_balance: #{e}"
40
+ end
41
+ ```
42
+
43
+ #### Using the get_account_balance_with_http_info variant
44
+
45
+ This returns an Array which contains the response data, status code and headers.
46
+
47
+ > <Array(<Array<AvailableBalanceTxnResp>>, Integer, Hash)> get_account_balance_with_http_info
48
+
49
+ ```ruby
50
+ begin
51
+ # Get current available balance
52
+ data, status_code, headers = api_instance.get_account_balance_with_http_info
53
+ p status_code # => 2xx
54
+ p headers # => { ... }
55
+ p data # => <Array<AvailableBalanceTxnResp>>
56
+ rescue MassPayRubySdk::ApiError => e
57
+ puts "Error when calling AccountApi->get_account_balance_with_http_info: #{e}"
58
+ end
59
+ ```
60
+
61
+ ### Parameters
62
+
63
+ This endpoint does not need any parameter.
64
+
65
+ ### Return type
66
+
67
+ [**Array&lt;AvailableBalanceTxnResp&gt;**](AvailableBalanceTxnResp.md)
68
+
69
+ ### Authorization
70
+
71
+ [AUTHORIZER_NAME](../README.md#AUTHORIZER_NAME)
72
+
73
+ ### HTTP request headers
74
+
75
+ - **Content-Type**: Not defined
76
+ - **Accept**: application/json
77
+
78
+
79
+ ## get_account_statement
80
+
81
+ > <GetAccountStatement200Response> get_account_statement(start_date, ending_date)
82
+
83
+ Get certified account statement
84
+
85
+ This **GET** endpoint is used to retrieve a certified PDF ledger statement for a provided timeframe. <br> You can use this endpoint to obtain a ledger statement for your MassPay account for a specific time period. <br> To use this endpoint, you need to provide the `start_date` and `ending_date` as required parameters in the Query string of the URL. <br> The response will include a certified PDF ledger statement containing transaction details for the specified timeframe.
86
+
87
+ ### Examples
88
+
89
+ ```ruby
90
+ require 'time'
91
+ require 'masspay_ruby_sdk'
92
+ # setup authorization
93
+ MassPayRubySdk.configure do |config|
94
+ # Configure API key authorization: AUTHORIZER_NAME
95
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
96
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
97
+ # config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
98
+ end
99
+
100
+ api_instance = MassPayRubySdk::AccountApi.new
101
+ start_date = Date.parse('Fri Jan 01 01:00:00 CET 2021') # Date | Starting date of the statement
102
+ ending_date = Date.parse('Mon Feb 01 01:00:00 CET 2021') # Date | Ending date of the statement (not more than 31 days than `start_date`)
103
+
104
+ begin
105
+ # Get certified account statement
106
+ result = api_instance.get_account_statement(start_date, ending_date)
107
+ p result
108
+ rescue MassPayRubySdk::ApiError => e
109
+ puts "Error when calling AccountApi->get_account_statement: #{e}"
110
+ end
111
+ ```
112
+
113
+ #### Using the get_account_statement_with_http_info variant
114
+
115
+ This returns an Array which contains the response data, status code and headers.
116
+
117
+ > <Array(<GetAccountStatement200Response>, Integer, Hash)> get_account_statement_with_http_info(start_date, ending_date)
118
+
119
+ ```ruby
120
+ begin
121
+ # Get certified account statement
122
+ data, status_code, headers = api_instance.get_account_statement_with_http_info(start_date, ending_date)
123
+ p status_code # => 2xx
124
+ p headers # => { ... }
125
+ p data # => <GetAccountStatement200Response>
126
+ rescue MassPayRubySdk::ApiError => e
127
+ puts "Error when calling AccountApi->get_account_statement_with_http_info: #{e}"
128
+ end
129
+ ```
130
+
131
+ ### Parameters
132
+
133
+ | Name | Type | Description | Notes |
134
+ | ---- | ---- | ----------- | ----- |
135
+ | **start_date** | **Date** | Starting date of the statement | |
136
+ | **ending_date** | **Date** | Ending date of the statement (not more than 31 days than &#x60;start_date&#x60;) | |
137
+
138
+ ### Return type
139
+
140
+ [**GetAccountStatement200Response**](GetAccountStatement200Response.md)
141
+
142
+ ### Authorization
143
+
144
+ [AUTHORIZER_NAME](../README.md#AUTHORIZER_NAME)
145
+
146
+ ### HTTP request headers
147
+
148
+ - **Content-Type**: Not defined
149
+ - **Accept**: application/json
150
+
@@ -0,0 +1,22 @@
1
+ # MassPayRubySdk::ApiResponse
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **code** | **Integer** | | [optional] |
8
+ | **type** | **String** | | [optional] |
9
+ | **message** | **String** | | [optional] |
10
+
11
+ ## Example
12
+
13
+ ```ruby
14
+ require 'masspay_ruby_sdk'
15
+
16
+ instance = MassPayRubySdk::ApiResponse.new(
17
+ code: null,
18
+ type: null,
19
+ message: null
20
+ )
21
+ ```
22
+
data/docs/AttrTxn.md ADDED
@@ -0,0 +1,20 @@
1
+ # MassPayRubySdk::AttrTxn
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **values** | [**Array&lt;AttrValue&gt;**](AttrValue.md) | | |
8
+ | **attr_set_token** | **String** | The token that represents a set of attributes for a specific payer. Optional, specify the value if you&#39;re trying to update a value of a specific attributes set. | [optional] |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'masspay_ruby_sdk'
14
+
15
+ instance = MassPayRubySdk::AttrTxn.new(
16
+ values: null,
17
+ attr_set_token: attr_set_e2ca24e9-c546-4c64-90d2-cb8e70e7c9ba
18
+ )
19
+ ```
20
+
data/docs/AttrValue.md ADDED
@@ -0,0 +1,20 @@
1
+ # MassPayRubySdk::AttrValue
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **token** | **String** | The token that represents the attribute that needs to be updated. | |
8
+ | **value** | **String** | The value that needs to be stored for the associated token | |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'masspay_ruby_sdk'
14
+
15
+ instance = MassPayRubySdk::AttrValue.new(
16
+ token: e2ca24e9-c546-4c64-90d2-cb8e70e7c9ba,
17
+ value: 432532532
18
+ )
19
+ ```
20
+
@@ -0,0 +1,20 @@
1
+ # MassPayRubySdk::AttrVelocityRequestInner
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **type** | **String** | The type of attribute to look for | |
8
+ | **value** | **String** | The value to search for | |
9
+
10
+ ## Example
11
+
12
+ ```ruby
13
+ require 'masspay_ruby_sdk'
14
+
15
+ instance = MassPayRubySdk::AttrVelocityRequestInner.new(
16
+ type: null,
17
+ value: null
18
+ )
19
+ ```
20
+
@@ -0,0 +1,168 @@
1
+ # MassPayRubySdk::AttributeApi
2
+
3
+ All URIs are relative to *https://api.masspay.io/v0.1.4*
4
+
5
+ | Method | HTTP request | Description |
6
+ | ------ | ------------ | ----------- |
7
+ | [**get_attrs**](AttributeApi.md#get_attrs) | **GET** /attribute/{user_token}/{destination_token}/{currency} | Get user attributes for destination_token |
8
+ | [**store_attrs**](AttributeApi.md#store_attrs) | **POST** /attribute/{user_token}/{destination_token}/{currency} | Store user attributes |
9
+
10
+
11
+ ## get_attrs
12
+
13
+ > <Array<AttrsRequirement>> get_attrs(currency, user_token, destination_token, opts)
14
+
15
+ Get user attributes for destination_token
16
+
17
+ This **GET** endpoint is used to retrieve user attributes for a specific destination token. <br> You can use this endpoint to retrieve user attributes and provide personalized service to your users based on their preferences, demographic data, or other relevant information. <br> To use this endpoint, you need to provide the `user_token`, `destination_token`, and currency as parameters in the URL Path. <br> The endpoint will then return all the required attributes for the provided user for the specified destination token. If any of the attributes already have a stored value, it will be returned as well.
18
+
19
+ ### Examples
20
+
21
+ ```ruby
22
+ require 'time'
23
+ require 'masspay_ruby_sdk'
24
+ # setup authorization
25
+ MassPayRubySdk.configure do |config|
26
+ # Configure API key authorization: AUTHORIZER_NAME
27
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
28
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
29
+ # config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
30
+ end
31
+
32
+ api_instance = MassPayRubySdk::AttributeApi.new
33
+ currency = 'BRL' # String | The destination currency sending funds to. Using [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format.
34
+ user_token = 'user_token_example' # String | Token representing the user to retrieve attributes for
35
+ destination_token = 'destination_token_example' # String | Token that represents the payout destination i.e. Omnex->Brazil->Bank Deposit->Itau. To be retrieved from the #pricing callback.
36
+ opts = {
37
+ idempotency_key: 'idempotency_key_example' # String | Unique key to prevent duplicate processing
38
+ }
39
+
40
+ begin
41
+ # Get user attributes for destination_token
42
+ result = api_instance.get_attrs(currency, user_token, destination_token, opts)
43
+ p result
44
+ rescue MassPayRubySdk::ApiError => e
45
+ puts "Error when calling AttributeApi->get_attrs: #{e}"
46
+ end
47
+ ```
48
+
49
+ #### Using the get_attrs_with_http_info variant
50
+
51
+ This returns an Array which contains the response data, status code and headers.
52
+
53
+ > <Array(<Array<AttrsRequirement>>, Integer, Hash)> get_attrs_with_http_info(currency, user_token, destination_token, opts)
54
+
55
+ ```ruby
56
+ begin
57
+ # Get user attributes for destination_token
58
+ data, status_code, headers = api_instance.get_attrs_with_http_info(currency, user_token, destination_token, opts)
59
+ p status_code # => 2xx
60
+ p headers # => { ... }
61
+ p data # => <Array<AttrsRequirement>>
62
+ rescue MassPayRubySdk::ApiError => e
63
+ puts "Error when calling AttributeApi->get_attrs_with_http_info: #{e}"
64
+ end
65
+ ```
66
+
67
+ ### Parameters
68
+
69
+ | Name | Type | Description | Notes |
70
+ | ---- | ---- | ----------- | ----- |
71
+ | **currency** | **String** | The destination currency sending funds to. Using [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format. | |
72
+ | **user_token** | **String** | Token representing the user to retrieve attributes for | |
73
+ | **destination_token** | **String** | Token that represents the payout destination i.e. Omnex-&gt;Brazil-&gt;Bank Deposit-&gt;Itau. To be retrieved from the #pricing callback. | |
74
+ | **idempotency_key** | **String** | Unique key to prevent duplicate processing | [optional] |
75
+
76
+ ### Return type
77
+
78
+ [**Array&lt;AttrsRequirement&gt;**](AttrsRequirement.md)
79
+
80
+ ### Authorization
81
+
82
+ [AUTHORIZER_NAME](../README.md#AUTHORIZER_NAME)
83
+
84
+ ### HTTP request headers
85
+
86
+ - **Content-Type**: Not defined
87
+ - **Accept**: application/json
88
+
89
+
90
+ ## store_attrs
91
+
92
+ > store_attrs(currency, user_token, destination_token, attr_txn, opts)
93
+
94
+ Store user attributes
95
+
96
+ This **POST** endpoint is used to store user attributes, allowing you to associate additional data with a user token. <br> To use this endpoint, you need to provide the `user_token`, `destination_token`, and currency as parameters in the URL Path. You also need to provide the attribute values as JSON parameters in the Request body. <br> If existing attributes are already stored for the user, this call will override their values.
97
+
98
+ ### Examples
99
+
100
+ ```ruby
101
+ require 'time'
102
+ require 'masspay_ruby_sdk'
103
+ # setup authorization
104
+ MassPayRubySdk.configure do |config|
105
+ # Configure API key authorization: AUTHORIZER_NAME
106
+ config.api_key['AUTHORIZER_NAME'] = 'YOUR API KEY'
107
+ # Uncomment the following line to set a prefix for the API key, e.g. 'Bearer' (defaults to nil)
108
+ # config.api_key_prefix['AUTHORIZER_NAME'] = 'Bearer'
109
+ end
110
+
111
+ api_instance = MassPayRubySdk::AttributeApi.new
112
+ currency = 'BRL' # String | The destination currency sending funds to. Using [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format.
113
+ user_token = 'user_token_example' # String | Token representing the user to store attributes for
114
+ destination_token = 'destination_token_example' # String | Token that represents the payout destination i.e. Omnex->Brazil->Bank Deposit->Itau. To be retrieved from the #pricing callback.
115
+ attr_txn = MassPayRubySdk::AttrTxn.new({values: [MassPayRubySdk::AttrValue.new({token: 'e2ca24e9-c546-4c64-90d2-cb8e70e7c9ba', value: '432532532'})]}) # AttrTxn | Attr parameters to store
116
+ opts = {
117
+ idempotency_key: 'idempotency_key_example' # String | Unique key to prevent duplicate processing
118
+ }
119
+
120
+ begin
121
+ # Store user attributes
122
+ api_instance.store_attrs(currency, user_token, destination_token, attr_txn, opts)
123
+ rescue MassPayRubySdk::ApiError => e
124
+ puts "Error when calling AttributeApi->store_attrs: #{e}"
125
+ end
126
+ ```
127
+
128
+ #### Using the store_attrs_with_http_info variant
129
+
130
+ This returns an Array which contains the response data (`nil` in this case), status code and headers.
131
+
132
+ > <Array(nil, Integer, Hash)> store_attrs_with_http_info(currency, user_token, destination_token, attr_txn, opts)
133
+
134
+ ```ruby
135
+ begin
136
+ # Store user attributes
137
+ data, status_code, headers = api_instance.store_attrs_with_http_info(currency, user_token, destination_token, attr_txn, opts)
138
+ p status_code # => 2xx
139
+ p headers # => { ... }
140
+ p data # => nil
141
+ rescue MassPayRubySdk::ApiError => e
142
+ puts "Error when calling AttributeApi->store_attrs_with_http_info: #{e}"
143
+ end
144
+ ```
145
+
146
+ ### Parameters
147
+
148
+ | Name | Type | Description | Notes |
149
+ | ---- | ---- | ----------- | ----- |
150
+ | **currency** | **String** | The destination currency sending funds to. Using [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) format. | |
151
+ | **user_token** | **String** | Token representing the user to store attributes for | |
152
+ | **destination_token** | **String** | Token that represents the payout destination i.e. Omnex-&gt;Brazil-&gt;Bank Deposit-&gt;Itau. To be retrieved from the #pricing callback. | |
153
+ | **attr_txn** | [**AttrTxn**](AttrTxn.md) | Attr parameters to store | |
154
+ | **idempotency_key** | **String** | Unique key to prevent duplicate processing | [optional] |
155
+
156
+ ### Return type
157
+
158
+ nil (empty response body)
159
+
160
+ ### Authorization
161
+
162
+ [AUTHORIZER_NAME](../README.md#AUTHORIZER_NAME)
163
+
164
+ ### HTTP request headers
165
+
166
+ - **Content-Type**: application/json
167
+ - **Accept**: application/json
168
+