@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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@shipfox/api-auth",
3
3
  "license": "MIT",
4
- "version": "12.0.0",
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.0.0",
30
+ "@shipfox/api-auth-context": "12.2.0",
31
31
  "@shipfox/api-auth-dto": "12.0.0",
32
- "@shipfox/api-email-challenges": "1.1.7",
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.1",
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.4",
42
- "@shipfox/node-module": "1.0.5",
43
- "@shipfox/node-opentelemetry": "0.6.3",
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(app: FastifyInstance, params: {email: string; password: string}) {
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',