card-management-sdk 1.0.0 → 1.2.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 +27 -19
- data/lib/shell_card_management_ap_is/client.rb +2 -3
- data/lib/shell_card_management_ap_is/configuration.rb +15 -22
- data/lib/shell_card_management_ap_is/controllers/base_controller.rb +9 -9
- data/lib/shell_card_management_ap_is/controllers/card_controller.rb +434 -434
- data/lib/shell_card_management_ap_is/controllers/customer_controller.rb +261 -262
- data/lib/shell_card_management_ap_is/controllers/o_auth_authorization_controller.rb +11 -11
- data/lib/shell_card_management_ap_is/controllers/restriction_controller.rb +421 -291
- data/lib/shell_card_management_ap_is/exceptions/error_object_exception.rb +15 -15
- data/lib/shell_card_management_ap_is/exceptions/{error_user_access_error1_exception.rb → fleetmanagement_v1_customer_customer403_error_exception.rb} +17 -17
- data/lib/shell_card_management_ap_is/exceptions/{default_error_exception.rb → fleetmanagement_v1_customer_payers400_error_exception.rb} +20 -20
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_customer_payers404_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser400_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser401_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser403_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser404_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v1_user_loggedinuser500_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v2_restriction_searchcard401_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/fleetmanagement_v2_restriction_searchcard500_error_exception.rb +32 -0
- data/lib/shell_card_management_ap_is/exceptions/o_auth_provider_exception.rb +15 -15
- data/lib/shell_card_management_ap_is/http/auth/bearer_token.rb +54 -10
- data/lib/shell_card_management_ap_is/models/account_access.rb +3 -8
- data/lib/shell_card_management_ap_is/models/account_request.rb +17 -26
- data/lib/shell_card_management_ap_is/models/account_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/account_response_accounts_items.rb +29 -53
- data/lib/shell_card_management_ap_is/models/account_restriction_request.rb +28 -10
- data/lib/shell_card_management_ap_is/models/account_restriction_response.rb +60 -11
- data/lib/shell_card_management_ap_is/models/account_velocity_limit.rb +11 -19
- data/lib/shell_card_management_ap_is/models/accounts.rb +1 -2
- data/lib/shell_card_management_ap_is/models/address.rb +4 -11
- data/lib/shell_card_management_ap_is/models/audit_request.rb +37 -33
- data/lib/shell_card_management_ap_is/models/audit_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/audit_response_audits_items.rb +50 -63
- data/lib/shell_card_management_ap_is/models/auto_renew_card_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/auto_renew_card_request_auto_renew_cards_items.rb +13 -5
- data/lib/shell_card_management_ap_is/models/auto_renew_card_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/auto_renew_card_response_data_items.rb +13 -3
- data/lib/shell_card_management_ap_is/models/bank_account.rb +5 -13
- data/lib/shell_card_management_ap_is/models/{search_account_limit_request_filters.rb → budle_details_request.rb} +29 -22
- data/lib/shell_card_management_ap_is/models/{create_bundle_response_data_items_cards_items.rb → bundle_card_restriction_status.rb} +4 -3
- data/lib/shell_card_management_ap_is/models/bundle_details_response.rb +181 -0
- data/lib/shell_card_management_ap_is/models/bundle_restriction.rb +86 -103
- data/lib/shell_card_management_ap_is/models/bundle_restriction_update.rb +185 -0
- data/lib/shell_card_management_ap_is/models/bundled_details_product_list.rb +116 -0
- data/lib/shell_card_management_ap_is/models/bundled_restrictions_list.rb +82 -0
- data/lib/shell_card_management_ap_is/models/cancel_card_request.rb +1 -3
- data/lib/shell_card_management_ap_is/models/cancel_card_response.rb +3 -6
- data/lib/shell_card_management_ap_is/models/card.rb +43 -51
- data/lib/shell_card_management_ap_is/models/card_block_schedule.rb +1 -2
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_response_data_items_card_bundles_items.rb → card_bundle.rb} +11 -18
- data/lib/shell_card_management_ap_is/models/card_contact.rb +222 -0
- data/lib/shell_card_management_ap_is/models/card_day_time_restrictions.rb +3 -9
- data/lib/shell_card_management_ap_is/models/card_delivery_address.rb +218 -0
- data/lib/shell_card_management_ap_is/models/card_delivery_contact.rb +7 -14
- data/lib/shell_card_management_ap_is/models/card_detail.rb +50 -61
- data/lib/shell_card_management_ap_is/models/card_details_request.rb +6 -14
- data/lib/shell_card_management_ap_is/models/card_details_response.rb +52 -89
- data/lib/shell_card_management_ap_is/models/card_details_response_card_block_schedules_items_all_of0.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_card_delivery_address.rb +6 -15
- data/lib/shell_card_management_ap_is/models/card_details_response_fuel_sets_items.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_non_fuel_sets_items.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_details_response_pin_delivery_address.rb +6 -15
- data/lib/shell_card_management_ap_is/models/card_group_request.rb +6 -12
- data/lib/shell_card_management_ap_is/models/card_group_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/card_group_response_card_groups_items.rb +10 -20
- data/lib/shell_card_management_ap_is/models/card_management_v1_cancel_request.rb +104 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_ordercard_request.rb +59 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_pinreminder_request.rb +130 -0
- data/lib/shell_card_management_ap_is/models/card_management_v1_updatestatus_request.rb +122 -0
- data/lib/shell_card_management_ap_is/models/card_move_request.rb +4 -9
- data/lib/shell_card_management_ap_is/models/card_move_request_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_move_response.rb +2 -4
- data/lib/shell_card_management_ap_is/models/card_move_response_error_cards_items.rb +2 -5
- data/lib/shell_card_management_ap_is/models/card_move_response_successful_requests_items.rb +2 -5
- data/lib/shell_card_management_ap_is/models/{restriction_card_request.rb → card_restriction_req.rb} +42 -50
- data/lib/shell_card_management_ap_is/models/card_restriction_response.rb +96 -0
- data/lib/shell_card_management_ap_is/models/card_search_response.rb +2 -7
- data/lib/shell_card_management_ap_is/models/card_settings.rb +626 -0
- data/lib/shell_card_management_ap_is/models/card_summary_request.rb +3 -5
- data/lib/shell_card_management_ap_is/models/card_summary_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_type_request.rb +3 -7
- data/lib/shell_card_management_ap_is/models/card_type_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/card_type_response_customer_card_types_items.rb +15 -31
- data/lib/shell_card_management_ap_is/models/card_type_response_error.rb +1 -2
- data/lib/shell_card_management_ap_is/models/card_usage_restrictions.rb +5 -10
- data/lib/shell_card_management_ap_is/models/col_co_access.rb +2 -4
- data/lib/shell_card_management_ap_is/models/{location_restrictions_country_restrictions.rb → country_restriction.rb} +20 -21
- data/lib/shell_card_management_ap_is/models/create_bundle_request.rb +64 -62
- data/lib/shell_card_management_ap_is/models/create_bundle_response.rb +122 -47
- data/lib/shell_card_management_ap_is/models/create_card_group_request.rb +3 -9
- data/lib/shell_card_management_ap_is/models/create_card_group_request_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_group_response.rb +2 -5
- data/lib/shell_card_management_ap_is/models/create_card_group_response_error_cards_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_group_response_successful_requests_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/create_card_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/customer_contract.rb +1 -2
- data/lib/shell_card_management_ap_is/models/customer_detail_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/customer_detail_response.rb +31 -45
- data/lib/shell_card_management_ap_is/models/day_time_restriction.rb +133 -0
- data/lib/shell_card_management_ap_is/models/day_time_restrictions.rb +52 -82
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_request.rb → default_error.rb} +10 -10
- data/lib/shell_card_management_ap_is/models/default_error_fault.rb +4 -5
- data/lib/shell_card_management_ap_is/models/delete_bundle_request.rb +14 -16
- data/lib/shell_card_management_ap_is/models/delete_bundle_response.rb +9 -10
- data/lib/shell_card_management_ap_is/models/delivery_address_update.rb +13 -11
- data/lib/shell_card_management_ap_is/models/delivery_address_update_references.rb +2 -5
- data/lib/shell_card_management_ap_is/models/delivery_address_update_references2.rb +98 -0
- data/lib/shell_card_management_ap_is/models/delivery_address_update_request.rb +3 -7
- data/lib/shell_card_management_ap_is/models/delivery_address_update_response.rb +5 -14
- data/lib/shell_card_management_ap_is/models/delivery_addresses.rb +7 -18
- data/lib/shell_card_management_ap_is/models/detail.rb +50 -0
- data/lib/shell_card_management_ap_is/models/eid_access.rb +1 -2
- data/lib/shell_card_management_ap_is/models/error_details.rb +1 -3
- data/lib/shell_card_management_ap_is/models/error_status.rb +1 -2
- data/lib/shell_card_management_ap_is/models/error_user_access_error.rb +1 -2
- data/lib/shell_card_management_ap_is/models/fault.rb +59 -0
- data/lib/shell_card_management_ap_is/models/filters.rb +702 -0
- data/lib/shell_card_management_ap_is/models/filters1.rb +579 -0
- data/lib/shell_card_management_ap_is/models/filters2.rb +200 -0
- data/lib/shell_card_management_ap_is/models/finance_currency.rb +1 -2
- data/lib/shell_card_management_ap_is/models/finance_currency2.rb +96 -0
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request.rb → fleetmanagement_v1_customer_payers400_error1.rb} +10 -10
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_customer_payers404_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser400_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser401_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser404_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser500_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v1_user_loggedinuser_request.rb +104 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v2_restriction_searchcard401_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/fleetmanagement_v2_restriction_searchcard500_error1.rb +50 -0
- data/lib/shell_card_management_ap_is/models/generate_pin_key_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/invoice_distribution_method.rb +2 -4
- data/lib/shell_card_management_ap_is/models/{location_restrictions.rb → location_restriction.rb} +20 -35
- data/lib/shell_card_management_ap_is/models/logged_in_user_request.rb +2 -4
- data/lib/shell_card_management_ap_is/models/logged_in_user_response.rb +12 -25
- data/lib/shell_card_management_ap_is/models/{location_restrictions_network_restrictions_items.rb → network_restriction.rb} +18 -20
- data/lib/shell_card_management_ap_is/models/o_auth_token.rb +2 -6
- data/lib/shell_card_management_ap_is/models/order_card_enquiry.rb +48 -45
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_req.rb +5 -12
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_request.rb +3 -4
- data/lib/shell_card_management_ap_is/models/order_card_enquiry_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/order_card_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/{location_restrictions_partner_site_restrictions_items.rb → partner_site_restriction.rb} +10 -12
- data/lib/shell_card_management_ap_is/models/payer_access.rb +3 -8
- data/lib/shell_card_management_ap_is/models/payer_details.rb +55 -96
- data/lib/shell_card_management_ap_is/models/payer_request.rb +9 -12
- data/lib/shell_card_management_ap_is/models/payer_response.rb +2 -6
- data/lib/shell_card_management_ap_is/models/payers.rb +2 -5
- data/lib/shell_card_management_ap_is/models/pin_advice_types.rb +5 -6
- data/lib/shell_card_management_ap_is/models/pin_contact.rb +234 -0
- data/lib/shell_card_management_ap_is/models/pin_deliver_to.rb +161 -0
- data/lib/shell_card_management_ap_is/models/pin_delivery_address.rb +222 -0
- data/lib/shell_card_management_ap_is/models/pin_delivery_contact.rb +7 -14
- data/lib/shell_card_management_ap_is/models/pin_delivery_details.rb +4 -11
- data/lib/shell_card_management_ap_is/models/pin_reminder_card_details.rb +19 -17
- data/lib/shell_card_management_ap_is/models/pin_reminder_reference.rb +2 -5
- data/lib/shell_card_management_ap_is/models/pin_reminder_request.rb +2 -6
- data/lib/shell_card_management_ap_is/models/pin_reminder_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/product_all_of0.rb +1 -2
- data/lib/shell_card_management_ap_is/models/product_group.rb +2 -6
- data/lib/shell_card_management_ap_is/models/{product_restrictions.rb → product_restriction_card.rb} +9 -12
- data/lib/shell_card_management_ap_is/models/purchase_categories.rb +1 -4
- data/lib/shell_card_management_ap_is/models/purchase_category1_all_of0.rb +10 -15
- data/lib/shell_card_management_ap_is/models/purchase_category_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/purchase_category_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/replace_card_settings.rb +25 -40
- data/lib/shell_card_management_ap_is/models/restriction.rb +82 -0
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_response_data_items.rb → restriction_card_list.rb} +284 -328
- data/lib/shell_card_management_ap_is/models/{restriction_card_request_cards_items.rb → restriction_cards_list.rb} +69 -82
- data/lib/shell_card_management_ap_is/models/restriction_product.rb +62 -0
- data/lib/shell_card_management_ap_is/models/{restriction_card_response_data_items.rb → restrictioncards_res.rb} +100 -114
- data/lib/shell_card_management_ap_is/models/role.rb +3 -6
- data/lib/shell_card_management_ap_is/models/schedule_card_block_cards_items.rb +42 -39
- data/lib/shell_card_management_ap_is/models/schedule_card_block_request.rb +1 -2
- data/lib/shell_card_management_ap_is/models/schedule_card_block_response.rb +1 -3
- data/lib/shell_card_management_ap_is/models/schedule_card_block_response_data_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/search_account_limit_request.rb +79 -10
- data/lib/shell_card_management_ap_is/models/search_account_limit_response.rb +74 -20
- data/lib/shell_card_management_ap_is/models/search_card.rb +13 -3
- data/lib/shell_card_management_ap_is/models/search_card_request.rb +4 -6
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request_filters_cards_items.rb → search_card_restriction.rb} +19 -16
- data/lib/shell_card_management_ap_is/models/{restriction_search_card_request_filters.rb → search_card_restriction_req.rb} +72 -71
- data/lib/shell_card_management_ap_is/models/search_card_restriction_res.rb +89 -0
- data/lib/shell_card_management_ap_is/models/search_product_restriction.rb +3 -4
- data/lib/shell_card_management_ap_is/models/search_request.rb +25 -47
- data/lib/shell_card_management_ap_is/models/{location_restrictions_shell_site_restrictions_items.rb → shell_site_restriction.rb} +10 -17
- data/lib/shell_card_management_ap_is/models/submitted_card.rb +24 -9
- data/lib/shell_card_management_ap_is/models/summary_request.rb +21 -39
- data/lib/shell_card_management_ap_is/models/summary_response.rb +5 -11
- data/lib/shell_card_management_ap_is/models/{summary_of_bundle_response_data_items.rb → summaryofbundle_response.rb} +36 -33
- data/lib/shell_card_management_ap_is/models/{summaryof_bundle.rb → summaryofbundler_request.rb} +43 -36
- data/lib/shell_card_management_ap_is/models/update_bundle_request.rb +65 -70
- data/lib/shell_card_management_ap_is/models/update_bundle_response.rb +75 -21
- data/lib/shell_card_management_ap_is/models/update_card.rb +31 -20
- data/lib/shell_card_management_ap_is/models/update_card_group_request.rb +9 -17
- data/lib/shell_card_management_ap_is/models/update_card_group_response.rb +3 -6
- data/lib/shell_card_management_ap_is/models/update_card_group_response_move_card_references_items.rb +1 -3
- data/lib/shell_card_management_ap_is/models/update_card_renewal_address.rb +5 -11
- data/lib/shell_card_management_ap_is/models/update_card_renewal_address2.rb +155 -0
- data/lib/shell_card_management_ap_is/models/update_card_status_request.rb +1 -3
- data/lib/shell_card_management_ap_is/models/update_card_status_response.rb +2 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_request.rb +2 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_request_m_pay_requests_items.rb +3 -5
- data/lib/shell_card_management_ap_is/models/update_m_pay_reg_status_response.rb +1 -2
- data/lib/shell_card_management_ap_is/models/usage_restriction.rb +1127 -0
- data/lib/shell_card_management_ap_is/models/{usage_restrictions.rb → usage_restrictions_card.rb} +74 -131
- data/lib/shell_card_management_ap_is/utilities/file_wrapper.rb +9 -9
- data/lib/shell_card_management_ap_is.rb +139 -95
- metadata +74 -38
- data/lib/shell_card_management_ap_is/models/create_bundle_request_restrictions.rb +0 -147
- data/lib/shell_card_management_ap_is/models/create_bundle_response_data_items.rb +0 -125
- data/lib/shell_card_management_ap_is/models/restriction_card_response.rb +0 -91
- data/lib/shell_card_management_ap_is/models/restriction_search_card_response.rb +0 -79
- data/lib/shell_card_management_ap_is/models/search_account_limit_response_data.rb +0 -106
- data/lib/shell_card_management_ap_is/models/search_card_response_restrictions.rb +0 -99
- data/lib/shell_card_management_ap_is/models/summary_of_bundle_response.rb +0 -79
- data/lib/shell_card_management_ap_is/models/url_enum.rb +0 -23
@@ -6,6 +6,157 @@
|
|
6
6
|
module ShellCardManagementApIs
|
7
7
|
# RestrictionController
|
8
8
|
class RestrictionController < BaseController
|
9
|
+
# This API will allows querying card details including the day/time and
|
10
|
+
# product restrictions.
|
11
|
+
# #### Supported operations
|
12
|
+
# * Search by list of cards or bundle
|
13
|
+
# * Include card bundle details (optional)
|
14
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
15
|
+
# specific environment which needs to be passed by the client.
|
16
|
+
# @param [String] request_id Required parameter: Mandatory UUID (according
|
17
|
+
# to RFC 4122 standards) for requests and responses. This will be played
|
18
|
+
# back in the response from the request.
|
19
|
+
# @param [SearchCardRestrictionReq] body Optional parameter: Restriction
|
20
|
+
# search card request body
|
21
|
+
# @return [SearchCardRestrictionRes] response from the API call.
|
22
|
+
def search_card_restriction(apikey,
|
23
|
+
request_id,
|
24
|
+
body: nil)
|
25
|
+
new_api_call_builder
|
26
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
27
|
+
'/fleetmanagement/v2/restriction/searchcard',
|
28
|
+
Server::SHELL)
|
29
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
30
|
+
.header_param(new_parameter(request_id, key: 'RequestId'))
|
31
|
+
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
32
|
+
.body_param(new_parameter(body))
|
33
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
34
|
+
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
35
|
+
.auth(Single.new('BasicAuth')))
|
36
|
+
.response(new_response_handler
|
37
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
38
|
+
.deserialize_into(SearchCardRestrictionRes.method(:from_hash))
|
39
|
+
.local_error('400',
|
40
|
+
"The server cannot or will not process the request due to'\
|
41
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
42
|
+
' malformed request syntax, invalid \r\n request message'\
|
43
|
+
' framing, or deceptive request routing).",
|
44
|
+
APIException)
|
45
|
+
.local_error('401',
|
46
|
+
'The request has not been applied because it lacks valid '\
|
47
|
+
' authentication credentials for the target resource.',
|
48
|
+
FleetmanagementV2RestrictionSearchcard401ErrorException)
|
49
|
+
.local_error('403',
|
50
|
+
'The server understood the request but refuses to authorize it'\
|
51
|
+
'.',
|
52
|
+
APIException)
|
53
|
+
.local_error('404',
|
54
|
+
'The origin server did not find a current representation for'\
|
55
|
+
' the target resource or is not willing to disclose that one'\
|
56
|
+
' exists.',
|
57
|
+
APIException)
|
58
|
+
.local_error('500',
|
59
|
+
'The server encountered an unexpected condition the prevented'\
|
60
|
+
' it from fulfilling the request.',
|
61
|
+
FleetmanagementV2RestrictionSearchcard500ErrorException))
|
62
|
+
.execute
|
63
|
+
end
|
64
|
+
|
65
|
+
# The Card Limit and Restriction API is REST-based and employs Basic and
|
66
|
+
# ApiKey authentication. The API endpoints accept JSON-encoded request
|
67
|
+
# bodies, return JSON-encoded responses and use standard HTTP response
|
68
|
+
# codes.
|
69
|
+
# All resources are located in the Shell Card Platform. The Shell Card
|
70
|
+
# Platform is the overall platform that encompasses all the internal Shell
|
71
|
+
# systems used to manage resources. The internal workings of the platform
|
72
|
+
# are not important when interacting with the API. However, it is worth
|
73
|
+
# noting that the platform uses a microservice architecture to communicate
|
74
|
+
# with various backend systems and some API calls are processed
|
75
|
+
# asynchronously.
|
76
|
+
# All endpoints use the `POST` verb for retrieving, updating, creating and
|
77
|
+
# deleting resources in the Shell Card Platform. The endpoints that retrieve
|
78
|
+
# resources from the Shell Card Platform allow flexible search parameters in
|
79
|
+
# the API request body.
|
80
|
+
# **Important Note** - This operation allows setting or updating the
|
81
|
+
# restrictions on existing cards. (For up to 3 cards in a single call).
|
82
|
+
# All restrictions of the cards are submitted and executed after successful
|
83
|
+
# below condition.
|
84
|
+
# • The card exists.
|
85
|
+
# • Day time restriction cannot be set to restrict the use of a card on
|
86
|
+
# all days of the week i.e., the values for all the days in the restriction
|
87
|
+
# cannot be set to false.
|
88
|
+
# • Either of the usage, daytime, location or product restriction ‘Reset’
|
89
|
+
# is set to ‘True’ or applied on the card.
|
90
|
+
# • All the limits in the usage restriction profile for a card is not set
|
91
|
+
# to ‘0’/null.
|
92
|
+
# • If IsVelocityCeiling is ‘true’, API will validate below condition:
|
93
|
+
# Usage restrictions for a card are lower than Customer Card Type level
|
94
|
+
# limits, if there are no customer level overrides available then lower than
|
95
|
+
# OU card type limits.
|
96
|
+
# • In usage restrictions, the limits per transaction should be less than
|
97
|
+
# or equal to Daily, Daily should be less than or equal to Weekly, Weekly
|
98
|
+
# should be less than or equal to Monthly, Monthly should be less than or
|
99
|
+
# equal to Yearly (Annually). Exception being null/blank will be skipped.
|
100
|
+
# i.e., Daily value should be less than equal to Monthly value if Weekly
|
101
|
+
# value is null/blank. Lifetime limit is not considered for usage
|
102
|
+
# restrictions limits validation.
|
103
|
+
# • Apply the card type limit to Gateway when a value is NULL in the
|
104
|
+
# input. However, if the card type limit is NULL for the same field, then no
|
105
|
+
# limit will be applied in Gateway.
|
106
|
+
# • If ‘SetDefaultOnVelocityUpdate’ is ‘true’ then the operation will
|
107
|
+
# apply customer cardtype or OU level velocity limits on existing cards when
|
108
|
+
# restrictions are modified without providing custom values for all fields.
|
109
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
110
|
+
# specific environment which needs to be passed by the client.
|
111
|
+
# @param [String] request_id Required parameter: Mandatory UUID (according
|
112
|
+
# to RFC 4122 standards) for requests and responses. This will be played
|
113
|
+
# back in the response from the request.
|
114
|
+
# @param [CardRestrictionReq] body Optional parameter: Card Restriction
|
115
|
+
# request body
|
116
|
+
# @return [CardRestrictionResponse] response from the API call.
|
117
|
+
def apply_restriction(apikey,
|
118
|
+
request_id,
|
119
|
+
body: nil)
|
120
|
+
new_api_call_builder
|
121
|
+
.request(new_request_builder(HttpMethodEnum::POST,
|
122
|
+
'/fleetmanagement/v2/restriction/card',
|
123
|
+
Server::SHELL)
|
124
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
125
|
+
.header_param(new_parameter(request_id, key: 'RequestId'))
|
126
|
+
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
127
|
+
.body_param(new_parameter(body))
|
128
|
+
.header_param(new_parameter('application/json', key: 'accept'))
|
129
|
+
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
130
|
+
.auth(Single.new('BasicAuth')))
|
131
|
+
.response(new_response_handler
|
132
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
133
|
+
.deserialize_into(CardRestrictionResponse.method(:from_hash))
|
134
|
+
.local_error('400',
|
135
|
+
"The server cannot or will not process the request due to'\
|
136
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
137
|
+
' malformed request syntax, invalid \r\n request message'\
|
138
|
+
' framing, or deceptive request routing).",
|
139
|
+
APIException)
|
140
|
+
.local_error('401',
|
141
|
+
'The request has not been applied because it lacks valid '\
|
142
|
+
' authentication credentials for the target resource.',
|
143
|
+
APIException)
|
144
|
+
.local_error('403',
|
145
|
+
'The server understood the request but refuses to authorize it'\
|
146
|
+
'.',
|
147
|
+
APIException)
|
148
|
+
.local_error('404',
|
149
|
+
'The origin server did not find a current representation for'\
|
150
|
+
' the target resource or is not willing to disclose that one'\
|
151
|
+
' exists.',
|
152
|
+
APIException)
|
153
|
+
.local_error('500',
|
154
|
+
'The server encountered an unexpected condition the prevented'\
|
155
|
+
' it from fulfilling the request.',
|
156
|
+
APIException))
|
157
|
+
.execute
|
158
|
+
end
|
159
|
+
|
9
160
|
# This API enables clients to create a new card bundle and apply
|
10
161
|
# restrictions.
|
11
162
|
# #### Supported operations
|
@@ -35,49 +186,54 @@ module ShellCardManagementApIs
|
|
35
186
|
# Monthly value if Weekly value is 0/blank.
|
36
187
|
# * `0007` - Error returned if request parameters fail validation e.g.
|
37
188
|
# mandatory check.
|
189
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
190
|
+
# specific environment which needs to be passed by the client.
|
38
191
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
39
192
|
# to RFC 4122 standards) for requests and responses. This will be played
|
40
193
|
# back in the response from the request.
|
41
|
-
# @param [CreateBundleRequest] body Optional parameter:
|
42
|
-
#
|
43
|
-
# @return [CreateBundleResponse] response from the API call
|
44
|
-
def
|
45
|
-
|
194
|
+
# @param [CreateBundleRequest] body Optional parameter: CreateBundle request
|
195
|
+
# body
|
196
|
+
# @return [CreateBundleResponse] response from the API call.
|
197
|
+
def create_bundle(apikey,
|
198
|
+
request_id,
|
199
|
+
body: nil)
|
46
200
|
new_api_call_builder
|
47
201
|
.request(new_request_builder(HttpMethodEnum::POST,
|
48
|
-
'/
|
49
|
-
Server::
|
202
|
+
'/fleetmanagement/v1/restriction/createbundle',
|
203
|
+
Server::SHELL)
|
204
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
50
205
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
51
206
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
52
207
|
.body_param(new_parameter(body))
|
53
208
|
.header_param(new_parameter('application/json', key: 'accept'))
|
54
209
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
55
|
-
.auth(Single.new('
|
210
|
+
.auth(Single.new('BasicAuth')))
|
56
211
|
.response(new_response_handler
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
'
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
|
79
|
-
'
|
80
|
-
|
212
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
213
|
+
.deserialize_into(CreateBundleResponse.method(:from_hash))
|
214
|
+
.local_error('400',
|
215
|
+
"The server cannot or will not process the request due to'\
|
216
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
217
|
+
' malformed request syntax, invalid \r\n request message'\
|
218
|
+
' framing, or deceptive request routing).",
|
219
|
+
APIException)
|
220
|
+
.local_error('401',
|
221
|
+
'The request has not been applied because it lacks valid '\
|
222
|
+
' authentication credentials for the target resource.',
|
223
|
+
APIException)
|
224
|
+
.local_error('403',
|
225
|
+
'The server understood the request but refuses to authorize it'\
|
226
|
+
'.',
|
227
|
+
APIException)
|
228
|
+
.local_error('404',
|
229
|
+
'The origin server did not find a current representation for'\
|
230
|
+
' the target resource or is not willing to disclose that one'\
|
231
|
+
' exists.',
|
232
|
+
APIException)
|
233
|
+
.local_error('500',
|
234
|
+
'The server encountered an unexpected condition the prevented'\
|
235
|
+
' it from fulfilling the request.',
|
236
|
+
APIException))
|
81
237
|
.execute
|
82
238
|
end
|
83
239
|
|
@@ -118,49 +274,54 @@ module ShellCardManagementApIs
|
|
118
274
|
# for Update request action.
|
119
275
|
# * `0007` - Error returned if request parameters fail validation e.g. at
|
120
276
|
# least one card must be provided in the input.
|
277
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
278
|
+
# specific environment which needs to be passed by the client.
|
121
279
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
122
280
|
# to RFC 4122 standards) for requests and responses. This will be played
|
123
281
|
# back in the response from the request.
|
124
282
|
# @param [UpdateBundleRequest] body Optional parameter: Update Bundle
|
125
|
-
#
|
126
|
-
# @return [UpdateBundleResponse] response from the API call
|
127
|
-
def
|
128
|
-
|
283
|
+
# request body
|
284
|
+
# @return [UpdateBundleResponse] response from the API call.
|
285
|
+
def update_bundle(apikey,
|
286
|
+
request_id,
|
287
|
+
body: nil)
|
129
288
|
new_api_call_builder
|
130
289
|
.request(new_request_builder(HttpMethodEnum::POST,
|
131
|
-
'/
|
132
|
-
Server::
|
290
|
+
'/fleetmanagement/v1/restriction/updatebundle',
|
291
|
+
Server::SHELL)
|
292
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
133
293
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
134
294
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
135
295
|
.body_param(new_parameter(body))
|
136
296
|
.header_param(new_parameter('application/json', key: 'accept'))
|
137
297
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
138
|
-
.auth(Single.new('
|
298
|
+
.auth(Single.new('BasicAuth')))
|
139
299
|
.response(new_response_handler
|
140
|
-
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
'
|
158
|
-
|
159
|
-
|
160
|
-
|
161
|
-
|
162
|
-
'
|
163
|
-
|
300
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
301
|
+
.deserialize_into(UpdateBundleResponse.method(:from_hash))
|
302
|
+
.local_error('400',
|
303
|
+
"The server cannot or will not process the request due to'\
|
304
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
305
|
+
' malformed request syntax, invalid \r\n request message'\
|
306
|
+
' framing, or deceptive request routing).",
|
307
|
+
APIException)
|
308
|
+
.local_error('401',
|
309
|
+
'The request has not been applied because it lacks valid '\
|
310
|
+
' authentication credentials for the target resource.',
|
311
|
+
APIException)
|
312
|
+
.local_error('403',
|
313
|
+
'The server understood the request but refuses to authorize it'\
|
314
|
+
'.',
|
315
|
+
APIException)
|
316
|
+
.local_error('404',
|
317
|
+
'The origin server did not find a current representation for'\
|
318
|
+
' the target resource or is not willing to disclose that one'\
|
319
|
+
' exists.',
|
320
|
+
APIException)
|
321
|
+
.local_error('500',
|
322
|
+
'The server encountered an unexpected condition the prevented'\
|
323
|
+
' it from fulfilling the request.',
|
324
|
+
APIException))
|
164
325
|
.execute
|
165
326
|
end
|
166
327
|
|
@@ -177,49 +338,54 @@ module ShellCardManagementApIs
|
|
177
338
|
# Platform.
|
178
339
|
# * `0007` - Error returned if request parameters fail validation e.g.
|
179
340
|
# mandatory check.
|
341
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
342
|
+
# specific environment which needs to be passed by the client.
|
180
343
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
181
344
|
# to RFC 4122 standards) for requests and responses. This will be played
|
182
345
|
# back in the response from the request.
|
183
|
-
# @param [DeleteBundleRequest] body Optional parameter:
|
184
|
-
#
|
185
|
-
# @return [DeleteBundleResponse] response from the API call
|
186
|
-
def
|
187
|
-
|
346
|
+
# @param [DeleteBundleRequest] body Optional parameter: Update Bundle
|
347
|
+
# request body
|
348
|
+
# @return [DeleteBundleResponse] response from the API call.
|
349
|
+
def delete_bundle(apikey,
|
350
|
+
request_id,
|
351
|
+
body: nil)
|
188
352
|
new_api_call_builder
|
189
353
|
.request(new_request_builder(HttpMethodEnum::POST,
|
190
|
-
'/
|
191
|
-
Server::
|
354
|
+
'/fleetmanagement/v1/restriction/deletebundle',
|
355
|
+
Server::SHELL)
|
356
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
192
357
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
193
358
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
194
359
|
.body_param(new_parameter(body))
|
195
360
|
.header_param(new_parameter('application/json', key: 'accept'))
|
196
361
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
197
|
-
.auth(Single.new('
|
362
|
+
.auth(Single.new('BasicAuth')))
|
198
363
|
.response(new_response_handler
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
204
|
-
|
205
|
-
|
206
|
-
|
207
|
-
|
208
|
-
|
209
|
-
|
210
|
-
|
211
|
-
|
212
|
-
|
213
|
-
|
214
|
-
|
215
|
-
|
216
|
-
'
|
217
|
-
|
218
|
-
|
219
|
-
|
220
|
-
|
221
|
-
'
|
222
|
-
|
364
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
365
|
+
.deserialize_into(DeleteBundleResponse.method(:from_hash))
|
366
|
+
.local_error('400',
|
367
|
+
"The server cannot or will not process the request due to'\
|
368
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
369
|
+
' malformed request syntax, invalid \r\n request message'\
|
370
|
+
' framing, or deceptive request routing).",
|
371
|
+
APIException)
|
372
|
+
.local_error('401',
|
373
|
+
'The request has not been applied because it lacks valid '\
|
374
|
+
' authentication credentials for the target resource.',
|
375
|
+
APIException)
|
376
|
+
.local_error('403',
|
377
|
+
'The server understood the request but refuses to authorize it'\
|
378
|
+
'.',
|
379
|
+
APIException)
|
380
|
+
.local_error('404',
|
381
|
+
'The origin server did not find a current representation for'\
|
382
|
+
' the target resource or is not willing to disclose that one'\
|
383
|
+
' exists.',
|
384
|
+
APIException)
|
385
|
+
.local_error('500',
|
386
|
+
'The server encountered an unexpected condition the prevented'\
|
387
|
+
' it from fulfilling the request.',
|
388
|
+
APIException))
|
223
389
|
.execute
|
224
390
|
end
|
225
391
|
|
@@ -234,130 +400,86 @@ module ShellCardManagementApIs
|
|
234
400
|
# left blank/null.
|
235
401
|
# #### Supported operations
|
236
402
|
# * Get summary of bundles by list of bundle Ids
|
403
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
404
|
+
# specific environment which needs to be passed by the client.
|
237
405
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
238
406
|
# to RFC 4122 standards) for requests and responses. This will be played
|
239
407
|
# back in the response from the request.
|
240
|
-
# @param [
|
241
|
-
#
|
242
|
-
# @return [
|
243
|
-
def
|
244
|
-
|
245
|
-
new_api_call_builder
|
246
|
-
.request(new_request_builder(HttpMethodEnum::POST,
|
247
|
-
'/card-restrictions/v1/bundles/Summary',
|
248
|
-
Server::DEFAULT)
|
249
|
-
.header_param(new_parameter(request_id, key: 'RequestId'))
|
250
|
-
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
251
|
-
.body_param(new_parameter(body))
|
252
|
-
.header_param(new_parameter('application/json', key: 'accept'))
|
253
|
-
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
254
|
-
.auth(Single.new('BearerToken')))
|
255
|
-
.response(new_response_handler
|
256
|
-
.deserializer(APIHelper.method(:custom_type_deserializer))
|
257
|
-
.deserialize_into(SummaryOfBundleResponse.method(:from_hash))
|
258
|
-
.local_error('400',
|
259
|
-
"The server cannot or will not process the request due to'\
|
260
|
-
' something that is perceived to be a client error (e.g.,'\
|
261
|
-
' malformed request syntax, invalid request message framing, or'\
|
262
|
-
' deceptive request routing).\n",
|
263
|
-
ErrorObjectException)
|
264
|
-
.local_error('401',
|
265
|
-
"The request has not been applied because it lacks valid '\
|
266
|
-
' authentication credentials for the target resource.\n",
|
267
|
-
ErrorObjectException)
|
268
|
-
.local_error('403',
|
269
|
-
'Forbidden',
|
270
|
-
ErrorObjectException)
|
271
|
-
.local_error('404',
|
272
|
-
"The origin server did not find a current representation for'\
|
273
|
-
' the target resource or is not willing to disclose that one'\
|
274
|
-
' exists.\n",
|
275
|
-
ErrorObjectException)
|
276
|
-
.local_error('500',
|
277
|
-
"The server encountered an unexpected condition that prevented'\
|
278
|
-
' it from fulfilling the request.\n",
|
279
|
-
ErrorObjectException))
|
280
|
-
.execute
|
281
|
-
end
|
282
|
-
|
283
|
-
# This API allows to set or update the restrictions for existing cards or
|
284
|
-
# newly ordered cards under the same payer.
|
285
|
-
# #### Supported operations
|
286
|
-
# * Set or reset usage restrictions for cards
|
287
|
-
# * Set or reset day/time restrictions for cards
|
288
|
-
# * Set or reset product restrictions for cards
|
289
|
-
# * Set or reset location restrictions for cards
|
290
|
-
# @param [String] request_id Required parameter: Mandatory UUID (according
|
291
|
-
# to RFC 4122 standards) for requests and responses. This will be played
|
292
|
-
# back in the response from the request.
|
293
|
-
# @param [RestrictionCardRequest] body Optional parameter: Summary Bundle
|
294
|
-
# Request body
|
295
|
-
# @return [RestrictionCardResponse] response from the API call
|
296
|
-
def card_restriction(request_id,
|
408
|
+
# @param [SummaryofbundlerRequest] body Optional parameter: Summary of
|
409
|
+
# Bundle request body
|
410
|
+
# @return [SummaryofbundleResponse] response from the API call.
|
411
|
+
def summaryofbundles(apikey,
|
412
|
+
request_id,
|
297
413
|
body: nil)
|
298
414
|
new_api_call_builder
|
299
415
|
.request(new_request_builder(HttpMethodEnum::POST,
|
300
|
-
'/
|
301
|
-
Server::
|
416
|
+
'/fleetmanagement/v1/restriction/summaryofbundles',
|
417
|
+
Server::SHELL)
|
418
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
302
419
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
303
420
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
304
421
|
.body_param(new_parameter(body))
|
305
422
|
.header_param(new_parameter('application/json', key: 'accept'))
|
306
423
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
307
|
-
.auth(Single.new('
|
424
|
+
.auth(Single.new('BasicAuth')))
|
308
425
|
.response(new_response_handler
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
'
|
327
|
-
|
328
|
-
|
329
|
-
|
330
|
-
|
331
|
-
'
|
332
|
-
|
426
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
427
|
+
.deserialize_into(SummaryofbundleResponse.method(:from_hash))
|
428
|
+
.local_error('400',
|
429
|
+
"The server cannot or will not process the request due to'\
|
430
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
431
|
+
' malformed request syntax, invalid \r\n request message'\
|
432
|
+
' framing, or deceptive request routing).",
|
433
|
+
APIException)
|
434
|
+
.local_error('401',
|
435
|
+
'The request has not been applied because it lacks valid '\
|
436
|
+
' authentication credentials for the target resource.',
|
437
|
+
APIException)
|
438
|
+
.local_error('403',
|
439
|
+
'The server understood the request but refuses to authorize it'\
|
440
|
+
'.',
|
441
|
+
APIException)
|
442
|
+
.local_error('404',
|
443
|
+
'The origin server did not find a current representation for'\
|
444
|
+
' the target resource or is not willing to disclose that one'\
|
445
|
+
' exists.',
|
446
|
+
APIException)
|
447
|
+
.local_error('500',
|
448
|
+
'The server encountered an unexpected condition the prevented'\
|
449
|
+
' it from fulfilling the request.',
|
450
|
+
APIException))
|
333
451
|
.execute
|
334
452
|
end
|
335
453
|
|
336
|
-
# This
|
337
|
-
#
|
338
|
-
#
|
339
|
-
#
|
340
|
-
#
|
341
|
-
# the account, on all days of the week.
|
342
|
-
#
|
343
|
-
# new restriction values provided for the account.
|
344
|
-
#
|
345
|
-
# equal to Daily, Daily should be less than or equal to Weekly, Weekly
|
454
|
+
# This API allows setting or updating the usage restrictions of an existing
|
455
|
+
# account.
|
456
|
+
# Then validation rules applied for this API.
|
457
|
+
# • The account exists.
|
458
|
+
# • Day time restriction cannot be set to restrict the use of a card,
|
459
|
+
# under the account, on all days of the week.
|
460
|
+
# • Either of the usage, daytime or location is either marked for reset
|
461
|
+
# or new restriction values provided for the account.
|
462
|
+
# • In usage restrictions, the limits per transaction should be less than
|
463
|
+
# or equal to Daily, Daily should be less than or equal to Weekly, Weekly
|
346
464
|
# should be less than or equal to Monthly. Exception being 0/blank will be
|
347
465
|
# skipped, i.e., Daily value should be less than equal to Monthly value if
|
348
466
|
# Weekly value is 0/blank.
|
467
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
468
|
+
# specific environment which needs to be passed by the client.
|
349
469
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
350
470
|
# to RFC 4122 standards) for requests and responses. This will be played
|
351
471
|
# back in the response from the request.
|
352
|
-
# @param [AccountRestrictionRequest] body Optional parameter:
|
353
|
-
#
|
354
|
-
# @return [AccountRestrictionResponse] response from the API call
|
355
|
-
def
|
472
|
+
# @param [AccountRestrictionRequest] body Optional parameter: Account
|
473
|
+
# Restriction request body
|
474
|
+
# @return [AccountRestrictionResponse] response from the API call.
|
475
|
+
def restriction_account(apikey,
|
476
|
+
request_id,
|
356
477
|
body: nil)
|
357
478
|
new_api_call_builder
|
358
479
|
.request(new_request_builder(HttpMethodEnum::POST,
|
359
|
-
'/
|
360
|
-
Server::
|
480
|
+
'/fleetmanagement/v1/restriction/account',
|
481
|
+
Server::SHELL)
|
482
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
361
483
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
362
484
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
363
485
|
.body_param(new_parameter(body))
|
@@ -365,131 +487,139 @@ module ShellCardManagementApIs
|
|
365
487
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
366
488
|
.auth(Single.new('BearerToken')))
|
367
489
|
.response(new_response_handler
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
375
|
-
|
376
|
-
|
377
|
-
|
378
|
-
|
379
|
-
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
'
|
386
|
-
|
387
|
-
|
388
|
-
|
389
|
-
|
390
|
-
'
|
391
|
-
|
490
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
491
|
+
.deserialize_into(AccountRestrictionResponse.method(:from_hash))
|
492
|
+
.local_error('400',
|
493
|
+
"The server cannot or will not process the request due to'\
|
494
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
495
|
+
' malformed request syntax, invalid \r\n request message'\
|
496
|
+
' framing, or deceptive request routing).",
|
497
|
+
APIException)
|
498
|
+
.local_error('401',
|
499
|
+
'The request has not been applied because it lacks valid '\
|
500
|
+
' authentication credentials for the target resource.',
|
501
|
+
APIException)
|
502
|
+
.local_error('403',
|
503
|
+
'The server understood the request but refuses to authorize it'\
|
504
|
+
'.',
|
505
|
+
APIException)
|
506
|
+
.local_error('404',
|
507
|
+
'The origin server did not find a current representation for'\
|
508
|
+
' the target resource or is not willing to disclose that one'\
|
509
|
+
' exists.',
|
510
|
+
APIException)
|
511
|
+
.local_error('500',
|
512
|
+
'The server encountered an unexpected condition the prevented'\
|
513
|
+
' it from fulfilling the request.',
|
514
|
+
APIException))
|
392
515
|
.execute
|
393
516
|
end
|
394
517
|
|
395
|
-
# This
|
396
|
-
# account.
|
397
|
-
#
|
398
|
-
#
|
518
|
+
# This API will allow user to get account level limits for the given
|
519
|
+
# account. It returns the velocity limits if its overridden at the account
|
520
|
+
# else the values will be null/empty.
|
521
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
522
|
+
# specific environment which needs to be passed by the client.
|
399
523
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
400
524
|
# to RFC 4122 standards) for requests and responses. This will be played
|
401
525
|
# back in the response from the request.
|
402
|
-
# @param [SearchAccountLimitRequest] body Optional parameter:
|
403
|
-
#
|
404
|
-
# @return [SearchAccountLimitResponse] response from the API call
|
405
|
-
def search_account_limit(
|
526
|
+
# @param [SearchAccountLimitRequest] body Optional parameter: Search Account
|
527
|
+
# Limit RequestBody
|
528
|
+
# @return [SearchAccountLimitResponse] response from the API call.
|
529
|
+
def search_account_limit(apikey,
|
530
|
+
request_id,
|
406
531
|
body: nil)
|
407
532
|
new_api_call_builder
|
408
533
|
.request(new_request_builder(HttpMethodEnum::POST,
|
409
|
-
'/
|
410
|
-
Server::
|
534
|
+
'/fleetmanagement/v1/restriction/searchaccountlimit',
|
535
|
+
Server::SHELL)
|
536
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
411
537
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
412
538
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
413
539
|
.body_param(new_parameter(body))
|
414
540
|
.header_param(new_parameter('application/json', key: 'accept'))
|
415
541
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
416
|
-
.auth(Single.new('
|
542
|
+
.auth(Single.new('BasicAuth')))
|
417
543
|
.response(new_response_handler
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
|
435
|
-
'
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
'
|
441
|
-
|
544
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
545
|
+
.deserialize_into(SearchAccountLimitResponse.method(:from_hash))
|
546
|
+
.local_error('400',
|
547
|
+
"The server cannot or will not process the request due to'\
|
548
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
549
|
+
' malformed request syntax, invalid \r\n request message'\
|
550
|
+
' framing, or deceptive request routing).",
|
551
|
+
APIException)
|
552
|
+
.local_error('401',
|
553
|
+
'The request has not been applied because it lacks valid '\
|
554
|
+
' authentication credentials for the target resource.',
|
555
|
+
APIException)
|
556
|
+
.local_error('403',
|
557
|
+
'The server understood the request but refuses to authorize it'\
|
558
|
+
'.',
|
559
|
+
APIException)
|
560
|
+
.local_error('404',
|
561
|
+
'The origin server did not find a current representation for'\
|
562
|
+
' the target resource or is not willing to disclose that one'\
|
563
|
+
' exists.',
|
564
|
+
APIException)
|
565
|
+
.local_error('500',
|
566
|
+
'The server encountered an unexpected condition the prevented'\
|
567
|
+
' it from fulfilling the request.',
|
568
|
+
APIException))
|
442
569
|
.execute
|
443
570
|
end
|
444
571
|
|
445
|
-
# This API
|
446
|
-
#
|
447
|
-
#
|
448
|
-
#
|
449
|
-
#
|
572
|
+
# This API allows to get the details of a specific card bundle. It returns
|
573
|
+
# the bundle basic details along with the cards in the bundle and
|
574
|
+
# restrictions applied on them.
|
575
|
+
# @param [String] apikey Required parameter: This is the API key of the
|
576
|
+
# specific environment which needs to be passed by the client.
|
450
577
|
# @param [String] request_id Required parameter: Mandatory UUID (according
|
451
578
|
# to RFC 4122 standards) for requests and responses. This will be played
|
452
579
|
# back in the response from the request.
|
453
|
-
# @param [
|
454
|
-
#
|
455
|
-
# @return [
|
456
|
-
def
|
457
|
-
|
580
|
+
# @param [BudleDetailsRequest] body Optional parameter: Bundle Details
|
581
|
+
# Request body
|
582
|
+
# @return [BundleDetailsResponse] response from the API call.
|
583
|
+
def bundledetails(apikey,
|
584
|
+
request_id,
|
585
|
+
body: nil)
|
458
586
|
new_api_call_builder
|
459
587
|
.request(new_request_builder(HttpMethodEnum::POST,
|
460
|
-
'/
|
461
|
-
Server::
|
588
|
+
'/fleetmanagement/v1/restriction/bundledetails',
|
589
|
+
Server::SHELL)
|
590
|
+
.header_param(new_parameter(apikey, key: 'apikey'))
|
462
591
|
.header_param(new_parameter(request_id, key: 'RequestId'))
|
463
592
|
.header_param(new_parameter('application/json', key: 'Content-Type'))
|
464
593
|
.body_param(new_parameter(body))
|
465
594
|
.header_param(new_parameter('application/json', key: 'accept'))
|
466
595
|
.body_serializer(proc do |param| param.to_json unless param.nil? end)
|
467
|
-
.auth(Single.new('
|
596
|
+
.auth(Single.new('BasicAuth')))
|
468
597
|
.response(new_response_handler
|
469
|
-
|
470
|
-
|
471
|
-
|
472
|
-
|
473
|
-
|
474
|
-
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
|
484
|
-
|
485
|
-
|
486
|
-
'
|
487
|
-
|
488
|
-
|
489
|
-
|
490
|
-
|
491
|
-
'
|
492
|
-
|
598
|
+
.deserializer(APIHelper.method(:custom_type_deserializer))
|
599
|
+
.deserialize_into(BundleDetailsResponse.method(:from_hash))
|
600
|
+
.local_error('400',
|
601
|
+
"The server cannot or will not process the request due to'\
|
602
|
+
' something that is perceived to be a client\r\n error (e.g.,'\
|
603
|
+
' malformed request syntax, invalid \r\n request message'\
|
604
|
+
' framing, or deceptive request routing).",
|
605
|
+
APIException)
|
606
|
+
.local_error('401',
|
607
|
+
'The request has not been applied because it lacks valid '\
|
608
|
+
' authentication credentials for the target resource.',
|
609
|
+
APIException)
|
610
|
+
.local_error('403',
|
611
|
+
'The server understood the request but refuses to authorize it'\
|
612
|
+
'.',
|
613
|
+
APIException)
|
614
|
+
.local_error('404',
|
615
|
+
'The origin server did not find a current representation for'\
|
616
|
+
' the target resource or is not willing to disclose that one'\
|
617
|
+
' exists.',
|
618
|
+
APIException)
|
619
|
+
.local_error('500',
|
620
|
+
'The server encountered an unexpected condition the prevented'\
|
621
|
+
' it from fulfilling the request.',
|
622
|
+
APIException))
|
493
623
|
.execute
|
494
624
|
end
|
495
625
|
end
|