@extrahorizon/javascript-sdk 8.9.0-dev-140-d9dfc1d → 8.9.0-dev-143-afddc5e
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/build/index.cjs.js
CHANGED
|
@@ -753,6 +753,8 @@ class NotFoundError extends ApiError {
|
|
|
753
753
|
}
|
|
754
754
|
class ResourceUnknownError extends NotFoundError {
|
|
755
755
|
}
|
|
756
|
+
class ServiceNotFoundError extends NotFoundError {
|
|
757
|
+
}
|
|
756
758
|
class NoConfiguredAppStoreProduct extends NotFoundError {
|
|
757
759
|
}
|
|
758
760
|
// 500 Server Error
|
|
@@ -927,6 +929,7 @@ const ErrorClassMap = {
|
|
|
927
929
|
414: StatusInUseError,
|
|
928
930
|
415: LockedDocumentError,
|
|
929
931
|
801: DefaultLocalizationMissingError,
|
|
932
|
+
903: ServiceNotFoundError,
|
|
930
933
|
1002: LocalizationKeyMissingError,
|
|
931
934
|
1003: TemplateFillingError,
|
|
932
935
|
1004: TemplateSyntaxError,
|
|
@@ -5542,7 +5545,7 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5542
5545
|
async function find(options) {
|
|
5543
5546
|
const result = await client.get(httpWithAuth, `/${(options === null || options === void 0 ? void 0 : options.rql) || ''}`, {
|
|
5544
5547
|
...options,
|
|
5545
|
-
customResponseKeys: ['data.
|
|
5548
|
+
customResponseKeys: ['data.inputs', 'data.outputs'],
|
|
5546
5549
|
});
|
|
5547
5550
|
return result.data;
|
|
5548
5551
|
}
|
|
@@ -5550,14 +5553,14 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5550
5553
|
async create(requestBody, options) {
|
|
5551
5554
|
const result = (await client.post(httpWithAuth, '/', requestBody, {
|
|
5552
5555
|
...options,
|
|
5553
|
-
customKeys: ['
|
|
5556
|
+
customKeys: ['inputs', 'outputs'],
|
|
5554
5557
|
}));
|
|
5555
5558
|
return result.data;
|
|
5556
5559
|
},
|
|
5557
5560
|
async update(templateId, requestBody, options) {
|
|
5558
5561
|
const result = (await client.put(httpWithAuth, `/${templateId}`, requestBody, {
|
|
5559
5562
|
...options,
|
|
5560
|
-
customKeys: ['
|
|
5563
|
+
customKeys: ['inputs', 'outputs'],
|
|
5561
5564
|
}));
|
|
5562
5565
|
return result.data;
|
|
5563
5566
|
},
|
|
@@ -5568,7 +5571,7 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5568
5571
|
async resolve(templateId, requestBody, options) {
|
|
5569
5572
|
const result = (await client.post(httpWithAuth, `/${templateId}/resolve`, requestBody, {
|
|
5570
5573
|
...options,
|
|
5571
|
-
customRequestKeys: ['
|
|
5574
|
+
customRequestKeys: ['inputs'],
|
|
5572
5575
|
customResponseKeys: ['*'],
|
|
5573
5576
|
}));
|
|
5574
5577
|
return result.data;
|
|
@@ -5610,7 +5613,7 @@ const templatesV2Service = (httpWithAuth) => {
|
|
|
5610
5613
|
};
|
|
5611
5614
|
};
|
|
5612
5615
|
|
|
5613
|
-
const version = '8.9.0-dev-
|
|
5616
|
+
const version = '8.9.0-dev-143-afddc5e';
|
|
5614
5617
|
|
|
5615
5618
|
/**
|
|
5616
5619
|
* Create ExtraHorizon client.
|
|
@@ -5876,6 +5879,7 @@ exports.RequestAbortedError = RequestAbortedError;
|
|
|
5876
5879
|
exports.ResourceAlreadyExistsError = ResourceAlreadyExistsError;
|
|
5877
5880
|
exports.ResourceUnknownError = ResourceUnknownError;
|
|
5878
5881
|
exports.ServerError = ServerError;
|
|
5882
|
+
exports.ServiceNotFoundError = ServiceNotFoundError;
|
|
5879
5883
|
exports.ServiceUnavailableError = ServiceUnavailableError;
|
|
5880
5884
|
exports.StatusInUseError = StatusInUseError;
|
|
5881
5885
|
exports.StripePaymentMethodError = StripePaymentMethodError;
|
package/build/index.mjs
CHANGED
|
@@ -723,6 +723,8 @@ class NotFoundError extends ApiError {
|
|
|
723
723
|
}
|
|
724
724
|
class ResourceUnknownError extends NotFoundError {
|
|
725
725
|
}
|
|
726
|
+
class ServiceNotFoundError extends NotFoundError {
|
|
727
|
+
}
|
|
726
728
|
class NoConfiguredAppStoreProduct extends NotFoundError {
|
|
727
729
|
}
|
|
728
730
|
// 500 Server Error
|
|
@@ -897,6 +899,7 @@ const ErrorClassMap = {
|
|
|
897
899
|
414: StatusInUseError,
|
|
898
900
|
415: LockedDocumentError,
|
|
899
901
|
801: DefaultLocalizationMissingError,
|
|
902
|
+
903: ServiceNotFoundError,
|
|
900
903
|
1002: LocalizationKeyMissingError,
|
|
901
904
|
1003: TemplateFillingError,
|
|
902
905
|
1004: TemplateSyntaxError,
|
|
@@ -5512,7 +5515,7 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5512
5515
|
async function find(options) {
|
|
5513
5516
|
const result = await client.get(httpWithAuth, `/${(options === null || options === void 0 ? void 0 : options.rql) || ''}`, {
|
|
5514
5517
|
...options,
|
|
5515
|
-
customResponseKeys: ['data.
|
|
5518
|
+
customResponseKeys: ['data.inputs', 'data.outputs'],
|
|
5516
5519
|
});
|
|
5517
5520
|
return result.data;
|
|
5518
5521
|
}
|
|
@@ -5520,14 +5523,14 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5520
5523
|
async create(requestBody, options) {
|
|
5521
5524
|
const result = (await client.post(httpWithAuth, '/', requestBody, {
|
|
5522
5525
|
...options,
|
|
5523
|
-
customKeys: ['
|
|
5526
|
+
customKeys: ['inputs', 'outputs'],
|
|
5524
5527
|
}));
|
|
5525
5528
|
return result.data;
|
|
5526
5529
|
},
|
|
5527
5530
|
async update(templateId, requestBody, options) {
|
|
5528
5531
|
const result = (await client.put(httpWithAuth, `/${templateId}`, requestBody, {
|
|
5529
5532
|
...options,
|
|
5530
|
-
customKeys: ['
|
|
5533
|
+
customKeys: ['inputs', 'outputs'],
|
|
5531
5534
|
}));
|
|
5532
5535
|
return result.data;
|
|
5533
5536
|
},
|
|
@@ -5538,7 +5541,7 @@ var templatesV2 = (client, httpWithAuth) => {
|
|
|
5538
5541
|
async resolve(templateId, requestBody, options) {
|
|
5539
5542
|
const result = (await client.post(httpWithAuth, `/${templateId}/resolve`, requestBody, {
|
|
5540
5543
|
...options,
|
|
5541
|
-
customRequestKeys: ['
|
|
5544
|
+
customRequestKeys: ['inputs'],
|
|
5542
5545
|
customResponseKeys: ['*'],
|
|
5543
5546
|
}));
|
|
5544
5547
|
return result.data;
|
|
@@ -5580,7 +5583,7 @@ const templatesV2Service = (httpWithAuth) => {
|
|
|
5580
5583
|
};
|
|
5581
5584
|
};
|
|
5582
5585
|
|
|
5583
|
-
const version = '8.9.0-dev-
|
|
5586
|
+
const version = '8.9.0-dev-143-afddc5e';
|
|
5584
5587
|
|
|
5585
5588
|
/**
|
|
5586
5589
|
* Create ExtraHorizon client.
|
|
@@ -5760,4 +5763,4 @@ const parseStoredCredentials = (fileContent) => exhCredentialsDecoder(fileConten
|
|
|
5760
5763
|
.filter(line => line.length === 2)
|
|
5761
5764
|
.reduce((memo, [key, value]) => ({ ...memo, [key]: value }), {}));
|
|
5762
5765
|
|
|
5763
|
-
export { AccessTokenExpiredError, AccessTokenUnknownError, ActionType, ActivationRequestLimitError, ActivationRequestTimeoutError, ActivationUnknownError, AlreadyActivatedError, ApiError, ApiFunctionRequestMethod, ApiRequestErrorType, AppStoreTransactionAlreadyLinked, ApplicationNotAuthenticatedError, ApplicationType, ApplicationUnknownError, AuthenticationError, AuthorizationCodeExpiredError, AuthorizationUnknownError, BadGatewayServerError, BadRequestError, BodyFormatError, CallbackNotValidError, Comorbidities, DefaultLocalizationMissingError, DisabledForOidcUsersError, DuplicateRequestError, EmailUnknownError, EmailUsedError, EmptyBodyError, ErrorClassMap, FieldFormatError, FieldType, FileTooLargeError, FirebaseConnectionError, FirebaseInvalidPlatformDataError, ForbiddenError, ForgotPasswordRequestLimitError, ForgotPasswordRequestTimeoutError, FunctionPermissionMode, Gender, GlobalPermissionName, IDFormatError, IllegalArgumentError, IllegalStateError, Impediments, IncorrectPinCodeError, InvalidClientError, InvalidCurrencyForProductPrice, InvalidGrantError, InvalidMfaCodeError, InvalidMfaTokenError, InvalidNonceError, InvalidPKCEError, InvalidPresenceTokenError, InvalidReceiptDataError, InvalidRequestError, InvalidTokenError, JSONSchemaType, LocalizationKeyMissingError, LockedDocumentError, LoginAttemptStatus, LoginFreezeError, LoginTimeoutError, MedicationFrequency, MedicationUnit, MfaReattemptDelayError, MfaRequiredError, MissingPKCEVerifierError, MissingRequiredFieldsError, NewMFARequiredError, NewPasswordHashUnknownError, NewPasswordPinCodeUnknownError, NoConfiguredAppStoreProduct, NoConfiguredPlayStoreProduct, NoMatchingPlayStoreLinkedSubscription, NoPermissionError, NotActivatedError, NotEnoughMfaMethodsError, NotFoundError, OAuth2ClientIdError, OAuth2ClientSecretError, OAuth2ErrorClassMap, OAuth2LoginError, OAuth2MissingClientCredentialsError, OauthKeyError, OauthSignatureError, OauthTokenError, OidcIdTokenError, OidcInvalidAuthorizationCodeError, OidcProviderResponseError, OrderSchemaStatus, PasswordError, PaymentIntentCreationSchemaPaymentMethodType, PaymentIntentCreationSchemaSetupPaymentMethodReuse, PinCodesNotEnabledError, PlayStoreTransactionAlreadyLinked, ProfileActivity, ProfileAlreadyExistsError, QueuedMailStatus, RefreshTokenExpiredError, RefreshTokenUnknownError, RemoveFieldError, RequestAbortedError, ResourceAlreadyExistsError, ResourceUnknownError, Results, ServerError, ServiceUnavailableError, StatusInUseError, StripePaymentMethodError, StripeRequestError, SubscriptionEntitlementSource, SubscriptionEntitlementStatus, SubscriptionEntitlementStatusCategory, SubscriptionEventSource, SubscriptionEventType, SupportedLanguageCodes, TaskStatus, TemplateFillingError, TemplateResolvingError, TemplateSyntaxError, TokenNotDeleteableError, TokenPermission, TooManyFailedAttemptsError, UnauthorizedClientError, UnauthorizedError, UnauthorizedTokenError, UnknownReceiptTransactionError, UnsupportedGrantError, UnsupportedGrantTypeError, UnsupportedResponseTypeError, UserNotAuthenticatedError, createClient, createOAuth1Client, createOAuth2Client, createProxyClient, findAllGeneric, findAllIterator, getMockSdkOAuth2 as getMockSdk, getMockSdkOAuth1, getMockSdkOAuth2, getMockSdkProxy, parseGlobalPermissions, parseStoredCredentials, recursiveMap, rqlBuilder, rqlParser };
|
|
5766
|
+
export { AccessTokenExpiredError, AccessTokenUnknownError, ActionType, ActivationRequestLimitError, ActivationRequestTimeoutError, ActivationUnknownError, AlreadyActivatedError, ApiError, ApiFunctionRequestMethod, ApiRequestErrorType, AppStoreTransactionAlreadyLinked, ApplicationNotAuthenticatedError, ApplicationType, ApplicationUnknownError, AuthenticationError, AuthorizationCodeExpiredError, AuthorizationUnknownError, BadGatewayServerError, BadRequestError, BodyFormatError, CallbackNotValidError, Comorbidities, DefaultLocalizationMissingError, DisabledForOidcUsersError, DuplicateRequestError, EmailUnknownError, EmailUsedError, EmptyBodyError, ErrorClassMap, FieldFormatError, FieldType, FileTooLargeError, FirebaseConnectionError, FirebaseInvalidPlatformDataError, ForbiddenError, ForgotPasswordRequestLimitError, ForgotPasswordRequestTimeoutError, FunctionPermissionMode, Gender, GlobalPermissionName, IDFormatError, IllegalArgumentError, IllegalStateError, Impediments, IncorrectPinCodeError, InvalidClientError, InvalidCurrencyForProductPrice, InvalidGrantError, InvalidMfaCodeError, InvalidMfaTokenError, InvalidNonceError, InvalidPKCEError, InvalidPresenceTokenError, InvalidReceiptDataError, InvalidRequestError, InvalidTokenError, JSONSchemaType, LocalizationKeyMissingError, LockedDocumentError, LoginAttemptStatus, LoginFreezeError, LoginTimeoutError, MedicationFrequency, MedicationUnit, MfaReattemptDelayError, MfaRequiredError, MissingPKCEVerifierError, MissingRequiredFieldsError, NewMFARequiredError, NewPasswordHashUnknownError, NewPasswordPinCodeUnknownError, NoConfiguredAppStoreProduct, NoConfiguredPlayStoreProduct, NoMatchingPlayStoreLinkedSubscription, NoPermissionError, NotActivatedError, NotEnoughMfaMethodsError, NotFoundError, OAuth2ClientIdError, OAuth2ClientSecretError, OAuth2ErrorClassMap, OAuth2LoginError, OAuth2MissingClientCredentialsError, OauthKeyError, OauthSignatureError, OauthTokenError, OidcIdTokenError, OidcInvalidAuthorizationCodeError, OidcProviderResponseError, OrderSchemaStatus, PasswordError, PaymentIntentCreationSchemaPaymentMethodType, PaymentIntentCreationSchemaSetupPaymentMethodReuse, PinCodesNotEnabledError, PlayStoreTransactionAlreadyLinked, ProfileActivity, ProfileAlreadyExistsError, QueuedMailStatus, RefreshTokenExpiredError, RefreshTokenUnknownError, RemoveFieldError, RequestAbortedError, ResourceAlreadyExistsError, ResourceUnknownError, Results, ServerError, ServiceNotFoundError, ServiceUnavailableError, StatusInUseError, StripePaymentMethodError, StripeRequestError, SubscriptionEntitlementSource, SubscriptionEntitlementStatus, SubscriptionEntitlementStatusCategory, SubscriptionEventSource, SubscriptionEventType, SupportedLanguageCodes, TaskStatus, TemplateFillingError, TemplateResolvingError, TemplateSyntaxError, TokenNotDeleteableError, TokenPermission, TooManyFailedAttemptsError, UnauthorizedClientError, UnauthorizedError, UnauthorizedTokenError, UnknownReceiptTransactionError, UnsupportedGrantError, UnsupportedGrantTypeError, UnsupportedResponseTypeError, UserNotAuthenticatedError, createClient, createOAuth1Client, createOAuth2Client, createProxyClient, findAllGeneric, findAllIterator, getMockSdkOAuth2 as getMockSdk, getMockSdkOAuth1, getMockSdkOAuth2, getMockSdkProxy, parseGlobalPermissions, parseStoredCredentials, recursiveMap, rqlBuilder, rqlParser };
|
package/build/types/errors.d.ts
CHANGED
|
@@ -219,6 +219,8 @@ export declare class NotFoundError extends ApiError {
|
|
|
219
219
|
}
|
|
220
220
|
export declare class ResourceUnknownError extends NotFoundError {
|
|
221
221
|
}
|
|
222
|
+
export declare class ServiceNotFoundError extends NotFoundError {
|
|
223
|
+
}
|
|
222
224
|
export declare class NoConfiguredAppStoreProduct extends NotFoundError {
|
|
223
225
|
}
|
|
224
226
|
export declare class ServerError extends ApiError {
|
|
@@ -331,6 +333,7 @@ export declare const ErrorClassMap: {
|
|
|
331
333
|
414: typeof StatusInUseError;
|
|
332
334
|
415: typeof LockedDocumentError;
|
|
333
335
|
801: typeof DefaultLocalizationMissingError;
|
|
336
|
+
903: typeof ServiceNotFoundError;
|
|
334
337
|
1002: typeof LocalizationKeyMissingError;
|
|
335
338
|
1003: typeof TemplateFillingError;
|
|
336
339
|
1004: typeof TemplateSyntaxError;
|
|
@@ -7,9 +7,15 @@ export interface TemplateV2 extends TemplateV2Creation {
|
|
|
7
7
|
export interface TemplateV2Creation {
|
|
8
8
|
name: string;
|
|
9
9
|
description?: string;
|
|
10
|
-
|
|
10
|
+
inputs?: Record<string, TemplateV2TypeConfiguration>;
|
|
11
11
|
outputs: Record<string, string>;
|
|
12
12
|
}
|
|
13
|
+
export interface TemplateV2Update {
|
|
14
|
+
name?: string;
|
|
15
|
+
description?: string | null;
|
|
16
|
+
inputs?: Record<string, TemplateV2TypeConfiguration> | null;
|
|
17
|
+
outputs?: Record<string, string>;
|
|
18
|
+
}
|
|
13
19
|
export declare type TemplateV2TypeConfiguration = TemplateV2ObjectConfiguration | TemplateV2ArrayConfiguration | TemplateV2StringConfiguration | TemplateV2NumberConfiguration | TemplateV2BooleanConfiguration;
|
|
14
20
|
export interface TemplateV2ObjectConfiguration {
|
|
15
21
|
type: 'object';
|
|
@@ -37,7 +43,7 @@ export interface TemplateV2ResolveIn<T extends Record<string, any>> {
|
|
|
37
43
|
* If not present (or empty) we will first check the configured time_zone in the users-service. If that is not present it will default to 'UTC'
|
|
38
44
|
*/
|
|
39
45
|
timeZone?: TimeZone;
|
|
40
|
-
|
|
46
|
+
inputs?: T;
|
|
41
47
|
}
|
|
42
48
|
export interface TemplatesV2ErrorInfo {
|
|
43
49
|
/**
|
|
@@ -95,7 +101,7 @@ export interface TemplatesV2Service {
|
|
|
95
101
|
* Permission | Scope | Effect
|
|
96
102
|
* - | - | -
|
|
97
103
|
* `CREATE_TEMPLATES` | `global` | **Required** for this endpoint
|
|
98
|
-
* @param requestBody
|
|
104
|
+
* @param requestBody TemplateV2Creation
|
|
99
105
|
* @returns TemplateV2
|
|
100
106
|
* @throws {ResourceAlreadyExistsError}
|
|
101
107
|
* @throws {TemplateSyntaxError}
|
|
@@ -108,13 +114,13 @@ export interface TemplatesV2Service {
|
|
|
108
114
|
* - | - | -
|
|
109
115
|
* `UPDATE_TEMPLATES` | `global` | **Required** for this endpoint
|
|
110
116
|
* @param templateIdOrName Id or Name of the targeted template
|
|
111
|
-
* @param requestBody
|
|
117
|
+
* @param requestBody TemplateV2Update
|
|
112
118
|
* @returns TemplateV2
|
|
113
119
|
* @throws {ResourceAlreadyExistsError}
|
|
114
120
|
* @throws {TemplateSyntaxError}
|
|
115
121
|
* @throws {ResourceUnknownError}
|
|
116
122
|
*/
|
|
117
|
-
update(templateIdOrName: string, requestBody:
|
|
123
|
+
update(templateIdOrName: string, requestBody: TemplateV2Update, options?: OptionsBase): Promise<AffectedRecords>;
|
|
118
124
|
/**
|
|
119
125
|
* Delete a template
|
|
120
126
|
*
|
package/build/types/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const version = "8.9.0-dev-
|
|
1
|
+
export declare const version = "8.9.0-dev-143-afddc5e";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@extrahorizon/javascript-sdk",
|
|
3
|
-
"version": "8.9.0-dev-
|
|
3
|
+
"version": "8.9.0-dev-143-afddc5e",
|
|
4
4
|
"description": "This package serves as a JavaScript wrapper around all Extra Horizon cloud services.",
|
|
5
5
|
"main": "build/index.cjs.js",
|
|
6
6
|
"types": "build/types/index.d.ts",
|