-
I created a secret api key in the following section: Now how do I use it to make requests? Like listing products? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 1 reply
-
In MedusaJS, the secret API key is used when you need to perform actions as an authenticated admin user directly from the frontend. If your goal is to display products in your webshop (storefront), you should use a publishable API key instead. This ensures secure access while exposing only the necessary public data. |
Beta Was this translation helpful? Give feedback.
-
I just found it's decribed here An It's kinda a twisted way of using basic authentication... |
Beta Was this translation helpful? Give feedback.
I just found it's decribed here
An
Authorization: Basic {token}
header must be added to the request.It's kinda a twisted way of using basic authentication...