brainerce 1.4.0 → 1.4.1

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/dist/index.js CHANGED
@@ -1487,18 +1487,22 @@ var BrainerceClient = class {
1487
1487
  * Works in vibe-coded, storefront, and admin mode
1488
1488
  */
1489
1489
  async forgotPassword(email) {
1490
+ const resetUrl = typeof window !== "undefined" ? `${window.location.origin}/reset-password` : void 0;
1490
1491
  if (this.isVibeCodedMode()) {
1491
1492
  return this.vibeCodedRequest("POST", "/customers/forgot-password", {
1492
- email
1493
+ email,
1494
+ resetUrl
1493
1495
  });
1494
1496
  }
1495
1497
  if (this.storeId && !this.apiKey) {
1496
1498
  return this.storefrontRequest("POST", "/customers/forgot-password", {
1497
- email
1499
+ email,
1500
+ resetUrl
1498
1501
  });
1499
1502
  }
1500
1503
  return this.adminRequest("POST", "/api/v1/customers/forgot-password", {
1501
- email
1504
+ email,
1505
+ resetUrl
1502
1506
  });
1503
1507
  }
1504
1508
  /**
package/dist/index.mjs CHANGED
@@ -1429,18 +1429,22 @@ var BrainerceClient = class {
1429
1429
  * Works in vibe-coded, storefront, and admin mode
1430
1430
  */
1431
1431
  async forgotPassword(email) {
1432
+ const resetUrl = typeof window !== "undefined" ? `${window.location.origin}/reset-password` : void 0;
1432
1433
  if (this.isVibeCodedMode()) {
1433
1434
  return this.vibeCodedRequest("POST", "/customers/forgot-password", {
1434
- email
1435
+ email,
1436
+ resetUrl
1435
1437
  });
1436
1438
  }
1437
1439
  if (this.storeId && !this.apiKey) {
1438
1440
  return this.storefrontRequest("POST", "/customers/forgot-password", {
1439
- email
1441
+ email,
1442
+ resetUrl
1440
1443
  });
1441
1444
  }
1442
1445
  return this.adminRequest("POST", "/api/v1/customers/forgot-password", {
1443
- email
1446
+ email,
1447
+ resetUrl
1444
1448
  });
1445
1449
  }
1446
1450
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "brainerce",
3
- "version": "1.4.0",
3
+ "version": "1.4.1",
4
4
  "description": "Official SDK for building e-commerce storefronts with Brainerce Platform. Perfect for vibe-coded sites, AI-built stores (Cursor, Lovable, v0), and custom storefronts.",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",