@matech/thebigpos-sdk 3.13.0 → 3.14.0-dev-5757

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/src/index.ts CHANGED
@@ -851,8 +851,10 @@ export interface AdminAccessUser {
851
851
  preferredLoanOfficer?: PreferredLoanOfficer | null;
852
852
  loanIDs: string[];
853
853
  drafts: Draft[];
854
+ inProgressLoans?: InProgressLoan[] | null;
854
855
  notificationSettings?: UserNotificationSettings | null;
855
856
  hasExtendedLoanVisibility: boolean;
857
+ applicationV3Enabled?: boolean | null;
856
858
  /** @format uuid */
857
859
  accountID?: string | null;
858
860
  loans: UserLoan[];
@@ -1303,6 +1305,7 @@ export interface AiPromptRun {
1303
1305
  errorType?: string | null;
1304
1306
  errorMessage?: string | null;
1305
1307
  result?: AiPromptRunResult | null;
1308
+ detailsWithheld: boolean;
1306
1309
  /** @format date-time */
1307
1310
  createdAt: string;
1308
1311
  /** @format date-time */
@@ -1732,8 +1735,10 @@ export interface BranchUser {
1732
1735
  preferredLoanOfficer?: PreferredLoanOfficer | null;
1733
1736
  loanIDs: string[];
1734
1737
  drafts: Draft[];
1738
+ inProgressLoans?: InProgressLoan[] | null;
1735
1739
  notificationSettings?: UserNotificationSettings | null;
1736
1740
  hasExtendedLoanVisibility: boolean;
1741
+ applicationV3Enabled?: boolean | null;
1737
1742
  /** @format uuid */
1738
1743
  branchID: string;
1739
1744
  branchName: string;
@@ -2354,8 +2359,10 @@ export interface DetailedUser {
2354
2359
  preferredLoanOfficer?: PreferredLoanOfficer | null;
2355
2360
  loanIDs: string[];
2356
2361
  drafts: Draft[];
2362
+ inProgressLoans?: InProgressLoan[] | null;
2357
2363
  notificationSettings?: UserNotificationSettings | null;
2358
2364
  hasExtendedLoanVisibility: boolean;
2365
+ applicationV3Enabled?: boolean | null;
2359
2366
  }
2360
2367
 
2361
2368
  export interface DocumentDataRequest {
@@ -2568,7 +2575,6 @@ export interface EnabledServices {
2568
2575
  socialSurvey?: boolean | null;
2569
2576
  borrowerTasks?: boolean | null;
2570
2577
  preBorrowerTasks?: boolean | null;
2571
- docusign?: boolean | null;
2572
2578
  emailNotifications?: boolean | null;
2573
2579
  autoTaskReminders?: boolean | null;
2574
2580
  voc?: boolean | null;
@@ -3176,8 +3182,10 @@ export interface ImpersonatedDetailedUser {
3176
3182
  preferredLoanOfficer?: PreferredLoanOfficer | null;
3177
3183
  loanIDs: string[];
3178
3184
  drafts: Draft[];
3185
+ inProgressLoans?: InProgressLoan[] | null;
3179
3186
  notificationSettings?: UserNotificationSettings | null;
3180
3187
  hasExtendedLoanVisibility: boolean;
3188
+ applicationV3Enabled?: boolean | null;
3181
3189
  /** @deprecated */
3182
3190
  impersonatedBy?: string | null;
3183
3191
  impersonatingUser?: User | null;
@@ -3190,12 +3198,72 @@ export interface ImportUserLoanTaskRequest {
3190
3198
  userID: string;
3191
3199
  }
3192
3200
 
3201
+ export interface InProgressLoan {
3202
+ /** @format uuid */
3203
+ id: string;
3204
+ /** @format uuid */
3205
+ borrowerId: string;
3206
+ /** @format uuid */
3207
+ siteConfigurationId?: string | null;
3208
+ /** @format date-time */
3209
+ updatedAt?: string | null;
3210
+ }
3211
+
3193
3212
  export interface IncompleteApplicationSummary {
3194
3213
  /** @format int32 */
3195
3214
  total: number;
3196
3215
  borrowers: BorrowerIdentity[];
3197
3216
  }
3198
3217
 
3218
+ export interface IncompleteLoan {
3219
+ /** @format uuid */
3220
+ loanId: string;
3221
+ /** @format uuid */
3222
+ borrowerId?: string | null;
3223
+ /** @format date-time */
3224
+ createdAt: string;
3225
+ /** @format date-time */
3226
+ updatedAt?: string | null;
3227
+ loanOfficer?: UserSummary | null;
3228
+ siteConfiguration?: IncompleteLoanSiteConfiguration | null;
3229
+ borrowers: IncompleteLoanBorrower[];
3230
+ }
3231
+
3232
+ export interface IncompleteLoanBorrower {
3233
+ /** @format uuid */
3234
+ id: string;
3235
+ firstName?: string | null;
3236
+ lastName?: string | null;
3237
+ email?: string | null;
3238
+ isPrimaryBorrower: boolean;
3239
+ applicationStatus: IncompleteLoanBorrowerApplicationStatusEnum;
3240
+ /** @format date-time */
3241
+ deletedAt?: string | null;
3242
+ }
3243
+
3244
+ export interface IncompleteLoanPaginated {
3245
+ rows: IncompleteLoan[];
3246
+ pagination: Pagination;
3247
+ /** @format int64 */
3248
+ count: number;
3249
+ }
3250
+
3251
+ export interface IncompleteLoanSearchCriteria {
3252
+ searchText?: string | null;
3253
+ /** @format uuid */
3254
+ loanOfficerId?: string | null;
3255
+ /** @format uuid */
3256
+ siteConfigurationId?: string | null;
3257
+ isUnassigned?: boolean | null;
3258
+ includeRemovedApplications?: boolean | null;
3259
+ }
3260
+
3261
+ export interface IncompleteLoanSiteConfiguration {
3262
+ /** @format uuid */
3263
+ id: string;
3264
+ name: string;
3265
+ }
3266
+
3199
3267
  export interface IntegrationSettings {
3200
3268
  encompass?: EncompassIntegrationSettings | null;
3201
3269
  }
@@ -3462,6 +3530,20 @@ export interface LoanApplicationRequest {
3462
3530
  existingLoanId?: string | null;
3463
3531
  }
3464
3532
 
3533
+ export interface LoanApplicationSession {
3534
+ routeName: string;
3535
+ currentQuestionId?: string | null;
3536
+ questionHistory: string[];
3537
+ /** @format date-time */
3538
+ completedAt?: string | null;
3539
+ }
3540
+
3541
+ export interface LoanApplicationSessionRequest {
3542
+ routeName: string;
3543
+ currentQuestionId?: string | null;
3544
+ questionHistory: string[];
3545
+ }
3546
+
3465
3547
  export interface LoanBorrower {
3466
3548
  /** @format uuid */
3467
3549
  id: string;
@@ -8242,6 +8324,8 @@ export type IpAddressAddressFamilyEnum =
8242
8324
  | "ControllerAreaNetwork"
8243
8325
  | "Unknown";
8244
8326
 
8327
+ export type IncompleteLoanBorrowerApplicationStatusEnum = "Draft" | "Complete";
8328
+
8245
8329
  export type LoanSigningMethodEnum = "ConsumerConnect" | "POSF";
8246
8330
 
8247
8331
  export type LoanBorrowerApplicationStatusEnum = "Draft" | "Complete";
@@ -8874,7 +8958,15 @@ export class HttpClient<SecurityDataType = unknown> {
8874
8958
  property instanceof Array ? property : [property];
8875
8959
 
8876
8960
  for (const formItem of propertyContent) {
8877
- const isFileType = formItem instanceof Blob || formItem instanceof File;
8961
+ // React Native files are plain { uri, name, type } objects, not Blob/File.
8962
+ const isReactNativeFile =
8963
+ !!formItem &&
8964
+ typeof formItem === "object" &&
8965
+ "uri" in formItem &&
8966
+ "name" in formItem &&
8967
+ "type" in formItem;
8968
+ const isFileType =
8969
+ isReactNativeFile || formItem instanceof Blob || formItem instanceof File;
8878
8970
  formData.append(
8879
8971
  key,
8880
8972
  isFileType ? formItem : this.stringifyFormItem(formItem),
@@ -8936,7 +9028,7 @@ export class HttpClient<SecurityDataType = unknown> {
8936
9028
 
8937
9029
  /**
8938
9030
  * @title The Big POS API
8939
- * @version v3.13.0
9031
+ * @version v3.14.0
8940
9032
  * @termsOfService https://www.thebigpos.com/terms-of-use/
8941
9033
  * @contact Mortgage Automation Technologies <support@thebigpos.com> (https://www.thebigpos.com/terms-of-use/)
8942
9034
  */
@@ -14119,6 +14211,42 @@ export class Api<
14119
14211
  ...params,
14120
14212
  }),
14121
14213
 
14214
+ /**
14215
+ * No description
14216
+ *
14217
+ * @tags IncompleteLoans
14218
+ * @name SearchIncompleteLoans
14219
+ * @summary Search incomplete loans
14220
+ * @request POST:/api/loans/incomplete/search
14221
+ * @secure
14222
+ * @response `200` `IncompleteLoanPaginated` OK
14223
+ * @response `400` `ProblemDetails` Bad Request
14224
+ * @response `403` `ProblemDetails` Forbidden
14225
+ * @response `404` `ProblemDetails` Not Found
14226
+ */
14227
+ searchIncompleteLoans: (
14228
+ data: IncompleteLoanSearchCriteria,
14229
+ query?: {
14230
+ /** @format int32 */
14231
+ pageSize?: number;
14232
+ /** @format int32 */
14233
+ pageNumber?: number;
14234
+ sortBy?: string;
14235
+ sortDirection?: string;
14236
+ },
14237
+ params: RequestParams = {},
14238
+ ) =>
14239
+ this.request<IncompleteLoanPaginated, ProblemDetails>({
14240
+ path: `/api/loans/incomplete/search`,
14241
+ method: "POST",
14242
+ query: query,
14243
+ body: data,
14244
+ secure: true,
14245
+ type: "application/json",
14246
+ format: "json",
14247
+ ...params,
14248
+ }),
14249
+
14122
14250
  /**
14123
14251
  * No description
14124
14252
  *
@@ -14835,6 +14963,50 @@ export class Api<
14835
14963
  ...params,
14836
14964
  }),
14837
14965
 
14966
+ /**
14967
+ * No description
14968
+ *
14969
+ * @tags LoanApplicationRemoval
14970
+ * @name RemoveLoanApplication
14971
+ * @summary Remove a loan application nobody has submitted
14972
+ * @request POST:/api/loans/{loanId}/application/remove
14973
+ * @secure
14974
+ * @response `204` `void` No Content
14975
+ * @response `400` `ProblemDetails` Bad Request
14976
+ * @response `403` `ProblemDetails` Forbidden
14977
+ * @response `404` `ProblemDetails` Not Found
14978
+ * @response `409` `ProblemDetails` Conflict
14979
+ */
14980
+ removeLoanApplication: (loanId: string, params: RequestParams = {}) =>
14981
+ this.request<void, ProblemDetails>({
14982
+ path: `/api/loans/${loanId}/application/remove`,
14983
+ method: "POST",
14984
+ secure: true,
14985
+ ...params,
14986
+ }),
14987
+
14988
+ /**
14989
+ * No description
14990
+ *
14991
+ * @tags LoanApplicationRemoval
14992
+ * @name RestoreLoanApplication
14993
+ * @summary Restore a removed loan application
14994
+ * @request POST:/api/loans/{loanId}/application/restore
14995
+ * @secure
14996
+ * @response `204` `void` No Content
14997
+ * @response `400` `ProblemDetails` Bad Request
14998
+ * @response `403` `ProblemDetails` Forbidden
14999
+ * @response `404` `ProblemDetails` Not Found
15000
+ * @response `409` `ProblemDetails` Conflict
15001
+ */
15002
+ restoreLoanApplication: (loanId: string, params: RequestParams = {}) =>
15003
+ this.request<void, ProblemDetails>({
15004
+ path: `/api/loans/${loanId}/application/restore`,
15005
+ method: "POST",
15006
+ secure: true,
15007
+ ...params,
15008
+ }),
15009
+
14838
15010
  /**
14839
15011
  * No description
14840
15012
  *
@@ -15300,7 +15472,7 @@ export class Api<
15300
15472
  }),
15301
15473
 
15302
15474
  /**
15303
- * @description Returns the folders the caller can access that are relevant to this loan — those holding a document the caller can read, plus those bound to one of the loan's tasks, even when empty — with the caller's effective accessLevel and the count of documents they can read in each. Upload destinations are the active entries with accessLevel at least Write. Documents that are not assigned to a folder are returned as a synthetic 'Unassigned' folder (ID = empty GUID, isUnassigned = true); filter to its documents with searchLoanDocuments folderScope 'Unassigned' rather than by echoing that ID.
15475
+ * @description Returns the folders the caller can access that are relevant to this loan — every active system-default folder, plus any folder holding a document the caller can read or bound to one of the loan's tasks, even when empty — with the caller's effective accessLevel and the count of documents they can read in each. Upload destinations are the active entries with accessLevel at least Write. Documents that are not assigned to a folder are returned as a synthetic 'Unassigned' folder (ID = empty GUID, isUnassigned = true); filter to its documents with searchLoanDocuments folderScope 'Unassigned' rather than by echoing that ID.
15304
15476
  *
15305
15477
  * @tags LoanDocumentFoldersForSingleLoan
15306
15478
  * @name ListLoanDocumentFolders
@@ -16683,11 +16855,19 @@ export class Api<
16683
16855
  * @response `400` `any` Bad Request
16684
16856
  * @response `401` `ProblemDetails` Unauthorized
16685
16857
  * @response `403` `ProblemDetails` Forbidden
16858
+ * @response `404` `ProblemDetails` Not Found
16686
16859
  */
16687
- createLoanv3: (data: LoanApplicationRequest, params: RequestParams = {}) =>
16860
+ createLoanv3: (
16861
+ data: LoanApplicationRequest,
16862
+ query?: {
16863
+ application?: string;
16864
+ },
16865
+ params: RequestParams = {},
16866
+ ) =>
16688
16867
  this.request<LoanApplication, ProblemDetails>({
16689
16868
  path: `/api/loans`,
16690
16869
  method: "POST",
16870
+ query: query,
16691
16871
  body: data,
16692
16872
  secure: true,
16693
16873
  type: "application/json",
@@ -16771,13 +16951,14 @@ export class Api<
16771
16951
  * @response `400` `ProblemDetails` Bad Request
16772
16952
  * @response `404` `ProblemDetails` Not Found
16773
16953
  * @response `409` `ProblemDetails` Conflict
16954
+ * @response `422` `UnprocessableEntity` Unprocessable Content
16774
16955
  */
16775
16956
  completeBorrowerApplication: (
16776
16957
  loanId: string,
16777
16958
  borrowerId: string,
16778
16959
  params: RequestParams = {},
16779
16960
  ) =>
16780
- this.request<void, ProblemDetails>({
16961
+ this.request<void, ProblemDetails | UnprocessableEntity>({
16781
16962
  path: `/api/loans/${loanId}/borrowers/${borrowerId}/complete`,
16782
16963
  method: "POST",
16783
16964
  secure: true,
@@ -16810,6 +16991,63 @@ export class Api<
16810
16991
  ...params,
16811
16992
  }),
16812
16993
 
16994
+ /**
16995
+ * No description
16996
+ *
16997
+ * @tags Loans
16998
+ * @name GetBorrowerApplicationSession
16999
+ * @summary Get borrower application session
17000
+ * @request GET:/api/loans/{loanId}/borrowers/{borrowerId}/application-session
17001
+ * @secure
17002
+ * @response `200` `LoanApplicationSession` OK
17003
+ * @response `400` `any` Bad Request
17004
+ * @response `401` `ProblemDetails` Unauthorized
17005
+ * @response `403` `ProblemDetails` Forbidden
17006
+ * @response `404` `ProblemDetails` Not Found
17007
+ */
17008
+ getBorrowerApplicationSession: (
17009
+ loanId: string,
17010
+ borrowerId: string,
17011
+ params: RequestParams = {},
17012
+ ) =>
17013
+ this.request<LoanApplicationSession, ProblemDetails>({
17014
+ path: `/api/loans/${loanId}/borrowers/${borrowerId}/application-session`,
17015
+ method: "GET",
17016
+ secure: true,
17017
+ format: "json",
17018
+ ...params,
17019
+ }),
17020
+
17021
+ /**
17022
+ * No description
17023
+ *
17024
+ * @tags Loans
17025
+ * @name UpdateBorrowerApplicationSession
17026
+ * @summary Update borrower application session
17027
+ * @request PUT:/api/loans/{loanId}/borrowers/{borrowerId}/application-session
17028
+ * @secure
17029
+ * @response `200` `LoanApplicationSession` OK
17030
+ * @response `400` `any` Bad Request
17031
+ * @response `401` `ProblemDetails` Unauthorized
17032
+ * @response `403` `ProblemDetails` Forbidden
17033
+ * @response `404` `ProblemDetails` Not Found
17034
+ */
17035
+ updateBorrowerApplicationSession: (
17036
+ loanId: string,
17037
+ borrowerId: string,
17038
+ data: LoanApplicationSessionRequest,
17039
+ params: RequestParams = {},
17040
+ ) =>
17041
+ this.request<LoanApplicationSession, ProblemDetails>({
17042
+ path: `/api/loans/${loanId}/borrowers/${borrowerId}/application-session`,
17043
+ method: "PUT",
17044
+ body: data,
17045
+ secure: true,
17046
+ type: "application/json",
17047
+ format: "json",
17048
+ ...params,
17049
+ }),
17050
+
16813
17051
  /**
16814
17052
  * No description
16815
17053
  *
@@ -16839,6 +17077,7 @@ export class Api<
16839
17077
  * @secure
16840
17078
  * @response `202` `void` Accepted
16841
17079
  * @response `404` `ProblemDetails` Not Found
17080
+ * @response `409` `ProblemDetails` Conflict
16842
17081
  */
16843
17082
  syncLoanToLos: (loanId: string, params: RequestParams = {}) =>
16844
17083
  this.request<void, ProblemDetails>({