stripe.net

“No such customer” when charging with Stripe

别等时光非礼了梦想. 提交于 2020-07-23 21:02:44
问题 I was testing around with Stripe API and I couldn't get this basic 'marketplace' scenario to work. The scenario is a buyer buys from a seller, and the application has a fee. My setup: # Seller has already connected their account to the application # through "Stripe Connect Standalone". Below will attempt to charge a customer. import stripe # application's sk from stripe stripe.api_key = "sk...." # Build customer customer = stripe.Customer.create( email = customer.email, card = token_from

Is it possible to get a count of subscribers for a plan from the Stripe API?

丶灬走出姿态 提交于 2020-01-02 18:17:12
问题 I am using the Stripe.net library to make calls against the Stripe API. I would like to get a total count of subscribers for various Plans but I am not sure if this is possible with the current API and/or the Stripe.NET Library at all. Can anyone provide any insight as to whether or not this is possible? 回答1: There's no direct call for this, but it's easy enough to accomplish. The "List all customers" API call ( StripeCustomerService 's List() method in Stripe.Net) returns the full JSON

Create Token With Apple Pay Without Payment

折月煮酒 提交于 2019-12-30 18:22:31
问题 I have two questions: Is there a way to create an STPToken using Apple Pay without a payment? In my iOS app, the customer either enters in their payment info or decides to use Apple Pay when registering. When the customer decides to make a purchase (some time in the future after signing up), their card will be automatically charged. There is a method that I can call to check if the payment request can be made, but it seems that I have to actually run the payment and charge the card in order

Stripe webhook signature failed - Stripe.net

时光总嘲笑我的痴心妄想 提交于 2019-12-23 12:43:22
问题 Im trying to implement a stripe webhook using the the c# library Stripe.net by Jayme Davis. i have set up the test endpoint in the stripe dashboard and generated the secret. The endpoint is being hit fine, and will generate the StripeEvent using the StripeEventUtility.ParseEvent. The problem is with using the ConstructEvent function i cant get the signatures to match. Any help or suggestions would be much appreciated. isSignaturePresent is returning false //call to create event stripeEvent =

Namespace not found for Stripe.net

最后都变了- 提交于 2019-12-14 02:34:19
问题 I'm trying to install a newer version of Stripe.net: https://github.com/jaymedavis/stripe.net Via Nuget, I build the Stripe.dll file I create a new website project I add a reference to Stripe.dll I add a reference to RestSharp.dll using System; using Stripe; public partial class _Default : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { StripeConfiguration.SetApiKey("[your api key here]"); } } But it throws the error: Error 1 The name 'StripeConfiguration' does not

How to Apply a Coupon to a Stripe Customer

冷暖自知 提交于 2019-12-13 02:31:50
问题 I can't find any way to apply the coupon/discount to an existing customer who has a reoccurring payment. I'm using the stripe gem. I went ahead and created the coupon on the Stripe dashboard. I see no mention on how to add a coupon on their API page. I've tried this solution below but to no avail. cu = Stripe::Customer.retrieve("cus_XXX") cu.discount = "my_coupon_id" cu.save # returns Stripe::InvalidRequestError: (Status 400) Received unknown parameter: discount There must be some sort of

How to make multiple payments using a token created from a customer using stripe?

偶尔善良 提交于 2019-12-12 03:26:34
问题 I'm getting an error when making a charge using a token created from a customer previously created using stripe. I need to be able to charge a user more than once so charges can go to multiple destinations, which is why I'm creating the token. However, when trying to charge anyone using the following code I get the error: Fatal error: Uncaught exception 'Stripe\Error\InvalidRequest' with message 'No such token: tok_187sfmBqiK1u6WYC3qS20eNu' $stripe_id and other variables have been assigned in

Ngrok not passing my post request on to localhost

人走茶凉 提交于 2019-12-07 06:47:37
问题 I'm trying to set up a webhook for Stripe and I've created a controller, according to the Stripe doc , to do it in ASP.Net MVC running in a virtual machine (maybe that changes things?). I've been testing the action in the controller to see if I can receive posts, so I'm using Postman to send my localhost posts requests which are working. But now I need to use Ngrok to give my localhost a url so that Stripe can use it. I'm running ngrok and passing in these parameters to run ngrok http -host

Is it possible to get a count of subscribers for a plan from the Stripe API?

[亡魂溺海] 提交于 2019-12-06 12:14:52
I am using the Stripe.net library to make calls against the Stripe API. I would like to get a total count of subscribers for various Plans but I am not sure if this is possible with the current API and/or the Stripe.NET Library at all. Can anyone provide any insight as to whether or not this is possible? There's no direct call for this, but it's easy enough to accomplish. The "List all customers" API call ( StripeCustomerService 's List() method in Stripe.Net ) returns the full JSON object for each customer, including their subscription and plan information. You can easily iterate through that

Non-English texts in Stripe possible?

*爱你&永不变心* 提交于 2019-12-03 08:25:59
问题 Successfully integrating Stripe into my online shop, I completely failed to get information on whether/how to configure Stripe to return error messages in German instead of English. So my question is: Is there a way to have localized error messages when using the client-side API " https://js.stripe.com/v2 "? Update 2014-05-03 I've asked the same question on Twitter and one of their staff (I guess) told me that this is currently not possible and on their TODO list. 回答1: For further reference: