@fluxyte/sdk 0.4.1 → 0.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -26,6 +26,29 @@ npm install @fluxyte/sdk
|
|
|
26
26
|
|
|
27
27
|
Treat your API key like a password. Do not commit it to source control.
|
|
28
28
|
|
|
29
|
+
### Create an API key
|
|
30
|
+
|
|
31
|
+
1. Sign up at `https://fluxyte.com/signup`
|
|
32
|
+
2. Verify your email
|
|
33
|
+
3. Open the `Account` menu
|
|
34
|
+
4. Select `API Keys`
|
|
35
|
+
5. Click `Create API Key`
|
|
36
|
+
6. Choose key type:
|
|
37
|
+
- `pk_*` (PUBLIC) for frontend/browser SDK usage
|
|
38
|
+
- `sk_*` (SECRET) for backend/server-only usage
|
|
39
|
+
7. Copy your API key (shown once)
|
|
40
|
+
|
|
41
|
+
### Use an API key
|
|
42
|
+
|
|
43
|
+
All integrations authenticate with an API key sent in the `X-API-Key` header.
|
|
44
|
+
|
|
45
|
+
- Use `pk_*` keys in browser/public SDK integrations
|
|
46
|
+
- Use `sk_*` keys only in backend/server environments
|
|
47
|
+
- For `pk_*` keys, configure allowed origins to restrict frontend domains
|
|
48
|
+
- The key controls organization access, docs scope, and analytics ownership
|
|
49
|
+
|
|
50
|
+
### Environment examples
|
|
51
|
+
|
|
29
52
|
- Vite: `VITE_FLUXYTE_API_KEY=pk_...`
|
|
30
53
|
- Next.js: `NEXT_PUBLIC_FLUXYTE_API_KEY=pk_...` (public key only)
|
|
31
54
|
- Server: `FLUXYTE_API_KEY=sk_...`
|