billfixers-partner 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/billfixers/partner/client.rb +12 -0
- data/lib/billfixers/partner/gql.rb +22 -0
- data/lib/billfixers/partner/version.rb +1 -1
- data/partner_schema.json +244 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f794d4a72efb2cca5bb9ff538de67eca7f244a02a13286d6a1482a57486e8363
|
4
|
+
data.tar.gz: b3da5849c748424e020f824234af7406f3921af8df93a0fd65458fb6b0ca65a2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7026f7678618ae96220c39a4d5600c11974213dc683ecf6a6fd1aa49d7304076a8fc03bf1d56af10f9f838be1928121a3ca9a3c922297c22440ebc40983e37cc
|
7
|
+
data.tar.gz: a0e9928aa8a50f0e75f717353e4168dc276093167e42af9cc2dd45c1e40ff30e85a5cb60e6b0d10a4ede0fc28f0dbdc3ce2339e2f0f3bcff47c1d3541b474463
|
@@ -155,6 +155,18 @@ module Billfixers
|
|
155
155
|
result.information_request
|
156
156
|
end
|
157
157
|
|
158
|
+
def calculate_savings_estimate(provider_id, current_monthly_payment)
|
159
|
+
response = @gql.query(
|
160
|
+
CALCULATE_SAVINGS_ESTIMATE,
|
161
|
+
{
|
162
|
+
provider_id: provider_id,
|
163
|
+
current_monthly_amount: current_monthly_payment
|
164
|
+
}
|
165
|
+
)
|
166
|
+
|
167
|
+
response.data.calculate_savings_estimate
|
168
|
+
end
|
169
|
+
|
158
170
|
private
|
159
171
|
|
160
172
|
def camelize(hsh)
|
@@ -260,5 +260,27 @@ module Billfixers
|
|
260
260
|
}
|
261
261
|
}
|
262
262
|
)
|
263
|
+
|
264
|
+
CALCULATE_SAVINGS_ESTIMATE = %(
|
265
|
+
query(
|
266
|
+
$providerId: ID!
|
267
|
+
$currentMonthlyAmount: Float!
|
268
|
+
) {
|
269
|
+
CalculateSavingsEstimate {
|
270
|
+
estimatedAnnualSavings(
|
271
|
+
providerId: $providerId
|
272
|
+
currentMonthlyAmount: $currentMonthlyAmount
|
273
|
+
)
|
274
|
+
estimatedMonthlySavings(
|
275
|
+
providerId: $providerId
|
276
|
+
currentMonthlyAmount: $currentMonthlyAmount
|
277
|
+
)
|
278
|
+
percentageSavings(
|
279
|
+
providerId: $providerId
|
280
|
+
currentMonthlyAmount: $currentMonthlyAmount
|
281
|
+
)
|
282
|
+
}
|
283
|
+
}
|
284
|
+
)
|
263
285
|
end
|
264
286
|
end
|
data/partner_schema.json
CHANGED
@@ -1595,6 +1595,16 @@
|
|
1595
1595
|
"enumValues": null,
|
1596
1596
|
"possibleTypes": null
|
1597
1597
|
},
|
1598
|
+
{
|
1599
|
+
"kind": "SCALAR",
|
1600
|
+
"name": "Float",
|
1601
|
+
"description": "Represents signed double-precision fractional values as specified by [IEEE 754](https://en.wikipedia.org/wiki/IEEE_floating_point).",
|
1602
|
+
"fields": null,
|
1603
|
+
"inputFields": null,
|
1604
|
+
"interfaces": null,
|
1605
|
+
"enumValues": null,
|
1606
|
+
"possibleTypes": null
|
1607
|
+
},
|
1598
1608
|
{
|
1599
1609
|
"kind": "SCALAR",
|
1600
1610
|
"name": "ID",
|
@@ -2449,6 +2459,24 @@
|
|
2449
2459
|
"isDeprecated": false,
|
2450
2460
|
"deprecationReason": null
|
2451
2461
|
},
|
2462
|
+
{
|
2463
|
+
"name": "type",
|
2464
|
+
"description": "The type of item",
|
2465
|
+
"args": [
|
2466
|
+
|
2467
|
+
],
|
2468
|
+
"type": {
|
2469
|
+
"kind": "NON_NULL",
|
2470
|
+
"name": null,
|
2471
|
+
"ofType": {
|
2472
|
+
"kind": "SCALAR",
|
2473
|
+
"name": "String",
|
2474
|
+
"ofType": null
|
2475
|
+
}
|
2476
|
+
},
|
2477
|
+
"isDeprecated": false,
|
2478
|
+
"deprecationReason": null
|
2479
|
+
},
|
2452
2480
|
{
|
2453
2481
|
"name": "underContract",
|
2454
2482
|
"description": "Indicates the item is under contract",
|
@@ -3590,6 +3618,56 @@
|
|
3590
3618
|
"isDeprecated": false,
|
3591
3619
|
"deprecationReason": null
|
3592
3620
|
},
|
3621
|
+
{
|
3622
|
+
"name": "name",
|
3623
|
+
"description": "Name of the partner",
|
3624
|
+
"args": [
|
3625
|
+
|
3626
|
+
],
|
3627
|
+
"type": {
|
3628
|
+
"kind": "NON_NULL",
|
3629
|
+
"name": null,
|
3630
|
+
"ofType": {
|
3631
|
+
"kind": "SCALAR",
|
3632
|
+
"name": "String",
|
3633
|
+
"ofType": null
|
3634
|
+
}
|
3635
|
+
},
|
3636
|
+
"isDeprecated": false,
|
3637
|
+
"deprecationReason": null
|
3638
|
+
},
|
3639
|
+
{
|
3640
|
+
"name": "referralCode",
|
3641
|
+
"description": "The partner's referral code",
|
3642
|
+
"args": [
|
3643
|
+
|
3644
|
+
],
|
3645
|
+
"type": {
|
3646
|
+
"kind": "SCALAR",
|
3647
|
+
"name": "String",
|
3648
|
+
"ofType": null
|
3649
|
+
},
|
3650
|
+
"isDeprecated": false,
|
3651
|
+
"deprecationReason": null
|
3652
|
+
},
|
3653
|
+
{
|
3654
|
+
"name": "referralLink",
|
3655
|
+
"description": "The partner's referral link",
|
3656
|
+
"args": [
|
3657
|
+
|
3658
|
+
],
|
3659
|
+
"type": {
|
3660
|
+
"kind": "NON_NULL",
|
3661
|
+
"name": null,
|
3662
|
+
"ofType": {
|
3663
|
+
"kind": "SCALAR",
|
3664
|
+
"name": "String",
|
3665
|
+
"ofType": null
|
3666
|
+
}
|
3667
|
+
},
|
3668
|
+
"isDeprecated": false,
|
3669
|
+
"deprecationReason": null
|
3670
|
+
},
|
3593
3671
|
{
|
3594
3672
|
"name": "testWebhookUrl",
|
3595
3673
|
"description": "Webhook URL for test/development requests",
|
@@ -3786,6 +3864,24 @@
|
|
3786
3864
|
"name": "Query",
|
3787
3865
|
"description": null,
|
3788
3866
|
"fields": [
|
3867
|
+
{
|
3868
|
+
"name": "CalculateSavingsEstimate",
|
3869
|
+
"description": null,
|
3870
|
+
"args": [
|
3871
|
+
|
3872
|
+
],
|
3873
|
+
"type": {
|
3874
|
+
"kind": "NON_NULL",
|
3875
|
+
"name": null,
|
3876
|
+
"ofType": {
|
3877
|
+
"kind": "OBJECT",
|
3878
|
+
"name": "SavingsEstimate",
|
3879
|
+
"ofType": null
|
3880
|
+
}
|
3881
|
+
},
|
3882
|
+
"isDeprecated": false,
|
3883
|
+
"deprecationReason": null
|
3884
|
+
},
|
3789
3885
|
{
|
3790
3886
|
"name": "FindBill",
|
3791
3887
|
"description": null,
|
@@ -4673,6 +4769,154 @@
|
|
4673
4769
|
"enumValues": null,
|
4674
4770
|
"possibleTypes": null
|
4675
4771
|
},
|
4772
|
+
{
|
4773
|
+
"kind": "OBJECT",
|
4774
|
+
"name": "SavingsEstimate",
|
4775
|
+
"description": null,
|
4776
|
+
"fields": [
|
4777
|
+
{
|
4778
|
+
"name": "estimatedAnnualSavings",
|
4779
|
+
"description": null,
|
4780
|
+
"args": [
|
4781
|
+
{
|
4782
|
+
"name": "providerId",
|
4783
|
+
"description": null,
|
4784
|
+
"type": {
|
4785
|
+
"kind": "NON_NULL",
|
4786
|
+
"name": null,
|
4787
|
+
"ofType": {
|
4788
|
+
"kind": "SCALAR",
|
4789
|
+
"name": "ID",
|
4790
|
+
"ofType": null
|
4791
|
+
}
|
4792
|
+
},
|
4793
|
+
"defaultValue": null
|
4794
|
+
},
|
4795
|
+
{
|
4796
|
+
"name": "currentMonthlyAmount",
|
4797
|
+
"description": null,
|
4798
|
+
"type": {
|
4799
|
+
"kind": "NON_NULL",
|
4800
|
+
"name": null,
|
4801
|
+
"ofType": {
|
4802
|
+
"kind": "SCALAR",
|
4803
|
+
"name": "Float",
|
4804
|
+
"ofType": null
|
4805
|
+
}
|
4806
|
+
},
|
4807
|
+
"defaultValue": null
|
4808
|
+
}
|
4809
|
+
],
|
4810
|
+
"type": {
|
4811
|
+
"kind": "NON_NULL",
|
4812
|
+
"name": null,
|
4813
|
+
"ofType": {
|
4814
|
+
"kind": "SCALAR",
|
4815
|
+
"name": "Money",
|
4816
|
+
"ofType": null
|
4817
|
+
}
|
4818
|
+
},
|
4819
|
+
"isDeprecated": false,
|
4820
|
+
"deprecationReason": null
|
4821
|
+
},
|
4822
|
+
{
|
4823
|
+
"name": "estimatedMonthlySavings",
|
4824
|
+
"description": null,
|
4825
|
+
"args": [
|
4826
|
+
{
|
4827
|
+
"name": "providerId",
|
4828
|
+
"description": null,
|
4829
|
+
"type": {
|
4830
|
+
"kind": "NON_NULL",
|
4831
|
+
"name": null,
|
4832
|
+
"ofType": {
|
4833
|
+
"kind": "SCALAR",
|
4834
|
+
"name": "ID",
|
4835
|
+
"ofType": null
|
4836
|
+
}
|
4837
|
+
},
|
4838
|
+
"defaultValue": null
|
4839
|
+
},
|
4840
|
+
{
|
4841
|
+
"name": "currentMonthlyAmount",
|
4842
|
+
"description": null,
|
4843
|
+
"type": {
|
4844
|
+
"kind": "NON_NULL",
|
4845
|
+
"name": null,
|
4846
|
+
"ofType": {
|
4847
|
+
"kind": "SCALAR",
|
4848
|
+
"name": "Float",
|
4849
|
+
"ofType": null
|
4850
|
+
}
|
4851
|
+
},
|
4852
|
+
"defaultValue": null
|
4853
|
+
}
|
4854
|
+
],
|
4855
|
+
"type": {
|
4856
|
+
"kind": "NON_NULL",
|
4857
|
+
"name": null,
|
4858
|
+
"ofType": {
|
4859
|
+
"kind": "SCALAR",
|
4860
|
+
"name": "Money",
|
4861
|
+
"ofType": null
|
4862
|
+
}
|
4863
|
+
},
|
4864
|
+
"isDeprecated": false,
|
4865
|
+
"deprecationReason": null
|
4866
|
+
},
|
4867
|
+
{
|
4868
|
+
"name": "percentageSavings",
|
4869
|
+
"description": null,
|
4870
|
+
"args": [
|
4871
|
+
{
|
4872
|
+
"name": "providerId",
|
4873
|
+
"description": null,
|
4874
|
+
"type": {
|
4875
|
+
"kind": "NON_NULL",
|
4876
|
+
"name": null,
|
4877
|
+
"ofType": {
|
4878
|
+
"kind": "SCALAR",
|
4879
|
+
"name": "ID",
|
4880
|
+
"ofType": null
|
4881
|
+
}
|
4882
|
+
},
|
4883
|
+
"defaultValue": null
|
4884
|
+
},
|
4885
|
+
{
|
4886
|
+
"name": "currentMonthlyAmount",
|
4887
|
+
"description": null,
|
4888
|
+
"type": {
|
4889
|
+
"kind": "NON_NULL",
|
4890
|
+
"name": null,
|
4891
|
+
"ofType": {
|
4892
|
+
"kind": "SCALAR",
|
4893
|
+
"name": "Float",
|
4894
|
+
"ofType": null
|
4895
|
+
}
|
4896
|
+
},
|
4897
|
+
"defaultValue": null
|
4898
|
+
}
|
4899
|
+
],
|
4900
|
+
"type": {
|
4901
|
+
"kind": "NON_NULL",
|
4902
|
+
"name": null,
|
4903
|
+
"ofType": {
|
4904
|
+
"kind": "SCALAR",
|
4905
|
+
"name": "Float",
|
4906
|
+
"ofType": null
|
4907
|
+
}
|
4908
|
+
},
|
4909
|
+
"isDeprecated": false,
|
4910
|
+
"deprecationReason": null
|
4911
|
+
}
|
4912
|
+
],
|
4913
|
+
"inputFields": null,
|
4914
|
+
"interfaces": [
|
4915
|
+
|
4916
|
+
],
|
4917
|
+
"enumValues": null,
|
4918
|
+
"possibleTypes": null
|
4919
|
+
},
|
4676
4920
|
{
|
4677
4921
|
"kind": "SCALAR",
|
4678
4922
|
"name": "String",
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: billfixers-partner
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- BillFixers
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-02-
|
11
|
+
date: 2021-02-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|