Webhooks

Payment Methodanchor

Notification kindsanchor

The notification kind, returned by calling kind on the notification object, reveals what triggered the webhook. The webhook_notification.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.
Currently this webhook will only be sent when a customer cancels their PayPal billing agreement, removes their Venmo connection, or when Venmo suspends the account due to suspicious activity on the customer's Venmo account.

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.

Attributesanchor

kindenum

The kind of webhook notification.

timestampdate

The UTC time at which the webhook was triggered.

revoked_payment_method_metadata

Metadata referencing the revoked payment method.

tokenstring

An alphanumeric value that references a specific payment method stored in your Vault (used for recurring purchases).

customer_idstring

A value representing an existing customer stored in your Vault. Use Customer: Find call to look up a single customer.

revoked_payment_method

The PaymentMethod object associated with the revoked payment method.

payment_method_customer_data_updated_metadata

Metadata referencing the payment method whose customer data was updated.

tokenstring

An alphanumeric value that references a specific payment method stored in your Vault (used for recurring purchases).

payment_method

The payment method including the customer data that was updated.

datetime_updatedstring

Timestamp of the customer data update.

enriched_customer_data

Collection of fields encompassing the Enriched Customer Data feature.

profile_data

Collection of fields encompassing the customer's profile data.

usernamestring

The customer's Venmo username.

first_namestring

The customer's first name.

last_namestring

The customer's last name.

phone_numberstring

The customer's phone number.

emailstring

The customer's email.

fields_updatedArray

Array containing which fields from the data collection were updated, triggering the webhook.