Skip to content

API Keys

Gro uses API keys for authentication. There are two types of keys for different use cases.

Type Purpose Safe to Expose?
SDK Browser-based tracking SDK Yes — scoped to tracking only
API Server-to-server API calls No — keep secret on your server

Used by the Gro JavaScript tracking SDK in your storefront. These keys can only submit tracking events and cannot access the backend API. It’s safe to include them in client-side code.

Used for server-to-server integrations. These keys can authenticate backend API requests and should be kept secret. Required for programmatic access to the Gro API.

gro_{mode}_{accountId}_{random}_{hmac}
  • Mode: test or live
  • Account ID: identifies which account the key belongs to
  • Random: unique random string
  • HMAC: signature for edge validation

Navigate to Settings → API Keys in the Gro dashboard to:

  • Generate new SDK or API keys
  • View existing keys (the full key is shown only once at creation)
  • Revoke keys that are no longer needed
  • Track key usage

Include in your tracking SDK initialisation:

gro.init("gro_live_acc123_xK9p2nZ4s_a7f3c2b");

Pass it in the X-API-Key header:

Terminal window
curl -H "X-API-Key: gro_live_acc123_xK9p2nZ4s_a7f3c2b" \
https://api.usegro.co/api/...

For full API documentation, see the API Reference.