data-and-reporting-sdk 1.3.0 → 2.0.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 +66 -35
- data/lib/shell_data_reporting_ap_is/api_helper.rb +2 -2
- data/lib/shell_data_reporting_ap_is/client.rb +11 -12
- data/lib/shell_data_reporting_ap_is/configuration.rb +23 -25
- data/lib/shell_data_reporting_ap_is/controllers/base_controller.rb +3 -9
- data/lib/shell_data_reporting_ap_is/controllers/customer_controller.rb +251 -288
- data/lib/shell_data_reporting_ap_is/controllers/invoice_controller.rb +20 -20
- data/lib/shell_data_reporting_ap_is/controllers/o_auth_authorization_controller.rb +7 -7
- data/lib/shell_data_reporting_ap_is/controllers/transaction_controller.rb +204 -259
- data/lib/shell_data_reporting_ap_is/exceptions/api_exception.rb +2 -2
- data/lib/shell_data_reporting_ap_is/exceptions/error_object_exception.rb +7 -5
- data/lib/shell_data_reporting_ap_is/exceptions/o_auth_provider_exception.rb +7 -5
- data/lib/shell_data_reporting_ap_is/http/auth/{bearer_token.rb → o_auth2.rb} +28 -27
- data/lib/shell_data_reporting_ap_is/http/http_call_back.rb +2 -2
- data/lib/shell_data_reporting_ap_is/http/http_method_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/http/http_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/http/http_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/http/proxy_settings.rb +13 -0
- data/lib/shell_data_reporting_ap_is/models/account_access.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/account_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/account_request.rb +3 -3
- data/lib/shell_data_reporting_ap_is/models/account_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/account_response_accounts_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/accounts.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/address.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/associated_account.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/audit_array_elements.rb +71 -0
- data/lib/shell_data_reporting_ap_is/models/audit_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/audit_request.rb +29 -41
- data/lib/shell_data_reporting_ap_is/models/audit_response.rb +88 -53
- data/lib/shell_data_reporting_ap_is/models/audit_response_audits_items.rb +29 -6
- data/lib/shell_data_reporting_ap_is/models/bank_account.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/base_model.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/bonus_configuration.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/bonus_history.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_day_time_restrictions.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_exceptions.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_group_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_request.rb +6 -31
- data/lib/shell_data_reporting_ap_is/models/card_group_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/card_group_response_card_groups_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/{error_user_access.rb → card_type_req.rb} +14 -14
- data/lib/shell_data_reporting_ap_is/models/card_type_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_type_res.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/card_type_response_customer_card_types_items.rb +3 -3
- data/lib/shell_data_reporting_ap_is/models/card_usage_restrictions.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_res.rb +116 -0
- data/lib/shell_data_reporting_ap_is/models/card_usage_summary_response.rb +6 -26
- data/lib/shell_data_reporting_ap_is/models/col_co_access.rb +4 -4
- data/lib/shell_data_reporting_ap_is/models/current_volume.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/customer_contract.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/customer_detail_request.rb +4 -4
- data/lib/shell_data_reporting_ap_is/models/customer_detail_response.rb +5 -32
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_res.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/customer_price_list_response.rb +7 -29
- data/lib/shell_data_reporting_ap_is/models/{default_error_fault_detail.rb → customer_req.rb} +15 -15
- data/lib/shell_data_reporting_ap_is/models/customer_res.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/delivery_addresses.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_access.rb +3 -3
- data/lib/shell_data_reporting_ap_is/models/eid_document.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_document_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_download_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_download_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_search_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/eid_search_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/error_details.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/exception_product.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/exception_site_location.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_item.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_item_summary_all_of0.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_rule_location.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_rule_product.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_rule_tier.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fee_summary_response.rb +57 -38
- data/lib/shell_data_reporting_ap_is/models/fees_fee_rule_tiers.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/filters.rb +522 -0
- data/lib/shell_data_reporting_ap_is/models/{finance_currency.rb → finance_currency2.rb} +8 -9
- data/lib/shell_data_reporting_ap_is/models/fleetmanagement_v1_user_loggedinuser_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_card.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_data.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/fuel_consumption_response.rb +58 -33
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_data.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_request_filters.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_dates_response_data.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_distribution_method.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_download_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_download_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_search_additional_document.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_search_details.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_search_request_filters.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_search_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_details.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_request_filters.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoice_summary_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/invoices_summaries.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/last_statement_of_account.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/last_statement_of_account2.rb +457 -0
- data/lib/shell_data_reporting_ap_is/models/{error_user_access_error.rb → location.rb} +25 -22
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_req.rb +63 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_res.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_response.rb +6 -30
- data/lib/shell_data_reporting_ap_is/models/monthly_invoice_trend.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_request_accounts_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response.rb +6 -57
- data/lib/shell_data_reporting_ap_is/models/multi_priced_transaction_response_transactions_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/o_auth_provider_error_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/o_auth_token.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/past_statement_of_accounts.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/payer_access.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/payer_details.rb +8 -6
- data/lib/shell_data_reporting_ap_is/models/payer_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/payer_request.rb +6 -33
- data/lib/shell_data_reporting_ap_is/models/payer_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/payers.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/payments_since_last_soa.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/pin_advice_types.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/price_list.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/price_trans_summary_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/price_trans_summary_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/price_transaction_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/price_transaction_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_request_data.rb +4 -8
- data/lib/shell_data_reporting_ap_is/models/priced_response_data.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_resp.rb +116 -0
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response_transactions_summary_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_items_location_items.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_invoice_status_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_period_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_req_v2_sort_order_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_request_v2.rb +5 -7
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_resp_v2_refund_flag_enum.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_transactions_items.rb +6 -27
- data/lib/shell_data_reporting_ap_is/models/priced_transaction_response_v2.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/pricing_current_volume.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/pricing_history.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/purchase_categories.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/recent_transaction_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/recent_transactions.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/recent_transactions_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/role.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_doc_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_documents_invoice.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_documents_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_documents_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_soa_req.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/search_statement_of_account_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/site_location.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_request_filters.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_resp.rb +9 -9
- data/lib/shell_data_reporting_ap_is/models/statement_of_account_response.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/tier.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions.rb +5 -5
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_res.rb +116 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_exceptions_response.rb +6 -26
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_req.rb +84 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_request.rb +6 -28
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_res.rb +158 -0
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_summary_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/update_odometer_reference.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/update_odometer_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/update_odometer_resp.rb +116 -0
- data/lib/shell_data_reporting_ap_is/models/update_odometer_response.rb +6 -26
- data/lib/shell_data_reporting_ap_is/models/usage_summary.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_res.rb +116 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_bonus_response.rb +6 -27
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_req.rb +62 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_request.rb +2 -2
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_res.rb +91 -0
- data/lib/shell_data_reporting_ap_is/models/volume_based_pricing_response.rb +28 -24
- data/lib/shell_data_reporting_ap_is/models/warning.rb +69 -0
- data/lib/shell_data_reporting_ap_is/utilities/date_time_helper.rb +2 -2
- data/lib/shell_data_reporting_ap_is/utilities/file_wrapper.rb +2 -2
- data/lib/shell_data_reporting_ap_is/utilities/union_type_lookup.rb +2 -2
- data/lib/shell_data_reporting_ap_is.rb +54 -29
- data/test/controllers/controller_test_base.rb +2 -2
- data/test/controllers/test_invoice_controller.rb +3 -12
- data/test/controllers/test_transaction_controller.rb +3 -5
- data/test/http_response_catcher.rb +3 -3
- metadata +50 -26
- data/lib/shell_data_reporting_ap_is/exceptions/default_error_exception.rb +0 -44
- data/lib/shell_data_reporting_ap_is/exceptions/error_user_access_error1_exception.rb +0 -44
- data/lib/shell_data_reporting_ap_is/http/auth/basic_auth.rb +0 -50
- data/lib/shell_data_reporting_ap_is/models/account_response.rb +0 -123
- data/lib/shell_data_reporting_ap_is/models/card_group_response.rb +0 -121
- data/lib/shell_data_reporting_ap_is/models/card_type_response.rb +0 -91
- data/lib/shell_data_reporting_ap_is/models/card_type_response_error.rb +0 -71
- data/lib/shell_data_reporting_ap_is/models/default_error_fault.rb +0 -71
- data/lib/shell_data_reporting_ap_is/models/error_status.rb +0 -81
- data/lib/shell_data_reporting_ap_is/models/logged_in_user_request.rb +0 -121
- data/lib/shell_data_reporting_ap_is/models/payer_response.rb +0 -127
- data/lib/shell_data_reporting_ap_is/models/priced_trans_summary_response.rb +0 -91
- data/lib/shell_data_reporting_ap_is/models/transaction_fees_response.rb +0 -123
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: '029daa034be160955c29be965509aadc2b080bfb587f24225b26b144b774b258'
|
4
|
+
data.tar.gz: 1c7f87bb1def847aba87695075112c83f91414b7998d1d55f313c61af7fc28b4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a3ab34fbd35187ac36a8442076cb6cf9cd0afc01a0b870074e0d4308c650996ed4f36d810ef84b883bb23d80c176d0ce6a9112dce5cda7af2a5104f0ed49242d
|
7
|
+
data.tar.gz: e6ada66e602acf2b3edaf55ea8b6c248bf9354cb58c215daab2297962b3435aa8db98e799d50b4681893d27b3af2027faaeb65d0c2627f064522a9758ddc330e
|
data/README.md
CHANGED
@@ -3,10 +3,33 @@
|
|
3
3
|
|
4
4
|
## Introduction
|
5
5
|
|
6
|
-
Data
|
7
|
-
|
8
|
-
|
9
|
-
|
6
|
+
The Shell Card Transaction and Invoice API is part of the Data and Reporting product suite, designed to provide secure and flexible access to transaction and invoice data related to Shell Cards.
|
7
|
+
|
8
|
+
### Authentication
|
9
|
+
|
10
|
+
- OAuth 2.0 Authentication.
|
11
|
+
|
12
|
+
### Architecture
|
13
|
+
|
14
|
+
- RESTful API design.
|
15
|
+
- All endpoints use the `POST` HTTP method for all operations including retrieval, creation, update, and deletion of resources.
|
16
|
+
- Requests and responses are encoded in JSON format.
|
17
|
+
- Standard HTTP status codes are used for response handling.
|
18
|
+
|
19
|
+
### Platform
|
20
|
+
|
21
|
+
- All resources are managed within the **Shell Card Platform**, which integrates multiple internal Shell systems for resource management.
|
22
|
+
|
23
|
+
### Features
|
24
|
+
|
25
|
+
- Flexible search parameters supported in the request body for data retrieval.
|
26
|
+
- Designed for integration with enterprise systems requiring Shell Card transaction and invoice data.
|
27
|
+
|
28
|
+
### Use Cases
|
29
|
+
|
30
|
+
- Retrieve detailed transaction history for Shell Cards.
|
31
|
+
- Access invoice summaries and line-item details.
|
32
|
+
- Integrate Shell Card financial data into internal reporting tools.
|
10
33
|
|
11
34
|
Go to the Shell Developer Portal: [https://developer.shell.com](https://developer.shell.com)
|
12
35
|
|
@@ -15,16 +38,16 @@ Go to the Shell Developer Portal: [https://developer.shell.com](https://develope
|
|
15
38
|
Install the gem from the command line:
|
16
39
|
|
17
40
|
```bash
|
18
|
-
gem install data-and-reporting-sdk -v
|
41
|
+
gem install data-and-reporting-sdk -v 2.0.0
|
19
42
|
```
|
20
43
|
|
21
44
|
Or add the gem to your Gemfile and run `bundle`:
|
22
45
|
|
23
46
|
```ruby
|
24
|
-
gem 'data-and-reporting-sdk', '
|
47
|
+
gem 'data-and-reporting-sdk', '2.0.0'
|
25
48
|
```
|
26
49
|
|
27
|
-
For additional gem details, see the [RubyGems page for the data-and-reporting-sdk gem](https://rubygems.org/gems/data-and-reporting-sdk/versions/
|
50
|
+
For additional gem details, see the [RubyGems page for the data-and-reporting-sdk gem](https://rubygems.org/gems/data-and-reporting-sdk/versions/2.0.0).
|
28
51
|
|
29
52
|
## Test the SDK
|
30
53
|
|
@@ -36,34 +59,33 @@ rake
|
|
36
59
|
|
37
60
|
## Initialize the API Client
|
38
61
|
|
39
|
-
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/
|
62
|
+
**_Note:_** Documentation for the client can be found [here.](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/client.md)
|
40
63
|
|
41
64
|
The following parameters are configurable for the API Client:
|
42
65
|
|
43
66
|
| Parameter | Type | Description |
|
44
67
|
| --- | --- | --- |
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
68
|
+
| environment | `Environment` | The API environment. <br> **Default: `Environment.SIT`** |
|
69
|
+
| connection | `Faraday::Connection` | The Faraday connection object passed by the SDK user for making requests |
|
70
|
+
| adapter | `Faraday::Adapter` | The Faraday adapter object passed by the SDK user for performing http requests |
|
71
|
+
| timeout | `Float` | The value to use for connection timeout. <br> **Default: 60** |
|
72
|
+
| max_retries | `Integer` | The number of times to retry an endpoint call if it fails. <br> **Default: 0** |
|
73
|
+
| retry_interval | `Float` | Pause in seconds between retries. <br> **Default: 1** |
|
74
|
+
| backoff_factor | `Float` | The amount to multiply each successive retry's interval amount by in order to provide backoff. <br> **Default: 2** |
|
75
|
+
| retry_statuses | `Array` | A list of HTTP statuses to retry. <br> **Default: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524]** |
|
76
|
+
| retry_methods | `Array` | A list of HTTP methods to retry. <br> **Default: %i[get put]** |
|
77
|
+
| http_callback | `HttpCallBack` | The Http CallBack allows defining callables for pre and post API calls. |
|
78
|
+
| proxy_settings | [`ProxySettings`](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/proxy-settings.md) | Optional proxy configuration to route HTTP requests through a proxy server. |
|
79
|
+
| client_credentials_auth_credentials | [`ClientCredentialsAuthCredentials`](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/auth/oauth-2-client-credentials-grant.md) | The credential object for OAuth 2 Client Credentials Grant |
|
57
80
|
|
58
81
|
The API client can be initialized as follows:
|
59
82
|
|
60
83
|
```ruby
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
bearer_token_credentials: BearerTokenCredentials.new(
|
84
|
+
require 'shell_data_reporting_ap_is'
|
85
|
+
include ShellDataReportingApIs
|
86
|
+
|
87
|
+
client = Client.new(
|
88
|
+
client_credentials_auth_credentials: ClientCredentialsAuthCredentials.new(
|
67
89
|
o_auth_client_id: 'OAuthClientId',
|
68
90
|
o_auth_client_secret: 'OAuthClientSecret'
|
69
91
|
),
|
@@ -86,18 +108,27 @@ The SDK can be configured to use a different environment for making API calls. A
|
|
86
108
|
|
87
109
|
This API uses the following authentication schemes.
|
88
110
|
|
89
|
-
* [`
|
90
|
-
* [`BearerToken (OAuth 2 Client Credentials Grant)`](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/1.3.0/doc/auth/oauth-2-client-credentials-grant.md)
|
111
|
+
* [`BearerToken (OAuth 2 Client Credentials Grant)`](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/auth/oauth-2-client-credentials-grant.md)
|
91
112
|
|
92
113
|
## List of APIs
|
93
114
|
|
94
|
-
* [Customer](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/
|
95
|
-
* [Transaction](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/
|
96
|
-
* [Invoice](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/
|
115
|
+
* [Customer](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/controllers/customer.md)
|
116
|
+
* [Transaction](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/controllers/transaction.md)
|
117
|
+
* [Invoice](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/controllers/invoice.md)
|
97
118
|
|
98
|
-
##
|
119
|
+
## SDK Infrastructure
|
99
120
|
|
100
|
-
|
101
|
-
|
102
|
-
* [
|
121
|
+
### Configuration
|
122
|
+
|
123
|
+
* [ProxySettings](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/proxy-settings.md)
|
124
|
+
|
125
|
+
### HTTP
|
126
|
+
|
127
|
+
* [HttpResponse](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/http-response.md)
|
128
|
+
* [HttpRequest](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/http-request.md)
|
129
|
+
|
130
|
+
### Utilities
|
131
|
+
|
132
|
+
* [ApiHelper](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/api-helper.md)
|
133
|
+
* [DateTimeHelper](https://www.github.com/sdks-io/data-and-reporting-ruby-sdk/tree/2.0.0/doc/date-time-helper.md)
|
103
134
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# shell_data_reporting_ap_is
|
2
2
|
#
|
3
|
-
# This file was automatically generated by
|
4
|
-
# ( https://apimatic.io ).
|
3
|
+
# This file was automatically generated by
|
4
|
+
# APIMATIC v3.0 ( https://www.apimatic.io ).
|
5
5
|
|
6
6
|
module ShellDataReportingApIs
|
7
7
|
# API utility class
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# shell_data_reporting_ap_is
|
2
2
|
#
|
3
|
-
# This file was automatically generated by
|
4
|
-
# ( https://apimatic.io ).
|
3
|
+
# This file was automatically generated by
|
4
|
+
# APIMATIC v3.0 ( https://www.apimatic.io ).
|
5
5
|
|
6
6
|
module ShellDataReportingApIs
|
7
7
|
# shell_data_reporting_ap_is client class.
|
@@ -42,9 +42,9 @@ module ShellDataReportingApIs
|
|
42
42
|
connection: nil, adapter: :net_http_persistent, timeout: 60,
|
43
43
|
max_retries: 0, retry_interval: 1, backoff_factor: 2,
|
44
44
|
retry_statuses: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524],
|
45
|
-
retry_methods: %i[get put], http_callback: nil,
|
46
|
-
environment: Environment::SIT,
|
47
|
-
|
45
|
+
retry_methods: %i[get put], http_callback: nil, proxy_settings: nil,
|
46
|
+
environment: Environment::SIT, client_credentials_auth_credentials: nil,
|
47
|
+
config: nil
|
48
48
|
)
|
49
49
|
@config = if config.nil?
|
50
50
|
Configuration.new(
|
@@ -53,9 +53,8 @@ module ShellDataReportingApIs
|
|
53
53
|
backoff_factor: backoff_factor,
|
54
54
|
retry_statuses: retry_statuses,
|
55
55
|
retry_methods: retry_methods, http_callback: http_callback,
|
56
|
-
environment: environment,
|
57
|
-
|
58
|
-
bearer_token_credentials: bearer_token_credentials
|
56
|
+
proxy_settings: proxy_settings, environment: environment,
|
57
|
+
client_credentials_auth_credentials: client_credentials_auth_credentials
|
59
58
|
)
|
60
59
|
else
|
61
60
|
config
|
@@ -75,10 +74,10 @@ module ShellDataReportingApIs
|
|
75
74
|
def initialize_auth_managers(global_config)
|
76
75
|
@auth_managers = {}
|
77
76
|
http_client_config = global_config.client_configuration
|
78
|
-
%w[
|
79
|
-
@auth_managers['
|
80
|
-
|
81
|
-
|
77
|
+
%w[BearerToken].each { |auth| @auth_managers[auth] = nil }
|
78
|
+
@auth_managers['BearerToken'] = OAuth2.new(
|
79
|
+
http_client_config.client_credentials_auth_credentials, global_config
|
80
|
+
)
|
82
81
|
end
|
83
82
|
end
|
84
83
|
end
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# shell_data_reporting_ap_is
|
2
2
|
#
|
3
|
-
# This file was automatically generated by
|
4
|
-
# ( https://apimatic.io ).
|
3
|
+
# This file was automatically generated by
|
4
|
+
# APIMATIC v3.0 ( https://www.apimatic.io ).
|
5
5
|
|
6
6
|
module ShellDataReportingApIs
|
7
7
|
# An enum for SDK environments.
|
@@ -24,7 +24,7 @@ module ShellDataReportingApIs
|
|
24
24
|
# are configured in this class.
|
25
25
|
class Configuration < CoreLibrary::HttpClientConfiguration
|
26
26
|
# The attribute readers for properties.
|
27
|
-
attr_reader :environment, :
|
27
|
+
attr_reader :environment, :client_credentials_auth_credentials
|
28
28
|
|
29
29
|
class << self
|
30
30
|
attr_reader :environments
|
@@ -34,24 +34,23 @@ module ShellDataReportingApIs
|
|
34
34
|
connection: nil, adapter: :net_http_persistent, timeout: 60,
|
35
35
|
max_retries: 0, retry_interval: 1, backoff_factor: 2,
|
36
36
|
retry_statuses: [408, 413, 429, 500, 502, 503, 504, 521, 522, 524],
|
37
|
-
retry_methods: %i[get put], http_callback: nil,
|
38
|
-
environment: Environment::SIT,
|
39
|
-
bearer_token_credentials: nil
|
37
|
+
retry_methods: %i[get put], http_callback: nil, proxy_settings: nil,
|
38
|
+
environment: Environment::SIT, client_credentials_auth_credentials: nil
|
40
39
|
)
|
41
|
-
|
42
40
|
super connection: connection, adapter: adapter, timeout: timeout,
|
43
41
|
max_retries: max_retries, retry_interval: retry_interval,
|
44
42
|
backoff_factor: backoff_factor, retry_statuses: retry_statuses,
|
45
|
-
retry_methods: retry_methods, http_callback: http_callback
|
43
|
+
retry_methods: retry_methods, http_callback: http_callback,
|
44
|
+
proxy_settings: proxy_settings
|
46
45
|
|
47
46
|
# Current API environment
|
48
47
|
@environment = String(environment)
|
49
48
|
|
50
|
-
# The object holding Basic Authentication credentials
|
51
|
-
@basic_auth_credentials = basic_auth_credentials
|
52
|
-
|
53
49
|
# The object holding OAuth 2 Client Credentials Grant credentials
|
54
|
-
@
|
50
|
+
@client_credentials_auth_credentials = client_credentials_auth_credentials
|
51
|
+
|
52
|
+
# Initializing OAuth 2 Client Credentials Grant credentials with the provided auth parameters
|
53
|
+
@client_credentials_auth_credentials = client_credentials_auth_credentials
|
55
54
|
|
56
55
|
# The Http Client to use for making requests.
|
57
56
|
set_http_client CoreLibrary::FaradayClient.new(self)
|
@@ -60,8 +59,8 @@ module ShellDataReportingApIs
|
|
60
59
|
def clone_with(connection: nil, adapter: nil, timeout: nil,
|
61
60
|
max_retries: nil, retry_interval: nil, backoff_factor: nil,
|
62
61
|
retry_statuses: nil, retry_methods: nil, http_callback: nil,
|
63
|
-
|
64
|
-
|
62
|
+
proxy_settings: nil, environment: nil,
|
63
|
+
client_credentials_auth_credentials: nil)
|
65
64
|
connection ||= self.connection
|
66
65
|
adapter ||= self.adapter
|
67
66
|
timeout ||= self.timeout
|
@@ -71,19 +70,18 @@ module ShellDataReportingApIs
|
|
71
70
|
retry_statuses ||= self.retry_statuses
|
72
71
|
retry_methods ||= self.retry_methods
|
73
72
|
http_callback ||= self.http_callback
|
73
|
+
proxy_settings ||= self.proxy_settings
|
74
74
|
environment ||= self.environment
|
75
|
-
|
76
|
-
bearer_token_credentials ||= self.bearer_token_credentials
|
75
|
+
client_credentials_auth_credentials ||= self.client_credentials_auth_credentials
|
77
76
|
|
78
|
-
Configuration.new(
|
79
|
-
|
80
|
-
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
85
|
-
|
86
|
-
bearer_token_credentials: bearer_token_credentials)
|
77
|
+
Configuration.new(
|
78
|
+
connection: connection, adapter: adapter, timeout: timeout,
|
79
|
+
max_retries: max_retries, retry_interval: retry_interval,
|
80
|
+
backoff_factor: backoff_factor, retry_statuses: retry_statuses,
|
81
|
+
retry_methods: retry_methods, http_callback: http_callback,
|
82
|
+
proxy_settings: proxy_settings, environment: environment,
|
83
|
+
client_credentials_auth_credentials: client_credentials_auth_credentials
|
84
|
+
)
|
87
85
|
end
|
88
86
|
|
89
87
|
|
@@ -1,7 +1,7 @@
|
|
1
1
|
# shell_data_reporting_ap_is
|
2
2
|
#
|
3
|
-
# This file was automatically generated by
|
4
|
-
# ( https://apimatic.io ).
|
3
|
+
# This file was automatically generated by
|
4
|
+
# APIMATIC v3.0 ( https://www.apimatic.io ).
|
5
5
|
|
6
6
|
module ShellDataReportingApIs
|
7
7
|
# BaseController.
|
@@ -26,13 +26,7 @@ module ShellDataReportingApIs
|
|
26
26
|
@global_configuration = global_configuration
|
27
27
|
@config = @global_configuration.client_configuration
|
28
28
|
@http_call_back = @config.http_callback
|
29
|
-
@api_call = ApiCall.new(@global_configuration)
|
30
|
-
end
|
31
|
-
|
32
|
-
# Creates a new builder for the Api Call instance.
|
33
|
-
# @return [ApiCall] The instance of ApiCall.
|
34
|
-
def new_api_call_builder
|
35
|
-
@api_call.new_builder
|
29
|
+
@api_call = ApiCall.new(@global_configuration)
|
36
30
|
end
|
37
31
|
|
38
32
|
# Creates a new instance of the request builder.
|