#Tifanny - secret

1 messages · Page 1 of 1 (latest)

tiny pendant
#

Hi! Can you double check that you are using the correct key? Based on the error message, it should be your secret key that looks like sk_xxx.

stuck shell
#

Hi ! Yes I checked again and the secret key starts with sk_live_xxx

#

and the other key starts with pk_live_xxx

tiny pendant
stuck shell
#

Ok, i'm going to check

#

could it be a problem if I deleted the old secret key and I didn't revoke it ?

tiny pendant
#

Delete means the key is deleted. Revoke means the key is deleted and then re-created.

#

So both options are possible

stuck shell
#

I checked and I use private key, but the problem is still here 😕

tiny pendant
#

Can you share the code that generate this error?

stuck shell
#

Sorry, I found a public key in my code. I try again.

tiny pendant
#

To be clear: sometimes you should use a public key (pk_xxx), for example on your frontend code to display the Payment Element. However on your backend code you should be using a secret key (sk_xxx).
You can learn more about API keys here: https://stripe.com/docs/keys

Manage your API keys to authenticate requests with Stripe.

stuck shell
#

Thank you so much, it works ! 🤩