Skip to main content

Update Credit Card Details


Use Update Credit Card Details to update a user's credit card details.

This screen loads the current saved card, captures updated card details through the secure payment field, and submits the selected payment method for the current payment context.



This screen includes:

#ElementDescription
1HeaderDisplays Update payment details with back navigation and settings access.
2Payment method sectionDisplays the saved payment method.
3Saved card selectorLets the user select the saved card for update.
4Update credit card details labelIdentifies the card details update area.
5Card number fieldCaptures the updated credit card number.
6Save card checkboxLets the user keep card details secured for future bookings.
7Secure payment indicatorDisplays the secure payment status and supported payment logos.
8Update actionSubmits the updated payment details.

Workflow

  1. Open Update payment details.
  2. Load the current payment method.
  3. Enter the new card details in the secure card field.
  4. Select or clear Keep card details secured for future appointments.
  5. Select Update.
  6. Attach the payment method to the user account.
  7. Apply the payment method to the appointment when appointment context exists.
  8. Display success or error state.

Validations

ScenarioApp BehaviorSDK Output
Session invalidBlock payment updatestate = unauthenticated
Payment method unavailableDisplay payment method errorerror = payment_method_unavailable
Card number emptyBlock updateerror = missing_card_number
Card details invalidDisplay card validation errorerror = invalid_card
Secure payment field unavailableDisplay payment field errorerror = payment_field_unavailable
Payment method unchangedPreserve current payment methodstate = unchanged
Update succeedsRefresh the displayed payment methodpaymentMethod = updated
Update failsDisplay error statestate = error

Actions

ScenarioApp BehaviorSDK Output
Update payment details openedLoad payment method screenPUT /api/v3/payment-method
Saved card selectedSet current payment methodpaymentMethod = selected
Card details enteredUpdate secure card field statecard = updated
Keep card selectedSave card for future appointmentssaveCard = true
Keep card clearedUse card for current payment context onlysaveCard = false
Update selectedAttach payment method to the accountPATCH /api/v3/payment-method
Update succeedsDisplay updated payment methodstate = updated
Update rejectedPreserve previous payment methodstate = unchanged

Endpoint Resources

Update

PUT 

v3/payment-method

Displays the screen for updating the patient's credit card payment method.

Confirm Payment Method

PATCH 

v3/payment-method

Attaches a payment method to the user account and applies it to the specified appointment.