Class: Increase::Resources::CardPushTransfers
- Inherits:
-
Object
- Object
- Increase::Resources::CardPushTransfers
- Defined in:
- lib/increase/resources/card_push_transfers.rb
Instance Method Summary collapse
-
#approve(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Approves a Card Push Transfer in a pending_approval state.
-
#cancel(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Cancels a Card Push Transfer in a pending_approval state.
-
#create(business_application_identifier:, card_token_id:, merchant_category_code:, merchant_city_name:, merchant_name:, merchant_name_prefix:, merchant_postal_code:, merchant_state:, presentment_amount:, recipient_name:, sender_address_city:, sender_address_line1:, sender_address_postal_code:, sender_address_state:, sender_name:, source_account_number_id:, merchant_legal_business_name: nil, merchant_street_address: nil, recipient_address_city: nil, recipient_address_line1: nil, recipient_address_postal_code: nil, recipient_address_state: nil, require_approval: nil, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Some parameter documentations has been truncated, see Models::CardPushTransferCreateParams for more details.
-
#initialize(client:) ⇒ CardPushTransfers
constructor
private
A new instance of CardPushTransfers.
-
#list(account_id: nil, created_at: nil, cursor: nil, idempotency_key: nil, limit: nil, status: nil, request_options: {}) ⇒ Increase::Internal::Page<Increase::Models::CardPushTransfer>
Some parameter documentations has been truncated, see Models::CardPushTransferListParams for more details.
-
#retrieve(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Retrieve a Card Push Transfer.
Constructor Details
#initialize(client:) ⇒ CardPushTransfers
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of CardPushTransfers.
175 176 177 |
# File 'lib/increase/resources/card_push_transfers.rb', line 175 def initialize(client:) @client = client end |
Instance Method Details
#approve(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Approves a Card Push Transfer in a pending_approval state.
143 144 145 146 147 148 149 150 |
# File 'lib/increase/resources/card_push_transfers.rb', line 143 def approve(card_push_transfer_id, params = {}) @client.request( method: :post, path: ["card_push_transfers/%1$s/approve", card_push_transfer_id], model: Increase::CardPushTransfer, options: params[:request_options] ) end |
#cancel(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Cancels a Card Push Transfer in a pending_approval state.
163 164 165 166 167 168 169 170 |
# File 'lib/increase/resources/card_push_transfers.rb', line 163 def cancel(card_push_transfer_id, params = {}) @client.request( method: :post, path: ["card_push_transfers/%1$s/cancel", card_push_transfer_id], model: Increase::CardPushTransfer, options: params[:request_options] ) end |
#create(business_application_identifier:, card_token_id:, merchant_category_code:, merchant_city_name:, merchant_name:, merchant_name_prefix:, merchant_postal_code:, merchant_state:, presentment_amount:, recipient_name:, sender_address_city:, sender_address_line1:, sender_address_postal_code:, sender_address_state:, sender_name:, source_account_number_id:, merchant_legal_business_name: nil, merchant_street_address: nil, recipient_address_city: nil, recipient_address_line1: nil, recipient_address_postal_code: nil, recipient_address_state: nil, require_approval: nil, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Some parameter documentations has been truncated, see Models::CardPushTransferCreateParams for more details.
Create a Card Push Transfer
64 65 66 67 68 69 70 71 72 73 |
# File 'lib/increase/resources/card_push_transfers.rb', line 64 def create(params) parsed, = Increase::CardPushTransferCreateParams.dump_request(params) @client.request( method: :post, path: "card_push_transfers", body: parsed, model: Increase::CardPushTransfer, options: ) end |
#list(account_id: nil, created_at: nil, cursor: nil, idempotency_key: nil, limit: nil, status: nil, request_options: {}) ⇒ Increase::Internal::Page<Increase::Models::CardPushTransfer>
Some parameter documentations has been truncated, see Models::CardPushTransferListParams for more details.
List Card Push Transfers
119 120 121 122 123 124 125 126 127 128 129 130 |
# File 'lib/increase/resources/card_push_transfers.rb', line 119 def list(params = {}) parsed, = Increase::CardPushTransferListParams.dump_request(params) query = Increase::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "card_push_transfers", query: query, page: Increase::Internal::Page, model: Increase::CardPushTransfer, options: ) end |
#retrieve(card_push_transfer_id, request_options: {}) ⇒ Increase::Models::CardPushTransfer
Retrieve a Card Push Transfer
86 87 88 89 90 91 92 93 |
# File 'lib/increase/resources/card_push_transfers.rb', line 86 def retrieve(card_push_transfer_id, params = {}) @client.request( method: :get, path: ["card_push_transfers/%1$s", card_push_transfer_id], model: Increase::CardPushTransfer, options: params[:request_options] ) end |