Webhooks
Payment Method
Notification kinds
The notification kind, returned by calling kind on the notification object, reveals what triggered the webhook. The webhookNotification.kind for Payment Method webhooks will be one of the following:
braintree.WebhookNotification.Kind.PaymentMethodRevokedByCustomer
braintree.WebhookNotification.Kind.PaymentMethodCustomerDataUpdated
The following table describes the conditions that trigger each kind of webhook.
Notification Type | Description |
---|---|
payment_revoked_by_customer | A payment instrument that was previously enabled has been revoked by the customer or by Venmo. |
payment_method_customer_data_updated | A payment method's customer data has been updated. Currently, the only trigger for this webhook is when a customer updates their Enriched Customer Data in Venmo, provided that the merchant has enabled the feature. |
Attributes
kind
enumThe kind of webhook notification.
timestamp
dateThe UTC time at which the webhook was triggered.
revokedPaymentMethodMetadata
Metadata referencing the revoked payment method.
token
stringAn alphanumeric value that references a specific payment method stored in your Vault (used for recurring purchases).
customerId
stringA value representing an existing customer stored in your Vault. Use Customer: Find call to look up a single customer.
revokedPaymentMethod
The PaymentMethod object associated with the revoked payment method.
paymentMethodCustomerDataUpdatedMetadata
Metadata referencing the payment method whose customer data was updated.
token
stringAn alphanumeric value that references a specific payment method stored in your Vault (used for recurring purchases).
paymentMethod
The payment method including the customer data that was updated.
datetimeUpdated
stringTimestamp of the customer data update.
enrichedCustomerData
Collection of fields encompassing the Enriched Customer Data feature.
profileData
Collection of fields encompassing the customer's profile data.
username
stringThe customer's Venmo username.
firstName
stringThe customer's first name.
lastName
stringThe customer's last name.
phoneNumber
stringThe customer's phone number.
email
stringThe customer's email.
fieldsUpdated
ArrayArray containing which fields from the data collection were updated, triggering the webhook.