Raw
1 import Medusa from "@medusajs/js-sdk"
2
3 const backendUrl = __BACKEND_URL__ ?? "/"
4 const authType = __AUTH_TYPE__ ?? "session"
5 const jwtTokenStorageKey = __JWT_TOKEN_STORAGE_KEY__ || undefined
6
7 export const sdk = new Medusa({
8 baseUrl: backendUrl,
9 auth: {
10 type: authType,
11 jwtTokenStorageKey: jwtTokenStorageKey,
12 },
13 })