Class: GenesisRuby::Api::Requests::NonFinancial::BillingApi::Transactions
- Inherits:
-
Base::NonFinancial::BillingApi::Base
- Object
- GenesisRuby::Api::Request
- Base::Versioned
- Base::Graphql
- Base::NonFinancial::BillingApi::Base
- GenesisRuby::Api::Requests::NonFinancial::BillingApi::Transactions
- Defined in:
- lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb
Overview
Billing Transactions API allows to programmatically retrieve information about billing transactions using given filters, pagination, and sort parameters.
Constant Summary collapse
- MAX_UNIQUE_ID_COUNT =
rubocop:disable Metrics/ClassLength
1_000- MAX_BILLING_STATEMENT_COUNT =
10- MAX_MERCHANT_TRANSACTION_COUNT =
1_000- MAX_MASTER_ACCOUNT_NAME_COUNT =
10- MAX_TRANSACTION_TYPE_COUNT =
10- MAX_DAYS_DIFFERENCE =
7
Constants inherited from GenesisRuby::Api::Request
GenesisRuby::Api::Request::AUTH_TYPE_BASIC, GenesisRuby::Api::Request::AUTH_TYPE_TOKEN, GenesisRuby::Api::Request::METHOD_DELETE, GenesisRuby::Api::Request::METHOD_GET, GenesisRuby::Api::Request::METHOD_PATCH, GenesisRuby::Api::Request::METHOD_POST, GenesisRuby::Api::Request::METHOD_PUT, GenesisRuby::Api::Request::PORT_HTTPS, GenesisRuby::Api::Request::PROTOCOL_HTTPS
Instance Attribute Summary
Attributes included from Mixins::Requests::NonFinancial::PagingAttributes
Attributes included from Mixins::Requests::NonFinancial::BillingApi::SortAttributes
#sort_by_direction, #sort_by_field
Attributes inherited from Base::Versioned
Attributes inherited from GenesisRuby::Api::Request
Instance Method Summary collapse
-
#initialize(configuration, _builder_interface = nil) ⇒ Transactions
constructor
A new instance of Transactions.
-
#master_account_name ⇒ Object
List of master account names.
-
#master_account_name=(value) ⇒ Object
List of master account names.
-
#merchant_transaction_id ⇒ Object
List of merchant transaction IDs.
-
#merchant_transaction_id=(value) ⇒ Object
List of merchant transaction IDs.
-
#response_fields ⇒ Object
Response Fields.
-
#response_fields=(value) ⇒ Object
Response Fields.
-
#transaction_type ⇒ Object
List of billing transaction types.
-
#transaction_type=(value) ⇒ Object
List of billing transaction types.
-
#unique_id ⇒ Object
List of billing transaction unique IDs.
-
#unique_id=(value) ⇒ Object
List of billing transaction unique IDs.
Methods inherited from Base::NonFinancial::BillingApi::Base
#billing_statement, #billing_statement=
Methods included from Mixins::Requests::NonFinancial::DateAttributes
#end_date, #end_date=, #end_date_from, #end_date_from=, #end_date_to, #end_date_to=, #start_date, #start_date=, #start_date_from, #start_date_from=, #start_date_to, #start_date_to=
Methods inherited from GenesisRuby::Api::Request
Constructor Details
#initialize(configuration, _builder_interface = nil) ⇒ Transactions
Returns a new instance of Transactions.
25 26 27 28 29 30 31 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 25 def initialize(configuration, _builder_interface = nil) super configuration self.root_key = 'query' self.request_name = 'billingTransactions' self.request_path = 'billing_transactions' end |
Instance Method Details
#master_account_name ⇒ Object
List of master account names. Max number of elements allowed is 10. Secondary filter.
67 68 69 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 67 def master_account_name @master_account_name || [] end |
#master_account_name=(value) ⇒ Object
List of master account names. Max number of elements allowed is 10. Secondary filter.
72 73 74 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 72 def master_account_name=(value) parse_array_of_strings attribute: __method__, value: value, allow_empty: true end |
#merchant_transaction_id ⇒ Object
List of merchant transaction IDs. Max number of elements allowed is 1000. Primary filter.
57 58 59 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 57 def merchant_transaction_id @merchant_transaction_id || [] end |
#merchant_transaction_id=(value) ⇒ Object
List of merchant transaction IDs. Max number of elements allowed is 1000. Primary filter.
62 63 64 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 62 def merchant_transaction_id=(value) parse_array_of_strings attribute: __method__, value: value, allow_empty: true end |
#response_fields ⇒ Object
Response Fields
34 35 36 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 34 def response_fields @response_fields || [] end |
#response_fields=(value) ⇒ Object
Response Fields
39 40 41 42 43 44 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 39 def response_fields=(value) parse_array_of_strings attribute: __method__, value: value, allowed: Api::Constants::Transactions::Parameters::NonFinancial::BillingApi:: ResponseFields.all end |
#transaction_type ⇒ Object
List of billing transaction types. Max number of elements allowed is 10.
77 78 79 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 77 def transaction_type @transaction_type || [] end |
#transaction_type=(value) ⇒ Object
List of billing transaction types. Max number of elements allowed is 10.
82 83 84 85 86 87 88 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 82 def transaction_type=(value) parse_array_of_strings attribute: __method__, value: value, allowed: Api::Constants::Transactions::Parameters::NonFinancial::BillingApi:: TransactionTypes.all, allow_empty: true end |
#unique_id ⇒ Object
List of billing transaction unique IDs. Max number of elements is 1000. Primary filter.
47 48 49 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 47 def unique_id @unique_id || [] end |
#unique_id=(value) ⇒ Object
List of billing transaction unique IDs. Max number of elements is 1000. Primary filter.
52 53 54 |
# File 'lib/genesis_ruby/api/requests/non_financial/billing_api/transactions.rb', line 52 def unique_id=(value) parse_array_of_strings attribute: __method__, value: value, allow_empty: true end |