@bwi-mentorspaces/application-utils-npm 0.0.6 → 0.0.7
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/chat/index.d.ts +36 -36
- package/chat/index.js +58 -58
- package/chat/stream/enum/index.d.ts +33 -27
- package/chat/stream/enum/index.js +41 -34
- package/chat/stream/enum/index.js.map +1 -1
- package/chat/stream/index.d.ts +9 -9
- package/chat/stream/index.js +17 -17
- package/chat/stream/models/_/channel.data.d.ts +19 -19
- package/chat/stream/models/_/channel.data.js +2 -2
- package/chat/stream/models/_/channel.member.d.ts +14 -14
- package/chat/stream/models/_/channel.member.js +11 -11
- package/chat/stream/models/_/channel.response.d.ts +8 -8
- package/chat/stream/models/_/channel.response.js +2 -2
- package/chat/stream/models/_/event.data.d.ts +16 -0
- package/chat/stream/models/_/event.data.js +4 -0
- package/chat/stream/models/_/event.data.js.map +1 -0
- package/chat/stream/models/_/message.response.d.ts +8 -8
- package/chat/stream/models/_/message.response.js +2 -2
- package/chat/stream/models/_/stream.config.d.ts +22 -22
- package/chat/stream/models/_/stream.config.js +2 -2
- package/chat/stream/models/_/user.response.d.ts +8 -8
- package/chat/stream/models/_/user.response.js +2 -2
- package/chat/stream/models/index.d.ts +9 -7
- package/chat/stream/models/index.js +5 -5
- package/chat/stream/models/index.js.map +1 -1
- package/chat/stream/stream.api.d.ts +63 -63
- package/chat/stream/stream.api.js +76 -76
- package/chat/stream/stream.auth.d.ts +70 -70
- package/chat/stream/stream.auth.js +80 -80
- package/chat/stream/stream.base.d.ts +56 -56
- package/chat/stream/stream.base.js +93 -93
- package/chat/stream/stream.channel.d.ts +132 -118
- package/chat/stream/stream.channel.js +306 -285
- package/chat/stream/stream.channel.js.map +1 -1
- package/chat/stream/stream.error.d.ts +19 -19
- package/chat/stream/stream.error.js +17 -17
- package/chat/stream/stream.member.d.ts +75 -75
- package/chat/stream/stream.member.js +175 -175
- package/chat/stream/stream.message.d.ts +59 -59
- package/chat/stream/stream.message.js +112 -112
- package/chat/stream/stream.user.d.ts +49 -49
- package/chat/stream/stream.user.js +90 -90
- package/core/_/api-error.d.ts +24 -24
- package/core/_/api-error.js +21 -21
- package/core/_/api-response.d.ts +25 -25
- package/core/_/api-response.js +21 -21
- package/core/_/cors-headers.d.ts +16 -16
- package/core/_/cors-headers.js +32 -32
- package/core/_/model.d.ts +39 -31
- package/core/_/model.js +2 -2
- package/core/_/service-request.d.ts +66 -66
- package/core/_/service-request.js +104 -104
- package/core/_/service-request.js.map +1 -1
- package/core/index.d.ts +10 -10
- package/core/index.js +11 -11
- package/deployment/_/serverless.d.ts +26 -26
- package/deployment/_/serverless.js +43 -43
- package/deployment/index.d.ts +2 -2
- package/deployment/index.js +5 -5
- package/endpoint-test-factory/_/test-factory.d.ts +45 -45
- package/endpoint-test-factory/_/test-factory.js +91 -91
- package/endpoint-test-factory/index.d.ts +2 -2
- package/endpoint-test-factory/index.js +5 -5
- package/enums/index.d.ts +92 -92
- package/enums/index.js +2 -2
- package/meet/index.d.ts +36 -36
- package/meet/index.js +58 -58
- package/meet/twilio/enum/index.d.ts +6 -6
- package/meet/twilio/enum/index.js +10 -10
- package/meet/twilio/index.d.ts +5 -5
- package/meet/twilio/index.js +11 -11
- package/meet/twilio/models/_/room.data.d.ts +6 -6
- package/meet/twilio/models/_/room.data.js +2 -2
- package/meet/twilio/models/_/twilio.config.d.ts +29 -29
- package/meet/twilio/models/_/twilio.config.js +2 -2
- package/meet/twilio/models/index.d.ts +3 -3
- package/meet/twilio/models/index.js +2 -2
- package/meet/twilio/twilio.api.d.ts +28 -28
- package/meet/twilio/twilio.api.js +45 -45
- package/meet/twilio/twilio.auth.d.ts +55 -55
- package/meet/twilio/twilio.auth.js +83 -83
- package/meet/twilio/twilio.base.d.ts +41 -41
- package/meet/twilio/twilio.base.js +53 -53
- package/meet/twilio/twilio.room.d.ts +46 -46
- package/meet/twilio/twilio.room.js +124 -124
- package/package.json +57 -57
- package/swagger/_/swagger.config.d.ts +21 -21
- package/swagger/_/swagger.config.js +2 -2
- package/swagger/_/swagger.d.ts +37 -37
- package/swagger/_/swagger.js +78 -78
- package/swagger/index.d.ts +3 -3
- package/swagger/index.js +5 -5
- package/types/index.d.ts +19 -19
- package/types/index.js +2 -2
- package/utils/_/encoder.d.ts +19 -19
- package/utils/_/encoder.js +27 -27
- package/utils/_/encryptor.d.ts +26 -26
- package/utils/_/encryptor.js +67 -67
- package/utils/_/hasher.d.ts +25 -25
- package/utils/_/hasher.js +63 -63
- package/utils/_/object-mapper.d.ts +12 -12
- package/utils/_/object-mapper.js +22 -22
- package/utils/_/string-formatter.d.ts +34 -34
- package/utils/_/string-formatter.js +49 -49
- package/utils/_/utc-date.d.ts +35 -35
- package/utils/_/utc-date.js +84 -84
- package/utils/index.d.ts +7 -7
- package/utils/index.js +15 -15
- package/validators/_/checker.d.ts +62 -62
- package/validators/_/checker.js +98 -98
- package/validators/_/regex.d.ts +98 -98
- package/validators/_/regex.js +142 -142
- package/validators/index.d.ts +3 -3
- package/validators/index.js +7 -7
|
@@ -1,92 +1,92 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
-
});
|
|
10
|
-
};
|
|
11
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
-
};
|
|
14
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
-
exports.TestFactory = void 0;
|
|
16
|
-
const supertest_1 = __importDefault(require("supertest"));
|
|
17
|
-
/**
|
|
18
|
-
* Test factory class
|
|
19
|
-
*/
|
|
20
|
-
class TestFactory {
|
|
21
|
-
/**
|
|
22
|
-
* Test Factor Constructor
|
|
23
|
-
*
|
|
24
|
-
* @param {Express.Application} app service express instance
|
|
25
|
-
* @param {boolean?} debug flag for debugging
|
|
26
|
-
*/
|
|
27
|
-
constructor(app, debug) {
|
|
28
|
-
this._xprs = app;
|
|
29
|
-
this._debug = debug ? debug : false;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* getter for app
|
|
33
|
-
*
|
|
34
|
-
* @returns {Request.SuperTest<Request.Test>} supertest request
|
|
35
|
-
*/
|
|
36
|
-
get app() {
|
|
37
|
-
return (0, supertest_1.default)(this._xprs);
|
|
38
|
-
}
|
|
39
|
-
/**
|
|
40
|
-
* Log message (this.log) if debug = true
|
|
41
|
-
*
|
|
42
|
-
* @param {any[]} msg message to log as arguments
|
|
43
|
-
*/
|
|
44
|
-
log(...msg) {
|
|
45
|
-
if (this._debug) {
|
|
46
|
-
console.log(msg);
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
/**
|
|
50
|
-
* Run test
|
|
51
|
-
*
|
|
52
|
-
* @param {Method} method enum value for GET, POST, PUT, DELETE
|
|
53
|
-
* @param {string} path api call path
|
|
54
|
-
* @param {object?} data post data
|
|
55
|
-
* @param {Map?} headers map of headers to add to request
|
|
56
|
-
* @returns {void}
|
|
57
|
-
*/
|
|
58
|
-
test(method, path, data, headers) {
|
|
59
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
60
|
-
let res;
|
|
61
|
-
let reqHeaders = {};
|
|
62
|
-
if (headers && headers.size > 0) {
|
|
63
|
-
headers.forEach((value, name) => {
|
|
64
|
-
reqHeaders = Object.assign(Object.assign({}, headers), { [name]: value });
|
|
65
|
-
});
|
|
66
|
-
this.log("Request Headers: ", reqHeaders);
|
|
67
|
-
}
|
|
68
|
-
switch (method) {
|
|
69
|
-
case "GET" /* GET */:
|
|
70
|
-
res = yield this.app.get(path).set(reqHeaders);
|
|
71
|
-
break;
|
|
72
|
-
case "POST" /* POST */:
|
|
73
|
-
res = yield this.app.post(path).send(data).set(reqHeaders);
|
|
74
|
-
break;
|
|
75
|
-
case "PATCH" /* PATCH */:
|
|
76
|
-
res = yield this.app.patch(path).send(data).set(reqHeaders);
|
|
77
|
-
break;
|
|
78
|
-
case "PUT" /* PUT */:
|
|
79
|
-
res = yield this.app.put(path).send(data).set(reqHeaders);
|
|
80
|
-
break;
|
|
81
|
-
case "DELETE" /* DELETE */:
|
|
82
|
-
res = yield this.app.delete(path).send(data).set(reqHeaders);
|
|
83
|
-
break;
|
|
84
|
-
default:
|
|
85
|
-
break;
|
|
86
|
-
}
|
|
87
|
-
return res;
|
|
88
|
-
});
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
exports.TestFactory = TestFactory;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
14
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
|
+
exports.TestFactory = void 0;
|
|
16
|
+
const supertest_1 = __importDefault(require("supertest"));
|
|
17
|
+
/**
|
|
18
|
+
* Test factory class
|
|
19
|
+
*/
|
|
20
|
+
class TestFactory {
|
|
21
|
+
/**
|
|
22
|
+
* Test Factor Constructor
|
|
23
|
+
*
|
|
24
|
+
* @param {Express.Application} app service express instance
|
|
25
|
+
* @param {boolean?} debug flag for debugging
|
|
26
|
+
*/
|
|
27
|
+
constructor(app, debug) {
|
|
28
|
+
this._xprs = app;
|
|
29
|
+
this._debug = debug ? debug : false;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* getter for app
|
|
33
|
+
*
|
|
34
|
+
* @returns {Request.SuperTest<Request.Test>} supertest request
|
|
35
|
+
*/
|
|
36
|
+
get app() {
|
|
37
|
+
return (0, supertest_1.default)(this._xprs);
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Log message (this.log) if debug = true
|
|
41
|
+
*
|
|
42
|
+
* @param {any[]} msg message to log as arguments
|
|
43
|
+
*/
|
|
44
|
+
log(...msg) {
|
|
45
|
+
if (this._debug) {
|
|
46
|
+
console.log(msg);
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Run test
|
|
51
|
+
*
|
|
52
|
+
* @param {Method} method enum value for GET, POST, PUT, DELETE
|
|
53
|
+
* @param {string} path api call path
|
|
54
|
+
* @param {object?} data post data
|
|
55
|
+
* @param {Map?} headers map of headers to add to request
|
|
56
|
+
* @returns {void}
|
|
57
|
+
*/
|
|
58
|
+
test(method, path, data, headers) {
|
|
59
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
60
|
+
let res;
|
|
61
|
+
let reqHeaders = {};
|
|
62
|
+
if (headers && headers.size > 0) {
|
|
63
|
+
headers.forEach((value, name) => {
|
|
64
|
+
reqHeaders = Object.assign(Object.assign({}, headers), { [name]: value });
|
|
65
|
+
});
|
|
66
|
+
this.log("Request Headers: ", reqHeaders);
|
|
67
|
+
}
|
|
68
|
+
switch (method) {
|
|
69
|
+
case "GET" /* GET */:
|
|
70
|
+
res = yield this.app.get(path).set(reqHeaders);
|
|
71
|
+
break;
|
|
72
|
+
case "POST" /* POST */:
|
|
73
|
+
res = yield this.app.post(path).send(data).set(reqHeaders);
|
|
74
|
+
break;
|
|
75
|
+
case "PATCH" /* PATCH */:
|
|
76
|
+
res = yield this.app.patch(path).send(data).set(reqHeaders);
|
|
77
|
+
break;
|
|
78
|
+
case "PUT" /* PUT */:
|
|
79
|
+
res = yield this.app.put(path).send(data).set(reqHeaders);
|
|
80
|
+
break;
|
|
81
|
+
case "DELETE" /* DELETE */:
|
|
82
|
+
res = yield this.app.delete(path).send(data).set(reqHeaders);
|
|
83
|
+
break;
|
|
84
|
+
default:
|
|
85
|
+
break;
|
|
86
|
+
}
|
|
87
|
+
return res;
|
|
88
|
+
});
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
exports.TestFactory = TestFactory;
|
|
92
92
|
//# sourceMappingURL=test-factory.js.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { TestFactory } from "./_/test-factory";
|
|
2
|
-
export { TestFactory };
|
|
1
|
+
import { TestFactory } from "./_/test-factory";
|
|
2
|
+
export { TestFactory };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TestFactory = void 0;
|
|
4
|
-
const test_factory_1 = require("./_/test-factory");
|
|
5
|
-
Object.defineProperty(exports, "TestFactory", { enumerable: true, get: function () { return test_factory_1.TestFactory; } });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TestFactory = void 0;
|
|
4
|
+
const test_factory_1 = require("./_/test-factory");
|
|
5
|
+
Object.defineProperty(exports, "TestFactory", { enumerable: true, get: function () { return test_factory_1.TestFactory; } });
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
package/enums/index.d.ts
CHANGED
|
@@ -1,92 +1,92 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Encryption Type enum
|
|
3
|
-
*/
|
|
4
|
-
export declare const enum EncryptionType {
|
|
5
|
-
AES = 0
|
|
6
|
-
}
|
|
7
|
-
/**
|
|
8
|
-
* Type of request method
|
|
9
|
-
*/
|
|
10
|
-
export declare const enum Method {
|
|
11
|
-
GET = "GET",
|
|
12
|
-
POST = "POST",
|
|
13
|
-
PUT = "PUT",
|
|
14
|
-
PATCH = "PATCH",
|
|
15
|
-
DELETE = "DELETE",
|
|
16
|
-
OPTIONS = "OPTIONS"
|
|
17
|
-
}
|
|
18
|
-
/**
|
|
19
|
-
* Type for MimeTypes
|
|
20
|
-
*/
|
|
21
|
-
export declare const enum MimeType {
|
|
22
|
-
ApplicationJson = "application/json"
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* Type of Req/Res Header Names
|
|
26
|
-
*/
|
|
27
|
-
export declare const enum Header {
|
|
28
|
-
Authorization = "Authorization",
|
|
29
|
-
Accept = "Accept",
|
|
30
|
-
AcceptCharset = "Accept-Charset",
|
|
31
|
-
AcceptEncoding = "Accept-Encoding",
|
|
32
|
-
ContentType = "Content-Type",
|
|
33
|
-
Cookie = "Cookie",
|
|
34
|
-
AccessControlAllowOrigin = "Access-Control-Allow-Origin",
|
|
35
|
-
AccessControlAllowMethods = "Access-Control-Allow-Methods",
|
|
36
|
-
AccessControlAllowHeaders = "Access-Control-Allow-Headers",
|
|
37
|
-
XAmzDate = "X-Amz-Date",
|
|
38
|
-
XAmzSecurityToken = "X-Amz-Security-Token",
|
|
39
|
-
XApiKey = "X-Api-Key",
|
|
40
|
-
Metadata = "Metadata"
|
|
41
|
-
}
|
|
42
|
-
/**
|
|
43
|
-
* Enum type for Http Status code
|
|
44
|
-
*/
|
|
45
|
-
export declare const enum Status {
|
|
46
|
-
OK = 200,
|
|
47
|
-
BadRequest = 400,
|
|
48
|
-
Unauthorized = 401,
|
|
49
|
-
Forbidden = 403,
|
|
50
|
-
NotFound = 404,
|
|
51
|
-
MethodNotAllowed = 405,
|
|
52
|
-
Conflict = 409,
|
|
53
|
-
InternalServerError = 500,
|
|
54
|
-
NotImplemented = 501,
|
|
55
|
-
ServiceUnavailable = 503
|
|
56
|
-
}
|
|
57
|
-
/**
|
|
58
|
-
* Type of friendly Messages to display on UI
|
|
59
|
-
*/
|
|
60
|
-
export declare const enum Message {
|
|
61
|
-
InvalidData = "Invalid data.",
|
|
62
|
-
Failure = "A failure occurred.",
|
|
63
|
-
Conflict = "A conflict occurred.",
|
|
64
|
-
InternalServerError = "An Internal Service Error occurred.",
|
|
65
|
-
MissingApiKeyHeader = "Missing Api Key header.",
|
|
66
|
-
MissingAuthorizationHeader = "Missing Authorization header.",
|
|
67
|
-
MissingMetadataHeader = "Missing Metadata header.",
|
|
68
|
-
Forbidden = "Access forbidden!",
|
|
69
|
-
Unauthorized = "You're not authorized!",
|
|
70
|
-
ExpiredToken = "Token Expired.",
|
|
71
|
-
InvalidToken = "Invalid Token.",
|
|
72
|
-
ExistingUser = "User already exists."
|
|
73
|
-
}
|
|
74
|
-
/**
|
|
75
|
-
* Routing options
|
|
76
|
-
*/
|
|
77
|
-
export declare const enum RouteOption {
|
|
78
|
-
Filter = "filter"
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* Interval time
|
|
82
|
-
*/
|
|
83
|
-
export declare const enum Interval {
|
|
84
|
-
Year = "year",
|
|
85
|
-
Quarter = "quarter",
|
|
86
|
-
Month = "month",
|
|
87
|
-
Week = "week",
|
|
88
|
-
Day = "day",
|
|
89
|
-
Hour = "hour",
|
|
90
|
-
Minute = "minute",
|
|
91
|
-
Second = "second"
|
|
92
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Encryption Type enum
|
|
3
|
+
*/
|
|
4
|
+
export declare const enum EncryptionType {
|
|
5
|
+
AES = 0
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* Type of request method
|
|
9
|
+
*/
|
|
10
|
+
export declare const enum Method {
|
|
11
|
+
GET = "GET",
|
|
12
|
+
POST = "POST",
|
|
13
|
+
PUT = "PUT",
|
|
14
|
+
PATCH = "PATCH",
|
|
15
|
+
DELETE = "DELETE",
|
|
16
|
+
OPTIONS = "OPTIONS"
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Type for MimeTypes
|
|
20
|
+
*/
|
|
21
|
+
export declare const enum MimeType {
|
|
22
|
+
ApplicationJson = "application/json"
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Type of Req/Res Header Names
|
|
26
|
+
*/
|
|
27
|
+
export declare const enum Header {
|
|
28
|
+
Authorization = "Authorization",
|
|
29
|
+
Accept = "Accept",
|
|
30
|
+
AcceptCharset = "Accept-Charset",
|
|
31
|
+
AcceptEncoding = "Accept-Encoding",
|
|
32
|
+
ContentType = "Content-Type",
|
|
33
|
+
Cookie = "Cookie",
|
|
34
|
+
AccessControlAllowOrigin = "Access-Control-Allow-Origin",
|
|
35
|
+
AccessControlAllowMethods = "Access-Control-Allow-Methods",
|
|
36
|
+
AccessControlAllowHeaders = "Access-Control-Allow-Headers",
|
|
37
|
+
XAmzDate = "X-Amz-Date",
|
|
38
|
+
XAmzSecurityToken = "X-Amz-Security-Token",
|
|
39
|
+
XApiKey = "X-Api-Key",
|
|
40
|
+
Metadata = "Metadata"
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* Enum type for Http Status code
|
|
44
|
+
*/
|
|
45
|
+
export declare const enum Status {
|
|
46
|
+
OK = 200,
|
|
47
|
+
BadRequest = 400,
|
|
48
|
+
Unauthorized = 401,
|
|
49
|
+
Forbidden = 403,
|
|
50
|
+
NotFound = 404,
|
|
51
|
+
MethodNotAllowed = 405,
|
|
52
|
+
Conflict = 409,
|
|
53
|
+
InternalServerError = 500,
|
|
54
|
+
NotImplemented = 501,
|
|
55
|
+
ServiceUnavailable = 503
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Type of friendly Messages to display on UI
|
|
59
|
+
*/
|
|
60
|
+
export declare const enum Message {
|
|
61
|
+
InvalidData = "Invalid data.",
|
|
62
|
+
Failure = "A failure occurred.",
|
|
63
|
+
Conflict = "A conflict occurred.",
|
|
64
|
+
InternalServerError = "An Internal Service Error occurred.",
|
|
65
|
+
MissingApiKeyHeader = "Missing Api Key header.",
|
|
66
|
+
MissingAuthorizationHeader = "Missing Authorization header.",
|
|
67
|
+
MissingMetadataHeader = "Missing Metadata header.",
|
|
68
|
+
Forbidden = "Access forbidden!",
|
|
69
|
+
Unauthorized = "You're not authorized!",
|
|
70
|
+
ExpiredToken = "Token Expired.",
|
|
71
|
+
InvalidToken = "Invalid Token.",
|
|
72
|
+
ExistingUser = "User already exists."
|
|
73
|
+
}
|
|
74
|
+
/**
|
|
75
|
+
* Routing options
|
|
76
|
+
*/
|
|
77
|
+
export declare const enum RouteOption {
|
|
78
|
+
Filter = "filter"
|
|
79
|
+
}
|
|
80
|
+
/**
|
|
81
|
+
* Interval time
|
|
82
|
+
*/
|
|
83
|
+
export declare const enum Interval {
|
|
84
|
+
Year = "year",
|
|
85
|
+
Quarter = "quarter",
|
|
86
|
+
Month = "month",
|
|
87
|
+
Week = "week",
|
|
88
|
+
Day = "day",
|
|
89
|
+
Hour = "hour",
|
|
90
|
+
Minute = "minute",
|
|
91
|
+
Second = "second"
|
|
92
|
+
}
|
package/enums/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
//# sourceMappingURL=index.js.map
|
package/meet/index.d.ts
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import { ClientType } from "./twilio/enum";
|
|
2
|
-
import { IMeetConfig } from "./twilio/models/_/twilio.config";
|
|
3
|
-
/**
|
|
4
|
-
* Meet declarations
|
|
5
|
-
*/
|
|
6
|
-
interface IMeet<T> {
|
|
7
|
-
client: T;
|
|
8
|
-
}
|
|
9
|
-
/**
|
|
10
|
-
* Meet implementation
|
|
11
|
-
*/
|
|
12
|
-
export declare class Meet<T> implements IMeet<T> {
|
|
13
|
-
private _client;
|
|
14
|
-
private _config;
|
|
15
|
-
private _clientType;
|
|
16
|
-
/**
|
|
17
|
-
* Meet constructor
|
|
18
|
-
*
|
|
19
|
-
* @param {ClientType} clientType client type
|
|
20
|
-
* @param {IMeetConfig} config meet configuration
|
|
21
|
-
*/
|
|
22
|
-
constructor(clientType: ClientType, config: IMeetConfig);
|
|
23
|
-
/**
|
|
24
|
-
* getter for client
|
|
25
|
-
*
|
|
26
|
-
* @returns {T} client of type T
|
|
27
|
-
*/
|
|
28
|
-
get client(): T;
|
|
29
|
-
/**
|
|
30
|
-
* initialize method
|
|
31
|
-
*
|
|
32
|
-
* @returns {void} promise of type void
|
|
33
|
-
*/
|
|
34
|
-
private init;
|
|
35
|
-
}
|
|
36
|
-
export {};
|
|
1
|
+
import { ClientType } from "./twilio/enum";
|
|
2
|
+
import { IMeetConfig } from "./twilio/models/_/twilio.config";
|
|
3
|
+
/**
|
|
4
|
+
* Meet declarations
|
|
5
|
+
*/
|
|
6
|
+
interface IMeet<T> {
|
|
7
|
+
client: T;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Meet implementation
|
|
11
|
+
*/
|
|
12
|
+
export declare class Meet<T> implements IMeet<T> {
|
|
13
|
+
private _client;
|
|
14
|
+
private _config;
|
|
15
|
+
private _clientType;
|
|
16
|
+
/**
|
|
17
|
+
* Meet constructor
|
|
18
|
+
*
|
|
19
|
+
* @param {ClientType} clientType client type
|
|
20
|
+
* @param {IMeetConfig} config meet configuration
|
|
21
|
+
*/
|
|
22
|
+
constructor(clientType: ClientType, config: IMeetConfig);
|
|
23
|
+
/**
|
|
24
|
+
* getter for client
|
|
25
|
+
*
|
|
26
|
+
* @returns {T} client of type T
|
|
27
|
+
*/
|
|
28
|
+
get client(): T;
|
|
29
|
+
/**
|
|
30
|
+
* initialize method
|
|
31
|
+
*
|
|
32
|
+
* @returns {void} promise of type void
|
|
33
|
+
*/
|
|
34
|
+
private init;
|
|
35
|
+
}
|
|
36
|
+
export {};
|
package/meet/index.js
CHANGED
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
-
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
-
};
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.Meet = void 0;
|
|
13
|
-
const tsyringe_1 = require("tsyringe");
|
|
14
|
-
const enum_1 = require("./twilio/enum");
|
|
15
|
-
const twilio_api_1 = require("./twilio/twilio.api");
|
|
16
|
-
/**
|
|
17
|
-
* Meet implementation
|
|
18
|
-
*/
|
|
19
|
-
let Meet = class Meet {
|
|
20
|
-
/**
|
|
21
|
-
* Meet constructor
|
|
22
|
-
*
|
|
23
|
-
* @param {ClientType} clientType client type
|
|
24
|
-
* @param {IMeetConfig} config meet configuration
|
|
25
|
-
*/
|
|
26
|
-
constructor(clientType, config) {
|
|
27
|
-
this._clientType = clientType;
|
|
28
|
-
this._config = config;
|
|
29
|
-
this.init();
|
|
30
|
-
}
|
|
31
|
-
// getter / setter
|
|
32
|
-
/**
|
|
33
|
-
* getter for client
|
|
34
|
-
*
|
|
35
|
-
* @returns {T} client of type T
|
|
36
|
-
*/
|
|
37
|
-
get client() {
|
|
38
|
-
return this._client;
|
|
39
|
-
}
|
|
40
|
-
// methods
|
|
41
|
-
/**
|
|
42
|
-
* initialize method
|
|
43
|
-
*
|
|
44
|
-
* @returns {void} promise of type void
|
|
45
|
-
*/
|
|
46
|
-
init() {
|
|
47
|
-
// change to switch when adding new client types
|
|
48
|
-
//Create a new Stream Client
|
|
49
|
-
if (this._clientType == enum_1.ClientType.Twilio) {
|
|
50
|
-
this._client = new twilio_api_1.TwilioApi(this._config);
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
};
|
|
54
|
-
Meet = __decorate([
|
|
55
|
-
(0, tsyringe_1.injectable)(),
|
|
56
|
-
__metadata("design:paramtypes", [String, Object])
|
|
57
|
-
], Meet);
|
|
58
|
-
exports.Meet = Meet;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Meet = void 0;
|
|
13
|
+
const tsyringe_1 = require("tsyringe");
|
|
14
|
+
const enum_1 = require("./twilio/enum");
|
|
15
|
+
const twilio_api_1 = require("./twilio/twilio.api");
|
|
16
|
+
/**
|
|
17
|
+
* Meet implementation
|
|
18
|
+
*/
|
|
19
|
+
let Meet = class Meet {
|
|
20
|
+
/**
|
|
21
|
+
* Meet constructor
|
|
22
|
+
*
|
|
23
|
+
* @param {ClientType} clientType client type
|
|
24
|
+
* @param {IMeetConfig} config meet configuration
|
|
25
|
+
*/
|
|
26
|
+
constructor(clientType, config) {
|
|
27
|
+
this._clientType = clientType;
|
|
28
|
+
this._config = config;
|
|
29
|
+
this.init();
|
|
30
|
+
}
|
|
31
|
+
// getter / setter
|
|
32
|
+
/**
|
|
33
|
+
* getter for client
|
|
34
|
+
*
|
|
35
|
+
* @returns {T} client of type T
|
|
36
|
+
*/
|
|
37
|
+
get client() {
|
|
38
|
+
return this._client;
|
|
39
|
+
}
|
|
40
|
+
// methods
|
|
41
|
+
/**
|
|
42
|
+
* initialize method
|
|
43
|
+
*
|
|
44
|
+
* @returns {void} promise of type void
|
|
45
|
+
*/
|
|
46
|
+
init() {
|
|
47
|
+
// change to switch when adding new client types
|
|
48
|
+
//Create a new Stream Client
|
|
49
|
+
if (this._clientType == enum_1.ClientType.Twilio) {
|
|
50
|
+
this._client = new twilio_api_1.TwilioApi(this._config);
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
};
|
|
54
|
+
Meet = __decorate([
|
|
55
|
+
(0, tsyringe_1.injectable)(),
|
|
56
|
+
__metadata("design:paramtypes", [String, Object])
|
|
57
|
+
], Meet);
|
|
58
|
+
exports.Meet = Meet;
|
|
59
59
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Client Type enum
|
|
3
|
-
*/
|
|
4
|
-
export declare enum ClientType {
|
|
5
|
-
Twilio = "twilio"
|
|
6
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* Client Type enum
|
|
3
|
+
*/
|
|
4
|
+
export declare enum ClientType {
|
|
5
|
+
Twilio = "twilio"
|
|
6
|
+
}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ClientType = void 0;
|
|
4
|
-
/**
|
|
5
|
-
* Client Type enum
|
|
6
|
-
*/
|
|
7
|
-
var ClientType;
|
|
8
|
-
(function (ClientType) {
|
|
9
|
-
ClientType["Twilio"] = "twilio";
|
|
10
|
-
})(ClientType = exports.ClientType || (exports.ClientType = {}));
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ClientType = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Client Type enum
|
|
6
|
+
*/
|
|
7
|
+
var ClientType;
|
|
8
|
+
(function (ClientType) {
|
|
9
|
+
ClientType["Twilio"] = "twilio";
|
|
10
|
+
})(ClientType = exports.ClientType || (exports.ClientType = {}));
|
|
11
11
|
//# sourceMappingURL=index.js.map
|
package/meet/twilio/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { TwilioAuth } from "./twilio.auth";
|
|
2
|
-
import { TwilioApi } from "./twilio.api";
|
|
3
|
-
import { TwilioBase } from "./twilio.base";
|
|
4
|
-
import { TwilioRoom } from "./twilio.room";
|
|
5
|
-
export { TwilioApi, TwilioAuth, TwilioBase, TwilioRoom };
|
|
1
|
+
import { TwilioAuth } from "./twilio.auth";
|
|
2
|
+
import { TwilioApi } from "./twilio.api";
|
|
3
|
+
import { TwilioBase } from "./twilio.base";
|
|
4
|
+
import { TwilioRoom } from "./twilio.room";
|
|
5
|
+
export { TwilioApi, TwilioAuth, TwilioBase, TwilioRoom };
|
package/meet/twilio/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TwilioRoom = exports.TwilioBase = exports.TwilioAuth = exports.TwilioApi = void 0;
|
|
4
|
-
const twilio_auth_1 = require("./twilio.auth");
|
|
5
|
-
Object.defineProperty(exports, "TwilioAuth", { enumerable: true, get: function () { return twilio_auth_1.TwilioAuth; } });
|
|
6
|
-
const twilio_api_1 = require("./twilio.api");
|
|
7
|
-
Object.defineProperty(exports, "TwilioApi", { enumerable: true, get: function () { return twilio_api_1.TwilioApi; } });
|
|
8
|
-
const twilio_base_1 = require("./twilio.base");
|
|
9
|
-
Object.defineProperty(exports, "TwilioBase", { enumerable: true, get: function () { return twilio_base_1.TwilioBase; } });
|
|
10
|
-
const twilio_room_1 = require("./twilio.room");
|
|
11
|
-
Object.defineProperty(exports, "TwilioRoom", { enumerable: true, get: function () { return twilio_room_1.TwilioRoom; } });
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.TwilioRoom = exports.TwilioBase = exports.TwilioAuth = exports.TwilioApi = void 0;
|
|
4
|
+
const twilio_auth_1 = require("./twilio.auth");
|
|
5
|
+
Object.defineProperty(exports, "TwilioAuth", { enumerable: true, get: function () { return twilio_auth_1.TwilioAuth; } });
|
|
6
|
+
const twilio_api_1 = require("./twilio.api");
|
|
7
|
+
Object.defineProperty(exports, "TwilioApi", { enumerable: true, get: function () { return twilio_api_1.TwilioApi; } });
|
|
8
|
+
const twilio_base_1 = require("./twilio.base");
|
|
9
|
+
Object.defineProperty(exports, "TwilioBase", { enumerable: true, get: function () { return twilio_base_1.TwilioBase; } });
|
|
10
|
+
const twilio_room_1 = require("./twilio.room");
|
|
11
|
+
Object.defineProperty(exports, "TwilioRoom", { enumerable: true, get: function () { return twilio_room_1.TwilioRoom; } });
|
|
12
12
|
//# sourceMappingURL=index.js.map
|