#hopp8435_webhooks
1 messages ¡ Page 1 of 1 (latest)
Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.
- hopp8435_treasury-connect-accounts, 10 hours ago, 60 messages
đ Welcome to your new thread!
â˛ď¸ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question.
âąď¸ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.
đ This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1275293778449797212
đ Have more to share? Add more details, code, screenshots, videos, etc. below.
hello! I'm not sure what you mean by the event doesn't have the stripe_account via the SDK, can you share the code snippet where you're attempting to read/find the stripe_account on the event?
def handle_event(event: stripe.Event, service_factory: ServiceFactory) -> None:
if event.type == "payment_method.attached":
payment_method: stripe.PaymentMethod = event.data.object
financial_service = service_factory.get_financial_account_service()
if (
hasattr(payment_method, "us_bank_account")
and payment_method.us_bank_account is not None
):
stripe_account_id = event.stripe_account
if not stripe_account_id:
logger.error("Stripe account not found in event")
financial_service.create_external_account(payment_method, stripe_account_id)
else:
logger.error(f"Payment method not found and is not supported: {payment_method.id}")
So I am going through the Connect link a payment method flow. https://docs.stripe.com/treasury/examples/moving-money#adding-an-external-bank-account
The events being triggered dont' have the Connect's stripe_account on them
this is stripe-python right?
yup
shouldn't it be event.account?
i guess that would fix your issue?