I had Stripe Connect working in development / test environment, however I am having issues when pushing live to production, receiving the following JSON error:
{
error: {
message: "No application matches the supplied client identifier"
}
}
I am using RoR, with Devise, and Figaro. I admit that there is some confusion between the differences of both my config/locales/secrets.yml, and config/locales/application.yml
My devise.rb is shown below:
if Rails.env.production?
Rails.configuration.stripe = {
publishable_key: ENV[ 'STRIPE_PUBLISHABLE_KEY' ],
secret_key: ENV[ 'STRIPE_SECRET_KEY' ]
}
else
Rails.configuration.stripe = {
publishable_key: 'pk_test_abcdefghijklmnopqrstuvwxyz', Not Real...
secret_key: 'sk_test_abcdefghijklmnopqrstuvwxyz'
}
end
Stripe.api_key = Rails.configuration.stripe[:secret_key]
In my application.yml, I have:
STRIPE_CLIENT_ID: (live key here....)
STRIPE_SECRET_KEY: (live key here....)
STRIPE_PUBLISHABLE_KEY: (live key here....)
In my secrets.yml, I have:
development:
secret_key_base: key.....
stripe_publishable_key: key.....
stripe_secret_key: key....
stripe_client_id: key....
test:
secret_key_base: key.....
production:
secret_key_base: key.....
stripe_publishable_key: key.....
stripe_secret_key: key.....
client_id: key.....
Any help or suggestions would be hugely appreciated.
Cheers,