citypay_api_client 1.1.1 → 1.1.3
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/Gemfile.lock +73 -0
- data/README.md +65 -37
- data/citypay_api_client.gemspec +4 -3
- data/docs/Acknowledgement.md +2 -2
- data/docs/AclCheckResponseModel.md +3 -3
- data/docs/AirlineAdvice.md +1 -1
- data/docs/AuthRequest.md +9 -7
- data/docs/AuthResponse.md +9 -5
- data/docs/AuthorisationAndPaymentApi.md +145 -10
- data/docs/Batch.md +1 -1
- data/docs/BatchProcessingApi.md +24 -20
- data/docs/BatchReportResponseModel.md +2 -2
- data/docs/BatchTransaction.md +1 -1
- data/docs/BatchTransactionReportRequest.md +22 -0
- data/docs/BatchTransactionReportResponse.md +24 -0
- data/docs/BatchTransactionResultModel.md +6 -2
- data/docs/Bin.md +2 -2
- data/docs/CaptureRequest.md +1 -1
- data/docs/Card.md +3 -3
- data/docs/CardHolderAccountApi.md +73 -14
- data/docs/ChargeRequest.md +8 -6
- data/docs/ContactDetails.md +11 -11
- data/docs/Decision.md +0 -2
- data/docs/DirectPostApi.md +26 -16
- data/docs/DirectPostRequest.md +9 -7
- data/docs/EventDataModel.md +2 -2
- data/docs/MerchantBatchReportRequest.md +28 -0
- data/docs/MerchantBatchReportResponse.md +24 -0
- data/docs/MerchantBatchResponse.md +30 -0
- data/docs/NetSummaryResponse.md +32 -0
- data/docs/OperationalFunctionsApi.md +28 -8
- data/docs/PaylinkAdjustmentRequest.md +1 -1
- data/docs/PaylinkApi.md +337 -21
- data/docs/PaylinkBillPaymentTokenRequest.md +1 -1
- data/docs/PaylinkCustomParam.md +3 -1
- data/docs/PaylinkErrorCode.md +2 -2
- data/docs/PaylinkFieldGuardModel.md +1 -1
- data/docs/PaylinkResendNotificationRequest.md +20 -0
- data/docs/PaylinkStateEvent.md +4 -4
- data/docs/PaylinkTokenCreated.md +11 -11
- data/docs/PaylinkTokenRequestModel.md +4 -0
- data/docs/PaylinkTokenStatus.md +7 -7
- data/docs/PaylinkTokenStatusChangeRequest.md +7 -7
- data/docs/PaylinkTokenStatusChangeResponse.md +6 -2
- data/docs/PaymentIntent.md +42 -0
- data/docs/PaymentIntentReference.md +18 -0
- data/docs/RefundRequest.md +1 -1
- data/docs/RegisterCard.md +1 -1
- data/docs/RemittanceData.md +28 -0
- data/docs/RemittanceReportRequest.md +28 -0
- data/docs/RemittanceReportResponse.md +24 -0
- data/docs/RemittedClientData.md +44 -0
- data/docs/ReportingApi.md +378 -0
- data/docs/ThreeDSecure.md +1 -1
- data/docs/TokenisationResponseModel.md +3 -3
- data/docs/images/3dsv1-challenge.png +0 -0
- data/docs/images/3dsv2-challenge.png +0 -0
- data/docs/images/3dsv2-frictionless.png +0 -0
- data/docs/images/3dsv2-method-challenge.png +0 -0
- data/docs/images/3dsv2-method-frictionless.png +0 -0
- data/docs/images/3dsv2-no3d.png +0 -0
- data/docs/images/citypay-logo.svg +1 -0
- data/docs/images/direct-post-flow.png +0 -0
- data/docs/images/favicon.ico +0 -0
- data/docs/images/header.png +0 -0
- data/docs/images/logo.ai +1913 -4
- data/docs/images/logo.png +0 -0
- data/docs/images/logo.svg +1 -0
- data/docs/images/merchant-BPS-workflow.png +0 -0
- data/docs/images/paylink-field-guards.png +0 -0
- data/lib/citypay_api_client/api/authorisation_and_payment_api__.rb +72 -4
- data/lib/citypay_api_client/api/batch_processing_api__.rb +15 -15
- data/lib/citypay_api_client/api/card_holder_account_api__.rb +5 -2
- data/lib/citypay_api_client/api/direct_post_api__.rb +9 -9
- data/lib/citypay_api_client/api/operational_functions_api__.rb +3 -3
- data/lib/citypay_api_client/api/paylink_api__.rb +163 -26
- data/lib/citypay_api_client/api/reporting_api__.rb +381 -0
- data/lib/citypay_api_client/api_client.rb +24 -22
- data/lib/citypay_api_client/api_error.rb +3 -2
- data/lib/citypay_api_client/configuration.rb +28 -9
- data/lib/citypay_api_client/models/account_create.rb +17 -20
- data/lib/citypay_api_client/models/account_status.rb +15 -20
- data/lib/citypay_api_client/models/acknowledgement.rb +21 -46
- data/lib/citypay_api_client/models/acl_check_request.rb +17 -20
- data/lib/citypay_api_client/models/acl_check_response_model.rb +16 -21
- data/lib/citypay_api_client/models/airline_advice.rb +45 -29
- data/lib/citypay_api_client/models/airline_segment.rb +35 -22
- data/lib/citypay_api_client/models/auth_reference.rb +41 -26
- data/lib/citypay_api_client/models/auth_references.rb +15 -20
- data/lib/citypay_api_client/models/auth_request.rb +72 -34
- data/lib/citypay_api_client/models/auth_response.rb +46 -23
- data/lib/citypay_api_client/models/authen_required.rb +15 -20
- data/lib/citypay_api_client/models/batch.rb +25 -22
- data/lib/citypay_api_client/models/batch_report_request.rb +23 -22
- data/lib/citypay_api_client/models/batch_report_response_model.rb +28 -21
- data/lib/citypay_api_client/models/batch_transaction.rb +25 -22
- data/lib/citypay_api_client/models/batch_transaction_report_request.rb +234 -0
- data/lib/citypay_api_client/models/batch_transaction_report_response.rb +252 -0
- data/lib/citypay_api_client/models/batch_transaction_result_model.rb +53 -22
- data/lib/citypay_api_client/models/bin.rb +15 -20
- data/lib/citypay_api_client/models/bin_lookup.rb +17 -20
- data/lib/citypay_api_client/models/c_res_auth_request.rb +15 -20
- data/lib/citypay_api_client/models/capture_request.rb +27 -22
- data/lib/citypay_api_client/models/card.rb +33 -26
- data/lib/citypay_api_client/models/card_holder_account.rb +19 -20
- data/lib/citypay_api_client/models/card_status.rb +15 -20
- data/lib/citypay_api_client/models/charge_request.rb +72 -34
- data/lib/citypay_api_client/models/check_batch_status.rb +23 -22
- data/lib/citypay_api_client/models/check_batch_status_response.rb +15 -20
- data/lib/citypay_api_client/models/contact_details.rb +77 -42
- data/lib/citypay_api_client/models/decision.rb +16 -30
- data/lib/citypay_api_client/models/direct_post_request.rb +72 -34
- data/lib/citypay_api_client/models/direct_token_auth_request.rb +15 -20
- data/lib/citypay_api_client/models/domain_key_check_request.rb +17 -20
- data/lib/citypay_api_client/models/domain_key_request.rb +19 -20
- data/lib/citypay_api_client/models/domain_key_response.rb +25 -22
- data/lib/citypay_api_client/models/error.rb +27 -24
- data/lib/citypay_api_client/models/event_data_model.rb +15 -20
- data/lib/citypay_api_client/models/exists.rb +17 -20
- data/lib/citypay_api_client/models/external_mpi.rb +39 -24
- data/lib/citypay_api_client/models/list_merchants_response.rb +21 -22
- data/lib/citypay_api_client/models/mcc6012.rb +15 -20
- data/lib/citypay_api_client/models/merchant.rb +15 -20
- data/lib/citypay_api_client/models/merchant_batch_report_request.rb +265 -0
- data/lib/citypay_api_client/models/merchant_batch_report_response.rb +252 -0
- data/lib/citypay_api_client/models/merchant_batch_response.rb +301 -0
- data/lib/citypay_api_client/models/net_summary_response.rb +472 -0
- data/lib/citypay_api_client/models/pa_res_auth_request.rb +19 -20
- data/lib/citypay_api_client/models/paylink_address.rb +52 -29
- data/lib/citypay_api_client/models/paylink_adjustment_request.rb +25 -22
- data/lib/citypay_api_client/models/paylink_attachment_request.rb +19 -20
- data/lib/citypay_api_client/models/paylink_attachment_result.rb +19 -20
- data/lib/citypay_api_client/models/paylink_bill_payment_token_request.rb +17 -20
- data/lib/citypay_api_client/models/paylink_card_holder.rb +30 -23
- data/lib/citypay_api_client/models/paylink_cart.rb +15 -20
- data/lib/citypay_api_client/models/paylink_cart_item_model.rb +15 -20
- data/lib/citypay_api_client/models/paylink_config.rb +15 -20
- data/lib/citypay_api_client/models/paylink_custom_param.rb +29 -22
- data/lib/citypay_api_client/models/paylink_email_notification_path.rb +17 -20
- data/lib/citypay_api_client/models/paylink_error_code.rb +19 -20
- data/lib/citypay_api_client/models/paylink_field_guard_model.rb +16 -21
- data/lib/citypay_api_client/models/paylink_part_payments.rb +15 -20
- data/lib/citypay_api_client/models/paylink_resend_notification_request.rb +224 -0
- data/lib/citypay_api_client/models/paylink_sms_notification_path.rb +17 -20
- data/lib/citypay_api_client/models/paylink_state_event.rb +16 -21
- data/lib/citypay_api_client/models/paylink_token_created.rb +56 -27
- data/lib/citypay_api_client/models/paylink_token_request_model.rb +75 -22
- data/lib/citypay_api_client/models/paylink_token_status.rb +44 -21
- data/lib/citypay_api_client/models/paylink_token_status_change_request.rb +24 -26
- data/lib/citypay_api_client/models/paylink_token_status_change_response.rb +39 -22
- data/lib/citypay_api_client/models/paylink_ui.rb +15 -20
- data/lib/citypay_api_client/models/payment_intent.rb +479 -0
- data/lib/citypay_api_client/models/payment_intent_reference.rb +221 -0
- data/lib/citypay_api_client/models/ping.rb +21 -22
- data/lib/citypay_api_client/models/process_batch_request.rb +27 -22
- data/lib/citypay_api_client/models/process_batch_response.rb +17 -20
- data/lib/citypay_api_client/models/refund_request.rb +28 -21
- data/lib/citypay_api_client/models/register_card.rb +27 -22
- data/lib/citypay_api_client/models/remittance_data.rb +404 -0
- data/lib/citypay_api_client/models/remittance_report_request.rb +265 -0
- data/lib/citypay_api_client/models/remittance_report_response.rb +252 -0
- data/lib/citypay_api_client/models/remitted_client_data.rb +612 -0
- data/lib/citypay_api_client/models/request_challenged.rb +15 -20
- data/lib/citypay_api_client/models/retrieve_request.rb +23 -22
- data/lib/citypay_api_client/models/three_d_secure.rb +16 -21
- data/lib/citypay_api_client/models/tokenisation_response_model.rb +23 -24
- data/lib/citypay_api_client/models/void_request.rb +23 -22
- data/lib/citypay_api_client/version.rb +3 -3
- data/lib/citypay_api_client.rb +16 -3
- data/spec/api/reporting_api___spec.rb +99 -0
- data/spec/it_api_sandbox_spec.rb +5 -14
- data/spec/models/account_create_spec.rb +1 -2
- data/spec/models/account_status_spec.rb +2 -2
- data/spec/models/airline_advice_spec.rb +0 -2
- data/spec/models/airline_segment_spec.rb +0 -2
- data/spec/models/auth_request_spec.rb +0 -2
- data/spec/models/auth_response_spec.rb +75 -30
- data/spec/models/batch_report_request_spec.rb +0 -2
- data/spec/models/batch_report_response_model_spec.rb +0 -2
- data/spec/models/batch_spec.rb +0 -2
- data/spec/models/batch_transaction_report_request_spec.rb +47 -0
- data/spec/models/batch_transaction_report_response_spec.rb +53 -0
- data/spec/models/batch_transaction_result_model_spec.rb +0 -2
- data/spec/models/batch_transaction_spec.rb +0 -2
- data/spec/models/bin_lookup_spec.rb +0 -2
- data/spec/models/capture_request_spec.rb +0 -2
- data/spec/models/card_holder_account_spec.rb +0 -2
- data/spec/models/charge_request_spec.rb +0 -2
- data/spec/models/decision_spec.rb +0 -26
- data/spec/models/direct_post_request_spec.rb +0 -2
- data/spec/models/domain_key_check_request_spec.rb +0 -2
- data/spec/models/merchant_batch_report_request_spec.rb +65 -0
- data/spec/models/merchant_batch_report_response_spec.rb +53 -0
- data/spec/models/merchant_batch_response_spec.rb +71 -0
- data/spec/models/net_summary_response_spec.rb +77 -0
- data/spec/models/paylink_resend_notification_request_spec.rb +41 -0
- data/spec/models/paylink_token_request_model_spec.rb +0 -2
- data/spec/models/payment_intent_reference_spec.rb +35 -0
- data/spec/models/payment_intent_spec.rb +107 -0
- data/spec/models/process_batch_request_spec.rb +0 -2
- data/spec/models/refund_request_spec.rb +0 -2
- data/spec/models/register_card_spec.rb +0 -2
- data/spec/models/remittance_data_spec.rb +65 -0
- data/spec/models/remittance_report_request_spec.rb +65 -0
- data/spec/models/remittance_report_response_spec.rb +53 -0
- data/spec/models/remitted_client_data_spec.rb +113 -0
- data/spec/spec_helper.rb +2 -2
- metadata +146 -78
- data/docs/OperationalApi.md +0 -214
- data/docs/PaymentProcessingApi.md +0 -559
- data/spec/models/authen_required_spec.rb +0 -52
@@ -1,11 +1,11 @@
|
|
1
1
|
=begin
|
2
2
|
#CityPay Payment API
|
3
3
|
|
4
|
-
#
|
4
|
+
# Welcome to the CityPay API, a robust HTTP API payment solution designed for seamless server-to-server transactional processing. Our API facilitates a wide array of payment operations, catering to diverse business needs. Whether you're integrating Internet payments, handling Mail Order/Telephone Order (MOTO) transactions, managing Subscriptions with Recurring and Continuous Authority payments, or navigating the complexities of 3-D Secure authentication, our API is equipped to support your requirements. Additionally, we offer functionalities for Authorisation, Refunding, Pre-Authorisation, Cancellation/Voids, and Completion processing, alongside the capability for tokenised payments. ## Compliance and Security Overview <aside class=\"notice\"> Ensuring the security of payment transactions and compliance with industry standards is paramount. Our API is designed with stringent security measures and compliance protocols to safeguard sensitive information and meet the rigorous requirements of Visa, MasterCard, and the PCI Security Standards Council. </aside> ### Key Compliance and Security Measures * **TLS Encryption**: All data transmissions must utilise TLS version 1.2 or higher, employing [strong cryptography](#enabled-tls-ciphers). Our infrastructure strictly enforces this requirement to maintain the integrity and confidentiality of data in transit. We conduct regular scans and assessments of our TLS endpoints to identify and mitigate vulnerabilities. * **Data Storage Prohibitions**: Storing sensitive cardholder data (CHD), such as the card security code (CSC) or primary account number (PAN), is strictly prohibited. Our API is designed to minimize your exposure to sensitive data, thereby reducing your compliance burden. * **Data Masking**: For consumer protection and compliance, full card numbers must not be displayed on receipts or any customer-facing materials. Our API automatically masks PANs, displaying only the last four digits to facilitate safe receipt generation. * **Network Scans**: If your application is web-based, regular scans of your hosting environment are mandatory to identify and rectify potential vulnerabilities. This proactive measure is crucial for maintaining a secure and compliant online presence. * **PCI Compliance**: Adherence to PCI DSS standards is not optional; it's a requirement for operating securely and legally in the payments ecosystem. For detailed information on compliance requirements and resources, please visit the PCI Security Standards Council website [https://www.pcisecuritystandards.org/](https://www.pcisecuritystandards.org/). * **Request Validation**: Our API includes mechanisms to verify the legitimacy of each request, ensuring it pertains to a valid account and originates from a trusted source. We leverage remote IP address verification alongside sophisticated application firewall technologies to thwart a wide array of common security threats. ## Getting Started Before integrating with the CityPay API, ensure your application and development practices align with the outlined compliance and security measures. This preparatory step is crucial for a smooth integration process and the long-term success of your payment processing operations. For further details on API endpoints, request/response formats, and code examples, proceed to the subsequent sections of our documentation. Our aim is to provide you with all the necessary tools and information to integrate our payment processing capabilities seamlessly into your application. Thank you for choosing CityPay API. We look forward to supporting your payment processing needs with our secure, compliant, and versatile API solution.
|
5
5
|
|
6
6
|
Contact: support@citypay.com
|
7
7
|
Generated by: https://openapi-generator.tech
|
8
|
-
OpenAPI Generator version:
|
8
|
+
OpenAPI Generator version: 7.2.0
|
9
9
|
|
10
10
|
=end
|
11
11
|
|
@@ -23,7 +23,7 @@ module CityPayApiClient
|
|
23
23
|
# The IP address used in the lookup.
|
24
24
|
attr_accessor :ip
|
25
25
|
|
26
|
-
# The source provider of the ACL.
|
26
|
+
# The source provider of the ACL such as cloud, subnet, country or IP based.
|
27
27
|
attr_accessor :provider
|
28
28
|
|
29
29
|
# Attribute mapping from ruby-style variable name to JSON key.
|
@@ -92,6 +92,7 @@ module CityPayApiClient
|
|
92
92
|
# Show invalid properties with the reasons. Usually used together with valid?
|
93
93
|
# @return Array for valid properties with the reasons
|
94
94
|
def list_invalid_properties
|
95
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
95
96
|
invalid_properties = Array.new
|
96
97
|
invalid_properties
|
97
98
|
end
|
@@ -99,6 +100,7 @@ module CityPayApiClient
|
|
99
100
|
# Check to see if the all the properties in the model are valid
|
100
101
|
# @return true if the model is valid
|
101
102
|
def valid?
|
103
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
102
104
|
true
|
103
105
|
end
|
104
106
|
|
@@ -129,37 +131,30 @@ module CityPayApiClient
|
|
129
131
|
# @param [Hash] attributes Model attributes in the form of hash
|
130
132
|
# @return [Object] Returns the model itself
|
131
133
|
def self.build_from_hash(attributes)
|
132
|
-
new.build_from_hash(attributes)
|
133
|
-
end
|
134
|
-
|
135
|
-
# Builds the object from hash
|
136
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
137
|
-
# @return [Object] Returns the model itself
|
138
|
-
def build_from_hash(attributes)
|
139
134
|
return nil unless attributes.is_a?(Hash)
|
140
135
|
attributes = attributes.transform_keys(&:to_sym)
|
141
|
-
|
142
|
-
|
143
|
-
|
136
|
+
transformed_hash = {}
|
137
|
+
openapi_types.each_pair do |key, type|
|
138
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
139
|
+
transformed_hash["#{key}"] = nil
|
144
140
|
elsif type =~ /\AArray<(.*)>/i
|
145
141
|
# check to ensure the input is an array given that the attribute
|
146
142
|
# is documented as an array but the input is not
|
147
|
-
if attributes[
|
148
|
-
|
143
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
144
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
149
145
|
end
|
150
|
-
elsif !attributes[
|
151
|
-
|
146
|
+
elsif !attributes[attribute_map[key]].nil?
|
147
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
152
148
|
end
|
153
149
|
end
|
154
|
-
|
155
|
-
self
|
150
|
+
new(transformed_hash)
|
156
151
|
end
|
157
152
|
|
158
153
|
# Deserializes the data based on type
|
159
154
|
# @param string type Data type
|
160
155
|
# @param string value Value to be deserialized
|
161
156
|
# @return [Object] Deserialized data
|
162
|
-
def _deserialize(type, value)
|
157
|
+
def self._deserialize(type, value)
|
163
158
|
case type.to_sym
|
164
159
|
when :Time
|
165
160
|
Time.parse(value)
|
@@ -194,7 +189,7 @@ module CityPayApiClient
|
|
194
189
|
else # model
|
195
190
|
# models (e.g. Pet) or oneOf
|
196
191
|
klass = CityPayApiClient.const_get(type)
|
197
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
192
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
198
193
|
end
|
199
194
|
end
|
200
195
|
|
@@ -1,11 +1,11 @@
|
|
1
1
|
=begin
|
2
2
|
#CityPay Payment API
|
3
3
|
|
4
|
-
#
|
4
|
+
# Welcome to the CityPay API, a robust HTTP API payment solution designed for seamless server-to-server transactional processing. Our API facilitates a wide array of payment operations, catering to diverse business needs. Whether you're integrating Internet payments, handling Mail Order/Telephone Order (MOTO) transactions, managing Subscriptions with Recurring and Continuous Authority payments, or navigating the complexities of 3-D Secure authentication, our API is equipped to support your requirements. Additionally, we offer functionalities for Authorisation, Refunding, Pre-Authorisation, Cancellation/Voids, and Completion processing, alongside the capability for tokenised payments. ## Compliance and Security Overview <aside class=\"notice\"> Ensuring the security of payment transactions and compliance with industry standards is paramount. Our API is designed with stringent security measures and compliance protocols to safeguard sensitive information and meet the rigorous requirements of Visa, MasterCard, and the PCI Security Standards Council. </aside> ### Key Compliance and Security Measures * **TLS Encryption**: All data transmissions must utilise TLS version 1.2 or higher, employing [strong cryptography](#enabled-tls-ciphers). Our infrastructure strictly enforces this requirement to maintain the integrity and confidentiality of data in transit. We conduct regular scans and assessments of our TLS endpoints to identify and mitigate vulnerabilities. * **Data Storage Prohibitions**: Storing sensitive cardholder data (CHD), such as the card security code (CSC) or primary account number (PAN), is strictly prohibited. Our API is designed to minimize your exposure to sensitive data, thereby reducing your compliance burden. * **Data Masking**: For consumer protection and compliance, full card numbers must not be displayed on receipts or any customer-facing materials. Our API automatically masks PANs, displaying only the last four digits to facilitate safe receipt generation. * **Network Scans**: If your application is web-based, regular scans of your hosting environment are mandatory to identify and rectify potential vulnerabilities. This proactive measure is crucial for maintaining a secure and compliant online presence. * **PCI Compliance**: Adherence to PCI DSS standards is not optional; it's a requirement for operating securely and legally in the payments ecosystem. For detailed information on compliance requirements and resources, please visit the PCI Security Standards Council website [https://www.pcisecuritystandards.org/](https://www.pcisecuritystandards.org/). * **Request Validation**: Our API includes mechanisms to verify the legitimacy of each request, ensuring it pertains to a valid account and originates from a trusted source. We leverage remote IP address verification alongside sophisticated application firewall technologies to thwart a wide array of common security threats. ## Getting Started Before integrating with the CityPay API, ensure your application and development practices align with the outlined compliance and security measures. This preparatory step is crucial for a smooth integration process and the long-term success of your payment processing operations. For further details on API endpoints, request/response formats, and code examples, proceed to the subsequent sections of our documentation. Our aim is to provide you with all the necessary tools and information to integrate our payment processing capabilities seamlessly into your application. Thank you for choosing CityPay API. We look forward to supporting your payment processing needs with our secure, compliant, and versatile API solution.
|
5
5
|
|
6
6
|
Contact: support@citypay.com
|
7
7
|
Generated by: https://openapi-generator.tech
|
8
|
-
OpenAPI Generator version:
|
8
|
+
OpenAPI Generator version: 7.2.0
|
9
9
|
|
10
10
|
=end
|
11
11
|
|
@@ -130,6 +130,8 @@ module CityPayApiClient
|
|
130
130
|
|
131
131
|
if attributes.key?(:'carrier_name')
|
132
132
|
self.carrier_name = attributes[:'carrier_name']
|
133
|
+
else
|
134
|
+
self.carrier_name = nil
|
133
135
|
end
|
134
136
|
|
135
137
|
if attributes.key?(:'conjunction_ticket_indicator')
|
@@ -158,6 +160,8 @@ module CityPayApiClient
|
|
158
160
|
|
159
161
|
if attributes.key?(:'segment1')
|
160
162
|
self.segment1 = attributes[:'segment1']
|
163
|
+
else
|
164
|
+
self.segment1 = nil
|
161
165
|
end
|
162
166
|
|
163
167
|
if attributes.key?(:'segment2')
|
@@ -174,28 +178,39 @@ module CityPayApiClient
|
|
174
178
|
|
175
179
|
if attributes.key?(:'ticket_issue_city')
|
176
180
|
self.ticket_issue_city = attributes[:'ticket_issue_city']
|
181
|
+
else
|
182
|
+
self.ticket_issue_city = nil
|
177
183
|
end
|
178
184
|
|
179
185
|
if attributes.key?(:'ticket_issue_date')
|
180
186
|
self.ticket_issue_date = attributes[:'ticket_issue_date']
|
187
|
+
else
|
188
|
+
self.ticket_issue_date = nil
|
181
189
|
end
|
182
190
|
|
183
191
|
if attributes.key?(:'ticket_issue_name')
|
184
192
|
self.ticket_issue_name = attributes[:'ticket_issue_name']
|
193
|
+
else
|
194
|
+
self.ticket_issue_name = nil
|
185
195
|
end
|
186
196
|
|
187
197
|
if attributes.key?(:'ticket_no')
|
188
198
|
self.ticket_no = attributes[:'ticket_no']
|
199
|
+
else
|
200
|
+
self.ticket_no = nil
|
189
201
|
end
|
190
202
|
|
191
203
|
if attributes.key?(:'transaction_type')
|
192
204
|
self.transaction_type = attributes[:'transaction_type']
|
205
|
+
else
|
206
|
+
self.transaction_type = nil
|
193
207
|
end
|
194
208
|
end
|
195
209
|
|
196
210
|
# Show invalid properties with the reasons. Usually used together with valid?
|
197
211
|
# @return Array for valid properties with the reasons
|
198
212
|
def list_invalid_properties
|
213
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
199
214
|
invalid_properties = Array.new
|
200
215
|
if @carrier_name.nil?
|
201
216
|
invalid_properties.push('invalid value for "carrier_name", carrier_name cannot be nil.')
|
@@ -213,10 +228,6 @@ module CityPayApiClient
|
|
213
228
|
invalid_properties.push('invalid value for "no_air_segments", must be greater than or equal to 0.')
|
214
229
|
end
|
215
230
|
|
216
|
-
if @number_in_party.nil?
|
217
|
-
invalid_properties.push('invalid value for "number_in_party", number_in_party cannot be nil.')
|
218
|
-
end
|
219
|
-
|
220
231
|
if !@original_ticket_no.nil? && @original_ticket_no.to_s.length > 14
|
221
232
|
invalid_properties.push('invalid value for "original_ticket_no", the character length must be smaller than or equal to 14.')
|
222
233
|
end
|
@@ -275,11 +286,11 @@ module CityPayApiClient
|
|
275
286
|
# Check to see if the all the properties in the model are valid
|
276
287
|
# @return true if the model is valid
|
277
288
|
def valid?
|
289
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
278
290
|
return false if @carrier_name.nil?
|
279
291
|
return false if @carrier_name.to_s.length > 25
|
280
292
|
return false if !@no_air_segments.nil? && @no_air_segments > 4
|
281
293
|
return false if !@no_air_segments.nil? && @no_air_segments < 0
|
282
|
-
return false if @number_in_party.nil?
|
283
294
|
return false if !@original_ticket_no.nil? && @original_ticket_no.to_s.length > 14
|
284
295
|
return false if !@passenger_name.nil? && @passenger_name.to_s.length > 25
|
285
296
|
return false if @segment1.nil?
|
@@ -313,11 +324,15 @@ module CityPayApiClient
|
|
313
324
|
# Custom attribute writer method with validation
|
314
325
|
# @param [Object] no_air_segments Value to be assigned
|
315
326
|
def no_air_segments=(no_air_segments)
|
316
|
-
if
|
327
|
+
if no_air_segments.nil?
|
328
|
+
fail ArgumentError, 'no_air_segments cannot be nil'
|
329
|
+
end
|
330
|
+
|
331
|
+
if no_air_segments > 4
|
317
332
|
fail ArgumentError, 'invalid value for "no_air_segments", must be smaller than or equal to 4.'
|
318
333
|
end
|
319
334
|
|
320
|
-
if
|
335
|
+
if no_air_segments < 0
|
321
336
|
fail ArgumentError, 'invalid value for "no_air_segments", must be greater than or equal to 0.'
|
322
337
|
end
|
323
338
|
|
@@ -327,7 +342,11 @@ module CityPayApiClient
|
|
327
342
|
# Custom attribute writer method with validation
|
328
343
|
# @param [Object] original_ticket_no Value to be assigned
|
329
344
|
def original_ticket_no=(original_ticket_no)
|
330
|
-
if
|
345
|
+
if original_ticket_no.nil?
|
346
|
+
fail ArgumentError, 'original_ticket_no cannot be nil'
|
347
|
+
end
|
348
|
+
|
349
|
+
if original_ticket_no.to_s.length > 14
|
331
350
|
fail ArgumentError, 'invalid value for "original_ticket_no", the character length must be smaller than or equal to 14.'
|
332
351
|
end
|
333
352
|
|
@@ -337,7 +356,11 @@ module CityPayApiClient
|
|
337
356
|
# Custom attribute writer method with validation
|
338
357
|
# @param [Object] passenger_name Value to be assigned
|
339
358
|
def passenger_name=(passenger_name)
|
340
|
-
if
|
359
|
+
if passenger_name.nil?
|
360
|
+
fail ArgumentError, 'passenger_name cannot be nil'
|
361
|
+
end
|
362
|
+
|
363
|
+
if passenger_name.to_s.length > 25
|
341
364
|
fail ArgumentError, 'invalid value for "passenger_name", the character length must be smaller than or equal to 25.'
|
342
365
|
end
|
343
366
|
|
@@ -443,37 +466,30 @@ module CityPayApiClient
|
|
443
466
|
# @param [Hash] attributes Model attributes in the form of hash
|
444
467
|
# @return [Object] Returns the model itself
|
445
468
|
def self.build_from_hash(attributes)
|
446
|
-
new.build_from_hash(attributes)
|
447
|
-
end
|
448
|
-
|
449
|
-
# Builds the object from hash
|
450
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
451
|
-
# @return [Object] Returns the model itself
|
452
|
-
def build_from_hash(attributes)
|
453
469
|
return nil unless attributes.is_a?(Hash)
|
454
470
|
attributes = attributes.transform_keys(&:to_sym)
|
455
|
-
|
456
|
-
|
457
|
-
|
471
|
+
transformed_hash = {}
|
472
|
+
openapi_types.each_pair do |key, type|
|
473
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
474
|
+
transformed_hash["#{key}"] = nil
|
458
475
|
elsif type =~ /\AArray<(.*)>/i
|
459
476
|
# check to ensure the input is an array given that the attribute
|
460
477
|
# is documented as an array but the input is not
|
461
|
-
if attributes[
|
462
|
-
|
478
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
479
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
463
480
|
end
|
464
|
-
elsif !attributes[
|
465
|
-
|
481
|
+
elsif !attributes[attribute_map[key]].nil?
|
482
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
466
483
|
end
|
467
484
|
end
|
468
|
-
|
469
|
-
self
|
485
|
+
new(transformed_hash)
|
470
486
|
end
|
471
487
|
|
472
488
|
# Deserializes the data based on type
|
473
489
|
# @param string type Data type
|
474
490
|
# @param string value Value to be deserialized
|
475
491
|
# @return [Object] Deserialized data
|
476
|
-
def _deserialize(type, value)
|
492
|
+
def self._deserialize(type, value)
|
477
493
|
case type.to_sym
|
478
494
|
when :Time
|
479
495
|
Time.parse(value)
|
@@ -508,7 +524,7 @@ module CityPayApiClient
|
|
508
524
|
else # model
|
509
525
|
# models (e.g. Pet) or oneOf
|
510
526
|
klass = CityPayApiClient.const_get(type)
|
511
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
527
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
512
528
|
end
|
513
529
|
end
|
514
530
|
|
@@ -1,11 +1,11 @@
|
|
1
1
|
=begin
|
2
2
|
#CityPay Payment API
|
3
3
|
|
4
|
-
#
|
4
|
+
# Welcome to the CityPay API, a robust HTTP API payment solution designed for seamless server-to-server transactional processing. Our API facilitates a wide array of payment operations, catering to diverse business needs. Whether you're integrating Internet payments, handling Mail Order/Telephone Order (MOTO) transactions, managing Subscriptions with Recurring and Continuous Authority payments, or navigating the complexities of 3-D Secure authentication, our API is equipped to support your requirements. Additionally, we offer functionalities for Authorisation, Refunding, Pre-Authorisation, Cancellation/Voids, and Completion processing, alongside the capability for tokenised payments. ## Compliance and Security Overview <aside class=\"notice\"> Ensuring the security of payment transactions and compliance with industry standards is paramount. Our API is designed with stringent security measures and compliance protocols to safeguard sensitive information and meet the rigorous requirements of Visa, MasterCard, and the PCI Security Standards Council. </aside> ### Key Compliance and Security Measures * **TLS Encryption**: All data transmissions must utilise TLS version 1.2 or higher, employing [strong cryptography](#enabled-tls-ciphers). Our infrastructure strictly enforces this requirement to maintain the integrity and confidentiality of data in transit. We conduct regular scans and assessments of our TLS endpoints to identify and mitigate vulnerabilities. * **Data Storage Prohibitions**: Storing sensitive cardholder data (CHD), such as the card security code (CSC) or primary account number (PAN), is strictly prohibited. Our API is designed to minimize your exposure to sensitive data, thereby reducing your compliance burden. * **Data Masking**: For consumer protection and compliance, full card numbers must not be displayed on receipts or any customer-facing materials. Our API automatically masks PANs, displaying only the last four digits to facilitate safe receipt generation. * **Network Scans**: If your application is web-based, regular scans of your hosting environment are mandatory to identify and rectify potential vulnerabilities. This proactive measure is crucial for maintaining a secure and compliant online presence. * **PCI Compliance**: Adherence to PCI DSS standards is not optional; it's a requirement for operating securely and legally in the payments ecosystem. For detailed information on compliance requirements and resources, please visit the PCI Security Standards Council website [https://www.pcisecuritystandards.org/](https://www.pcisecuritystandards.org/). * **Request Validation**: Our API includes mechanisms to verify the legitimacy of each request, ensuring it pertains to a valid account and originates from a trusted source. We leverage remote IP address verification alongside sophisticated application firewall technologies to thwart a wide array of common security threats. ## Getting Started Before integrating with the CityPay API, ensure your application and development practices align with the outlined compliance and security measures. This preparatory step is crucial for a smooth integration process and the long-term success of your payment processing operations. For further details on API endpoints, request/response formats, and code examples, proceed to the subsequent sections of our documentation. Our aim is to provide you with all the necessary tools and information to integrate our payment processing capabilities seamlessly into your application. Thank you for choosing CityPay API. We look forward to supporting your payment processing needs with our secure, compliant, and versatile API solution.
|
5
5
|
|
6
6
|
Contact: support@citypay.com
|
7
7
|
Generated by: https://openapi-generator.tech
|
8
|
-
OpenAPI Generator version:
|
8
|
+
OpenAPI Generator version: 7.2.0
|
9
9
|
|
10
10
|
=end
|
11
11
|
|
@@ -94,18 +94,26 @@ module CityPayApiClient
|
|
94
94
|
|
95
95
|
if attributes.key?(:'arrival_location_code')
|
96
96
|
self.arrival_location_code = attributes[:'arrival_location_code']
|
97
|
+
else
|
98
|
+
self.arrival_location_code = nil
|
97
99
|
end
|
98
100
|
|
99
101
|
if attributes.key?(:'carrier_code')
|
100
102
|
self.carrier_code = attributes[:'carrier_code']
|
103
|
+
else
|
104
|
+
self.carrier_code = nil
|
101
105
|
end
|
102
106
|
|
103
107
|
if attributes.key?(:'class_service_code')
|
104
108
|
self.class_service_code = attributes[:'class_service_code']
|
109
|
+
else
|
110
|
+
self.class_service_code = nil
|
105
111
|
end
|
106
112
|
|
107
113
|
if attributes.key?(:'departure_date')
|
108
114
|
self.departure_date = attributes[:'departure_date']
|
115
|
+
else
|
116
|
+
self.departure_date = nil
|
109
117
|
end
|
110
118
|
|
111
119
|
if attributes.key?(:'departure_location_code')
|
@@ -114,6 +122,8 @@ module CityPayApiClient
|
|
114
122
|
|
115
123
|
if attributes.key?(:'flight_number')
|
116
124
|
self.flight_number = attributes[:'flight_number']
|
125
|
+
else
|
126
|
+
self.flight_number = nil
|
117
127
|
end
|
118
128
|
|
119
129
|
if attributes.key?(:'segment_fare')
|
@@ -128,6 +138,7 @@ module CityPayApiClient
|
|
128
138
|
# Show invalid properties with the reasons. Usually used together with valid?
|
129
139
|
# @return Array for valid properties with the reasons
|
130
140
|
def list_invalid_properties
|
141
|
+
warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
|
131
142
|
invalid_properties = Array.new
|
132
143
|
if @arrival_location_code.nil?
|
133
144
|
invalid_properties.push('invalid value for "arrival_location_code", arrival_location_code cannot be nil.')
|
@@ -179,6 +190,7 @@ module CityPayApiClient
|
|
179
190
|
# Check to see if the all the properties in the model are valid
|
180
191
|
# @return true if the model is valid
|
181
192
|
def valid?
|
193
|
+
warn '[DEPRECATED] the `valid?` method is obsolete'
|
182
194
|
return false if @arrival_location_code.nil?
|
183
195
|
return false if @arrival_location_code.to_s.length > 3
|
184
196
|
return false if @carrier_code.nil?
|
@@ -238,7 +250,11 @@ module CityPayApiClient
|
|
238
250
|
# Custom attribute writer method with validation
|
239
251
|
# @param [Object] departure_location_code Value to be assigned
|
240
252
|
def departure_location_code=(departure_location_code)
|
241
|
-
if
|
253
|
+
if departure_location_code.nil?
|
254
|
+
fail ArgumentError, 'departure_location_code cannot be nil'
|
255
|
+
end
|
256
|
+
|
257
|
+
if departure_location_code.to_s.length > 3
|
242
258
|
fail ArgumentError, 'invalid value for "departure_location_code", the character length must be smaller than or equal to 3.'
|
243
259
|
end
|
244
260
|
|
@@ -262,7 +278,11 @@ module CityPayApiClient
|
|
262
278
|
# Custom attribute writer method with validation
|
263
279
|
# @param [Object] stop_over_indicator Value to be assigned
|
264
280
|
def stop_over_indicator=(stop_over_indicator)
|
265
|
-
if
|
281
|
+
if stop_over_indicator.nil?
|
282
|
+
fail ArgumentError, 'stop_over_indicator cannot be nil'
|
283
|
+
end
|
284
|
+
|
285
|
+
if stop_over_indicator.to_s.length > 1
|
266
286
|
fail ArgumentError, 'invalid value for "stop_over_indicator", the character length must be smaller than or equal to 1.'
|
267
287
|
end
|
268
288
|
|
@@ -300,37 +320,30 @@ module CityPayApiClient
|
|
300
320
|
# @param [Hash] attributes Model attributes in the form of hash
|
301
321
|
# @return [Object] Returns the model itself
|
302
322
|
def self.build_from_hash(attributes)
|
303
|
-
new.build_from_hash(attributes)
|
304
|
-
end
|
305
|
-
|
306
|
-
# Builds the object from hash
|
307
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
308
|
-
# @return [Object] Returns the model itself
|
309
|
-
def build_from_hash(attributes)
|
310
323
|
return nil unless attributes.is_a?(Hash)
|
311
324
|
attributes = attributes.transform_keys(&:to_sym)
|
312
|
-
|
313
|
-
|
314
|
-
|
325
|
+
transformed_hash = {}
|
326
|
+
openapi_types.each_pair do |key, type|
|
327
|
+
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
328
|
+
transformed_hash["#{key}"] = nil
|
315
329
|
elsif type =~ /\AArray<(.*)>/i
|
316
330
|
# check to ensure the input is an array given that the attribute
|
317
331
|
# is documented as an array but the input is not
|
318
|
-
if attributes[
|
319
|
-
|
332
|
+
if attributes[attribute_map[key]].is_a?(Array)
|
333
|
+
transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
|
320
334
|
end
|
321
|
-
elsif !attributes[
|
322
|
-
|
335
|
+
elsif !attributes[attribute_map[key]].nil?
|
336
|
+
transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
|
323
337
|
end
|
324
338
|
end
|
325
|
-
|
326
|
-
self
|
339
|
+
new(transformed_hash)
|
327
340
|
end
|
328
341
|
|
329
342
|
# Deserializes the data based on type
|
330
343
|
# @param string type Data type
|
331
344
|
# @param string value Value to be deserialized
|
332
345
|
# @return [Object] Deserialized data
|
333
|
-
def _deserialize(type, value)
|
346
|
+
def self._deserialize(type, value)
|
334
347
|
case type.to_sym
|
335
348
|
when :Time
|
336
349
|
Time.parse(value)
|
@@ -365,7 +378,7 @@ module CityPayApiClient
|
|
365
378
|
else # model
|
366
379
|
# models (e.g. Pet) or oneOf
|
367
380
|
klass = CityPayApiClient.const_get(type)
|
368
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
381
|
+
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
369
382
|
end
|
370
383
|
end
|
371
384
|
|