Skip to main content
Crovver uses three different credential types depending on who is making the call.

Credential Types

TypeHeaderWho uses itFormat
Public Keyx-public-key or ?publicKey=Browser / React SDKpk_live_...
API Key (Secret)Authorization: BearerYour backend serversk_live_...
Service Keyx-service-keyEcom portal / internal servicesenv var

Which Key Should I Use?

Use your Public Key. It’s safe to expose in frontend code. It can only read data and initiate checkout — it cannot modify subscriptions.
<CrovverProvider config={{ publicKey: "pk_live_..." }}>
Use your Secret Key (API Key) in the Authorization header. Keep this server-side only — never expose it in client code.
Authorization: Bearer sk_live_...
Use the Service Key with an orgId query param. This is an internal credential for server-to-server calls between Crovver services.
x-service-key: <CROVVER_SERVICE_KEY>
GET /api/public/subscriptions?orgId=org_123

Test vs Live Keys

Both public and secret keys come in test and live variants:
PrefixEnvironment
pk_live_, sk_live_Production — real payments
pk_test_, sk_test_Test — routed to test payment credentials
Test keys route to payment providers configured with test credentials. Use Stripe test card 4242 4242 4242 4242 to simulate successful payments.