#hugues9308

1 messages · Page 1 of 1 (latest)

neat roseBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

marsh kite
#

hi there!

#

do you get an error when using the code you shared?

tight lantern
#

No but the returned SetupIntent object contains a null value for its payment_method_options property. I think that it's due to one of the limitations of stripe-mock.

marsh kite
#

I think that's exppected. based on the readme:

Responses are generated based off resource fixtures [...] They are hardcoded, and will not necessarily represent realistic responses based on the parameters you input into the request.

tight lantern
#

I know this. All I wanted to verify is how to specify the format for an array of values for payment_method_options[acss_debit][mandate_options][default_for][]. I want its value to be [invoice, subscription] . I'm not sure if I've secified it correctly.

late zenith
#

Hi! I'm taking over from my colleague. Please, give me a moment to catch up.

tight lantern
#

Sure

late zenith
#

Why are you not using the Test mode?

tight lantern
#

Because I want to use stripe-mock for our integration tests. Is it a bad idea?

late zenith
#

No, but Test mode would provide you with more real-life responses.

tight lantern
#

Sure, I'm verifying my API calls with small java prototypes calling the Stripe server in *Test mode'. But the build process of our project include test task and using the Stripe server for this is not performant in terms of execution time. Stripe-mock is light and executes fast. We'd use it to confirm that the syntax of the Sripe API calls is correct.

#

So, back to my question: How to specify that payment_method_options[acss_debit][mandate_options][default_for][] should contain [invoice, subscription]?

late zenith
tight lantern
#

So I have to do it that way?

...
    -d "payment_method_options[acss_debit][mandate_options][default_for][]"=invoice \
    -d "payment_method_options[acss_debit][mandate_options][default_for][]"=subscription \
...
late zenith
#

Yes

tight lantern
#

Thanks, have a nice day.

late zenith
#

Happy to help.