Class: SyncteraRubySdk::WiresApi
- Inherits:
-
Object
- Object
- SyncteraRubySdk::WiresApi
- Defined in:
- lib/synctera_ruby_sdk/api/wires_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#cancel_wire(wire_id, update_transfer, opts = {}) ⇒ Wire
Cancel an outgoing wire Cancel an outgoing tranfer.
-
#cancel_wire_with_http_info(wire_id, update_transfer, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Cancel an outgoing wire Cancel an outgoing tranfer.
-
#create_wire(wire_request, opts = {}) ⇒ Wire
Send a wire Create an outgoing wire transfer.
-
#create_wire_with_http_info(wire_request, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Send a wire Create an outgoing wire transfer.
-
#get_wire(wire_id, opts = {}) ⇒ Wire
Get a wire by id Get a wire by id.
-
#get_wire_with_http_info(wire_id, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Get a wire by id Get a wire by id.
-
#initialize(api_client = ApiClient.default) ⇒ WiresApi
constructor
A new instance of WiresApi.
-
#list_wires(opts = {}) ⇒ WireList
List wires Get paginated list of wires.
-
#list_wires_with_http_info(opts = {}) ⇒ Array<(WireList, Integer, Hash)>
List wires Get paginated list of wires.
Constructor Details
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#cancel_wire(wire_id, update_transfer, opts = {}) ⇒ Wire
Cancel an outgoing wire Cancel an outgoing tranfer
29 30 31 32 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 29 def cancel_wire(wire_id, update_transfer, opts = {}) data, _status_code, _headers = cancel_wire_with_http_info(wire_id, update_transfer, opts) data end |
#cancel_wire_with_http_info(wire_id, update_transfer, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Cancel an outgoing wire Cancel an outgoing tranfer
41 42 43 44 45 46 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 94 95 96 97 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 41 def cancel_wire_with_http_info(wire_id, update_transfer, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: WiresApi.cancel_wire ...' end # verify the required parameter 'wire_id' is set if @api_client.config.client_side_validation && wire_id.nil? fail ArgumentError, "Missing the required parameter 'wire_id' when calling WiresApi.cancel_wire" end # verify the required parameter 'update_transfer' is set if @api_client.config.client_side_validation && update_transfer.nil? fail ArgumentError, "Missing the required parameter 'update_transfer' when calling WiresApi.cancel_wire" end # resource path local_var_path = '/wires/{wire_id}'.sub('{' + 'wire_id' + '}', CGI.escape(wire_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil? # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(update_transfer) # return_type return_type = opts[:debug_return_type] || 'Wire' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"WiresApi.cancel_wire", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: WiresApi#cancel_wire\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#create_wire(wire_request, opts = {}) ⇒ Wire
Send a wire Create an outgoing wire transfer
105 106 107 108 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 105 def create_wire(wire_request, opts = {}) data, _status_code, _headers = create_wire_with_http_info(wire_request, opts) data end |
#create_wire_with_http_info(wire_request, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Send a wire Create an outgoing wire transfer
116 117 118 119 120 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 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 116 def create_wire_with_http_info(wire_request, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: WiresApi.create_wire ...' end # verify the required parameter 'wire_request' is set if @api_client.config.client_side_validation && wire_request.nil? fail ArgumentError, "Missing the required parameter 'wire_request' when calling WiresApi.create_wire" end # resource path local_var_path = '/wires' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json']) # HTTP header 'Content-Type' content_type = @api_client.select_header_content_type(['application/json']) if !content_type.nil? header_params['Content-Type'] = content_type end header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil? # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] || @api_client.object_to_http_body(wire_request) # return_type return_type = opts[:debug_return_type] || 'Wire' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"WiresApi.create_wire", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: WiresApi#create_wire\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#get_wire(wire_id, opts = {}) ⇒ Wire
Get a wire by id Get a wire by id
175 176 177 178 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 175 def get_wire(wire_id, opts = {}) data, _status_code, _headers = get_wire_with_http_info(wire_id, opts) data end |
#get_wire_with_http_info(wire_id, opts = {}) ⇒ Array<(Wire, Integer, Hash)>
Get a wire by id Get a wire by id
185 186 187 188 189 190 191 192 193 194 195 196 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 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 185 def get_wire_with_http_info(wire_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: WiresApi.get_wire ...' end # verify the required parameter 'wire_id' is set if @api_client.config.client_side_validation && wire_id.nil? fail ArgumentError, "Missing the required parameter 'wire_id' when calling WiresApi.get_wire" end # resource path local_var_path = '/wires/{wire_id}'.sub('{' + 'wire_id' + '}', CGI.escape(wire_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'Wire' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"WiresApi.get_wire", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: WiresApi#get_wire\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#list_wires(opts = {}) ⇒ WireList
List wires Get paginated list of wires
243 244 245 246 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 243 def list_wires(opts = {}) data, _status_code, _headers = list_wires_with_http_info(opts) data end |
#list_wires_with_http_info(opts = {}) ⇒ Array<(WireList, Integer, Hash)>
List wires Get paginated list of wires
258 259 260 261 262 263 264 265 266 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 310 311 312 313 314 |
# File 'lib/synctera_ruby_sdk/api/wires_api.rb', line 258 def list_wires_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: WiresApi.list_wires ...' end if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1 fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling WiresApi.list_wires, must be greater than or equal to 1.' end allowable_values = ["READY", "BLOCKED", "POSTED"] if @api_client.config.client_side_validation && opts[:'status'] && !allowable_values.include?(opts[:'status']) fail ArgumentError, "invalid value for \"status\", must be one of #{allowable_values}" end # resource path local_var_path = '/wires' # query parameters query_params = opts[:query_params] || {} query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'page_token'] = opts[:'page_token'] if !opts[:'page_token'].nil? query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil? query_params[:'customer_id'] = opts[:'customer_id'] if !opts[:'customer_id'].nil? query_params[:'originating_account_id'] = opts[:'originating_account_id'] if !opts[:'originating_account_id'].nil? query_params[:'receiving_account_id'] = opts[:'receiving_account_id'] if !opts[:'receiving_account_id'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json', 'application/problem+json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:debug_body] # return_type return_type = opts[:debug_return_type] || 'WireList' # auth_names auth_names = opts[:debug_auth_names] || ['bearerAuth'] = opts.merge( :operation => :"WiresApi.list_wires", :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: WiresApi#list_wires\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |