Giter Club home page Giter Club logo

stripe's Introduction

stripe's People

Contributors

formator avatar jklemmack avatar jpasichnyk avatar leepaulsmith avatar mythz avatar paulallington avatar pseabury avatar scottmcarthur avatar xplicit avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

stripe's Issues

Please include decline codes

When the Stripe API returns 402, and the code is card_declined, can we get the decline_code?

This would help us to tell our customers when to reach out to their bank. For example, if the decline_code is "do_not_honor", the Stripe documentation indicates that the customer has to reach out to her bank to correct the payment processing issue. It's not an issue on Stripe's end our ours as the merchant. These type of "it's the bank's issue with their client" issues would be good to just tell them upfront as it would save us support time.

UpdateStripeCustomer Metadata malformed

Metadata problem for ServiceStack/Stripe when having multiple entries in Metadata Dictionary.

gateway.Post(new UpdateStripeCustomer
{
    Id = "xxxx",
    Metadata = new Dictionary<string, string>
    {
        { "Data1", "Value1" },
        { "Data2", "Value2" }
    }
}

Metadata seen by Stripe dashboard
Data1 = "Value1metadata[Data2]=Value2"

Test function Can_Create_and_UpdateCustomer_with_Metadata() would spot this bug if it was testing for more than one dictionary member.

Return charges from a specified date

Would it be possible to implement the API charges[lt], lte etc. which allow charges from a particular period to be returned. When there are many charges its nice to be able to filter them by a period.

Getting payment methods as list not working

In the documentation the "GetStripeCards" is not a valid Class name.
There is something similar called "GetStripeCustomerCards" but those goes to the incorrect endpoint.

So it looks like there is currently no way to get a list of payment methods for a specific customer.

I'm using the .net standard version (.Core)

Create a new Subscription

Hello,
I have some problems with subscriptions.
When I create a subscription, it is well created at the stripe level but when I want to create another new subscription with the same customer, it just update the last subscription and not create a new one. So I would like to know if there is a method to create a new subscription like here and not update the customer old subscription like given here.

How can I handle 3D Secure Card payment?

Hey, I wanted to ask you that how can I handle payments which are being made by customers using 3D Secure Credit/Debit Cards?
Is there any way to handle that using this library?

image

Here are some sample Test Cards, Stripe Testing Cards.
This issue always comes, when using cards for whichs 3D Secure or 3D Secure 2 is required.

Your support on this would be highly appreciated.

Unable to attach a card token to a customer, since the "Source" property is not exposed on UpdateStripeCustomer

Based on the documentation, it looks like we should be able to take a card token obtained through stripe.js, and attach it to a customer via the Source parameter of the update request. however, this property is missing.

https://stripe.com/docs/api/curl#create_customer

specifically:
curl https://api.stripe.com/v1/customers
-u sk_test_testkeyhere:
-d description="Customer for [email protected]"
-d source=tok_testtokenhere

Iphone/Android impelementation problems

Hey, i have been trying to integrate Stipe into my iPhone application but got crash
Here is the inner exception
"InnerException {System.TypeInitializationException: An exception was thrown by the type initializer for ServiceStack.LicenseUtils ---> System.NullReferenceException: Object reference not set to an instance of an object at ServiceStack.LicenseUtils..cctor () [0x00000] in :0 --- End of inner exception stack trace --- at ServiceStack.Text.JsConfig..cctor () [0x00000] in :0 } System.TypeInitializationException"

Could you please prepare working sample for iPhone (trial period maybe just for testing )

Events support?

Are there any plans to support Stripe events? I would like to be able to use this with webhook requests

Subscription is null in GetStripeCustomer

Hi Guys,

I can see that a fix was made on 9th Sept (commit = 1ed9160) that should have fixed this issue. So I've updated all my nuget packages (V4.0.33) so I have the latest but so for some reason when I'm debugging GetStripeCustomer I'm still getting a null Subscription property in the StripeCustomer object rather than a Subscriptions collection. I'm deleted all the servicestack package and re-downloaded then, restarted VS, restarted IIS and no joy.
Can someone confirm whether this fix was in the latest release... I'm guessing as on master branch it should be in there.

I know for sure the Stripe API is working and returning subs as I've debugged that also (screenshot attached).

Any help much appreciated.

Thanks in advance
Claire

debug_getstripecustomer
nugget_packages_v4 0 33
servicestack stripe commit
subscriptions_comming_from_stripe_api

ServiceStack.Text.JsConfig.With(…) Method is missing?

Hi,

I'm testing Create Stripe Customer API:
return _stripeGateway.Post(new CreateStripeCustomer
{
Email = email,
Description = description
});

The above code throws the below exception:

Method not found: 'ServiceStack.Text.JsConfigScope ServiceStack.Text.JsConfig.With(System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1<ServiceStack.Text.ParseAsType>, System.Nullable1<ServiceStack.Text.ParseAsType>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1<ServiceStack.Text.DateHandler>, System.Nullable1<ServiceStack.Text.TimeSpanHandler>, System.Nullable1<ServiceStack.Text.PropertyConvention>, System.Nullable1<Boolean>, System.Nullable1, System.String, System.Func2<System.Type,System.String>, System.Func2<System.String,System.Type>, System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1, System.Nullable1<Boolean>, System.Nullable1, ServiceStack.EmptyCtorFactoryDelegate, System.String[])'.

I have installed ServiceStack.Stripe using 'Manage Nuget Packages' in Visual Studio.

Following are the dll versions show in my Visual Studio properties window:
Stripe: 4.0.42.0
ServiceStack.Client: 4.0.42.0
ServiceStack.Interfaces: 4.0.0.0
ServiceStack.Text: 4.0.42.0

Someone on Stackoverflow mentioned it could be because of dll version mismatch. Could ServiceStack.Interfaces dll causing the issue? If yes, then how and where to get the latest dll version (4.0.42.0)?

Please help !

Cheers,

License missing?

I just noticed this library is missing a license, and would love to use it for an upcoming project. Could you put the license file in this repo?

SubscriptionId on CancelStripeSubscription Model

In CancelStripeSubscription there's no field to inform the subscriptionID, only CustomerId.
If the customer have more than one subscription to a different plans, wich will be canceled?
Both?

CreateCard from token

I would like to Create a card from a token. It seems missing from the library.

$ curl https://api.stripe.com/v1/customers/cus_9O9nDRLqwaxzcX/sources \
   -u sk_test_BQokikJOvBiI2zlWg34LMnQ2: \
   -d source=tok_1895WV2eZvKYlo2CJRqkCEf5

I guess the code could be used like this:

StripeCard card = gateway.Post(new CreateStripeCard
{
    CustomerId = "cus_9O9nDRLqwaxzcX",
    Source = "tok_1895WV2eZvKYlo2CJRqkCEf5"
});

Add async support.

I would like to see async versions of the entire API for all the reasons that the async/await pattern is good.

public async Task<String> CreateCustomer(String cardId, String stripeApiKey)
{
    var gateway = new StripeGateway(stripeApiKey);
    var customer = await gateway.PostAsync(new CreateStripeCustomerWithToken { Card = cardId });
    return customer.Id;
}

Issue with multiple subscription

Hi,

I am using stripe.dll to create a subscription in stripe. This subscription is for new user creation in our application. Below is code to create a new subscription using VB.Net. This subscription will create when user will register first time to our application.

        Dim gateway = New StripeGateway(stripeKey)

        If (list("CouponId").ToString() = "") Then GoTo Line1 Else GoTo Line2

Line1: Dim subscription = gateway.Post(New SubscribeStripeCustomer() With { _

            .CustomerId = "cus_96OuD7MM31KKR3", _

            .Plan = "IG-monthly"

        })

        If subscription.Id = "" Then GoTo Line2 Else GoTo Line3

Line2: Dim subscription1 = gateway.Post(New SubscribeStripeCustomer() With { _

             .CustomerId = "cus_96OuD7MM31KKR3", _

             .Plan = "IG-monthly", _

             .Coupon ="choicefree2"_

         })

User is created successfully in stripe. Again our requirement is to create another subscription in stripe for same customer when he will purchase “Email on Acid” in our application. To do this task I wrote following code.

            Dim subscription As ServiceStack.Stripe.Types.StripeSubscription

            If list("CouponCode") <> "" Then



                subscription = gateway.Post(New SubscribeStripeCustomer() With { _

                             .CustomerId = "cus_96OuD7MM31KKR3", _

                                 .Plan = "EOAMTH", _

                                 .Coupon = "testc2"

                             })

            Else

                subscription = gateway.Post(New SubscribeStripeCustomer() With { _

                             .CustomerId = "cus_96OuD7MM31KKR3", _

                                 .Plan = "EOAMTH" _

                             })

            End If

Here again subscription is created successfully but it is ending existing subscription(IG-Monthly) and new subscription for EOAMTH is created. It is overriding existing subscription. Our requirement is to run both subscription for same customer. If user purchases “Email On Acid” then along with IG-Monthly plan he has to charge for EOAMTH plan based on his subscription date.

I have updated old stripe dll and now I am using ServiceStack.Stripe dll (Verson 4.5.0.0) but still this issue did not resolve.

Is this dll support multiple subscription only for licenced ?????? So i can purchase and go forword.
Please suggest me how will I fulfil my requirement.

Thanks & Regards,

Piyush Srivastava

PCI Compliance using Servicestack.Stripe

From what I read in the stripe documentation, it seems as if you use stripe.net or Servicestack.stripe, that you need to be PCI compliant, unless you create a token for a charge from a client side library like stripe.js and the pass to servicestack. Do we need to be PCI compliant when using Servicestack Stripe

Serializing Nested Types Fails

I created some new types to deal with Stripe Accounts, but they serialize incorrectly and get rejected by the Stripe servers. Here are the relevant Types.

// Extend the Existing Api with call the Create a Stripe Account
[Route("/accounts")]
public class CreateStripeAccount : IPost, IReturn<StripeAccount>
{
    public string Country { get; set; }
    public bool Managed { get; set; }
    public string Email { get; set; }
    public StripeTOSAcceptance TOSAcceptance { get; set; }
    public StripeLegalEntity LegalEntity { get; set; }
}

public class StripeTOSAcceptance
{
    public DateTime Date { get; set; }
    public string IP { get; set; }
    public string UserAgent { get; set; }
}

public class StripeLegalEntity
{    
    public StripeDOB DOB { get; set; }    
}

public class StripeAccount : StripeId
{
    public Dictionary<string, string> Keys { get; set; }
}

If I submit a CreateStripeAccount request like this:

var entity = new StripeLegalEntity { DOB = new StripeDOB { Day = "1", Month = "1", Year = "1970" }};
var custAccount = gateway.Post(new CreateStripeAccount
{
    Country = "US",
    Email = newCust.Email,
    Managed = true,
    TOSAcceptance = tos,
    LegalEntity = entity
}, Guid.NewGuid().ToString());

The problem is with the DOB property of StripeLegalEntity. It gets serialized as

...&legal_entity[dob]={day:1,month:1,year:1970}

resulting in this error

{
  "error": {
    "type": "invalid_request_error",
    "message": "'dob' must be a hash.",
    "param": "legal_entity[dob]"
  }
}

instead of a success response if I submit this

...&legal_entity[dob][day]=1&legal_entity[dob][month]=1&legal_entity[dob][year]=1970

How can I tell this library to serialize these types properly? The StripeTOSAcceptance object serializes properly, but it's only a 1 deep graph. I'm guessing that this has something to do with ServiceStack.Text and how it decides to emit these Complex objects to the UrlParams sequence, but am not sure.

Thanks,

Paul

No way to access Prices

Was trying to find a way to access the Prices attached to a product, I can't seem to find any reference to Stripe Price object.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.