Class: CyberSource::TransactionBatchesApi
- Inherits:
-
Object
- Object
- CyberSource::TransactionBatchesApi
- Defined in:
- lib/cybersource_rest_client/api/transaction_batches_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#get_transaction_batch_details(id, opts = {}) ⇒ nil
Get Transaction Details for a given Batch Id Provides real-time detailed status information about the transactions that you previously uploaded in the Business Center or processed with the Offline Transaction File Submission service.
-
#get_transaction_batch_details_with_http_info(id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Get Transaction Details for a given Batch Id Provides real-time detailed status information about the transactions that you previously uploaded in the Business Center or processed with the Offline Transaction File Submission service.
-
#get_transaction_batch_id(id, opts = {}) ⇒ PtsV1TransactionBatchesIdGet200Response
Get Individual Batch File Provide the search range.
-
#get_transaction_batch_id_with_http_info(id, opts = {}) ⇒ Array<(PtsV1TransactionBatchesIdGet200Response, Fixnum, Hash)>
Get Individual Batch File Provide the search range.
-
#get_transaction_batches(start_time, end_time, opts = {}) ⇒ PtsV1TransactionBatchesGet200Response
Get a List of Batch Files Provide the search range.
-
#get_transaction_batches_with_http_info(start_time, end_time, opts = {}) ⇒ Array<(PtsV1TransactionBatchesGet200Response, Fixnum, Hash)>
Get a List of Batch Files Provide the search range.
-
#initialize(api_client = ApiClient.default, config) ⇒ TransactionBatchesApi
constructor
A new instance of TransactionBatchesApi.
Constructor Details
#initialize(api_client = ApiClient.default, config) ⇒ TransactionBatchesApi
Returns a new instance of TransactionBatchesApi.
19 20 21 22 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 19 def initialize(api_client = ApiClient.default, config) @api_client = api_client @api_client.set_configuration(config) end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#get_transaction_batch_details(id, opts = {}) ⇒ nil
Get Transaction Details for a given Batch Id Provides real-time detailed status information about the transactions that you previously uploaded in the Business Center or processed with the Offline Transaction File Submission service.
30 31 32 33 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 30 def get_transaction_batch_details(id, opts = {}) data, status_code, headers = get_transaction_batch_details_with_http_info(id, opts) return data, status_code, headers end |
#get_transaction_batch_details_with_http_info(id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>
Get Transaction Details for a given Batch Id Provides real-time detailed status information about the transactions that you previously uploaded in the Business Center or processed with the Offline Transaction File Submission service.
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 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 42 def get_transaction_batch_details_with_http_info(id, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: TransactionBatchesApi.get_transaction_batch_details ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling TransactionBatchesApi.get_transaction_batch_details" end # resource path local_var_path = 'pts/v1/transaction-batch-details/{id}'.sub('{' + 'id' + '}', id.to_s) # query parameters query_params = {} query_params[:'uploadDate'] = opts[:'upload_date'] if !opts[:'upload_date'].nil? query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil? # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['text/csv', 'application/xml', 'text/vnd.cybersource.map-csv']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) if 'GET' == 'POST' post_body = '{}' else post_body = nil end auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names) if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: TransactionBatchesApi#get_transaction_batch_details\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#get_transaction_batch_id(id, opts = {}) ⇒ PtsV1TransactionBatchesIdGet200Response
Get Individual Batch File Provide the search range
102 103 104 105 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 102 def get_transaction_batch_id(id, opts = {}) data, status_code, headers = get_transaction_batch_id_with_http_info(id, opts) return data, status_code, headers end |
#get_transaction_batch_id_with_http_info(id, opts = {}) ⇒ Array<(PtsV1TransactionBatchesIdGet200Response, Fixnum, Hash)>
Get Individual Batch File Provide the search range
112 113 114 115 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 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 112 def get_transaction_batch_id_with_http_info(id, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: TransactionBatchesApi.get_transaction_batch_id ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling TransactionBatchesApi.get_transaction_batch_id" end # resource path local_var_path = 'pts/v1/transaction-batches/{id}'.sub('{' + 'id' + '}', id.to_s) # query parameters query_params = {} # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/hal+json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) if 'GET' == 'POST' post_body = '{}' else post_body = nil end auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'PtsV1TransactionBatchesIdGet200Response') if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: TransactionBatchesApi#get_transaction_batch_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |
#get_transaction_batches(start_time, end_time, opts = {}) ⇒ PtsV1TransactionBatchesGet200Response
Get a List of Batch Files Provide the search range
172 173 174 175 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 172 def get_transaction_batches(start_time, end_time, opts = {}) data, status_code, headers = get_transaction_batches_with_http_info(start_time, end_time, opts) return data, status_code, headers end |
#get_transaction_batches_with_http_info(start_time, end_time, opts = {}) ⇒ Array<(PtsV1TransactionBatchesGet200Response, Fixnum, Hash)>
Get a List of Batch Files Provide the search range
183 184 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 232 233 234 235 236 237 238 239 240 241 242 |
# File 'lib/cybersource_rest_client/api/transaction_batches_api.rb', line 183 def get_transaction_batches_with_http_info(start_time, end_time, opts = {}) if @api_client.config.debugging begin raise @api_client.config.logger.debug 'Calling API: TransactionBatchesApi.get_transaction_batches ...' rescue puts 'Cannot write to log' end end # verify the required parameter 'start_time' is set if @api_client.config.client_side_validation && start_time.nil? fail ArgumentError, "Missing the required parameter 'start_time' when calling TransactionBatchesApi.get_transaction_batches" end # verify the required parameter 'end_time' is set if @api_client.config.client_side_validation && end_time.nil? fail ArgumentError, "Missing the required parameter 'end_time' when calling TransactionBatchesApi.get_transaction_batches" end # resource path local_var_path = 'pts/v1/transaction-batches' # query parameters query_params = {} query_params[:'startTime'] = start_time query_params[:'endTime'] = end_time # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/hal+json']) # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/json;charset=utf-8']) # form parameters form_params = {} # http body (model) if 'GET' == 'POST' post_body = '{}' else post_body = nil end auth_names = [] data, status_code, headers = @api_client.call_api(:GET, local_var_path, :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => 'PtsV1TransactionBatchesGet200Response') if @api_client.config.debugging begin raise @api_client.config.logger.debug "API called: TransactionBatchesApi#get_transaction_batches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" rescue puts 'Cannot write to log' end end return data, status_code, headers end |