#stripe_connect_platform-api-keys

1 messages · Page 1 of 1 (latest)

stoic pasture
#

You would use the test API key to make test-mode API requests

pulsar dagger
#

Sorry, so in development

#

We pass in the:
ca_ test
and the test api.key

#

I think I just needed to switch the ca_ as well for dev

#

I always get hella confused on this one.
We let our connected customer make livemode: true and livemode: false buttons to allow for testing.
And I always get confused since when we are in dev mode, we still would love to make it similar to what our customer do in production where they can make both test and live

#

Can you clarify

#

When we are connecting a Standard Stripe account in production we only need the top one right?

#

But in development, do we need the top one and the bottom one?

#

I am confused b/c when you toggle to "testmode" I see only a live connnection and I had to run the connect flow twice and switch out our ca_ and api_key to get it connected like in the above pic since we weren't getting webhooks for payments completed in development for a test button

#

I am seeing if this works. This one always boggles my mind

#

That did it. Hmmm.

#

So question is, when we are in development, do we need to do something different?
Like do we need to loop through this twice, passing in both our ca_test and ca_live
response = HTTParty.post(uri,
:body => { :client_secret => "#{platforms_secret_key}",
:code => code,
:grant_type => "authorization_code"
}.to_json,
:headers => { 'Content-Type' => 'application/json' } )
And in prod, we just pass in live and then we get both test and live????

glossy oyster
#

Hey apologies for the silence here, two-shoes had to step out and I am just now catching up on this thread.

#

Glad that you found your way forward on this!

#

I don't think the auth code can be used twice like that but will check.

glossy oyster
#

It looks like you can't re-use the code. To connect in both modes, your integration will need to have the user go through connect onboarding once in each mode

pulsar dagger
#

hm

#

ok this is really just for development. that's what i did. Hm...Ok, i keep revisiting this to find a more elegant way. OK.