@solongate/proxy 0.81.90 → 0.81.91

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.
@@ -134,6 +134,7 @@ async function request(method, path, opts = {}) {
134
134
  }
135
135
  if (res.status === 401) throw new ApiError(401, "AUTHENTICATION_ERROR", "Invalid API key. Run `solongate` and log in from the Accounts panel.");
136
136
  if (res.status === 429) throw new ApiError(429, "RATE_LIMITED", "Rate limited by the API. Slow down and retry.");
137
+ if (res.status >= 500) throw new ApiError(res.status, "SERVER_ERROR", text || "SolonGate API had a problem (server error). Please try again in a moment.");
137
138
  throw new ApiError(res.status, "ERROR", text || res.statusText || `HTTP ${res.status}`);
138
139
  }
139
140
  return json;
package/dist/index.js CHANGED
@@ -7274,6 +7274,7 @@ async function request(method, path, opts = {}) {
7274
7274
  }
7275
7275
  if (res.status === 401) throw new ApiError(401, "AUTHENTICATION_ERROR", "Invalid API key. Run `solongate` and log in from the Accounts panel.");
7276
7276
  if (res.status === 429) throw new ApiError(429, "RATE_LIMITED", "Rate limited by the API. Slow down and retry.");
7277
+ if (res.status >= 500) throw new ApiError(res.status, "SERVER_ERROR", text || "SolonGate API had a problem (server error). Please try again in a moment.");
7277
7278
  throw new ApiError(res.status, "ERROR", text || res.statusText || `HTTP ${res.status}`);
7278
7279
  }
7279
7280
  return json;
@@ -9109,7 +9110,7 @@ function RateLimitPanel({ focused }) {
9109
9110
  const [status, setStatus] = useState4(null);
9110
9111
  useEffect4(() => {
9111
9112
  if (layersQ.data && !dirty) setDraft({ ...layersQ.data.layers.rateLimit });
9112
- }, [layersQ.data, dirty]);
9113
+ }, [layersQ.data]);
9113
9114
  usePoll(() => {
9114
9115
  if (!dirty) layersQ.reloadQuiet();
9115
9116
  historyQ.reloadQuiet();
@@ -9131,6 +9132,7 @@ function RateLimitPanel({ focused }) {
9131
9132
  setDraft({ ...res.layers.rateLimit });
9132
9133
  setDirty(false);
9133
9134
  setStatus("\u2713 Saved");
9135
+ layersQ.reload();
9134
9136
  historyQ.reload();
9135
9137
  insightsQ.reload();
9136
9138
  } catch (e) {
@@ -9279,7 +9281,7 @@ function DlpPanel({ focused }) {
9279
9281
  setGhostOn(q.data.layers.ghost.mode === "on");
9280
9282
  setGhostPats([...q.data.layers.ghost.patterns]);
9281
9283
  }
9282
- }, [q.data, dirty]);
9284
+ }, [q.data]);
9283
9285
  usePoll(() => {
9284
9286
  if (!dirty && !adding) q.reloadQuiet();
9285
9287
  }, 6e3);
@@ -9299,6 +9301,7 @@ function DlpPanel({ focused }) {
9299
9301
  setGhostPats([...res.layers.ghost.patterns]);
9300
9302
  setDirty(false);
9301
9303
  setStatus("\u2713 Saved");
9304
+ q.reload();
9302
9305
  } catch (e) {
9303
9306
  setStatus("\u2717 " + (e instanceof Error ? e.message : String(e)));
9304
9307
  }
package/dist/tui/index.js CHANGED
@@ -504,6 +504,7 @@ async function request(method, path, opts = {}) {
504
504
  }
505
505
  if (res.status === 401) throw new ApiError(401, "AUTHENTICATION_ERROR", "Invalid API key. Run `solongate` and log in from the Accounts panel.");
506
506
  if (res.status === 429) throw new ApiError(429, "RATE_LIMITED", "Rate limited by the API. Slow down and retry.");
507
+ if (res.status >= 500) throw new ApiError(res.status, "SERVER_ERROR", text || "SolonGate API had a problem (server error). Please try again in a moment.");
507
508
  throw new ApiError(res.status, "ERROR", text || res.statusText || `HTTP ${res.status}`);
508
509
  }
509
510
  return json;
@@ -2202,7 +2203,7 @@ function RateLimitPanel({ focused }) {
2202
2203
  const [status, setStatus] = useState4(null);
2203
2204
  useEffect4(() => {
2204
2205
  if (layersQ.data && !dirty) setDraft({ ...layersQ.data.layers.rateLimit });
2205
- }, [layersQ.data, dirty]);
2206
+ }, [layersQ.data]);
2206
2207
  usePoll(() => {
2207
2208
  if (!dirty) layersQ.reloadQuiet();
2208
2209
  historyQ.reloadQuiet();
@@ -2224,6 +2225,7 @@ function RateLimitPanel({ focused }) {
2224
2225
  setDraft({ ...res.layers.rateLimit });
2225
2226
  setDirty(false);
2226
2227
  setStatus("\u2713 Saved");
2228
+ layersQ.reload();
2227
2229
  historyQ.reload();
2228
2230
  insightsQ.reload();
2229
2231
  } catch (e) {
@@ -2357,7 +2359,7 @@ function DlpPanel({ focused }) {
2357
2359
  setGhostOn(q.data.layers.ghost.mode === "on");
2358
2360
  setGhostPats([...q.data.layers.ghost.patterns]);
2359
2361
  }
2360
- }, [q.data, dirty]);
2362
+ }, [q.data]);
2361
2363
  usePoll(() => {
2362
2364
  if (!dirty && !adding) q.reloadQuiet();
2363
2365
  }, 6e3);
@@ -2377,6 +2379,7 @@ function DlpPanel({ focused }) {
2377
2379
  setGhostPats([...res.layers.ghost.patterns]);
2378
2380
  setDirty(false);
2379
2381
  setStatus("\u2713 Saved");
2382
+ q.reload();
2380
2383
  } catch (e) {
2381
2384
  setStatus("\u2717 " + (e instanceof Error ? e.message : String(e)));
2382
2385
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@solongate/proxy",
3
- "version": "0.81.90",
3
+ "version": "0.81.91",
4
4
  "description": "AI tool security proxy: protect any AI tool server with customizable policies, path/command constraints, rate limiting, and audit logging. No code changes required.",
5
5
  "type": "module",
6
6
  "bin": {