#Rupinder
1 messages · Page 1 of 1 (latest)
this is the code
Are you talking about customer's invoice_settings.default_payment_method ? https://stripe.com/docs/api/customers/update?lang=ruby#update_customer-invoice_settings-default_payment_method
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
it updated the name insted of card
yes
I'm not familiar with php curl, but there's a Stripe PHP library that you should use in your PHP app
how to pass this as parameter invoice_settings.default_payment_method
can you give me example
$stripe->customers->update(
'cus_XXX',
['invoice_settings' => ['default_payment_method' => 'pm_XXX']]
);
for some reason it is updating name
Was that the result from my code?
As I said earlier, I'm not familiar with PHP curl, but I can help if you are using Stripe PHP library.
anyone who can help me with curl
can you send me the link to stripe php library then
I've already sent you
now where to define secret key and how to include