@krak-stack/auth 0.1.45 → 0.1.46

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.
@@ -143,19 +143,19 @@ export declare const AdminApiGroup: HttpApiGroup.HttpApiGroup<"admin", HttpApiEn
143
143
  }>>, Schema.String, never, never>, never, never>>;
144
144
  readonly projectId: Schema.optional<Schema.String>;
145
145
  }>>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.StringTree<never>, HttpApiEndpoint.Json<Schema.Struct<{
146
- readonly data: Schema.$Array<Schema.Schema<{
147
- readonly id: string;
148
- readonly name: string;
149
- readonly email: string;
150
- readonly emailVerified: boolean;
151
- readonly image: string | null;
152
- readonly createdAt: Date;
153
- readonly lastSignedIn: Date | null;
154
- readonly role: string | null;
155
- readonly banned: boolean | null;
156
- readonly banReason: string | null;
157
- readonly banExpires: Date | null;
158
- }>>;
146
+ readonly data: Schema.$Array<Schema.Schema<Schema.Struct.ReadonlySide<{
147
+ readonly id: Schema.String;
148
+ readonly name: Schema.String;
149
+ readonly email: Schema.String;
150
+ readonly emailVerified: Schema.Boolean;
151
+ readonly image: Schema.NullOr<Schema.String>;
152
+ readonly createdAt: Schema.Date;
153
+ readonly lastSignedIn: Schema.NullOr<Schema.Date>;
154
+ readonly role: Schema.NullOr<Schema.String>;
155
+ readonly banned: Schema.NullOr<Schema.Boolean>;
156
+ readonly banReason: Schema.NullOr<Schema.String>;
157
+ readonly banExpires: Schema.NullOr<Schema.Date>;
158
+ }, "Type">>>;
159
159
  readonly meta: Schema.Struct<{
160
160
  readonly page: Schema.Int;
161
161
  readonly pageSize: Schema.Int;
@@ -86,19 +86,19 @@ export declare const DashboardStatsResponse: Schema.Struct<{
86
86
  }>>;
87
87
  }>;
88
88
  export declare const PaginatedAdminUsers: Schema.Struct<{
89
- readonly data: Schema.$Array<Schema.Schema<{
90
- readonly id: string;
91
- readonly name: string;
92
- readonly email: string;
93
- readonly emailVerified: boolean;
94
- readonly image: string | null;
95
- readonly createdAt: Date;
96
- readonly lastSignedIn: Date | null;
97
- readonly role: string | null;
98
- readonly banned: boolean | null;
99
- readonly banReason: string | null;
100
- readonly banExpires: Date | null;
101
- }>>;
89
+ readonly data: Schema.$Array<Schema.Schema<Schema.Struct.ReadonlySide<{
90
+ readonly id: Schema.String;
91
+ readonly name: Schema.String;
92
+ readonly email: Schema.String;
93
+ readonly emailVerified: Schema.Boolean;
94
+ readonly image: Schema.NullOr<Schema.String>;
95
+ readonly createdAt: Schema.Date;
96
+ readonly lastSignedIn: Schema.NullOr<Schema.Date>;
97
+ readonly role: Schema.NullOr<Schema.String>;
98
+ readonly banned: Schema.NullOr<Schema.Boolean>;
99
+ readonly banReason: Schema.NullOr<Schema.String>;
100
+ readonly banExpires: Schema.NullOr<Schema.Date>;
101
+ }, "Type">>>;
102
102
  readonly meta: Schema.Struct<{
103
103
  readonly page: Schema.Int;
104
104
  readonly pageSize: Schema.Int;
package/dist/api.d.ts CHANGED
@@ -56,7 +56,7 @@ export declare const AuthServiceApi: HttpApi.HttpApi<"AuthServiceApi", import("e
56
56
  readonly createdAt: import("effect/Schema").Date;
57
57
  readonly updatedAt: import("effect/Schema").Date;
58
58
  }>;
59
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
59
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
60
60
  readonly configId: import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>;
61
61
  readonly name: import("effect/Schema").optional<import("effect/Schema").NonEmptyString>;
62
62
  readonly organizationId: import("effect/Schema").optional<import("effect/Schema").String>;
@@ -64,7 +64,7 @@ export declare const AuthServiceApi: HttpApi.HttpApi<"AuthServiceApi", import("e
64
64
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
65
65
  readonly id: import("effect/Schema").String;
66
66
  readonly key: import("effect/Schema").String;
67
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
67
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
68
68
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
69
69
  readonly clientId: import("effect/Schema").optional<import("effect/Schema").String>;
70
70
  readonly host: import("effect/Schema").optional<import("effect/Schema").String>;
@@ -87,11 +87,11 @@ export declare const AuthServiceApi: HttpApi.HttpApi<"AuthServiceApi", import("e
87
87
  readonly newPassword: import("effect/Schema").NonEmptyString;
88
88
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
89
89
  readonly ok: import("effect/Schema").Boolean;
90
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
90
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
91
91
  readonly file: import("effect/Schema").decodeTo<import("effect/unstable/http/Multipart").PersistedFileSchema, import("effect/Schema").$Array<import("effect/unstable/http/Multipart").PersistedFileSchema>, never, never>;
92
92
  }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
93
93
  readonly url: import("effect/Schema").String;
94
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
94
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
95
95
  readonly key: import("effect/Schema").NonEmptyString;
96
96
  readonly configId: import("effect/Schema").optional<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>>;
97
97
  readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
@@ -119,7 +119,7 @@ export declare const AuthServiceApi: HttpApi.HttpApi<"AuthServiceApi", import("e
119
119
  readonly password: import("effect/Schema").NonEmptyString;
120
120
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
121
121
  readonly ok: import("effect/Schema").Boolean;
122
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"domains", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createDomain", "POST", "/api/domains", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
122
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"domains", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createDomain", "POST", "/api/domains", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
123
123
  readonly hostname: import("effect/Schema").NonEmptyString;
124
124
  readonly rootHostname: import("effect/Schema").NonEmptyString;
125
125
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
@@ -456,19 +456,19 @@ export declare const AuthClientApi: HttpApi.HttpApi<"AuthClientApi", import("eff
456
456
  }>>, import("effect/Schema").String, never, never>, never, never>>;
457
457
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
458
458
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
459
- readonly data: import("effect/Schema").$Array<import("effect/Schema").Schema<{
460
- readonly id: string;
461
- readonly name: string;
462
- readonly email: string;
463
- readonly emailVerified: boolean;
464
- readonly image: string | null;
465
- readonly createdAt: Date;
466
- readonly lastSignedIn: Date | null;
467
- readonly role: string | null;
468
- readonly banned: boolean | null;
469
- readonly banReason: string | null;
470
- readonly banExpires: Date | null;
471
- }>>;
459
+ readonly data: import("effect/Schema").$Array<import("effect/Schema").Schema<import("effect/Schema").Struct.ReadonlySide<{
460
+ readonly id: import("effect/Schema").String;
461
+ readonly name: import("effect/Schema").String;
462
+ readonly email: import("effect/Schema").String;
463
+ readonly emailVerified: import("effect/Schema").Boolean;
464
+ readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
465
+ readonly createdAt: import("effect/Schema").Date;
466
+ readonly lastSignedIn: import("effect/Schema").NullOr<import("effect/Schema").Date>;
467
+ readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
468
+ readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
469
+ readonly banReason: import("effect/Schema").NullOr<import("effect/Schema").String>;
470
+ readonly banExpires: import("effect/Schema").NullOr<import("effect/Schema").Date>;
471
+ }, "Type">>>;
472
472
  readonly meta: import("effect/Schema").Struct<{
473
473
  readonly page: import("effect/Schema").Int;
474
474
  readonly pageSize: import("effect/Schema").Int;
@@ -569,7 +569,7 @@ export declare const AuthClientApi: HttpApi.HttpApi<"AuthClientApi", import("eff
569
569
  readonly createdAt: import("effect/Schema").Date;
570
570
  readonly updatedAt: import("effect/Schema").Date;
571
571
  }>;
572
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
572
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
573
573
  readonly configId: import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>;
574
574
  readonly name: import("effect/Schema").optional<import("effect/Schema").NonEmptyString>;
575
575
  readonly organizationId: import("effect/Schema").optional<import("effect/Schema").String>;
@@ -577,7 +577,7 @@ export declare const AuthClientApi: HttpApi.HttpApi<"AuthClientApi", import("eff
577
577
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
578
578
  readonly id: import("effect/Schema").String;
579
579
  readonly key: import("effect/Schema").String;
580
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
580
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
581
581
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
582
582
  readonly clientId: import("effect/Schema").optional<import("effect/Schema").String>;
583
583
  readonly host: import("effect/Schema").optional<import("effect/Schema").String>;
@@ -600,11 +600,11 @@ export declare const AuthClientApi: HttpApi.HttpApi<"AuthClientApi", import("eff
600
600
  readonly newPassword: import("effect/Schema").NonEmptyString;
601
601
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
602
602
  readonly ok: import("effect/Schema").Boolean;
603
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
603
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
604
604
  readonly file: import("effect/Schema").decodeTo<import("effect/unstable/http/Multipart").PersistedFileSchema, import("effect/Schema").$Array<import("effect/unstable/http/Multipart").PersistedFileSchema>, never, never>;
605
605
  }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
606
606
  readonly url: import("effect/Schema").String;
607
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
607
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
608
608
  readonly key: import("effect/Schema").NonEmptyString;
609
609
  readonly configId: import("effect/Schema").optional<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>>;
610
610
  readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
@@ -632,4 +632,4 @@ export declare const AuthClientApi: HttpApi.HttpApi<"AuthClientApi", import("eff
632
632
  readonly password: import("effect/Schema").NonEmptyString;
633
633
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
634
634
  readonly ok: import("effect/Schema").Boolean;
635
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("./extra/schema").ExtraBadRequest>, never, never>, false>>;
635
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("./extra/schema").ExtraBadRequest>, never, never>, false>>;
@@ -59,4 +59,4 @@ export declare const BetterAuthApiGroup: HttpApiGroup.HttpApiGroup<"auth", HttpA
59
59
  readonly createdAt: import("effect/Schema").Date;
60
60
  readonly updatedAt: import("effect/Schema").Date;
61
61
  }>;
62
- }>>, HttpApiEndpoint.Json<typeof HttpApiError.BadRequest | typeof HttpApiError.Unauthorized | typeof HttpApiError.NotFound | typeof HttpApiError.InternalServerError>, never, never>, false>;
62
+ }>>, HttpApiEndpoint.Json<typeof HttpApiError.BadRequest | typeof HttpApiError.Unauthorized | typeof HttpApiError.Forbidden | typeof HttpApiError.NotFound | typeof HttpApiError.InternalServerError>, never, never>, false>;
@@ -24,6 +24,7 @@ export const BetterAuthApiGroup = HttpApiGroup.make("auth")
24
24
  error: [
25
25
  HttpApiError.BadRequest,
26
26
  HttpApiError.Unauthorized,
27
+ HttpApiError.Forbidden,
27
28
  HttpApiError.NotFound,
28
29
  HttpApiError.InternalServerError,
29
30
  ],
@@ -1,125 +1,5 @@
1
1
  import { AtomHttpApi } from "effect/unstable/reactivity";
2
- export declare const authClientApi: (baseUrl?: string | undefined) => AtomHttpApi.AtomHttpApiClient<object, `AuthClientApi:${string}`, import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"auth", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getSession", "GET", "/api/auth/get-session", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").NullOr<import("effect/Schema").Struct<{
3
- readonly session: import("effect/Schema").Struct<{
4
- readonly id: import("effect/Schema").String;
5
- readonly expiresAt: import("effect/Schema").Date;
6
- readonly token: import("effect/Schema").String;
7
- readonly createdAt: import("effect/Schema").Date;
8
- readonly updatedAt: import("effect/Schema").Date;
9
- readonly ipAddress: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
10
- readonly userAgent: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
11
- readonly userId: import("effect/Schema").String;
12
- readonly impersonatedBy: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
13
- readonly impersonatedByOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
14
- readonly activeOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
15
- }>;
16
- readonly user: import("effect/Schema").Struct<{
17
- readonly id: import("effect/Schema").String;
18
- readonly name: import("effect/Schema").String;
19
- readonly email: import("effect/Schema").String;
20
- readonly emailVerified: import("effect/Schema").Boolean;
21
- readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
22
- readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
23
- readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
24
- readonly lastLoginMethod: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
25
- readonly createdAt: import("effect/Schema").Date;
26
- readonly updatedAt: import("effect/Schema").Date;
27
- }>;
28
- }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../better-auth/schema").TooManyRequests>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"organizationImpersonateUser", "POST", "/api/auth/organization/impersonate-user", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
29
- readonly organizationId: import("effect/Schema").NonEmptyString;
30
- readonly actorUserId: import("effect/Schema").NonEmptyString;
31
- readonly targetUserId: import("effect/Schema").NonEmptyString;
32
- readonly expiresInSeconds: import("effect/Schema").optional<import("effect/Schema").Number>;
33
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
34
- readonly session: import("effect/Schema").Struct<{
35
- readonly id: import("effect/Schema").String;
36
- readonly expiresAt: import("effect/Schema").Date;
37
- readonly token: import("effect/Schema").String;
38
- readonly createdAt: import("effect/Schema").Date;
39
- readonly updatedAt: import("effect/Schema").Date;
40
- readonly ipAddress: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
41
- readonly userAgent: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
42
- readonly userId: import("effect/Schema").String;
43
- readonly impersonatedBy: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
44
- readonly impersonatedByOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
45
- readonly activeOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
46
- }>;
47
- readonly user: import("effect/Schema").Struct<{
48
- readonly id: import("effect/Schema").String;
49
- readonly name: import("effect/Schema").String;
50
- readonly email: import("effect/Schema").String;
51
- readonly emailVerified: import("effect/Schema").Boolean;
52
- readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
53
- readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
54
- readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
55
- readonly lastLoginMethod: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
56
- readonly createdAt: import("effect/Schema").Date;
57
- readonly updatedAt: import("effect/Schema").Date;
58
- }>;
59
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
60
- readonly configId: import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>;
61
- readonly name: import("effect/Schema").optional<import("effect/Schema").NonEmptyString>;
62
- readonly organizationId: import("effect/Schema").optional<import("effect/Schema").String>;
63
- readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
64
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
65
- readonly id: import("effect/Schema").String;
66
- readonly key: import("effect/Schema").String;
67
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
68
- readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
69
- readonly clientId: import("effect/Schema").optional<import("effect/Schema").String>;
70
- readonly host: import("effect/Schema").optional<import("effect/Schema").String>;
71
- readonly rootHost: import("effect/Schema").optional<import("effect/Schema").String>;
72
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
73
- readonly projectKey: import("effect/Schema").String;
74
- readonly name: import("effect/Schema").NullOr<import("effect/Schema").String>;
75
- readonly logoUrl: import("effect/Schema").NullOr<import("effect/Schema").String>;
76
- readonly authDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
77
- readonly rootDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
78
- readonly themeCss: import("effect/Schema").NullOr<import("effect/Schema").String>;
79
- readonly authOptions: import("effect/Schema").Struct<{
80
- readonly emailPassword: import("effect/Schema").Boolean;
81
- readonly emailOtp: import("effect/Schema").Boolean;
82
- readonly google: import("effect/Schema").Boolean;
83
- readonly signUp: import("effect/Schema").Boolean;
84
- readonly signUpName: import("effect/Schema").Boolean;
85
- }>;
86
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"setPassword", "POST", "/api/auth/set-password", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
87
- readonly newPassword: import("effect/Schema").NonEmptyString;
88
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
89
- readonly ok: import("effect/Schema").Boolean;
90
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
91
- readonly file: import("effect/Schema").decodeTo<import("effect/unstable/http/Multipart").PersistedFileSchema, import("effect/Schema").$Array<import("effect/unstable/http/Multipart").PersistedFileSchema>, never, never>;
92
- }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
93
- readonly url: import("effect/Schema").String;
94
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
95
- readonly key: import("effect/Schema").NonEmptyString;
96
- readonly configId: import("effect/Schema").optional<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>>;
97
- readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
98
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
99
- readonly valid: import("effect/Schema").Boolean;
100
- readonly error: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
101
- readonly message: import("effect/Schema").String;
102
- readonly code: import("effect/Schema").String;
103
- }>>;
104
- readonly key: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
105
- readonly id: import("effect/Schema").String;
106
- readonly configId: import("effect/Schema").String;
107
- readonly name: import("effect/Schema").NullOr<import("effect/Schema").String>;
108
- readonly start: import("effect/Schema").NullOr<import("effect/Schema").String>;
109
- readonly prefix: import("effect/Schema").NullOr<import("effect/Schema").String>;
110
- readonly referenceId: import("effect/Schema").String;
111
- readonly enabled: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
112
- readonly expiresAt: import("effect/Schema").NullOr<import("effect/Schema").Date>;
113
- readonly createdAt: import("effect/Schema").Date;
114
- readonly updatedAt: import("effect/Schema").Date;
115
- readonly permissions: import("effect/Schema").NullOr<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
116
- readonly metadata: import("effect/Schema").NullOr<import("effect/Schema").Unknown>;
117
- }>>;
118
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyPassword", "POST", "/api/auth/verify-password", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
119
- readonly password: import("effect/Schema").NonEmptyString;
120
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
121
- readonly ok: import("effect/Schema").Boolean;
122
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("../extra/schema").ExtraBadRequest>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"admin", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createDomain", "POST", "/api/auth/admin/domains", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
2
+ export declare const authClientApi: (baseUrl?: string | undefined) => AtomHttpApi.AtomHttpApiClient<object, `AuthClientApi:${string}`, import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"admin", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createDomain", "POST", "/api/auth/admin/domains", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
123
3
  readonly hostname: import("effect/Schema").NonEmptyString;
124
4
  readonly rootHostname: import("effect/Schema").NonEmptyString;
125
5
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
@@ -261,19 +141,19 @@ export declare const authClientApi: (baseUrl?: string | undefined) => AtomHttpAp
261
141
  }>>, import("effect/Schema").String, never, never>, never, never>>;
262
142
  readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
263
143
  }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
264
- readonly data: import("effect/Schema").$Array<import("effect/Schema").Schema<{
265
- readonly id: string;
266
- readonly name: string;
267
- readonly email: string;
268
- readonly emailVerified: boolean;
269
- readonly image: string | null;
270
- readonly createdAt: Date;
271
- readonly lastSignedIn: Date | null;
272
- readonly role: string | null;
273
- readonly banned: boolean | null;
274
- readonly banReason: string | null;
275
- readonly banExpires: Date | null;
276
- }>>;
144
+ readonly data: import("effect/Schema").$Array<import("effect/Schema").Schema<import("effect/Schema").Struct.ReadonlySide<{
145
+ readonly id: import("effect/Schema").String;
146
+ readonly name: import("effect/Schema").String;
147
+ readonly email: import("effect/Schema").String;
148
+ readonly emailVerified: import("effect/Schema").Boolean;
149
+ readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
150
+ readonly createdAt: import("effect/Schema").Date;
151
+ readonly lastSignedIn: import("effect/Schema").NullOr<import("effect/Schema").Date>;
152
+ readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
153
+ readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
154
+ readonly banReason: import("effect/Schema").NullOr<import("effect/Schema").String>;
155
+ readonly banExpires: import("effect/Schema").NullOr<import("effect/Schema").Date>;
156
+ }, "Type">>>;
277
157
  readonly meta: import("effect/Schema").Struct<{
278
158
  readonly page: import("effect/Schema").Int;
279
159
  readonly pageSize: import("effect/Schema").Int;
@@ -317,4 +197,124 @@ export declare const authClientApi: (baseUrl?: string | undefined) => AtomHttpAp
317
197
  readonly metadata: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
318
198
  readonly memberCount: import("effect/Schema").optional<import("effect/Schema").Number>;
319
199
  readonly createdAt: import("effect/Schema").Date;
320
- }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false>>;
200
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"auth", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getSession", "GET", "/api/auth/get-session", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").NullOr<import("effect/Schema").Struct<{
201
+ readonly session: import("effect/Schema").Struct<{
202
+ readonly id: import("effect/Schema").String;
203
+ readonly expiresAt: import("effect/Schema").Date;
204
+ readonly token: import("effect/Schema").String;
205
+ readonly createdAt: import("effect/Schema").Date;
206
+ readonly updatedAt: import("effect/Schema").Date;
207
+ readonly ipAddress: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
208
+ readonly userAgent: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
209
+ readonly userId: import("effect/Schema").String;
210
+ readonly impersonatedBy: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
211
+ readonly impersonatedByOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
212
+ readonly activeOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
213
+ }>;
214
+ readonly user: import("effect/Schema").Struct<{
215
+ readonly id: import("effect/Schema").String;
216
+ readonly name: import("effect/Schema").String;
217
+ readonly email: import("effect/Schema").String;
218
+ readonly emailVerified: import("effect/Schema").Boolean;
219
+ readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
220
+ readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
221
+ readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
222
+ readonly lastLoginMethod: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
223
+ readonly createdAt: import("effect/Schema").Date;
224
+ readonly updatedAt: import("effect/Schema").Date;
225
+ }>;
226
+ }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../better-auth/schema").TooManyRequests>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"organizationImpersonateUser", "POST", "/api/auth/organization/impersonate-user", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
227
+ readonly organizationId: import("effect/Schema").NonEmptyString;
228
+ readonly actorUserId: import("effect/Schema").NonEmptyString;
229
+ readonly targetUserId: import("effect/Schema").NonEmptyString;
230
+ readonly expiresInSeconds: import("effect/Schema").optional<import("effect/Schema").Number>;
231
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
232
+ readonly session: import("effect/Schema").Struct<{
233
+ readonly id: import("effect/Schema").String;
234
+ readonly expiresAt: import("effect/Schema").Date;
235
+ readonly token: import("effect/Schema").String;
236
+ readonly createdAt: import("effect/Schema").Date;
237
+ readonly updatedAt: import("effect/Schema").Date;
238
+ readonly ipAddress: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
239
+ readonly userAgent: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
240
+ readonly userId: import("effect/Schema").String;
241
+ readonly impersonatedBy: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
242
+ readonly impersonatedByOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
243
+ readonly activeOrganizationId: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
244
+ }>;
245
+ readonly user: import("effect/Schema").Struct<{
246
+ readonly id: import("effect/Schema").String;
247
+ readonly name: import("effect/Schema").String;
248
+ readonly email: import("effect/Schema").String;
249
+ readonly emailVerified: import("effect/Schema").Boolean;
250
+ readonly image: import("effect/Schema").NullOr<import("effect/Schema").String>;
251
+ readonly role: import("effect/Schema").NullOr<import("effect/Schema").String>;
252
+ readonly banned: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
253
+ readonly lastLoginMethod: import("effect/Schema").optional<import("effect/Schema").NullOr<import("effect/Schema").String>>;
254
+ readonly createdAt: import("effect/Schema").Date;
255
+ readonly updatedAt: import("effect/Schema").Date;
256
+ }>;
257
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").BadRequest | typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").NotFound | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never>, false> | import("effect/unstable/httpapi/HttpApiGroup").HttpApiGroup<"authExtra", import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"createApiKey", "POST", "/api/auth/create-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
258
+ readonly configId: import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>;
259
+ readonly name: import("effect/Schema").optional<import("effect/Schema").NonEmptyString>;
260
+ readonly organizationId: import("effect/Schema").optional<import("effect/Schema").String>;
261
+ readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
262
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
263
+ readonly id: import("effect/Schema").String;
264
+ readonly key: import("effect/Schema").String;
265
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"getProjectPublicConfig", "GET", "/api/auth/project-config", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<import("effect/Schema").Struct<{
266
+ readonly projectId: import("effect/Schema").optional<import("effect/Schema").String>;
267
+ readonly clientId: import("effect/Schema").optional<import("effect/Schema").String>;
268
+ readonly host: import("effect/Schema").optional<import("effect/Schema").String>;
269
+ readonly rootHost: import("effect/Schema").optional<import("effect/Schema").String>;
270
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
271
+ readonly projectKey: import("effect/Schema").String;
272
+ readonly name: import("effect/Schema").NullOr<import("effect/Schema").String>;
273
+ readonly logoUrl: import("effect/Schema").NullOr<import("effect/Schema").String>;
274
+ readonly authDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
275
+ readonly rootDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
276
+ readonly themeCss: import("effect/Schema").NullOr<import("effect/Schema").String>;
277
+ readonly authOptions: import("effect/Schema").Struct<{
278
+ readonly emailPassword: import("effect/Schema").Boolean;
279
+ readonly emailOtp: import("effect/Schema").Boolean;
280
+ readonly google: import("effect/Schema").Boolean;
281
+ readonly signUp: import("effect/Schema").Boolean;
282
+ readonly signUpName: import("effect/Schema").Boolean;
283
+ }>;
284
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"setPassword", "POST", "/api/auth/set-password", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
285
+ readonly newPassword: import("effect/Schema").NonEmptyString;
286
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
287
+ readonly ok: import("effect/Schema").Boolean;
288
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"uploadUserImage", "POST", "/api/auth/image/upload", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/unstable/httpapi/HttpApiSchema").asMultipartStream<import("effect/Schema").Struct<{
289
+ readonly file: import("effect/Schema").decodeTo<import("effect/unstable/http/Multipart").PersistedFileSchema, import("effect/Schema").$Array<import("effect/unstable/http/Multipart").PersistedFileSchema>, never, never>;
290
+ }>>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
291
+ readonly url: import("effect/Schema").String;
292
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyApiKey", "POST", "/api/auth/verify-api-key", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
293
+ readonly key: import("effect/Schema").NonEmptyString;
294
+ readonly configId: import("effect/Schema").optional<import("effect/Schema").Union<readonly [import("effect/Schema").Literal<"user">, import("effect/Schema").Literal<"organization">, import("effect/Schema").Literal<"service">]>>;
295
+ readonly permissions: import("effect/Schema").optional<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
296
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
297
+ readonly valid: import("effect/Schema").Boolean;
298
+ readonly error: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
299
+ readonly message: import("effect/Schema").String;
300
+ readonly code: import("effect/Schema").String;
301
+ }>>;
302
+ readonly key: import("effect/Schema").NullOr<import("effect/Schema").Struct<{
303
+ readonly id: import("effect/Schema").String;
304
+ readonly configId: import("effect/Schema").String;
305
+ readonly name: import("effect/Schema").NullOr<import("effect/Schema").String>;
306
+ readonly start: import("effect/Schema").NullOr<import("effect/Schema").String>;
307
+ readonly prefix: import("effect/Schema").NullOr<import("effect/Schema").String>;
308
+ readonly referenceId: import("effect/Schema").String;
309
+ readonly enabled: import("effect/Schema").NullOr<import("effect/Schema").Boolean>;
310
+ readonly expiresAt: import("effect/Schema").NullOr<import("effect/Schema").Date>;
311
+ readonly createdAt: import("effect/Schema").Date;
312
+ readonly updatedAt: import("effect/Schema").Date;
313
+ readonly permissions: import("effect/Schema").NullOr<import("effect/Schema").$Record<import("effect/Schema").String, import("effect/Schema").$Array<import("effect/Schema").String>>>;
314
+ readonly metadata: import("effect/Schema").NullOr<import("effect/Schema").Unknown>;
315
+ }>>;
316
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("../extra/schema").ExtraBadRequest>, never, never> | import("effect/unstable/httpapi/HttpApiEndpoint").HttpApiEndpoint<"verifyPassword", "POST", "/api/auth/verify-password", import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
317
+ readonly password: import("effect/Schema").NonEmptyString;
318
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").StringTree<never>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<import("effect/Schema").Struct<{
319
+ readonly ok: import("effect/Schema").Boolean;
320
+ }>>, import("effect/unstable/httpapi/HttpApiEndpoint").Json<typeof import("effect/unstable/httpapi/HttpApiError").Unauthorized | typeof import("effect/unstable/httpapi/HttpApiError").Forbidden | typeof import("effect/unstable/httpapi/HttpApiError").InternalServerError | typeof import("../extra/schema").ExtraBadRequest>, never, never>, false>>;
@@ -21,18 +21,18 @@ export type KrakstackAuthContextValue = {
21
21
  export declare function KrakstackAuthProvider({ children, locale, baseUrl, projectId, authClient, }: KrakstackAuthProviderProps): import("react").JSX.Element;
22
22
  export declare const useKrakstackAuth: () => KrakstackAuthContextValue | null;
23
23
  export declare const useAuthClient: () => AuthUiClient;
24
- export declare const useKrakstackAuthProjectConfig: () => {
25
- readonly projectKey: string;
26
- readonly name: string | null;
27
- readonly logoUrl: string | null;
28
- readonly authDomain: string | null;
29
- readonly rootDomain: string | null;
30
- readonly themeCss: string | null;
31
- readonly authOptions: {
32
- readonly emailPassword: boolean;
33
- readonly emailOtp: boolean;
34
- readonly google: boolean;
35
- readonly signUp: boolean;
36
- readonly signUpName: boolean;
37
- };
38
- } | null;
24
+ export declare const useKrakstackAuthProjectConfig: () => import("effect/Schema").Struct.ReadonlySide<{
25
+ readonly projectKey: import("effect/Schema").String;
26
+ readonly name: import("effect/Schema").NullOr<import("effect/Schema").String>;
27
+ readonly logoUrl: import("effect/Schema").NullOr<import("effect/Schema").String>;
28
+ readonly authDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
29
+ readonly rootDomain: import("effect/Schema").NullOr<import("effect/Schema").String>;
30
+ readonly themeCss: import("effect/Schema").NullOr<import("effect/Schema").String>;
31
+ readonly authOptions: import("effect/Schema").Struct<{
32
+ readonly emailPassword: import("effect/Schema").Boolean;
33
+ readonly emailOtp: import("effect/Schema").Boolean;
34
+ readonly google: import("effect/Schema").Boolean;
35
+ readonly signUp: import("effect/Schema").Boolean;
36
+ readonly signUpName: import("effect/Schema").Boolean;
37
+ }>;
38
+ }, "Type"> | null;