atrium-ruby 2.3.0 → 2.4.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/README.md +6 -4
- data/docs/AccountsApi.md +2 -2
- data/docs/InstitutionsApi.md +1 -1
- data/docs/MembersApi.md +43 -53
- data/docs/Statement.md +2 -4
- data/docs/StatementsApi.md +88 -0
- data/docs/TransactionsApi.md +1 -1
- data/docs/UsersApi.md +1 -1
- data/lib/atrium-ruby.rb +1 -0
- data/lib/atrium-ruby/api/atrium_client.rb +2 -0
- data/lib/atrium-ruby/api/members_api.rb +58 -65
- data/lib/atrium-ruby/api/statements_api.rb +146 -0
- data/lib/atrium-ruby/models/statement.rb +21 -41
- data/lib/atrium-ruby/version.rb +1 -1
- data/spec/api/members_api_spec.rb +13 -16
- data/spec/api/statements_api_spec.rb +58 -0
- data/spec/models/statement_spec.rb +4 -16
- metadata +29 -25
@@ -7,6 +7,7 @@ module Atrium
|
|
7
7
|
attr_accessor :institutions
|
8
8
|
attr_accessor :members
|
9
9
|
attr_accessor :merchants
|
10
|
+
attr_accessor :statements
|
10
11
|
attr_accessor :transactions
|
11
12
|
attr_accessor :users
|
12
13
|
attr_accessor :verification
|
@@ -24,6 +25,7 @@ module Atrium
|
|
24
25
|
@institutions = Atrium::InstitutionsApi.new()
|
25
26
|
@members = Atrium::MembersApi.new()
|
26
27
|
@merchants = Atrium::MerchantsApi.new()
|
28
|
+
@statements = Atrium::StatementsApi.new()
|
27
29
|
@transactions = Atrium::TransactionsApi.new()
|
28
30
|
@users = Atrium::UsersApi.new()
|
29
31
|
@verification = Atrium::VerificationApi.new()
|
@@ -20,7 +20,6 @@ module Atrium
|
|
20
20
|
# @param member_guid The unique identifier for a `member`.
|
21
21
|
# @param user_guid The unique identifier for a `user`.
|
22
22
|
# @param [Hash] opts the optional parameters
|
23
|
-
# @option opts [String] :type An optional parameter which determines the type of aggregation to be peformed. Possible values are `statement` and `history`.
|
24
23
|
# @return [MemberResponseBody]
|
25
24
|
def aggregate_member(member_guid, user_guid, opts = {})
|
26
25
|
data, _status_code, _headers = aggregate_member_with_http_info(member_guid, user_guid, opts)
|
@@ -49,6 +48,17 @@ module Atrium
|
|
49
48
|
nil
|
50
49
|
end
|
51
50
|
|
51
|
+
# Extend history
|
52
|
+
# The extend_history endpoint begins the process of fetching up to 24 months of data associated with a particular `member`.
|
53
|
+
# @param member_guid The unique identifier for a `member`.
|
54
|
+
# @param user_guid The unique identifier for a `user`.
|
55
|
+
# @param [Hash] opts the optional parameters
|
56
|
+
# @return [MemberResponseBody]
|
57
|
+
def extend_history(member_guid, user_guid, opts = {})
|
58
|
+
data, _status_code, _headers = extend_history_with_http_info(member_guid, user_guid, opts)
|
59
|
+
data
|
60
|
+
end
|
61
|
+
|
52
62
|
# List member accounts
|
53
63
|
# This endpoint returns an array with information about every account associated with a particular member.
|
54
64
|
# @param member_guid The unique identifier for a `member`.
|
@@ -84,19 +94,6 @@ module Atrium
|
|
84
94
|
data
|
85
95
|
end
|
86
96
|
|
87
|
-
# List member statements
|
88
|
-
# Certain institutions in Atrium allow developers to access account statements associated with a particular `member`. Use this endpoint to get an array of available statements. Before this endpoint can be used, an aggregation of type `statement` should be performed on the relevant `member`.
|
89
|
-
# @param member_guid The unique identifier for a `member`.
|
90
|
-
# @param user_guid The unique identifier for a `user`.
|
91
|
-
# @param [Hash] opts the optional parameters
|
92
|
-
# @option opts [Integer] :page Specify current page.
|
93
|
-
# @option opts [Integer] :records_per_page Specify records per page.
|
94
|
-
# @return [StatementsResponseBody]
|
95
|
-
def list_member_statements(member_guid, user_guid, opts = {})
|
96
|
-
data, _status_code, _headers = list_member_statements_with_http_info(member_guid, user_guid, opts)
|
97
|
-
data
|
98
|
-
end
|
99
|
-
|
100
97
|
# List member transactions
|
101
98
|
# Use this endpoint to get all transactions from all accounts associated with a specific member.<br> This endpoint accepts optional URL query parameters — from_date and to_date — which are used to filter transactions according to the date they were posted. If no values are given for the query parameters, from_date will default to 90 days prior to the request and to_date will default to 5 days from the time of the request.
|
102
99
|
# @param member_guid The unique identifier for a `member`.
|
@@ -178,7 +175,6 @@ module Atrium
|
|
178
175
|
# @param member_guid The unique identifier for a `member`.
|
179
176
|
# @param user_guid The unique identifier for a `user`.
|
180
177
|
# @param [Hash] opts the optional parameters
|
181
|
-
# @option opts [String] :type An optional parameter which determines the type of aggregation to be peformed. Possible values are `statement` and `history`.
|
182
178
|
# @return [Array<(MemberResponseBody, Fixnum, Hash)>] MemberResponseBody data, response status code and response headers
|
183
179
|
def aggregate_member_with_http_info(member_guid, user_guid, opts = {})
|
184
180
|
if @api_client.config.debugging
|
@@ -197,7 +193,6 @@ module Atrium
|
|
197
193
|
|
198
194
|
# query parameters
|
199
195
|
query_params = {}
|
200
|
-
query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
|
201
196
|
|
202
197
|
# header parameters
|
203
198
|
header_params = {}
|
@@ -319,38 +314,36 @@ module Atrium
|
|
319
314
|
end
|
320
315
|
return data, status_code, headers
|
321
316
|
end
|
322
|
-
#
|
323
|
-
#
|
317
|
+
# Extend history
|
318
|
+
# The extend_history endpoint begins the process of fetching up to 24 months of data associated with a particular `member`.
|
324
319
|
# @param member_guid The unique identifier for a `member`.
|
325
320
|
# @param user_guid The unique identifier for a `user`.
|
326
321
|
# @param [Hash] opts the optional parameters
|
327
|
-
# @
|
328
|
-
|
329
|
-
# @return [Array<(AccountsResponseBody, Fixnum, Hash)>] AccountsResponseBody data, response status code and response headers
|
330
|
-
def list_member_accounts_with_http_info(member_guid, user_guid, opts = {})
|
322
|
+
# @return [Array<(MemberResponseBody, Fixnum, Hash)>] MemberResponseBody data, response status code and response headers
|
323
|
+
def extend_history_with_http_info(member_guid, user_guid, opts = {})
|
331
324
|
if @api_client.config.debugging
|
332
|
-
@api_client.config.logger.debug 'Calling API: MembersApi.
|
325
|
+
@api_client.config.logger.debug 'Calling API: MembersApi.extend_history ...'
|
333
326
|
end
|
334
327
|
# verify the required parameter 'member_guid' is set
|
335
328
|
if @api_client.config.client_side_validation && member_guid.nil?
|
336
|
-
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.
|
329
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.extend_history"
|
337
330
|
end
|
338
331
|
# verify the required parameter 'user_guid' is set
|
339
332
|
if @api_client.config.client_side_validation && user_guid.nil?
|
340
|
-
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.
|
333
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.extend_history"
|
341
334
|
end
|
342
335
|
# resource path
|
343
|
-
local_var_path = '/users/{user_guid}/members/{member_guid}/
|
336
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/extend_history'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
344
337
|
|
345
338
|
# query parameters
|
346
339
|
query_params = {}
|
347
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
348
|
-
query_params[:'records_per_page'] = opts[:'records_per_page'] if !opts[:'records_per_page'].nil?
|
349
340
|
|
350
341
|
# header parameters
|
351
342
|
header_params = {}
|
352
343
|
# HTTP header 'Accept' (if needed)
|
353
344
|
header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.atrium.v1+json'])
|
345
|
+
# HTTP header 'Content-Type'
|
346
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
354
347
|
|
355
348
|
# form parameters
|
356
349
|
form_params = {}
|
@@ -358,41 +351,45 @@ module Atrium
|
|
358
351
|
# http body (model)
|
359
352
|
post_body = nil
|
360
353
|
auth_names = ['apiKey', 'clientID']
|
361
|
-
data, status_code, headers = @api_client.call_api(:
|
354
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
362
355
|
:header_params => header_params,
|
363
356
|
:query_params => query_params,
|
364
357
|
:form_params => form_params,
|
365
358
|
:body => post_body,
|
366
359
|
:auth_names => auth_names,
|
367
|
-
:return_type => '
|
360
|
+
:return_type => 'MemberResponseBody')
|
368
361
|
if @api_client.config.debugging
|
369
|
-
@api_client.config.logger.debug "API called: MembersApi#
|
362
|
+
@api_client.config.logger.debug "API called: MembersApi#extend_history\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
370
363
|
end
|
371
364
|
return data, status_code, headers
|
372
365
|
end
|
373
|
-
# List member
|
374
|
-
# This endpoint returns an array
|
366
|
+
# List member accounts
|
367
|
+
# This endpoint returns an array with information about every account associated with a particular member.
|
375
368
|
# @param member_guid The unique identifier for a `member`.
|
376
369
|
# @param user_guid The unique identifier for a `user`.
|
377
370
|
# @param [Hash] opts the optional parameters
|
378
|
-
# @
|
379
|
-
|
371
|
+
# @option opts [Integer] :page Specify current page.
|
372
|
+
# @option opts [Integer] :records_per_page Specify records per page.
|
373
|
+
# @return [Array<(AccountsResponseBody, Fixnum, Hash)>] AccountsResponseBody data, response status code and response headers
|
374
|
+
def list_member_accounts_with_http_info(member_guid, user_guid, opts = {})
|
380
375
|
if @api_client.config.debugging
|
381
|
-
@api_client.config.logger.debug 'Calling API: MembersApi.
|
376
|
+
@api_client.config.logger.debug 'Calling API: MembersApi.list_member_accounts ...'
|
382
377
|
end
|
383
378
|
# verify the required parameter 'member_guid' is set
|
384
379
|
if @api_client.config.client_side_validation && member_guid.nil?
|
385
|
-
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.
|
380
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.list_member_accounts"
|
386
381
|
end
|
387
382
|
# verify the required parameter 'user_guid' is set
|
388
383
|
if @api_client.config.client_side_validation && user_guid.nil?
|
389
|
-
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.
|
384
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.list_member_accounts"
|
390
385
|
end
|
391
386
|
# resource path
|
392
|
-
local_var_path = '/users/{user_guid}/members/{member_guid}/
|
387
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/accounts'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
393
388
|
|
394
389
|
# query parameters
|
395
390
|
query_params = {}
|
391
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
392
|
+
query_params[:'records_per_page'] = opts[:'records_per_page'] if !opts[:'records_per_page'].nil?
|
396
393
|
|
397
394
|
# header parameters
|
398
395
|
header_params = {}
|
@@ -411,32 +408,32 @@ module Atrium
|
|
411
408
|
:form_params => form_params,
|
412
409
|
:body => post_body,
|
413
410
|
:auth_names => auth_names,
|
414
|
-
:return_type => '
|
411
|
+
:return_type => 'AccountsResponseBody')
|
415
412
|
if @api_client.config.debugging
|
416
|
-
@api_client.config.logger.debug "API called: MembersApi#
|
413
|
+
@api_client.config.logger.debug "API called: MembersApi#list_member_accounts\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
417
414
|
end
|
418
415
|
return data, status_code, headers
|
419
416
|
end
|
420
|
-
# List member
|
421
|
-
#
|
417
|
+
# List member credentials
|
418
|
+
# This endpoint returns an array which contains information on every non-MFA credential associated with a specific member.
|
422
419
|
# @param member_guid The unique identifier for a `member`.
|
423
420
|
# @param user_guid The unique identifier for a `user`.
|
424
421
|
# @param [Hash] opts the optional parameters
|
425
|
-
# @return [Array<(
|
426
|
-
def
|
422
|
+
# @return [Array<(CredentialsResponseBody, Fixnum, Hash)>] CredentialsResponseBody data, response status code and response headers
|
423
|
+
def list_member_credentials_with_http_info(member_guid, user_guid, opts = {})
|
427
424
|
if @api_client.config.debugging
|
428
|
-
@api_client.config.logger.debug 'Calling API: MembersApi.
|
425
|
+
@api_client.config.logger.debug 'Calling API: MembersApi.list_member_credentials ...'
|
429
426
|
end
|
430
427
|
# verify the required parameter 'member_guid' is set
|
431
428
|
if @api_client.config.client_side_validation && member_guid.nil?
|
432
|
-
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.
|
429
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.list_member_credentials"
|
433
430
|
end
|
434
431
|
# verify the required parameter 'user_guid' is set
|
435
432
|
if @api_client.config.client_side_validation && user_guid.nil?
|
436
|
-
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.
|
433
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.list_member_credentials"
|
437
434
|
end
|
438
435
|
# resource path
|
439
|
-
local_var_path = '/users/{user_guid}/members/{member_guid}/
|
436
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/credentials'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
440
437
|
|
441
438
|
# query parameters
|
442
439
|
query_params = {}
|
@@ -458,39 +455,35 @@ module Atrium
|
|
458
455
|
:form_params => form_params,
|
459
456
|
:body => post_body,
|
460
457
|
:auth_names => auth_names,
|
461
|
-
:return_type => '
|
458
|
+
:return_type => 'CredentialsResponseBody')
|
462
459
|
if @api_client.config.debugging
|
463
|
-
@api_client.config.logger.debug "API called: MembersApi#
|
460
|
+
@api_client.config.logger.debug "API called: MembersApi#list_member_credentials\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
464
461
|
end
|
465
462
|
return data, status_code, headers
|
466
463
|
end
|
467
|
-
# List member
|
468
|
-
#
|
464
|
+
# List member MFA challenges
|
465
|
+
# Use this endpoint for information on what multi-factor authentication challenges need to be answered in order to aggregate a member.<br> If the aggregation is not challenged, i.e., the member does not have a connection status of CHALLENGED, then code 204 No Content will be returned.<br> If the aggregation has been challenged, i.e., the member does have a connection status of CHALLENGED, then code 200 OK will be returned — along with the corresponding credentials.
|
469
466
|
# @param member_guid The unique identifier for a `member`.
|
470
467
|
# @param user_guid The unique identifier for a `user`.
|
471
468
|
# @param [Hash] opts the optional parameters
|
472
|
-
# @
|
473
|
-
|
474
|
-
# @return [Array<(StatementsResponseBody, Fixnum, Hash)>] StatementsResponseBody data, response status code and response headers
|
475
|
-
def list_member_statements_with_http_info(member_guid, user_guid, opts = {})
|
469
|
+
# @return [Array<(ChallengesResponseBody, Fixnum, Hash)>] ChallengesResponseBody data, response status code and response headers
|
470
|
+
def list_member_mfa_challenges_with_http_info(member_guid, user_guid, opts = {})
|
476
471
|
if @api_client.config.debugging
|
477
|
-
@api_client.config.logger.debug 'Calling API: MembersApi.
|
472
|
+
@api_client.config.logger.debug 'Calling API: MembersApi.list_member_mfa_challenges ...'
|
478
473
|
end
|
479
474
|
# verify the required parameter 'member_guid' is set
|
480
475
|
if @api_client.config.client_side_validation && member_guid.nil?
|
481
|
-
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.
|
476
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling MembersApi.list_member_mfa_challenges"
|
482
477
|
end
|
483
478
|
# verify the required parameter 'user_guid' is set
|
484
479
|
if @api_client.config.client_side_validation && user_guid.nil?
|
485
|
-
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.
|
480
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling MembersApi.list_member_mfa_challenges"
|
486
481
|
end
|
487
482
|
# resource path
|
488
|
-
local_var_path = '/users/{user_guid}/members/{member_guid}/
|
483
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/challenges'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
489
484
|
|
490
485
|
# query parameters
|
491
486
|
query_params = {}
|
492
|
-
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
493
|
-
query_params[:'records_per_page'] = opts[:'records_per_page'] if !opts[:'records_per_page'].nil?
|
494
487
|
|
495
488
|
# header parameters
|
496
489
|
header_params = {}
|
@@ -509,9 +502,9 @@ module Atrium
|
|
509
502
|
:form_params => form_params,
|
510
503
|
:body => post_body,
|
511
504
|
:auth_names => auth_names,
|
512
|
-
:return_type => '
|
505
|
+
:return_type => 'ChallengesResponseBody')
|
513
506
|
if @api_client.config.debugging
|
514
|
-
@api_client.config.logger.debug "API called: MembersApi#
|
507
|
+
@api_client.config.logger.debug "API called: MembersApi#list_member_mfa_challenges\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
515
508
|
end
|
516
509
|
return data, status_code, headers
|
517
510
|
end
|
@@ -0,0 +1,146 @@
|
|
1
|
+
=begin
|
2
|
+
#MX API
|
3
|
+
|
4
|
+
#The MX Atrium API supports over 48,000 data connections to thousands of financial institutions. It provides secure access to your users' accounts and transactions with industry-leading cleansing, categorization, and classification. Atrium is designed according to resource-oriented REST architecture and responds with JSON bodies and HTTP response codes. Use Atrium's development environment, vestibule.mx.com, to quickly get up and running. The development environment limits are 100 users, 25 members per user, and access to the top 15 institutions. Contact MX to purchase production access.
|
5
|
+
|
6
|
+
|
7
|
+
=end
|
8
|
+
|
9
|
+
require 'uri'
|
10
|
+
|
11
|
+
module Atrium
|
12
|
+
class StatementsApi
|
13
|
+
attr_accessor :api_client
|
14
|
+
|
15
|
+
def initialize(api_client = ApiClient.default)
|
16
|
+
@api_client = api_client
|
17
|
+
end
|
18
|
+
# Fetch statements
|
19
|
+
# The fetch statements endpoint begins fetching statements for a member.
|
20
|
+
# @param member_guid The unique identifier for a `member`.
|
21
|
+
# @param user_guid The unique identifier for a `user`.
|
22
|
+
# @param [Hash] opts the optional parameters
|
23
|
+
# @return [MemberResponseBody]
|
24
|
+
def fetch_statements(member_guid, user_guid, opts = {})
|
25
|
+
data, _status_code, _headers = fetch_statements_with_http_info(member_guid, user_guid, opts)
|
26
|
+
data
|
27
|
+
end
|
28
|
+
|
29
|
+
# List member statements
|
30
|
+
# Certain institutions in Atrium allow developers to access account statements associated with a particular `member`. Use this endpoint to get an array of available statements. Before this endpoint can be used, `fetch_statements` should be performed on the relevant `member`.
|
31
|
+
# @param member_guid The unique identifier for a `member`.
|
32
|
+
# @param user_guid The unique identifier for a `user`.
|
33
|
+
# @param [Hash] opts the optional parameters
|
34
|
+
# @option opts [Integer] :page Specify current page.
|
35
|
+
# @option opts [Integer] :records_per_page Specify records per page.
|
36
|
+
# @return [StatementsResponseBody]
|
37
|
+
def list_member_statements(member_guid, user_guid, opts = {})
|
38
|
+
data, _status_code, _headers = list_member_statements_with_http_info(member_guid, user_guid, opts)
|
39
|
+
data
|
40
|
+
end
|
41
|
+
|
42
|
+
|
43
|
+
private
|
44
|
+
|
45
|
+
# Fetch statements
|
46
|
+
# The fetch statements endpoint begins fetching statements for a member.
|
47
|
+
# @param member_guid The unique identifier for a `member`.
|
48
|
+
# @param user_guid The unique identifier for a `user`.
|
49
|
+
# @param [Hash] opts the optional parameters
|
50
|
+
# @return [Array<(MemberResponseBody, Fixnum, Hash)>] MemberResponseBody data, response status code and response headers
|
51
|
+
def fetch_statements_with_http_info(member_guid, user_guid, opts = {})
|
52
|
+
if @api_client.config.debugging
|
53
|
+
@api_client.config.logger.debug 'Calling API: StatementsApi.fetch_statements ...'
|
54
|
+
end
|
55
|
+
# verify the required parameter 'member_guid' is set
|
56
|
+
if @api_client.config.client_side_validation && member_guid.nil?
|
57
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling StatementsApi.fetch_statements"
|
58
|
+
end
|
59
|
+
# verify the required parameter 'user_guid' is set
|
60
|
+
if @api_client.config.client_side_validation && user_guid.nil?
|
61
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling StatementsApi.fetch_statements"
|
62
|
+
end
|
63
|
+
# resource path
|
64
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/fetch_statements'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
65
|
+
|
66
|
+
# query parameters
|
67
|
+
query_params = {}
|
68
|
+
|
69
|
+
# header parameters
|
70
|
+
header_params = {}
|
71
|
+
# HTTP header 'Accept' (if needed)
|
72
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.atrium.v1+json'])
|
73
|
+
# HTTP header 'Content-Type'
|
74
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
75
|
+
|
76
|
+
# form parameters
|
77
|
+
form_params = {}
|
78
|
+
|
79
|
+
# http body (model)
|
80
|
+
post_body = nil
|
81
|
+
auth_names = ['apiKey', 'clientID']
|
82
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path,
|
83
|
+
:header_params => header_params,
|
84
|
+
:query_params => query_params,
|
85
|
+
:form_params => form_params,
|
86
|
+
:body => post_body,
|
87
|
+
:auth_names => auth_names,
|
88
|
+
:return_type => 'MemberResponseBody')
|
89
|
+
if @api_client.config.debugging
|
90
|
+
@api_client.config.logger.debug "API called: StatementsApi#fetch_statements\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
91
|
+
end
|
92
|
+
return data, status_code, headers
|
93
|
+
end
|
94
|
+
# List member statements
|
95
|
+
# Certain institutions in Atrium allow developers to access account statements associated with a particular `member`. Use this endpoint to get an array of available statements. Before this endpoint can be used, `fetch_statements` should be performed on the relevant `member`.
|
96
|
+
# @param member_guid The unique identifier for a `member`.
|
97
|
+
# @param user_guid The unique identifier for a `user`.
|
98
|
+
# @param [Hash] opts the optional parameters
|
99
|
+
# @option opts [Integer] :page Specify current page.
|
100
|
+
# @option opts [Integer] :records_per_page Specify records per page.
|
101
|
+
# @return [Array<(StatementsResponseBody, Fixnum, Hash)>] StatementsResponseBody data, response status code and response headers
|
102
|
+
def list_member_statements_with_http_info(member_guid, user_guid, opts = {})
|
103
|
+
if @api_client.config.debugging
|
104
|
+
@api_client.config.logger.debug 'Calling API: StatementsApi.list_member_statements ...'
|
105
|
+
end
|
106
|
+
# verify the required parameter 'member_guid' is set
|
107
|
+
if @api_client.config.client_side_validation && member_guid.nil?
|
108
|
+
fail ArgumentError, "Missing the required parameter 'member_guid' when calling StatementsApi.list_member_statements"
|
109
|
+
end
|
110
|
+
# verify the required parameter 'user_guid' is set
|
111
|
+
if @api_client.config.client_side_validation && user_guid.nil?
|
112
|
+
fail ArgumentError, "Missing the required parameter 'user_guid' when calling StatementsApi.list_member_statements"
|
113
|
+
end
|
114
|
+
# resource path
|
115
|
+
local_var_path = '/users/{user_guid}/members/{member_guid}/statements'.sub('{' + 'member_guid' + '}', member_guid.to_s).sub('{' + 'user_guid' + '}', user_guid.to_s)
|
116
|
+
|
117
|
+
# query parameters
|
118
|
+
query_params = {}
|
119
|
+
query_params[:'page'] = opts[:'page'] if !opts[:'page'].nil?
|
120
|
+
query_params[:'records_per_page'] = opts[:'records_per_page'] if !opts[:'records_per_page'].nil?
|
121
|
+
|
122
|
+
# header parameters
|
123
|
+
header_params = {}
|
124
|
+
# HTTP header 'Accept' (if needed)
|
125
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.atrium.v1+json'])
|
126
|
+
|
127
|
+
# form parameters
|
128
|
+
form_params = {}
|
129
|
+
|
130
|
+
# http body (model)
|
131
|
+
post_body = nil
|
132
|
+
auth_names = ['apiKey', 'clientID']
|
133
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
134
|
+
:header_params => header_params,
|
135
|
+
:query_params => query_params,
|
136
|
+
:form_params => form_params,
|
137
|
+
:body => post_body,
|
138
|
+
:auth_names => auth_names,
|
139
|
+
:return_type => 'StatementsResponseBody')
|
140
|
+
if @api_client.config.debugging
|
141
|
+
@api_client.config.logger.debug "API called: StatementsApi#list_member_statements\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
142
|
+
end
|
143
|
+
return data, status_code, headers
|
144
|
+
end
|
145
|
+
end
|
146
|
+
end
|
@@ -16,20 +16,11 @@ module Atrium
|
|
16
16
|
# The date and time the `statement` was created.
|
17
17
|
attr_accessor :created_at
|
18
18
|
|
19
|
-
# An SHA-256 hash value of the statement's byte payload, used as a unique identifier.
|
20
|
-
attr_accessor :content_hash
|
21
|
-
|
22
|
-
# The date and time the `statement` was deleted. Statements are automatically deleted when an `account` is deleted.
|
23
|
-
attr_accessor :deleted_at
|
24
|
-
|
25
19
|
# The unique identifier for the `statement`. Defined by MX.
|
26
20
|
attr_accessor :guid
|
27
21
|
|
28
|
-
#
|
29
|
-
attr_accessor :
|
30
|
-
|
31
|
-
# The date and time at which the `statement` was last updated.
|
32
|
-
attr_accessor :updated_at
|
22
|
+
# The unique identifier for the `member` associated with the `statement`. Defined by MX.
|
23
|
+
attr_accessor :member_guid
|
33
24
|
|
34
25
|
# A URI for accessing the byte payload of the `statement`.
|
35
26
|
attr_accessor :uri
|
@@ -37,18 +28,19 @@ module Atrium
|
|
37
28
|
# The unique identifier for the `user` associated with the `statement`. Defined by MX.
|
38
29
|
attr_accessor :user_guid
|
39
30
|
|
31
|
+
# The date and time at which the `statement` was last updated.
|
32
|
+
attr_accessor :updated_at
|
33
|
+
|
40
34
|
# Attribute mapping from ruby-style variable name to JSON key.
|
41
35
|
def self.attribute_map
|
42
36
|
{
|
43
37
|
:'account_guid' => :'account_guid',
|
44
38
|
:'created_at' => :'created_at',
|
45
|
-
:'content_hash' => :'content_hash',
|
46
|
-
:'deleted_at' => :'deleted_at',
|
47
39
|
:'guid' => :'guid',
|
48
|
-
:'
|
49
|
-
:'updated_at' => :'updated_at',
|
40
|
+
:'member_guid' => :'member_guid',
|
50
41
|
:'uri' => :'uri',
|
51
|
-
:'user_guid' => :'user_guid'
|
42
|
+
:'user_guid' => :'user_guid',
|
43
|
+
:'updated_at' => :'updated_at'
|
52
44
|
}
|
53
45
|
end
|
54
46
|
|
@@ -57,13 +49,11 @@ module Atrium
|
|
57
49
|
{
|
58
50
|
:'account_guid' => :'String',
|
59
51
|
:'created_at' => :'String',
|
60
|
-
:'content_hash' => :'String',
|
61
|
-
:'deleted_at' => :'String',
|
62
52
|
:'guid' => :'String',
|
63
|
-
:'
|
64
|
-
:'updated_at' => :'String',
|
53
|
+
:'member_guid' => :'String',
|
65
54
|
:'uri' => :'String',
|
66
|
-
:'user_guid' => :'String'
|
55
|
+
:'user_guid' => :'String',
|
56
|
+
:'updated_at' => :'String'
|
67
57
|
}
|
68
58
|
end
|
69
59
|
|
@@ -83,24 +73,12 @@ module Atrium
|
|
83
73
|
self.created_at = attributes[:'created_at']
|
84
74
|
end
|
85
75
|
|
86
|
-
if attributes.has_key?(:'content_hash')
|
87
|
-
self.content_hash = attributes[:'content_hash']
|
88
|
-
end
|
89
|
-
|
90
|
-
if attributes.has_key?(:'deleted_at')
|
91
|
-
self.deleted_at = attributes[:'deleted_at']
|
92
|
-
end
|
93
|
-
|
94
76
|
if attributes.has_key?(:'guid')
|
95
77
|
self.guid = attributes[:'guid']
|
96
78
|
end
|
97
79
|
|
98
|
-
if attributes.has_key?(:'
|
99
|
-
self.
|
100
|
-
end
|
101
|
-
|
102
|
-
if attributes.has_key?(:'updated_at')
|
103
|
-
self.updated_at = attributes[:'updated_at']
|
80
|
+
if attributes.has_key?(:'member_guid')
|
81
|
+
self.member_guid = attributes[:'member_guid']
|
104
82
|
end
|
105
83
|
|
106
84
|
if attributes.has_key?(:'uri')
|
@@ -110,6 +88,10 @@ module Atrium
|
|
110
88
|
if attributes.has_key?(:'user_guid')
|
111
89
|
self.user_guid = attributes[:'user_guid']
|
112
90
|
end
|
91
|
+
|
92
|
+
if attributes.has_key?(:'updated_at')
|
93
|
+
self.updated_at = attributes[:'updated_at']
|
94
|
+
end
|
113
95
|
end
|
114
96
|
|
115
97
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -132,13 +114,11 @@ module Atrium
|
|
132
114
|
self.class == o.class &&
|
133
115
|
account_guid == o.account_guid &&
|
134
116
|
created_at == o.created_at &&
|
135
|
-
content_hash == o.content_hash &&
|
136
|
-
deleted_at == o.deleted_at &&
|
137
117
|
guid == o.guid &&
|
138
|
-
|
139
|
-
updated_at == o.updated_at &&
|
118
|
+
member_guid == o.member_guid &&
|
140
119
|
uri == o.uri &&
|
141
|
-
user_guid == o.user_guid
|
120
|
+
user_guid == o.user_guid &&
|
121
|
+
updated_at == o.updated_at
|
142
122
|
end
|
143
123
|
|
144
124
|
# @see the `==` method
|
@@ -150,7 +130,7 @@ module Atrium
|
|
150
130
|
# Calculates hash code according to all attributes.
|
151
131
|
# @return [Fixnum] Hash code
|
152
132
|
def hash
|
153
|
-
[account_guid, created_at,
|
133
|
+
[account_guid, created_at, guid, member_guid, uri, user_guid, updated_at].hash
|
154
134
|
end
|
155
135
|
|
156
136
|
# Builds the object from hash
|