Refactored payment link creation to ensure booking_id is set in both the PaymentLink and PaymentIntent metadata. Extracted parameter building logic into a helper for improved testability. Added a unit test to verify metadata propagation.