apiverve_loanpaymentcalculator 1.2.3 → 1.2.5

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '069e8df6874d02f18c1a05135935b0b0959a2c85fd812c5de32fae31555de6cd'
4
- data.tar.gz: c48760526ffca129d46dc98ce8a3d4cf0350098cb7848c7d85c4da73b68fb9f5
3
+ metadata.gz: a840e8b33dddb6529cf4a1512da0f296c31a5f04934dabe504417fe7973072ce
4
+ data.tar.gz: e4f20ff34885cd6ff9ac86128d44abffdd86ec5e6e1c6a5888b8540d1ce11efb
5
5
  SHA512:
6
- metadata.gz: '093dad3befd91fff55313ab73258b52351858629f52f1c95abd3eda16eaed8302bfc70de4ad0c26baffe83c3b34a06a927158412b316a92662facd14408904c5'
7
- data.tar.gz: 5d170b9b62d434c8a42d909f5f6b35eebb44b64311af9d772d914fed9a45d4ce87ca744245d894a08b28e543363d7f1c3d6050d43118c9c93571eb27f7e3f631
6
+ metadata.gz: 16e821ae9f4719a67e4fe993eeca48d6d29ecf2510b449a61ac3876a4ee5e31a29f37b183c8f8dd1f3c3f34e36d77fedce3ff11a33f35940913c47d0ec597bf0
7
+ data.tar.gz: 732e8a3c42905ac416b91804d891f89677bc0adc013d99a519cac30be827da7140609e46aaa34165419fa4d33208cc5092d0189fa0f58a179d523dbb5ed89a49
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Loan Calculator API - Ruby Gem
2
2
 
3
- Loan Calculator is a payment calculation API that computes monthly loan payments, total interest, and overall loan costs based on principal, annual interest rate, and term length. Include an optional down payment to determine adjusted financing balances and interest ratios.
3
+ Loan Calculator is a payment calculation API that computes monthly loan payments, total interest, and overall loan costs based on principal, annual interest rate, and term length. Include an optional down payment to determine adjusted financing balances and interest ratios. On paid plans, optional inputs add an extra-payment payoff plan with months and interest saved, payoff dates from a start date, biweekly or weekly payment figures, and an APR that includes upfront fees.
4
4
 
5
5
  ## Installation
6
6
 
@@ -38,7 +38,11 @@ client = APIVerve::Loanpaymentcalculator::Client.new(api_key: "YOUR_API_KEY")
38
38
  response = client.execute({
39
39
  loanAmount: 32000,
40
40
  interestRate: 8.5,
41
- loanTerm: 6
41
+ loanTerm: 6,
42
+ extraPayment: 100,
43
+ startDate: "2026-12-01",
44
+ paymentFrequency: "biweekly",
45
+ fees: 800
42
46
  })
43
47
 
44
48
  # Print the response
@@ -50,7 +54,7 @@ puts response
50
54
 
51
55
  ```ruby
52
56
  begin
53
- response = client.execute({ loanAmount: 32000, interestRate: 8.5, loanTerm: 6 })
57
+ response = client.execute({ loanAmount: 32000, interestRate: 8.5, loanTerm: 6, extraPayment: 100, startDate: "2026-12-01", paymentFrequency: "biweekly", fees: 800 })
54
58
  puts response["data"]
55
59
  rescue APIVerve::Loanpaymentcalculator::ValidationError => e
56
60
  puts "Validation error: #{e.errors.join(', ')}"
@@ -83,13 +87,13 @@ client = APIVerve::Loanpaymentcalculator::Client.new(
83
87
  "loanTerm": 6,
84
88
  "monthly_payment": 568.91,
85
89
  "total_interest_paid": 8961.4,
86
- "total_payment": 40961.52,
90
+ "total_payment": 40961.4,
87
91
  "interestRatio": 21.88,
88
92
  "formatted": {
89
93
  "loanAmount": "$32,000.00",
90
94
  "monthlyPayment": "$568.91",
91
95
  "totalInterestPaid": "$8,961.40",
92
- "totalPayment": "$40,961.52"
96
+ "totalPayment": "$40,961.40"
93
97
  },
94
98
  "amortization_schedule": [
95
99
  {
@@ -110,7 +114,49 @@ client = APIVerve::Loanpaymentcalculator::Client.new(
110
114
  "principal_payment": 347.11,
111
115
  "remaining_balance": 30965.99
112
116
  }
113
- ]
117
+ ],
118
+ "payoff_date": "2032-12-01",
119
+ "extra_payment": {
120
+ "extra_monthly_payment": 100,
121
+ "monthly_payment": 668.91,
122
+ "payoff_months": 59,
123
+ "months_saved": 13,
124
+ "total_interest_paid": 7214.73,
125
+ "total_payment": 39214.73,
126
+ "interest_saved": 1746.67,
127
+ "payoff_date": "2031-11-01",
128
+ "amortization_schedule": [
129
+ {
130
+ "month": 1,
131
+ "interest_payment": 226.67,
132
+ "principal_payment": 442.24,
133
+ "remaining_balance": 31557.76
134
+ },
135
+ {
136
+ "month": 2,
137
+ "interest_payment": 223.53,
138
+ "principal_payment": 445.37,
139
+ "remaining_balance": 31112.38
140
+ },
141
+ {
142
+ "month": 3,
143
+ "interest_payment": 220.38,
144
+ "principal_payment": 448.53,
145
+ "remaining_balance": 30663.86
146
+ }
147
+ ]
148
+ },
149
+ "payment_frequency": {
150
+ "frequency": "biweekly",
151
+ "payments_per_year": 26,
152
+ "number_of_payments": 156,
153
+ "payment": 262.19,
154
+ "total_interest_paid": 8901.77,
155
+ "total_payment": 40901.77,
156
+ "interest_saved": 59.62
157
+ },
158
+ "fees": 800,
159
+ "apr": 9.419
114
160
  }
115
161
  }
116
162
  ```
@@ -10,7 +10,7 @@ module APIVerve
10
10
  #
11
11
  # @example Basic usage
12
12
  # client = APIVerve::Loanpaymentcalculator::Client.new(api_key: "your_api_key")
13
- # response = client.execute({ loanAmount: 32000, interestRate: 8.5, loanTerm: 6 })
13
+ # response = client.execute({ loanAmount: 32000, interestRate: 8.5, loanTerm: 6, extraPayment: 100, startDate: "2026-12-01", paymentFrequency: "biweekly", fees: 800 })
14
14
  # puts response
15
15
  #
16
16
  # @see https://apiverve.com/marketplace/loanpaymentcalculator?utm_source=ruby&utm_medium=referral&utm_content=readme
@@ -19,7 +19,7 @@ module APIVerve
19
19
  DEFAULT_TIMEOUT = 30
20
20
 
21
21
  # Validation rules for parameters
22
- VALIDATION_RULES = { 'loanAmount' => { type: 'number', required: true, min: 0 }, 'interestRate' => { type: 'number', required: true, min: 0, max: 100 }, 'loanTerm' => { type: 'integer', required: true, min: 1, max: 50 }, 'downpayment' => { type: 'number', required: false, min: 0 } }
22
+ VALIDATION_RULES = { 'loanAmount' => { type: 'number', required: true, min: 0 }, 'interestRate' => { type: 'number', required: true, min: 0, max: 100 }, 'loanTerm' => { type: 'integer', required: true, min: 1, max: 50 }, 'downpayment' => { type: 'number', required: false, min: 0 }, 'extraPayment' => { type: 'number', required: false, min: 0 }, 'startDate' => { type: 'string', required: false, format: 'date' }, 'paymentFrequency' => { type: 'string', required: false }, 'fees' => { type: 'number', required: false, min: 0 } }
23
23
 
24
24
  # Format validation patterns
25
25
  FORMAT_PATTERNS = {
@@ -4,6 +4,6 @@ require_relative "apiverve_loanpaymentcalculator/client"
4
4
 
5
5
  module APIVerve
6
6
  module Loanpaymentcalculator
7
- VERSION = "1.2.3"
7
+ VERSION = "1.2.5"
8
8
  end
9
9
  end
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: apiverve_loanpaymentcalculator
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.3
4
+ version: 1.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - APIVerve
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2026-10-26 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: faraday
@@ -61,7 +60,9 @@ dependencies:
61
60
  description: Loan Calculator is a payment calculation API that computes monthly loan
62
61
  payments, total interest, and overall loan costs based on principal, annual interest
63
62
  rate, and term length. Include an optional down payment to determine adjusted financing
64
- balances and interest ratios.
63
+ balances and interest ratios. On paid plans, optional inputs add an extra-payment
64
+ payoff plan with months and interest saved, payoff dates from a start date, biweekly
65
+ or weekly payment figures, and an APR that includes upfront fees.
65
66
  email:
66
67
  - hello@apiverve.com
67
68
  executables: []
@@ -80,7 +81,6 @@ metadata:
80
81
  source_code_uri: https://github.com/apiverve/loanpaymentcalculator-API/tree/main/ruby
81
82
  changelog_uri: https://apiverve.com/changelog
82
83
  documentation_uri: https://docs.apiverve.com/ref/loanpaymentcalculator
83
- post_install_message:
84
84
  rdoc_options: []
85
85
  require_paths:
86
86
  - lib
@@ -95,8 +95,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
95
95
  - !ruby/object:Gem::Version
96
96
  version: '0'
97
97
  requirements: []
98
- rubygems_version: 3.0.3.1
99
- signing_key:
98
+ rubygems_version: 4.0.23
100
99
  specification_version: 4
101
100
  summary: Loan Calculator API - Ruby Client
102
101
  test_files: []