Learn how to customize checkout sessions for common use cases like shipping, taxes, discounts, and embedded checkout.
shipping_address_collection
parameter to true
as part of the payload.
If you additionally want to charge a shipping rate then you can do so by either:
shipping_rate_id
as part of the payload when creating a checkout session.
checkout.session.completed
Webhook Event. However, unlike webhooks, the event from the client
is not guaranteed to fire. Therefore it is recommended to listen to the webhooks in order to ensure that the message is
received.
The message could be customized by creating a redirect to your own site and having that page
post a message to the parent: