@zgeoff/mcp-auth 0.2.4 → 0.3.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/types.d.ts +2 -3
- package/package.json +1 -1
- package/src/types.ts +2 -3
package/dist/types.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Database } from 'bun:sqlite';
|
|
2
|
+
import type { Clock as StdClock } from '@zgeoff/std';
|
|
2
3
|
import type { Kysely } from 'kysely';
|
|
3
4
|
import type { Tagged } from 'type-fest';
|
|
4
5
|
export type GrantID = Tagged<string, 'GrantID'>;
|
|
@@ -28,9 +29,7 @@ export interface MCPAuthTables {
|
|
|
28
29
|
readonly passkey: string;
|
|
29
30
|
readonly enrollmentToken: string;
|
|
30
31
|
}
|
|
31
|
-
export
|
|
32
|
-
readonly now: () => number;
|
|
33
|
-
}
|
|
32
|
+
export type Clock = Pick<StdClock, 'now'>;
|
|
34
33
|
export interface Requester {
|
|
35
34
|
readonly socketAddress: string | null;
|
|
36
35
|
readonly connectingIP: {
|
package/package.json
CHANGED
package/src/types.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import type { Database } from 'bun:sqlite';
|
|
2
|
+
import type { Clock as StdClock } from '@zgeoff/std';
|
|
2
3
|
import type { Kysely } from 'kysely';
|
|
3
4
|
import type { Tagged } from 'type-fest';
|
|
4
5
|
|
|
@@ -44,9 +45,7 @@ export interface MCPAuthTables {
|
|
|
44
45
|
// The clock for the times the core stamps itself: sign-ins in progress,
|
|
45
46
|
// enrollments, lastUsedAt and removeExpired. better-auth stamps token, code
|
|
46
47
|
// and session expiries from Date.now().
|
|
47
|
-
export
|
|
48
|
-
readonly now: () => number;
|
|
49
|
-
}
|
|
48
|
+
export type Clock = Pick<StdClock, 'now'>;
|
|
50
49
|
|
|
51
50
|
export interface Requester {
|
|
52
51
|
readonly socketAddress: string | null;
|