@blinkdotnew/dev-sdk 2.1.7 → 2.1.9
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 +6 -6
- package/dist/index.mjs +6 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -398,7 +398,7 @@ var HttpClient = class {
|
|
|
398
398
|
this.getToken = getToken;
|
|
399
399
|
this.getValidToken = getValidToken;
|
|
400
400
|
this.authUrl = config.auth?.authUrl ?? "https://blink.new";
|
|
401
|
-
this.coreUrl = config.auth?.coreUrl ?? "https://
|
|
401
|
+
this.coreUrl = config.auth?.coreUrl ?? "https://core.blink.new";
|
|
402
402
|
}
|
|
403
403
|
/**
|
|
404
404
|
* Make an authenticated request to the Blink API
|
|
@@ -1179,14 +1179,14 @@ var BlinkAuth = class {
|
|
|
1179
1179
|
this.authConfig = {
|
|
1180
1180
|
mode: "managed",
|
|
1181
1181
|
// Default mode
|
|
1182
|
-
authUrl: "https://
|
|
1183
|
-
coreUrl: "https://
|
|
1182
|
+
authUrl: "https://laverna-nonsubmissive-semirhythmically.ngrok-free.dev",
|
|
1183
|
+
coreUrl: "https://core.blink.new",
|
|
1184
1184
|
detectSessionInUrl: true,
|
|
1185
1185
|
// Default to true for web compatibility
|
|
1186
1186
|
...config.auth
|
|
1187
1187
|
};
|
|
1188
|
-
this.authUrl =
|
|
1189
|
-
this.coreUrl = this.authConfig.coreUrl || "https://
|
|
1188
|
+
this.authUrl = "https://laverna-nonsubmissive-semirhythmically.ngrok-free.dev";
|
|
1189
|
+
this.coreUrl = this.authConfig.coreUrl || "https://core.blink.new";
|
|
1190
1190
|
const hostname = getLocationHostname();
|
|
1191
1191
|
if (hostname && this.authUrl === "https://blink.new" && (hostname === "localhost" || hostname === "127.0.0.1")) {
|
|
1192
1192
|
console.warn("\u26A0\uFE0F Using default authUrl in development. Set auth.authUrl to your app origin for headless auth endpoints to work.");
|
|
@@ -4804,7 +4804,7 @@ var BlinkRealtimeChannel = class {
|
|
|
4804
4804
|
return new Promise((resolve, reject) => {
|
|
4805
4805
|
try {
|
|
4806
4806
|
const httpClient = this.httpClient;
|
|
4807
|
-
const coreUrl = httpClient.coreUrl || "https://
|
|
4807
|
+
const coreUrl = httpClient.coreUrl || "https://core.blink.new";
|
|
4808
4808
|
const baseUrl = coreUrl.replace("https://", "wss://").replace("http://", "ws://");
|
|
4809
4809
|
const wsUrl = `${baseUrl}?project_id=${this.projectId}`;
|
|
4810
4810
|
console.log(`\u{1F517} Attempting WebSocket connection to: ${wsUrl}`);
|
package/dist/index.mjs
CHANGED
|
@@ -396,7 +396,7 @@ var HttpClient = class {
|
|
|
396
396
|
this.getToken = getToken;
|
|
397
397
|
this.getValidToken = getValidToken;
|
|
398
398
|
this.authUrl = config.auth?.authUrl ?? "https://blink.new";
|
|
399
|
-
this.coreUrl = config.auth?.coreUrl ?? "https://
|
|
399
|
+
this.coreUrl = config.auth?.coreUrl ?? "https://core.blink.new";
|
|
400
400
|
}
|
|
401
401
|
/**
|
|
402
402
|
* Make an authenticated request to the Blink API
|
|
@@ -1177,14 +1177,14 @@ var BlinkAuth = class {
|
|
|
1177
1177
|
this.authConfig = {
|
|
1178
1178
|
mode: "managed",
|
|
1179
1179
|
// Default mode
|
|
1180
|
-
authUrl: "https://
|
|
1181
|
-
coreUrl: "https://
|
|
1180
|
+
authUrl: "https://laverna-nonsubmissive-semirhythmically.ngrok-free.dev",
|
|
1181
|
+
coreUrl: "https://core.blink.new",
|
|
1182
1182
|
detectSessionInUrl: true,
|
|
1183
1183
|
// Default to true for web compatibility
|
|
1184
1184
|
...config.auth
|
|
1185
1185
|
};
|
|
1186
|
-
this.authUrl =
|
|
1187
|
-
this.coreUrl = this.authConfig.coreUrl || "https://
|
|
1186
|
+
this.authUrl = "https://laverna-nonsubmissive-semirhythmically.ngrok-free.dev";
|
|
1187
|
+
this.coreUrl = this.authConfig.coreUrl || "https://core.blink.new";
|
|
1188
1188
|
const hostname = getLocationHostname();
|
|
1189
1189
|
if (hostname && this.authUrl === "https://blink.new" && (hostname === "localhost" || hostname === "127.0.0.1")) {
|
|
1190
1190
|
console.warn("\u26A0\uFE0F Using default authUrl in development. Set auth.authUrl to your app origin for headless auth endpoints to work.");
|
|
@@ -4802,7 +4802,7 @@ var BlinkRealtimeChannel = class {
|
|
|
4802
4802
|
return new Promise((resolve, reject) => {
|
|
4803
4803
|
try {
|
|
4804
4804
|
const httpClient = this.httpClient;
|
|
4805
|
-
const coreUrl = httpClient.coreUrl || "https://
|
|
4805
|
+
const coreUrl = httpClient.coreUrl || "https://core.blink.new";
|
|
4806
4806
|
const baseUrl = coreUrl.replace("https://", "wss://").replace("http://", "ws://");
|
|
4807
4807
|
const wsUrl = `${baseUrl}?project_id=${this.projectId}`;
|
|
4808
4808
|
console.log(`\u{1F517} Attempting WebSocket connection to: ${wsUrl}`);
|
package/package.json
CHANGED