#parK-dev
1 messages · Page 1 of 1 (latest)
Hi Jack,
Is there a way to track where the payment methods originated from? Whether its from the PaymentElement itself or set after on the intent or something.
Trying to figure out why there is 2 of the same test 4242 payment method on this test customer I made.
https://dashboard.stripe.com/test/customers/cus_NOcFC95Ockfl0U
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
These two payment_method was created for two different payment_intent
See
https://dashboard.stripe.com/test/logs/req_7QZl6yqyMRqXcf and https://dashboard.stripe.com/test/logs/req_Kq2zZ9c3x6zISP
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
Sign in to the Stripe Dashboard to manage business payments and operations in your account. Manage payments and refunds, respond to disputes and more.
So my intents are duplicated?
As far as I can tell, these are two different payment_intents
Yeah well they're the same order.
So I'll change my question a bit.
See these two payment methods are in fact the same card.
Is there a way to retrieve only unique cards when retrieving a customer's payment methods to show them?
from this api: https://stripe.com/docs/api/payment_methods/list
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
You should use https://stripe.com/docs/api/payment_methods/customer_list if you want to list your customer's payment_methods
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
current params are these :
let params = ListPaymentMethods {
customer: Some(customer.id),
ending_before: None,
expand: &["data"],
limit: Some(5),
starting_after: None,
type_: PaymentMethodTypeFilter::Card,
};
let methods = PaymentMethod::list(&self.client, params).await?;
Yeah I want to show my user their payment methods.
But it seems the same method (same say physical card like last4 4242) can be there multiple times if used on seperate payment intents?
Is there a way to only get back unique card or should I filter them myself?
You need to filter by yourself, you can check the card's fingerprint (https://stripe.com/docs/api/payment_methods/object#payment_method_object-card-fingerprint) against another card to determine if they are the same card.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.