@jogolabs/billing-sdk-v2 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/.eslintignore +1 -0
- package/.eslintrc.js +18 -0
- package/dist/billing/src/__generated__/Billing.d.ts +20 -0
- package/dist/billing/src/__generated__/Billing.js +39 -0
- package/dist/billing/src/__generated__/core/ApiError.d.ts +10 -0
- package/dist/billing/src/__generated__/core/ApiError.js +20 -0
- package/dist/billing/src/__generated__/core/ApiRequestOptions.d.ts +13 -0
- package/dist/billing/src/__generated__/core/ApiRequestOptions.js +2 -0
- package/dist/billing/src/__generated__/core/ApiResult.d.ts +7 -0
- package/dist/billing/src/__generated__/core/ApiResult.js +2 -0
- package/dist/billing/src/__generated__/core/AxiosHttpRequest.d.ts +14 -0
- package/dist/billing/src/__generated__/core/AxiosHttpRequest.js +20 -0
- package/dist/billing/src/__generated__/core/BaseHttpRequest.d.ts +8 -0
- package/dist/billing/src/__generated__/core/BaseHttpRequest.js +10 -0
- package/dist/billing/src/__generated__/core/CancelablePromise.d.ts +20 -0
- package/dist/billing/src/__generated__/core/CancelablePromise.js +104 -0
- package/dist/billing/src/__generated__/core/OpenAPI.d.ts +16 -0
- package/dist/billing/src/__generated__/core/OpenAPI.js +14 -0
- package/dist/billing/src/__generated__/core/request.d.ts +34 -0
- package/dist/billing/src/__generated__/core/request.js +292 -0
- package/dist/billing/src/__generated__/index.d.ts +42 -0
- package/dist/billing/src/__generated__/index.js +74 -0
- package/dist/billing/src/__generated__/models/ConsumeClassResponse.d.ts +5 -0
- package/dist/billing/src/__generated__/models/ConsumeClassResponse.js +2 -0
- package/dist/billing/src/__generated__/models/CreateMerchantRequest.d.ts +23 -0
- package/dist/billing/src/__generated__/models/CreateMerchantRequest.js +15 -0
- package/dist/billing/src/__generated__/models/CreatePackageRequest.d.ts +8 -0
- package/dist/billing/src/__generated__/models/CreatePackageRequest.js +2 -0
- package/dist/billing/src/__generated__/models/CreateSubscriptionRequest.d.ts +25 -0
- package/dist/billing/src/__generated__/models/CreateSubscriptionRequest.js +2 -0
- package/dist/billing/src/__generated__/models/CreateSubscriptionResponse.d.ts +8 -0
- package/dist/billing/src/__generated__/models/CreateSubscriptionResponse.js +2 -0
- package/dist/billing/src/__generated__/models/Error.d.ts +3 -0
- package/dist/billing/src/__generated__/models/Error.js +2 -0
- package/dist/billing/src/__generated__/models/Merchant.d.ts +20 -0
- package/dist/billing/src/__generated__/models/Merchant.js +10 -0
- package/dist/billing/src/__generated__/models/MerchantProviderConfig.d.ts +15 -0
- package/dist/billing/src/__generated__/models/MerchantProviderConfig.js +11 -0
- package/dist/billing/src/__generated__/models/Package.d.ts +14 -0
- package/dist/billing/src/__generated__/models/Package.js +2 -0
- package/dist/billing/src/__generated__/models/Payment.d.ts +32 -0
- package/dist/billing/src/__generated__/models/Payment.js +22 -0
- package/dist/billing/src/__generated__/models/SavedCard.d.ts +18 -0
- package/dist/billing/src/__generated__/models/SavedCard.js +10 -0
- package/dist/billing/src/__generated__/models/Subscription.d.ts +33 -0
- package/dist/billing/src/__generated__/models/Subscription.js +14 -0
- package/dist/billing/src/__generated__/models/TokenizeCardRequest.d.ts +8 -0
- package/dist/billing/src/__generated__/models/TokenizeCardRequest.js +2 -0
- package/dist/billing/src/__generated__/models/UpdateMerchantRequest.d.ts +16 -0
- package/dist/billing/src/__generated__/models/UpdateMerchantRequest.js +11 -0
- package/dist/billing/src/__generated__/models/UpdatePackageRequest.d.ts +9 -0
- package/dist/billing/src/__generated__/models/UpdatePackageRequest.js +2 -0
- package/dist/billing/src/__generated__/schemas/$ConsumeClassResponse.d.ts +10 -0
- package/dist/billing/src/__generated__/schemas/$ConsumeClassResponse.js +17 -0
- package/dist/billing/src/__generated__/schemas/$CreateMerchantRequest.d.ts +39 -0
- package/dist/billing/src/__generated__/schemas/$CreateMerchantRequest.js +46 -0
- package/dist/billing/src/__generated__/schemas/$CreatePackageRequest.d.ts +28 -0
- package/dist/billing/src/__generated__/schemas/$CreatePackageRequest.js +35 -0
- package/dist/billing/src/__generated__/schemas/$CreateSubscriptionRequest.d.ts +57 -0
- package/dist/billing/src/__generated__/schemas/$CreateSubscriptionRequest.js +64 -0
- package/dist/billing/src/__generated__/schemas/$CreateSubscriptionResponse.d.ts +13 -0
- package/dist/billing/src/__generated__/schemas/$CreateSubscriptionResponse.js +20 -0
- package/dist/billing/src/__generated__/schemas/$Error.d.ts +7 -0
- package/dist/billing/src/__generated__/schemas/$Error.js +14 -0
- package/dist/billing/src/__generated__/schemas/$Merchant.d.ts +35 -0
- package/dist/billing/src/__generated__/schemas/$Merchant.js +42 -0
- package/dist/billing/src/__generated__/schemas/$MerchantProviderConfig.d.ts +19 -0
- package/dist/billing/src/__generated__/schemas/$MerchantProviderConfig.js +26 -0
- package/dist/billing/src/__generated__/schemas/$Package.d.ts +43 -0
- package/dist/billing/src/__generated__/schemas/$Package.js +50 -0
- package/dist/billing/src/__generated__/schemas/$Payment.d.ts +43 -0
- package/dist/billing/src/__generated__/schemas/$Payment.js +50 -0
- package/dist/billing/src/__generated__/schemas/$SavedCard.d.ts +39 -0
- package/dist/billing/src/__generated__/schemas/$SavedCard.js +46 -0
- package/dist/billing/src/__generated__/schemas/$Subscription.d.ts +63 -0
- package/dist/billing/src/__generated__/schemas/$Subscription.js +70 -0
- package/dist/billing/src/__generated__/schemas/$TokenizeCardRequest.d.ts +29 -0
- package/dist/billing/src/__generated__/schemas/$TokenizeCardRequest.js +36 -0
- package/dist/billing/src/__generated__/schemas/$UpdateMerchantRequest.d.ts +31 -0
- package/dist/billing/src/__generated__/schemas/$UpdateMerchantRequest.js +38 -0
- package/dist/billing/src/__generated__/schemas/$UpdatePackageRequest.d.ts +27 -0
- package/dist/billing/src/__generated__/schemas/$UpdatePackageRequest.js +34 -0
- package/dist/billing/src/__generated__/services/CardsService.d.ts +54 -0
- package/dist/billing/src/__generated__/services/CardsService.js +89 -0
- package/dist/billing/src/__generated__/services/HealthService.d.ts +16 -0
- package/dist/billing/src/__generated__/services/HealthService.js +22 -0
- package/dist/billing/src/__generated__/services/MerchantsService.d.ts +43 -0
- package/dist/billing/src/__generated__/services/MerchantsService.js +71 -0
- package/dist/billing/src/__generated__/services/PackagesService.d.ts +66 -0
- package/dist/billing/src/__generated__/services/PackagesService.js +110 -0
- package/dist/billing/src/__generated__/services/PaymentsService.d.ts +53 -0
- package/dist/billing/src/__generated__/services/PaymentsService.js +66 -0
- package/dist/billing/src/__generated__/services/SubscriptionsService.d.ts +86 -0
- package/dist/billing/src/__generated__/services/SubscriptionsService.js +148 -0
- package/dist/billing/src/index.d.ts +1 -0
- package/dist/billing/src/index.js +17 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +54 -0
- package/package.json +36 -0
- package/scripts/generate-api-sdk.js +86 -0
- package/scripts/publish.js +72 -0
- package/src/billing/src/__generated__/Billing.ts +43 -0
- package/src/billing/src/__generated__/core/ApiError.ts +25 -0
- package/src/billing/src/__generated__/core/ApiRequestOptions.ts +17 -0
- package/src/billing/src/__generated__/core/ApiResult.ts +11 -0
- package/src/billing/src/__generated__/core/AxiosHttpRequest.ts +26 -0
- package/src/billing/src/__generated__/core/BaseHttpRequest.ts +14 -0
- package/src/billing/src/__generated__/core/CancelablePromise.ts +131 -0
- package/src/billing/src/__generated__/core/OpenAPI.ts +32 -0
- package/src/billing/src/__generated__/core/request.ts +323 -0
- package/src/billing/src/__generated__/index.ts +50 -0
- package/src/billing/src/__generated__/models/ConsumeClassResponse.ts +10 -0
- package/src/billing/src/__generated__/models/CreateMerchantRequest.ts +28 -0
- package/src/billing/src/__generated__/models/CreatePackageRequest.ts +13 -0
- package/src/billing/src/__generated__/models/CreateSubscriptionRequest.ts +30 -0
- package/src/billing/src/__generated__/models/CreateSubscriptionResponse.ts +13 -0
- package/src/billing/src/__generated__/models/Error.ts +8 -0
- package/src/billing/src/__generated__/models/Merchant.ts +25 -0
- package/src/billing/src/__generated__/models/MerchantProviderConfig.ts +20 -0
- package/src/billing/src/__generated__/models/Package.ts +19 -0
- package/src/billing/src/__generated__/models/Payment.ts +37 -0
- package/src/billing/src/__generated__/models/SavedCard.ts +23 -0
- package/src/billing/src/__generated__/models/Subscription.ts +38 -0
- package/src/billing/src/__generated__/models/TokenizeCardRequest.ts +13 -0
- package/src/billing/src/__generated__/models/UpdateMerchantRequest.ts +21 -0
- package/src/billing/src/__generated__/models/UpdatePackageRequest.ts +14 -0
- package/src/billing/src/__generated__/schemas/$ConsumeClassResponse.ts +14 -0
- package/src/billing/src/__generated__/schemas/$CreateMerchantRequest.ts +43 -0
- package/src/billing/src/__generated__/schemas/$CreatePackageRequest.ts +32 -0
- package/src/billing/src/__generated__/schemas/$CreateSubscriptionRequest.ts +61 -0
- package/src/billing/src/__generated__/schemas/$CreateSubscriptionResponse.ts +17 -0
- package/src/billing/src/__generated__/schemas/$Error.ts +11 -0
- package/src/billing/src/__generated__/schemas/$Merchant.ts +39 -0
- package/src/billing/src/__generated__/schemas/$MerchantProviderConfig.ts +23 -0
- package/src/billing/src/__generated__/schemas/$Package.ts +47 -0
- package/src/billing/src/__generated__/schemas/$Payment.ts +47 -0
- package/src/billing/src/__generated__/schemas/$SavedCard.ts +43 -0
- package/src/billing/src/__generated__/schemas/$Subscription.ts +67 -0
- package/src/billing/src/__generated__/schemas/$TokenizeCardRequest.ts +33 -0
- package/src/billing/src/__generated__/schemas/$UpdateMerchantRequest.ts +35 -0
- package/src/billing/src/__generated__/schemas/$UpdatePackageRequest.ts +31 -0
- package/src/billing/src/__generated__/services/CardsService.ts +115 -0
- package/src/billing/src/__generated__/services/HealthService.ts +24 -0
- package/src/billing/src/__generated__/services/MerchantsService.ts +90 -0
- package/src/billing/src/__generated__/services/PackagesService.ts +150 -0
- package/src/billing/src/__generated__/services/PaymentsService.ts +96 -0
- package/src/billing/src/__generated__/services/SubscriptionsService.ts +185 -0
- package/src/billing/src/index.ts +1 -0
- package/src/index.ts +49 -0
- package/tsconfig.json +18 -0
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Payment = void 0;
|
|
4
|
+
var Payment;
|
|
5
|
+
(function (Payment) {
|
|
6
|
+
let type;
|
|
7
|
+
(function (type) {
|
|
8
|
+
type["SUBSCRIPTION"] = "subscription";
|
|
9
|
+
type["PRODUCT"] = "product";
|
|
10
|
+
})(type = Payment.type || (Payment.type = {}));
|
|
11
|
+
let provider;
|
|
12
|
+
(function (provider) {
|
|
13
|
+
provider["WOMPI"] = "wompi";
|
|
14
|
+
})(provider = Payment.provider || (Payment.provider = {}));
|
|
15
|
+
let status;
|
|
16
|
+
(function (status) {
|
|
17
|
+
status["PENDING"] = "pending";
|
|
18
|
+
status["COMPLETED"] = "completed";
|
|
19
|
+
status["FAILED"] = "failed";
|
|
20
|
+
status["REFUNDED"] = "refunded";
|
|
21
|
+
})(status = Payment.status || (Payment.status = {}));
|
|
22
|
+
})(Payment || (exports.Payment = Payment = {}));
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export type SavedCard = {
|
|
2
|
+
_id?: string;
|
|
3
|
+
customerId?: string;
|
|
4
|
+
merchantId?: string;
|
|
5
|
+
provider?: SavedCard.provider;
|
|
6
|
+
lastFour?: string;
|
|
7
|
+
cardBrand?: string | null;
|
|
8
|
+
expirationMonth?: number;
|
|
9
|
+
expirationYear?: number;
|
|
10
|
+
isDefault?: boolean;
|
|
11
|
+
active?: boolean;
|
|
12
|
+
createdAt?: string;
|
|
13
|
+
};
|
|
14
|
+
export declare namespace SavedCard {
|
|
15
|
+
enum provider {
|
|
16
|
+
WOMPI = "wompi"
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SavedCard = void 0;
|
|
4
|
+
var SavedCard;
|
|
5
|
+
(function (SavedCard) {
|
|
6
|
+
let provider;
|
|
7
|
+
(function (provider) {
|
|
8
|
+
provider["WOMPI"] = "wompi";
|
|
9
|
+
})(provider = SavedCard.provider || (SavedCard.provider = {}));
|
|
10
|
+
})(SavedCard || (exports.SavedCard = SavedCard = {}));
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { Package } from './Package';
|
|
2
|
+
export type Subscription = {
|
|
3
|
+
_id?: string;
|
|
4
|
+
merchantId?: string;
|
|
5
|
+
/**
|
|
6
|
+
* ID del cliente en jogo-backend
|
|
7
|
+
*/
|
|
8
|
+
customerId?: string;
|
|
9
|
+
packageId?: (string | Package);
|
|
10
|
+
status?: Subscription.status;
|
|
11
|
+
autoRenew?: boolean;
|
|
12
|
+
classesTotal?: number;
|
|
13
|
+
classesUsed?: number;
|
|
14
|
+
/**
|
|
15
|
+
* Campo virtual calculado: classesTotal - classesUsed
|
|
16
|
+
*/
|
|
17
|
+
readonly classesRemaining?: number;
|
|
18
|
+
startDate?: string;
|
|
19
|
+
endDate?: string;
|
|
20
|
+
savedCardId?: string | null;
|
|
21
|
+
lastPaymentId?: string | null;
|
|
22
|
+
createdAt?: string;
|
|
23
|
+
updatedAt?: string;
|
|
24
|
+
};
|
|
25
|
+
export declare namespace Subscription {
|
|
26
|
+
enum status {
|
|
27
|
+
PENDING_PAYMENT = "pending_payment",
|
|
28
|
+
ACTIVE = "active",
|
|
29
|
+
EXPIRED = "expired",
|
|
30
|
+
CANCELLED = "cancelled",
|
|
31
|
+
SUSPENDED = "suspended"
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Subscription = void 0;
|
|
4
|
+
var Subscription;
|
|
5
|
+
(function (Subscription) {
|
|
6
|
+
let status;
|
|
7
|
+
(function (status) {
|
|
8
|
+
status["PENDING_PAYMENT"] = "pending_payment";
|
|
9
|
+
status["ACTIVE"] = "active";
|
|
10
|
+
status["EXPIRED"] = "expired";
|
|
11
|
+
status["CANCELLED"] = "cancelled";
|
|
12
|
+
status["SUSPENDED"] = "suspended";
|
|
13
|
+
})(status = Subscription.status || (Subscription.status = {}));
|
|
14
|
+
})(Subscription || (exports.Subscription = Subscription = {}));
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export type UpdateMerchantRequest = {
|
|
2
|
+
name?: string;
|
|
3
|
+
email?: string;
|
|
4
|
+
apiKey?: string;
|
|
5
|
+
environment?: UpdateMerchantRequest.environment;
|
|
6
|
+
webhookUrl?: string;
|
|
7
|
+
redirectUrl?: string;
|
|
8
|
+
cardGroupId?: string;
|
|
9
|
+
active?: boolean;
|
|
10
|
+
};
|
|
11
|
+
export declare namespace UpdateMerchantRequest {
|
|
12
|
+
enum environment {
|
|
13
|
+
SANDBOX = "sandbox",
|
|
14
|
+
PRODUCTION = "production"
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UpdateMerchantRequest = void 0;
|
|
4
|
+
var UpdateMerchantRequest;
|
|
5
|
+
(function (UpdateMerchantRequest) {
|
|
6
|
+
let environment;
|
|
7
|
+
(function (environment) {
|
|
8
|
+
environment["SANDBOX"] = "sandbox";
|
|
9
|
+
environment["PRODUCTION"] = "production";
|
|
10
|
+
})(environment = UpdateMerchantRequest.environment || (UpdateMerchantRequest.environment = {}));
|
|
11
|
+
})(UpdateMerchantRequest || (exports.UpdateMerchantRequest = UpdateMerchantRequest = {}));
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$ConsumeClassResponse = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$ConsumeClassResponse = {
|
|
9
|
+
properties: {
|
|
10
|
+
subscription: {
|
|
11
|
+
type: 'Subscription',
|
|
12
|
+
},
|
|
13
|
+
classesRemaining: {
|
|
14
|
+
type: 'number',
|
|
15
|
+
},
|
|
16
|
+
},
|
|
17
|
+
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export declare const $CreateMerchantRequest: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly businessId: {
|
|
4
|
+
readonly type: "string";
|
|
5
|
+
readonly isRequired: true;
|
|
6
|
+
};
|
|
7
|
+
readonly name: {
|
|
8
|
+
readonly type: "string";
|
|
9
|
+
readonly isRequired: true;
|
|
10
|
+
};
|
|
11
|
+
readonly email: {
|
|
12
|
+
readonly type: "string";
|
|
13
|
+
readonly isRequired: true;
|
|
14
|
+
readonly format: "email";
|
|
15
|
+
};
|
|
16
|
+
readonly paymentProvider: {
|
|
17
|
+
readonly type: "Enum";
|
|
18
|
+
};
|
|
19
|
+
readonly apiKey: {
|
|
20
|
+
readonly type: "string";
|
|
21
|
+
readonly description: "API Key de Wompi (se encripta antes de guardar)";
|
|
22
|
+
readonly isRequired: true;
|
|
23
|
+
};
|
|
24
|
+
readonly environment: {
|
|
25
|
+
readonly type: "Enum";
|
|
26
|
+
};
|
|
27
|
+
readonly webhookUrl: {
|
|
28
|
+
readonly type: "string";
|
|
29
|
+
readonly format: "uri";
|
|
30
|
+
};
|
|
31
|
+
readonly redirectUrl: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
readonly format: "uri";
|
|
34
|
+
};
|
|
35
|
+
readonly cardGroupId: {
|
|
36
|
+
readonly type: "string";
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$CreateMerchantRequest = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$CreateMerchantRequest = {
|
|
9
|
+
properties: {
|
|
10
|
+
businessId: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
isRequired: true,
|
|
13
|
+
},
|
|
14
|
+
name: {
|
|
15
|
+
type: 'string',
|
|
16
|
+
isRequired: true,
|
|
17
|
+
},
|
|
18
|
+
email: {
|
|
19
|
+
type: 'string',
|
|
20
|
+
isRequired: true,
|
|
21
|
+
format: 'email',
|
|
22
|
+
},
|
|
23
|
+
paymentProvider: {
|
|
24
|
+
type: 'Enum',
|
|
25
|
+
},
|
|
26
|
+
apiKey: {
|
|
27
|
+
type: 'string',
|
|
28
|
+
description: `API Key de Wompi (se encripta antes de guardar)`,
|
|
29
|
+
isRequired: true,
|
|
30
|
+
},
|
|
31
|
+
environment: {
|
|
32
|
+
type: 'Enum',
|
|
33
|
+
},
|
|
34
|
+
webhookUrl: {
|
|
35
|
+
type: 'string',
|
|
36
|
+
format: 'uri',
|
|
37
|
+
},
|
|
38
|
+
redirectUrl: {
|
|
39
|
+
type: 'string',
|
|
40
|
+
format: 'uri',
|
|
41
|
+
},
|
|
42
|
+
cardGroupId: {
|
|
43
|
+
type: 'string',
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export declare const $CreatePackageRequest: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly name: {
|
|
4
|
+
readonly type: "string";
|
|
5
|
+
readonly isRequired: true;
|
|
6
|
+
};
|
|
7
|
+
readonly description: {
|
|
8
|
+
readonly type: "string";
|
|
9
|
+
};
|
|
10
|
+
readonly numberOfClasses: {
|
|
11
|
+
readonly type: "number";
|
|
12
|
+
readonly isRequired: true;
|
|
13
|
+
readonly minimum: 1;
|
|
14
|
+
};
|
|
15
|
+
readonly durationDays: {
|
|
16
|
+
readonly type: "number";
|
|
17
|
+
readonly isRequired: true;
|
|
18
|
+
readonly minimum: 1;
|
|
19
|
+
};
|
|
20
|
+
readonly price: {
|
|
21
|
+
readonly type: "number";
|
|
22
|
+
readonly isRequired: true;
|
|
23
|
+
};
|
|
24
|
+
readonly autoRenewDefault: {
|
|
25
|
+
readonly type: "boolean";
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$CreatePackageRequest = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$CreatePackageRequest = {
|
|
9
|
+
properties: {
|
|
10
|
+
name: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
isRequired: true,
|
|
13
|
+
},
|
|
14
|
+
description: {
|
|
15
|
+
type: 'string',
|
|
16
|
+
},
|
|
17
|
+
numberOfClasses: {
|
|
18
|
+
type: 'number',
|
|
19
|
+
isRequired: true,
|
|
20
|
+
minimum: 1,
|
|
21
|
+
},
|
|
22
|
+
durationDays: {
|
|
23
|
+
type: 'number',
|
|
24
|
+
isRequired: true,
|
|
25
|
+
minimum: 1,
|
|
26
|
+
},
|
|
27
|
+
price: {
|
|
28
|
+
type: 'number',
|
|
29
|
+
isRequired: true,
|
|
30
|
+
},
|
|
31
|
+
autoRenewDefault: {
|
|
32
|
+
type: 'boolean',
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
export declare const $CreateSubscriptionRequest: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly merchantId: {
|
|
4
|
+
readonly type: "string";
|
|
5
|
+
readonly isRequired: true;
|
|
6
|
+
};
|
|
7
|
+
readonly packageId: {
|
|
8
|
+
readonly type: "string";
|
|
9
|
+
readonly isRequired: true;
|
|
10
|
+
};
|
|
11
|
+
readonly autoRenew: {
|
|
12
|
+
readonly type: "boolean";
|
|
13
|
+
};
|
|
14
|
+
readonly customerEmail: {
|
|
15
|
+
readonly type: "string";
|
|
16
|
+
readonly isRequired: true;
|
|
17
|
+
readonly format: "email";
|
|
18
|
+
};
|
|
19
|
+
readonly customerName: {
|
|
20
|
+
readonly type: "string";
|
|
21
|
+
readonly isRequired: true;
|
|
22
|
+
};
|
|
23
|
+
readonly customerLastName: {
|
|
24
|
+
readonly type: "string";
|
|
25
|
+
readonly isRequired: true;
|
|
26
|
+
};
|
|
27
|
+
readonly customerPhone: {
|
|
28
|
+
readonly type: "string";
|
|
29
|
+
};
|
|
30
|
+
readonly city: {
|
|
31
|
+
readonly type: "string";
|
|
32
|
+
};
|
|
33
|
+
readonly address: {
|
|
34
|
+
readonly type: "string";
|
|
35
|
+
};
|
|
36
|
+
readonly savedCardId: {
|
|
37
|
+
readonly type: "string";
|
|
38
|
+
readonly description: "ID de tarjeta guardada. Requerido si no se envía cardNumber.";
|
|
39
|
+
};
|
|
40
|
+
readonly cvv: {
|
|
41
|
+
readonly type: "string";
|
|
42
|
+
readonly description: "CVV requerido siempre (con tarjeta guardada o nueva)";
|
|
43
|
+
};
|
|
44
|
+
readonly cardNumber: {
|
|
45
|
+
readonly type: "string";
|
|
46
|
+
readonly description: "Número de tarjeta. Requerido si no se envía savedCardId.";
|
|
47
|
+
};
|
|
48
|
+
readonly expirationMonth: {
|
|
49
|
+
readonly type: "number";
|
|
50
|
+
readonly maximum: 12;
|
|
51
|
+
readonly minimum: 1;
|
|
52
|
+
};
|
|
53
|
+
readonly expirationYear: {
|
|
54
|
+
readonly type: "number";
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
};
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$CreateSubscriptionRequest = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$CreateSubscriptionRequest = {
|
|
9
|
+
properties: {
|
|
10
|
+
merchantId: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
isRequired: true,
|
|
13
|
+
},
|
|
14
|
+
packageId: {
|
|
15
|
+
type: 'string',
|
|
16
|
+
isRequired: true,
|
|
17
|
+
},
|
|
18
|
+
autoRenew: {
|
|
19
|
+
type: 'boolean',
|
|
20
|
+
},
|
|
21
|
+
customerEmail: {
|
|
22
|
+
type: 'string',
|
|
23
|
+
isRequired: true,
|
|
24
|
+
format: 'email',
|
|
25
|
+
},
|
|
26
|
+
customerName: {
|
|
27
|
+
type: 'string',
|
|
28
|
+
isRequired: true,
|
|
29
|
+
},
|
|
30
|
+
customerLastName: {
|
|
31
|
+
type: 'string',
|
|
32
|
+
isRequired: true,
|
|
33
|
+
},
|
|
34
|
+
customerPhone: {
|
|
35
|
+
type: 'string',
|
|
36
|
+
},
|
|
37
|
+
city: {
|
|
38
|
+
type: 'string',
|
|
39
|
+
},
|
|
40
|
+
address: {
|
|
41
|
+
type: 'string',
|
|
42
|
+
},
|
|
43
|
+
savedCardId: {
|
|
44
|
+
type: 'string',
|
|
45
|
+
description: `ID de tarjeta guardada. Requerido si no se envía cardNumber.`,
|
|
46
|
+
},
|
|
47
|
+
cvv: {
|
|
48
|
+
type: 'string',
|
|
49
|
+
description: `CVV requerido siempre (con tarjeta guardada o nueva)`,
|
|
50
|
+
},
|
|
51
|
+
cardNumber: {
|
|
52
|
+
type: 'string',
|
|
53
|
+
description: `Número de tarjeta. Requerido si no se envía savedCardId.`,
|
|
54
|
+
},
|
|
55
|
+
expirationMonth: {
|
|
56
|
+
type: 'number',
|
|
57
|
+
maximum: 12,
|
|
58
|
+
minimum: 1,
|
|
59
|
+
},
|
|
60
|
+
expirationYear: {
|
|
61
|
+
type: 'number',
|
|
62
|
+
},
|
|
63
|
+
},
|
|
64
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const $CreateSubscriptionResponse: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly subscription: {
|
|
4
|
+
readonly type: "Subscription";
|
|
5
|
+
};
|
|
6
|
+
readonly redirectUrl: {
|
|
7
|
+
readonly type: "string";
|
|
8
|
+
readonly description: "URL de Wompi para completar autenticación 3DS. Si está presente, redirigir al usuario a esta URL. La suscripción se activará cuando Wompi notifique vía webhook.";
|
|
9
|
+
readonly isNullable: true;
|
|
10
|
+
readonly format: "uri";
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$CreateSubscriptionResponse = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$CreateSubscriptionResponse = {
|
|
9
|
+
properties: {
|
|
10
|
+
subscription: {
|
|
11
|
+
type: 'Subscription',
|
|
12
|
+
},
|
|
13
|
+
redirectUrl: {
|
|
14
|
+
type: 'string',
|
|
15
|
+
description: `URL de Wompi para completar autenticación 3DS. Si está presente, redirigir al usuario a esta URL. La suscripción se activará cuando Wompi notifique vía webhook.`,
|
|
16
|
+
isNullable: true,
|
|
17
|
+
format: 'uri',
|
|
18
|
+
},
|
|
19
|
+
},
|
|
20
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$Error = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$Error = {
|
|
9
|
+
properties: {
|
|
10
|
+
error: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
},
|
|
13
|
+
},
|
|
14
|
+
};
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export declare const $Merchant: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly _id: {
|
|
4
|
+
readonly type: "string";
|
|
5
|
+
};
|
|
6
|
+
readonly businessId: {
|
|
7
|
+
readonly type: "string";
|
|
8
|
+
readonly description: "ID del negocio en jogo-backend";
|
|
9
|
+
};
|
|
10
|
+
readonly name: {
|
|
11
|
+
readonly type: "string";
|
|
12
|
+
};
|
|
13
|
+
readonly email: {
|
|
14
|
+
readonly type: "string";
|
|
15
|
+
readonly format: "email";
|
|
16
|
+
};
|
|
17
|
+
readonly paymentProvider: {
|
|
18
|
+
readonly type: "Enum";
|
|
19
|
+
};
|
|
20
|
+
readonly providerConfig: {
|
|
21
|
+
readonly type: "MerchantProviderConfig";
|
|
22
|
+
};
|
|
23
|
+
readonly active: {
|
|
24
|
+
readonly type: "boolean";
|
|
25
|
+
};
|
|
26
|
+
readonly createdAt: {
|
|
27
|
+
readonly type: "string";
|
|
28
|
+
readonly format: "date-time";
|
|
29
|
+
};
|
|
30
|
+
readonly updatedAt: {
|
|
31
|
+
readonly type: "string";
|
|
32
|
+
readonly format: "date-time";
|
|
33
|
+
};
|
|
34
|
+
};
|
|
35
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$Merchant = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$Merchant = {
|
|
9
|
+
properties: {
|
|
10
|
+
_id: {
|
|
11
|
+
type: 'string',
|
|
12
|
+
},
|
|
13
|
+
businessId: {
|
|
14
|
+
type: 'string',
|
|
15
|
+
description: `ID del negocio en jogo-backend`,
|
|
16
|
+
},
|
|
17
|
+
name: {
|
|
18
|
+
type: 'string',
|
|
19
|
+
},
|
|
20
|
+
email: {
|
|
21
|
+
type: 'string',
|
|
22
|
+
format: 'email',
|
|
23
|
+
},
|
|
24
|
+
paymentProvider: {
|
|
25
|
+
type: 'Enum',
|
|
26
|
+
},
|
|
27
|
+
providerConfig: {
|
|
28
|
+
type: 'MerchantProviderConfig',
|
|
29
|
+
},
|
|
30
|
+
active: {
|
|
31
|
+
type: 'boolean',
|
|
32
|
+
},
|
|
33
|
+
createdAt: {
|
|
34
|
+
type: 'string',
|
|
35
|
+
format: 'date-time',
|
|
36
|
+
},
|
|
37
|
+
updatedAt: {
|
|
38
|
+
type: 'string',
|
|
39
|
+
format: 'date-time',
|
|
40
|
+
},
|
|
41
|
+
},
|
|
42
|
+
};
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export declare const $MerchantProviderConfig: {
|
|
2
|
+
readonly properties: {
|
|
3
|
+
readonly environment: {
|
|
4
|
+
readonly type: "Enum";
|
|
5
|
+
};
|
|
6
|
+
readonly webhookUrl: {
|
|
7
|
+
readonly type: "string";
|
|
8
|
+
readonly format: "uri";
|
|
9
|
+
};
|
|
10
|
+
readonly redirectUrl: {
|
|
11
|
+
readonly type: "string";
|
|
12
|
+
readonly format: "uri";
|
|
13
|
+
};
|
|
14
|
+
readonly cardGroupId: {
|
|
15
|
+
readonly type: "string";
|
|
16
|
+
readonly description: "ID del grupo de tarjetas en Wompi para validación adicional";
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.$MerchantProviderConfig = void 0;
|
|
4
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
5
|
+
/* istanbul ignore file */
|
|
6
|
+
/* tslint:disable */
|
|
7
|
+
/* eslint-disable */
|
|
8
|
+
exports.$MerchantProviderConfig = {
|
|
9
|
+
properties: {
|
|
10
|
+
environment: {
|
|
11
|
+
type: 'Enum',
|
|
12
|
+
},
|
|
13
|
+
webhookUrl: {
|
|
14
|
+
type: 'string',
|
|
15
|
+
format: 'uri',
|
|
16
|
+
},
|
|
17
|
+
redirectUrl: {
|
|
18
|
+
type: 'string',
|
|
19
|
+
format: 'uri',
|
|
20
|
+
},
|
|
21
|
+
cardGroupId: {
|
|
22
|
+
type: 'string',
|
|
23
|
+
description: `ID del grupo de tarjetas en Wompi para validación adicional`,
|
|
24
|
+
},
|
|
25
|
+
},
|
|
26
|
+
};
|