@tramvai/tokens-server-private 4.41.48 → 4.41.52
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/lib/index.d.ts +30 -8
- package/package.json +4 -3
package/lib/index.d.ts
CHANGED
|
@@ -1,19 +1,42 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
/// <reference types="node" />
|
|
3
3
|
import type { Server } from 'http';
|
|
4
|
-
import type { FastifyError, FastifyInstance, FastifyReply, FastifyRequest
|
|
4
|
+
import type { FastifyError, FastifyInstance, FastifyReply, FastifyRequest } from 'fastify';
|
|
5
5
|
import type { Papi } from '@tramvai/papi';
|
|
6
6
|
import type { Duplex } from 'stream';
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
declare module 'fastify' {
|
|
8
|
+
interface FastifyInstance {
|
|
9
|
+
/**
|
|
10
|
+
* Manual cookie parsing method
|
|
11
|
+
* @docs https://github.com/fastify/fastify-cookie#manual-cookie-parsing
|
|
12
|
+
* @param cookieHeader Raw cookie header value
|
|
13
|
+
*/
|
|
14
|
+
parseCookie(cookieHeader: string): {
|
|
15
|
+
[key: string]: string;
|
|
16
|
+
};
|
|
17
|
+
}
|
|
18
|
+
interface FastifyRequest {
|
|
19
|
+
/**
|
|
20
|
+
* Request cookies
|
|
21
|
+
*/
|
|
22
|
+
cookies: {
|
|
23
|
+
[cookieName: string]: string | undefined;
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
interface FastifyReply {
|
|
27
|
+
/**
|
|
28
|
+
* Request cookies
|
|
29
|
+
*/
|
|
30
|
+
cookies: {
|
|
31
|
+
[cookieName: string]: string | undefined;
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
}
|
|
10
35
|
/**
|
|
11
36
|
* @description
|
|
12
37
|
* Direct reference to request object
|
|
13
38
|
*/
|
|
14
|
-
export declare const FASTIFY_REQUEST:
|
|
15
|
-
cookies: Record<string, string>;
|
|
16
|
-
} & {
|
|
39
|
+
export declare const FASTIFY_REQUEST: FastifyRequest<import("fastify").RouteGenericInterface, import("fastify").RawServerDefault, import("http").IncomingMessage, import("fastify").FastifySchema, import("fastify").FastifyTypeProviderDefault, unknown, import("fastify").FastifyBaseLogger, import("fastify/types/type-provider").ResolveFastifyRequestType<import("fastify").FastifyTypeProviderDefault, import("fastify").FastifySchema, import("fastify").RouteGenericInterface>> & {
|
|
17
40
|
__type?: "base token" | undefined;
|
|
18
41
|
};
|
|
19
42
|
/**
|
|
@@ -158,5 +181,4 @@ export interface EarlyHintsManager {
|
|
|
158
181
|
export declare const PAPI_FASTIFY_INIT_TOKEN: FASTIFY_APP_INIT_HANDLER & {
|
|
159
182
|
__type?: "multi token" | undefined;
|
|
160
183
|
};
|
|
161
|
-
export {};
|
|
162
184
|
//# sourceMappingURL=index.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tramvai/tokens-server-private",
|
|
3
|
-
"version": "4.41.
|
|
3
|
+
"version": "4.41.52",
|
|
4
4
|
"description": "Tramvai private tokens for @tramvai/module-server",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/index.es.js",
|
|
@@ -18,11 +18,12 @@
|
|
|
18
18
|
"watch": "tsc -w"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@tramvai/papi": "4.41.
|
|
21
|
+
"@tramvai/papi": "4.41.52"
|
|
22
22
|
},
|
|
23
23
|
"peerDependencies": {
|
|
24
24
|
"@tinkoff/dippy": "0.10.11",
|
|
25
|
-
"fastify": "^4.
|
|
25
|
+
"fastify": "^4.14.1",
|
|
26
|
+
"@fastify/cookie": "^8.3.0",
|
|
26
27
|
"tslib": "^2.4.0"
|
|
27
28
|
},
|
|
28
29
|
"devDependencies": {},
|