@matech/thebigpos-sdk 3.21.0 → 3.22.0-main-7349

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -86,7 +86,13 @@ export class HttpClient {
86
86
  const property = input[key];
87
87
  const propertyContent = property instanceof Array ? property : [property];
88
88
  for (const formItem of propertyContent) {
89
- const isFileType = formItem instanceof Blob || formItem instanceof File;
89
+ // React Native files are plain { uri, name, type } objects, not Blob/File.
90
+ const isReactNativeFile = !!formItem &&
91
+ typeof formItem === "object" &&
92
+ "uri" in formItem &&
93
+ "name" in formItem &&
94
+ "type" in formItem;
95
+ const isFileType = isReactNativeFile || formItem instanceof Blob || formItem instanceof File;
90
96
  formData.append(key, isFileType ? formItem : this.stringifyFormItem(formItem));
91
97
  }
92
98
  return formData;
@@ -95,7 +101,7 @@ export class HttpClient {
95
101
  }
96
102
  /**
97
103
  * @title The Big POS API
98
- * @version v3.21.0
104
+ * @version v3.22.0
99
105
  * @termsOfService https://www.thebigpos.com/terms-of-use/
100
106
  * @contact Mortgage Automation Technologies <support@thebigpos.com> (https://www.thebigpos.com/terms-of-use/)
101
107
  */
@@ -363,30 +369,6 @@ export class Api extends HttpClient {
363
369
  * @response `409` `ProblemDetails` Conflict
364
370
  */
365
371
  deleteAiPrompt: (id, query, params = {}) => this.request(Object.assign({ path: `/api/ai/prompts/${id}`, method: "DELETE", query: query, secure: true }, params)),
366
- /**
367
- * No description
368
- *
369
- * @tags AiAdminPrompt
370
- * @name GetAiTools
371
- * @summary List available agent tools and their settings schema
372
- * @request GET:/api/ai/prompts/tools
373
- * @secure
374
- * @response `200` `(AiToolCatalogItem)[]` OK
375
- */
376
- getAiTools: (params = {}) => this.request(Object.assign({ path: `/api/ai/prompts/tools`, method: "GET", secure: true, format: "json" }, params)),
377
- /**
378
- * No description
379
- *
380
- * @tags AiAdminPrompt
381
- * @name UpdateAiPromptTools
382
- * @summary Replace the prompt's agent tool configuration
383
- * @request PUT:/api/ai/prompts/{id}/tools
384
- * @secure
385
- * @response `200` `AiPrompt` OK
386
- * @response `400` `ProblemDetails` Bad Request
387
- * @response `404` `ProblemDetails` Not Found
388
- */
389
- updateAiPromptTools: (id, data, params = {}) => this.request(Object.assign({ path: `/api/ai/prompts/${id}/tools`, method: "PUT", body: data, secure: true, type: "application/json", format: "json" }, params)),
390
372
  /**
391
373
  * No description
392
374
  *
@@ -3126,6 +3108,36 @@ export class Api extends HttpClient {
3126
3108
  * @response `409` `ProblemDetails` Conflict
3127
3109
  */
3128
3110
  restoreLoanApplication: (loanId, params = {}) => this.request(Object.assign({ path: `/api/loans/${loanId}/application/restore`, method: "POST", secure: true }, params)),
3111
+ /**
3112
+ * No description
3113
+ *
3114
+ * @tags LoanBorrowerRemoval
3115
+ * @name RemoveLoanBorrower
3116
+ * @summary Remove a co-borrower from an application in progress
3117
+ * @request POST:/api/loans/{loanId}/borrowers/{borrowerId}/remove
3118
+ * @secure
3119
+ * @response `204` `void` No Content
3120
+ * @response `400` `ProblemDetails` Bad Request
3121
+ * @response `403` `ProblemDetails` Forbidden
3122
+ * @response `404` `ProblemDetails` Not Found
3123
+ * @response `409` `ProblemDetails` Conflict
3124
+ */
3125
+ removeLoanBorrower: (loanId, borrowerId, params = {}) => this.request(Object.assign({ path: `/api/loans/${loanId}/borrowers/${borrowerId}/remove`, method: "POST", secure: true }, params)),
3126
+ /**
3127
+ * No description
3128
+ *
3129
+ * @tags LoanBorrowerRemoval
3130
+ * @name RestoreLoanBorrower
3131
+ * @summary Restore a removed co-borrower to an application in progress
3132
+ * @request POST:/api/loans/{loanId}/borrowers/{borrowerId}/restore
3133
+ * @secure
3134
+ * @response `204` `void` No Content
3135
+ * @response `400` `ProblemDetails` Bad Request
3136
+ * @response `403` `ProblemDetails` Forbidden
3137
+ * @response `404` `ProblemDetails` Not Found
3138
+ * @response `409` `ProblemDetails` Conflict
3139
+ */
3140
+ restoreLoanBorrower: (loanId, borrowerId, params = {}) => this.request(Object.assign({ path: `/api/loans/${loanId}/borrowers/${borrowerId}/restore`, method: "POST", secure: true }, params)),
3129
3141
  /**
3130
3142
  * No description
3131
3143
  *
@@ -3357,14 +3369,15 @@ export class Api extends HttpClient {
3357
3369
  *
3358
3370
  * @tags LoanDocumentFolders
3359
3371
  * @name DeactivateLoanDocumentFolder
3360
- * @summary Deactivate a loan document folder. Rejected for the system-default Unassigned folder.
3372
+ * @summary Deactivate a loan document folder. Rejected with 409 (errorCode FolderInUse, the referencing tasks and templates in references) while tasks or document templates still reference it, unless reassignToFolderId names an active replacement folder, in which case every reference is moved there and the folder is deactivated in one transaction. Rejected for the system-default Unassigned folder.
3361
3373
  * @request POST:/api/loan-document-folders/{id}/deactivate
3362
3374
  * @secure
3363
3375
  * @response `204` `void` No Content
3364
3376
  * @response `400` `ProblemDetails` Bad Request
3365
3377
  * @response `404` `ProblemDetails` Not Found
3378
+ * @response `409` `ProblemDetails` Conflict
3366
3379
  */
3367
- deactivateLoanDocumentFolder: (id, params = {}) => this.request(Object.assign({ path: `/api/loan-document-folders/${id}/deactivate`, method: "POST", secure: true }, params)),
3380
+ deactivateLoanDocumentFolder: (id, data, params = {}) => this.request(Object.assign({ path: `/api/loan-document-folders/${id}/deactivate`, method: "POST", body: data, secure: true, type: "application/json" }, params)),
3368
3381
  /**
3369
3382
  * No description
3370
3383
  *