@protobase/client 0.55.3 → 0.55.4

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/problem.d.ts CHANGED
@@ -30,6 +30,10 @@ export type ProblemDetails = {
30
30
  resource: string;
31
31
  field?: string;
32
32
  };
33
+ /** For a create refused by a resource's `.openExisting()` unique key: the key of the record holding those values, when the caller may read it. */
34
+ existing?: {
35
+ key: string;
36
+ };
33
37
  /** For `strong-sign-in-required`: how many minutes old the strong sign-in may be. */
34
38
  minutes?: number;
35
39
  };
@@ -47,6 +51,10 @@ export declare class ApiError extends Error {
47
51
  resource: string;
48
52
  field?: string;
49
53
  } | undefined;
54
+ /** For a create refused by a resource's `.openExisting()` unique key: the record holding those values, when the caller may read it. */
55
+ get existing(): {
56
+ key: string;
57
+ } | undefined;
50
58
  get errors(): ProblemError[];
51
59
  /** Filter errors carry the span of the offending text, so the UI can underline it. */
52
60
  get filterErrors(): ProblemError[];
package/dist/problem.js CHANGED
@@ -22,6 +22,10 @@ var ApiError = class extends Error {
22
22
  get blockedBy() {
23
23
  return this.problem.blockedBy;
24
24
  }
25
+ /** For a create refused by a resource's `.openExisting()` unique key: the record holding those values, when the caller may read it. */
26
+ get existing() {
27
+ return this.problem.existing;
28
+ }
25
29
  get errors() {
26
30
  return this.problem.errors ?? [];
27
31
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@protobase/client",
3
- "version": "0.55.3",
3
+ "version": "0.55.4",
4
4
  "description": "Typed fetch client for the Protobase REST API.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -30,8 +30,8 @@
30
30
  },
31
31
  "dependencies": {
32
32
  "@better-auth/passkey": "^1.7.12",
33
- "@protobase/layout": "0.55.3",
34
- "@protobase/schema": "0.55.3",
33
+ "@protobase/layout": "0.55.4",
34
+ "@protobase/schema": "0.55.4",
35
35
  "@simplewebauthn/browser": "^13.3.0",
36
36
  "better-auth": "^1.7.12"
37
37
  }