@stigg/api-client-js 0.0.1
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/README.md +11 -0
- package/package.json +11 -0
- package/src/generated/sdk.d.ts +2802 -0
- package/src/generated/sdk.js +1064 -0
- package/src/generated/sdk.js.map +1 -0
- package/src/index.d.ts +1 -0
- package/src/index.js +5 -0
- package/src/index.js.map +1 -0
- package/src/lib/client.d.ts +10 -0
- package/src/lib/client.js +18 -0
- package/src/lib/client.js.map +1 -0
|
@@ -0,0 +1,1064 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SubscriptionCancelReason = exports.SubscriptionAddonSortFields = exports.SourceType = exports.SortNulls = exports.SortDirection = exports.PublishMigrationType = exports.PromotionalEntitlementStatus = exports.PromotionalEntitlementSortFields = exports.PromotionalEntitlementPeriod = exports.ProductSortFields = exports.PricingType = exports.PriceSortFields = exports.PlanSortFields = exports.PaymentMethodType = exports.PackageStatus = exports.PackageEntitlementSortFields = exports.PackageDtoSortFields = exports.MonthlyAccordingTo = exports.MeterType = exports.MemberStatus = exports.MemberSortFields = exports.IntegrationSortFields = exports.ImportIntegrationTaskSortFields = exports.HookStatus = exports.HookSortFields = exports.FeatureType = exports.FeatureStatus = exports.FeatureSortFields = exports.ExperimentStatus = exports.ExperimentSortFields = exports.ExperimentGroup = exports.EventLogType = exports.ErrorCode = exports.EnvironmentSortFields = exports.EntitySelectionMode = exports.EntitlementResetPeriod = exports.CustomerSubscriptionSortFields = exports.CustomerSortFields = exports.Currency = exports.CouponType = exports.CouponStatus = exports.CouponSortFields = exports.ChangeType = exports.BillingPeriod = exports.BillingModel = exports.BillingAnchor = exports.ApiKeyType = exports.ApiKeySortFields = exports.AddonSortFields = exports.AccessDeniedReason = void 0;
|
|
4
|
+
exports.getSdk = exports.GetCouponsDocument = exports.GetPaywallDocument = exports.GetCustomerByIdDocument = exports.InitiateCheckoutDocument = exports.CancelSubscriptionDocument = exports.CreateSubscriptionDocument = exports.UpdateSubscriptionDocument = exports.UpdateCustomerDocument = exports.ImportCustomerDocument = exports.ProvisionCustomerDocument = exports.CreateCustomerDocument = exports.PaywallAddonFragmentDoc = exports.PaywallPlanFragmentDoc = exports.PaywallPriceFragmentDoc = exports.PaywallPackageEntitlementFragmentDoc = exports.SlimSubscriptionFragmentDoc = exports.CustomerFragmentDoc = exports.CouponFragmentDoc = exports.PromotionalEntitlementFragmentDoc = exports.SubscriptionFragmentDoc = exports.PlanFragmentDoc = exports.AddonFragmentDoc = exports.PackageEntitlementFragmentDoc = exports.TotalPriceFragmentDoc = exports.PriceFragmentDoc = exports.FeatureFragmentDoc = exports.WeeklyAccordingTo = exports.VendorIdentifier = exports.UsageMeasurementSortFields = exports.TrialPeriodUnits = exports.TaskType = exports.TaskStatus = exports.SyncStatus = exports.SubscriptionStrategyDecision = exports.SubscriptionStatus = exports.SubscriptionStartSetup = exports.SubscriptionPriceSortFields = exports.SubscriptionMigrationTaskSortFields = exports.SubscriptionEndSetup = exports.SubscriptionCancellationTime = void 0;
|
|
5
|
+
const graphql_tag_1 = require("graphql-tag");
|
|
6
|
+
/** DenyReason of get access policy */
|
|
7
|
+
var AccessDeniedReason;
|
|
8
|
+
(function (AccessDeniedReason) {
|
|
9
|
+
AccessDeniedReason["CustomerNotFound"] = "CustomerNotFound";
|
|
10
|
+
AccessDeniedReason["FeatureNotFound"] = "FeatureNotFound";
|
|
11
|
+
AccessDeniedReason["NoActiveSubscription"] = "NoActiveSubscription";
|
|
12
|
+
AccessDeniedReason["NoFeatureEntitlementInSubscription"] = "NoFeatureEntitlementInSubscription";
|
|
13
|
+
AccessDeniedReason["RequestedUsageExceedingLimit"] = "RequestedUsageExceedingLimit";
|
|
14
|
+
AccessDeniedReason["Unknown"] = "Unknown";
|
|
15
|
+
})(AccessDeniedReason = exports.AccessDeniedReason || (exports.AccessDeniedReason = {}));
|
|
16
|
+
var AddonSortFields;
|
|
17
|
+
(function (AddonSortFields) {
|
|
18
|
+
AddonSortFields["BillingId"] = "billingId";
|
|
19
|
+
AddonSortFields["CreatedAt"] = "createdAt";
|
|
20
|
+
AddonSortFields["Description"] = "description";
|
|
21
|
+
AddonSortFields["DisplayName"] = "displayName";
|
|
22
|
+
AddonSortFields["EnvironmentId"] = "environmentId";
|
|
23
|
+
AddonSortFields["Id"] = "id";
|
|
24
|
+
AddonSortFields["IsLatest"] = "isLatest";
|
|
25
|
+
AddonSortFields["PricingType"] = "pricingType";
|
|
26
|
+
AddonSortFields["ProductId"] = "productId";
|
|
27
|
+
AddonSortFields["RefId"] = "refId";
|
|
28
|
+
AddonSortFields["Status"] = "status";
|
|
29
|
+
AddonSortFields["UpdatedAt"] = "updatedAt";
|
|
30
|
+
AddonSortFields["VersionNumber"] = "versionNumber";
|
|
31
|
+
})(AddonSortFields = exports.AddonSortFields || (exports.AddonSortFields = {}));
|
|
32
|
+
var ApiKeySortFields;
|
|
33
|
+
(function (ApiKeySortFields) {
|
|
34
|
+
ApiKeySortFields["Id"] = "id";
|
|
35
|
+
})(ApiKeySortFields = exports.ApiKeySortFields || (exports.ApiKeySortFields = {}));
|
|
36
|
+
var ApiKeyType;
|
|
37
|
+
(function (ApiKeyType) {
|
|
38
|
+
ApiKeyType["Client"] = "CLIENT";
|
|
39
|
+
ApiKeyType["Server"] = "SERVER";
|
|
40
|
+
})(ApiKeyType = exports.ApiKeyType || (exports.ApiKeyType = {}));
|
|
41
|
+
var BillingAnchor;
|
|
42
|
+
(function (BillingAnchor) {
|
|
43
|
+
BillingAnchor["StartOfTheMonth"] = "START_OF_THE_MONTH";
|
|
44
|
+
BillingAnchor["SubscriptionStart"] = "SUBSCRIPTION_START";
|
|
45
|
+
})(BillingAnchor = exports.BillingAnchor || (exports.BillingAnchor = {}));
|
|
46
|
+
/** Billing model. */
|
|
47
|
+
var BillingModel;
|
|
48
|
+
(function (BillingModel) {
|
|
49
|
+
BillingModel["FlatFee"] = "FLAT_FEE";
|
|
50
|
+
BillingModel["PerUnit"] = "PER_UNIT";
|
|
51
|
+
BillingModel["UsageBased"] = "USAGE_BASED";
|
|
52
|
+
})(BillingModel = exports.BillingModel || (exports.BillingModel = {}));
|
|
53
|
+
/** Billing period. */
|
|
54
|
+
var BillingPeriod;
|
|
55
|
+
(function (BillingPeriod) {
|
|
56
|
+
BillingPeriod["Annually"] = "ANNUALLY";
|
|
57
|
+
BillingPeriod["Monthly"] = "MONTHLY";
|
|
58
|
+
})(BillingPeriod = exports.BillingPeriod || (exports.BillingPeriod = {}));
|
|
59
|
+
var ChangeType;
|
|
60
|
+
(function (ChangeType) {
|
|
61
|
+
ChangeType["Added"] = "ADDED";
|
|
62
|
+
ChangeType["Deleted"] = "DELETED";
|
|
63
|
+
ChangeType["Modified"] = "MODIFIED";
|
|
64
|
+
})(ChangeType = exports.ChangeType || (exports.ChangeType = {}));
|
|
65
|
+
var CouponSortFields;
|
|
66
|
+
(function (CouponSortFields) {
|
|
67
|
+
CouponSortFields["BillingId"] = "billingId";
|
|
68
|
+
CouponSortFields["CreatedAt"] = "createdAt";
|
|
69
|
+
CouponSortFields["Description"] = "description";
|
|
70
|
+
CouponSortFields["EnvironmentId"] = "environmentId";
|
|
71
|
+
CouponSortFields["Id"] = "id";
|
|
72
|
+
CouponSortFields["Name"] = "name";
|
|
73
|
+
CouponSortFields["RefId"] = "refId";
|
|
74
|
+
CouponSortFields["Status"] = "status";
|
|
75
|
+
CouponSortFields["Type"] = "type";
|
|
76
|
+
CouponSortFields["UpdatedAt"] = "updatedAt";
|
|
77
|
+
})(CouponSortFields = exports.CouponSortFields || (exports.CouponSortFields = {}));
|
|
78
|
+
/** The status of the coupon */
|
|
79
|
+
var CouponStatus;
|
|
80
|
+
(function (CouponStatus) {
|
|
81
|
+
CouponStatus["Active"] = "ACTIVE";
|
|
82
|
+
CouponStatus["Archived"] = "ARCHIVED";
|
|
83
|
+
})(CouponStatus = exports.CouponStatus || (exports.CouponStatus = {}));
|
|
84
|
+
/** The type of the coupon */
|
|
85
|
+
var CouponType;
|
|
86
|
+
(function (CouponType) {
|
|
87
|
+
CouponType["Fixed"] = "FIXED";
|
|
88
|
+
CouponType["Percentage"] = "PERCENTAGE";
|
|
89
|
+
})(CouponType = exports.CouponType || (exports.CouponType = {}));
|
|
90
|
+
/** Currency */
|
|
91
|
+
var Currency;
|
|
92
|
+
(function (Currency) {
|
|
93
|
+
Currency["Usd"] = "USD";
|
|
94
|
+
})(Currency = exports.Currency || (exports.Currency = {}));
|
|
95
|
+
var CustomerSortFields;
|
|
96
|
+
(function (CustomerSortFields) {
|
|
97
|
+
CustomerSortFields["BillingId"] = "billingId";
|
|
98
|
+
CustomerSortFields["CreatedAt"] = "createdAt";
|
|
99
|
+
CustomerSortFields["CrmHubspotCompanyId"] = "crmHubspotCompanyId";
|
|
100
|
+
CustomerSortFields["CrmHubspotCompanyUrl"] = "crmHubspotCompanyUrl";
|
|
101
|
+
CustomerSortFields["CrmId"] = "crmId";
|
|
102
|
+
CustomerSortFields["Email"] = "email";
|
|
103
|
+
CustomerSortFields["EnvironmentId"] = "environmentId";
|
|
104
|
+
CustomerSortFields["ExperimentGroup"] = "experimentGroup";
|
|
105
|
+
CustomerSortFields["Id"] = "id";
|
|
106
|
+
CustomerSortFields["Name"] = "name";
|
|
107
|
+
CustomerSortFields["RefId"] = "refId";
|
|
108
|
+
CustomerSortFields["UpdatedAt"] = "updatedAt";
|
|
109
|
+
})(CustomerSortFields = exports.CustomerSortFields || (exports.CustomerSortFields = {}));
|
|
110
|
+
var CustomerSubscriptionSortFields;
|
|
111
|
+
(function (CustomerSubscriptionSortFields) {
|
|
112
|
+
CustomerSubscriptionSortFields["BillingId"] = "billingId";
|
|
113
|
+
CustomerSubscriptionSortFields["CancelReason"] = "cancelReason";
|
|
114
|
+
CustomerSubscriptionSortFields["CancellationDate"] = "cancellationDate";
|
|
115
|
+
CustomerSubscriptionSortFields["CreatedAt"] = "createdAt";
|
|
116
|
+
CustomerSubscriptionSortFields["CrmId"] = "crmId";
|
|
117
|
+
CustomerSubscriptionSortFields["CrmLinkUrl"] = "crmLinkUrl";
|
|
118
|
+
CustomerSubscriptionSortFields["EffectiveEndDate"] = "effectiveEndDate";
|
|
119
|
+
CustomerSubscriptionSortFields["EndDate"] = "endDate";
|
|
120
|
+
CustomerSubscriptionSortFields["EnvironmentId"] = "environmentId";
|
|
121
|
+
CustomerSubscriptionSortFields["ExperimentGroup"] = "experimentGroup";
|
|
122
|
+
CustomerSubscriptionSortFields["Id"] = "id";
|
|
123
|
+
CustomerSubscriptionSortFields["PricingType"] = "pricingType";
|
|
124
|
+
CustomerSubscriptionSortFields["RefId"] = "refId";
|
|
125
|
+
CustomerSubscriptionSortFields["StartDate"] = "startDate";
|
|
126
|
+
CustomerSubscriptionSortFields["Status"] = "status";
|
|
127
|
+
CustomerSubscriptionSortFields["TrialEndDate"] = "trialEndDate";
|
|
128
|
+
})(CustomerSubscriptionSortFields = exports.CustomerSubscriptionSortFields || (exports.CustomerSubscriptionSortFields = {}));
|
|
129
|
+
/** Entitlement reset period. */
|
|
130
|
+
var EntitlementResetPeriod;
|
|
131
|
+
(function (EntitlementResetPeriod) {
|
|
132
|
+
EntitlementResetPeriod["Day"] = "DAY";
|
|
133
|
+
EntitlementResetPeriod["Hour"] = "HOUR";
|
|
134
|
+
EntitlementResetPeriod["Month"] = "MONTH";
|
|
135
|
+
EntitlementResetPeriod["Week"] = "WEEK";
|
|
136
|
+
})(EntitlementResetPeriod = exports.EntitlementResetPeriod || (exports.EntitlementResetPeriod = {}));
|
|
137
|
+
var EntitySelectionMode;
|
|
138
|
+
(function (EntitySelectionMode) {
|
|
139
|
+
EntitySelectionMode["BlackList"] = "BLACK_LIST";
|
|
140
|
+
EntitySelectionMode["WhiteList"] = "WHITE_LIST";
|
|
141
|
+
})(EntitySelectionMode = exports.EntitySelectionMode || (exports.EntitySelectionMode = {}));
|
|
142
|
+
var EnvironmentSortFields;
|
|
143
|
+
(function (EnvironmentSortFields) {
|
|
144
|
+
EnvironmentSortFields["CreatedAt"] = "createdAt";
|
|
145
|
+
EnvironmentSortFields["DisplayName"] = "displayName";
|
|
146
|
+
EnvironmentSortFields["Id"] = "id";
|
|
147
|
+
EnvironmentSortFields["Slug"] = "slug";
|
|
148
|
+
})(EnvironmentSortFields = exports.EnvironmentSortFields || (exports.EnvironmentSortFields = {}));
|
|
149
|
+
/** error codes */
|
|
150
|
+
var ErrorCode;
|
|
151
|
+
(function (ErrorCode) {
|
|
152
|
+
ErrorCode["AccountNotFoundError"] = "AccountNotFoundError";
|
|
153
|
+
ErrorCode["AddonHasToHavePriceError"] = "AddonHasToHavePriceError";
|
|
154
|
+
ErrorCode["AddonNotFound"] = "AddonNotFound";
|
|
155
|
+
ErrorCode["ArchivedCouponCantBeApplied"] = "ArchivedCouponCantBeApplied";
|
|
156
|
+
ErrorCode["BadUserInput"] = "BadUserInput";
|
|
157
|
+
ErrorCode["BillingPeriodMissingError"] = "BillingPeriodMissingError";
|
|
158
|
+
ErrorCode["CannotDeleteCustomerError"] = "CannotDeleteCustomerError";
|
|
159
|
+
ErrorCode["CannotDeleteFeatureError"] = "CannotDeleteFeatureError";
|
|
160
|
+
ErrorCode["CantCreateExperiment"] = "CantCreateExperiment";
|
|
161
|
+
ErrorCode["CheckoutIsNotSupported"] = "CheckoutIsNotSupported";
|
|
162
|
+
ErrorCode["CouponNotFound"] = "CouponNotFound";
|
|
163
|
+
ErrorCode["CustomerHasNoPaymentMethod"] = "CustomerHasNoPaymentMethod";
|
|
164
|
+
ErrorCode["CustomerNoBillingId"] = "CustomerNoBillingId";
|
|
165
|
+
ErrorCode["CustomerNotFound"] = "CustomerNotFound";
|
|
166
|
+
ErrorCode["DraftPlanCantBeArchived"] = "DraftPlanCantBeArchived";
|
|
167
|
+
ErrorCode["DuplicatedEntityNotAllowed"] = "DuplicatedEntityNotAllowed";
|
|
168
|
+
ErrorCode["EditAllowedOnDraftPackageOnlyError"] = "EditAllowedOnDraftPackageOnlyError";
|
|
169
|
+
ErrorCode["EnvironmentMissing"] = "EnvironmentMissing";
|
|
170
|
+
ErrorCode["ExperimentNotFoundError"] = "ExperimentNotFoundError";
|
|
171
|
+
ErrorCode["ExperimentStatusError"] = "ExperimentStatusError";
|
|
172
|
+
ErrorCode["FailedToImportCustomer"] = "FailedToImportCustomer";
|
|
173
|
+
ErrorCode["FeatureNotFound"] = "FeatureNotFound";
|
|
174
|
+
ErrorCode["IdentityForbidden"] = "IdentityForbidden";
|
|
175
|
+
ErrorCode["ImportAlreadyInProgress"] = "ImportAlreadyInProgress";
|
|
176
|
+
ErrorCode["InitStripePaymentMethodError"] = "InitStripePaymentMethodError";
|
|
177
|
+
ErrorCode["IntegrationNotFound"] = "IntegrationNotFound";
|
|
178
|
+
ErrorCode["IntegrityViolation"] = "IntegrityViolation";
|
|
179
|
+
ErrorCode["InvalidAddressError"] = "InvalidAddressError";
|
|
180
|
+
ErrorCode["InvalidArgumentError"] = "InvalidArgumentError";
|
|
181
|
+
ErrorCode["InvalidCancellationDate"] = "InvalidCancellationDate";
|
|
182
|
+
ErrorCode["InvalidEntitlementResetPeriod"] = "InvalidEntitlementResetPeriod";
|
|
183
|
+
ErrorCode["InvalidMemberDelete"] = "InvalidMemberDelete";
|
|
184
|
+
ErrorCode["InvalidQuantity"] = "InvalidQuantity";
|
|
185
|
+
ErrorCode["InvalidSubscriptionStatus"] = "InvalidSubscriptionStatus";
|
|
186
|
+
ErrorCode["InvalidUpdatePriceUnitAmountError"] = "InvalidUpdatePriceUnitAmountError";
|
|
187
|
+
ErrorCode["InvalidUsageValueForIncrementalFeatureError"] = "InvalidUsageValueForIncrementalFeatureError";
|
|
188
|
+
ErrorCode["MemberInvitationError"] = "MemberInvitationError";
|
|
189
|
+
ErrorCode["MemberNotFound"] = "MemberNotFound";
|
|
190
|
+
ErrorCode["MeteringNotAvailableForFeatureType"] = "MeteringNotAvailableForFeatureType";
|
|
191
|
+
ErrorCode["NoFeatureEntitlementInSubscription"] = "NoFeatureEntitlementInSubscription";
|
|
192
|
+
ErrorCode["PackageAlreadyPublished"] = "PackageAlreadyPublished";
|
|
193
|
+
ErrorCode["PackagePricingTypeNotSet"] = "PackagePricingTypeNotSet";
|
|
194
|
+
ErrorCode["PlanAlreadyExtended"] = "PlanAlreadyExtended";
|
|
195
|
+
ErrorCode["PlanIsUsedAsDefaultStartPlan"] = "PlanIsUsedAsDefaultStartPlan";
|
|
196
|
+
ErrorCode["PlanIsUsedAsDowngradePlan"] = "PlanIsUsedAsDowngradePlan";
|
|
197
|
+
ErrorCode["PlanNotFound"] = "PlanNotFound";
|
|
198
|
+
ErrorCode["PlanWithChildCantBeDeleted"] = "PlanWithChildCantBeDeleted";
|
|
199
|
+
ErrorCode["PlansCircularDependencyError"] = "PlansCircularDependencyError";
|
|
200
|
+
ErrorCode["PriceNotFound"] = "PriceNotFound";
|
|
201
|
+
ErrorCode["RateLimitExceeded"] = "RateLimitExceeded";
|
|
202
|
+
ErrorCode["ResyncAlreadyInProgress"] = "ResyncAlreadyInProgress";
|
|
203
|
+
ErrorCode["SelectedBillingModelDoesntMatchImportedItemError"] = "SelectedBillingModelDoesntMatchImportedItemError";
|
|
204
|
+
ErrorCode["StripeCustomerIsDeleted"] = "StripeCustomerIsDeleted";
|
|
205
|
+
ErrorCode["SubscriptionAlreadyCanceledOrExpired"] = "SubscriptionAlreadyCanceledOrExpired";
|
|
206
|
+
ErrorCode["SubscriptionMustHaveSinglePlanError"] = "SubscriptionMustHaveSinglePlanError";
|
|
207
|
+
ErrorCode["SubscriptionNotFound"] = "SubscriptionNotFound";
|
|
208
|
+
ErrorCode["TrialMinDateError"] = "TrialMinDateError";
|
|
209
|
+
ErrorCode["TrialMustBeCancelledImmediately"] = "TrialMustBeCancelledImmediately";
|
|
210
|
+
ErrorCode["UnPublishedPackage"] = "UnPublishedPackage";
|
|
211
|
+
ErrorCode["Unauthenticated"] = "Unauthenticated";
|
|
212
|
+
ErrorCode["UncompatibleSubscriptionAddon"] = "UncompatibleSubscriptionAddon";
|
|
213
|
+
ErrorCode["UnexpectedError"] = "UnexpectedError";
|
|
214
|
+
ErrorCode["UnsupportedFeatureType"] = "UnsupportedFeatureType";
|
|
215
|
+
ErrorCode["UnsupportedVendorIdentifier"] = "UnsupportedVendorIdentifier";
|
|
216
|
+
})(ErrorCode = exports.ErrorCode || (exports.ErrorCode = {}));
|
|
217
|
+
/** EventLogType */
|
|
218
|
+
var EventLogType;
|
|
219
|
+
(function (EventLogType) {
|
|
220
|
+
EventLogType["AddonCreated"] = "ADDON_CREATED";
|
|
221
|
+
EventLogType["AddonDeleted"] = "ADDON_DELETED";
|
|
222
|
+
EventLogType["AddonUpdated"] = "ADDON_UPDATED";
|
|
223
|
+
EventLogType["CouponArchived"] = "COUPON_ARCHIVED";
|
|
224
|
+
EventLogType["CouponCreated"] = "COUPON_CREATED";
|
|
225
|
+
EventLogType["CouponUpdated"] = "COUPON_UPDATED";
|
|
226
|
+
EventLogType["CreateSubscriptionFailed"] = "CREATE_SUBSCRIPTION_FAILED";
|
|
227
|
+
EventLogType["CustomerCreated"] = "CUSTOMER_CREATED";
|
|
228
|
+
EventLogType["CustomerDeleted"] = "CUSTOMER_DELETED";
|
|
229
|
+
EventLogType["CustomerPaymentFailed"] = "CUSTOMER_PAYMENT_FAILED";
|
|
230
|
+
EventLogType["CustomerUpdated"] = "CUSTOMER_UPDATED";
|
|
231
|
+
EventLogType["EntitlementsUpdated"] = "ENTITLEMENTS_UPDATED";
|
|
232
|
+
EventLogType["EntitlementDenied"] = "ENTITLEMENT_DENIED";
|
|
233
|
+
EventLogType["EntitlementGranted"] = "ENTITLEMENT_GRANTED";
|
|
234
|
+
EventLogType["EntitlementRequested"] = "ENTITLEMENT_REQUESTED";
|
|
235
|
+
EventLogType["FeatureCreated"] = "FEATURE_CREATED";
|
|
236
|
+
EventLogType["FeatureDeleted"] = "FEATURE_DELETED";
|
|
237
|
+
EventLogType["FeatureUpdated"] = "FEATURE_UPDATED";
|
|
238
|
+
EventLogType["ImportIntegrationCatalogTriggered"] = "IMPORT_INTEGRATION_CATALOG_TRIGGERED";
|
|
239
|
+
EventLogType["ImportIntegrationCustomersTriggered"] = "IMPORT_INTEGRATION_CUSTOMERS_TRIGGERED";
|
|
240
|
+
EventLogType["MeasurementReported"] = "MEASUREMENT_REPORTED";
|
|
241
|
+
EventLogType["PackagePublished"] = "PACKAGE_PUBLISHED";
|
|
242
|
+
EventLogType["PlanCreated"] = "PLAN_CREATED";
|
|
243
|
+
EventLogType["PlanDeleted"] = "PLAN_DELETED";
|
|
244
|
+
EventLogType["PlanUpdated"] = "PLAN_UPDATED";
|
|
245
|
+
EventLogType["PromotionalEntitlementExpired"] = "PROMOTIONAL_ENTITLEMENT_EXPIRED";
|
|
246
|
+
EventLogType["PromotionalEntitlementGranted"] = "PROMOTIONAL_ENTITLEMENT_GRANTED";
|
|
247
|
+
EventLogType["PromotionalEntitlementRevoked"] = "PROMOTIONAL_ENTITLEMENT_REVOKED";
|
|
248
|
+
EventLogType["PromotionalEntitlementUpdated"] = "PROMOTIONAL_ENTITLEMENT_UPDATED";
|
|
249
|
+
EventLogType["ResyncIntegrationTriggered"] = "RESYNC_INTEGRATION_TRIGGERED";
|
|
250
|
+
EventLogType["SubscriptionCanceled"] = "SUBSCRIPTION_CANCELED";
|
|
251
|
+
EventLogType["SubscriptionCreated"] = "SUBSCRIPTION_CREATED";
|
|
252
|
+
EventLogType["SubscriptionExpired"] = "SUBSCRIPTION_EXPIRED";
|
|
253
|
+
EventLogType["SubscriptionTrialConverted"] = "SUBSCRIPTION_TRIAL_CONVERTED";
|
|
254
|
+
EventLogType["SubscriptionTrialEndsSoon"] = "SUBSCRIPTION_TRIAL_ENDS_SOON";
|
|
255
|
+
EventLogType["SubscriptionTrialExpired"] = "SUBSCRIPTION_TRIAL_EXPIRED";
|
|
256
|
+
EventLogType["SubscriptionTrialStarted"] = "SUBSCRIPTION_TRIAL_STARTED";
|
|
257
|
+
EventLogType["SubscriptionUpdated"] = "SUBSCRIPTION_UPDATED";
|
|
258
|
+
EventLogType["SubscriptionUsageUpdated"] = "SUBSCRIPTION_USAGE_UPDATED";
|
|
259
|
+
EventLogType["SyncFailed"] = "SYNC_FAILED";
|
|
260
|
+
})(EventLogType = exports.EventLogType || (exports.EventLogType = {}));
|
|
261
|
+
/** The group of the experiment */
|
|
262
|
+
var ExperimentGroup;
|
|
263
|
+
(function (ExperimentGroup) {
|
|
264
|
+
ExperimentGroup["Control"] = "CONTROL";
|
|
265
|
+
ExperimentGroup["Variant"] = "VARIANT";
|
|
266
|
+
})(ExperimentGroup = exports.ExperimentGroup || (exports.ExperimentGroup = {}));
|
|
267
|
+
var ExperimentSortFields;
|
|
268
|
+
(function (ExperimentSortFields) {
|
|
269
|
+
ExperimentSortFields["CreatedAt"] = "createdAt";
|
|
270
|
+
ExperimentSortFields["EnvironmentId"] = "environmentId";
|
|
271
|
+
ExperimentSortFields["Id"] = "id";
|
|
272
|
+
ExperimentSortFields["Name"] = "name";
|
|
273
|
+
ExperimentSortFields["ProductId"] = "productId";
|
|
274
|
+
ExperimentSortFields["RefId"] = "refId";
|
|
275
|
+
ExperimentSortFields["Status"] = "status";
|
|
276
|
+
})(ExperimentSortFields = exports.ExperimentSortFields || (exports.ExperimentSortFields = {}));
|
|
277
|
+
/** The status of the EXPERIMENT */
|
|
278
|
+
var ExperimentStatus;
|
|
279
|
+
(function (ExperimentStatus) {
|
|
280
|
+
ExperimentStatus["Completed"] = "COMPLETED";
|
|
281
|
+
ExperimentStatus["Draft"] = "DRAFT";
|
|
282
|
+
ExperimentStatus["InProgress"] = "IN_PROGRESS";
|
|
283
|
+
})(ExperimentStatus = exports.ExperimentStatus || (exports.ExperimentStatus = {}));
|
|
284
|
+
var FeatureSortFields;
|
|
285
|
+
(function (FeatureSortFields) {
|
|
286
|
+
FeatureSortFields["CreatedAt"] = "createdAt";
|
|
287
|
+
FeatureSortFields["Description"] = "description";
|
|
288
|
+
FeatureSortFields["DisplayName"] = "displayName";
|
|
289
|
+
FeatureSortFields["EnvironmentId"] = "environmentId";
|
|
290
|
+
FeatureSortFields["FeatureStatus"] = "featureStatus";
|
|
291
|
+
FeatureSortFields["FeatureType"] = "featureType";
|
|
292
|
+
FeatureSortFields["Id"] = "id";
|
|
293
|
+
FeatureSortFields["MeterType"] = "meterType";
|
|
294
|
+
FeatureSortFields["RefId"] = "refId";
|
|
295
|
+
FeatureSortFields["UpdatedAt"] = "updatedAt";
|
|
296
|
+
})(FeatureSortFields = exports.FeatureSortFields || (exports.FeatureSortFields = {}));
|
|
297
|
+
/** Feature status. */
|
|
298
|
+
var FeatureStatus;
|
|
299
|
+
(function (FeatureStatus) {
|
|
300
|
+
FeatureStatus["Active"] = "ACTIVE";
|
|
301
|
+
FeatureStatus["New"] = "NEW";
|
|
302
|
+
FeatureStatus["Suspended"] = "SUSPENDED";
|
|
303
|
+
})(FeatureStatus = exports.FeatureStatus || (exports.FeatureStatus = {}));
|
|
304
|
+
/** The type of the feature */
|
|
305
|
+
var FeatureType;
|
|
306
|
+
(function (FeatureType) {
|
|
307
|
+
FeatureType["Boolean"] = "BOOLEAN";
|
|
308
|
+
FeatureType["Number"] = "NUMBER";
|
|
309
|
+
})(FeatureType = exports.FeatureType || (exports.FeatureType = {}));
|
|
310
|
+
var HookSortFields;
|
|
311
|
+
(function (HookSortFields) {
|
|
312
|
+
HookSortFields["CreatedAt"] = "createdAt";
|
|
313
|
+
HookSortFields["Endpoint"] = "endpoint";
|
|
314
|
+
HookSortFields["EnvironmentId"] = "environmentId";
|
|
315
|
+
HookSortFields["Id"] = "id";
|
|
316
|
+
HookSortFields["Status"] = "status";
|
|
317
|
+
})(HookSortFields = exports.HookSortFields || (exports.HookSortFields = {}));
|
|
318
|
+
/** HookStatus. */
|
|
319
|
+
var HookStatus;
|
|
320
|
+
(function (HookStatus) {
|
|
321
|
+
HookStatus["Active"] = "ACTIVE";
|
|
322
|
+
HookStatus["Inactive"] = "INACTIVE";
|
|
323
|
+
})(HookStatus = exports.HookStatus || (exports.HookStatus = {}));
|
|
324
|
+
var ImportIntegrationTaskSortFields;
|
|
325
|
+
(function (ImportIntegrationTaskSortFields) {
|
|
326
|
+
ImportIntegrationTaskSortFields["CreatedAt"] = "createdAt";
|
|
327
|
+
ImportIntegrationTaskSortFields["EnvironmentId"] = "environmentId";
|
|
328
|
+
ImportIntegrationTaskSortFields["Id"] = "id";
|
|
329
|
+
ImportIntegrationTaskSortFields["Status"] = "status";
|
|
330
|
+
ImportIntegrationTaskSortFields["TaskType"] = "taskType";
|
|
331
|
+
})(ImportIntegrationTaskSortFields = exports.ImportIntegrationTaskSortFields || (exports.ImportIntegrationTaskSortFields = {}));
|
|
332
|
+
var IntegrationSortFields;
|
|
333
|
+
(function (IntegrationSortFields) {
|
|
334
|
+
IntegrationSortFields["CreatedAt"] = "createdAt";
|
|
335
|
+
IntegrationSortFields["EnvironmentId"] = "environmentId";
|
|
336
|
+
IntegrationSortFields["Id"] = "id";
|
|
337
|
+
IntegrationSortFields["VendorIdentifier"] = "vendorIdentifier";
|
|
338
|
+
})(IntegrationSortFields = exports.IntegrationSortFields || (exports.IntegrationSortFields = {}));
|
|
339
|
+
var MemberSortFields;
|
|
340
|
+
(function (MemberSortFields) {
|
|
341
|
+
MemberSortFields["CreatedAt"] = "createdAt";
|
|
342
|
+
MemberSortFields["Id"] = "id";
|
|
343
|
+
})(MemberSortFields = exports.MemberSortFields || (exports.MemberSortFields = {}));
|
|
344
|
+
/** Member Status. */
|
|
345
|
+
var MemberStatus;
|
|
346
|
+
(function (MemberStatus) {
|
|
347
|
+
MemberStatus["Invited"] = "INVITED";
|
|
348
|
+
MemberStatus["Registered"] = "REGISTERED";
|
|
349
|
+
})(MemberStatus = exports.MemberStatus || (exports.MemberStatus = {}));
|
|
350
|
+
/** The meter type of the feature */
|
|
351
|
+
var MeterType;
|
|
352
|
+
(function (MeterType) {
|
|
353
|
+
MeterType["Fluctuating"] = "Fluctuating";
|
|
354
|
+
MeterType["Incremental"] = "Incremental";
|
|
355
|
+
MeterType["None"] = "None";
|
|
356
|
+
})(MeterType = exports.MeterType || (exports.MeterType = {}));
|
|
357
|
+
/** Montly reset period according to configuration */
|
|
358
|
+
var MonthlyAccordingTo;
|
|
359
|
+
(function (MonthlyAccordingTo) {
|
|
360
|
+
MonthlyAccordingTo["StartOfTheMonth"] = "StartOfTheMonth";
|
|
361
|
+
MonthlyAccordingTo["SubscriptionStart"] = "SubscriptionStart";
|
|
362
|
+
})(MonthlyAccordingTo = exports.MonthlyAccordingTo || (exports.MonthlyAccordingTo = {}));
|
|
363
|
+
var PackageDtoSortFields;
|
|
364
|
+
(function (PackageDtoSortFields) {
|
|
365
|
+
PackageDtoSortFields["BillingId"] = "billingId";
|
|
366
|
+
PackageDtoSortFields["CreatedAt"] = "createdAt";
|
|
367
|
+
PackageDtoSortFields["Description"] = "description";
|
|
368
|
+
PackageDtoSortFields["DisplayName"] = "displayName";
|
|
369
|
+
PackageDtoSortFields["EnvironmentId"] = "environmentId";
|
|
370
|
+
PackageDtoSortFields["Id"] = "id";
|
|
371
|
+
PackageDtoSortFields["IsLatest"] = "isLatest";
|
|
372
|
+
PackageDtoSortFields["PricingType"] = "pricingType";
|
|
373
|
+
PackageDtoSortFields["ProductId"] = "productId";
|
|
374
|
+
PackageDtoSortFields["RefId"] = "refId";
|
|
375
|
+
PackageDtoSortFields["Status"] = "status";
|
|
376
|
+
PackageDtoSortFields["UpdatedAt"] = "updatedAt";
|
|
377
|
+
PackageDtoSortFields["VersionNumber"] = "versionNumber";
|
|
378
|
+
})(PackageDtoSortFields = exports.PackageDtoSortFields || (exports.PackageDtoSortFields = {}));
|
|
379
|
+
var PackageEntitlementSortFields;
|
|
380
|
+
(function (PackageEntitlementSortFields) {
|
|
381
|
+
PackageEntitlementSortFields["CreatedAt"] = "createdAt";
|
|
382
|
+
PackageEntitlementSortFields["EnvironmentId"] = "environmentId";
|
|
383
|
+
PackageEntitlementSortFields["Id"] = "id";
|
|
384
|
+
PackageEntitlementSortFields["PackageId"] = "packageId";
|
|
385
|
+
PackageEntitlementSortFields["UpdatedAt"] = "updatedAt";
|
|
386
|
+
})(PackageEntitlementSortFields = exports.PackageEntitlementSortFields || (exports.PackageEntitlementSortFields = {}));
|
|
387
|
+
/** Package status. */
|
|
388
|
+
var PackageStatus;
|
|
389
|
+
(function (PackageStatus) {
|
|
390
|
+
PackageStatus["Archived"] = "ARCHIVED";
|
|
391
|
+
PackageStatus["Draft"] = "DRAFT";
|
|
392
|
+
PackageStatus["Published"] = "PUBLISHED";
|
|
393
|
+
})(PackageStatus = exports.PackageStatus || (exports.PackageStatus = {}));
|
|
394
|
+
/** Type of a payment method */
|
|
395
|
+
var PaymentMethodType;
|
|
396
|
+
(function (PaymentMethodType) {
|
|
397
|
+
PaymentMethodType["Bank"] = "BANK";
|
|
398
|
+
PaymentMethodType["Card"] = "CARD";
|
|
399
|
+
})(PaymentMethodType = exports.PaymentMethodType || (exports.PaymentMethodType = {}));
|
|
400
|
+
var PlanSortFields;
|
|
401
|
+
(function (PlanSortFields) {
|
|
402
|
+
PlanSortFields["BillingId"] = "billingId";
|
|
403
|
+
PlanSortFields["CreatedAt"] = "createdAt";
|
|
404
|
+
PlanSortFields["Description"] = "description";
|
|
405
|
+
PlanSortFields["DisplayName"] = "displayName";
|
|
406
|
+
PlanSortFields["EnvironmentId"] = "environmentId";
|
|
407
|
+
PlanSortFields["Id"] = "id";
|
|
408
|
+
PlanSortFields["IsLatest"] = "isLatest";
|
|
409
|
+
PlanSortFields["PricingType"] = "pricingType";
|
|
410
|
+
PlanSortFields["ProductId"] = "productId";
|
|
411
|
+
PlanSortFields["RefId"] = "refId";
|
|
412
|
+
PlanSortFields["Status"] = "status";
|
|
413
|
+
PlanSortFields["UpdatedAt"] = "updatedAt";
|
|
414
|
+
PlanSortFields["VersionNumber"] = "versionNumber";
|
|
415
|
+
})(PlanSortFields = exports.PlanSortFields || (exports.PlanSortFields = {}));
|
|
416
|
+
var PriceSortFields;
|
|
417
|
+
(function (PriceSortFields) {
|
|
418
|
+
PriceSortFields["BillingModel"] = "billingModel";
|
|
419
|
+
PriceSortFields["BillingPeriod"] = "billingPeriod";
|
|
420
|
+
PriceSortFields["CreatedAt"] = "createdAt";
|
|
421
|
+
PriceSortFields["Id"] = "id";
|
|
422
|
+
})(PriceSortFields = exports.PriceSortFields || (exports.PriceSortFields = {}));
|
|
423
|
+
/** Package pricing type. */
|
|
424
|
+
var PricingType;
|
|
425
|
+
(function (PricingType) {
|
|
426
|
+
PricingType["Custom"] = "CUSTOM";
|
|
427
|
+
PricingType["Free"] = "FREE";
|
|
428
|
+
PricingType["Paid"] = "PAID";
|
|
429
|
+
})(PricingType = exports.PricingType || (exports.PricingType = {}));
|
|
430
|
+
var ProductSortFields;
|
|
431
|
+
(function (ProductSortFields) {
|
|
432
|
+
ProductSortFields["CreatedAt"] = "createdAt";
|
|
433
|
+
ProductSortFields["Description"] = "description";
|
|
434
|
+
ProductSortFields["DisplayName"] = "displayName";
|
|
435
|
+
ProductSortFields["EnvironmentId"] = "environmentId";
|
|
436
|
+
ProductSortFields["Id"] = "id";
|
|
437
|
+
ProductSortFields["IsDefaultProduct"] = "isDefaultProduct";
|
|
438
|
+
ProductSortFields["RefId"] = "refId";
|
|
439
|
+
ProductSortFields["UpdatedAt"] = "updatedAt";
|
|
440
|
+
})(ProductSortFields = exports.ProductSortFields || (exports.ProductSortFields = {}));
|
|
441
|
+
/** Promotional entitlement duration */
|
|
442
|
+
var PromotionalEntitlementPeriod;
|
|
443
|
+
(function (PromotionalEntitlementPeriod) {
|
|
444
|
+
PromotionalEntitlementPeriod["Custom"] = "CUSTOM";
|
|
445
|
+
PromotionalEntitlementPeriod["Lifetime"] = "LIFETIME";
|
|
446
|
+
PromotionalEntitlementPeriod["OneMonth"] = "ONE_MONTH";
|
|
447
|
+
PromotionalEntitlementPeriod["OneWeek"] = "ONE_WEEK";
|
|
448
|
+
PromotionalEntitlementPeriod["OneYear"] = "ONE_YEAR";
|
|
449
|
+
PromotionalEntitlementPeriod["SixMonth"] = "SIX_MONTH";
|
|
450
|
+
})(PromotionalEntitlementPeriod = exports.PromotionalEntitlementPeriod || (exports.PromotionalEntitlementPeriod = {}));
|
|
451
|
+
var PromotionalEntitlementSortFields;
|
|
452
|
+
(function (PromotionalEntitlementSortFields) {
|
|
453
|
+
PromotionalEntitlementSortFields["CreatedAt"] = "createdAt";
|
|
454
|
+
PromotionalEntitlementSortFields["EnvironmentId"] = "environmentId";
|
|
455
|
+
PromotionalEntitlementSortFields["Id"] = "id";
|
|
456
|
+
PromotionalEntitlementSortFields["Status"] = "status";
|
|
457
|
+
PromotionalEntitlementSortFields["UpdatedAt"] = "updatedAt";
|
|
458
|
+
})(PromotionalEntitlementSortFields = exports.PromotionalEntitlementSortFields || (exports.PromotionalEntitlementSortFields = {}));
|
|
459
|
+
/** Promotional entitlement status */
|
|
460
|
+
var PromotionalEntitlementStatus;
|
|
461
|
+
(function (PromotionalEntitlementStatus) {
|
|
462
|
+
PromotionalEntitlementStatus["Active"] = "Active";
|
|
463
|
+
PromotionalEntitlementStatus["Expired"] = "Expired";
|
|
464
|
+
PromotionalEntitlementStatus["Paused"] = "Paused";
|
|
465
|
+
})(PromotionalEntitlementStatus = exports.PromotionalEntitlementStatus || (exports.PromotionalEntitlementStatus = {}));
|
|
466
|
+
/** PublishMigrationType */
|
|
467
|
+
var PublishMigrationType;
|
|
468
|
+
(function (PublishMigrationType) {
|
|
469
|
+
PublishMigrationType["AllCustomers"] = "ALL_CUSTOMERS";
|
|
470
|
+
PublishMigrationType["NewCustomers"] = "NEW_CUSTOMERS";
|
|
471
|
+
})(PublishMigrationType = exports.PublishMigrationType || (exports.PublishMigrationType = {}));
|
|
472
|
+
/** Sort Directions */
|
|
473
|
+
var SortDirection;
|
|
474
|
+
(function (SortDirection) {
|
|
475
|
+
SortDirection["Asc"] = "ASC";
|
|
476
|
+
SortDirection["Desc"] = "DESC";
|
|
477
|
+
})(SortDirection = exports.SortDirection || (exports.SortDirection = {}));
|
|
478
|
+
/** Sort Nulls Options */
|
|
479
|
+
var SortNulls;
|
|
480
|
+
(function (SortNulls) {
|
|
481
|
+
SortNulls["NullsFirst"] = "NULLS_FIRST";
|
|
482
|
+
SortNulls["NullsLast"] = "NULLS_LAST";
|
|
483
|
+
})(SortNulls = exports.SortNulls || (exports.SortNulls = {}));
|
|
484
|
+
var SourceType;
|
|
485
|
+
(function (SourceType) {
|
|
486
|
+
SourceType["JsClientSdk"] = "JS_CLIENT_SDK";
|
|
487
|
+
SourceType["NodeServerSdk"] = "NODE_SERVER_SDK";
|
|
488
|
+
})(SourceType = exports.SourceType || (exports.SourceType = {}));
|
|
489
|
+
var SubscriptionAddonSortFields;
|
|
490
|
+
(function (SubscriptionAddonSortFields) {
|
|
491
|
+
SubscriptionAddonSortFields["CreatedAt"] = "createdAt";
|
|
492
|
+
SubscriptionAddonSortFields["Id"] = "id";
|
|
493
|
+
SubscriptionAddonSortFields["Quantity"] = "quantity";
|
|
494
|
+
SubscriptionAddonSortFields["UpdatedAt"] = "updatedAt";
|
|
495
|
+
})(SubscriptionAddonSortFields = exports.SubscriptionAddonSortFields || (exports.SubscriptionAddonSortFields = {}));
|
|
496
|
+
/** Subscription cancellation status */
|
|
497
|
+
var SubscriptionCancelReason;
|
|
498
|
+
(function (SubscriptionCancelReason) {
|
|
499
|
+
SubscriptionCancelReason["CancelledByBilling"] = "CancelledByBilling";
|
|
500
|
+
SubscriptionCancelReason["DetachBilling"] = "DetachBilling";
|
|
501
|
+
SubscriptionCancelReason["Expired"] = "Expired";
|
|
502
|
+
SubscriptionCancelReason["Immediate"] = "Immediate";
|
|
503
|
+
SubscriptionCancelReason["PendingPaymentExpired"] = "PendingPaymentExpired";
|
|
504
|
+
SubscriptionCancelReason["ScheduledCancellation"] = "ScheduledCancellation";
|
|
505
|
+
SubscriptionCancelReason["TrialConverted"] = "TrialConverted";
|
|
506
|
+
SubscriptionCancelReason["TrialEnded"] = "TrialEnded";
|
|
507
|
+
SubscriptionCancelReason["UpgradeOrDowngrade"] = "UpgradeOrDowngrade";
|
|
508
|
+
})(SubscriptionCancelReason = exports.SubscriptionCancelReason || (exports.SubscriptionCancelReason = {}));
|
|
509
|
+
var SubscriptionCancellationTime;
|
|
510
|
+
(function (SubscriptionCancellationTime) {
|
|
511
|
+
SubscriptionCancellationTime["EndOfBillingPeriod"] = "END_OF_BILLING_PERIOD";
|
|
512
|
+
SubscriptionCancellationTime["Immediate"] = "IMMEDIATE";
|
|
513
|
+
SubscriptionCancellationTime["SpecificDate"] = "SPECIFIC_DATE";
|
|
514
|
+
})(SubscriptionCancellationTime = exports.SubscriptionCancellationTime || (exports.SubscriptionCancellationTime = {}));
|
|
515
|
+
var SubscriptionEndSetup;
|
|
516
|
+
(function (SubscriptionEndSetup) {
|
|
517
|
+
SubscriptionEndSetup["CancelSubscription"] = "CANCEL_SUBSCRIPTION";
|
|
518
|
+
SubscriptionEndSetup["DowngradeToFree"] = "DOWNGRADE_TO_FREE";
|
|
519
|
+
})(SubscriptionEndSetup = exports.SubscriptionEndSetup || (exports.SubscriptionEndSetup = {}));
|
|
520
|
+
var SubscriptionMigrationTaskSortFields;
|
|
521
|
+
(function (SubscriptionMigrationTaskSortFields) {
|
|
522
|
+
SubscriptionMigrationTaskSortFields["CreatedAt"] = "createdAt";
|
|
523
|
+
SubscriptionMigrationTaskSortFields["EnvironmentId"] = "environmentId";
|
|
524
|
+
SubscriptionMigrationTaskSortFields["Id"] = "id";
|
|
525
|
+
SubscriptionMigrationTaskSortFields["Status"] = "status";
|
|
526
|
+
SubscriptionMigrationTaskSortFields["TaskType"] = "taskType";
|
|
527
|
+
})(SubscriptionMigrationTaskSortFields = exports.SubscriptionMigrationTaskSortFields || (exports.SubscriptionMigrationTaskSortFields = {}));
|
|
528
|
+
var SubscriptionPriceSortFields;
|
|
529
|
+
(function (SubscriptionPriceSortFields) {
|
|
530
|
+
SubscriptionPriceSortFields["CreatedAt"] = "createdAt";
|
|
531
|
+
SubscriptionPriceSortFields["Id"] = "id";
|
|
532
|
+
SubscriptionPriceSortFields["UpdatedAt"] = "updatedAt";
|
|
533
|
+
SubscriptionPriceSortFields["UsageLimit"] = "usageLimit";
|
|
534
|
+
})(SubscriptionPriceSortFields = exports.SubscriptionPriceSortFields || (exports.SubscriptionPriceSortFields = {}));
|
|
535
|
+
var SubscriptionStartSetup;
|
|
536
|
+
(function (SubscriptionStartSetup) {
|
|
537
|
+
SubscriptionStartSetup["FreePlan"] = "FREE_PLAN";
|
|
538
|
+
SubscriptionStartSetup["PlanSelection"] = "PLAN_SELECTION";
|
|
539
|
+
SubscriptionStartSetup["TrialPeriod"] = "TRIAL_PERIOD";
|
|
540
|
+
})(SubscriptionStartSetup = exports.SubscriptionStartSetup || (exports.SubscriptionStartSetup = {}));
|
|
541
|
+
/** Subscription status */
|
|
542
|
+
var SubscriptionStatus;
|
|
543
|
+
(function (SubscriptionStatus) {
|
|
544
|
+
SubscriptionStatus["Active"] = "ACTIVE";
|
|
545
|
+
SubscriptionStatus["Canceled"] = "CANCELED";
|
|
546
|
+
SubscriptionStatus["Expired"] = "EXPIRED";
|
|
547
|
+
SubscriptionStatus["InTrial"] = "IN_TRIAL";
|
|
548
|
+
SubscriptionStatus["NotStarted"] = "NOT_STARTED";
|
|
549
|
+
SubscriptionStatus["PaymentPending"] = "PAYMENT_PENDING";
|
|
550
|
+
})(SubscriptionStatus = exports.SubscriptionStatus || (exports.SubscriptionStatus = {}));
|
|
551
|
+
/** Subscription strategy decision */
|
|
552
|
+
var SubscriptionStrategyDecision;
|
|
553
|
+
(function (SubscriptionStrategyDecision) {
|
|
554
|
+
SubscriptionStrategyDecision["PredefinedFreePlan"] = "PREDEFINED_FREE_PLAN";
|
|
555
|
+
SubscriptionStrategyDecision["PredefinedTrialPlan"] = "PREDEFINED_TRIAL_PLAN";
|
|
556
|
+
SubscriptionStrategyDecision["RequestedPlan"] = "REQUESTED_PLAN";
|
|
557
|
+
SubscriptionStrategyDecision["SkippedSubscriptionCreation"] = "SKIPPED_SUBSCRIPTION_CREATION";
|
|
558
|
+
})(SubscriptionStrategyDecision = exports.SubscriptionStrategyDecision || (exports.SubscriptionStrategyDecision = {}));
|
|
559
|
+
/** Status of the integration sync */
|
|
560
|
+
var SyncStatus;
|
|
561
|
+
(function (SyncStatus) {
|
|
562
|
+
SyncStatus["Error"] = "ERROR";
|
|
563
|
+
SyncStatus["NoSyncRequired"] = "NO_SYNC_REQUIRED";
|
|
564
|
+
SyncStatus["Pending"] = "PENDING";
|
|
565
|
+
SyncStatus["Success"] = "SUCCESS";
|
|
566
|
+
})(SyncStatus = exports.SyncStatus || (exports.SyncStatus = {}));
|
|
567
|
+
var TaskStatus;
|
|
568
|
+
(function (TaskStatus) {
|
|
569
|
+
TaskStatus["Completed"] = "COMPLETED";
|
|
570
|
+
TaskStatus["Failed"] = "FAILED";
|
|
571
|
+
TaskStatus["InProgress"] = "IN_PROGRESS";
|
|
572
|
+
TaskStatus["PartiallyFailed"] = "PARTIALLY_FAILED";
|
|
573
|
+
TaskStatus["Pending"] = "PENDING";
|
|
574
|
+
})(TaskStatus = exports.TaskStatus || (exports.TaskStatus = {}));
|
|
575
|
+
var TaskType;
|
|
576
|
+
(function (TaskType) {
|
|
577
|
+
TaskType["ImportIntegrationCatalog"] = "IMPORT_INTEGRATION_CATALOG";
|
|
578
|
+
TaskType["ImportIntegrationCustomers"] = "IMPORT_INTEGRATION_CUSTOMERS";
|
|
579
|
+
TaskType["ResyncIntegration"] = "RESYNC_INTEGRATION";
|
|
580
|
+
TaskType["SubscriptionMigration"] = "SUBSCRIPTION_MIGRATION";
|
|
581
|
+
})(TaskType = exports.TaskType || (exports.TaskType = {}));
|
|
582
|
+
/** day or month. */
|
|
583
|
+
var TrialPeriodUnits;
|
|
584
|
+
(function (TrialPeriodUnits) {
|
|
585
|
+
TrialPeriodUnits["Day"] = "DAY";
|
|
586
|
+
TrialPeriodUnits["Month"] = "MONTH";
|
|
587
|
+
})(TrialPeriodUnits = exports.TrialPeriodUnits || (exports.TrialPeriodUnits = {}));
|
|
588
|
+
var UsageMeasurementSortFields;
|
|
589
|
+
(function (UsageMeasurementSortFields) {
|
|
590
|
+
UsageMeasurementSortFields["CreatedAt"] = "createdAt";
|
|
591
|
+
UsageMeasurementSortFields["EnvironmentId"] = "environmentId";
|
|
592
|
+
UsageMeasurementSortFields["Id"] = "id";
|
|
593
|
+
})(UsageMeasurementSortFields = exports.UsageMeasurementSortFields || (exports.UsageMeasurementSortFields = {}));
|
|
594
|
+
var VendorIdentifier;
|
|
595
|
+
(function (VendorIdentifier) {
|
|
596
|
+
VendorIdentifier["Hubspot"] = "HUBSPOT";
|
|
597
|
+
VendorIdentifier["Stripe"] = "STRIPE";
|
|
598
|
+
VendorIdentifier["Zuora"] = "ZUORA";
|
|
599
|
+
})(VendorIdentifier = exports.VendorIdentifier || (exports.VendorIdentifier = {}));
|
|
600
|
+
/** Weekly reset period according to configuration */
|
|
601
|
+
var WeeklyAccordingTo;
|
|
602
|
+
(function (WeeklyAccordingTo) {
|
|
603
|
+
WeeklyAccordingTo["EveryFriday"] = "EveryFriday";
|
|
604
|
+
WeeklyAccordingTo["EveryMonday"] = "EveryMonday";
|
|
605
|
+
WeeklyAccordingTo["EverySaturday"] = "EverySaturday";
|
|
606
|
+
WeeklyAccordingTo["EverySunday"] = "EverySunday";
|
|
607
|
+
WeeklyAccordingTo["EveryThursday"] = "EveryThursday";
|
|
608
|
+
WeeklyAccordingTo["EveryTuesday"] = "EveryTuesday";
|
|
609
|
+
WeeklyAccordingTo["EveryWednesday"] = "EveryWednesday";
|
|
610
|
+
WeeklyAccordingTo["SubscriptionStart"] = "SubscriptionStart";
|
|
611
|
+
})(WeeklyAccordingTo = exports.WeeklyAccordingTo || (exports.WeeklyAccordingTo = {}));
|
|
612
|
+
exports.FeatureFragmentDoc = (0, graphql_tag_1.default) `
|
|
613
|
+
fragment FeatureFragment on Feature {
|
|
614
|
+
id: refId
|
|
615
|
+
featureType
|
|
616
|
+
meterType
|
|
617
|
+
featureUnits
|
|
618
|
+
featureUnitsPlural
|
|
619
|
+
displayName
|
|
620
|
+
description
|
|
621
|
+
}
|
|
622
|
+
`;
|
|
623
|
+
exports.PriceFragmentDoc = (0, graphql_tag_1.default) `
|
|
624
|
+
fragment PriceFragment on Price {
|
|
625
|
+
billingModel
|
|
626
|
+
billingPeriod
|
|
627
|
+
price {
|
|
628
|
+
amount
|
|
629
|
+
currency
|
|
630
|
+
}
|
|
631
|
+
feature {
|
|
632
|
+
...FeatureFragment
|
|
633
|
+
}
|
|
634
|
+
}
|
|
635
|
+
${exports.FeatureFragmentDoc}`;
|
|
636
|
+
exports.TotalPriceFragmentDoc = (0, graphql_tag_1.default) `
|
|
637
|
+
fragment TotalPriceFragment on CustomerSubscriptionTotalPrice {
|
|
638
|
+
subTotal {
|
|
639
|
+
amount
|
|
640
|
+
currency
|
|
641
|
+
}
|
|
642
|
+
total {
|
|
643
|
+
amount
|
|
644
|
+
currency
|
|
645
|
+
}
|
|
646
|
+
}
|
|
647
|
+
`;
|
|
648
|
+
exports.PackageEntitlementFragmentDoc = (0, graphql_tag_1.default) `
|
|
649
|
+
fragment PackageEntitlementFragment on PackageEntitlement {
|
|
650
|
+
usageLimit
|
|
651
|
+
hasUnlimitedUsage
|
|
652
|
+
featureId
|
|
653
|
+
resetPeriod
|
|
654
|
+
feature {
|
|
655
|
+
...FeatureFragment
|
|
656
|
+
}
|
|
657
|
+
}
|
|
658
|
+
${exports.FeatureFragmentDoc}`;
|
|
659
|
+
exports.AddonFragmentDoc = (0, graphql_tag_1.default) `
|
|
660
|
+
fragment AddonFragment on Addon {
|
|
661
|
+
id: refId
|
|
662
|
+
displayName
|
|
663
|
+
description
|
|
664
|
+
metadata: additionalMetaData
|
|
665
|
+
entitlements {
|
|
666
|
+
...PackageEntitlementFragment
|
|
667
|
+
}
|
|
668
|
+
pricingType
|
|
669
|
+
}
|
|
670
|
+
${exports.PackageEntitlementFragmentDoc}`;
|
|
671
|
+
exports.PlanFragmentDoc = (0, graphql_tag_1.default) `
|
|
672
|
+
fragment PlanFragment on Plan {
|
|
673
|
+
id: refId
|
|
674
|
+
displayName
|
|
675
|
+
description
|
|
676
|
+
metadata: additionalMetaData
|
|
677
|
+
product {
|
|
678
|
+
id: refId
|
|
679
|
+
displayName
|
|
680
|
+
description
|
|
681
|
+
}
|
|
682
|
+
basePlan {
|
|
683
|
+
id: refId
|
|
684
|
+
displayName
|
|
685
|
+
}
|
|
686
|
+
entitlements {
|
|
687
|
+
...PackageEntitlementFragment
|
|
688
|
+
}
|
|
689
|
+
inheritedEntitlements {
|
|
690
|
+
...PackageEntitlementFragment
|
|
691
|
+
}
|
|
692
|
+
compatibleAddons {
|
|
693
|
+
...AddonFragment
|
|
694
|
+
}
|
|
695
|
+
prices {
|
|
696
|
+
...PriceFragment
|
|
697
|
+
}
|
|
698
|
+
pricingType
|
|
699
|
+
defaultTrialConfig {
|
|
700
|
+
duration
|
|
701
|
+
units
|
|
702
|
+
}
|
|
703
|
+
}
|
|
704
|
+
${exports.PackageEntitlementFragmentDoc}
|
|
705
|
+
${exports.AddonFragmentDoc}
|
|
706
|
+
${exports.PriceFragmentDoc}`;
|
|
707
|
+
exports.SubscriptionFragmentDoc = (0, graphql_tag_1.default) `
|
|
708
|
+
fragment SubscriptionFragment on CustomerSubscription {
|
|
709
|
+
id: refId
|
|
710
|
+
status
|
|
711
|
+
startDate
|
|
712
|
+
endDate
|
|
713
|
+
trialEndDate
|
|
714
|
+
cancellationDate
|
|
715
|
+
effectiveEndDate
|
|
716
|
+
currentBillingPeriodEnd
|
|
717
|
+
metadata: additionalMetaData
|
|
718
|
+
billingId
|
|
719
|
+
billingLinkUrl
|
|
720
|
+
prices {
|
|
721
|
+
usageLimit
|
|
722
|
+
price {
|
|
723
|
+
...PriceFragment
|
|
724
|
+
}
|
|
725
|
+
}
|
|
726
|
+
totalPrice {
|
|
727
|
+
...TotalPriceFragment
|
|
728
|
+
}
|
|
729
|
+
pricingType
|
|
730
|
+
plan {
|
|
731
|
+
...PlanFragment
|
|
732
|
+
}
|
|
733
|
+
addons {
|
|
734
|
+
id
|
|
735
|
+
quantity
|
|
736
|
+
addon {
|
|
737
|
+
...AddonFragment
|
|
738
|
+
}
|
|
739
|
+
}
|
|
740
|
+
}
|
|
741
|
+
${exports.PriceFragmentDoc}
|
|
742
|
+
${exports.TotalPriceFragmentDoc}
|
|
743
|
+
${exports.PlanFragmentDoc}
|
|
744
|
+
${exports.AddonFragmentDoc}`;
|
|
745
|
+
exports.PromotionalEntitlementFragmentDoc = (0, graphql_tag_1.default) `
|
|
746
|
+
fragment PromotionalEntitlementFragment on PromotionalEntitlement {
|
|
747
|
+
status
|
|
748
|
+
usageLimit
|
|
749
|
+
featureId
|
|
750
|
+
hasUnlimitedUsage
|
|
751
|
+
resetPeriod
|
|
752
|
+
endDate
|
|
753
|
+
isVisible
|
|
754
|
+
feature {
|
|
755
|
+
...FeatureFragment
|
|
756
|
+
}
|
|
757
|
+
}
|
|
758
|
+
${exports.FeatureFragmentDoc}`;
|
|
759
|
+
exports.CouponFragmentDoc = (0, graphql_tag_1.default) `
|
|
760
|
+
fragment CouponFragment on Coupon {
|
|
761
|
+
id: refId
|
|
762
|
+
name
|
|
763
|
+
description
|
|
764
|
+
type
|
|
765
|
+
discountValue
|
|
766
|
+
metadata: additionalMetaData
|
|
767
|
+
createdAt
|
|
768
|
+
updatedAt
|
|
769
|
+
billingId
|
|
770
|
+
billingLinkUrl
|
|
771
|
+
status
|
|
772
|
+
}
|
|
773
|
+
`;
|
|
774
|
+
exports.CustomerFragmentDoc = (0, graphql_tag_1.default) `
|
|
775
|
+
fragment CustomerFragment on Customer {
|
|
776
|
+
id: refId
|
|
777
|
+
name
|
|
778
|
+
email
|
|
779
|
+
createdAt
|
|
780
|
+
updatedAt
|
|
781
|
+
subscriptions {
|
|
782
|
+
...SubscriptionFragment
|
|
783
|
+
}
|
|
784
|
+
promotionalEntitlements {
|
|
785
|
+
...PromotionalEntitlementFragment
|
|
786
|
+
}
|
|
787
|
+
hasPaymentMethod
|
|
788
|
+
coupon {
|
|
789
|
+
...CouponFragment
|
|
790
|
+
}
|
|
791
|
+
billingId
|
|
792
|
+
metadata: additionalMetaData
|
|
793
|
+
}
|
|
794
|
+
${exports.SubscriptionFragmentDoc}
|
|
795
|
+
${exports.PromotionalEntitlementFragmentDoc}
|
|
796
|
+
${exports.CouponFragmentDoc}`;
|
|
797
|
+
exports.SlimSubscriptionFragmentDoc = (0, graphql_tag_1.default) `
|
|
798
|
+
fragment SlimSubscriptionFragment on CustomerSubscription {
|
|
799
|
+
id: refId
|
|
800
|
+
status
|
|
801
|
+
metadata: additionalMetaData
|
|
802
|
+
billingId
|
|
803
|
+
billingLinkUrl
|
|
804
|
+
effectiveEndDate
|
|
805
|
+
currentBillingPeriodEnd
|
|
806
|
+
pricingType
|
|
807
|
+
prices {
|
|
808
|
+
usageLimit
|
|
809
|
+
price {
|
|
810
|
+
...PriceFragment
|
|
811
|
+
}
|
|
812
|
+
}
|
|
813
|
+
totalPrice {
|
|
814
|
+
...TotalPriceFragment
|
|
815
|
+
}
|
|
816
|
+
plan {
|
|
817
|
+
id: refId
|
|
818
|
+
}
|
|
819
|
+
addons {
|
|
820
|
+
quantity
|
|
821
|
+
addon {
|
|
822
|
+
id: refId
|
|
823
|
+
}
|
|
824
|
+
}
|
|
825
|
+
customer {
|
|
826
|
+
id: refId
|
|
827
|
+
}
|
|
828
|
+
}
|
|
829
|
+
${exports.PriceFragmentDoc}
|
|
830
|
+
${exports.TotalPriceFragmentDoc}`;
|
|
831
|
+
exports.PaywallPackageEntitlementFragmentDoc = (0, graphql_tag_1.default) `
|
|
832
|
+
fragment PaywallPackageEntitlementFragment on PackageEntitlement {
|
|
833
|
+
usageLimit
|
|
834
|
+
hasUnlimitedUsage
|
|
835
|
+
featureId
|
|
836
|
+
resetPeriod
|
|
837
|
+
feature {
|
|
838
|
+
...FeatureFragment
|
|
839
|
+
}
|
|
840
|
+
}
|
|
841
|
+
${exports.FeatureFragmentDoc}`;
|
|
842
|
+
exports.PaywallPriceFragmentDoc = (0, graphql_tag_1.default) `
|
|
843
|
+
fragment PaywallPriceFragment on Price {
|
|
844
|
+
billingModel
|
|
845
|
+
billingPeriod
|
|
846
|
+
price {
|
|
847
|
+
amount
|
|
848
|
+
currency
|
|
849
|
+
}
|
|
850
|
+
feature {
|
|
851
|
+
...FeatureFragment
|
|
852
|
+
}
|
|
853
|
+
}
|
|
854
|
+
${exports.FeatureFragmentDoc}`;
|
|
855
|
+
exports.PaywallPlanFragmentDoc = (0, graphql_tag_1.default) `
|
|
856
|
+
fragment PaywallPlanFragment on Plan {
|
|
857
|
+
id: refId
|
|
858
|
+
description
|
|
859
|
+
displayName
|
|
860
|
+
product {
|
|
861
|
+
id: refId
|
|
862
|
+
displayName
|
|
863
|
+
description
|
|
864
|
+
}
|
|
865
|
+
basePlan {
|
|
866
|
+
id: refId
|
|
867
|
+
displayName
|
|
868
|
+
}
|
|
869
|
+
entitlements {
|
|
870
|
+
...PaywallPackageEntitlementFragment
|
|
871
|
+
}
|
|
872
|
+
metadata: additionalMetaData
|
|
873
|
+
inheritedEntitlements {
|
|
874
|
+
...PaywallPackageEntitlementFragment
|
|
875
|
+
}
|
|
876
|
+
prices {
|
|
877
|
+
...PaywallPriceFragment
|
|
878
|
+
}
|
|
879
|
+
pricingType
|
|
880
|
+
defaultTrialConfig {
|
|
881
|
+
duration
|
|
882
|
+
units
|
|
883
|
+
}
|
|
884
|
+
}
|
|
885
|
+
${exports.PaywallPackageEntitlementFragmentDoc}
|
|
886
|
+
${exports.PaywallPriceFragmentDoc}`;
|
|
887
|
+
exports.PaywallAddonFragmentDoc = (0, graphql_tag_1.default) `
|
|
888
|
+
fragment PaywallAddonFragment on Addon {
|
|
889
|
+
id: refId
|
|
890
|
+
displayName
|
|
891
|
+
description
|
|
892
|
+
entitlements {
|
|
893
|
+
...PaywallPackageEntitlementFragment
|
|
894
|
+
}
|
|
895
|
+
prices {
|
|
896
|
+
...PaywallPriceFragment
|
|
897
|
+
}
|
|
898
|
+
metadata: additionalMetaData
|
|
899
|
+
pricingType
|
|
900
|
+
}
|
|
901
|
+
${exports.PaywallPackageEntitlementFragmentDoc}
|
|
902
|
+
${exports.PaywallPriceFragmentDoc}`;
|
|
903
|
+
exports.CreateCustomerDocument = (0, graphql_tag_1.default) `
|
|
904
|
+
mutation createCustomer($customerId: String!, $email: String, $name: String, $billingInfo: CustomerBillingInfo, $metadata: JSON, $couponId: String, $shouldSyncFree: Boolean = true) {
|
|
905
|
+
createCustomer: createOneCustomer(
|
|
906
|
+
input: {refId: $customerId, additionalMetaData: $metadata, billingInformation: $billingInfo, couponRefId: $couponId, email: $email, name: $name, shouldSyncFree: $shouldSyncFree}
|
|
907
|
+
) {
|
|
908
|
+
...CustomerFragment
|
|
909
|
+
}
|
|
910
|
+
}
|
|
911
|
+
${exports.CustomerFragmentDoc}`;
|
|
912
|
+
exports.ProvisionCustomerDocument = (0, graphql_tag_1.default) `
|
|
913
|
+
mutation provisionCustomer($customerId: String!, $email: String, $name: String, $billingInfo: CustomerBillingInfo, $metadata: JSON, $couponId: String, $shouldSyncFree: Boolean = true, $subscriptionParams: SubscriptionBaseInput) {
|
|
914
|
+
provisionCustomer(
|
|
915
|
+
input: {refId: $customerId, additionalMetaData: $metadata, billingInformation: $billingInfo, couponRefId: $couponId, email: $email, name: $name, shouldSyncFree: $shouldSyncFree, subscriptionParams: $subscriptionParams}
|
|
916
|
+
) {
|
|
917
|
+
customer {
|
|
918
|
+
...CustomerFragment
|
|
919
|
+
}
|
|
920
|
+
subscriptionStrategyDecision
|
|
921
|
+
subscription {
|
|
922
|
+
...SlimSubscriptionFragment
|
|
923
|
+
}
|
|
924
|
+
}
|
|
925
|
+
}
|
|
926
|
+
${exports.CustomerFragmentDoc}
|
|
927
|
+
${exports.SlimSubscriptionFragmentDoc}`;
|
|
928
|
+
exports.ImportCustomerDocument = (0, graphql_tag_1.default) `
|
|
929
|
+
mutation importCustomer($customerId: String!, $billingId: String!, $email: String, $name: String) {
|
|
930
|
+
importCustomer: importOneCustomer(
|
|
931
|
+
input: {refId: $customerId, billingId: $billingId, email: $email, name: $name}
|
|
932
|
+
) {
|
|
933
|
+
...CustomerFragment
|
|
934
|
+
}
|
|
935
|
+
}
|
|
936
|
+
${exports.CustomerFragmentDoc}`;
|
|
937
|
+
exports.UpdateCustomerDocument = (0, graphql_tag_1.default) `
|
|
938
|
+
mutation updateCustomer($metadata: JSON, $billingInfo: CustomerBillingInfo, $couponId: String, $email: String, $name: String, $customerId: String!) {
|
|
939
|
+
updateCustomer: updateOneCustomer(
|
|
940
|
+
input: {refId: $customerId, name: $name, email: $email, couponRefId: $couponId, billingInformation: $billingInfo, additionalMetaData: $metadata}
|
|
941
|
+
) {
|
|
942
|
+
...CustomerFragment
|
|
943
|
+
}
|
|
944
|
+
}
|
|
945
|
+
${exports.CustomerFragmentDoc}`;
|
|
946
|
+
exports.UpdateSubscriptionDocument = (0, graphql_tag_1.default) `
|
|
947
|
+
mutation updateSubscription($metadata: JSON, $subscriptionId: String!, $unitQuantity: Float) {
|
|
948
|
+
updateSubscription: updateOneSubscription(
|
|
949
|
+
input: {additionalMetaData: $metadata, refId: $subscriptionId, unitQuantity: $unitQuantity}
|
|
950
|
+
) {
|
|
951
|
+
...SlimSubscriptionFragment
|
|
952
|
+
}
|
|
953
|
+
}
|
|
954
|
+
${exports.SlimSubscriptionFragmentDoc}`;
|
|
955
|
+
exports.CreateSubscriptionDocument = (0, graphql_tag_1.default) `
|
|
956
|
+
mutation createSubscription($metadata: JSON, $addons: [SubscriptionAddonInput!], $awaitPaymentConfirmation: Boolean = false, $billingId: String, $billingInfo: SubscriptionBillingInfo, $billingPeriod: BillingPeriod, $customerId: String!, $isTrial: Boolean, $isOverridingTrialConfig: Boolean, $planId: String, $unitQuantity: Float, $subscriptionId: String, $startDate: DateTime) {
|
|
957
|
+
createSubscription(
|
|
958
|
+
subscription: {refId: $subscriptionId, additionalMetaData: $metadata, billingInformation: $billingInfo, billingId: $billingId, addons: $addons, customerId: $customerId, awaitPaymentConfirmation: $awaitPaymentConfirmation, billingPeriod: $billingPeriod, isTrial: $isTrial, isOverridingTrialConfig: $isOverridingTrialConfig, planId: $planId, priceUnitAmount: $unitQuantity, startDate: $startDate}
|
|
959
|
+
) {
|
|
960
|
+
...SlimSubscriptionFragment
|
|
961
|
+
}
|
|
962
|
+
}
|
|
963
|
+
${exports.SlimSubscriptionFragmentDoc}`;
|
|
964
|
+
exports.CancelSubscriptionDocument = (0, graphql_tag_1.default) `
|
|
965
|
+
mutation cancelSubscription($endDate: DateTime, $cancellationTime: SubscriptionCancellationTime, $subscriptionId: String!) {
|
|
966
|
+
cancelSubscription(
|
|
967
|
+
input: {subscriptionRefId: $subscriptionId, subscriptionCancellationTime: $cancellationTime, endDate: $endDate}
|
|
968
|
+
) {
|
|
969
|
+
...SlimSubscriptionFragment
|
|
970
|
+
}
|
|
971
|
+
}
|
|
972
|
+
${exports.SlimSubscriptionFragmentDoc}`;
|
|
973
|
+
exports.InitiateCheckoutDocument = (0, graphql_tag_1.default) `
|
|
974
|
+
mutation initiateCheckout($addons: [SubscriptionAddonInput!], $billingPeriod: BillingPeriod!, $cancelUrl: String!, $customerId: String!, $planId: String!, $successUrl: String!, $unitQuantity: Int) {
|
|
975
|
+
initiateCheckout(
|
|
976
|
+
input: {planId: $planId, billingPeriod: $billingPeriod, cancelUrl: $cancelUrl, customerId: $customerId, addons: $addons, unitQuantity: $unitQuantity, successUrl: $successUrl}
|
|
977
|
+
) {
|
|
978
|
+
id
|
|
979
|
+
checkoutUrl
|
|
980
|
+
checkoutBillingId
|
|
981
|
+
}
|
|
982
|
+
}
|
|
983
|
+
`;
|
|
984
|
+
exports.GetCustomerByIdDocument = (0, graphql_tag_1.default) `
|
|
985
|
+
query getCustomerById($customerId: String) {
|
|
986
|
+
customers(filter: {refId: {eq: $customerId}}) {
|
|
987
|
+
edges {
|
|
988
|
+
node {
|
|
989
|
+
...CustomerFragment
|
|
990
|
+
}
|
|
991
|
+
}
|
|
992
|
+
}
|
|
993
|
+
}
|
|
994
|
+
${exports.CustomerFragmentDoc}`;
|
|
995
|
+
exports.GetPaywallDocument = (0, graphql_tag_1.default) `
|
|
996
|
+
query getPaywall($productId: String) {
|
|
997
|
+
plans(
|
|
998
|
+
paging: {first: 50}
|
|
999
|
+
filter: {status: {eq: PUBLISHED}, isLatest: {is: true}, product: {refId: {eq: $productId}}}
|
|
1000
|
+
sorting: {field: refId, direction: ASC}
|
|
1001
|
+
) {
|
|
1002
|
+
edges {
|
|
1003
|
+
node {
|
|
1004
|
+
...PaywallPlanFragment
|
|
1005
|
+
compatibleAddons(filter: {status: {eq: PUBLISHED}, isLatest: {is: true}}) {
|
|
1006
|
+
...PaywallAddonFragment
|
|
1007
|
+
}
|
|
1008
|
+
}
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
}
|
|
1012
|
+
${exports.PaywallPlanFragmentDoc}
|
|
1013
|
+
${exports.PaywallAddonFragmentDoc}`;
|
|
1014
|
+
exports.GetCouponsDocument = (0, graphql_tag_1.default) `
|
|
1015
|
+
query getCoupons {
|
|
1016
|
+
coupons(filter: {status: {eq: ACTIVE}}, paging: {first: 50}) {
|
|
1017
|
+
edges {
|
|
1018
|
+
node {
|
|
1019
|
+
...CouponFragment
|
|
1020
|
+
}
|
|
1021
|
+
}
|
|
1022
|
+
}
|
|
1023
|
+
}
|
|
1024
|
+
${exports.CouponFragmentDoc}`;
|
|
1025
|
+
const defaultWrapper = (action, _operationName, _operationType) => action();
|
|
1026
|
+
function getSdk(client, withWrapper = defaultWrapper) {
|
|
1027
|
+
return {
|
|
1028
|
+
createCustomer(variables, requestHeaders) {
|
|
1029
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.CreateCustomerDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'createCustomer', 'mutation');
|
|
1030
|
+
},
|
|
1031
|
+
provisionCustomer(variables, requestHeaders) {
|
|
1032
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.ProvisionCustomerDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'provisionCustomer', 'mutation');
|
|
1033
|
+
},
|
|
1034
|
+
importCustomer(variables, requestHeaders) {
|
|
1035
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.ImportCustomerDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'importCustomer', 'mutation');
|
|
1036
|
+
},
|
|
1037
|
+
updateCustomer(variables, requestHeaders) {
|
|
1038
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.UpdateCustomerDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'updateCustomer', 'mutation');
|
|
1039
|
+
},
|
|
1040
|
+
updateSubscription(variables, requestHeaders) {
|
|
1041
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.UpdateSubscriptionDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'updateSubscription', 'mutation');
|
|
1042
|
+
},
|
|
1043
|
+
createSubscription(variables, requestHeaders) {
|
|
1044
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.CreateSubscriptionDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'createSubscription', 'mutation');
|
|
1045
|
+
},
|
|
1046
|
+
cancelSubscription(variables, requestHeaders) {
|
|
1047
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.CancelSubscriptionDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'cancelSubscription', 'mutation');
|
|
1048
|
+
},
|
|
1049
|
+
initiateCheckout(variables, requestHeaders) {
|
|
1050
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.InitiateCheckoutDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'initiateCheckout', 'mutation');
|
|
1051
|
+
},
|
|
1052
|
+
getCustomerById(variables, requestHeaders) {
|
|
1053
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.GetCustomerByIdDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'getCustomerById', 'query');
|
|
1054
|
+
},
|
|
1055
|
+
getPaywall(variables, requestHeaders) {
|
|
1056
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.GetPaywallDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'getPaywall', 'query');
|
|
1057
|
+
},
|
|
1058
|
+
getCoupons(variables, requestHeaders) {
|
|
1059
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.GetCouponsDocument, variables, Object.assign(Object.assign({}, requestHeaders), wrappedRequestHeaders)), 'getCoupons', 'query');
|
|
1060
|
+
}
|
|
1061
|
+
};
|
|
1062
|
+
}
|
|
1063
|
+
exports.getSdk = getSdk;
|
|
1064
|
+
//# sourceMappingURL=sdk.js.map
|