generate methods

This commit is contained in:
David Brownman 2025-11-15 12:03:58 -08:00
parent 1f394eb76b
commit a3f0e8c97f
5 changed files with 853 additions and 118 deletions

View File

@ -18,7 +18,7 @@ Layout/LineLength:
Exclude:
- "lib/stripe/object_types.rb"
- "lib/stripe/stripe_client.rb"
- "lib/stripe/stripe_event_handler.rb"
- "lib/stripe/stripe_event_router.rb"
- "lib/stripe/resources/**/*.rb"
- "lib/stripe/services/**/*.rb"
- "lib/stripe/events/**/*.rb"
@ -89,7 +89,7 @@ Metrics/ParameterLists:
Naming/MethodName:
Exclude:
- "lib/stripe/stripe_event_handler.rb"
- "lib/stripe/stripe_event_router.rb"
Naming/MethodParameterName:
# We have many parameters that are less than 3 characters for tax codes

View File

@ -1,63 +0,0 @@
# frozen_string_literal: true
module Stripe
class StripeEventHandler
def initialize(client, webhook_secret)
@client = client
@registered_handlers = {}
@webhook_secret = webhook_secret
end
def handle(webhook_body, sig_header)
@client.parse_event_notification(
webhook_body,
sig_header,
@webhook_secret
)
# TODO: rebind stripe-context temporarily
case event_notification.type
# event-method-routing: The beginning of the section generated from our OpenAPI spec
when
"v1.billing.meter.error_report_triggered"
on_V1BillingMeterErrorReportTriggeredEventNotification(event_notification, @client)
when
"v1.billing.meter.no_meter_found"
on_V1BillingMeterNoMeterFoundEventNotification(event_notification, @client)
when
"v2.core.event_destination.ping"
on_V2CoreEventDestinationPingEventNotification(event_notification, @client)
# event-method-routing: The end of the section generated from our OpenAPI spec
else
# only used for types that the SDK has no class for
on_UnknownEventNotification(
event_notification,
@client
)
end
end
# Overwrite this method to handle events that the SDK has types for, but you've chosen not to handle with their dedicated method.
def on_unhandled_event_notification(event_notification, _client)
raise "Received an event that the SDK has a corresponding class for, but for which you haven't written a corresponding handler: \"#{event_notification.type}\""
end
def on_UnknownEventNotification(event_notification, _client)
raise "Received event type that the SDK doesn't have a corresponding class for: \"#{event_notification.type}\". Consider upgrading your SDK to handle this more gracefully."
end
# event-handler-methods: The beginning of the section generated from our OpenAPI spec
def on_V1BillingMeterErrorReportTriggeredEventNotification(event_notification, client)
on_unhandled_event_notification(event_notification, client)
end
def on_V1BillingMeterNoMeterFoundEventNotification(event_notification, client)
on_unhandled_event_notification(event_notification, client)
end
def on_V2CoreEventDestinationPingEventNotification(event_notification, client)
on_unhandled_event_notification(event_notification, client)
end
# event-handler-methods: The end of the section generated from our OpenAPI spec
end
end

View File

@ -0,0 +1,437 @@
# frozen_string_literal: true
module Stripe
class UnhandledNotificationDetails
attr_reader :is_known_event_type
def initialize(is_known_event_type)
@is_known_event_type = is_known_event_type
end
end
class StripeEventRouter
def initialize(client, webhook_secret, &on_unhandled_handler)
raise ArgumentError, "You must pass a block to respond to unhandled events" if on_unhandled_handler.nil?
@client = client
@webhook_secret = webhook_secret
@on_unhandled_handler = on_unhandled_handler
@registered_handlers = {}
@has_handled_events = false
end
def handle(webhook_body, sig_header)
@has_handled_events = true
notif = @client.parse_event_notification(
webhook_body,
sig_header,
@webhook_secret
)
@handler = @registered_handlers[notif.type]
if @handler
@handler.call(notif, @client)
else
@on_unhandled_handler.call(notif, @client,
UnhandledNotificationDetails.new(notif.is_a?(Stripe::Events::UnknownEventNotification)))
end
end
private def register(event_type, &handler)
raise "Cannot register new event handlers after handling events" if @has_handled_events
if @registered_handlers.key?(event_type)
raise ArgumentError, "Handler already registered for event type: #{event_type}"
end
@registered_handlers[event_type] = handler
end
# def on_UnknownEventNotification(event_notification, _client)
# raise "Received event type that the SDK doesn't have a corresponding class for: \"#{event_notification.type}\". Consider upgrading your SDK to handle this more gracefully."
# end
# event-handler-methods: The beginning of the section generated from our OpenAPI spec
def on_V1BillingMeterErrorReportTriggeredEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v1.billing.meter.error_report_triggered", &handler)
end
def on_V1BillingMeterNoMeterFoundEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v1.billing.meter.no_meter_found", &handler)
end
def on_V2CoreAccountClosedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account.closed", &handler)
end
def on_V2CoreAccountCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account.created", &handler)
end
def on_V2CoreAccountUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account.updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationCustomerCapabilityStatusUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.customer].capability_status_updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationCustomerUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.customer].updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationMerchantCapabilityStatusUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.merchant].capability_status_updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationMerchantUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.merchant].updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEventNotification(
&handler
)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.recipient].capability_status_updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationRecipientUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.recipient].updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.storer].capability_status_updated", &handler)
end
def on_V2CoreAccountIncludingConfigurationStorerUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[configuration.storer].updated", &handler)
end
def on_V2CoreAccountIncludingDefaultsUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[defaults].updated", &handler)
end
def on_V2CoreAccountIncludingIdentityUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[identity].updated", &handler)
end
def on_V2CoreAccountIncludingRequirementsUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account[requirements].updated", &handler)
end
def on_V2CoreAccountLinkReturnedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account_link.returned", &handler)
end
def on_V2CoreAccountPersonCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account_person.created", &handler)
end
def on_V2CoreAccountPersonDeletedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account_person.deleted", &handler)
end
def on_V2CoreAccountPersonUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.account_person.updated", &handler)
end
def on_V2CoreEventDestinationPingEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.core.event_destination.ping", &handler)
end
def on_V2MoneyManagementAdjustmentCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.adjustment.created", &handler)
end
def on_V2MoneyManagementFinancialAccountCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.financial_account.created", &handler)
end
def on_V2MoneyManagementFinancialAccountUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.financial_account.updated", &handler)
end
def on_V2MoneyManagementFinancialAddressActivatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.financial_address.activated", &handler)
end
def on_V2MoneyManagementFinancialAddressFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.financial_address.failed", &handler)
end
def on_V2MoneyManagementInboundTransferAvailableEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.available", &handler)
end
def on_V2MoneyManagementInboundTransferBankDebitFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.bank_debit_failed", &handler)
end
def on_V2MoneyManagementInboundTransferBankDebitProcessingEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.bank_debit_processing", &handler)
end
def on_V2MoneyManagementInboundTransferBankDebitQueuedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.bank_debit_queued", &handler)
end
def on_V2MoneyManagementInboundTransferBankDebitReturnedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.bank_debit_returned", &handler)
end
def on_V2MoneyManagementInboundTransferBankDebitSucceededEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.inbound_transfer.bank_debit_succeeded", &handler)
end
def on_V2MoneyManagementOutboundPaymentCanceledEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.canceled", &handler)
end
def on_V2MoneyManagementOutboundPaymentCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.created", &handler)
end
def on_V2MoneyManagementOutboundPaymentFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.failed", &handler)
end
def on_V2MoneyManagementOutboundPaymentPostedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.posted", &handler)
end
def on_V2MoneyManagementOutboundPaymentReturnedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.returned", &handler)
end
def on_V2MoneyManagementOutboundPaymentUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_payment.updated", &handler)
end
def on_V2MoneyManagementOutboundTransferCanceledEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.canceled", &handler)
end
def on_V2MoneyManagementOutboundTransferCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.created", &handler)
end
def on_V2MoneyManagementOutboundTransferFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.failed", &handler)
end
def on_V2MoneyManagementOutboundTransferPostedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.posted", &handler)
end
def on_V2MoneyManagementOutboundTransferReturnedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.returned", &handler)
end
def on_V2MoneyManagementOutboundTransferUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.outbound_transfer.updated", &handler)
end
def on_V2MoneyManagementPayoutMethodUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.payout_method.updated", &handler)
end
def on_V2MoneyManagementReceivedCreditAvailableEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_credit.available", &handler)
end
def on_V2MoneyManagementReceivedCreditFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_credit.failed", &handler)
end
def on_V2MoneyManagementReceivedCreditReturnedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_credit.returned", &handler)
end
def on_V2MoneyManagementReceivedCreditSucceededEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_credit.succeeded", &handler)
end
def on_V2MoneyManagementReceivedDebitCanceledEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_debit.canceled", &handler)
end
def on_V2MoneyManagementReceivedDebitFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_debit.failed", &handler)
end
def on_V2MoneyManagementReceivedDebitPendingEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_debit.pending", &handler)
end
def on_V2MoneyManagementReceivedDebitSucceededEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_debit.succeeded", &handler)
end
def on_V2MoneyManagementReceivedDebitUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.received_debit.updated", &handler)
end
def on_V2MoneyManagementTransactionCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.transaction.created", &handler)
end
def on_V2MoneyManagementTransactionUpdatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.money_management.transaction.updated", &handler)
end
def on_V2PaymentsOffSessionPaymentAuthorizationAttemptFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.authorization_attempt_failed", &handler)
end
def on_V2PaymentsOffSessionPaymentAuthorizationAttemptStartedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.authorization_attempt_started", &handler)
end
def on_V2PaymentsOffSessionPaymentCanceledEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.canceled", &handler)
end
def on_V2PaymentsOffSessionPaymentCreatedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.created", &handler)
end
def on_V2PaymentsOffSessionPaymentFailedEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.failed", &handler)
end
def on_V2PaymentsOffSessionPaymentRequiresCaptureEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.requires_capture", &handler)
end
def on_V2PaymentsOffSessionPaymentSucceededEventNotification(&handler)
raise ArgumentError, "Block required to register event handler" if handler.nil?
register("v2.payments.off_session_payment.succeeded", &handler)
end
# event-handler-methods: The end of the section generated from our OpenAPI spec
end
end

View File

@ -1,53 +0,0 @@
# frozen_string_literal: true
# typed: true
module Stripe
class StripeEventHandler
sig do
params(client: ::Stripe::StripeClient, webhook_secret: String)
.void
end
def initialize(client, webhook_secret); end
end
sig do
params(
webhook_body: String,
sig_header: String
)
.void
end
def handle(webhook_body, sig_header); end
sig do
overridable.params(event_notification: ::Stripe::V2::Core::EventNotification, client: ::Stripe::StripeClient).void
end
def on_unhandled_event_notification(event_notification, client); end
sig do
overridable.params(event_notification: ::Stripe::Events::UnknownEventNotification, client: ::Stripe::StripeClient).void
end
def on_UnknownEventNotification(event_notification, client); end
# event-handler-methods: The beginning of the section generated from our OpenAPI spec
sig do
overridable.params(event_notification: ::Stripe::Events::V1BillingMeterErrorReportTriggeredEventNotification, client: ::Stripe::StripeClient).void
end
def on_V1BillingMeterErrorReportTriggeredEventNotification(event_notification, client);
end
sig do
overridable.params(event_notification: ::Stripe::Events::V1BillingMeterNoMeterFoundEventNotification, client: ::Stripe::StripeClient).void
end
def on_V1BillingMeterNoMeterFoundEventNotification(event_notification, client);
end
sig do
overridable.params(event_notification: ::Stripe::Events::V2CoreEventDestinationPingEventNotification, client: ::Stripe::StripeClient).void
end
def on_V2CoreEventDestinationPingEventNotification(event_notification, client);
end
# event-handler-methods: The end of the section generated from our OpenAPI spec
end

View File

@ -0,0 +1,414 @@
# frozen_string_literal: true
# typed: true
module Stripe
class UnhandledNotificationDetails
sig { returns(T::Boolean) }
def is_known_event_type; end
end
class StripeEventRouter
sig do
params(
client: ::Stripe::StripeClient,
webhook_secret: String,
on_unhandled_handler: T.proc.params(
event_notification: ::Stripe::V2::Core::EventNotification,
client: ::Stripe::StripeClient,
details: ::Stripe::UnhandledNotificationDetails).void)
.void
end
def initialize(client, webhook_secret, &on_unhandled_handler); end
end
sig do
params(
webhook_body: String,
sig_header: String
)
.void
end
def handle(webhook_body, sig_header); end
# event-handler-methods: The beginning of the section generated from our OpenAPI spec
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V1BillingMeterErrorReportTriggeredEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V1BillingMeterErrorReportTriggeredEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V1BillingMeterNoMeterFoundEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V1BillingMeterNoMeterFoundEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountClosedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountClosedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationCustomerCapabilityStatusUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationCustomerCapabilityStatusUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationCustomerUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationCustomerUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationMerchantCapabilityStatusUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationMerchantCapabilityStatusUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationMerchantUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationMerchantUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationRecipientUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationRecipientUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingConfigurationStorerUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingConfigurationStorerUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingDefaultsUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingDefaultsUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingIdentityUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingIdentityUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountIncludingRequirementsUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountIncludingRequirementsUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountLinkReturnedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountLinkReturnedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountPersonCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountPersonCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountPersonDeletedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountPersonDeletedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreAccountPersonUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreAccountPersonUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2CoreEventDestinationPingEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2CoreEventDestinationPingEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementAdjustmentCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementAdjustmentCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementFinancialAccountCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementFinancialAccountCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementFinancialAccountUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementFinancialAccountUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementFinancialAddressActivatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementFinancialAddressActivatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementFinancialAddressFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementFinancialAddressFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferAvailableEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferAvailableEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferBankDebitFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferBankDebitFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferBankDebitProcessingEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferBankDebitProcessingEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferBankDebitQueuedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferBankDebitQueuedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferBankDebitReturnedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferBankDebitReturnedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementInboundTransferBankDebitSucceededEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementInboundTransferBankDebitSucceededEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentCanceledEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentCanceledEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentPostedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentPostedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentReturnedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentReturnedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundPaymentUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundPaymentUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferCanceledEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferCanceledEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferPostedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferPostedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferReturnedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferReturnedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementOutboundTransferUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementOutboundTransferUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementPayoutMethodUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementPayoutMethodUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedCreditAvailableEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedCreditAvailableEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedCreditFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedCreditFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedCreditReturnedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedCreditReturnedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedCreditSucceededEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedCreditSucceededEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedDebitCanceledEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedDebitCanceledEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedDebitFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedDebitFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedDebitPendingEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedDebitPendingEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedDebitSucceededEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedDebitSucceededEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementReceivedDebitUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementReceivedDebitUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementTransactionCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementTransactionCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2MoneyManagementTransactionUpdatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2MoneyManagementTransactionUpdatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentAuthorizationAttemptFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentAuthorizationAttemptFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentAuthorizationAttemptStartedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentAuthorizationAttemptStartedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentCanceledEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentCanceledEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentCreatedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentCreatedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentFailedEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentFailedEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentRequiresCaptureEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentRequiresCaptureEventNotification(&blk);
end
sig do
params(blk: T.proc.params(event_notification: ::Stripe::Events::V2PaymentsOffSessionPaymentSucceededEventNotification, client: ::Stripe::StripeClient).void).void
end
def on_V2PaymentsOffSessionPaymentSucceededEventNotification(&blk);
end
# event-handler-methods: The end of the section generated from our OpenAPI spec
end