plaid 6.1.0 → 6.2.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +1 -1
- data/README.md +1 -1
- data/lib/plaid/client.rb +3 -0
- data/lib/plaid/models.rb +56 -0
- data/lib/plaid/products/asset_report.rb +72 -6
- data/lib/plaid/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 865a246047bc8acf858a9b9d521aa1aef8d275ce
|
4
|
+
data.tar.gz: 3a197bc1f6e0d94550e4063cd16fb984580934aa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 258a35dee81754143a6172f65a47e1a596aaada2336d0486d54d1fbdbf8da6f163fd152265e00e9c506c4b5b7dd1f584d17cc6eb28da4a64c31b98154b487fff
|
7
|
+
data.tar.gz: e32bd447ebd887917500e041b4dacb1d9b9afffdf71454566d60b1903e57bc642cf6bb25d58e5ce1f842d5988911862c027d401a013051fd174fce328ddce486
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -237,5 +237,5 @@ The gem is available as open source under the terms of the [MIT License](http://
|
|
237
237
|
If you're looking for a Ruby client that works with the legacy Plaid API, use the [`plaid-legacy` gem][2].
|
238
238
|
|
239
239
|
[2]: https://github.com/plaid/plaid-ruby-legacy
|
240
|
-
[version-changelog]: https://plaid.com/docs/
|
240
|
+
[version-changelog]: https://plaid.com/docs/api-upgrades
|
241
241
|
[api-version-2018-05-22]: https://plaid.com/docs/api-upgrades#2018-05-22
|
data/lib/plaid/client.rb
CHANGED
@@ -8,6 +8,9 @@ module Plaid
|
|
8
8
|
# Public: The current environment in use (one of ENVIRONMENTS).
|
9
9
|
attr_reader :env
|
10
10
|
|
11
|
+
# Public: The client ID.
|
12
|
+
attr_reader :client_id
|
13
|
+
|
11
14
|
# Public: Construct a Client instance
|
12
15
|
#
|
13
16
|
# Optionally takes a block to allow overriding the default Faraday
|
data/lib/plaid/models.rb
CHANGED
@@ -551,6 +551,12 @@ module Plaid
|
|
551
551
|
# Public: The Boolean flag indicating if the institution uses MFA.
|
552
552
|
property :has_mfa
|
553
553
|
|
554
|
+
##
|
555
|
+
# :attr_reader:
|
556
|
+
# Public: The String reflecting the MFA code type ("numeric" /
|
557
|
+
# "alphanumeric")
|
558
|
+
property :mfa_code_type
|
559
|
+
|
554
560
|
##
|
555
561
|
# :attr_reader:
|
556
562
|
# Public: The String institution ID (e.g. "ins_109512").
|
@@ -915,6 +921,56 @@ module Plaid
|
|
915
921
|
# Public: The unofficial currency code associated with the transaction.
|
916
922
|
# Always nil if iso_currency_code is non-nil.
|
917
923
|
property :unofficial_currency_code
|
924
|
+
|
925
|
+
##
|
926
|
+
# :attr_reader: Public: The String account owner (or nil). This field
|
927
|
+
# only appears in an Asset Report with Insights.
|
928
|
+
property :account_owner
|
929
|
+
|
930
|
+
##
|
931
|
+
# :attr_reader: Public: The Array of String category (or nil). This field
|
932
|
+
# only appears in an Asset Report with Insights. E.g. ["Payment", "Credit
|
933
|
+
# Card"].
|
934
|
+
property :category
|
935
|
+
|
936
|
+
##
|
937
|
+
# :attr_reader: Public: The String category_id (or nil). This field only
|
938
|
+
# appears in an Asset Report with Insights. E.g. "16001000".
|
939
|
+
property :category_id
|
940
|
+
|
941
|
+
##
|
942
|
+
# :attr_reader: Public: The String date of the transaction (or nil). This
|
943
|
+
# field only appears in an Asset Report with Insights.
|
944
|
+
property :date_transacted
|
945
|
+
|
946
|
+
##
|
947
|
+
# :attr_reader: Public: The location where transaction occurred
|
948
|
+
# (TransactionLocation). This field only appears in an Asset Report with
|
949
|
+
# Insights.
|
950
|
+
property :location, coerce: TransactionLocation
|
951
|
+
|
952
|
+
##
|
953
|
+
# :attr_reader: Public: The String transaction name (or nil). This field
|
954
|
+
# only appears in an Asset Report with Insights. E.g. "CREDIT CARD 3333
|
955
|
+
# PAYMENT *//".
|
956
|
+
property :name
|
957
|
+
|
958
|
+
##
|
959
|
+
# :attr_reader: Public: The payment meta information
|
960
|
+
# (TransactionPaymentMeta). This field only appears in an Asset Report
|
961
|
+
# with Insights.
|
962
|
+
property :payment_meta, coerce: TransactionPaymentMeta
|
963
|
+
|
964
|
+
##
|
965
|
+
# :attr_reader: Public: The String pending transaction ID (or nil). This
|
966
|
+
# field only appears in an Asset Report with Insights.
|
967
|
+
property :pending_transaction_id
|
968
|
+
|
969
|
+
##
|
970
|
+
# :attr_reader: Public: The String transaction type (or nil). E.g.
|
971
|
+
# "special", or "place". This field only appears in an Asset Report with
|
972
|
+
# Insights.
|
973
|
+
property :transaction_type
|
918
974
|
end
|
919
975
|
|
920
976
|
# Public: A representation of an asset report account.
|
@@ -10,12 +10,12 @@ module Plaid
|
|
10
10
|
# the Asset Report. Plaid will return as much data as
|
11
11
|
# possible within the implied date range, up to a maximum
|
12
12
|
# of 730 days (2 years) of history.
|
13
|
-
# options
|
13
|
+
# options - An optional object containing client-provided user
|
14
14
|
# information, a client-provided report ID, and a webhook.
|
15
15
|
# For more information, see the website listed above.
|
16
16
|
#
|
17
17
|
# Returns a AssetReportCreateResponse object.
|
18
|
-
def create(access_tokens, days_requested, options)
|
18
|
+
def create(access_tokens, days_requested, options = {})
|
19
19
|
post_with_auth 'asset_report/create',
|
20
20
|
AssetReportCreateResponse,
|
21
21
|
access_tokens: access_tokens,
|
@@ -23,15 +23,57 @@ module Plaid
|
|
23
23
|
options: options
|
24
24
|
end
|
25
25
|
|
26
|
+
# Public: Create a new, filtered asset report.
|
27
|
+
#
|
28
|
+
# asset_report_token - The asset report token for the asset report you
|
29
|
+
# want to filter.
|
30
|
+
# account_ids_to_exclude - The list of account IDs to exclude from the
|
31
|
+
# original asset report.
|
32
|
+
#
|
33
|
+
# Returns a AssetReportFilterResponse object.
|
34
|
+
def filter(asset_report_token, account_ids_to_exclude)
|
35
|
+
post_with_auth 'asset_report/filter',
|
36
|
+
AssetReportFilterResponse,
|
37
|
+
asset_report_token: asset_report_token,
|
38
|
+
account_ids_to_exclude: account_ids_to_exclude
|
39
|
+
end
|
40
|
+
|
41
|
+
# Public: Create a new, refreshed asset report.
|
42
|
+
#
|
43
|
+
# asset_report_token - The asset report token for the asset report you want
|
44
|
+
# to refresh.
|
45
|
+
# days_requested - Days of transaction history requested to be included
|
46
|
+
# in the Asset Report. Plaid will return as much data
|
47
|
+
# as possible within the implied date range, up to a
|
48
|
+
# maximum of 730 days (2 years) of history.
|
49
|
+
# options - An optional object containing client-provided user
|
50
|
+
# information, a client-provided report ID, and a
|
51
|
+
# webhook. For more information, see the website
|
52
|
+
# listed above.
|
53
|
+
#
|
54
|
+
# Returns a AssetReportRefreshResponse object.
|
55
|
+
def refresh(asset_report_token, days_requested, options = {})
|
56
|
+
post_with_auth 'asset_report/refresh',
|
57
|
+
AssetReportRefreshResponse,
|
58
|
+
asset_report_token: asset_report_token,
|
59
|
+
days_requested: days_requested,
|
60
|
+
options: options
|
61
|
+
end
|
62
|
+
|
26
63
|
# Public: Retrieve an asset report.
|
27
64
|
#
|
28
65
|
# asset_report_token - The asset report token from the `create` response.
|
66
|
+
# include_insights - An optional boolean specifying whether we should
|
67
|
+
# retrieve the report as an "Assets + Insights"
|
68
|
+
# report. For information about Assets + Insights
|
69
|
+
# reports, see https://plaid.com/docs/#assets.
|
29
70
|
#
|
30
71
|
# Returns a AssetReportGetResponse object.
|
31
|
-
def get(asset_report_token)
|
72
|
+
def get(asset_report_token, include_insights: false)
|
32
73
|
post_with_auth 'asset_report/get',
|
33
74
|
AssetReportGetResponse,
|
34
|
-
asset_report_token: asset_report_token
|
75
|
+
asset_report_token: asset_report_token,
|
76
|
+
include_insights: include_insights
|
35
77
|
end
|
36
78
|
|
37
79
|
# Public: Retrieve an asset report as a PDF.
|
@@ -69,6 +111,18 @@ module Plaid
|
|
69
111
|
auditor_id: auditor_id
|
70
112
|
end
|
71
113
|
|
114
|
+
# Public: Retrieve an audit copy.
|
115
|
+
#
|
116
|
+
# audit_copy_token - The audit copy token from the `create_audit_copy`
|
117
|
+
# response.
|
118
|
+
#
|
119
|
+
# Returns a AuditCopyGetResponse object.
|
120
|
+
def get_audit_copy(audit_copy_token)
|
121
|
+
post_with_auth 'asset_report/audit_copy/get',
|
122
|
+
AuditCopyGetResponse,
|
123
|
+
audit_copy_token: audit_copy_token
|
124
|
+
end
|
125
|
+
|
72
126
|
# Public: Remove an audit copy token.
|
73
127
|
#
|
74
128
|
# audit_copy_token - The audit copy token from the `create` response.
|
@@ -94,6 +148,14 @@ module Plaid
|
|
94
148
|
property :asset_report_id
|
95
149
|
end
|
96
150
|
|
151
|
+
# Public: The response wrapper for /asset_report/filter.
|
152
|
+
class AssetReportFilterResponse < AssetReportCreateResponse
|
153
|
+
end
|
154
|
+
|
155
|
+
# Public: The response wrapper for /asset_report/refresh.
|
156
|
+
class AssetReportRefreshResponse < AssetReportCreateResponse
|
157
|
+
end
|
158
|
+
|
97
159
|
# Public: The response wrapper for /asset_report/get.
|
98
160
|
class AssetReportGetResponse < Models::BaseResponse
|
99
161
|
##
|
@@ -115,7 +177,7 @@ module Plaid
|
|
115
177
|
property :removed
|
116
178
|
end
|
117
179
|
|
118
|
-
# Public: The response wrapper for /audit_copy/create.
|
180
|
+
# Public: The response wrapper for /asset_report/audit_copy/create.
|
119
181
|
class AuditCopyCreateResponse < Models::BaseResponse
|
120
182
|
##
|
121
183
|
# :attr_reader:
|
@@ -123,7 +185,11 @@ module Plaid
|
|
123
185
|
property :audit_copy_token
|
124
186
|
end
|
125
187
|
|
126
|
-
# Public: The response wrapper for /audit_copy/
|
188
|
+
# Public: The response wrapper for /asset_report/audit_copy/get.
|
189
|
+
class AuditCopyGetResponse < AssetReportGetResponse
|
190
|
+
end
|
191
|
+
|
192
|
+
# Public: The response wrapper for /asset_report/audit_copy/remove.
|
127
193
|
class AuditCopyRemoveResponse < Models::BaseResponse
|
128
194
|
##
|
129
195
|
# :attr_reader:
|
data/lib/plaid/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: plaid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.
|
4
|
+
version: 6.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Edmund Loo
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-11-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: faraday
|