Skip to content

Commit

Permalink
VISA, Paypal source, Partial Auth and account_holder updates (#152)
Browse files Browse the repository at this point in the history
  • Loading branch information
armando-rodriguez-cko authored Nov 4, 2024
1 parent 99cd7b0 commit 7ca3887
Show file tree
Hide file tree
Showing 76 changed files with 990 additions and 60 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
*.DS_Store
*.lock

/vendor/
/.bundle/
/.yardoc
/_yardoc/
Expand Down
21 changes: 21 additions & 0 deletions lib/checkout_sdk/accounts/accounts.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,3 +36,24 @@
require 'checkout_sdk/accounts/payment_instruments_query'
require 'checkout_sdk/accounts/headers'
require 'checkout_sdk/accounts/update_payment_instrument_request'
require 'checkout_sdk/accounts/additional_document'
require 'checkout_sdk/accounts/additional_info'
require 'checkout_sdk/accounts/articles_of_association_type'
require 'checkout_sdk/accounts/bank_verification'
require 'checkout_sdk/accounts/bank_verification_type'
require 'checkout_sdk/accounts/company_verification'
require 'checkout_sdk/accounts/company_verification_type'
require 'checkout_sdk/accounts/date_of_incorporation'
require 'checkout_sdk/accounts/financial_verification'
require 'checkout_sdk/accounts/financial_verification_type'
require 'checkout_sdk/accounts/invitee'
require 'checkout_sdk/accounts/onboard_sub_entity_documents'
require 'checkout_sdk/accounts/processing_details'
require 'checkout_sdk/accounts/proof_of_legality'
require 'checkout_sdk/accounts/proof_of_legality_type'
require 'checkout_sdk/accounts/proof_of_principal_address'
require 'checkout_sdk/accounts/proof_of_principal_address_type'
require 'checkout_sdk/accounts/shareholder_structure'
require 'checkout_sdk/accounts/shareholder_structure_type'
require 'checkout_sdk/accounts/tax_verification'
require 'checkout_sdk/accounts/tax_verification_type'
11 changes: 11 additions & 0 deletions lib/checkout_sdk/accounts/additional_document.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute front
# @return [String]
class AdditionalDocument
attr_accessor :front
end
end
end
17 changes: 17 additions & 0 deletions lib/checkout_sdk/accounts/additional_info.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute field1
# @return [String]
# @!attribute field2
# @return [String]
# @!attribute field3
# @return [String]
class AdditionalInfo
attr_accessor :field1,
:field2,
:field3
end
end
end
10 changes: 10 additions & 0 deletions lib/checkout_sdk/accounts/articles_of_association_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module ArticlesOfAssociationType
MEMORANDUM_OF_ASSOCIATION = 'memorandum_of_association'
ARTICLES_OF_ASSOCIATION = 'articles_of_association'
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/bank_verification.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute type
# @return [BankVerificationType]
# @!attribute front
# @return [String]
class BankVerification
attr_accessor :type,
:front
end
end
end
9 changes: 9 additions & 0 deletions lib/checkout_sdk/accounts/bank_verification_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module BankVerificationType
BANK_STATEMENT = 'bank_statement'
end
end
end
8 changes: 7 additions & 1 deletion lib/checkout_sdk/accounts/company.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,16 @@ module Accounts
# @return [String]
# @!attribute trading_name
# @return [String]
# @!attribute date_of_incorporation
# @return [DateOfIncorporation]
# @!attribute regulatory_licence_number
# @return [String]
# @!attribute principal_address
# @return [CheckoutSdk::Common::Address]
# @!attribute registered_address
# @return [CheckoutSdk::Common::Address]
# @!attribute representatives
# @return [Array(Representative)]
# @return [Array(EntityRepresentative)]
# @!attribute document
# @return [EntityDocument]
# @!attribute financial_details
Expand All @@ -25,6 +29,8 @@ class Company
:business_type,
:legal_name,
:trading_name,
:date_of_incorporation,
:regulatory_licence_number,
:principal_address,
:registered_address,
:representatives,
Expand Down
5 changes: 4 additions & 1 deletion lib/checkout_sdk/accounts/contact_details.rb
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,12 @@ module Accounts
# @return [Phone]
# @!attribute email_addresses
# @return [EntityEmailAddresses]
# @!attribute invitee
# @return [Invitee]
class ContactDetails
attr_accessor :phone,
:email_addresses
:email_addresses,
:invitee
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/date_of_incorporation.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute month
# @return [Integer]
# @!attribute year
# @return [Integer]
class DateOfIncorporation
attr_reader :month,
:year
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/financial_verification.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute type
# @return [FinancialVerificationType]
# @!attribute front
# @return [String]
class FinancialVerification
attr_reader :type,
:front
end
end
end
9 changes: 9 additions & 0 deletions lib/checkout_sdk/accounts/financial_verification_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module FinancialVerificationType
FINANCIAL_STATEMENT = 'financial_statement'
end
end
end
11 changes: 11 additions & 0 deletions lib/checkout_sdk/accounts/invitee.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute email
# @return [String]
class Invitee
attr_accessor :email
end
end
end
17 changes: 13 additions & 4 deletions lib/checkout_sdk/accounts/onboard_entity.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,32 @@ module CheckoutSdk
module Accounts
# @!attribute reference
# @return [String]
# @!attribute contact_details
# @return [ContactDetails]
# @!attribute is_draft
# @return [Boolean]
# @!attribute profile
# @return [Profile]
# @!attribute contact_details
# @return [ContactDetails]
# @!attribute company
# @return [Company]
# @!attribute processing_details
# @return [ProcessingDetails]
# @!attribute individual
# @return [Individual]
# @!attribute documents
# @return [OnboardSubEntityDocuments]
# @!attribute additional_info
# @return [AdditionalInfo]
class OnboardEntity
attr_accessor :reference,
:contact_details,
:is_draft,
:profile,
:contact_details,
:company,
:processing_details,
:individual,
:documents
:documents,
:additional_info
end
end
end
35 changes: 31 additions & 4 deletions lib/checkout_sdk/accounts/onboard_sub_entity_documents.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,43 @@

module CheckoutSdk
module Accounts
# @!attribute documents
# @return [Document]
# @!attribute identity_verification
# @return [EntityIdentificationDocument]
# @!attribute company_verification
# @return [CompanyVerification]
# @!attribute articles_of_association
# @return [ArticlesOfAssociationType]
# @!attribute bank_verification
# @return [BankVerification]
# @!attribute shareholder_structure
# @return [ShareholderStructure]
# @!attribute proof_of_legality
# @return [ProofOfLegality]
# @!attribute proof_of_principal_address
# @return [ProofOfPrincipalAddress]
# @!attribute additional_document1
# @return [AdditionalDocument]
# @!attribute additional_document2
# @return [AdditionalDocument]
# @!attribute additional_document3
# @return [AdditionalDocument]
# @!attribute tax_verification
# @return [TaxVerification]
# @!attribute financial_verification
# @return [FinancialVerification]
class OnboardSubEntityDocuments
attr_accessor :documents,
attr_accessor :identity_verification,
:company_verification,
:tax_verification
:articles_of_association,
:bank_verification,
:shareholder_structure,
:proof_of_legality,
:proof_of_principal_address,
:additional_document1,
:additional_document2,
:additional_document3,
:tax_verification,
:financial_verification
end
end
end
26 changes: 26 additions & 0 deletions lib/checkout_sdk/accounts/processing_details.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute settlement_country
# @return [String]
# @!attribute target_countries
# @return [Array(String)]
# @!attribute annual_processing_volume
# @return [Integer]
# @!attribute average_transaction_value
# @return [Integer]
# @!attribute highest_transaction_value
# @return [Integer]
# @!attribute currency
# @return [CheckoutSdk::Common::Currency]
class ProcessingDetails
attr_accessor :settlement_country,
:target_countries,
:annual_processing_volume,
:average_transaction_value,
:highest_transaction_value,
:currency
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/proof_of_legality.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute type
# @return [ProofOfLegalityType]
# @!attribute front
# @return [String]
class ProofOfLegality
attr_accessor :type,
:front
end
end
end
9 changes: 9 additions & 0 deletions lib/checkout_sdk/accounts/proof_of_legality_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module ProofOfLegalityType
PROOF_OF_LEGALITY = 'proof_of_legality'
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/proof_of_principal_address.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute type
# @return [ProofOfPrincipalAddressType]
# @!attribute front
# @return [String]
class ProofOfPrincipalAddress
attr_reader :type,
:front
end
end
end
9 changes: 9 additions & 0 deletions lib/checkout_sdk/accounts/proof_of_principal_address_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module ProofOfPrincipalAddressType
PROOF_OF_ADDRESS = 'proof_of_address'
end
end
end
14 changes: 14 additions & 0 deletions lib/checkout_sdk/accounts/shareholder_structure.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
# @!attribute type
# @return [ShareholderStructureType]
# @!attribute front
# @return [String]
class ShareholderStructure
attr_accessor :type,
:front
end
end
end
9 changes: 9 additions & 0 deletions lib/checkout_sdk/accounts/shareholder_structure_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# frozen_string_literal: true

module CheckoutSdk
module Accounts
module ShareholderStructureType
CERTIFIED_SHAREHOLDER_STRUCTURE = 'certified_shareholder_structure'
end
end
end
12 changes: 12 additions & 0 deletions lib/checkout_sdk/common/account_change_indicator_type.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# frozen_string_literal: true

module CheckoutSdk
module Common
class AccountChangeIndicatorType
THIS_TRANSACTION = 'this_transaction'
LESS_THAN_THIRTY_DAYS = 'less_than_thirty_days'
THIRTY_TO_SIXTY_DAYS = 'thirty_to_sixty_days'
MORE_THAN_SIXTY_DAYS = 'more_than_sixty_days'
end
end
end
Loading

0 comments on commit 7ca3887

Please sign in to comment.