oneentry 1.0.137 → 1.0.138
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/admins/adminsApi.d.ts +2 -2
- package/dist/admins/adminsApi.js +2 -2
- package/dist/admins/adminsInterfaces.d.ts +1 -1
- package/dist/attribute-sets/attributeSetsApi.d.ts +8 -8
- package/dist/attribute-sets/attributeSetsApi.js +8 -8
- package/dist/attribute-sets/attributeSetsInterfaces.d.ts +3 -3
- package/dist/auth-provider/authProviderApi.d.ts +33 -33
- package/dist/auth-provider/authProviderApi.js +33 -33
- package/dist/auth-provider/authProvidersInterfaces.d.ts +12 -62
- package/dist/base/asyncModules.js +4 -50
- package/dist/base/stateModule.d.ts +1 -0
- package/dist/base/stateModule.js +16 -15
- package/dist/base/syncModules.d.ts +6 -0
- package/dist/base/syncModules.js +48 -5
- package/dist/base/utils.d.ts +15 -8
- package/dist/blocks/blocksApi.d.ts +10 -10
- package/dist/blocks/blocksApi.js +10 -10
- package/dist/blocks/blocksInterfaces.d.ts +1 -0
- package/dist/events/eventsApi.d.ts +5 -5
- package/dist/events/eventsApi.js +5 -5
- package/dist/events/eventsInterfaces.d.ts +25 -15
- package/dist/file-uploading/fileUploadingApi.d.ts +6 -6
- package/dist/file-uploading/fileUploadingApi.js +6 -6
- package/dist/forms/formsApi.d.ts +4 -4
- package/dist/forms/formsApi.js +4 -4
- package/dist/forms/formsInterfaces.d.ts +1 -0
- package/dist/forms-data/formsDataApi.d.ts +10 -10
- package/dist/forms-data/formsDataApi.js +10 -10
- package/dist/forms-data/formsDataInterfaces.d.ts +24 -24
- package/dist/forms-data/formsDataSchemas.d.ts +36 -28
- package/dist/forms-data/formsDataSchemas.js +16 -13
- package/dist/general-types/generalTypesApi.d.ts +2 -2
- package/dist/general-types/generalTypesApi.js +2 -2
- package/dist/index.d.ts +23 -1
- package/dist/integration-collections/integrationCollectionsApi.d.ts +17 -17
- package/dist/integration-collections/integrationCollectionsApi.js +17 -17
- package/dist/locales/localesApi.d.ts +2 -2
- package/dist/locales/localesApi.js +2 -2
- package/dist/menus/menusApi.d.ts +2 -2
- package/dist/menus/menusApi.js +2 -2
- package/dist/menus/menusInterfaces.d.ts +2 -2
- package/dist/orders/ordersApi.d.ts +12 -12
- package/dist/orders/ordersApi.js +12 -12
- package/dist/orders/ordersInterfaces.d.ts +2 -1
- package/dist/pages/pagesApi.d.ts +20 -20
- package/dist/pages/pagesApi.js +20 -20
- package/dist/pages/pagesInterfaces.d.ts +10 -7
- package/dist/payments/paymentsApi.d.ts +13 -13
- package/dist/payments/paymentsApi.js +12 -12
- package/dist/payments/paymentsInterfaces.d.ts +8 -2
- package/dist/payments/paymentsSchemas.d.ts +22 -6
- package/dist/payments/paymentsSchemas.js +6 -3
- package/dist/product-statuses/productStatusesApi.d.ts +6 -6
- package/dist/product-statuses/productStatusesApi.js +6 -6
- package/dist/products/productsApi.d.ts +29 -28
- package/dist/products/productsApi.js +31 -30
- package/dist/products/productsInterfaces.d.ts +26 -21
- package/dist/system/systemApi.d.ts +10 -10
- package/dist/system/systemApi.js +10 -10
- package/dist/templates/templatesApi.d.ts +6 -6
- package/dist/templates/templatesApi.js +6 -6
- package/dist/templates-preview/templatesPreviewApi.d.ts +3 -3
- package/dist/templates-preview/templatesPreviewApi.js +3 -3
- package/dist/templates-preview/templatesPreviewInterfaces.d.ts +1 -0
- package/dist/users/usersApi.d.ts +18 -18
- package/dist/users/usersApi.js +18 -18
- package/dist/users/usersInterfaces.d.ts +8 -10
- package/package.json +34 -11
- package/dist/config.d.ts +0 -21
- package/dist/config.js +0 -48
package/dist/users/usersApi.d.ts
CHANGED
|
@@ -20,8 +20,8 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
20
20
|
* Getting the data of an authorized user.
|
|
21
21
|
* @handleName getUser
|
|
22
22
|
* @param {string} [langCode] - Language code. Default: "en_US".
|
|
23
|
-
* @returns {IUserEntity} Returns a promise that resolves to the user entity object if successful; otherwise, returns an error object.
|
|
24
|
-
* @throws {IError}
|
|
23
|
+
* @returns {Promise<IUserEntity | IError>} Returns a promise that resolves to the user entity object if successful; otherwise, returns an error object.
|
|
24
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
25
25
|
* @description This method requires user authorization.
|
|
26
26
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
27
27
|
*/
|
|
@@ -70,8 +70,8 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
70
70
|
"value": "password"
|
|
71
71
|
}
|
|
72
72
|
]
|
|
73
|
-
* @param {string} body.authData[
|
|
74
|
-
* @param {string} body.authData[
|
|
73
|
+
* @param {string} body.authData[].marker - Identifies the field being used. Example: "email_reg".
|
|
74
|
+
* @param {string} body.authData[].value - Contains the value of the field. Example: "example@oneentry.cloud".
|
|
75
75
|
* @param {string} body.formData - Contains additional data for the user.
|
|
76
76
|
* @example
|
|
77
77
|
[
|
|
@@ -81,9 +81,9 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
81
81
|
"value": "Username"
|
|
82
82
|
}
|
|
83
83
|
]
|
|
84
|
-
* @param {string} body.formData[
|
|
85
|
-
* @param {string} body.formData[
|
|
86
|
-
* @param {string} body.formData[
|
|
84
|
+
* @param {string} body.formData[].marker - The marker of the field. Example: "last_name".
|
|
85
|
+
* @param {string} body.formData[].type - The type of the field. Example: "string".
|
|
86
|
+
* @param {string} body.formData[].value - The value of the field. Example: "Username".
|
|
87
87
|
* @param {string} body.notificationData - The notification data.
|
|
88
88
|
* @example
|
|
89
89
|
{
|
|
@@ -95,8 +95,8 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
95
95
|
* @param {string} body.notificationData.phonePush - An array of phone numbers for push notifications. Example: ["+99999999999"].
|
|
96
96
|
* @param {string} body.notificationData.phoneSMS - The phone number for SMS notifications. Example: "+99999999999".
|
|
97
97
|
* @param {string} [langCode] - Language code. Default: "en_US".
|
|
98
|
-
* @returns {boolean} Returns `true` if the user object was successfully updated; otherwise, returns an error object.
|
|
99
|
-
* @throws {IError}
|
|
98
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user object was successfully updated; otherwise, returns an error object.
|
|
99
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
100
100
|
* @description This method updates the user's data. This method requires user authorization.
|
|
101
101
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
102
102
|
* @see For more information about {@link https://doc.oneentry.cloud/docs/forms/create-form registration forms}, see the documentation in the {@link https://doc.oneentry.cloud/docs/forms/create-form forms configuration section}.
|
|
@@ -105,17 +105,17 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
105
105
|
/**
|
|
106
106
|
* Archiving one user object (marked for deletion).
|
|
107
107
|
* @handleName archiveUser
|
|
108
|
-
* @returns {boolean} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
109
|
-
* @throws {IError}
|
|
108
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
109
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
110
110
|
* @description This method archives a user object (marks it for deletion). This method requires user authorization.
|
|
111
|
-
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/
|
|
111
|
+
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/auth-provider/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
112
112
|
*/
|
|
113
113
|
archiveUser(): Promise<boolean | IError>;
|
|
114
114
|
/**
|
|
115
115
|
* Delete a single user.
|
|
116
116
|
* @handleName deleteUser
|
|
117
|
-
* @returns {boolean} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
118
|
-
* @throws {IError}
|
|
117
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
118
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
119
119
|
* @description This method deletes the user from the system. This method requires user authorization.
|
|
120
120
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
121
121
|
*/
|
|
@@ -124,8 +124,8 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
124
124
|
* Adds an FCM (Firebase Cloud Messaging) token for sending push notifications.
|
|
125
125
|
* @handleName addFCMToken
|
|
126
126
|
* @param {string} token - The cloud messaging token to be added. This token is used to identify the user's device for push notifications. Example: "fcm_token_1234567890abcdefg".
|
|
127
|
-
* @returns {boolean} Returns `true` if the token was successfully added; otherwise, returns an error object.
|
|
128
|
-
* @throws {IError}
|
|
127
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the token was successfully added; otherwise, returns an error object.
|
|
128
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
129
129
|
* @description This method adds an FCM token for sending push notifications. This method requires user authorization.
|
|
130
130
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
131
131
|
*/
|
|
@@ -134,8 +134,8 @@ export default class UsersApi extends AsyncModules implements IUsers {
|
|
|
134
134
|
* Deletes an FCM (Firebase Cloud Messaging) token.
|
|
135
135
|
* @handleName deleteFCMToken
|
|
136
136
|
* @param {string} token - The cloud messaging token to be deleted. This token is used to identify the user's device for push notifications and will be removed. Example: "fcm_token_1234567890abcdefg".
|
|
137
|
-
* @returns {boolean} Returns `true` if the token was successfully deleted; otherwise, returns an error object.
|
|
138
|
-
* @throws {IError}
|
|
137
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the token was successfully deleted; otherwise, returns an error object.
|
|
138
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
139
139
|
* @description This method deletes an existing FCM token. This method requires user authorization.
|
|
140
140
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
141
141
|
*/
|
package/dist/users/usersApi.js
CHANGED
|
@@ -24,8 +24,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
24
24
|
* Getting the data of an authorized user.
|
|
25
25
|
* @handleName getUser
|
|
26
26
|
* @param {string} [langCode] - Language code. Default: "en_US".
|
|
27
|
-
* @returns {IUserEntity} Returns a promise that resolves to the user entity object if successful; otherwise, returns an error object.
|
|
28
|
-
* @throws {IError}
|
|
27
|
+
* @returns {Promise<IUserEntity | IError>} Returns a promise that resolves to the user entity object if successful; otherwise, returns an error object.
|
|
28
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
29
29
|
* @description This method requires user authorization.
|
|
30
30
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
31
31
|
*/
|
|
@@ -79,8 +79,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
79
79
|
"value": "password"
|
|
80
80
|
}
|
|
81
81
|
]
|
|
82
|
-
* @param {string} body.authData[
|
|
83
|
-
* @param {string} body.authData[
|
|
82
|
+
* @param {string} body.authData[].marker - Identifies the field being used. Example: "email_reg".
|
|
83
|
+
* @param {string} body.authData[].value - Contains the value of the field. Example: "example@oneentry.cloud".
|
|
84
84
|
* @param {string} body.formData - Contains additional data for the user.
|
|
85
85
|
* @example
|
|
86
86
|
[
|
|
@@ -90,9 +90,9 @@ class UsersApi extends asyncModules_1.default {
|
|
|
90
90
|
"value": "Username"
|
|
91
91
|
}
|
|
92
92
|
]
|
|
93
|
-
* @param {string} body.formData[
|
|
94
|
-
* @param {string} body.formData[
|
|
95
|
-
* @param {string} body.formData[
|
|
93
|
+
* @param {string} body.formData[].marker - The marker of the field. Example: "last_name".
|
|
94
|
+
* @param {string} body.formData[].type - The type of the field. Example: "string".
|
|
95
|
+
* @param {string} body.formData[].value - The value of the field. Example: "Username".
|
|
96
96
|
* @param {string} body.notificationData - The notification data.
|
|
97
97
|
* @example
|
|
98
98
|
{
|
|
@@ -104,8 +104,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
104
104
|
* @param {string} body.notificationData.phonePush - An array of phone numbers for push notifications. Example: ["+99999999999"].
|
|
105
105
|
* @param {string} body.notificationData.phoneSMS - The phone number for SMS notifications. Example: "+99999999999".
|
|
106
106
|
* @param {string} [langCode] - Language code. Default: "en_US".
|
|
107
|
-
* @returns {boolean} Returns `true` if the user object was successfully updated; otherwise, returns an error object.
|
|
108
|
-
* @throws {IError}
|
|
107
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user object was successfully updated; otherwise, returns an error object.
|
|
108
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
109
109
|
* @description This method updates the user's data. This method requires user authorization.
|
|
110
110
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
111
111
|
* @see For more information about {@link https://doc.oneentry.cloud/docs/forms/create-form registration forms}, see the documentation in the {@link https://doc.oneentry.cloud/docs/forms/create-form forms configuration section}.
|
|
@@ -123,10 +123,10 @@ class UsersApi extends asyncModules_1.default {
|
|
|
123
123
|
/**
|
|
124
124
|
* Archiving one user object (marked for deletion).
|
|
125
125
|
* @handleName archiveUser
|
|
126
|
-
* @returns {boolean} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
127
|
-
* @throws {IError}
|
|
126
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
127
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
128
128
|
* @description This method archives a user object (marks it for deletion). This method requires user authorization.
|
|
129
|
-
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/
|
|
129
|
+
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/auth-provider/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
130
130
|
*/
|
|
131
131
|
async archiveUser() {
|
|
132
132
|
const result = await this._fetchDelete('/me');
|
|
@@ -135,8 +135,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
135
135
|
/**
|
|
136
136
|
* Delete a single user.
|
|
137
137
|
* @handleName deleteUser
|
|
138
|
-
* @returns {boolean} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
139
|
-
* @throws {IError}
|
|
138
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the user was successfully deleted; otherwise, returns an error object.
|
|
139
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
140
140
|
* @description This method deletes the user from the system. This method requires user authorization.
|
|
141
141
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
142
142
|
*/
|
|
@@ -148,8 +148,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
148
148
|
* Adds an FCM (Firebase Cloud Messaging) token for sending push notifications.
|
|
149
149
|
* @handleName addFCMToken
|
|
150
150
|
* @param {string} token - The cloud messaging token to be added. This token is used to identify the user's device for push notifications. Example: "fcm_token_1234567890abcdefg".
|
|
151
|
-
* @returns {boolean} Returns `true` if the token was successfully added; otherwise, returns an error object.
|
|
152
|
-
* @throws {IError}
|
|
151
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the token was successfully added; otherwise, returns an error object.
|
|
152
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
153
153
|
* @description This method adds an FCM token for sending push notifications. This method requires user authorization.
|
|
154
154
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
155
155
|
*/
|
|
@@ -161,8 +161,8 @@ class UsersApi extends asyncModules_1.default {
|
|
|
161
161
|
* Deletes an FCM (Firebase Cloud Messaging) token.
|
|
162
162
|
* @handleName deleteFCMToken
|
|
163
163
|
* @param {string} token - The cloud messaging token to be deleted. This token is used to identify the user's device for push notifications and will be removed. Example: "fcm_token_1234567890abcdefg".
|
|
164
|
-
* @returns {boolean} Returns `true` if the token was successfully deleted; otherwise, returns an error object.
|
|
165
|
-
* @throws {IError}
|
|
164
|
+
* @returns {Promise<boolean | IError>} Returns `true` if the token was successfully deleted; otherwise, returns an error object.
|
|
165
|
+
* @throws {IError} When isShell=false and an error occurs during the fetch
|
|
166
166
|
* @description This method deletes an existing FCM token. This method requires user authorization.
|
|
167
167
|
* @see For more information about configuring the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider authorization module}, see the documentation in the {@link https://js-sdk.oneentry.cloud/docs/category/authprovider configuration settings section of the SDK}.
|
|
168
168
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
import type { IAuthFormData } from '../auth-provider/authProvidersInterfaces';
|
|
1
|
+
import type { IAuthData, IAuthFormData } from '../auth-provider/authProvidersInterfaces';
|
|
3
2
|
import type { IError } from '../base/utils';
|
|
3
|
+
import type { IFormConfig } from '../forms/formsInterfaces';
|
|
4
4
|
import type { FormDataType } from '../forms-data/formsDataInterfaces';
|
|
5
5
|
/**
|
|
6
6
|
* Interface representing user-related operations.
|
|
@@ -154,13 +154,14 @@ interface IUsers {
|
|
|
154
154
|
}
|
|
155
155
|
]
|
|
156
156
|
* @property {string} formIdentifier - Text identifier of the form. Example: "form_12345".
|
|
157
|
-
* @property {
|
|
157
|
+
* @property {string} total - Total value. Example: "0".
|
|
158
|
+
* @property {Array<string | number>} groups - Array of user groups.
|
|
158
159
|
* @example
|
|
159
160
|
[
|
|
160
161
|
"group_1",
|
|
161
162
|
"group_2"
|
|
162
163
|
]
|
|
163
|
-
* @property {
|
|
164
|
+
* @property {object} state - Object containing additional user state information.
|
|
164
165
|
* @example
|
|
165
166
|
{
|
|
166
167
|
"key": "value"
|
|
@@ -183,7 +184,7 @@ interface IUserEntity {
|
|
|
183
184
|
* @interface IUserBody
|
|
184
185
|
* @property {string} formIdentifier - Text identifier of the form. Example: "form_12345".
|
|
185
186
|
* @property {string} [langCode] - Language code for localization. Default: "en_US".
|
|
186
|
-
* @property {
|
|
187
|
+
* @property {IAuthData[]} [authData] - Array of authentication data objects with markers and values.
|
|
187
188
|
* @example
|
|
188
189
|
[
|
|
189
190
|
{
|
|
@@ -212,7 +213,7 @@ interface IUserEntity {
|
|
|
212
213
|
"phonePush": ["+99999999999"],
|
|
213
214
|
"phoneSMS": "+99999999999"
|
|
214
215
|
}
|
|
215
|
-
* @property {
|
|
216
|
+
* @property {object} [state] - Object containing additional state information.
|
|
216
217
|
* @example
|
|
217
218
|
{
|
|
218
219
|
"key": "value"
|
|
@@ -222,10 +223,7 @@ interface IUserEntity {
|
|
|
222
223
|
interface IUserBody {
|
|
223
224
|
formIdentifier: string;
|
|
224
225
|
langCode?: string;
|
|
225
|
-
authData?:
|
|
226
|
-
marker: string;
|
|
227
|
-
value: string;
|
|
228
|
-
}>;
|
|
226
|
+
authData?: IAuthData[];
|
|
229
227
|
formData?: IAuthFormData | IAuthFormData[];
|
|
230
228
|
notificationData?: {
|
|
231
229
|
email: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oneentry",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.138",
|
|
4
4
|
"description": "OneEntry NPM package",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -11,29 +11,50 @@
|
|
|
11
11
|
"productionBuild": "run-s lint testAll build",
|
|
12
12
|
"testAll": "run-s admins attributesets authProvider blocks events fileuploading forms formsdata generaltypes integrationcollections locales menus orders pages payments productstatuses products templates templatespreview users",
|
|
13
13
|
"admins": "npx jest src/admins/tests/admins.spec.ts",
|
|
14
|
+
"update admins": "npx jest src/admins/tests/admins.spec.ts --updateSnapshot",
|
|
14
15
|
"attributesets": "npx jest src/attribute-sets/tests/attributesets.spec.ts",
|
|
16
|
+
"update attributesets": "npx jest src/attribute-sets/tests/attributesets.spec.ts --updateSnapshot",
|
|
15
17
|
"authProvider": "npx jest src/auth-provider/tests/authProvider.spec.ts",
|
|
18
|
+
"update authProvider": "npx jest src/auth-provider/tests/authProvider.spec.ts --updateSnapshot",
|
|
16
19
|
"blocks": "npx jest src/blocks/tests/blocks.spec.ts",
|
|
20
|
+
"update blocks": "npx jest src/blocks/tests/blocks.spec.ts --updateSnapshot",
|
|
17
21
|
"events": "npx jest src/events/tests/events.spec.ts",
|
|
22
|
+
"update events": "npx jest src/events/tests/events.spec.ts --updateSnapshot",
|
|
18
23
|
"fileuploading": "npx jest src/file-uploading/tests/fileuploading.spec.ts",
|
|
24
|
+
"update fileuploading": "npx jest src/file-uploading/tests/fileuploading.spec.ts --updateSnapshot",
|
|
19
25
|
"forms": "npx jest src/forms/tests/forms.spec.ts",
|
|
26
|
+
"update forms": "npx jest src/forms/tests/forms.spec.ts --updateSnapshot",
|
|
20
27
|
"formsdata": "npx jest src/forms-data/tests/formsdata.spec.ts",
|
|
28
|
+
"update formsdata": "npx jest src/forms-data/tests/formsdata.spec.ts --updateSnapshot",
|
|
21
29
|
"generaltypes": "npx jest src/general-types/tests/generaltypes.spec.ts",
|
|
30
|
+
"update generaltypes": "npx jest src/general-types/tests/generaltypes.spec.ts --updateSnapshot",
|
|
22
31
|
"integrationcollections": "npx jest src/integration-collections/tests/integrationcollections.spec.ts",
|
|
32
|
+
"update integrationcollections": "npx jest src/integration-collections/tests/integrationcollections.spec.ts --updateSnapshot",
|
|
23
33
|
"locales": "npx jest src/locales/tests/locales.spec.ts",
|
|
34
|
+
"update locales": "npx jest src/locales/tests/locales.spec.ts --updateSnapshot",
|
|
24
35
|
"menus": "npx jest src/menus/tests/menus.spec.ts",
|
|
36
|
+
"update menus": "npx jest src/menus/tests/menus.spec.ts --updateSnapshot",
|
|
25
37
|
"orders": "npx jest src/orders/tests/orders.spec.ts",
|
|
38
|
+
"update orders": "npx jest src/orders/tests/orders.spec.ts --updateSnapshot",
|
|
26
39
|
"pages": "npx jest src/pages/tests/pages.spec.ts",
|
|
40
|
+
"update pages": "npx jest src/pages/tests/pages.spec.ts --updateSnapshot",
|
|
27
41
|
"payments": "npx jest src/payments/tests/payments.spec.ts",
|
|
42
|
+
"update payments": "npx jest src/payments/tests/payments.spec.ts --updateSnapshot",
|
|
28
43
|
"productstatuses": "npx jest src/product-statuses/tests/productstatuses.spec.ts",
|
|
44
|
+
"update productstatuses": "npx jest src/product-statuses/tests/productstatuses.spec.ts --updateSnapshot",
|
|
29
45
|
"products": "npx jest src/products/tests/products.spec.ts",
|
|
46
|
+
"update products": "npx jest src/products/tests/products.spec.ts --updateSnapshot",
|
|
30
47
|
"templates": "npx jest src/templates/tests/templates.spec.ts",
|
|
48
|
+
"update templates": "npx jest src/templates/tests/templates.spec.ts --updateSnapshot",
|
|
31
49
|
"templatespreview": "npx jest src/templates-preview/tests/templatespreview.spec.ts",
|
|
50
|
+
"update templatespreview": "npx jest src/templates-preview/tests/templatespreview.spec.ts --updateSnapshot",
|
|
32
51
|
"users": "npx jest src/users/tests/users.spec.ts",
|
|
52
|
+
"update users": "npx jest src/users/tests/users.spec.ts --updateSnapshot",
|
|
33
53
|
"lint": "npx eslint .",
|
|
34
54
|
"tsc": "npx tsc --noEmit --watch false",
|
|
35
55
|
"lintFix": "npx eslint . --fix",
|
|
36
|
-
"build": "npx tsc"
|
|
56
|
+
"build": "npx tsc",
|
|
57
|
+
"updateSnapshots": "npx jest --updateSnapshot"
|
|
37
58
|
},
|
|
38
59
|
"bin": {
|
|
39
60
|
"oneentry": "./configure.js"
|
|
@@ -41,31 +62,33 @@
|
|
|
41
62
|
"author": "ONEENTRY PORTAL CO.",
|
|
42
63
|
"license": "ISC",
|
|
43
64
|
"dependencies": {
|
|
44
|
-
"io": "^1.5.
|
|
65
|
+
"io": "^1.5.8",
|
|
45
66
|
"socket.io-client": "^4.8.3",
|
|
46
|
-
"zod": "^4.3.
|
|
67
|
+
"zod": "^4.3.6"
|
|
47
68
|
},
|
|
48
69
|
"devDependencies": {
|
|
70
|
+
"@eslint/eslintrc": "^3.3.3",
|
|
49
71
|
"@jest/globals": "^30.2.0",
|
|
50
72
|
"@types/eslint-config-prettier": "^6.11.3",
|
|
51
73
|
"@types/jest": "^30.0.0",
|
|
52
|
-
"@types/node": "^25.
|
|
53
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
54
|
-
"@typescript-eslint/parser": "^8.
|
|
74
|
+
"@types/node": "^25.2.3",
|
|
75
|
+
"@typescript-eslint/eslint-plugin": "^8.55.0",
|
|
76
|
+
"@typescript-eslint/parser": "^8.55.0",
|
|
55
77
|
"eslint": "^9.39.2",
|
|
56
78
|
"eslint-config-prettier": "^10.1.8",
|
|
57
79
|
"eslint-plugin-import": "^2.32.0",
|
|
58
|
-
"eslint-plugin-jest": "^29.
|
|
80
|
+
"eslint-plugin-jest": "^29.15.0",
|
|
59
81
|
"eslint-plugin-jest-extended": "^3.0.1",
|
|
60
|
-
"eslint-plugin-jsdoc": "^
|
|
61
|
-
"eslint-plugin-prettier": "^5.5.
|
|
82
|
+
"eslint-plugin-jsdoc": "^62.5.5",
|
|
83
|
+
"eslint-plugin-prettier": "^5.5.5",
|
|
62
84
|
"eslint-plugin-simple-import-sort": "^12.1.1",
|
|
63
85
|
"jest": "^30.2.0",
|
|
64
86
|
"jest-extended": "^7.0.0",
|
|
65
87
|
"jsdoc": "^4.0.5",
|
|
66
88
|
"npm-run-all": "^4.1.5",
|
|
67
|
-
"prettier": "^3.
|
|
89
|
+
"prettier": "^3.8.1",
|
|
68
90
|
"ts-jest": "^29.4.6",
|
|
91
|
+
"ts-node": "^10.9.2",
|
|
69
92
|
"typescript": "^5.9.3"
|
|
70
93
|
}
|
|
71
94
|
}
|
package/dist/config.d.ts
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* OneEntry SDK Configuration
|
|
3
|
-
* Uses environment variables when available, falls back to test defaults
|
|
4
|
-
*
|
|
5
|
-
* Environment variables (Node.js only):
|
|
6
|
-
* - ONEENTRY_PROJECT_URL: Your OneEntry project URL
|
|
7
|
-
* - ONEENTRY_API_TOKEN: Your OneEntry API token (JWT)
|
|
8
|
-
*/
|
|
9
|
-
export declare const projectUrl: string;
|
|
10
|
-
export declare const projectToken: string;
|
|
11
|
-
/**
|
|
12
|
-
* authData
|
|
13
|
-
*/
|
|
14
|
-
export declare const authData: {
|
|
15
|
-
marker: string;
|
|
16
|
-
value: string;
|
|
17
|
-
}[];
|
|
18
|
-
export declare const authData2: {
|
|
19
|
-
marker: string;
|
|
20
|
-
value: string;
|
|
21
|
-
}[];
|
package/dist/config.js
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* OneEntry SDK Configuration
|
|
4
|
-
* Uses environment variables when available, falls back to test defaults
|
|
5
|
-
*
|
|
6
|
-
* Environment variables (Node.js only):
|
|
7
|
-
* - ONEENTRY_PROJECT_URL: Your OneEntry project URL
|
|
8
|
-
* - ONEENTRY_API_TOKEN: Your OneEntry API token (JWT)
|
|
9
|
-
*/
|
|
10
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
11
|
-
exports.authData2 = exports.authData = exports.projectToken = exports.projectUrl = void 0;
|
|
12
|
-
// Helper to safely get environment variable (works in both Node.js and browser)
|
|
13
|
-
const getEnv = (key) => {
|
|
14
|
-
if (typeof process !== 'undefined' && (process === null || process === void 0 ? void 0 : process.env)) {
|
|
15
|
-
return process.env[key];
|
|
16
|
-
}
|
|
17
|
-
return undefined;
|
|
18
|
-
};
|
|
19
|
-
// Project URL - uses environment variable or falls back to test server
|
|
20
|
-
exports.projectUrl = getEnv('ONEENTRY_PROJECT_URL') || 'https://js-sdk-tests.oneentry.cloud';
|
|
21
|
-
// API Token - uses environment variable or falls back to test token
|
|
22
|
-
exports.projectToken = getEnv('ONEENTRY_API_TOKEN') ||
|
|
23
|
-
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJuYW1lIjoiTlBNIiwic2VyaWFsTnVtYmVyIjozLCJpYXQiOjE3NDA1OTE0MzgsImV4cCI6MTc3MjEyNzQzMX0.MWbtBoXh-MqGTWgmiMTZSkfN8N-WYv3Cv2kSPhRpFlk';
|
|
24
|
-
/**
|
|
25
|
-
* authData
|
|
26
|
-
*/
|
|
27
|
-
exports.authData = [
|
|
28
|
-
{
|
|
29
|
-
marker: 'email_reg',
|
|
30
|
-
value: 'test@test.ru',
|
|
31
|
-
},
|
|
32
|
-
{
|
|
33
|
-
marker: 'password_reg',
|
|
34
|
-
// value: '12345',
|
|
35
|
-
value: '1-1',
|
|
36
|
-
},
|
|
37
|
-
];
|
|
38
|
-
exports.authData2 = [
|
|
39
|
-
{
|
|
40
|
-
marker: 'email_reg',
|
|
41
|
-
value: 'test2@test.ru',
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
marker: 'password_reg',
|
|
45
|
-
// value: '12345',
|
|
46
|
-
value: '1-1',
|
|
47
|
-
},
|
|
48
|
-
];
|