## Update a PaymentRequest object `paymentRequest.update(options: object)` `PaymentRequest` instances can be updated with an options object. Available options are documented below. `paymentRequest.update` can only be called when the browser payment interface is not showing. Listen to the [click](https://docs.stripe.com/js/element/events.md) and [cancel](https://docs.stripe.com/js/element/events.md) events to detect if the payment interface has been initiated. To update the `PaymentRequest` right before the payment interface is initiated, call `paymentRequest.update` in your click event handler. - `options` A set of options to update this PaymentRequest instance with. - `currency` Three character currency code (e.g., `usd`). - `total` A [PaymentItem](#payment_item_object) object. This `PaymentItem` is shown to the customer in the browser’s payment interface. - `displayItems` An array of [PaymentItem](#payment_item_object) objects. These payment items are shown as line items in the browser’s payment interface. Note that the sum of the line item amounts does not need to add up to the `total` amount above. - `shippingOptions` An array of [ShippingOption](https://docs.stripe.com/js/appendix/shipping_option.md) objects. The first shipping option listed appears in the browser payment interface as the default option. - `applePay` Specify Apple Pay specific options. These are passed through to the Apple Pay API. - `recurringPaymentRequest` Specify a request to set up a recurring payment. See the [Apple Pay documentation](https://developer.apple.com/documentation/apple_pay_on_the_web/applepayrecurringpaymentrequest) for more details. - `paymentDescription` - `managementURL` - `regularBilling` - `amount` - `label` - `recurringPaymentStartDate` - `recurringPaymentEndDate` - `recurringPaymentIntervalUnit` - `recurringPaymentIntervalCount` - `trialBilling` - `amount` - `label` - `recurringPaymentStartDate` - `recurringPaymentEndDate` - `recurringPaymentIntervalUnit` - `recurringPaymentIntervalCount` - `billingAgreement` - `deferredPaymentRequest` Specify a request to set up a deferred payment. See the [Apple Pay documentation](https://developer.apple.com/documentation/apple_pay_on_the_web/applepaydeferredpaymentrequest) for more details. - `paymentDescription` - `managementURL` - `deferredBilling` - `amount` - `label` - `deferredPaymentDate` - `billingAgreement` - `freeCancellationDate` If set, you must also supply a freeCancellationDateTimeZone. - `freeCancellationDateTimeZone` If set, you must also supply a freeCancellationDate. These are [tz](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) timezones such as `America/Los_Angeles`, `Europe/Dublin`, and `Asia/Singapore`. - `automaticReloadPaymentRequest` Specify a request to set up an automatic reload payment. See the [Apple Pay documentation](https://developer.apple.com/documentation/apple_pay_on_the_web/applepayautomaticreloadpaymentrequest) for more details. - `paymentDescription` - `managementURL` - `automaticReloadBilling` - `amount` - `label` - `automaticReloadPaymentThresholdAmount` - `billingAgreement` - `cardFunding` By default, Apple Pay allows both credit and debit cards. You can specify if you only want to support one type of card with either 'supportsDebit' or 'supportsCredit'. ### Example ```title Update a PaymentRequest ```