Class: BudgeaClient::RecipientsApi

Inherits:
Object
  • Object
show all
Defined in:
lib/budgea_client/api/recipients_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ RecipientsApi

Returns a new instance of RecipientsApi.



19
20
21
# File 'lib/budgea_client/api/recipients_api.rb', line 19

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/budgea_client/api/recipients_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#users_id_user_accounts_id_account_recipients_post(id_user, id_account, opts = {}) ⇒ Recipient

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted

Parameters:

  • id_user

    Hint: you can use 'me' or 'all'

  • id_account
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:



32
33
34
35
# File 'lib/budgea_client/api/recipients_api.rb', line 32

def (id_user, , opts = {})
  data, _status_code, _headers = (id_user, , opts)
  data
end

#users_id_user_accounts_id_account_recipients_post_with_http_info(id_user, id_account, opts = {}) ⇒ Array<(Recipient, Fixnum, Hash)>

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted&lt;br&gt;&lt;br&gt;

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • id_account
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:

  • (Array<(Recipient, Fixnum, Hash)>)

    Recipient data, response status code and response headers



47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
# File 'lib/budgea_client/api/recipients_api.rb', line 47

def (id_user, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: RecipientsApi.users_id_user_accounts_id_account_recipients_post ...'
  end
  # verify the required parameter 'id_user' is set
  if @api_client.config.client_side_validation && id_user.nil?
    fail ArgumentError, "Missing the required parameter 'id_user' when calling RecipientsApi.users_id_user_accounts_id_account_recipients_post"
  end
  # verify the required parameter 'id_account' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'id_account' when calling RecipientsApi.users_id_user_accounts_id_account_recipients_post"
  end
  # resource path
  local_var_path = '/users/{id_user}/accounts/{id_account}/recipients'.sub('{' + 'id_user' + '}', id_user.to_s).sub('{' + 'id_account' + '}', .to_s)

  # query parameters
  query_params = {}
  query_params[:'background'] = opts[:'background'] if !opts[:'background'].nil?
  query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded'])

  # form parameters
  form_params = {}
  form_params['label'] = opts[:'label'] if !opts[:'label'].nil?
  form_params['iban'] = opts[:'iban'] if !opts[:'iban'].nil?

  # http body (model)
  post_body = nil
  auth_names = ['api_key']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Recipient')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: RecipientsApi#users_id_user_accounts_id_account_recipients_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#users_id_user_connections_id_connection_accounts_id_account_recipients_post(id_user, id_connection, id_account, opts = {}) ⇒ Recipient

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • id_connection
  • id_account
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:



105
106
107
108
# File 'lib/budgea_client/api/recipients_api.rb', line 105

def (id_user, id_connection, , opts = {})
  data, _status_code, _headers = (id_user, id_connection, , opts)
  data
end

#users_id_user_connections_id_connection_accounts_id_account_recipients_post_with_http_info(id_user, id_connection, id_account, opts = {}) ⇒ Array<(Recipient, Fixnum, Hash)>

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted&lt;br&gt;&lt;br&gt;

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • id_connection
  • id_account
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:

  • (Array<(Recipient, Fixnum, Hash)>)

    Recipient data, response status code and response headers



121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
# File 'lib/budgea_client/api/recipients_api.rb', line 121

def (id_user, id_connection, , opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: RecipientsApi.users_id_user_connections_id_connection_accounts_id_account_recipients_post ...'
  end
  # verify the required parameter 'id_user' is set
  if @api_client.config.client_side_validation && id_user.nil?
    fail ArgumentError, "Missing the required parameter 'id_user' when calling RecipientsApi.users_id_user_connections_id_connection_accounts_id_account_recipients_post"
  end
  # verify the required parameter 'id_connection' is set
  if @api_client.config.client_side_validation && id_connection.nil?
    fail ArgumentError, "Missing the required parameter 'id_connection' when calling RecipientsApi.users_id_user_connections_id_connection_accounts_id_account_recipients_post"
  end
  # verify the required parameter 'id_account' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'id_account' when calling RecipientsApi.users_id_user_connections_id_connection_accounts_id_account_recipients_post"
  end
  # resource path
  local_var_path = '/users/{id_user}/connections/{id_connection}/accounts/{id_account}/recipients'.sub('{' + 'id_user' + '}', id_user.to_s).sub('{' + 'id_connection' + '}', id_connection.to_s).sub('{' + 'id_account' + '}', .to_s)

  # query parameters
  query_params = {}
  query_params[:'background'] = opts[:'background'] if !opts[:'background'].nil?
  query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded'])

  # form parameters
  form_params = {}
  form_params['label'] = opts[:'label'] if !opts[:'label'].nil?
  form_params['iban'] = opts[:'iban'] if !opts[:'iban'].nil?

  # http body (model)
  post_body = nil
  auth_names = ['api_key']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Recipient')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: RecipientsApi#users_id_user_connections_id_connection_accounts_id_account_recipients_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#users_id_user_connections_id_connection_recipients_post(id_user, id_connection, opts = {}) ⇒ Recipient

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • id_connection
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:



182
183
184
185
# File 'lib/budgea_client/api/recipients_api.rb', line 182

def users_id_user_connections_id_connection_recipients_post(id_user, id_connection, opts = {})
  data, _status_code, _headers = users_id_user_connections_id_connection_recipients_post_with_http_info(id_user, id_connection, opts)
  data
end

#users_id_user_connections_id_connection_recipients_post_with_http_info(id_user, id_connection, opts = {}) ⇒ Array<(Recipient, Fixnum, Hash)>

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted&lt;br&gt;&lt;br&gt;

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • id_connection
  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:

  • (Array<(Recipient, Fixnum, Hash)>)

    Recipient data, response status code and response headers



197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
# File 'lib/budgea_client/api/recipients_api.rb', line 197

def users_id_user_connections_id_connection_recipients_post_with_http_info(id_user, id_connection, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: RecipientsApi.users_id_user_connections_id_connection_recipients_post ...'
  end
  # verify the required parameter 'id_user' is set
  if @api_client.config.client_side_validation && id_user.nil?
    fail ArgumentError, "Missing the required parameter 'id_user' when calling RecipientsApi.users_id_user_connections_id_connection_recipients_post"
  end
  # verify the required parameter 'id_connection' is set
  if @api_client.config.client_side_validation && id_connection.nil?
    fail ArgumentError, "Missing the required parameter 'id_connection' when calling RecipientsApi.users_id_user_connections_id_connection_recipients_post"
  end
  # resource path
  local_var_path = '/users/{id_user}/connections/{id_connection}/recipients'.sub('{' + 'id_user' + '}', id_user.to_s).sub('{' + 'id_connection' + '}', id_connection.to_s)

  # query parameters
  query_params = {}
  query_params[:'background'] = opts[:'background'] if !opts[:'background'].nil?
  query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded'])

  # form parameters
  form_params = {}
  form_params['label'] = opts[:'label'] if !opts[:'label'].nil?
  form_params['iban'] = opts[:'iban'] if !opts[:'iban'].nil?

  # http body (model)
  post_body = nil
  auth_names = ['api_key']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Recipient')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: RecipientsApi#users_id_user_connections_id_connection_recipients_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#users_id_user_recipients_post(id_user, opts = {}) ⇒ Recipient

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:



253
254
255
256
# File 'lib/budgea_client/api/recipients_api.rb', line 253

def users_id_user_recipients_post(id_user, opts = {})
  data, _status_code, _headers = users_id_user_recipients_post_with_http_info(id_user, opts)
  data
end

#users_id_user_recipients_post_with_http_info(id_user, opts = {}) ⇒ Array<(Recipient, Fixnum, Hash)>

Add a recipient. if config key transfer.recipient.iban_white_list.enabled is set to 1, recipients whose IBAN are not from countries codes contained in transfer.recipient.iban_white_list.entries will be deleted&lt;br&gt;&lt;br&gt;

Parameters:

  • id_user

    Hint: you can use &#39;me&#39; or &#39;all&#39;

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :background (BOOLEAN)

    if true, do synchronization in background

  • :label (String)

    label of recipient

  • :iban (String)

    iban of recipient

  • :expand (String)

Returns:

  • (Array<(Recipient, Fixnum, Hash)>)

    Recipient data, response status code and response headers



267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
# File 'lib/budgea_client/api/recipients_api.rb', line 267

def users_id_user_recipients_post_with_http_info(id_user, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: RecipientsApi.users_id_user_recipients_post ...'
  end
  # verify the required parameter 'id_user' is set
  if @api_client.config.client_side_validation && id_user.nil?
    fail ArgumentError, "Missing the required parameter 'id_user' when calling RecipientsApi.users_id_user_recipients_post"
  end
  # resource path
  local_var_path = '/users/{id_user}/recipients'.sub('{' + 'id_user' + '}', id_user.to_s)

  # query parameters
  query_params = {}
  query_params[:'background'] = opts[:'background'] if !opts[:'background'].nil?
  query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded'])

  # form parameters
  form_params = {}
  form_params['label'] = opts[:'label'] if !opts[:'label'].nil?
  form_params['iban'] = opts[:'iban'] if !opts[:'iban'].nil?

  # http body (model)
  post_body = nil
  auth_names = ['api_key']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Recipient')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: RecipientsApi#users_id_user_recipients_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end