mx-platform-ruby 0.36.0 → 0.38.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -909,6 +909,69 @@ module MxPlatformRuby
909
909
  return data, status_code, headers
910
910
  end
911
911
 
912
+ # Read a Credit Card Product
913
+ # This endpoint returns the specified `credit_card_product` according to the unique GUID.
914
+ # @param credit_card_product_guid [String] The required `credit_card_product_guid` can be found on the `account` object.
915
+ # @param [Hash] opts the optional parameters
916
+ # @return [CreditCardProductResponse]
917
+ def credit_card(credit_card_product_guid, opts = {})
918
+ data, _status_code, _headers = credit_card_with_http_info(credit_card_product_guid, opts)
919
+ data
920
+ end
921
+
922
+ # Read a Credit Card Product
923
+ # This endpoint returns the specified `credit_card_product` according to the unique GUID.
924
+ # @param credit_card_product_guid [String] The required `credit_card_product_guid` can be found on the `account` object.
925
+ # @param [Hash] opts the optional parameters
926
+ # @return [Array<(CreditCardProductResponse, Integer, Hash)>] CreditCardProductResponse data, response status code and response headers
927
+ def credit_card_with_http_info(credit_card_product_guid, opts = {})
928
+ if @api_client.config.debugging
929
+ @api_client.config.logger.debug 'Calling API: MxPlatformApi.credit_card ...'
930
+ end
931
+ # verify the required parameter 'credit_card_product_guid' is set
932
+ if @api_client.config.client_side_validation && credit_card_product_guid.nil?
933
+ fail ArgumentError, "Missing the required parameter 'credit_card_product_guid' when calling MxPlatformApi.credit_card"
934
+ end
935
+ # resource path
936
+ local_var_path = '/credit_card_products/{credit_card_product_guid}'.sub('{' + 'credit_card_product_guid' + '}', CGI.escape(credit_card_product_guid.to_s))
937
+
938
+ # query parameters
939
+ query_params = opts[:query_params] || {}
940
+
941
+ # header parameters
942
+ header_params = opts[:header_params] || {}
943
+ # HTTP header 'Accept' (if needed)
944
+ header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.api.v1+json'])
945
+
946
+ # form parameters
947
+ form_params = opts[:form_params] || {}
948
+
949
+ # http body (model)
950
+ post_body = opts[:debug_body]
951
+
952
+ # return_type
953
+ return_type = opts[:debug_return_type] || 'CreditCardProductResponse'
954
+
955
+ # auth_names
956
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
957
+
958
+ new_options = opts.merge(
959
+ :operation => :"MxPlatformApi.credit_card",
960
+ :header_params => header_params,
961
+ :query_params => query_params,
962
+ :form_params => form_params,
963
+ :body => post_body,
964
+ :auth_names => auth_names,
965
+ :return_type => return_type
966
+ )
967
+
968
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
969
+ if @api_client.config.debugging
970
+ @api_client.config.logger.debug "API called: MxPlatformApi#credit_card\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
971
+ end
972
+ return data, status_code, headers
973
+ end
974
+
912
975
  # Delete category
913
976
  # Use this endpoint to delete a specific custom category according to its unique GUID. The API will respond with an empty object and a status of `204 No Content`.
914
977
  # @param category_guid [String] The unique id for a &#x60;category&#x60;.
@@ -1946,6 +2009,75 @@ module MxPlatformRuby
1946
2009
  return data, status_code, headers
1947
2010
  end
1948
2011
 
2012
+ # Fetch Rewards
2013
+ # Calling this endpoint initiates an aggregation-type event which will gather the member's rewards information, as well as account and transaction information. Rewards data is also gathered with daily background aggregations.
2014
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
2015
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
2016
+ # @param [Hash] opts the optional parameters
2017
+ # @return [MemberResponseBody]
2018
+ def fetch_rewards(user_guid, member_guid, opts = {})
2019
+ data, _status_code, _headers = fetch_rewards_with_http_info(user_guid, member_guid, opts)
2020
+ data
2021
+ end
2022
+
2023
+ # Fetch Rewards
2024
+ # Calling this endpoint initiates an aggregation-type event which will gather the member&#39;s rewards information, as well as account and transaction information. Rewards data is also gathered with daily background aggregations.
2025
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
2026
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
2027
+ # @param [Hash] opts the optional parameters
2028
+ # @return [Array<(MemberResponseBody, Integer, Hash)>] MemberResponseBody data, response status code and response headers
2029
+ def fetch_rewards_with_http_info(user_guid, member_guid, opts = {})
2030
+ if @api_client.config.debugging
2031
+ @api_client.config.logger.debug 'Calling API: MxPlatformApi.fetch_rewards ...'
2032
+ end
2033
+ # verify the required parameter 'user_guid' is set
2034
+ if @api_client.config.client_side_validation && user_guid.nil?
2035
+ fail ArgumentError, "Missing the required parameter 'user_guid' when calling MxPlatformApi.fetch_rewards"
2036
+ end
2037
+ # verify the required parameter 'member_guid' is set
2038
+ if @api_client.config.client_side_validation && member_guid.nil?
2039
+ fail ArgumentError, "Missing the required parameter 'member_guid' when calling MxPlatformApi.fetch_rewards"
2040
+ end
2041
+ # resource path
2042
+ local_var_path = '/users/{user_guid}/members/{member_guid}/fetch_rewards'.sub('{' + 'user_guid' + '}', CGI.escape(user_guid.to_s)).sub('{' + 'member_guid' + '}', CGI.escape(member_guid.to_s))
2043
+
2044
+ # query parameters
2045
+ query_params = opts[:query_params] || {}
2046
+
2047
+ # header parameters
2048
+ header_params = opts[:header_params] || {}
2049
+ # HTTP header 'Accept' (if needed)
2050
+ header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.api.v1+json'])
2051
+
2052
+ # form parameters
2053
+ form_params = opts[:form_params] || {}
2054
+
2055
+ # http body (model)
2056
+ post_body = opts[:debug_body]
2057
+
2058
+ # return_type
2059
+ return_type = opts[:debug_return_type] || 'MemberResponseBody'
2060
+
2061
+ # auth_names
2062
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
2063
+
2064
+ new_options = opts.merge(
2065
+ :operation => :"MxPlatformApi.fetch_rewards",
2066
+ :header_params => header_params,
2067
+ :query_params => query_params,
2068
+ :form_params => form_params,
2069
+ :body => post_body,
2070
+ :auth_names => auth_names,
2071
+ :return_type => return_type
2072
+ )
2073
+
2074
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
2075
+ if @api_client.config.debugging
2076
+ @api_client.config.logger.debug "API called: MxPlatformApi#fetch_rewards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
2077
+ end
2078
+ return data, status_code, headers
2079
+ end
2080
+
1949
2081
  # Fetch statements
1950
2082
  # Use this endpoint to fetch the statements associated with a particular member.
1951
2083
  # @param member_guid [String] The unique id for a &#x60;member&#x60;.
@@ -3674,6 +3806,75 @@ module MxPlatformRuby
3674
3806
  return data, status_code, headers
3675
3807
  end
3676
3808
 
3809
+ # List Rewards
3810
+ # Use this endpoint to list all the `rewards` associated with a specified `member`.
3811
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
3812
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
3813
+ # @param [Hash] opts the optional parameters
3814
+ # @return [RewardsResponseBody]
3815
+ def list_rewards(user_guid, member_guid, opts = {})
3816
+ data, _status_code, _headers = list_rewards_with_http_info(user_guid, member_guid, opts)
3817
+ data
3818
+ end
3819
+
3820
+ # List Rewards
3821
+ # Use this endpoint to list all the &#x60;rewards&#x60; associated with a specified &#x60;member&#x60;.
3822
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
3823
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
3824
+ # @param [Hash] opts the optional parameters
3825
+ # @return [Array<(RewardsResponseBody, Integer, Hash)>] RewardsResponseBody data, response status code and response headers
3826
+ def list_rewards_with_http_info(user_guid, member_guid, opts = {})
3827
+ if @api_client.config.debugging
3828
+ @api_client.config.logger.debug 'Calling API: MxPlatformApi.list_rewards ...'
3829
+ end
3830
+ # verify the required parameter 'user_guid' is set
3831
+ if @api_client.config.client_side_validation && user_guid.nil?
3832
+ fail ArgumentError, "Missing the required parameter 'user_guid' when calling MxPlatformApi.list_rewards"
3833
+ end
3834
+ # verify the required parameter 'member_guid' is set
3835
+ if @api_client.config.client_side_validation && member_guid.nil?
3836
+ fail ArgumentError, "Missing the required parameter 'member_guid' when calling MxPlatformApi.list_rewards"
3837
+ end
3838
+ # resource path
3839
+ local_var_path = '/users/{user_guid}/members/{member_guid}/rewards'.sub('{' + 'user_guid' + '}', CGI.escape(user_guid.to_s)).sub('{' + 'member_guid' + '}', CGI.escape(member_guid.to_s))
3840
+
3841
+ # query parameters
3842
+ query_params = opts[:query_params] || {}
3843
+
3844
+ # header parameters
3845
+ header_params = opts[:header_params] || {}
3846
+ # HTTP header 'Accept' (if needed)
3847
+ header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.api.v1+json'])
3848
+
3849
+ # form parameters
3850
+ form_params = opts[:form_params] || {}
3851
+
3852
+ # http body (model)
3853
+ post_body = opts[:debug_body]
3854
+
3855
+ # return_type
3856
+ return_type = opts[:debug_return_type] || 'RewardsResponseBody'
3857
+
3858
+ # auth_names
3859
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
3860
+
3861
+ new_options = opts.merge(
3862
+ :operation => :"MxPlatformApi.list_rewards",
3863
+ :header_params => header_params,
3864
+ :query_params => query_params,
3865
+ :form_params => form_params,
3866
+ :body => post_body,
3867
+ :auth_names => auth_names,
3868
+ :return_type => return_type
3869
+ )
3870
+
3871
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
3872
+ if @api_client.config.debugging
3873
+ @api_client.config.logger.debug "API called: MxPlatformApi#list_rewards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
3874
+ end
3875
+ return data, status_code, headers
3876
+ end
3877
+
3677
3878
  # List statements by member
3678
3879
  # Use this endpoint to get an array of available statements.
3679
3880
  # @param member_guid [String] The unique id for a &#x60;member&#x60;.
@@ -5393,6 +5594,81 @@ module MxPlatformRuby
5393
5594
  return data, status_code, headers
5394
5595
  end
5395
5596
 
5597
+ # Read Reward
5598
+ # Use this endpoint to read a specific `reward` based on its unique GUID..
5599
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
5600
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
5601
+ # @param reward_guid [String] The unique identifier for the rewards. Defined by MX.
5602
+ # @param [Hash] opts the optional parameters
5603
+ # @return [RewardResponseBody]
5604
+ def read_rewards(user_guid, member_guid, reward_guid, opts = {})
5605
+ data, _status_code, _headers = read_rewards_with_http_info(user_guid, member_guid, reward_guid, opts)
5606
+ data
5607
+ end
5608
+
5609
+ # Read Reward
5610
+ # Use this endpoint to read a specific &#x60;reward&#x60; based on its unique GUID..
5611
+ # @param user_guid [String] The unique id for a &#x60;user&#x60;.
5612
+ # @param member_guid [String] The unique identifier for the member. Defined by MX.
5613
+ # @param reward_guid [String] The unique identifier for the rewards. Defined by MX.
5614
+ # @param [Hash] opts the optional parameters
5615
+ # @return [Array<(RewardResponseBody, Integer, Hash)>] RewardResponseBody data, response status code and response headers
5616
+ def read_rewards_with_http_info(user_guid, member_guid, reward_guid, opts = {})
5617
+ if @api_client.config.debugging
5618
+ @api_client.config.logger.debug 'Calling API: MxPlatformApi.read_rewards ...'
5619
+ end
5620
+ # verify the required parameter 'user_guid' is set
5621
+ if @api_client.config.client_side_validation && user_guid.nil?
5622
+ fail ArgumentError, "Missing the required parameter 'user_guid' when calling MxPlatformApi.read_rewards"
5623
+ end
5624
+ # verify the required parameter 'member_guid' is set
5625
+ if @api_client.config.client_side_validation && member_guid.nil?
5626
+ fail ArgumentError, "Missing the required parameter 'member_guid' when calling MxPlatformApi.read_rewards"
5627
+ end
5628
+ # verify the required parameter 'reward_guid' is set
5629
+ if @api_client.config.client_side_validation && reward_guid.nil?
5630
+ fail ArgumentError, "Missing the required parameter 'reward_guid' when calling MxPlatformApi.read_rewards"
5631
+ end
5632
+ # resource path
5633
+ local_var_path = '/users/{user_guid}/members/{member_guid}/rewards/{reward_guid}'.sub('{' + 'user_guid' + '}', CGI.escape(user_guid.to_s)).sub('{' + 'member_guid' + '}', CGI.escape(member_guid.to_s)).sub('{' + 'reward_guid' + '}', CGI.escape(reward_guid.to_s))
5634
+
5635
+ # query parameters
5636
+ query_params = opts[:query_params] || {}
5637
+
5638
+ # header parameters
5639
+ header_params = opts[:header_params] || {}
5640
+ # HTTP header 'Accept' (if needed)
5641
+ header_params['Accept'] = @api_client.select_header_accept(['application/vnd.mx.api.v1+json'])
5642
+
5643
+ # form parameters
5644
+ form_params = opts[:form_params] || {}
5645
+
5646
+ # http body (model)
5647
+ post_body = opts[:debug_body]
5648
+
5649
+ # return_type
5650
+ return_type = opts[:debug_return_type] || 'RewardResponseBody'
5651
+
5652
+ # auth_names
5653
+ auth_names = opts[:debug_auth_names] || ['basicAuth']
5654
+
5655
+ new_options = opts.merge(
5656
+ :operation => :"MxPlatformApi.read_rewards",
5657
+ :header_params => header_params,
5658
+ :query_params => query_params,
5659
+ :form_params => form_params,
5660
+ :body => post_body,
5661
+ :auth_names => auth_names,
5662
+ :return_type => return_type
5663
+ )
5664
+
5665
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
5666
+ if @api_client.config.debugging
5667
+ @api_client.config.logger.debug "API called: MxPlatformApi#read_rewards\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
5668
+ end
5669
+ return data, status_code, headers
5670
+ end
5671
+
5396
5672
  # Read statement by member
5397
5673
  # Use this endpoint to read a JSON representation of the statement.
5398
5674
  # @param member_guid [String] The unique id for a &#x60;member&#x60;.
@@ -23,6 +23,8 @@ module MxPlatformRuby
23
23
 
24
24
  attr_accessor :loan_guarantor
25
25
 
26
+ attr_accessor :loan_reference_number
27
+
26
28
  attr_accessor :institution_number
27
29
 
28
30
  attr_accessor :member_guid
@@ -31,6 +33,8 @@ module MxPlatformRuby
31
33
 
32
34
  attr_accessor :routing_number
33
35
 
36
+ attr_accessor :sequence_number
37
+
34
38
  attr_accessor :transit_number
35
39
 
36
40
  attr_accessor :user_guid
@@ -42,10 +46,12 @@ module MxPlatformRuby
42
46
  :'account_number' => :'account_number',
43
47
  :'guid' => :'guid',
44
48
  :'loan_guarantor' => :'loan_guarantor',
49
+ :'loan_reference_number' => :'loan_reference_number',
45
50
  :'institution_number' => :'institution_number',
46
51
  :'member_guid' => :'member_guid',
47
52
  :'passed_validation' => :'passed_validation',
48
53
  :'routing_number' => :'routing_number',
54
+ :'sequence_number' => :'sequence_number',
49
55
  :'transit_number' => :'transit_number',
50
56
  :'user_guid' => :'user_guid'
51
57
  }
@@ -63,10 +69,12 @@ module MxPlatformRuby
63
69
  :'account_number' => :'String',
64
70
  :'guid' => :'String',
65
71
  :'loan_guarantor' => :'String',
72
+ :'loan_reference_number' => :'String',
66
73
  :'institution_number' => :'String',
67
74
  :'member_guid' => :'String',
68
75
  :'passed_validation' => :'Boolean',
69
76
  :'routing_number' => :'String',
77
+ :'sequence_number' => :'String',
70
78
  :'transit_number' => :'String',
71
79
  :'user_guid' => :'String'
72
80
  }
@@ -79,10 +87,12 @@ module MxPlatformRuby
79
87
  :'account_number',
80
88
  :'guid',
81
89
  :'loan_guarantor',
90
+ :'loan_reference_number',
82
91
  :'institution_number',
83
92
  :'member_guid',
84
93
  :'passed_validation',
85
94
  :'routing_number',
95
+ :'sequence_number',
86
96
  :'transit_number',
87
97
  :'user_guid'
88
98
  ])
@@ -119,6 +129,10 @@ module MxPlatformRuby
119
129
  self.loan_guarantor = attributes[:'loan_guarantor']
120
130
  end
121
131
 
132
+ if attributes.key?(:'loan_reference_number')
133
+ self.loan_reference_number = attributes[:'loan_reference_number']
134
+ end
135
+
122
136
  if attributes.key?(:'institution_number')
123
137
  self.institution_number = attributes[:'institution_number']
124
138
  end
@@ -135,6 +149,10 @@ module MxPlatformRuby
135
149
  self.routing_number = attributes[:'routing_number']
136
150
  end
137
151
 
152
+ if attributes.key?(:'sequence_number')
153
+ self.sequence_number = attributes[:'sequence_number']
154
+ end
155
+
138
156
  if attributes.key?(:'transit_number')
139
157
  self.transit_number = attributes[:'transit_number']
140
158
  end
@@ -168,10 +186,12 @@ module MxPlatformRuby
168
186
  account_number == o.account_number &&
169
187
  guid == o.guid &&
170
188
  loan_guarantor == o.loan_guarantor &&
189
+ loan_reference_number == o.loan_reference_number &&
171
190
  institution_number == o.institution_number &&
172
191
  member_guid == o.member_guid &&
173
192
  passed_validation == o.passed_validation &&
174
193
  routing_number == o.routing_number &&
194
+ sequence_number == o.sequence_number &&
175
195
  transit_number == o.transit_number &&
176
196
  user_guid == o.user_guid
177
197
  end
@@ -185,7 +205,7 @@ module MxPlatformRuby
185
205
  # Calculates hash code according to all attributes.
186
206
  # @return [Integer] Hash code
187
207
  def hash
188
- [account_guid, account_number, guid, loan_guarantor, institution_number, member_guid, passed_validation, routing_number, transit_number, user_guid].hash
208
+ [account_guid, account_number, guid, loan_guarantor, loan_reference_number, institution_number, member_guid, passed_validation, routing_number, sequence_number, transit_number, user_guid].hash
189
209
  end
190
210
 
191
211
  # Builds the object from hash