@settlemint/dalp-sdk 3.1.19-main.34874518496 → 3.1.19-main.34892927439

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.
@@ -1,5 +1,5 @@
1
1
  import type { DalpFetch } from "../client/ssr-fetch.ts";
2
- import type { AuthGetApiKeyListResponse, AuthGetOrganizationListResponse, AuthPostApiKeyCreateData, AuthPostApiKeyCreateResponse, AuthPostApiKeyDeleteData, AuthPostApiKeyDeleteResponse, AuthPostDeviceApproveData, AuthPostDeviceApproveResponse, AuthPostDeviceDenyData, AuthPostDeviceDenyResponse, AuthPostOrganizationAcceptInvitationData, AuthPostOrganizationAcceptInvitationResponse, AuthPostOrganizationCreateData, AuthPostOrganizationCreateResponse, AuthPostOrganizationRemoveMemberData, AuthPostOrganizationRemoveMemberResponse, AuthPostRevokeOtherSessionsResponse, AuthPostRevokeSessionData, AuthPostRevokeSessionResponse, AuthPostTwoFactorDisableData, AuthPostTwoFactorDisableResponse, AuthPostTwoFactorEnableData, AuthPostTwoFactorEnableResponse, AuthPostTwoFactorGenerateBackupCodesData, AuthPostTwoFactorGenerateBackupCodesResponse, AuthPostTwoFactorVerifyBackupCodeData, AuthPostTwoFactorVerifyBackupCodeResponse, AuthPostTwoFactorVerifyTotpData, AuthPostTwoFactorVerifyTotpResponse, CreateOrganizationInvitationData, CreateOrganizationInvitationResponse, GetSessionResponse, ListUserSessionsResponse, Member, SetActiveOrganizationData, SetActiveOrganizationResponse } from "../generated/api-types.d.ts";
2
+ import type { AuthGetApiKeyListResponse, AuthGetOrganizationListResponse, AuthPostApiKeyCreateData, AuthPostApiKeyCreateResponse, AuthPostApiKeyDeleteData, AuthPostApiKeyDeleteResponse, AuthPostOrganizationAcceptInvitationData, AuthPostOrganizationAcceptInvitationResponse, AuthPostOrganizationCreateData, AuthPostOrganizationCreateResponse, AuthPostOrganizationRemoveMemberData, AuthPostOrganizationRemoveMemberResponse, AuthPostRevokeOtherSessionsResponse, AuthPostRevokeSessionData, AuthPostRevokeSessionResponse, AuthPostTwoFactorDisableData, AuthPostTwoFactorDisableResponse, AuthPostTwoFactorEnableData, AuthPostTwoFactorEnableResponse, AuthPostTwoFactorVerifyBackupCodeData, AuthPostTwoFactorVerifyBackupCodeResponse, AuthPostTwoFactorVerifyTotpData, AuthPostTwoFactorVerifyTotpResponse, CreateOrganizationInvitationData, CreateOrganizationInvitationResponse, GetSessionResponse, ListUserSessionsResponse, Member, SetActiveOrganizationData, SetActiveOrganizationResponse } from "../generated/api-types.d.ts";
3
3
  import { Secret } from "../secret.ts";
4
4
  import type { CookieStoreShape } from "../transport/cookie-store.ts";
5
5
  export interface DalpAuthClientConfig {
@@ -103,11 +103,6 @@ export interface DalpCliAuthClient {
103
103
  readonly disable: DalpRequiredAuthOperation<RequestBody<AuthPostTwoFactorDisableData>, AuthPostTwoFactorDisableResponse>;
104
104
  readonly verifyTotp: DalpRequiredAuthOperation<RequestBody<AuthPostTwoFactorVerifyTotpData>, AuthPostTwoFactorVerifyTotpResponse>;
105
105
  readonly verifyBackupCode: DalpRequiredAuthOperation<RequestBody<AuthPostTwoFactorVerifyBackupCodeData>, AuthPostTwoFactorVerifyBackupCodeResponse>;
106
- readonly generateBackupCodes: DalpRequiredAuthOperation<RequestBody<AuthPostTwoFactorGenerateBackupCodesData>, AuthPostTwoFactorGenerateBackupCodesResponse>;
107
- };
108
- readonly device: {
109
- readonly approve: DalpRequiredAuthOperation<RequestBody<AuthPostDeviceApproveData>, AuthPostDeviceApproveResponse>;
110
- readonly deny: DalpRequiredAuthOperation<RequestBody<AuthPostDeviceDenyData>, AuthPostDeviceDenyResponse>;
111
106
  };
112
107
  }
113
108
  export declare function decodeDalpAuthClientConfig(input: DalpAuthClientConfig): Promise<DecodedDalpAuthClientConfig>;
@@ -50,8 +50,20 @@ type ConfiguredBetterAuthClientOptions = Omit<BetterAuthClientOptions, "plugins"
50
50
  plugins: ConfiguredBetterAuthPluginTuple;
51
51
  };
52
52
  export type InferredBetterAuthClient = AuthClient<ConfiguredBetterAuthClientOptions>;
53
+ /**
54
+ * Better Auth members whose routes the mount does not serve, or that are a
55
+ * browser page's step rather than an integrator call. Device approve and deny
56
+ * belong to the verification page, so a CLI keeps only the code and token
57
+ * exchange. Account deletion stays mounted for the signed-in user's
58
+ * email-gated flow, which an SDK caller never starts.
59
+ */
60
+ type UnservedAuthClientMembers = "deleteUser" | "revokeSessions" | "sendVerificationEmail";
61
+ interface DalpDeviceAuthClient {
62
+ readonly device: Omit<InferredBetterAuthClient["device"], "approve" | "deny">;
63
+ readonly passkey: Omit<InferredBetterAuthClient["passkey"], "updatePasskey">;
64
+ }
53
65
  /** Better Auth client with the exact DALP plugin surface and stable operation types. */
54
- export type DalpAuthClient = Omit<InferredBetterAuthClient, keyof DalpCliAuthClient | keyof DalpWalletAuthClient> & DalpCliAuthClient & DalpWalletAuthClient;
66
+ export type DalpAuthClient = Omit<InferredBetterAuthClient, keyof DalpCliAuthClient | keyof DalpWalletAuthClient | keyof DalpDeviceAuthClient | UnservedAuthClientMembers> & DalpDeviceAuthClient & DalpCliAuthClient & DalpWalletAuthClient;
55
67
  export declare function createDalpAuthClient(input: DalpAuthClientConfig): Promise<DalpAuthClient>;
56
68
  export declare const makeDalpAuthClient: typeof createDalpAuthClient;
57
69
  export {};
package/dist/auth.js CHANGED
@@ -10,7 +10,7 @@ import {
10
10
  makeCookieStore2,
11
11
  createCookieStoreFetch2,
12
12
  SDK_USER_AGENT2
13
- } from "./chunk-yhzqnnbj.js";
13
+ } from "./chunk-6n12yppr.js";
14
14
 
15
15
  // src/auth/live.ts
16
16
  import { apiKeyClient } from "@better-auth/api-key/client";
package/dist/bundler.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import"./chunk-h0z2r2hv.js";
2
2
  import"./chunk-j4sxrfzz.js";
3
- import"./chunk-shp8v4ws.js";
3
+ import"./chunk-tmyd93kk.js";
4
4
  import"./chunk-xp3fx2yt.js";
5
5
  import {
6
6
  createDalpClient2
7
- } from "./chunk-qqhrt2cm.js";
8
- import"./chunk-79av07h6.js";
7
+ } from "./chunk-xp7b97rw.js";
8
+ import"./chunk-7y52nnrf.js";
9
9
 
10
10
  // src/bundler.ts
11
11
  import { getAddress, hexToBigInt, isHex } from "viem";
@@ -102,7 +102,7 @@ function createCookieStoreFetch2(cookieStore, fetchImpl = globalThis.fetch) {
102
102
  // package.json
103
103
  var package_default = {
104
104
  name: "@settlemint/dalp-sdk",
105
- version: "3.1.19-main.34874518496",
105
+ version: "3.1.19-main.34892927439",
106
106
  private: false,
107
107
  description: "Fully typed SDK for the DALP tokenization platform API",
108
108
  homepage: "https://settlemint.com",
@@ -4,7 +4,7 @@ import {
4
4
  sendRequest,
5
5
  createFetchExecutor,
6
6
  createTanstackFactories
7
- } from "./chunk-shp8v4ws.js";
7
+ } from "./chunk-tmyd93kk.js";
8
8
  import {
9
9
  buildProxy,
10
10
  findRoute
@@ -390,7 +390,6 @@ var CONDITIONAL_RESPONSE_MAX_BODY_BYTES = 1048576;
390
390
  var IDENTITY_RESET_PATH_SUFFIXES = [
391
391
  "/api/auth/sign-out",
392
392
  "/api/auth/revoke-session",
393
- "/api/auth/revoke-sessions",
394
393
  "/api/auth/revoke-other-sessions",
395
394
  "/api/auth/organization/set-active"
396
395
  ];
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-h0z2r2hv.js";
4
4
  import {
5
5
  buildDalpClient
6
- } from "./chunk-79av07h6.js";
6
+ } from "./chunk-7y52nnrf.js";
7
7
 
8
8
  // src/proxy/client.ts
9
9
  function createDalpClient2(options) {
package/dist/effect.js CHANGED
@@ -8,7 +8,7 @@ import {
8
8
  streamRequest,
9
9
  sendRequest,
10
10
  queryKeyFor2
11
- } from "./chunk-shp8v4ws.js";
11
+ } from "./chunk-tmyd93kk.js";
12
12
  import"./chunk-xp3fx2yt.js";
13
13
  import {
14
14
  buildProxy,
@@ -51788,15 +51788,6 @@ export type AuthPostPasskeyDeletePasskeyResponse = {
51788
51788
  readonly status: boolean;
51789
51789
  };
51790
51790
 
51791
- export type AuthPostPasskeyUpdatePasskeyData = {
51792
- readonly id: string;
51793
- readonly name: string;
51794
- };
51795
-
51796
- export type AuthPostPasskeyUpdatePasskeyResponse = {
51797
- readonly passkey: Passkey;
51798
- };
51799
-
51800
51791
  export type AuthPostRevokeOtherSessionsData = Readonly<Record<string, unknown>>;
51801
51792
 
51802
51793
  export type AuthPostRevokeOtherSessionsResponse = {
@@ -51811,12 +51802,6 @@ export type AuthPostRevokeSessionResponse = {
51811
51802
  readonly status: boolean;
51812
51803
  };
51813
51804
 
51814
- export type AuthPostRevokeSessionsData = Readonly<Record<string, unknown>>;
51815
-
51816
- export type AuthPostRevokeSessionsResponse = {
51817
- readonly status: boolean;
51818
- };
51819
-
51820
51805
  export type AuthPostTwoFactorDisableData = {
51821
51806
  readonly password: string;
51822
51807
  };
@@ -51835,31 +51820,6 @@ export type AuthPostTwoFactorEnableResponse = {
51835
51820
  readonly backupCodes?: ReadonlyArray<string>;
51836
51821
  };
51837
51822
 
51838
- export type AuthPostTwoFactorGenerateBackupCodesData = {
51839
- readonly password: string;
51840
- };
51841
-
51842
- export type AuthPostTwoFactorGenerateBackupCodesResponse = {
51843
- readonly status: true;
51844
- readonly backupCodes: ReadonlyArray<string>;
51845
- };
51846
-
51847
- export type AuthPostTwoFactorGetTotpUriData = {
51848
- readonly password: string;
51849
- };
51850
-
51851
- export type AuthPostTwoFactorGetTotpUriResponse = {
51852
- readonly totpURI?: string;
51853
- };
51854
-
51855
- export type AuthPostTwoFactorSendOtpData = {
51856
- readonly trustDevice?: boolean;
51857
- };
51858
-
51859
- export type AuthPostTwoFactorSendOtpResponse = {
51860
- readonly status?: boolean;
51861
- };
51862
-
51863
51823
  export type AuthPostTwoFactorVerifyBackupCodeData = {
51864
51824
  readonly code: string;
51865
51825
  readonly disableSession?: boolean;
@@ -51885,24 +51845,6 @@ export type AuthPostTwoFactorVerifyBackupCodeResponse = {
51885
51845
  };
51886
51846
  };
51887
51847
 
51888
- export type AuthPostTwoFactorVerifyOtpData = {
51889
- readonly code: string;
51890
- readonly trustDevice?: boolean;
51891
- };
51892
-
51893
- export type AuthPostTwoFactorVerifyOtpResponse = {
51894
- readonly token: string;
51895
- readonly user: {
51896
- readonly id: string;
51897
- readonly email?: string;
51898
- readonly emailVerified?: boolean;
51899
- readonly name?: string;
51900
- readonly image?: string;
51901
- readonly createdAt: string;
51902
- readonly updatedAt: string;
51903
- };
51904
- };
51905
-
51906
51848
  export type AuthPostTwoFactorVerifyTotpData = {
51907
51849
  readonly code: string;
51908
51850
  readonly trustDevice?: boolean;
@@ -52258,15 +52200,6 @@ export type RevokeUserSessionsResponse = {
52258
52200
  readonly success?: boolean;
52259
52201
  };
52260
52202
 
52261
- export type SendVerificationEmailData = {
52262
- readonly email: string;
52263
- readonly callbackURL?: string;
52264
- };
52265
-
52266
- export type SendVerificationEmailResponse = {
52267
- readonly status?: boolean;
52268
- };
52269
-
52270
52203
  export type SetActiveOrganizationData = {
52271
52204
  readonly organizationId?: string | null;
52272
52205
  readonly organizationSlug?: string;
package/dist/index.js CHANGED
@@ -12,7 +12,7 @@ import {
12
12
  RESERVED_STREAM_FAILURE_EVENT2,
13
13
  STREAM_FAILED_ERROR_CODE2,
14
14
  decodeEventStream2
15
- } from "./chunk-shp8v4ws.js";
15
+ } from "./chunk-tmyd93kk.js";
16
16
  import {
17
17
  SECRET_REDACTION_MARKER2,
18
18
  Secret2,
@@ -23,14 +23,14 @@ import {
23
23
  createCookieStoreFetch2,
24
24
  SDK_VERSION2,
25
25
  SDK_USER_AGENT2
26
- } from "./chunk-yhzqnnbj.js";
26
+ } from "./chunk-6n12yppr.js";
27
27
  import {
28
28
  createDalpClient2
29
- } from "./chunk-qqhrt2cm.js";
29
+ } from "./chunk-xp7b97rw.js";
30
30
  import {
31
31
  readsAsIndexerRebuild2
32
32
  } from "./chunk-sk9nc2q3.js";
33
- import"./chunk-79av07h6.js";
33
+ import"./chunk-7y52nnrf.js";
34
34
  // src/transport/sse-lifecycle.ts
35
35
  class SseLifecycleError extends Error {
36
36
  reason;
@@ -3,7 +3,7 @@ import {
3
3
  canonicalize2,
4
4
  queryKeyFor2,
5
5
  UI_SETTLEMENT_TIMEOUT_MS2
6
- } from "./chunk-shp8v4ws.js";
6
+ } from "./chunk-tmyd93kk.js";
7
7
  import"./chunk-xp3fx2yt.js";
8
8
  export {
9
9
  UI_SETTLEMENT_TIMEOUT_MS2 as UI_SETTLEMENT_TIMEOUT_MS,