heartraite 1.0.29 → 1.0.31

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.
@@ -1,6 +1,6 @@
1
1
  import { CloudFunction } from "../enum";
2
- import { AddImagesRequest, AuthenticateBankIDRequest, CalculatePLSScoreRequest, CollectBankIDRequest, CreateBillingPortalRequest, CreateCheckoutSessionRequest, CreateLikeRequest, CreatePLSAssessmentRequest, CreatePLSInputRequest, CreatePLSSubmissionRequest, CreateReportRequest, GetCARequest, GetMatchableUserRequest, GetMatchCheckRequest, GetMatchesRequest, GetMatchRequest, GetMessagesRequest, GetPLSAssessmentRequest, GetPLSSubmissionRequest, GetProductsRequest, GetUserRequest, HandleLikeSeenRequest, HandleMatchSeenRequest, RegisterOnboardingRequest, RegisterUserRequest, RemoveMatchRequest, SendMessageRequest, SubmitAnswerRequest, SubmitCategoryFeedbackRequest, SubmitPLSCategoryFeedbackRequest, UpdatePLSAnswerRequest, UpdateQuestionsRequest, UpdateUserRequest } from "./request.types";
3
- import { AddImagesResponse, AuthenticateBankIDResponse, CalculatePLSScoreResponse, CollectBankIDResponse, CreateBillingPortalResponse, CreateCheckoutSessionResponse, CreateLikeResponse, CreatePLSAssessmentResponse, CreatePLSInputResponse, CreatePLSSubmissionResponse, CreateReportResponse, GetCAResponse, GetMatchableUserResponse, GetMatchableUsersResponse, GetMatchCheckResponse, GetMatchesResponse, GetMatchResponse, GetMessagesResponse, GetPLSAssessmentResponse, GetPLSAssessmentsResponse, GetPLSSubmissionResponse, GetProductsResponse, GetUserResponse, HandleLikeSeenResponse, HandleMatchSeenResponse, RegisterOnboardingResponse, RegisterUserResponse, RemoveMatchResponse, SendMessageResponse, SubmitAnswerResponse, SubmitCategoryFeedbackResponse, SubmitPLSCategoryFeedbackResponse, UpdatePLSAnswerResponse, UpdateQuestionsResponse, UpdateUserResponse } from "./response.types";
2
+ import { AddImagesRequest, AuthenticateBankIDRequest, CollectBankIDRequest, CreateBillingPortalRequest, CreateCheckoutSessionRequest, CreateLikeRequest, CreatePLSInputRequest, CreatePLSSubmissionRequest, CreateReportRequest, GetCARequest, GetMatchableUserRequest, GetMatchCheckRequest, GetMatchesRequest, GetMatchRequest, GetMessagesRequest, GetPLSSubmissionRequest, GetProductsRequest, GetUserRequest, HandleLikeSeenRequest, HandleMatchSeenRequest, RegisterOnboardingRequest, RegisterUserRequest, RemoveMatchRequest, SendMessageRequest, SubmitAnswerRequest, SubmitCategoryFeedbackRequest, SubmitPLSCategoryFeedbackRequest, UpdatePLSAnswerRequest, UpdateQuestionsRequest, UpdateUserRequest } from "./request.types";
3
+ import { AddImagesResponse, AuthenticateBankIDResponse, CollectBankIDResponse, CreateBillingPortalResponse, CreateCheckoutSessionResponse, CreateLikeResponse, CreatePLSInputResponse, CreatePLSSubmissionResponse, CreateReportResponse, GetCAResponse, GetMatchableUserResponse, GetMatchableUsersResponse, GetMatchCheckResponse, GetMatchesResponse, GetMatchResponse, GetMessagesResponse, GetPLSSubmissionResponse, GetProductsResponse, GetUserResponse, HandleLikeSeenResponse, HandleMatchSeenResponse, RegisterOnboardingResponse, RegisterUserResponse, RemoveMatchResponse, SendMessageResponse, SubmitAnswerResponse, SubmitCategoryFeedbackResponse, SubmitPLSCategoryFeedbackResponse, UpdatePLSAnswerResponse, UpdateQuestionsResponse, UpdateUserResponse } from "./response.types";
4
4
  export type CloudFunctionTypes = {
5
5
  [CloudFunction.REGISTER_USER]: {
6
6
  payload: RegisterUserRequest;
@@ -74,10 +74,6 @@ export type CloudFunctionTypes = {
74
74
  payload: GetMessagesRequest;
75
75
  response: GetMessagesResponse;
76
76
  };
77
- [CloudFunction.CALCULATE_PLS_SCORE]: {
78
- payload: CalculatePLSScoreRequest;
79
- response: CalculatePLSScoreResponse;
80
- };
81
77
  [CloudFunction.CREATE_PLS_INPUT]: {
82
78
  payload: CreatePLSInputRequest;
83
79
  response: CreatePLSInputResponse;
@@ -98,18 +94,6 @@ export type CloudFunctionTypes = {
98
94
  payload: SubmitPLSCategoryFeedbackRequest;
99
95
  response: SubmitPLSCategoryFeedbackResponse;
100
96
  };
101
- [CloudFunction.CREATE_PLS_ASSESSMENT]: {
102
- payload: CreatePLSAssessmentRequest;
103
- response: CreatePLSAssessmentResponse;
104
- };
105
- [CloudFunction.GET_PLS_ASSESSMENT]: {
106
- payload: GetPLSAssessmentRequest;
107
- response: GetPLSAssessmentResponse;
108
- };
109
- [CloudFunction.GET_PLS_ASSESSMENTS]: {
110
- payload?: undefined;
111
- response: GetPLSAssessmentsResponse;
112
- };
113
97
  [CloudFunction.UPDATE_QUESTIONS]: {
114
98
  payload: UpdateQuestionsRequest;
115
99
  response: UpdateQuestionsResponse;
@@ -1,10 +1,12 @@
1
- import { FeedbackAgreement, Gender, LikeType, ReportReason } from "../enum";
1
+ import { FeedbackAgreement, Gender, LikeType, ProviderType, ReportReason } from "../enum";
2
2
  import { DeepPartial } from "./helper.types";
3
3
  import { Answer } from "./submission.types";
4
4
  import { DatingPreferences, UserNotifications, UserProfile } from "./user.types";
5
5
  export type RegisterUserRequest = {
6
+ userId: string;
6
7
  email: string;
7
- password: string;
8
+ provider: ProviderType;
9
+ created: string;
8
10
  referrerId?: string;
9
11
  };
10
12
  export type GetCARequest = undefined;
@@ -62,9 +64,6 @@ export type GetMatchableUserRequest = {
62
64
  export type GetMatchCheckRequest = {
63
65
  userId: string;
64
66
  };
65
- export type CalculatePLSScoreRequest = {
66
- assessmentId: string;
67
- };
68
67
  export type CreatePLSInputRequest = {
69
68
  questionnaire: Record<string, string>;
70
69
  channelId: string;
@@ -91,10 +90,6 @@ export type SubmitPLSCategoryFeedbackRequest = {
91
90
  evaluationReflection: string;
92
91
  additionalThoughts: string;
93
92
  };
94
- export type CreatePLSAssessmentRequest = undefined;
95
- export type GetPLSAssessmentRequest = {
96
- id: string;
97
- };
98
93
  export type UpdateQuestionsRequest = {
99
94
  questions: Record<string, string>;
100
95
  };
@@ -1,4 +1,3 @@
1
- import { Assessment, FullAssessment } from "./assessment.types";
2
1
  import { Submission, CategoryEvaluation } from "./submission.types";
3
2
  import { Match, UserMatch } from "./match.types";
4
3
  import { MatchableUser, MatchCheck } from "./matchmaking.types";
@@ -42,11 +41,7 @@ export type CreateLikeResponse = {
42
41
  };
43
42
  export type GetLikesResponse = Like[];
44
43
  export type HandleLikeSeenResponse = void;
45
- export type CalculatePLSScoreResponse = FullAssessment;
46
44
  export type CreatePLSInputResponse = void;
47
- export type CreatePLSAssessmentResponse = Assessment;
48
- export type GetPLSAssessmentResponse = FullAssessment;
49
- export type GetPLSAssessmentsResponse = FullAssessment[];
50
45
  export type CreatePLSSubmissionResponse = Submission;
51
46
  export type GetPLSSubmissionResponse = Submission;
52
47
  export type UpdatePLSAnswerResponse = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "heartraite",
3
- "version": "1.0.29",
3
+ "version": "1.0.31",
4
4
  "description": "Heartraite npm package for common functionality",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -2,12 +2,10 @@ import { CloudFunction } from "../enum";
2
2
  import {
3
3
  AddImagesRequest,
4
4
  AuthenticateBankIDRequest,
5
- CalculatePLSScoreRequest,
6
5
  CollectBankIDRequest,
7
6
  CreateBillingPortalRequest,
8
7
  CreateCheckoutSessionRequest,
9
8
  CreateLikeRequest,
10
- CreatePLSAssessmentRequest,
11
9
  CreatePLSInputRequest,
12
10
  CreatePLSSubmissionRequest,
13
11
  CreateReportRequest,
@@ -17,7 +15,6 @@ import {
17
15
  GetMatchesRequest,
18
16
  GetMatchRequest,
19
17
  GetMessagesRequest,
20
- GetPLSAssessmentRequest,
21
18
  GetPLSSubmissionRequest,
22
19
  GetProductsRequest,
23
20
  GetUserRequest,
@@ -37,12 +34,10 @@ import {
37
34
  import {
38
35
  AddImagesResponse,
39
36
  AuthenticateBankIDResponse,
40
- CalculatePLSScoreResponse,
41
37
  CollectBankIDResponse,
42
38
  CreateBillingPortalResponse,
43
39
  CreateCheckoutSessionResponse,
44
40
  CreateLikeResponse,
45
- CreatePLSAssessmentResponse,
46
41
  CreatePLSInputResponse,
47
42
  CreatePLSSubmissionResponse,
48
43
  CreateReportResponse,
@@ -53,8 +48,6 @@ import {
53
48
  GetMatchesResponse,
54
49
  GetMatchResponse,
55
50
  GetMessagesResponse,
56
- GetPLSAssessmentResponse,
57
- GetPLSAssessmentsResponse,
58
51
  GetPLSSubmissionResponse,
59
52
  GetProductsResponse,
60
53
  GetUserResponse,
@@ -159,10 +152,6 @@ export type CloudFunctionTypes = {
159
152
  };
160
153
 
161
154
  // pls
162
- [CloudFunction.CALCULATE_PLS_SCORE]: {
163
- payload: CalculatePLSScoreRequest;
164
- response: CalculatePLSScoreResponse;
165
- };
166
155
  [CloudFunction.CREATE_PLS_INPUT]: {
167
156
  payload: CreatePLSInputRequest;
168
157
  response: CreatePLSInputResponse;
@@ -183,18 +172,6 @@ export type CloudFunctionTypes = {
183
172
  payload: SubmitPLSCategoryFeedbackRequest;
184
173
  response: SubmitPLSCategoryFeedbackResponse;
185
174
  };
186
- [CloudFunction.CREATE_PLS_ASSESSMENT]: {
187
- payload: CreatePLSAssessmentRequest;
188
- response: CreatePLSAssessmentResponse;
189
- };
190
- [CloudFunction.GET_PLS_ASSESSMENT]: {
191
- payload: GetPLSAssessmentRequest;
192
- response: GetPLSAssessmentResponse;
193
- };
194
- [CloudFunction.GET_PLS_ASSESSMENTS]: {
195
- payload?: undefined;
196
- response: GetPLSAssessmentsResponse;
197
- };
198
175
 
199
176
  // rating
200
177
  [CloudFunction.UPDATE_QUESTIONS]: {
@@ -1,4 +1,10 @@
1
- import { FeedbackAgreement, Gender, LikeType, ReportReason } from "../enum";
1
+ import {
2
+ FeedbackAgreement,
3
+ Gender,
4
+ LikeType,
5
+ ProviderType,
6
+ ReportReason,
7
+ } from "../enum";
2
8
  import { DeepPartial } from "./helper.types";
3
9
  import { Answer } from "./submission.types";
4
10
  import {
@@ -9,8 +15,10 @@ import {
9
15
 
10
16
  // auth
11
17
  export type RegisterUserRequest = {
18
+ userId: string;
12
19
  email: string;
13
- password: string;
20
+ provider: ProviderType;
21
+ created: string;
14
22
  referrerId?: string;
15
23
  };
16
24
 
@@ -57,9 +65,6 @@ export type GetMatchableUserRequest = { userId: string };
57
65
  export type GetMatchCheckRequest = { userId: string };
58
66
 
59
67
  // pls
60
- export type CalculatePLSScoreRequest = {
61
- assessmentId: string;
62
- };
63
68
  export type CreatePLSInputRequest = {
64
69
  questionnaire: Record<string, string>;
65
70
  channelId: string;
@@ -86,8 +91,6 @@ export type SubmitPLSCategoryFeedbackRequest = {
86
91
  evaluationReflection: string;
87
92
  additionalThoughts: string;
88
93
  };
89
- export type CreatePLSAssessmentRequest = undefined;
90
- export type GetPLSAssessmentRequest = { id: string };
91
94
 
92
95
  // rating
93
96
  export type UpdateQuestionsRequest = { questions: Record<string, string> };
@@ -55,11 +55,7 @@ export type GetLikesResponse = Like[];
55
55
  export type HandleLikeSeenResponse = void;
56
56
 
57
57
  // pls
58
- export type CalculatePLSScoreResponse = FullAssessment;
59
58
  export type CreatePLSInputResponse = void;
60
- export type CreatePLSAssessmentResponse = Assessment;
61
- export type GetPLSAssessmentResponse = FullAssessment;
62
- export type GetPLSAssessmentsResponse = FullAssessment[];
63
59
  export type CreatePLSSubmissionResponse = Submission;
64
60
  export type GetPLSSubmissionResponse = Submission;
65
61
  export type UpdatePLSAnswerResponse = {