Class: WhopSDK::Resources::Payouts::Methods
- Inherits:
-
Object
- Object
- WhopSDK::Resources::Payouts::Methods
- Defined in:
- lib/whop_sdk/resources/payouts/methods.rb,
sig/whop_sdk/resources/payouts/methods.rbs
Overview
Payouts represent money sent from an account or user balance to an external destination, such as a bank account, wallet, or other saved payout method.
Use the Payouts API to create payouts from stablecoin accounts, list payout history for accounts or users, monitor payout statuses, and show expected arrival details for funds leaving Whop.
Instance Method Summary collapse
-
#initialize(client:) ⇒ Methods
constructor
private
A new instance of Methods.
-
#list(account_id: nil, after: nil, amount: nil, before: nil, currency: nil, first: nil, include_available: nil, last: nil, status: nil, user_id: nil, request_options: {}) ⇒ WhopSDK::Internal::CursorPage<WhopSDK::Models::Payouts::MethodListResponse>
Some parameter documentations has been truncated, see Models::Payouts::MethodListParams for more details.
Constructor Details
#initialize(client:) ⇒ Methods
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 Methods.
65 66 67 |
# File 'lib/whop_sdk/resources/payouts/methods.rb', line 65 def initialize(client:) @client = client end |
Instance Method Details
#list(account_id: nil, after: nil, amount: nil, before: nil, currency: nil, first: nil, include_available: nil, last: nil, status: nil, user_id: nil, request_options: {}) ⇒ WhopSDK::Internal::CursorPage<WhopSDK::Models::Payouts::MethodListResponse>
Some parameter documentations has been truncated, see Models::Payouts::MethodListParams for more details.
Lists the saved payout methods (bank accounts, digital wallets, crypto addresses) that an account or user can withdraw to, most recently added first. Pass exactly one of accountid (a biz identifier) or userid (a user identifier). Pass an amount to additionally get a fee and delivery quote per method for withdrawing that amount.
49 50 51 52 53 54 55 56 57 58 59 60 |
# File 'lib/whop_sdk/resources/payouts/methods.rb', line 49 def list(params = {}) parsed, = WhopSDK::Payouts::MethodListParams.dump_request(params) query = WhopSDK::Internal::Util.encode_query_params(parsed) @client.request( method: :get, path: "payouts/methods", query: query, page: WhopSDK::Internal::CursorPage, model: WhopSDK::Models::Payouts::MethodListResponse, options: ) end |