@shipfox/api-auth 12.0.0 → 12.2.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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +11 -0
- package/dist/core/errors.d.ts.map +1 -1
- package/dist/core/jwt.d.ts +2 -2
- package/dist/core/rate-limit.d.ts.map +1 -1
- package/dist/db/admin-user-moderation.d.ts.map +1 -1
- package/dist/db/db.d.ts +16 -16
- package/dist/db/schema/admin-command-results.d.ts +1 -1
- package/dist/db/schema/admin-grants.d.ts +1 -1
- package/dist/db/schema/outbox.d.ts +1 -1
- package/dist/db/schema/password-resets.d.ts +1 -1
- package/dist/db/schema/rate-limits.d.ts +1 -1
- package/dist/db/schema/refresh-tokens.d.ts +1 -1
- package/dist/db/schema/users.d.ts +2 -2
- package/dist/presentation/routes/rate-limit.d.ts.map +1 -1
- package/dist/tsconfig.test.tsbuildinfo +1 -1
- package/package.json +7 -7
- package/test/routes.ts +6 -2
- package/tsconfig.build.tsbuildinfo +1 -1
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shipfox/api-auth",
|
|
3
3
|
"license": "MIT",
|
|
4
|
-
"version": "12.
|
|
4
|
+
"version": "12.2.0",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "git+https://github.com/ShipfoxHQ/shipfox.git",
|
|
@@ -27,20 +27,20 @@
|
|
|
27
27
|
"drizzle-orm": "^0.45.2",
|
|
28
28
|
"zod": "^4.4.3",
|
|
29
29
|
"@shipfox/api-common-dto": "12.0.0",
|
|
30
|
-
"@shipfox/api-auth-context": "12.
|
|
30
|
+
"@shipfox/api-auth-context": "12.2.0",
|
|
31
31
|
"@shipfox/api-auth-dto": "12.0.0",
|
|
32
|
-
"@shipfox/api-email-challenges": "1.1.
|
|
32
|
+
"@shipfox/api-email-challenges": "1.1.8",
|
|
33
33
|
"@shipfox/api-workspaces-dto": "12.0.0",
|
|
34
34
|
"@shipfox/inter-module": "0.2.3",
|
|
35
35
|
"@shipfox/config": "1.2.4",
|
|
36
36
|
"@shipfox/node-drizzle": "0.3.5",
|
|
37
37
|
"@shipfox/node-auth-root-key": "0.2.3",
|
|
38
|
-
"@shipfox/node-fastify": "0.4.
|
|
38
|
+
"@shipfox/node-fastify": "0.4.2",
|
|
39
39
|
"@shipfox/node-jwt": "0.4.0",
|
|
40
40
|
"@shipfox/node-email": "0.3.4",
|
|
41
|
-
"@shipfox/node-mailer": "0.2.
|
|
42
|
-
"@shipfox/node-module": "1.0.
|
|
43
|
-
"@shipfox/node-opentelemetry": "0.6.
|
|
41
|
+
"@shipfox/node-mailer": "0.2.5",
|
|
42
|
+
"@shipfox/node-module": "1.0.6",
|
|
43
|
+
"@shipfox/node-opentelemetry": "0.6.4",
|
|
44
44
|
"@shipfox/node-outbox": "0.2.6",
|
|
45
45
|
"@shipfox/node-postgres": "0.5.0",
|
|
46
46
|
"@shipfox/node-rate-limit": "0.4.0",
|
package/test/routes.ts
CHANGED
|
@@ -73,6 +73,7 @@ vi.mock('@shipfox/node-mailer', () => ({mailer: testConfig.mailer}));
|
|
|
73
73
|
const CODE_RE = /\b\d{8}\b/u;
|
|
74
74
|
const TOKEN_RE = /token=([\w\-_=]+)/;
|
|
75
75
|
type AuthEmailEventType = typeof AUTH_PASSWORD_RESET_SEND_REQUESTED;
|
|
76
|
+
type InjectResponse = Awaited<ReturnType<FastifyInstance['inject']>>;
|
|
76
77
|
|
|
77
78
|
export const ROUTE_TEST_SECRET = userAccessTokenKey();
|
|
78
79
|
export const acceptWorkspaceInvitationMock: ReturnType<typeof vi.fn> =
|
|
@@ -172,7 +173,7 @@ export async function createAuthTestApp(params?: {
|
|
|
172
173
|
export async function signup(
|
|
173
174
|
app: FastifyInstance,
|
|
174
175
|
params: {email: string; password: string; name?: string},
|
|
175
|
-
) {
|
|
176
|
+
): Promise<InjectResponse> {
|
|
176
177
|
const result = await app.inject({
|
|
177
178
|
method: 'POST',
|
|
178
179
|
url: '/auth/signup',
|
|
@@ -198,7 +199,10 @@ export async function verifyEmail(
|
|
|
198
199
|
expect(res.statusCode).toBe(200);
|
|
199
200
|
}
|
|
200
201
|
|
|
201
|
-
export async function login(
|
|
202
|
+
export async function login(
|
|
203
|
+
app: FastifyInstance,
|
|
204
|
+
params: {email: string; password: string},
|
|
205
|
+
): Promise<InjectResponse> {
|
|
202
206
|
return await app.inject({
|
|
203
207
|
method: 'POST',
|
|
204
208
|
url: '/auth/login',
|