@fonoster/apiserver 0.62.0 → 0.63.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/config/schema.d.ts +3 -2
- package/dist/config/schema.js +4 -4
- package/dist/core/routrConfig.d.ts +1 -0
- package/dist/core/routrConfig.js +2 -1
- package/dist/envs.d.ts +2 -0
- package/dist/envs.js +4 -2
- package/package.json +13 -13
package/dist/config/schema.d.ts
CHANGED
|
@@ -161,8 +161,9 @@ declare const fonosterConfigSchema: z.ZodObject<{
|
|
|
161
161
|
}>>;
|
|
162
162
|
}, z.core.$strip>>;
|
|
163
163
|
}, z.core.$strip>>;
|
|
164
|
-
routr: z.
|
|
164
|
+
routr: z.ZodObject<{
|
|
165
165
|
apiEndpoint: z.ZodDefault<z.ZodString>;
|
|
166
|
+
apiKey: z.ZodString;
|
|
166
167
|
sipProxy: z.ZodDefault<z.ZodString>;
|
|
167
168
|
roomrPeer: z.ZodPrefault<z.ZodObject<{
|
|
168
169
|
aor: z.ZodDefault<z.ZodString>;
|
|
@@ -170,7 +171,7 @@ declare const fonosterConfigSchema: z.ZodObject<{
|
|
|
170
171
|
username: z.ZodDefault<z.ZodString>;
|
|
171
172
|
password: z.ZodOptional<z.ZodString>;
|
|
172
173
|
}, z.core.$strip>>;
|
|
173
|
-
}, z.core.$strip
|
|
174
|
+
}, z.core.$strip>;
|
|
174
175
|
nats: z.ZodObject<{
|
|
175
176
|
url: z.ZodString;
|
|
176
177
|
user: z.ZodOptional<z.ZodString>;
|
package/dist/config/schema.js
CHANGED
|
@@ -275,9 +275,10 @@ const fonosterConfigSchema = zod_1.z
|
|
|
275
275
|
})
|
|
276
276
|
.prefault({}),
|
|
277
277
|
features: featuresSchema,
|
|
278
|
-
routr: zod_1.z
|
|
279
|
-
.object({
|
|
278
|
+
routr: zod_1.z.object({
|
|
280
279
|
apiEndpoint: zod_1.z.string().default("routr:51907"),
|
|
280
|
+
/** Sent as "authorization: Bearer <key>" on every Data API call (spec.data.apiKeys). */
|
|
281
|
+
apiKey: zod_1.z.string().min(1),
|
|
281
282
|
/**
|
|
282
283
|
* host:port of Routr's SIP listener: API-originated calls are dialed through it
|
|
283
284
|
* (CreateCall's to.proxy), as the roomr peer below (to.auth).
|
|
@@ -295,8 +296,7 @@ const fonosterConfigSchema = zod_1.z
|
|
|
295
296
|
password: zod_1.z.string().optional()
|
|
296
297
|
})
|
|
297
298
|
.prefault({})
|
|
298
|
-
})
|
|
299
|
-
.prefault({}),
|
|
299
|
+
}),
|
|
300
300
|
// user/password: the apiserver's NATS user when the server has per-service users
|
|
301
301
|
// (add-platform 4.1); password is usually a secret:// reference.
|
|
302
302
|
nats: zod_1.z.object({
|
package/dist/core/routrConfig.js
CHANGED
|
@@ -26,7 +26,8 @@ const sdk_1 = __importDefault(require("@routr/sdk"));
|
|
|
26
26
|
const envs_1 = require("../envs");
|
|
27
27
|
const routrConfig = {
|
|
28
28
|
endpoint: envs_1.ROUTR_API_ENDPOINT,
|
|
29
|
-
insecure: true
|
|
29
|
+
insecure: true,
|
|
30
|
+
apiKey: envs_1.ROUTR_API_KEY
|
|
30
31
|
};
|
|
31
32
|
exports.routrConfig = routrConfig;
|
|
32
33
|
let numbers;
|
package/dist/envs.d.ts
CHANGED
|
@@ -66,6 +66,8 @@ export declare const NATS: {
|
|
|
66
66
|
inboxPrefix?: string;
|
|
67
67
|
};
|
|
68
68
|
export declare const ROUTR_API_ENDPOINT: string;
|
|
69
|
+
/** Routr's Data API key (spec.data.apiKeys), sent as a Bearer token on every call. */
|
|
70
|
+
export declare const ROUTR_API_KEY: string;
|
|
69
71
|
export declare const ROUTR_ROOMR_PEER: {
|
|
70
72
|
aor: string;
|
|
71
73
|
name: string;
|
package/dist/envs.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.
|
|
5
|
-
exports.DOMAIN_NAMES_ROOT = exports.TRUNK_NAMES_ROOT = exports.SIP_ROOT = exports.PSTN_ROOT = exports.DOMAIN = exports.REGIONS = exports.WEBHOOKS = exports.SESSION_APPS = exports.CALL_RECORDS = exports.TWILIO_PHONE_NUMBER = exports.TWILIO_AUTH_TOKEN = exports.TWILIO_ACCOUNT_SID = void 0;
|
|
4
|
+
exports.SMTP_SENDER = exports.SMTP_SECURE = exports.SMTP_PORT = exports.SMTP_HOST = exports.SMTP_AUTH_USER = exports.SMTP_AUTH_PASS = exports.ROUTR_SIP_PROXY = exports.ROUTR_ROOMR_PEER = exports.ROUTR_API_KEY = exports.ROUTR_API_ENDPOINT = exports.NATS = exports.NATS_CONNECTION = exports.NATS_URL = exports.EVALUATIONS = exports.AUTHZ_SERVICE_METHODS = exports.AUTHZ_SERVICE_PORT = exports.AUTHZ_SERVICE_HOST = exports.AUTHZ_SERVICE_ENABLED = exports.BILLING_ADDRESS = exports.BILLING_ENABLED = exports.IDENTITY_DATABASE_URL = exports.IDENTITY_WORKSPACE_INVITE_URL = exports.IDENTITY_WORKSPACE_INVITE_EXPIRATION = exports.IDENTITY_WORKSPACE_INVITE_FAIL_URL = exports.IDENTITY_REFRESH_TOKEN_EXPIRES_IN = exports.IDENTITY_PUBLIC_KEY = exports.IDENTITY_PRIVATE_KEY = exports.IDENTITY_OAUTH2_GITHUB_CLIENT_SECRET = exports.IDENTITY_OAUTH2_GITHUB_CLIENT_ID = exports.IDENTITY_OAUTH2_GITHUB_ENABLED = exports.IDENTITY_TWO_FACTOR_AUTHENTICATION_REQUIRED = exports.IDENTITY_CONTACT_VERIFICATION_REQUIRED = exports.IDENTITY_ISSUER = exports.IDENTITY_ID_TOKEN_EXPIRES_IN = exports.IDENTITY_AUDIENCE = exports.IDENTITY_ACCESS_TOKEN_EXPIRES_IN = exports.HTTP_BRIDGE_PORT = exports.DEFAULT_NATS_QUEUE_GROUP = exports.DATABASE_URL = exports.CLOAK_ENCRYPTION_KEY = exports.NODE_HEARTBEAT_WILDCARD = exports.MEDIA_CALL_EVENTS_WILDCARD = exports.mediaCallEventsSubject = exports.CALL_EVENTS_WILDCARD = exports.callEventsSubject = exports.CALLS_CREATE_SUBJECT = exports.APP_URL = exports.APISERVER_SIGNALING_SERVER = exports.APISERVER_HOST = exports.APISERVER_BIND_ADDR = void 0;
|
|
5
|
+
exports.DOMAIN_NAMES_ROOT = exports.TRUNK_NAMES_ROOT = exports.SIP_ROOT = exports.PSTN_ROOT = exports.DOMAIN = exports.REGIONS = exports.WEBHOOKS = exports.SESSION_APPS = exports.CALL_RECORDS = exports.TWILIO_PHONE_NUMBER = exports.TWILIO_AUTH_TOKEN = exports.TWILIO_ACCOUNT_SID = exports.TEMPLATES_DIR = void 0;
|
|
6
6
|
/**
|
|
7
7
|
* Copyright (C) 2025 by Fonoster Inc (https://fonoster.com)
|
|
8
8
|
* http://github.com/fonoster/fonoster
|
|
@@ -94,6 +94,8 @@ exports.NATS_CONNECTION = config.nats;
|
|
|
94
94
|
/** nats.js connect options: the URL plus the apiserver's NATS user, when set (add-platform 4.1). */
|
|
95
95
|
exports.NATS = (0, common_1.natsConnectOptions)(config.nats);
|
|
96
96
|
exports.ROUTR_API_ENDPOINT = config.routr.apiEndpoint;
|
|
97
|
+
/** Routr's Data API key (spec.data.apiKeys), sent as a Bearer token on every call. */
|
|
98
|
+
exports.ROUTR_API_KEY = config.routr.apiKey;
|
|
97
99
|
// The roomr peer every app-linked number points at (add-roomr 4.1)
|
|
98
100
|
exports.ROUTR_ROOMR_PEER = config.routr.roomrPeer;
|
|
99
101
|
/** Routr's SIP address: API-originated calls are dialed through it (Roomr CreateCall). */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fonoster/apiserver",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.63.0",
|
|
4
4
|
"description": "APIServer for Fonoster",
|
|
5
5
|
"author": "Pedro Sanders <psanders@fonoster.com>",
|
|
6
6
|
"homepage": "https://github.com/fonoster/fonoster#readme",
|
|
@@ -23,18 +23,18 @@
|
|
|
23
23
|
"fonoster-owner": "./dist/bin/owner.js"
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@fonoster/authz": "^0.
|
|
27
|
-
"@fonoster/autopilot": "^0.
|
|
28
|
-
"@fonoster/callrecord": "^0.
|
|
29
|
-
"@fonoster/common": "^0.
|
|
30
|
-
"@fonoster/identity": "^0.
|
|
31
|
-
"@fonoster/logger": "^0.
|
|
32
|
-
"@fonoster/sipnet": "^0.
|
|
33
|
-
"@fonoster/types": "^0.
|
|
26
|
+
"@fonoster/authz": "^0.63.0",
|
|
27
|
+
"@fonoster/autopilot": "^0.63.0",
|
|
28
|
+
"@fonoster/callrecord": "^0.63.0",
|
|
29
|
+
"@fonoster/common": "^0.63.0",
|
|
30
|
+
"@fonoster/identity": "^0.63.0",
|
|
31
|
+
"@fonoster/logger": "^0.63.0",
|
|
32
|
+
"@fonoster/sipnet": "^0.63.0",
|
|
33
|
+
"@fonoster/types": "^0.63.0",
|
|
34
34
|
"@grpc/grpc-js": "~1.14.6",
|
|
35
35
|
"@prisma/client": "^6.19.1",
|
|
36
|
-
"@routr/common": "^
|
|
37
|
-
"@routr/sdk": "^
|
|
36
|
+
"@routr/common": "^3.0.0",
|
|
37
|
+
"@routr/sdk": "^3.0.0",
|
|
38
38
|
"express": "^5.0.1",
|
|
39
39
|
"grpc-health-check": "^2.0.1",
|
|
40
40
|
"jsonwebtoken": "^9.0.2",
|
|
@@ -62,13 +62,13 @@
|
|
|
62
62
|
"url": "https://github.com/fonoster/fonoster/issues"
|
|
63
63
|
},
|
|
64
64
|
"devDependencies": {
|
|
65
|
-
"@fonoster/ops": "^0.
|
|
65
|
+
"@fonoster/ops": "^0.63.0",
|
|
66
66
|
"@types/express": "^5.0.6",
|
|
67
67
|
"@types/jsonwebtoken": "^9.0.10",
|
|
68
68
|
"@types/uuid": "^10.0.0",
|
|
69
69
|
"@types/validator": "^13.15.10"
|
|
70
70
|
},
|
|
71
|
-
"gitHead": "
|
|
71
|
+
"gitHead": "23c2f96ed0fdc2ad3961328a937388fc26dd57ce",
|
|
72
72
|
"prisma": {
|
|
73
73
|
"seed": "tsx src/core/seed.ts"
|
|
74
74
|
}
|