@marcoappio/marco-config 7.0.0 → 7.1.0
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/sdk/endpoints/index.d.ts +124 -2
- package/dist/sdk/endpoints/index.d.ts.map +1 -1
- package/dist/sdk/endpoints/public/auth/browser/deleteSession.d.ts +17 -0
- package/dist/sdk/endpoints/public/auth/browser/deleteSession.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/browser/deleteSession.js +14 -0
- package/dist/sdk/endpoints/public/auth/browser/index.d.ts +123 -0
- package/dist/sdk/endpoints/public/auth/browser/index.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/browser/index.js +8 -0
- package/dist/sdk/endpoints/public/auth/browser/refreshAuth.d.ts +40 -0
- package/dist/sdk/endpoints/public/auth/browser/refreshAuth.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/browser/refreshAuth.js +14 -0
- package/dist/sdk/endpoints/public/auth/browser/schemas.d.ts +82 -0
- package/dist/sdk/endpoints/public/auth/browser/schemas.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/browser/schemas.js +25 -0
- package/dist/sdk/endpoints/public/auth/browser/verifyAuthCode.d.ts +69 -0
- package/dist/sdk/endpoints/public/auth/browser/verifyAuthCode.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/browser/verifyAuthCode.js +21 -0
- package/dist/sdk/endpoints/public/auth/index.d.ts +124 -2
- package/dist/sdk/endpoints/public/auth/index.d.ts.map +1 -1
- package/dist/sdk/endpoints/public/auth/index.js +2 -0
- package/dist/sdk/endpoints/public/auth/refreshAuth.d.ts +1 -1
- package/dist/sdk/endpoints/public/auth/refreshAuth.d.ts.map +1 -1
- package/dist/sdk/endpoints/public/auth/refreshAuth.js +2 -14
- package/dist/sdk/endpoints/public/auth/schemas.d.ts +39 -0
- package/dist/sdk/endpoints/public/auth/schemas.d.ts.map +1 -0
- package/dist/sdk/endpoints/public/auth/schemas.js +20 -0
- package/dist/sdk/endpoints/public/auth/verifyAuthCode.d.ts +1 -1
- package/dist/sdk/endpoints/public/auth/verifyAuthCode.d.ts.map +1 -1
- package/dist/sdk/endpoints/public/auth/verifyAuthCode.js +2 -14
- package/dist/sdk/endpoints/public/index.d.ts +124 -2
- package/dist/sdk/endpoints/public/index.d.ts.map +1 -1
- package/dist/sdk/index.d.ts +124 -2
- package/dist/sdk/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -115,6 +115,128 @@ export declare const endpoints: {
|
|
|
115
115
|
};
|
|
116
116
|
public: {
|
|
117
117
|
auth: {
|
|
118
|
+
browser: {
|
|
119
|
+
deleteSession: EndpointConfig<"/v1/pb/auth/browser/session", GenericSchema | undefined, import("valibot").StrictObjectSchema<{
|
|
120
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
121
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
122
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
123
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
124
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
125
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
126
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
127
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
128
|
+
}, undefined>;
|
|
129
|
+
}, undefined>;
|
|
130
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
131
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
132
|
+
readonly status: import("valibot").LiteralSchema<204, undefined>;
|
|
133
|
+
}, undefined>], undefined>>;
|
|
134
|
+
refreshAuth: EndpointConfig<"/v1/pb/auth/browser/refresh", GenericSchema | undefined, import("valibot").StrictObjectSchema<{
|
|
135
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
136
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
137
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
138
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
139
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
140
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
141
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
142
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
143
|
+
}, undefined>;
|
|
144
|
+
}, undefined>;
|
|
145
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
146
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
147
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
148
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_REFRESH_TOKEN_INVALID", undefined>;
|
|
149
|
+
}, undefined>;
|
|
150
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
151
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
152
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
153
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
154
|
+
}, undefined>;
|
|
155
|
+
readonly status: import("valibot").LiteralSchema<502, undefined>;
|
|
156
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
157
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
158
|
+
accessToken: import("valibot").StringSchema<undefined>;
|
|
159
|
+
user: import("valibot").ObjectSchema<{
|
|
160
|
+
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
161
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
162
|
+
readonly emailVerified: import("valibot").BooleanSchema<undefined>;
|
|
163
|
+
readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
164
|
+
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
165
|
+
readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
166
|
+
readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
167
|
+
readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
168
|
+
}, undefined>;
|
|
169
|
+
}, undefined>;
|
|
170
|
+
readonly status: import("valibot").LiteralSchema<200, undefined>;
|
|
171
|
+
}, undefined>], undefined>>;
|
|
172
|
+
verifyAuthCode: EndpointConfig<"/v1/pb/auth/browser/verify-code", import("valibot").ObjectSchema<{
|
|
173
|
+
readonly authType: import("valibot").LiteralSchema<"CODE", undefined>;
|
|
174
|
+
readonly code: import("valibot").StringSchema<undefined>;
|
|
175
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
176
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
177
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
178
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
179
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
180
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
181
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
182
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
183
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
184
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
185
|
+
}, undefined>;
|
|
186
|
+
}, undefined>;
|
|
187
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
188
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
189
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
190
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_EXPIRED", undefined>;
|
|
191
|
+
}, undefined>;
|
|
192
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
193
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
194
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
195
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_INVALID", undefined>;
|
|
196
|
+
}, undefined>;
|
|
197
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
198
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
199
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
200
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_PREVIOUSLY_USED", undefined>;
|
|
201
|
+
}, undefined>;
|
|
202
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
203
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
204
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
205
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_TOO_MANY_ATTEMPTS", undefined>;
|
|
206
|
+
}, undefined>;
|
|
207
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
208
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
209
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
210
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
211
|
+
}, undefined>;
|
|
212
|
+
readonly status: import("valibot").LiteralSchema<502, undefined>;
|
|
213
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
214
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
215
|
+
readonly code: import("valibot").LiteralSchema<"USER_NOT_FOUND", undefined>;
|
|
216
|
+
}, undefined>;
|
|
217
|
+
readonly status: import("valibot").LiteralSchema<404, undefined>;
|
|
218
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
219
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
220
|
+
readonly code: import("valibot").LiteralSchema<"USER_MARKED_FOR_DELETION", undefined>;
|
|
221
|
+
}, undefined>;
|
|
222
|
+
readonly status: import("valibot").LiteralSchema<409, undefined>;
|
|
223
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
224
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
225
|
+
accessToken: import("valibot").StringSchema<undefined>;
|
|
226
|
+
user: import("valibot").ObjectSchema<{
|
|
227
|
+
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
228
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
229
|
+
readonly emailVerified: import("valibot").BooleanSchema<undefined>;
|
|
230
|
+
readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
231
|
+
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
232
|
+
readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
233
|
+
readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
234
|
+
readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
235
|
+
}, undefined>;
|
|
236
|
+
}, undefined>;
|
|
237
|
+
readonly status: import("valibot").LiteralSchema<200, undefined>;
|
|
238
|
+
}, undefined>], undefined>>;
|
|
239
|
+
};
|
|
118
240
|
refreshAuth: EndpointConfig<"/v1/pb/auth/refresh", import("valibot").ObjectSchema<{
|
|
119
241
|
readonly refreshToken: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
120
242
|
}, undefined>, GenericSchema | undefined, import("valibot").UnionSchema<[import("valibot").ObjectSchema<{
|
|
@@ -139,8 +261,8 @@ export declare const endpoints: {
|
|
|
139
261
|
readonly status: import("valibot").LiteralSchema<502, undefined>;
|
|
140
262
|
}, undefined>, import("valibot").ObjectSchema<{
|
|
141
263
|
readonly data: import("valibot").ObjectSchema<{
|
|
142
|
-
readonly accessToken: import("valibot").StringSchema<undefined>;
|
|
143
264
|
readonly refreshToken: import("valibot").StringSchema<undefined>;
|
|
265
|
+
readonly accessToken: import("valibot").StringSchema<undefined>;
|
|
144
266
|
readonly user: import("valibot").ObjectSchema<{
|
|
145
267
|
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
146
268
|
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
@@ -230,8 +352,8 @@ export declare const endpoints: {
|
|
|
230
352
|
readonly status: import("valibot").LiteralSchema<409, undefined>;
|
|
231
353
|
}, undefined>, import("valibot").ObjectSchema<{
|
|
232
354
|
readonly data: import("valibot").ObjectSchema<{
|
|
233
|
-
readonly accessToken: import("valibot").StringSchema<undefined>;
|
|
234
355
|
readonly refreshToken: import("valibot").StringSchema<undefined>;
|
|
356
|
+
readonly accessToken: import("valibot").StringSchema<undefined>;
|
|
235
357
|
readonly user: import("valibot").ObjectSchema<{
|
|
236
358
|
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
237
359
|
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/sdk/endpoints/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAE5C,OAAO,KAAK,EAAE,cAAc,EAAe,MAAM,qBAAqB,CAAA;AAWtE,eAAO,MAAM,SAAS
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/sdk/endpoints/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAE5C,OAAO,KAAK,EAAE,cAAc,EAAe,MAAM,qBAAqB,CAAA;AAWtE,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGM,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
export declare const deleteSession: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/session", v.GenericSchema | undefined, v.StrictObjectSchema<{
|
|
3
|
+
readonly sessionGeneration: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.UuidAction<string, undefined>]>;
|
|
4
|
+
}, undefined>, v.UnionSchema<[v.StrictObjectSchema<{
|
|
5
|
+
readonly data: v.StrictObjectSchema<{
|
|
6
|
+
readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
7
|
+
readonly issues: v.ObjectSchema<{
|
|
8
|
+
readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
9
|
+
readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
10
|
+
readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
11
|
+
}, undefined>;
|
|
12
|
+
}, undefined>;
|
|
13
|
+
readonly status: v.LiteralSchema<400, undefined>;
|
|
14
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
15
|
+
readonly status: v.LiteralSchema<204, undefined>;
|
|
16
|
+
}, undefined>], undefined>>;
|
|
17
|
+
//# sourceMappingURL=deleteSession.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"deleteSession.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/public/auth/browser/deleteSession.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAK5B,eAAO,MAAM,aAAa;;;;;;;;;;;;;;2BAUxB,CAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
import { createEndpoint } from '../../../../../sdk/endpoints/createEndpointConfig';
|
|
3
|
+
import { browserAuthQuerySchema, browserErrorSchemas } from '../../../../../sdk/endpoints/public/auth/browser/schemas';
|
|
4
|
+
export const deleteSession = createEndpoint({
|
|
5
|
+
method: 'DELETE',
|
|
6
|
+
path: '/v1/pb/auth/browser/session',
|
|
7
|
+
query: browserAuthQuerySchema,
|
|
8
|
+
response: v.union([
|
|
9
|
+
browserErrorSchemas.validationFailed,
|
|
10
|
+
v.strictObject({
|
|
11
|
+
status: v.literal(204),
|
|
12
|
+
}),
|
|
13
|
+
]),
|
|
14
|
+
});
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
export declare const browser: {
|
|
2
|
+
deleteSession: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/session", import("valibot").GenericSchema | undefined, import("valibot").StrictObjectSchema<{
|
|
3
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
4
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
5
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
6
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
7
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
8
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
9
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
10
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
11
|
+
}, undefined>;
|
|
12
|
+
}, undefined>;
|
|
13
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
14
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
15
|
+
readonly status: import("valibot").LiteralSchema<204, undefined>;
|
|
16
|
+
}, undefined>], undefined>>;
|
|
17
|
+
refreshAuth: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/refresh", import("valibot").GenericSchema | undefined, import("valibot").StrictObjectSchema<{
|
|
18
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
19
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
20
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
21
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
22
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
23
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
24
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
25
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
26
|
+
}, undefined>;
|
|
27
|
+
}, undefined>;
|
|
28
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
29
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
30
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
31
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_REFRESH_TOKEN_INVALID", undefined>;
|
|
32
|
+
}, undefined>;
|
|
33
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
34
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
35
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
36
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
37
|
+
}, undefined>;
|
|
38
|
+
readonly status: import("valibot").LiteralSchema<502, undefined>;
|
|
39
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
40
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
41
|
+
accessToken: import("valibot").StringSchema<undefined>;
|
|
42
|
+
user: import("valibot").ObjectSchema<{
|
|
43
|
+
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
44
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
45
|
+
readonly emailVerified: import("valibot").BooleanSchema<undefined>;
|
|
46
|
+
readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
47
|
+
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
48
|
+
readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
49
|
+
readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
50
|
+
readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
51
|
+
}, undefined>;
|
|
52
|
+
}, undefined>;
|
|
53
|
+
readonly status: import("valibot").LiteralSchema<200, undefined>;
|
|
54
|
+
}, undefined>], undefined>>;
|
|
55
|
+
verifyAuthCode: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/verify-code", import("valibot").ObjectSchema<{
|
|
56
|
+
readonly authType: import("valibot").LiteralSchema<"CODE", undefined>;
|
|
57
|
+
readonly code: import("valibot").StringSchema<undefined>;
|
|
58
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
59
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
60
|
+
readonly sessionGeneration: import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").UuidAction<string, undefined>]>;
|
|
61
|
+
}, undefined>, import("valibot").UnionSchema<[import("valibot").StrictObjectSchema<{
|
|
62
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
63
|
+
readonly code: import("valibot").LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
64
|
+
readonly issues: import("valibot").ObjectSchema<{
|
|
65
|
+
readonly nested: import("valibot").OptionalSchema<import("valibot").RecordSchema<import("valibot").StringSchema<undefined>, import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
66
|
+
readonly other: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
67
|
+
readonly root: import("valibot").OptionalSchema<import("valibot").ArraySchema<import("valibot").StringSchema<undefined>, undefined>, undefined>;
|
|
68
|
+
}, undefined>;
|
|
69
|
+
}, undefined>;
|
|
70
|
+
readonly status: import("valibot").LiteralSchema<400, undefined>;
|
|
71
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
72
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
73
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_EXPIRED", undefined>;
|
|
74
|
+
}, undefined>;
|
|
75
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
76
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
77
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
78
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_INVALID", undefined>;
|
|
79
|
+
}, undefined>;
|
|
80
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
81
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
82
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
83
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_CODE_PREVIOUSLY_USED", undefined>;
|
|
84
|
+
}, undefined>;
|
|
85
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
86
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
87
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
88
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_TOO_MANY_ATTEMPTS", undefined>;
|
|
89
|
+
}, undefined>;
|
|
90
|
+
readonly status: import("valibot").LiteralSchema<401, undefined>;
|
|
91
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
92
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
93
|
+
readonly code: import("valibot").LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
94
|
+
}, undefined>;
|
|
95
|
+
readonly status: import("valibot").LiteralSchema<502, undefined>;
|
|
96
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
97
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
98
|
+
readonly code: import("valibot").LiteralSchema<"USER_NOT_FOUND", undefined>;
|
|
99
|
+
}, undefined>;
|
|
100
|
+
readonly status: import("valibot").LiteralSchema<404, undefined>;
|
|
101
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
102
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
103
|
+
readonly code: import("valibot").LiteralSchema<"USER_MARKED_FOR_DELETION", undefined>;
|
|
104
|
+
}, undefined>;
|
|
105
|
+
readonly status: import("valibot").LiteralSchema<409, undefined>;
|
|
106
|
+
}, undefined>, import("valibot").StrictObjectSchema<{
|
|
107
|
+
readonly data: import("valibot").StrictObjectSchema<{
|
|
108
|
+
accessToken: import("valibot").StringSchema<undefined>;
|
|
109
|
+
user: import("valibot").ObjectSchema<{
|
|
110
|
+
readonly createdAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
111
|
+
readonly email: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").RfcEmailAction<string, undefined>]>, undefined>;
|
|
112
|
+
readonly emailVerified: import("valibot").BooleanSchema<undefined>;
|
|
113
|
+
readonly firstName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
114
|
+
readonly id: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
115
|
+
readonly lastName: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
116
|
+
readonly profilePictureUrl: import("valibot").NullableSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
117
|
+
readonly updatedAt: import("valibot").NonOptionalSchema<import("valibot").SchemaWithPipe<readonly [import("valibot").StringSchema<undefined>, import("valibot").NonEmptyAction<string, undefined>, import("valibot").MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
118
|
+
}, undefined>;
|
|
119
|
+
}, undefined>;
|
|
120
|
+
readonly status: import("valibot").LiteralSchema<200, undefined>;
|
|
121
|
+
}, undefined>], undefined>>;
|
|
122
|
+
};
|
|
123
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/public/auth/browser/index.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAInB,CAAA"}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
export declare const refreshAuth: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/refresh", v.GenericSchema | undefined, v.StrictObjectSchema<{
|
|
3
|
+
readonly sessionGeneration: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.UuidAction<string, undefined>]>;
|
|
4
|
+
}, undefined>, v.UnionSchema<[v.StrictObjectSchema<{
|
|
5
|
+
readonly data: v.StrictObjectSchema<{
|
|
6
|
+
readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
7
|
+
readonly issues: v.ObjectSchema<{
|
|
8
|
+
readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
9
|
+
readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
10
|
+
readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
11
|
+
}, undefined>;
|
|
12
|
+
}, undefined>;
|
|
13
|
+
readonly status: v.LiteralSchema<400, undefined>;
|
|
14
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
15
|
+
readonly data: v.StrictObjectSchema<{
|
|
16
|
+
readonly code: v.LiteralSchema<"AUTH_REFRESH_TOKEN_INVALID", undefined>;
|
|
17
|
+
}, undefined>;
|
|
18
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
19
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
20
|
+
readonly data: v.StrictObjectSchema<{
|
|
21
|
+
readonly code: v.LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
22
|
+
}, undefined>;
|
|
23
|
+
readonly status: v.LiteralSchema<502, undefined>;
|
|
24
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
25
|
+
readonly data: v.StrictObjectSchema<{
|
|
26
|
+
accessToken: v.StringSchema<undefined>;
|
|
27
|
+
user: v.ObjectSchema<{
|
|
28
|
+
readonly createdAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
29
|
+
readonly email: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>;
|
|
30
|
+
readonly emailVerified: v.BooleanSchema<undefined>;
|
|
31
|
+
readonly firstName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
32
|
+
readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
33
|
+
readonly lastName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
34
|
+
readonly profilePictureUrl: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
35
|
+
readonly updatedAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
36
|
+
}, undefined>;
|
|
37
|
+
}, undefined>;
|
|
38
|
+
readonly status: v.LiteralSchema<200, undefined>;
|
|
39
|
+
}, undefined>], undefined>>;
|
|
40
|
+
//# sourceMappingURL=refreshAuth.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"refreshAuth.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/public/auth/browser/refreshAuth.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAS5B,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAUtB,CAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
import { createEndpoint } from '../../../../../sdk/endpoints/createEndpointConfig';
|
|
3
|
+
import { browserAuthQuerySchema, browserAuthSuccessResponseSchema, browserErrorSchemas, } from '../../../../../sdk/endpoints/public/auth/browser/schemas';
|
|
4
|
+
export const refreshAuth = createEndpoint({
|
|
5
|
+
method: 'POST',
|
|
6
|
+
path: '/v1/pb/auth/browser/refresh',
|
|
7
|
+
query: browserAuthQuerySchema,
|
|
8
|
+
response: v.union([
|
|
9
|
+
browserErrorSchemas.validationFailed,
|
|
10
|
+
browserErrorSchemas.authRefreshTokenInvalid,
|
|
11
|
+
browserErrorSchemas.authServerResponseUnexpected,
|
|
12
|
+
browserAuthSuccessResponseSchema,
|
|
13
|
+
]),
|
|
14
|
+
});
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
export declare const browserAuthQuerySchema: v.StrictObjectSchema<{
|
|
3
|
+
readonly sessionGeneration: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.UuidAction<string, undefined>]>;
|
|
4
|
+
}, undefined>;
|
|
5
|
+
export declare const browserAuthSuccessResponseSchema: v.StrictObjectSchema<{
|
|
6
|
+
readonly data: v.StrictObjectSchema<{
|
|
7
|
+
accessToken: v.StringSchema<undefined>;
|
|
8
|
+
user: v.ObjectSchema<{
|
|
9
|
+
readonly createdAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
10
|
+
readonly email: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>;
|
|
11
|
+
readonly emailVerified: v.BooleanSchema<undefined>;
|
|
12
|
+
readonly firstName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
13
|
+
readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
14
|
+
readonly lastName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
15
|
+
readonly profilePictureUrl: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
16
|
+
readonly updatedAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
17
|
+
}, undefined>;
|
|
18
|
+
}, undefined>;
|
|
19
|
+
readonly status: v.LiteralSchema<200, undefined>;
|
|
20
|
+
}, undefined>;
|
|
21
|
+
export declare const browserErrorSchemas: {
|
|
22
|
+
readonly authCodeExpired: v.StrictObjectSchema<{
|
|
23
|
+
readonly data: v.StrictObjectSchema<{
|
|
24
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_EXPIRED", undefined>;
|
|
25
|
+
}, undefined>;
|
|
26
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
27
|
+
}, undefined>;
|
|
28
|
+
readonly authCodeInvalid: v.StrictObjectSchema<{
|
|
29
|
+
readonly data: v.StrictObjectSchema<{
|
|
30
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_INVALID", undefined>;
|
|
31
|
+
}, undefined>;
|
|
32
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
33
|
+
}, undefined>;
|
|
34
|
+
readonly authCodePreviouslyUsed: v.StrictObjectSchema<{
|
|
35
|
+
readonly data: v.StrictObjectSchema<{
|
|
36
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_PREVIOUSLY_USED", undefined>;
|
|
37
|
+
}, undefined>;
|
|
38
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
39
|
+
}, undefined>;
|
|
40
|
+
readonly authRefreshTokenInvalid: v.StrictObjectSchema<{
|
|
41
|
+
readonly data: v.StrictObjectSchema<{
|
|
42
|
+
readonly code: v.LiteralSchema<"AUTH_REFRESH_TOKEN_INVALID", undefined>;
|
|
43
|
+
}, undefined>;
|
|
44
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
45
|
+
}, undefined>;
|
|
46
|
+
readonly authServerResponseUnexpected: v.StrictObjectSchema<{
|
|
47
|
+
readonly data: v.StrictObjectSchema<{
|
|
48
|
+
readonly code: v.LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
49
|
+
}, undefined>;
|
|
50
|
+
readonly status: v.LiteralSchema<502, undefined>;
|
|
51
|
+
}, undefined>;
|
|
52
|
+
readonly authTooManyAttempts: v.StrictObjectSchema<{
|
|
53
|
+
readonly data: v.StrictObjectSchema<{
|
|
54
|
+
readonly code: v.LiteralSchema<"AUTH_TOO_MANY_ATTEMPTS", undefined>;
|
|
55
|
+
}, undefined>;
|
|
56
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
57
|
+
}, undefined>;
|
|
58
|
+
readonly userMarkedForDeletion: v.StrictObjectSchema<{
|
|
59
|
+
readonly data: v.StrictObjectSchema<{
|
|
60
|
+
readonly code: v.LiteralSchema<"USER_MARKED_FOR_DELETION", undefined>;
|
|
61
|
+
}, undefined>;
|
|
62
|
+
readonly status: v.LiteralSchema<409, undefined>;
|
|
63
|
+
}, undefined>;
|
|
64
|
+
readonly userNotFound: v.StrictObjectSchema<{
|
|
65
|
+
readonly data: v.StrictObjectSchema<{
|
|
66
|
+
readonly code: v.LiteralSchema<"USER_NOT_FOUND", undefined>;
|
|
67
|
+
}, undefined>;
|
|
68
|
+
readonly status: v.LiteralSchema<404, undefined>;
|
|
69
|
+
}, undefined>;
|
|
70
|
+
readonly validationFailed: v.StrictObjectSchema<{
|
|
71
|
+
readonly data: v.StrictObjectSchema<{
|
|
72
|
+
readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
73
|
+
readonly issues: v.ObjectSchema<{
|
|
74
|
+
readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
75
|
+
readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
76
|
+
readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
77
|
+
}, undefined>;
|
|
78
|
+
}, undefined>;
|
|
79
|
+
readonly status: v.LiteralSchema<400, undefined>;
|
|
80
|
+
}, undefined>;
|
|
81
|
+
};
|
|
82
|
+
//# sourceMappingURL=schemas.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schemas.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/public/auth/browser/schemas.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAkB5B,eAAO,MAAM,sBAAsB;;aAEjC,CAAA;AAEF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;aAG3C,CAAA;AAEF,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqCtB,CAAA"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
import { authResponseDataEntries } from '../../../../../sdk/endpoints/public/auth/schemas';
|
|
3
|
+
import { errors } from '../../../../../sdk/validation/errors';
|
|
4
|
+
const createBrowserErrorResponseSchema = (data, status) => v.strictObject({
|
|
5
|
+
data: v.strictObject(data.entries),
|
|
6
|
+
status,
|
|
7
|
+
});
|
|
8
|
+
export const browserAuthQuerySchema = v.strictObject({
|
|
9
|
+
sessionGeneration: v.pipe(v.string(), v.uuid()),
|
|
10
|
+
});
|
|
11
|
+
export const browserAuthSuccessResponseSchema = v.strictObject({
|
|
12
|
+
data: v.strictObject(authResponseDataEntries),
|
|
13
|
+
status: v.literal(200),
|
|
14
|
+
});
|
|
15
|
+
export const browserErrorSchemas = {
|
|
16
|
+
authCodeExpired: createBrowserErrorResponseSchema(errors.authCodeExpiredErrorSchema.entries.data, errors.authCodeExpiredErrorSchema.entries.status),
|
|
17
|
+
authCodeInvalid: createBrowserErrorResponseSchema(errors.authCodeInvalidErrorSchema.entries.data, errors.authCodeInvalidErrorSchema.entries.status),
|
|
18
|
+
authCodePreviouslyUsed: createBrowserErrorResponseSchema(errors.authCodePreviouslyUsedErrorSchema.entries.data, errors.authCodePreviouslyUsedErrorSchema.entries.status),
|
|
19
|
+
authRefreshTokenInvalid: createBrowserErrorResponseSchema(errors.authRefreshTokenInvalid.entries.data, errors.authRefreshTokenInvalid.entries.status),
|
|
20
|
+
authServerResponseUnexpected: createBrowserErrorResponseSchema(errors.authServerResponseUnexpectedErrorSchema.entries.data, errors.authServerResponseUnexpectedErrorSchema.entries.status),
|
|
21
|
+
authTooManyAttempts: createBrowserErrorResponseSchema(errors.authTooManyAttemptsErrorSchema.entries.data, errors.authTooManyAttemptsErrorSchema.entries.status),
|
|
22
|
+
userMarkedForDeletion: createBrowserErrorResponseSchema(errors.userMarkedForDeletionErrorSchema.entries.data, errors.userMarkedForDeletionErrorSchema.entries.status),
|
|
23
|
+
userNotFound: createBrowserErrorResponseSchema(errors.userNotFoundErrorSchema.entries.data, errors.userNotFoundErrorSchema.entries.status),
|
|
24
|
+
validationFailed: createBrowserErrorResponseSchema(errors.validationFailedErrorSchema.entries.data, errors.validationFailedErrorSchema.entries.status),
|
|
25
|
+
};
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import * as v from 'valibot';
|
|
2
|
+
export declare const verifyAuthCode: import("../../../../..").EndpointConfig<"/v1/pb/auth/browser/verify-code", v.ObjectSchema<{
|
|
3
|
+
readonly authType: v.LiteralSchema<"CODE", undefined>;
|
|
4
|
+
readonly code: v.StringSchema<undefined>;
|
|
5
|
+
readonly email: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>;
|
|
6
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
7
|
+
readonly sessionGeneration: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.UuidAction<string, undefined>]>;
|
|
8
|
+
}, undefined>, v.UnionSchema<[v.StrictObjectSchema<{
|
|
9
|
+
readonly data: v.StrictObjectSchema<{
|
|
10
|
+
readonly code: v.LiteralSchema<"VALIDATION_FAILED", undefined>;
|
|
11
|
+
readonly issues: v.ObjectSchema<{
|
|
12
|
+
readonly nested: v.OptionalSchema<v.RecordSchema<v.StringSchema<undefined>, v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>, undefined>, undefined>;
|
|
13
|
+
readonly other: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
14
|
+
readonly root: v.OptionalSchema<v.ArraySchema<v.StringSchema<undefined>, undefined>, undefined>;
|
|
15
|
+
}, undefined>;
|
|
16
|
+
}, undefined>;
|
|
17
|
+
readonly status: v.LiteralSchema<400, undefined>;
|
|
18
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
19
|
+
readonly data: v.StrictObjectSchema<{
|
|
20
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_EXPIRED", undefined>;
|
|
21
|
+
}, undefined>;
|
|
22
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
23
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
24
|
+
readonly data: v.StrictObjectSchema<{
|
|
25
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_INVALID", undefined>;
|
|
26
|
+
}, undefined>;
|
|
27
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
28
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
29
|
+
readonly data: v.StrictObjectSchema<{
|
|
30
|
+
readonly code: v.LiteralSchema<"AUTH_CODE_PREVIOUSLY_USED", undefined>;
|
|
31
|
+
}, undefined>;
|
|
32
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
33
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
34
|
+
readonly data: v.StrictObjectSchema<{
|
|
35
|
+
readonly code: v.LiteralSchema<"AUTH_TOO_MANY_ATTEMPTS", undefined>;
|
|
36
|
+
}, undefined>;
|
|
37
|
+
readonly status: v.LiteralSchema<401, undefined>;
|
|
38
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
39
|
+
readonly data: v.StrictObjectSchema<{
|
|
40
|
+
readonly code: v.LiteralSchema<"AUTH_SERVER_RESPONSE_UNEXPECTED", undefined>;
|
|
41
|
+
}, undefined>;
|
|
42
|
+
readonly status: v.LiteralSchema<502, undefined>;
|
|
43
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
44
|
+
readonly data: v.StrictObjectSchema<{
|
|
45
|
+
readonly code: v.LiteralSchema<"USER_NOT_FOUND", undefined>;
|
|
46
|
+
}, undefined>;
|
|
47
|
+
readonly status: v.LiteralSchema<404, undefined>;
|
|
48
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
49
|
+
readonly data: v.StrictObjectSchema<{
|
|
50
|
+
readonly code: v.LiteralSchema<"USER_MARKED_FOR_DELETION", undefined>;
|
|
51
|
+
}, undefined>;
|
|
52
|
+
readonly status: v.LiteralSchema<409, undefined>;
|
|
53
|
+
}, undefined>, v.StrictObjectSchema<{
|
|
54
|
+
readonly data: v.StrictObjectSchema<{
|
|
55
|
+
accessToken: v.StringSchema<undefined>;
|
|
56
|
+
user: v.ObjectSchema<{
|
|
57
|
+
readonly createdAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
58
|
+
readonly email: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RfcEmailAction<string, undefined>]>, undefined>;
|
|
59
|
+
readonly emailVerified: v.BooleanSchema<undefined>;
|
|
60
|
+
readonly firstName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
61
|
+
readonly id: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
62
|
+
readonly lastName: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
63
|
+
readonly profilePictureUrl: v.NullableSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
64
|
+
readonly updatedAt: v.NonOptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.NonEmptyAction<string, undefined>, v.MaxLengthAction<string, number, undefined>]>, undefined>;
|
|
65
|
+
}, undefined>;
|
|
66
|
+
}, undefined>;
|
|
67
|
+
readonly status: v.LiteralSchema<200, undefined>;
|
|
68
|
+
}, undefined>], undefined>>;
|
|
69
|
+
//# sourceMappingURL=verifyAuthCode.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"verifyAuthCode.d.ts","sourceRoot":"","sources":["../../../../../../src/sdk/endpoints/public/auth/browser/verifyAuthCode.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,SAAS,CAAA;AAU5B,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;2BAgBzB,CAAA"}
|