@based/functions 3.2.3 → 3.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/auth.d.ts +2 -1
- package/dist/client.d.ts +6 -4
- package/dist/client.js +1 -0
- package/dist/client.js.map +1 -1
- package/dist/client_original.d.ts +6 -4
- package/dist/context.d.ts +10 -8
- package/dist/context.js.map +1 -1
- package/dist/functions.d.ts +9 -9
- package/dist/functions.js +3 -2
- package/dist/functions.js.map +1 -1
- package/dist/stream.d.ts +0 -5
- package/dist/stream.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -0
- package/package.json +8 -8
package/dist/auth.d.ts
CHANGED
|
@@ -3,12 +3,13 @@ import { HttpRequest } from './uws.js';
|
|
|
3
3
|
import { Context, WebSocketSession, HttpSession } from './context.js';
|
|
4
4
|
export type AuthState = {
|
|
5
5
|
token?: string;
|
|
6
|
-
userId?: string;
|
|
6
|
+
userId?: string | number;
|
|
7
7
|
refreshToken?: string;
|
|
8
8
|
error?: string;
|
|
9
9
|
persistent?: boolean;
|
|
10
10
|
type?: string;
|
|
11
11
|
t?: 0 | 1;
|
|
12
|
+
v?: 2;
|
|
12
13
|
};
|
|
13
14
|
export type Authorize = (based: BasedFunctionClient, context: Context<HttpSession | WebSocketSession>, name: string, // name as generic dope
|
|
14
15
|
payload?: any) => Promise<boolean>;
|
package/dist/client.d.ts
CHANGED
|
@@ -3,16 +3,18 @@ import { BasedChannel } from './channel.js';
|
|
|
3
3
|
import { Context } from './context.js';
|
|
4
4
|
import { BasedQuery } from './query.js';
|
|
5
5
|
import { StreamFunctionOpts } from './stream.js';
|
|
6
|
-
import {
|
|
6
|
+
import type { DbClient } from '@based/db';
|
|
7
7
|
export declare abstract class BasedFunctionClient {
|
|
8
8
|
server: any;
|
|
9
|
-
db:
|
|
9
|
+
db: DbClient;
|
|
10
|
+
dbs: Record<string, DbClient>;
|
|
10
11
|
abstract call(name: string, payload?: any, ctx?: Context): Promise<any>;
|
|
11
|
-
abstract query(name: string, payload?: any
|
|
12
|
+
abstract query(name: string, payload?: any, ctx?: {
|
|
13
|
+
[key: string]: any;
|
|
14
|
+
} | Context): BasedQuery;
|
|
12
15
|
abstract channel(name: string, payload?: any): BasedChannel;
|
|
13
16
|
abstract stream(name: string, payload: StreamFunctionOpts, ctx?: Context): Promise<any>;
|
|
14
17
|
abstract sendAuthState(ctx: Context, authState: AuthState): void;
|
|
15
|
-
abstract geo(ctx: Context): Promise<Geo>;
|
|
16
18
|
abstract renewAuthState(ctx: Context, authState?: AuthState): Promise<AuthState>;
|
|
17
19
|
}
|
|
18
20
|
export type QueryMap = {
|
package/dist/client.js
CHANGED
package/dist/client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAQA,MAAM,OAAgB,mBAAmB;IACvC,MAAM,CAAK;IAEX,EAAE,CAAU;IACZ,GAAG,CAA0B;CA0B9B"}
|
|
@@ -3,16 +3,18 @@ import { BasedChannel } from './channel.js';
|
|
|
3
3
|
import { Context } from './context.js';
|
|
4
4
|
import { BasedQuery } from './query.js';
|
|
5
5
|
import { StreamFunctionOpts } from './stream.js';
|
|
6
|
-
import {
|
|
6
|
+
import type { DbClient } from '@based/db';
|
|
7
7
|
export declare abstract class BasedFunctionClient {
|
|
8
8
|
server: any;
|
|
9
|
-
db:
|
|
9
|
+
db: DbClient;
|
|
10
|
+
dbs: Record<string, DbClient>;
|
|
10
11
|
abstract call(name: string, payload?: any, ctx?: Context): Promise<any>;
|
|
11
|
-
abstract query(name: string, payload?: any
|
|
12
|
+
abstract query(name: string, payload?: any, ctx?: {
|
|
13
|
+
[key: string]: any;
|
|
14
|
+
} | Context): BasedQuery;
|
|
12
15
|
abstract channel(name: string, payload?: any): BasedChannel;
|
|
13
16
|
abstract stream(name: string, payload: StreamFunctionOpts, ctx?: Context): Promise<any>;
|
|
14
17
|
abstract sendAuthState(ctx: Context, authState: AuthState): void;
|
|
15
|
-
abstract geo(ctx: Context): Promise<Geo>;
|
|
16
18
|
abstract renewAuthState(ctx: Context, authState?: AuthState): Promise<AuthState>;
|
|
17
19
|
}
|
|
18
20
|
export type QueryMap = {
|
package/dist/context.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { parseQuery } from '@
|
|
1
|
+
import { parseQuery } from '@based/utils';
|
|
2
2
|
import { AuthState } from './auth.js';
|
|
3
3
|
import { WebSocket, HttpRequest, HttpResponse } from './uws.js';
|
|
4
4
|
import { BasedFunctionClient } from './client.js';
|
|
5
|
-
import { StreamPayload } from './functions.js';
|
|
5
|
+
import { BasedRoute, StreamPayload } from './functions.js';
|
|
6
6
|
export type WebSocketSession = {
|
|
7
7
|
state?: any;
|
|
8
8
|
query: string;
|
|
@@ -17,20 +17,22 @@ export type WebSocketSession = {
|
|
|
17
17
|
unauthorizedObs?: Set<{
|
|
18
18
|
id: number;
|
|
19
19
|
checksum: number;
|
|
20
|
-
|
|
20
|
+
route: BasedRoute<'query'>;
|
|
21
21
|
payload: any;
|
|
22
22
|
}>;
|
|
23
|
+
unauthorizedChannels?: Set<{
|
|
24
|
+
id: number;
|
|
25
|
+
route: BasedRoute<'channel'>;
|
|
26
|
+
payload: any;
|
|
27
|
+
}>;
|
|
28
|
+
attachedCtxObs?: Set<number>;
|
|
23
29
|
streams?: {
|
|
24
30
|
[reqId: string]: StreamPayload;
|
|
25
31
|
};
|
|
26
32
|
headers: {
|
|
27
33
|
[key: string]: string;
|
|
28
34
|
};
|
|
29
|
-
|
|
30
|
-
id: number;
|
|
31
|
-
name: string;
|
|
32
|
-
payload: any;
|
|
33
|
-
}>;
|
|
35
|
+
v?: 2;
|
|
34
36
|
c?: Context<WebSocketSession>;
|
|
35
37
|
ws?: BasedWebSocket;
|
|
36
38
|
};
|
package/dist/context.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.js","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"context.js","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":"AAgHA,MAAM,CAAC,MAAM,aAAa,GAAG,CAC3B,GAAqB,EACQ,EAAE;IAC/B,IAAI,KAAK,IAAI,GAAG,EAAE,OAAO,EAAE,CAAC;QAC1B,OAAO,IAAI,CAAA;IACb,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,WAAW,GAAG,CACzB,GAAqB,EACa,EAAE;IACpC,IAAI,GAAG,CAAC,OAAO,IAAI,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC;QAC5C,OAAO,IAAI,CAAA;IACb,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,eAAe,GAAG,CAC7B,GAAqB,EAC2B,EAAE;IAClD,IAAI,GAAG,CAAC,OAAO,IAAI,CAAC,WAAW,CAAC,GAAG,CAAC,OAAO,CAAC,IAAI,aAAa,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,EAAE,CAAC;QAC5E,OAAO,IAAI,CAAA;IACb,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,aAAa,GAAG,CAC3B,OAA4B,EACJ,EAAE;IAC1B,IAAI,OAAO,IAAI,KAAK,IAAI,OAAO,EAAE,CAAC;QAChC,OAAO,IAAI,CAAA;IACb,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC,CAAA;AAED,MAAM,CAAC,MAAM,WAAW,GAAG,CACzB,OAA4B,EACC,EAAE;IAC/B,IAAI,OAAO,IAAI,MAAM,IAAI,OAAO,EAAE,CAAC;QACjC,OAAO,IAAI,CAAA;IACb,CAAC;IACD,OAAO,KAAK,CAAA;AACd,CAAC,CAAA"}
|
package/dist/functions.d.ts
CHANGED
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
3
1
|
import type { Required } from 'utility-types';
|
|
4
2
|
import { Context, HttpSession } from './context.js';
|
|
5
3
|
import { BasedFunctionClient } from './client.js';
|
|
@@ -41,7 +39,7 @@ export type StreamPayload<P = any> = {
|
|
|
41
39
|
seqId?: number;
|
|
42
40
|
};
|
|
43
41
|
export type BasedStreamFunction<P = any, K = any> = BasedFunction<StreamPayload<P>, K>;
|
|
44
|
-
export type BasedQueryFunction<P = any, K = any> = ((based: BasedFunctionClient, payload: P, update: ObservableUpdateFunction<K>, error: ObserveErrorListener) => Promise<() => void>) | ((based: BasedFunctionClient, payload: P, update: ObservableUpdateFunction<K>, error: ObserveErrorListener) => () => void);
|
|
42
|
+
export type BasedQueryFunction<P = any, K = any> = ((based: BasedFunctionClient, payload: P, update: ObservableUpdateFunction<K>, error: ObserveErrorListener, ctx?: any) => Promise<() => void>) | ((based: BasedFunctionClient, payload: P, update: ObservableUpdateFunction<K>, error: ObserveErrorListener, ctx?: any) => () => void);
|
|
45
43
|
export type BasedChannelFunction<P = any, K = any> = (based: BasedFunctionClient, payload: P, id: number, update: ChannelMessageFunction<K>, error: (err?: any) => void) => () => void;
|
|
46
44
|
export type BasedChannelPublishFunction<P = any, M = any> = (based: BasedFunctionClient, payload: P, message: M, id: number, ctx: Context) => void;
|
|
47
45
|
export type ChannelMessageFunction<M = any> = (message: M) => void;
|
|
@@ -164,7 +162,7 @@ type FunctionConfigSharedComplete = Required<FunctionConfigShared, 'maxPayloadSi
|
|
|
164
162
|
tokens?: PathToken[];
|
|
165
163
|
};
|
|
166
164
|
export type BasedFunctionTypes = 'channel' | 'query' | 'function' | 'stream' | 'app' | 'job' | 'http';
|
|
167
|
-
type BasedChannelFunctionConfig = {
|
|
165
|
+
export type BasedChannelFunctionConfig = {
|
|
168
166
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
169
167
|
type: 'channel';
|
|
170
168
|
/** Channel subscriber
|
|
@@ -199,19 +197,19 @@ type BasedChannelFunctionConfig = {
|
|
|
199
197
|
/** Throttle amount of outgoing messages, in milliseconds */
|
|
200
198
|
throttle?: number;
|
|
201
199
|
};
|
|
202
|
-
type BasedCallFunctionConfig = {
|
|
200
|
+
export type BasedCallFunctionConfig = {
|
|
203
201
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
204
202
|
type: 'function';
|
|
205
203
|
fn?: BasedFunction;
|
|
206
204
|
httpResponse?: HttpResponse;
|
|
207
205
|
};
|
|
208
|
-
type BasedHttpFunctionConfig = {
|
|
206
|
+
export type BasedHttpFunctionConfig = {
|
|
209
207
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
210
208
|
type: 'http';
|
|
211
209
|
path: string;
|
|
212
210
|
fn: BasedHttpFunction;
|
|
213
211
|
};
|
|
214
|
-
type BasedQueryFunctionConfig = {
|
|
212
|
+
export type BasedQueryFunctionConfig = {
|
|
215
213
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
216
214
|
type: 'query';
|
|
217
215
|
fn?: BasedQueryFunction;
|
|
@@ -220,13 +218,15 @@ type BasedQueryFunctionConfig = {
|
|
|
220
218
|
closeAfterIdleTime?: number;
|
|
221
219
|
/** Throttle amount of outgoing messages, in milliseconds */
|
|
222
220
|
throttle?: number;
|
|
221
|
+
/** Bind this query function to specific paths in clients ctx */
|
|
222
|
+
ctx?: string[];
|
|
223
223
|
};
|
|
224
|
-
type BasedStreamFunctionConfig = {
|
|
224
|
+
export type BasedStreamFunctionConfig = {
|
|
225
225
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
226
226
|
type: 'stream';
|
|
227
227
|
fn: BasedStreamFunction;
|
|
228
228
|
};
|
|
229
|
-
type BasedAppFunctionConfig = {
|
|
229
|
+
export type BasedAppFunctionConfig = {
|
|
230
230
|
/** Function type `app, http, channel, function, query, stream, authorize, job` */
|
|
231
231
|
type: 'app';
|
|
232
232
|
main: string;
|
package/dist/functions.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
export function isBasedRoute(type, route) {
|
|
2
|
-
|
|
2
|
+
const isBasedroute = route &&
|
|
3
3
|
typeof route === 'object' &&
|
|
4
4
|
route.type === type &&
|
|
5
|
-
typeof route.name === 'string'
|
|
5
|
+
typeof route.name === 'string';
|
|
6
|
+
return isBasedroute;
|
|
6
7
|
}
|
|
7
8
|
export function isAnyBasedRoute(route) {
|
|
8
9
|
return (route &&
|
package/dist/functions.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"functions.js","sourceRoot":"","sources":["../src/functions.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"functions.js","sourceRoot":"","sources":["../src/functions.ts"],"names":[],"mappings":"AAkaA,MAAM,UAAU,YAAY,CAC1B,IAAO,EACP,KAAU;IAEV,MAAM,YAAY,GAChB,KAAK;QACL,OAAO,KAAK,KAAK,QAAQ;QACzB,KAAK,CAAC,IAAI,KAAK,IAAI;QACnB,OAAO,KAAK,CAAC,IAAI,KAAK,QAAQ,CAAA;IAChC,OAAO,YAAY,CAAA;AACrB,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,KAAU;IACxC,OAAO,CACL,KAAK;QACL,OAAO,KAAK,KAAK,QAAQ;QACzB,CAAC,KAAK,CAAC,IAAI,KAAK,SAAS;YACvB,KAAK,CAAC,IAAI,KAAK,OAAO;YACtB,KAAK,CAAC,IAAI,KAAK,UAAU;YACzB,KAAK,CAAC,IAAI,KAAK,MAAM;YACrB,KAAK,CAAC,IAAI,KAAK,QAAQ,CAAC;QAC1B,OAAO,KAAK,CAAC,IAAI,KAAK,QAAQ,CAC/B,CAAA;AACH,CAAC;AAED,MAAM,UAAU,qBAAqB,CACnC,IAAO,EACP,MAAW;IAEX,OAAO,YAAY,CAAC,IAAI,EAAE,MAAM,CAAC,CAAA;AACnC,CAAC;AAED,MAAM,UAAU,wBAAwB,CACtC,MAAW;IAEX,OAAO,eAAe,CAAC,MAAM,CAAC,CAAA;AAChC,CAAC"}
|
package/dist/stream.d.ts
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
3
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
4
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
5
|
-
/// <reference types="node" resolution-mode="require"/>
|
|
6
1
|
import { Duplex, Readable } from "node:stream";
|
|
7
2
|
import util from "node:util";
|
|
8
3
|
export declare class BasedDataStream extends Duplex {
|
package/dist/stream.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stream.js","sourceRoot":"","sources":["../src/stream.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,IAAI,MAAM,WAAW,CAAC;AAE7B,MAAM,OAAO,eAAgB,SAAQ,MAAM;IAClC,IAAI,GAAW,CAAC,CAAC;IACjB,MAAM,GAAY,KAAK,CAAC;IACxB,aAAa,GAAW,CAAC,CAAC;IAC1B,YAAY,CAAiB;IAEpC,YAAY,IAAY;QACtB,KAAK,EAAE,CAAC;QACR,IAAI,CAAC,IAAI,GAAG,IAAI,CAAC;QAEjB,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,GAAG,EAAE;YACpB,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;QACrB,CAAC,CAAC,CAAC;QAEH,IAAI,CAAC,EAAE,CAAC,QAAQ,EAAE,GAAG,EAAE;YACrB,IAAI,CAAC,MAAM,GAAG,KAAK,CAAC;QACtB,CAAC,CAAC,CAAC;QAEH,IAAI,CAAC,IAAI,CAAC,UAAU,EAAE,CAAC,CAAC,CAAC;IAC3B,CAAC;IAEQ,KAAK,K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AAC;gBAChC,GAAG,CACJ,KAAK,EAAE,GAAG,CAAC;QACd,CAAC;aAAM,CAAC;YACN,OAAO,eAAe,CAAC;QACzB,CAAC;IACH,CAAC;CACF;AA8BD,MAAM,CAAC,MAAM,oBAAoB,GAAG,CAClC,IAAmD,EACrB,EAAE;IAChC,OAAO,IAAI,CAAC,QAAQ,YAAY,MAAM,IAAI,IAAI,CAAC,QAAQ,YAAY,QAAQ,CAAC;AAC9E,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"root":["../src/auth.ts","../src/channel.ts","../src/client.ts","../src/context.ts","../src/functions.ts","../src/geo.ts","../src/index.ts","../src/query.ts","../src/stream.ts","../src/uws.d.ts"],"version":"5.9.2"}
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@based/functions",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.3.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
|
-
"files":[
|
|
7
|
+
"files": [
|
|
8
8
|
"dist"
|
|
9
9
|
],
|
|
10
10
|
"scripts": {
|
|
@@ -13,17 +13,17 @@
|
|
|
13
13
|
"clean:ts:before": "rm -rf ./dist ./tsconfig.tsbuildinfo || true",
|
|
14
14
|
"build": "npm run clean:ts:before && npx tsc -b && npm run copy:uws && npm run copy:client",
|
|
15
15
|
"watch": "npx tsc --watch",
|
|
16
|
-
"clean": "
|
|
16
|
+
"clean": "rm -rf ./dist ./node_modules"
|
|
17
17
|
},
|
|
18
18
|
"sideEffects": false,
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@
|
|
21
|
-
"
|
|
20
|
+
"@based/db": "^0.1.1",
|
|
21
|
+
"@based/utils": "^1.0.0",
|
|
22
|
+
"utility-types": "^3.10.0",
|
|
23
|
+
"arktype": "^2.1.20"
|
|
22
24
|
},
|
|
23
25
|
"devDependencies": {
|
|
24
|
-
"
|
|
25
|
-
"ts-node": "10.9.1",
|
|
26
|
-
"typescript": "^4.3.5"
|
|
26
|
+
"ts-node": "10.9.1"
|
|
27
27
|
},
|
|
28
28
|
"peerDependencies": {
|
|
29
29
|
"esbuild": "*"
|