ocpp-ws-io 2.2.1 → 2.2.2-beta.1
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/adapters/redis.d.mts +2 -2
- package/dist/adapters/redis.d.ts +2 -2
- package/dist/context-Cy7YIKyU.d.mts +21 -0
- package/dist/context-DcTIzhq-.d.ts +21 -0
- package/dist/express.d.mts +70 -0
- package/dist/express.d.ts +70 -0
- package/dist/express.js +2 -0
- package/dist/express.mjs +2 -0
- package/dist/fastify.d.mts +37 -0
- package/dist/fastify.d.ts +37 -0
- package/dist/fastify.js +2 -0
- package/dist/fastify.mjs +2 -0
- package/dist/hono.d.mts +51 -0
- package/dist/hono.d.ts +51 -0
- package/dist/hono.js +2 -0
- package/dist/hono.mjs +2 -0
- package/dist/{index-Defn9aOS.d.mts → index-B9rTwvbn.d.mts} +1 -1
- package/dist/{index-BefjKqkS.d.ts → index-D5pJ3wS4.d.ts} +1 -1
- package/dist/index.d.mts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/nestjs.d.mts +169 -0
- package/dist/nestjs.d.ts +169 -0
- package/dist/nestjs.js +4826 -0
- package/dist/nestjs.mjs +4826 -0
- package/dist/plugins.d.mts +1 -1
- package/dist/plugins.d.ts +1 -1
- package/dist/{types-BHIHsj__.d.mts → types-xFfIgIuS.d.mts} +2 -2
- package/dist/{types-BHIHsj__.d.ts → types-xFfIgIuS.d.ts} +2 -2
- package/package.json +62 -1
- package/dist/browser.d.mts +0 -4982
- package/dist/browser.d.ts +0 -4982
package/dist/plugins.d.mts
CHANGED
package/dist/plugins.d.ts
CHANGED
|
@@ -5979,7 +5979,7 @@ interface BaseConnectionContext {
|
|
|
5979
5979
|
reject: (code?: number, message?: string) => never;
|
|
5980
5980
|
}
|
|
5981
5981
|
interface ConnectionContext extends BaseConnectionContext {
|
|
5982
|
-
/** Triggers the next middleware in the execution chain, optionally merging a payload into ctx.state */
|
|
5982
|
+
/** Triggers the next middleware in the execution chain, optionally merging a payload into ctx.state and then client.session in the chain*/
|
|
5983
5983
|
next: (payload?: Record<string, unknown>) => Promise<void>;
|
|
5984
5984
|
}
|
|
5985
5985
|
interface AuthContext<TSession = Record<string, unknown>> extends BaseConnectionContext {
|
|
@@ -5990,4 +5990,4 @@ interface AuthContext<TSession = Record<string, unknown>> extends BaseConnection
|
|
|
5990
5990
|
}
|
|
5991
5991
|
type ConnectionMiddleware = (ctx: ConnectionContext) => Promise<void> | void;
|
|
5992
5992
|
|
|
5993
|
-
export { type
|
|
5993
|
+
export { type ServerEvents as $, type AllMethodNames as A, MessageType as B, type CallOptions as C, type MiddlewareNext as D, type EventAdapterInterface as E, MiddlewareStack as F, type OCPP16Methods as G, type HandlerContext as H, type OCPP201Methods as I, type OCPP21Methods as J, type OCPPCall as K, type LoggerLike as L, type MiddlewareFunction as M, NOREPLY as N, OCPPServer as O, type OCPPCallError as P, type OCPPCallResult as Q, OCPPClient as R, type OCPPMessage as S, type OCPPMethodMap as T, type OCPPProtocolKey as U, Validator as V, OCPPRouter as W, type RateLimitOptions as X, type RouterConfig as Y, type SecurityEvent as Z, SecurityProfile as _, OCPPServerClient as a, type ServerOptions as a0, type SessionData as a1, type TLSOptions as a2, type TelemetryConfig as a3, type TypedEventEmitter as a4, type WildcardHandler as a5, createRouter as a6, createValidator as a7, type OCPPServerStats as b, type OCPPProtocol as c, type OCPPRequestType as d, type OCPPResponseType as e, type CloseOptions as f, type AuthCallback as g, type LoggingConfig as h, type MiddlewareContext as i, type OCPPPlugin as j, type ConnectionMiddleware as k, type AnyOCPPProtocol as l, type AuthAccept as m, type AuthContext as n, type CORSOptions as o, type CallHandler as p, type ClientEvents as q, type ClientOptions as r, type CompressionOptions as s, type ConnectionContext as t, ConnectionState as u, type HandshakeInfo as v, type ListenOptions as w, type MessageDirection as x, type MessageEventContext as y, type MessageEventPayload as z };
|
|
@@ -5979,7 +5979,7 @@ interface BaseConnectionContext {
|
|
|
5979
5979
|
reject: (code?: number, message?: string) => never;
|
|
5980
5980
|
}
|
|
5981
5981
|
interface ConnectionContext extends BaseConnectionContext {
|
|
5982
|
-
/** Triggers the next middleware in the execution chain, optionally merging a payload into ctx.state */
|
|
5982
|
+
/** Triggers the next middleware in the execution chain, optionally merging a payload into ctx.state and then client.session in the chain*/
|
|
5983
5983
|
next: (payload?: Record<string, unknown>) => Promise<void>;
|
|
5984
5984
|
}
|
|
5985
5985
|
interface AuthContext<TSession = Record<string, unknown>> extends BaseConnectionContext {
|
|
@@ -5990,4 +5990,4 @@ interface AuthContext<TSession = Record<string, unknown>> extends BaseConnection
|
|
|
5990
5990
|
}
|
|
5991
5991
|
type ConnectionMiddleware = (ctx: ConnectionContext) => Promise<void> | void;
|
|
5992
5992
|
|
|
5993
|
-
export { type
|
|
5993
|
+
export { type ServerEvents as $, type AllMethodNames as A, MessageType as B, type CallOptions as C, type MiddlewareNext as D, type EventAdapterInterface as E, MiddlewareStack as F, type OCPP16Methods as G, type HandlerContext as H, type OCPP201Methods as I, type OCPP21Methods as J, type OCPPCall as K, type LoggerLike as L, type MiddlewareFunction as M, NOREPLY as N, OCPPServer as O, type OCPPCallError as P, type OCPPCallResult as Q, OCPPClient as R, type OCPPMessage as S, type OCPPMethodMap as T, type OCPPProtocolKey as U, Validator as V, OCPPRouter as W, type RateLimitOptions as X, type RouterConfig as Y, type SecurityEvent as Z, SecurityProfile as _, OCPPServerClient as a, type ServerOptions as a0, type SessionData as a1, type TLSOptions as a2, type TelemetryConfig as a3, type TypedEventEmitter as a4, type WildcardHandler as a5, createRouter as a6, createValidator as a7, type OCPPServerStats as b, type OCPPProtocol as c, type OCPPRequestType as d, type OCPPResponseType as e, type CloseOptions as f, type AuthCallback as g, type LoggingConfig as h, type MiddlewareContext as i, type OCPPPlugin as j, type ConnectionMiddleware as k, type AnyOCPPProtocol as l, type AuthAccept as m, type AuthContext as n, type CORSOptions as o, type CallHandler as p, type ClientEvents as q, type ClientOptions as r, type CompressionOptions as s, type ConnectionContext as t, ConnectionState as u, type HandshakeInfo as v, type ListenOptions as w, type MessageDirection as x, type MessageEventContext as y, type MessageEventPayload as z };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ocpp-ws-io",
|
|
3
|
-
"version": "2.2.1",
|
|
3
|
+
"version": "2.2.2-beta.1",
|
|
4
4
|
"description": "OCPP RPC WebSocket client and server for OCPP 1.6J, 2.0.1, and 2.1. Type-safe TypeScript toolkit for EV charging, CSMS backends, Redis scaling, and protocol validation.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,6 +34,26 @@
|
|
|
34
34
|
"types": "./dist/plugins.d.ts",
|
|
35
35
|
"import": "./dist/plugins.mjs",
|
|
36
36
|
"require": "./dist/plugins.js"
|
|
37
|
+
},
|
|
38
|
+
"./express": {
|
|
39
|
+
"types": "./dist/express.d.ts",
|
|
40
|
+
"import": "./dist/express.mjs",
|
|
41
|
+
"require": "./dist/express.js"
|
|
42
|
+
},
|
|
43
|
+
"./nestjs": {
|
|
44
|
+
"types": "./dist/nestjs.d.ts",
|
|
45
|
+
"import": "./dist/nestjs.mjs",
|
|
46
|
+
"require": "./dist/nestjs.js"
|
|
47
|
+
},
|
|
48
|
+
"./fastify": {
|
|
49
|
+
"types": "./dist/fastify.d.ts",
|
|
50
|
+
"import": "./dist/fastify.mjs",
|
|
51
|
+
"require": "./dist/fastify.js"
|
|
52
|
+
},
|
|
53
|
+
"./hono": {
|
|
54
|
+
"types": "./dist/hono.d.ts",
|
|
55
|
+
"import": "./dist/hono.mjs",
|
|
56
|
+
"require": "./dist/hono.js"
|
|
37
57
|
}
|
|
38
58
|
},
|
|
39
59
|
"scripts": {
|
|
@@ -97,6 +117,38 @@
|
|
|
97
117
|
"dist"
|
|
98
118
|
],
|
|
99
119
|
"license": "MIT",
|
|
120
|
+
"peerDependencies": {
|
|
121
|
+
"@nestjs/common": "^10.0.0 || ^11.0.0",
|
|
122
|
+
"@nestjs/core": "^10.0.0 || ^11.0.0",
|
|
123
|
+
"express": "^4.18.0 || ^5.0.0",
|
|
124
|
+
"fastify": "^4.0.0 || ^5.0.0",
|
|
125
|
+
"fastify-plugin": "^4.0.0 || ^5.0.0",
|
|
126
|
+
"hono": "^4.0.0",
|
|
127
|
+
"reflect-metadata": "^0.2.2"
|
|
128
|
+
},
|
|
129
|
+
"peerDependenciesMeta": {
|
|
130
|
+
"@nestjs/common": {
|
|
131
|
+
"optional": true
|
|
132
|
+
},
|
|
133
|
+
"@nestjs/core": {
|
|
134
|
+
"optional": true
|
|
135
|
+
},
|
|
136
|
+
"express": {
|
|
137
|
+
"optional": true
|
|
138
|
+
},
|
|
139
|
+
"fastify": {
|
|
140
|
+
"optional": true
|
|
141
|
+
},
|
|
142
|
+
"fastify-plugin": {
|
|
143
|
+
"optional": true
|
|
144
|
+
},
|
|
145
|
+
"hono": {
|
|
146
|
+
"optional": true
|
|
147
|
+
},
|
|
148
|
+
"reflect-metadata": {
|
|
149
|
+
"optional": true
|
|
150
|
+
}
|
|
151
|
+
},
|
|
100
152
|
"dependencies": {
|
|
101
153
|
"ajv": "^8.18.0",
|
|
102
154
|
"ajv-formats": "^3.0.1",
|
|
@@ -104,10 +156,19 @@
|
|
|
104
156
|
"ws": "^8.19.0"
|
|
105
157
|
},
|
|
106
158
|
"devDependencies": {
|
|
159
|
+
"@hono/node-server": "^2.0.0",
|
|
160
|
+
"@nestjs/common": "^11.0.0",
|
|
161
|
+
"@nestjs/core": "^11.0.0",
|
|
162
|
+
"@nestjs/testing": "^11.1.19",
|
|
107
163
|
"@types/node": "^22.19.11",
|
|
108
164
|
"@types/ws": "^8.18.1",
|
|
109
165
|
"@vitest/coverage-v8": "^3.2.4",
|
|
166
|
+
"express": "^5.2.1",
|
|
167
|
+
"fastify": "^5.2.1",
|
|
168
|
+
"fastify-plugin": "^5.0.1",
|
|
169
|
+
"hono": "^4.12.15",
|
|
110
170
|
"ioredis-mock": "^8.13.1",
|
|
171
|
+
"reflect-metadata": "^0.2.2",
|
|
111
172
|
"tsup": "^8.5.1",
|
|
112
173
|
"typescript": "^5.9.3",
|
|
113
174
|
"vitest": "^3.2.4"
|