quidproquo-actionprocessor-awslambda 0.0.100 → 0.0.101
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/getActionProcessor/core/event/utils/isAuthValid.js +1 -3
- package/lib/getActionProcessor/core/keyValueStore/getKeyValueStoreUpsertActionProcessor.d.ts +6 -0
- package/lib/getActionProcessor/core/keyValueStore/getKeyValueStoreUpsertActionProcessor.js +35 -0
- package/lib/getActionProcessor/core/keyValueStore/index.d.ts +1 -1
- package/lib/getActionProcessor/core/keyValueStore/index.js +2 -2
- package/lib/getActionProcessor/core/userDirectory/getUserDirectoryGetUserAttributesActionProcessor.d.ts +5 -0
- package/lib/getActionProcessor/core/{keyValueStore/getKeyValueStoreSetActionProcessor.js → userDirectory/getUserDirectoryGetUserAttributesActionProcessor.js} +12 -12
- package/lib/getActionProcessor/core/userDirectory/getUserDirectoryReadAccessTokenActionProcessor.js +2 -3
- package/lib/getActionProcessor/core/userDirectory/getUserDirectoryRefreshTokenActionProcessor.js +1 -1
- package/lib/getActionProcessor/core/userDirectory/getUserDirectorySetUserAttributesActionProcessor.d.ts +5 -0
- package/lib/getActionProcessor/core/userDirectory/getUserDirectorySetUserAttributesActionProcessor.js +28 -0
- package/lib/getActionProcessor/core/userDirectory/index.d.ts +2 -0
- package/lib/getActionProcessor/core/userDirectory/index.js +3 -1
- package/lib/logic/cognito/cognitoAttributeMap.d.ts +10 -0
- package/lib/logic/cognito/cognitoAttributeMap.js +50 -0
- package/lib/logic/cognito/createUser.d.ts +0 -4
- package/lib/logic/cognito/createUser.js +3 -31
- package/lib/logic/cognito/decodeValidJwt.d.ts +1 -1
- package/lib/logic/cognito/decodeValidJwt.js +21 -11
- package/lib/logic/cognito/getUser.js +0 -2
- package/lib/logic/cognito/getUserAttributes.d.ts +2 -0
- package/lib/logic/cognito/getUserAttributes.js +26 -0
- package/lib/logic/cognito/requestEmailVerificationCode.js +0 -1
- package/lib/logic/cognito/respondToAuthChallengeChallenge.js +0 -1
- package/lib/logic/cognito/setUserAttributes.d.ts +2 -0
- package/lib/logic/cognito/setUserAttributes.js +36 -0
- package/lib/logic/cognito/verifyJwt.d.ts +1 -1
- package/lib/logic/cognito/verifyJwt.js +2 -2
- package/lib/logic/dynamo/putItem.d.ts +9 -1
- package/lib/logic/dynamo/putItem.js +34 -3
- package/package.json +6 -1
- package/lib/getActionProcessor/core/keyValueStore/getKeyValueStoreSetActionProcessor.d.ts +0 -6
|
@@ -34,10 +34,8 @@ const isAuthValidForCognito = (qpqConfig, authSettings, authHeader) => __awaiter
|
|
|
34
34
|
const region = quidproquo_core_1.qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
35
35
|
// Resolve the user pool id
|
|
36
36
|
const userPoolId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolIdFromConfig)(userDirectoryName, qpqConfig, authSettings.serviceName, authSettings.applicationName), region);
|
|
37
|
-
// Resolve the user pool client id
|
|
38
|
-
const userPoolClientId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolClientIdFromConfig)(userDirectoryName, qpqConfig, authSettings.serviceName, authSettings.applicationName), region);
|
|
39
37
|
// Verify the token
|
|
40
|
-
return yield (0, verifyJwt_1.verifyJwt)(accessToken, userPoolId,
|
|
38
|
+
return yield (0, verifyJwt_1.verifyJwt)(accessToken, userPoolId, region, false);
|
|
41
39
|
});
|
|
42
40
|
const isAuthValidForApiKeys = (qpqConfig, authSettings, apiKeyHeader) => __awaiter(void 0, void 0, void 0, function* () {
|
|
43
41
|
const apiKeys = authSettings.apiKeys || [];
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { QPQConfig } from 'quidproquo-core';
|
|
2
|
+
import { KeyValueStoreUpsertActionProcessor } from 'quidproquo-core';
|
|
3
|
+
declare const _default: (qpqConfig: QPQConfig) => {
|
|
4
|
+
"@quidproquo-core/KeyValueStore/Upsert": KeyValueStoreUpsertActionProcessor<any>;
|
|
5
|
+
};
|
|
6
|
+
export default _default;
|
|
@@ -0,0 +1,35 @@
|
|
|
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
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
const quidproquo_core_1 = require("quidproquo-core");
|
|
13
|
+
const getProcessKeyValueStoreUpsert = (qpqConfig) => {
|
|
14
|
+
return ({ keyValueStoreName, item, options }) => __awaiter(void 0, void 0, void 0, function* () {
|
|
15
|
+
// const dynamoTableName = getQpqRuntimeResourceNameFromConfig(
|
|
16
|
+
// keyValueStoreName,
|
|
17
|
+
// qpqConfig,
|
|
18
|
+
// 'kvs',
|
|
19
|
+
// );
|
|
20
|
+
// const region = qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
21
|
+
// await putItem(
|
|
22
|
+
// dynamoTableName,
|
|
23
|
+
// key,
|
|
24
|
+
// value,
|
|
25
|
+
// {
|
|
26
|
+
// expires: options?.ttlInSeconds,
|
|
27
|
+
// },
|
|
28
|
+
// region,
|
|
29
|
+
// );
|
|
30
|
+
return (0, quidproquo_core_1.actionResult)(void 0);
|
|
31
|
+
});
|
|
32
|
+
};
|
|
33
|
+
exports.default = (qpqConfig) => ({
|
|
34
|
+
[quidproquo_core_1.KeyValueStoreActionType.Upsert]: getProcessKeyValueStoreUpsert(qpqConfig),
|
|
35
|
+
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { QPQConfig } from 'quidproquo-core';
|
|
2
2
|
declare const _default: (qpqConfig: QPQConfig) => {
|
|
3
3
|
"@quidproquo-core/KeyValueStore/Update": import("quidproquo-core").KeyValueStoreUpdateActionProcessor<any>;
|
|
4
|
-
"@quidproquo-core/KeyValueStore/
|
|
4
|
+
"@quidproquo-core/KeyValueStore/Upsert": import("quidproquo-core").KeyValueStoreUpsertActionProcessor<any>;
|
|
5
5
|
"@quidproquo-core/KeyValueStore/Get": import("quidproquo-core").KeyValueStoreGetActionProcessor<any>;
|
|
6
6
|
"@quidproquo-core/KeyValueStore/Delete": import("quidproquo-core").KeyValueStoreDeleteActionProcessor;
|
|
7
7
|
};
|
|
@@ -5,6 +5,6 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const getKeyValueStoreDeleteActionProcessor_1 = __importDefault(require("./getKeyValueStoreDeleteActionProcessor"));
|
|
7
7
|
const getKeyValueStoreGetActionProcessor_1 = __importDefault(require("./getKeyValueStoreGetActionProcessor"));
|
|
8
|
-
const
|
|
8
|
+
const getKeyValueStoreUpsertActionProcessor_1 = __importDefault(require("./getKeyValueStoreUpsertActionProcessor"));
|
|
9
9
|
const getKeyValueStoreUpdateActionProcessor_1 = __importDefault(require("./getKeyValueStoreUpdateActionProcessor"));
|
|
10
|
-
exports.default = (qpqConfig) => (Object.assign(Object.assign(Object.assign(Object.assign({}, (0, getKeyValueStoreDeleteActionProcessor_1.default)(qpqConfig)), (0, getKeyValueStoreGetActionProcessor_1.default)(qpqConfig)), (0,
|
|
10
|
+
exports.default = (qpqConfig) => (Object.assign(Object.assign(Object.assign(Object.assign({}, (0, getKeyValueStoreDeleteActionProcessor_1.default)(qpqConfig)), (0, getKeyValueStoreGetActionProcessor_1.default)(qpqConfig)), (0, getKeyValueStoreUpsertActionProcessor_1.default)(qpqConfig)), (0, getKeyValueStoreUpdateActionProcessor_1.default)(qpqConfig)));
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { UserDirectoryGetUserAttributesActionProcessor, QPQConfig } from 'quidproquo-core';
|
|
2
|
+
declare const _default: (qpqConfig: QPQConfig) => {
|
|
3
|
+
"@quidproquo-core/UserDirectory/GetUserAttributes": UserDirectoryGetUserAttributesActionProcessor;
|
|
4
|
+
};
|
|
5
|
+
export default _default;
|
|
@@ -11,18 +11,18 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
const quidproquo_core_1 = require("quidproquo-core");
|
|
13
13
|
const awsNamingUtils_1 = require("../../../awsNamingUtils");
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
return ({
|
|
18
|
-
const dynamoTableName = (0, awsNamingUtils_1.getQpqRuntimeResourceNameFromConfig)(keyValueStoreName, qpqConfig, 'kvs');
|
|
14
|
+
const getExportedValue_1 = require("../../../logic/cloudformation/getExportedValue");
|
|
15
|
+
const getUserAttributes_1 = require("../../../logic/cognito/getUserAttributes");
|
|
16
|
+
const getUserDirectoryGetUserAttributesActionProcessor = (qpqConfig) => {
|
|
17
|
+
return ({ userDirectoryName, serviceOverride, username }, session) => __awaiter(void 0, void 0, void 0, function* () {
|
|
19
18
|
const region = quidproquo_core_1.qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
20
|
-
yield (0,
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
return (0, quidproquo_core_2.actionResult)(void 0);
|
|
19
|
+
const userPoolId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolIdFromConfig)(userDirectoryName, qpqConfig, serviceOverride), region);
|
|
20
|
+
const userAttributes = yield (0, getUserAttributes_1.getUserAttributes)(userPoolId, region, username);
|
|
21
|
+
return (0, quidproquo_core_1.actionResult)(userAttributes);
|
|
24
22
|
});
|
|
25
23
|
};
|
|
26
|
-
exports.default = (qpqConfig) =>
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
exports.default = (qpqConfig) => {
|
|
25
|
+
return {
|
|
26
|
+
[quidproquo_core_1.UserDirectoryActionType.GetUserAttributes]: getUserDirectoryGetUserAttributesActionProcessor(qpqConfig),
|
|
27
|
+
};
|
|
28
|
+
};
|
package/lib/getActionProcessor/core/userDirectory/getUserDirectoryReadAccessTokenActionProcessor.js
CHANGED
|
@@ -14,11 +14,10 @@ const awsNamingUtils_1 = require("../../../awsNamingUtils");
|
|
|
14
14
|
const getExportedValue_1 = require("../../../logic/cloudformation/getExportedValue");
|
|
15
15
|
const decodeValidJwt_1 = require("../../../logic/cognito/decodeValidJwt");
|
|
16
16
|
const getUserDirectoryReadAccessTokenActionProcessor = (qpqConfig) => {
|
|
17
|
-
return ({ userDirectoryName, serviceOverride }, session) => __awaiter(void 0, void 0, void 0, function* () {
|
|
17
|
+
return ({ userDirectoryName, serviceOverride, ignoreExpiration }, session) => __awaiter(void 0, void 0, void 0, function* () {
|
|
18
18
|
const region = quidproquo_core_1.qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
19
19
|
const userPoolId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolIdFromConfig)(userDirectoryName, qpqConfig, serviceOverride), region);
|
|
20
|
-
const
|
|
21
|
-
const authInfo = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId, userPoolClientId, 'access', session.accessToken);
|
|
20
|
+
const authInfo = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId, region, ignoreExpiration, session.accessToken);
|
|
22
21
|
if (!authInfo || !(authInfo === null || authInfo === void 0 ? void 0 : authInfo.username)) {
|
|
23
22
|
return (0, quidproquo_core_1.actionResultError)(quidproquo_core_1.ErrorTypeEnum.Unauthorized, 'Invalid accessToken');
|
|
24
23
|
}
|
package/lib/getActionProcessor/core/userDirectory/getUserDirectoryRefreshTokenActionProcessor.js
CHANGED
|
@@ -19,7 +19,7 @@ const getUserDirectoryRefreshTokenActionProcessor = (qpqConfig) => {
|
|
|
19
19
|
const region = quidproquo_core_1.qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
20
20
|
const userPoolId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolIdFromConfig)(userDirectoryName, qpqConfig), region);
|
|
21
21
|
const userPoolClientId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolClientIdFromConfig)(userDirectoryName, qpqConfig), region);
|
|
22
|
-
const authInfo = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId,
|
|
22
|
+
const authInfo = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId, region, true, session.accessToken);
|
|
23
23
|
if (!authInfo || !(authInfo === null || authInfo === void 0 ? void 0 : authInfo.username)) {
|
|
24
24
|
return (0, quidproquo_core_1.actionResultError)(quidproquo_core_1.ErrorTypeEnum.Unauthorized, 'Invalid accessToken');
|
|
25
25
|
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { UserDirectorySetUserAttributesActionProcessor, QPQConfig } from 'quidproquo-core';
|
|
2
|
+
declare const _default: (qpqConfig: QPQConfig) => {
|
|
3
|
+
"@quidproquo-core/UserDirectory/SetUserAttributes": UserDirectorySetUserAttributesActionProcessor;
|
|
4
|
+
};
|
|
5
|
+
export default _default;
|
|
@@ -0,0 +1,28 @@
|
|
|
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
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
const quidproquo_core_1 = require("quidproquo-core");
|
|
13
|
+
const awsNamingUtils_1 = require("../../../awsNamingUtils");
|
|
14
|
+
const getExportedValue_1 = require("../../../logic/cloudformation/getExportedValue");
|
|
15
|
+
const setUserAttributes_1 = require("../../../logic/cognito/setUserAttributes");
|
|
16
|
+
const getUserDirectorySetUserAttributesActionProcessor = (qpqConfig) => {
|
|
17
|
+
return ({ userDirectoryName, serviceOverride, username, userAttributes }, session) => __awaiter(void 0, void 0, void 0, function* () {
|
|
18
|
+
const region = quidproquo_core_1.qpqCoreUtils.getApplicationModuleDeployRegion(qpqConfig);
|
|
19
|
+
const userPoolId = yield (0, getExportedValue_1.getExportedValue)((0, awsNamingUtils_1.getCFExportNameUserPoolIdFromConfig)(userDirectoryName, qpqConfig, serviceOverride), region);
|
|
20
|
+
yield (0, setUserAttributes_1.setUserAttributes)(userPoolId, region, username, userAttributes);
|
|
21
|
+
return (0, quidproquo_core_1.actionResult)(void 0);
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
exports.default = (qpqConfig) => {
|
|
25
|
+
return {
|
|
26
|
+
[quidproquo_core_1.UserDirectoryActionType.SetUserAttributes]: getUserDirectorySetUserAttributesActionProcessor(qpqConfig),
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { QPQConfig } from 'quidproquo-core';
|
|
2
2
|
declare const _default: (qpqConfig: QPQConfig) => {
|
|
3
|
+
"@quidproquo-core/UserDirectory/SetUserAttributes": import("quidproquo-core").UserDirectorySetUserAttributesActionProcessor;
|
|
3
4
|
"@quidproquo-core/UserDirectory/RespondToAuthChallenge": import("quidproquo-core").UserDirectoryRespondToAuthChallengeActionProcessor;
|
|
4
5
|
"@quidproquo-core/UserDirectory/RequestEmailVerification": import("quidproquo-core").UserDirectoryRequestEmailVerificationActionProcessor;
|
|
5
6
|
"@quidproquo-core/UserDirectory/RefreshToken": import("quidproquo-core").UserDirectoryRefreshTokenActionProcessor;
|
|
6
7
|
"@quidproquo-core/UserDirectory/ReadAccessToken": import("quidproquo-core").UserDirectoryReadAccessTokenActionProcessor;
|
|
8
|
+
"@quidproquo-core/UserDirectory/GetUserAttributes": import("quidproquo-core").UserDirectoryGetUserAttributesActionProcessor;
|
|
7
9
|
"@quidproquo-core/UserDirectory/ForgotPassword": import("quidproquo-core").UserDirectoryForgotPasswordActionProcessor;
|
|
8
10
|
"@quidproquo-core/UserDirectory/CreateUser": import("quidproquo-core").UserDirectoryCreateUserActionProcessor;
|
|
9
11
|
"@quidproquo-core/UserDirectory/ConfirmForgotPassword": import("quidproquo-core").UserDirectoryConfirmForgotPasswordActionProcessor;
|
|
@@ -8,8 +8,10 @@ const getUserDirectoryConfirmEmailVerificationActionProcessor_1 = __importDefaul
|
|
|
8
8
|
const getUserDirectoryConfirmForgetPasswordActionProcessor_1 = __importDefault(require("./getUserDirectoryConfirmForgetPasswordActionProcessor"));
|
|
9
9
|
const getUserDirectoryCreateUserActionProcessor_1 = __importDefault(require("./getUserDirectoryCreateUserActionProcessor"));
|
|
10
10
|
const getUserDirectoryForgetPasswordActionProcessor_1 = __importDefault(require("./getUserDirectoryForgetPasswordActionProcessor"));
|
|
11
|
+
const getUserDirectoryGetUserAttributesActionProcessor_1 = __importDefault(require("./getUserDirectoryGetUserAttributesActionProcessor"));
|
|
11
12
|
const getUserDirectoryReadAccessTokenActionProcessor_1 = __importDefault(require("./getUserDirectoryReadAccessTokenActionProcessor"));
|
|
12
13
|
const getUserDirectoryRefreshTokenActionProcessor_1 = __importDefault(require("./getUserDirectoryRefreshTokenActionProcessor"));
|
|
13
14
|
const getUserDirectoryRequestEmailVerificationActionProcessor_1 = __importDefault(require("./getUserDirectoryRequestEmailVerificationActionProcessor"));
|
|
14
15
|
const getUserDirectoryRespondToAuthChallengeActionProcessor_1 = __importDefault(require("./getUserDirectoryRespondToAuthChallengeActionProcessor"));
|
|
15
|
-
|
|
16
|
+
const getUserDirectorySetUserAttributesActionProcessor_1 = __importDefault(require("./getUserDirectorySetUserAttributesActionProcessor"));
|
|
17
|
+
exports.default = (qpqConfig) => (Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, (0, getUserDirectoryAuthenticateUserActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryConfirmEmailVerificationActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryConfirmForgetPasswordActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryCreateUserActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryForgetPasswordActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryGetUserAttributesActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryReadAccessTokenActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryRefreshTokenActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryRequestEmailVerificationActionProcessor_1.default)(qpqConfig)), (0, getUserDirectoryRespondToAuthChallengeActionProcessor_1.default)(qpqConfig)), (0, getUserDirectorySetUserAttributesActionProcessor_1.default)(qpqConfig)));
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { UserAttributes } from 'quidproquo-core';
|
|
2
|
+
export declare const cognitoAttributeMap: Record<keyof UserAttributes, string>;
|
|
3
|
+
export declare const getCognitoUserAttributesFromQpqUserAttributes: (userAttributes: UserAttributes) => {
|
|
4
|
+
Name: string;
|
|
5
|
+
Value: string;
|
|
6
|
+
}[];
|
|
7
|
+
export declare const getQpqAttributesFromCognitoUserAttributes: (cognitoUserAttributes: {
|
|
8
|
+
Name: string;
|
|
9
|
+
Value: string;
|
|
10
|
+
}[]) => UserAttributes;
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getQpqAttributesFromCognitoUserAttributes = exports.getCognitoUserAttributesFromQpqUserAttributes = exports.cognitoAttributeMap = void 0;
|
|
4
|
+
exports.cognitoAttributeMap = {
|
|
5
|
+
email: 'email',
|
|
6
|
+
emailVerified: 'email_verified',
|
|
7
|
+
userId: 'sub',
|
|
8
|
+
address: 'address',
|
|
9
|
+
birthDate: 'birthdate',
|
|
10
|
+
familyName: 'family_name',
|
|
11
|
+
gender: 'gender',
|
|
12
|
+
givenName: 'given_name',
|
|
13
|
+
locale: 'locale',
|
|
14
|
+
middleName: 'middle_name',
|
|
15
|
+
name: 'name',
|
|
16
|
+
nickname: 'nickname',
|
|
17
|
+
phoneNumber: 'phone_number',
|
|
18
|
+
picture: 'picture',
|
|
19
|
+
preferredUsername: 'preferred_username',
|
|
20
|
+
profile: 'profile',
|
|
21
|
+
website: 'website',
|
|
22
|
+
zoneInfo: 'zoneinfo',
|
|
23
|
+
};
|
|
24
|
+
// Flip the cognitoAttributeMap for reverse mapping
|
|
25
|
+
const reversedCognitoAttributeMap = Object.entries(exports.cognitoAttributeMap).reduce((acc, [key, value]) => (Object.assign(Object.assign({}, acc), { [value]: key })), {});
|
|
26
|
+
const getCognitoUserAttributesFromQpqUserAttributes = (userAttributes) => {
|
|
27
|
+
return Object.keys(userAttributes)
|
|
28
|
+
.map((key) => ({
|
|
29
|
+
Name: exports.cognitoAttributeMap[key],
|
|
30
|
+
Value: `${userAttributes[key]}`,
|
|
31
|
+
}))
|
|
32
|
+
.filter((attribute) => !!attribute.Name && !!attribute.Value);
|
|
33
|
+
};
|
|
34
|
+
exports.getCognitoUserAttributesFromQpqUserAttributes = getCognitoUserAttributesFromQpqUserAttributes;
|
|
35
|
+
const getQpqAttributesFromCognitoUserAttributes = (cognitoUserAttributes) => {
|
|
36
|
+
// Map cognitoUserAttributes to your UserAttributes format
|
|
37
|
+
const userAttributes = cognitoUserAttributes.reduce((acc, { Name, Value }) => {
|
|
38
|
+
const userAttributeKey = reversedCognitoAttributeMap[Name];
|
|
39
|
+
if (!userAttributeKey) {
|
|
40
|
+
return acc; // If there's no matching key in your mapping, just continue with the current accumulation
|
|
41
|
+
}
|
|
42
|
+
if (userAttributeKey === 'emailVerified') {
|
|
43
|
+
// Assume the value of 'email_verified' is a string of 'true' or 'false'
|
|
44
|
+
return Object.assign(Object.assign({}, acc), { [userAttributeKey]: Value === 'true' });
|
|
45
|
+
}
|
|
46
|
+
return Object.assign(Object.assign({}, acc), { [userAttributeKey]: Value });
|
|
47
|
+
}, {});
|
|
48
|
+
return userAttributes;
|
|
49
|
+
};
|
|
50
|
+
exports.getQpqAttributesFromCognitoUserAttributes = getQpqAttributesFromCognitoUserAttributes;
|
|
@@ -1,6 +1,2 @@
|
|
|
1
1
|
import { CreateUserRequest, AuthenticateUserResponse } from 'quidproquo-core';
|
|
2
|
-
export declare const getUserAttributesFromCreateUserRequest: (createUserRequest: CreateUserRequest) => {
|
|
3
|
-
Name: string;
|
|
4
|
-
Value: string;
|
|
5
|
-
}[];
|
|
6
2
|
export declare const createUser: (userPoolId: string, region: string, clientId: string, createUserRequest: CreateUserRequest) => Promise<AuthenticateUserResponse>;
|
|
@@ -9,39 +9,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.createUser =
|
|
12
|
+
exports.createUser = void 0;
|
|
13
13
|
const client_cognito_identity_provider_1 = require("@aws-sdk/client-cognito-identity-provider");
|
|
14
14
|
const authenticateUser_1 = require("./authenticateUser");
|
|
15
15
|
const setUserPassword_1 = require("./setUserPassword");
|
|
16
|
-
const
|
|
17
|
-
email: 'email',
|
|
18
|
-
emailVerified: 'email_verified',
|
|
19
|
-
password: 'password',
|
|
20
|
-
address: 'address',
|
|
21
|
-
birthDate: 'birthdate',
|
|
22
|
-
familyName: 'family_name',
|
|
23
|
-
gender: 'gender',
|
|
24
|
-
givenName: 'given_name',
|
|
25
|
-
locale: 'locale',
|
|
26
|
-
middleName: 'middle_name',
|
|
27
|
-
name: 'name',
|
|
28
|
-
nickname: 'nickname',
|
|
29
|
-
phoneNumber: 'phone_number',
|
|
30
|
-
picture: 'picture',
|
|
31
|
-
preferredUsername: 'preferred_username',
|
|
32
|
-
profile: 'profile',
|
|
33
|
-
website: 'website',
|
|
34
|
-
zoneInfo: 'zoneinfo',
|
|
35
|
-
};
|
|
36
|
-
const getUserAttributesFromCreateUserRequest = (createUserRequest) => {
|
|
37
|
-
return Object.keys(createUserRequest)
|
|
38
|
-
.map((key) => ({
|
|
39
|
-
Name: cognitoAttributeMap[key],
|
|
40
|
-
Value: `${createUserRequest[key]}`,
|
|
41
|
-
}))
|
|
42
|
-
.filter((attribute) => !!attribute.Value && attribute.Name !== 'password');
|
|
43
|
-
};
|
|
44
|
-
exports.getUserAttributesFromCreateUserRequest = getUserAttributesFromCreateUserRequest;
|
|
16
|
+
const cognitoAttributeMap_1 = require("./cognitoAttributeMap");
|
|
45
17
|
const createUser = (userPoolId, region, clientId, createUserRequest) => __awaiter(void 0, void 0, void 0, function* () {
|
|
46
18
|
var _a;
|
|
47
19
|
const cognitoClient = new client_cognito_identity_provider_1.CognitoIdentityProviderClient({ region });
|
|
@@ -50,7 +22,7 @@ const createUser = (userPoolId, region, clientId, createUserRequest) => __awaite
|
|
|
50
22
|
Username: createUserRequest.email,
|
|
51
23
|
MessageAction: client_cognito_identity_provider_1.MessageActionType.SUPPRESS,
|
|
52
24
|
DesiredDeliveryMediums: [client_cognito_identity_provider_1.DeliveryMediumType.EMAIL],
|
|
53
|
-
UserAttributes: (0,
|
|
25
|
+
UserAttributes: (0, cognitoAttributeMap_1.getCognitoUserAttributesFromQpqUserAttributes)(createUserRequest),
|
|
54
26
|
ForceAliasCreation: false,
|
|
55
27
|
};
|
|
56
28
|
if (createUserRequest.phoneNumber) {
|
|
@@ -2,4 +2,4 @@ export type AuthInfo = {
|
|
|
2
2
|
userId: string;
|
|
3
3
|
username: string;
|
|
4
4
|
};
|
|
5
|
-
export declare const decodeValidJwt: (userPoolId: string,
|
|
5
|
+
export declare const decodeValidJwt: (userPoolId: string, region: string, ignoreExpiration: boolean, accessToken?: string) => Promise<AuthInfo | null>;
|
|
@@ -8,28 +8,38 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
12
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
13
|
+
};
|
|
11
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
15
|
exports.decodeValidJwt = void 0;
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
|
|
16
|
+
const jsonwebtoken_1 = require("jsonwebtoken");
|
|
17
|
+
const jwks_rsa_1 = __importDefault(require("jwks-rsa"));
|
|
18
|
+
const decodeValidJwt = (userPoolId, region, ignoreExpiration, accessToken) => __awaiter(void 0, void 0, void 0, function* () {
|
|
16
19
|
if (!accessToken) {
|
|
17
20
|
return null;
|
|
18
21
|
}
|
|
19
|
-
const verifier = aws_jwt_verify_1.CognitoJwtVerifier.create({
|
|
20
|
-
userPoolId: userPoolId,
|
|
21
|
-
tokenUse: tokenType,
|
|
22
|
-
clientId: clientId,
|
|
23
|
-
});
|
|
24
22
|
try {
|
|
25
|
-
const
|
|
23
|
+
const decodedToken = (0, jsonwebtoken_1.decode)(accessToken, { complete: true });
|
|
24
|
+
if (!decodedToken) {
|
|
25
|
+
return null;
|
|
26
|
+
}
|
|
27
|
+
const client = (0, jwks_rsa_1.default)({
|
|
28
|
+
jwksUri: `https://cognito-idp.${region}.amazonaws.com/${userPoolId}/.well-known/jwks.json`,
|
|
29
|
+
});
|
|
30
|
+
const key = yield client.getSigningKey(decodedToken.header.kid);
|
|
31
|
+
const signingKey = key.getPublicKey();
|
|
32
|
+
const payload = (0, jsonwebtoken_1.verify)(accessToken, signingKey, {
|
|
33
|
+
algorithms: ['RS256'],
|
|
34
|
+
ignoreExpiration,
|
|
35
|
+
});
|
|
26
36
|
return {
|
|
27
37
|
userId: payload.sub,
|
|
28
|
-
username:
|
|
38
|
+
username: payload.username,
|
|
29
39
|
};
|
|
30
40
|
}
|
|
31
41
|
catch (e) {
|
|
32
|
-
console.log('
|
|
42
|
+
console.log('Failed to decode jwt token', e);
|
|
33
43
|
return null;
|
|
34
44
|
}
|
|
35
45
|
});
|
|
@@ -22,7 +22,6 @@ const getUser = (accessToken, region) => __awaiter(void 0, void 0, void 0, funct
|
|
|
22
22
|
AccessToken: accessToken,
|
|
23
23
|
};
|
|
24
24
|
const response = yield cognitoClient.send(new client_cognito_identity_provider_1.GetUserCommand(params));
|
|
25
|
-
console.log(JSON.stringify(response, null, 2));
|
|
26
25
|
const attributeTypes = (response.UserAttributes || []).filter((ua) => !!ua.Value);
|
|
27
26
|
const userAttributes = attributeTypes.reduce((acc, ua) => (Object.assign(Object.assign({}, acc), { [ua.Name]: ua.Value })), {});
|
|
28
27
|
const user = {
|
|
@@ -31,7 +30,6 @@ const getUser = (accessToken, region) => __awaiter(void 0, void 0, void 0, funct
|
|
|
31
30
|
email: getUserAttribute('email', attributeTypes),
|
|
32
31
|
userAttributes,
|
|
33
32
|
};
|
|
34
|
-
console.log(JSON.stringify(user, null, 2));
|
|
35
33
|
return user;
|
|
36
34
|
});
|
|
37
35
|
exports.getUser = getUser;
|
|
@@ -0,0 +1,26 @@
|
|
|
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
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.getUserAttributes = void 0;
|
|
13
|
+
const client_cognito_identity_provider_1 = require("@aws-sdk/client-cognito-identity-provider");
|
|
14
|
+
const cognitoAttributeMap_1 = require("./cognitoAttributeMap");
|
|
15
|
+
const getUserAttributes = (userPoolId, region, username) => __awaiter(void 0, void 0, void 0, function* () {
|
|
16
|
+
const cognitoClient = new client_cognito_identity_provider_1.CognitoIdentityProviderClient({ region });
|
|
17
|
+
const params = {
|
|
18
|
+
UserPoolId: userPoolId,
|
|
19
|
+
Username: username,
|
|
20
|
+
};
|
|
21
|
+
const response = yield cognitoClient.send(new client_cognito_identity_provider_1.AdminGetUserCommand(params));
|
|
22
|
+
const validAttributes = (response.UserAttributes || []).filter((attr) => attr.Name && attr.Value);
|
|
23
|
+
const attributes = (0, cognitoAttributeMap_1.getQpqAttributesFromCognitoUserAttributes)(validAttributes);
|
|
24
|
+
return attributes;
|
|
25
|
+
});
|
|
26
|
+
exports.getUserAttributes = getUserAttributes;
|
|
@@ -18,6 +18,5 @@ const requestEmailVerificationCode = (region, accessToken) => __awaiter(void 0,
|
|
|
18
18
|
AttributeName: 'email', // Request verification for the email attribute
|
|
19
19
|
};
|
|
20
20
|
const requestEmailVerificationCodeResponse = yield cognitoClient.send(new client_cognito_identity_provider_1.GetUserAttributeVerificationCodeCommand(params));
|
|
21
|
-
console.log(JSON.stringify(requestEmailVerificationCodeResponse, null, 2));
|
|
22
21
|
});
|
|
23
22
|
exports.requestEmailVerificationCode = requestEmailVerificationCode;
|
|
@@ -24,7 +24,6 @@ const respondToAuthChallengeChallenge = (userPoolId, clientId, region, username,
|
|
|
24
24
|
Session: session,
|
|
25
25
|
ChallengeResponses: Object.assign({ USERNAME: username, SECRET_HASH: secretHash }, attributes),
|
|
26
26
|
};
|
|
27
|
-
console.log('params', JSON.stringify(params, null, 2));
|
|
28
27
|
const issueDateTime = new Date().toISOString();
|
|
29
28
|
const response = yield cognitoClient.send(new client_cognito_identity_provider_1.RespondToAuthChallengeCommand(params));
|
|
30
29
|
// transform the response into your custom format, similar to your refreshToken function
|
|
@@ -0,0 +1,36 @@
|
|
|
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 __rest = (this && this.__rest) || function (s, e) {
|
|
12
|
+
var t = {};
|
|
13
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
14
|
+
t[p] = s[p];
|
|
15
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
16
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
17
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
18
|
+
t[p[i]] = s[p[i]];
|
|
19
|
+
}
|
|
20
|
+
return t;
|
|
21
|
+
};
|
|
22
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
23
|
+
exports.setUserAttributes = void 0;
|
|
24
|
+
const client_cognito_identity_provider_1 = require("@aws-sdk/client-cognito-identity-provider");
|
|
25
|
+
const cognitoAttributeMap_1 = require("./cognitoAttributeMap");
|
|
26
|
+
const setUserAttributes = (userPoolId, region, username, userAttributes) => __awaiter(void 0, void 0, void 0, function* () {
|
|
27
|
+
const cognitoClient = new client_cognito_identity_provider_1.CognitoIdentityProviderClient({ region });
|
|
28
|
+
const { userId } = userAttributes, writeableUserAttributes = __rest(userAttributes, ["userId"]);
|
|
29
|
+
const params = {
|
|
30
|
+
UserPoolId: userPoolId,
|
|
31
|
+
Username: username,
|
|
32
|
+
UserAttributes: (0, cognitoAttributeMap_1.getCognitoUserAttributesFromQpqUserAttributes)(writeableUserAttributes),
|
|
33
|
+
};
|
|
34
|
+
yield cognitoClient.send(new client_cognito_identity_provider_1.AdminUpdateUserAttributesCommand(params));
|
|
35
|
+
});
|
|
36
|
+
exports.setUserAttributes = setUserAttributes;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const verifyJwt: (accessToken: string, userPoolId: string,
|
|
1
|
+
export declare const verifyJwt: (accessToken: string, userPoolId: string, region: string, ignoreExpiration?: boolean) => Promise<boolean>;
|
|
@@ -11,8 +11,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.verifyJwt = void 0;
|
|
13
13
|
const decodeValidJwt_1 = require("./decodeValidJwt");
|
|
14
|
-
const verifyJwt = (accessToken, userPoolId,
|
|
15
|
-
const info = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId,
|
|
14
|
+
const verifyJwt = (accessToken, userPoolId, region, ignoreExpiration = false) => __awaiter(void 0, void 0, void 0, function* () {
|
|
15
|
+
const info = yield (0, decodeValidJwt_1.decodeValidJwt)(userPoolId, region, ignoreExpiration, accessToken);
|
|
16
16
|
// if we hav info, its valid
|
|
17
17
|
return !!info;
|
|
18
18
|
});
|
|
@@ -1,4 +1,12 @@
|
|
|
1
|
+
import { KvsKey } from 'quidproquo-core';
|
|
1
2
|
export interface PutItemOptions {
|
|
2
3
|
expires?: number;
|
|
3
4
|
}
|
|
4
|
-
export
|
|
5
|
+
export type KvsKeyValue<T> = {
|
|
6
|
+
key: KvsKey;
|
|
7
|
+
value: T;
|
|
8
|
+
};
|
|
9
|
+
export type DynamoAttributeType = 'S' | 'N' | 'B';
|
|
10
|
+
export declare const readKvsAttributeValue: <T, K extends keyof T>(item: T, key: KvsKey) => KvsKeyValue<T[K]>;
|
|
11
|
+
export declare const getDynamoValueTypeFromKvsKey: (key: KvsKey) => DynamoAttributeType;
|
|
12
|
+
export declare function putItem<Item>(tableName: string, key: string, item: Item, attributes: KvsKey[], options: PutItemOptions, region: string): Promise<void>;
|
|
@@ -9,14 +9,45 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
9
9
|
});
|
|
10
10
|
};
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.putItem = void 0;
|
|
12
|
+
exports.putItem = exports.getDynamoValueTypeFromKvsKey = exports.readKvsAttributeValue = void 0;
|
|
13
13
|
const client_dynamodb_1 = require("@aws-sdk/client-dynamodb");
|
|
14
|
-
|
|
14
|
+
const lodash_1 = require("lodash");
|
|
15
|
+
const readKvsAttributeValue = (item, key) => {
|
|
16
|
+
const value = (0, lodash_1.get)(item, key.key);
|
|
17
|
+
return {
|
|
18
|
+
key,
|
|
19
|
+
value,
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
exports.readKvsAttributeValue = readKvsAttributeValue;
|
|
23
|
+
const getDynamoValueTypeFromKvsKey = (key) => {
|
|
24
|
+
switch (key.type) {
|
|
25
|
+
case 'string':
|
|
26
|
+
return 'S';
|
|
27
|
+
case 'number':
|
|
28
|
+
return 'N';
|
|
29
|
+
case 'binary':
|
|
30
|
+
return 'B';
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
exports.getDynamoValueTypeFromKvsKey = getDynamoValueTypeFromKvsKey;
|
|
34
|
+
function putItem(tableName, key, item, attributes, options, region) {
|
|
15
35
|
return __awaiter(this, void 0, void 0, function* () {
|
|
16
36
|
const dynamoClient = new client_dynamodb_1.DynamoDBClient({ region });
|
|
37
|
+
// Read all the values from the item
|
|
38
|
+
const dynamoProps = attributes
|
|
39
|
+
.filter((a, index, self) => index === self.findIndex((t) => t.key === a.key))
|
|
40
|
+
.reduce((acc, attribute) => {
|
|
41
|
+
const { key, value } = (0, exports.readKvsAttributeValue)(item, attribute);
|
|
42
|
+
const attributeValue = {
|
|
43
|
+
[(0, exports.getDynamoValueTypeFromKvsKey)(key)]: value,
|
|
44
|
+
};
|
|
45
|
+
acc[key.key] = attributeValue;
|
|
46
|
+
return acc;
|
|
47
|
+
}, {});
|
|
17
48
|
yield dynamoClient.send(new client_dynamodb_1.PutItemCommand({
|
|
18
49
|
TableName: tableName,
|
|
19
|
-
Item: Object.assign({
|
|
50
|
+
Item: Object.assign({}, dynamoProps),
|
|
20
51
|
}));
|
|
21
52
|
});
|
|
22
53
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "quidproquo-actionprocessor-awslambda",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.101",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"types": "./lib/index.d.js",
|
|
@@ -38,12 +38,17 @@
|
|
|
38
38
|
"@aws-sdk/client-ssm": "^3.278.0",
|
|
39
39
|
"aws-jwt-verify": "^3.4.0",
|
|
40
40
|
"aws-sdk": "^2.1322.0",
|
|
41
|
+
"jsonwebtoken": "^9.0.0",
|
|
42
|
+
"jwks-rsa": "^3.0.1",
|
|
43
|
+
"lodash": "^4.17.21",
|
|
41
44
|
"node-match-path": "^0.6.3",
|
|
42
45
|
"quidproquo-core": "*",
|
|
43
46
|
"quidproquo-webserver": "*"
|
|
44
47
|
},
|
|
45
48
|
"devDependencies": {
|
|
46
49
|
"@types/aws-lambda": "^8.10.109",
|
|
50
|
+
"@types/jsonwebtoken": "^9.0.2",
|
|
51
|
+
"@types/lodash": "^4.14.194",
|
|
47
52
|
"@types/node": "^18.11.9",
|
|
48
53
|
"quidproquo-tsconfig": "*",
|
|
49
54
|
"typescript": "^4.9.3"
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { QPQConfig } from 'quidproquo-core';
|
|
2
|
-
import { KeyValueStoreSetActionProcessor } from 'quidproquo-core';
|
|
3
|
-
declare const _default: (qpqConfig: QPQConfig) => {
|
|
4
|
-
"@quidproquo-core/KeyValueStore/Set": KeyValueStoreSetActionProcessor<any>;
|
|
5
|
-
};
|
|
6
|
-
export default _default;
|