@zyphr-dev/node-sdk 0.1.43 → 0.1.45

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 CHANGED
@@ -381,16 +381,18 @@ await zyphr.devices.deleteUserDevices('user_123');
381
381
 
382
382
  Full Auth-as-a-Service API for end-user authentication: registration, login, MFA, magic links, OAuth, and more.
383
383
 
384
- > **Important:** Auth endpoints require application credentials, not just an API key. Create an application in the Zyphr dashboard first, then pass the credentials when constructing the client:
384
+ > **Important:** Auth endpoints use **Application-scoped** credentials (`X-Application-Key` + `X-Application-Secret`), which are distinct from the **Project-scoped** notification API key (`zy_live_*` / `zy_test_*`, sent as `Authorization: Bearer`). Create an application in the Zyphr dashboard first, then pass the credentials when constructing the client:
385
385
 
386
386
  ```ts
387
387
  const zyphr = new Zyphr({
388
- apiKey: process.env.ZYPHR_API_KEY!,
389
- applicationKey: process.env.ZYPHR_APP_PUBLIC_KEY!, // za_pub_*
390
- applicationSecret: process.env.ZYPHR_APP_SECRET_KEY!, // za_sec_*
388
+ apiKey: process.env.ZYPHR_API_KEY!, // Project-scoped: zy_live_* / zy_test_*
389
+ applicationKey: process.env.ZYPHR_APP_PUBLIC_KEY!, // Application-scoped public: za_live_pub_* / za_test_pub_*
390
+ applicationSecret: process.env.ZYPHR_APP_SECRET_KEY!, // Application-scoped secret: za_live_sec_* / za_test_sec_*
391
391
  });
392
392
  ```
393
393
 
394
+ > Legacy `za_pub_*` / `za_sec_*` application-key prefixes are deprecated but still accepted.
395
+
394
396
  > **Common mistake:** `POST /v1/auth/register` creates a **platform account** (for the Zyphr dashboard). To register **end users** in your application, use `POST /v1/auth/users/register` via `zyphr.auth.registration.registerEndUser()`.
395
397
 
396
398
  ```ts