@l7mp/tivadar-ai-api-sdk 0.2.10 → 0.2.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api-client.d.ts +29 -4
- package/dist/api-client.js +22 -3
- package/dist/apis/AdminSubscriptionsApi.d.ts +82 -0
- package/dist/apis/AdminSubscriptionsApi.js +242 -0
- package/dist/apis/SubscriptionApi.d.ts +54 -75
- package/dist/apis/SubscriptionApi.js +95 -114
- package/dist/apis/VoiceUsageApi.d.ts +31 -0
- package/dist/apis/VoiceUsageApi.js +73 -0
- package/dist/apis/index.d.ts +2 -0
- package/dist/apis/index.js +2 -0
- package/dist/esm/api-client.d.ts +29 -4
- package/dist/esm/api-client.js +22 -3
- package/dist/esm/apis/AdminSubscriptionsApi.d.ts +82 -0
- package/dist/esm/apis/AdminSubscriptionsApi.js +238 -0
- package/dist/esm/apis/SubscriptionApi.d.ts +54 -75
- package/dist/esm/apis/SubscriptionApi.js +96 -115
- package/dist/esm/apis/VoiceUsageApi.d.ts +31 -0
- package/dist/esm/apis/VoiceUsageApi.js +69 -0
- package/dist/esm/apis/index.d.ts +2 -0
- package/dist/esm/apis/index.js +2 -0
- package/dist/esm/models/AdminGrantMinutesRequest.d.ts +38 -0
- package/dist/esm/models/AdminGrantMinutesRequest.js +45 -0
- package/dist/esm/models/AdminSetSubscriptionRequest.d.ts +86 -0
- package/dist/esm/models/AdminSetSubscriptionRequest.js +71 -0
- package/dist/esm/models/BillingPortalRequest.d.ts +1 -1
- package/dist/esm/models/BillingPortalResponse.d.ts +1 -1
- package/dist/esm/models/CancelSubscriptionRequest.d.ts +2 -2
- package/dist/esm/models/CheckoutSessionResponse.d.ts +2 -2
- package/dist/esm/models/CreateCheckoutSessionRequest.d.ts +21 -7
- package/dist/esm/models/CreateCheckoutSessionRequest.js +18 -5
- package/dist/esm/models/CurrentPeriodUsage.d.ts +59 -0
- package/dist/esm/models/CurrentPeriodUsage.js +62 -0
- package/dist/esm/models/LifecycleResponse.d.ts +50 -0
- package/dist/esm/models/LifecycleResponse.js +51 -0
- package/dist/esm/models/PauseSubscriptionRequest.d.ts +1 -1
- package/dist/esm/models/PlanCatalogEntry.d.ts +90 -0
- package/dist/esm/models/PlanCatalogEntry.js +73 -0
- package/dist/esm/models/PlanCatalogEntryOverageInner.d.ts +44 -0
- package/dist/esm/models/PlanCatalogEntryOverageInner.js +45 -0
- package/dist/esm/models/PlanCatalogPrice.d.ts +58 -0
- package/dist/esm/models/PlanCatalogPrice.js +60 -0
- package/dist/esm/models/SubscriptionPlanSummary.d.ts +83 -0
- package/dist/esm/models/SubscriptionPlanSummary.js +70 -0
- package/dist/esm/models/SubscriptionPlanSummaryOverageRate.d.ts +38 -0
- package/dist/esm/models/SubscriptionPlanSummaryOverageRate.js +43 -0
- package/dist/esm/models/SubscriptionStatus.d.ts +103 -10
- package/dist/esm/models/SubscriptionStatus.js +58 -9
- package/dist/esm/models/SubscriptionUsageSummary.d.ts +56 -0
- package/dist/esm/models/SubscriptionUsageSummary.js +57 -0
- package/dist/esm/models/UpdatePlanRequest.d.ts +13 -5
- package/dist/esm/models/UpdatePlanRequest.js +12 -3
- package/dist/esm/models/UsageBreakdownByAgent.d.ts +44 -0
- package/dist/esm/models/UsageBreakdownByAgent.js +49 -0
- package/dist/esm/models/UsageBreakdownByDay.d.ts +44 -0
- package/dist/esm/models/UsageBreakdownByDay.js +51 -0
- package/dist/esm/models/UsageHistoryResponse.d.ts +39 -0
- package/dist/esm/models/UsageHistoryResponse.js +48 -0
- package/dist/esm/models/UsageRecordDto.d.ts +80 -0
- package/dist/esm/models/UsageRecordDto.js +65 -0
- package/dist/esm/models/VoiceUsageReportRequest.d.ts +62 -0
- package/dist/esm/models/VoiceUsageReportRequest.js +57 -0
- package/dist/esm/models/VoiceUsageReportResponse.d.ts +51 -0
- package/dist/esm/models/VoiceUsageReportResponse.js +52 -0
- package/dist/esm/models/index.d.ts +16 -13
- package/dist/esm/models/index.js +16 -13
- package/dist/models/AdminGrantMinutesRequest.d.ts +38 -0
- package/dist/models/AdminGrantMinutesRequest.js +52 -0
- package/dist/models/AdminSetSubscriptionRequest.d.ts +86 -0
- package/dist/models/AdminSetSubscriptionRequest.js +79 -0
- package/dist/models/BillingPortalRequest.d.ts +1 -1
- package/dist/models/BillingPortalResponse.d.ts +1 -1
- package/dist/models/CancelSubscriptionRequest.d.ts +2 -2
- package/dist/models/CheckoutSessionResponse.d.ts +2 -2
- package/dist/models/CreateCheckoutSessionRequest.d.ts +21 -7
- package/dist/models/CreateCheckoutSessionRequest.js +19 -5
- package/dist/models/CurrentPeriodUsage.d.ts +59 -0
- package/dist/models/CurrentPeriodUsage.js +69 -0
- package/dist/models/LifecycleResponse.d.ts +50 -0
- package/dist/models/LifecycleResponse.js +58 -0
- package/dist/models/PauseSubscriptionRequest.d.ts +1 -1
- package/dist/models/PlanCatalogEntry.d.ts +90 -0
- package/dist/models/PlanCatalogEntry.js +80 -0
- package/dist/models/PlanCatalogEntryOverageInner.d.ts +44 -0
- package/dist/models/PlanCatalogEntryOverageInner.js +52 -0
- package/dist/models/PlanCatalogPrice.d.ts +58 -0
- package/dist/models/PlanCatalogPrice.js +68 -0
- package/dist/models/SubscriptionPlanSummary.d.ts +83 -0
- package/dist/models/SubscriptionPlanSummary.js +77 -0
- package/dist/models/SubscriptionPlanSummaryOverageRate.d.ts +38 -0
- package/dist/models/SubscriptionPlanSummaryOverageRate.js +50 -0
- package/dist/models/SubscriptionStatus.d.ts +103 -10
- package/dist/models/SubscriptionStatus.js +59 -9
- package/dist/models/SubscriptionUsageSummary.d.ts +56 -0
- package/dist/models/SubscriptionUsageSummary.js +64 -0
- package/dist/models/UpdatePlanRequest.d.ts +13 -5
- package/dist/models/UpdatePlanRequest.js +13 -3
- package/dist/models/UsageBreakdownByAgent.d.ts +44 -0
- package/dist/models/UsageBreakdownByAgent.js +56 -0
- package/dist/models/UsageBreakdownByDay.d.ts +44 -0
- package/dist/models/UsageBreakdownByDay.js +58 -0
- package/dist/models/UsageHistoryResponse.d.ts +39 -0
- package/dist/models/UsageHistoryResponse.js +55 -0
- package/dist/models/UsageRecordDto.d.ts +80 -0
- package/dist/models/UsageRecordDto.js +72 -0
- package/dist/models/VoiceUsageReportRequest.d.ts +62 -0
- package/dist/models/VoiceUsageReportRequest.js +64 -0
- package/dist/models/VoiceUsageReportResponse.d.ts +51 -0
- package/dist/models/VoiceUsageReportResponse.js +59 -0
- package/dist/models/index.d.ts +16 -13
- package/dist/models/index.js +16 -13
- package/package.json +1 -1
- package/src/api-client.ts +42 -6
- package/src/apis/AdminSubscriptionsApi.ts +327 -0
- package/src/apis/SubscriptionApi.ts +130 -162
- package/src/apis/VoiceUsageApi.ts +86 -0
- package/src/apis/index.ts +2 -0
- package/src/models/AdminGrantMinutesRequest.ts +74 -0
- package/src/models/AdminSetSubscriptionRequest.ts +136 -0
- package/src/models/BillingPortalRequest.ts +1 -1
- package/src/models/BillingPortalResponse.ts +1 -1
- package/src/models/CancelSubscriptionRequest.ts +2 -2
- package/src/models/CheckoutSessionResponse.ts +2 -2
- package/src/models/CreateCheckoutSessionRequest.ts +33 -12
- package/src/models/CurrentPeriodUsage.ts +124 -0
- package/src/models/LifecycleResponse.ts +91 -0
- package/src/models/PauseSubscriptionRequest.ts +1 -1
- package/src/models/PlanCatalogEntry.ts +158 -0
- package/src/models/PlanCatalogEntryOverageInner.ts +81 -0
- package/src/models/PlanCatalogPrice.ts +103 -0
- package/src/models/SubscriptionPlanSummary.ts +143 -0
- package/src/models/SubscriptionPlanSummaryOverageRate.ts +73 -0
- package/src/models/SubscriptionStatus.ts +150 -32
- package/src/models/SubscriptionUsageSummary.ts +101 -0
- package/src/models/UpdatePlanRequest.ts +20 -8
- package/src/models/UsageBreakdownByAgent.ts +83 -0
- package/src/models/UsageBreakdownByDay.ts +84 -0
- package/src/models/UsageHistoryResponse.ts +83 -0
- package/src/models/UsageRecordDto.ts +133 -0
- package/src/models/VoiceUsageReportRequest.ts +108 -0
- package/src/models/VoiceUsageReportResponse.ts +99 -0
- package/src/models/index.ts +16 -13
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Tivadar AI Backend API
|
|
5
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* Check if a given object implements the AdminGrantMinutesRequest interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfAdminGrantMinutesRequest(value) {
|
|
18
|
+
if (!('minutes' in value) || value['minutes'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
return true;
|
|
21
|
+
}
|
|
22
|
+
export function AdminGrantMinutesRequestFromJSON(json) {
|
|
23
|
+
return AdminGrantMinutesRequestFromJSONTyped(json, false);
|
|
24
|
+
}
|
|
25
|
+
export function AdminGrantMinutesRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
26
|
+
if (json == null) {
|
|
27
|
+
return json;
|
|
28
|
+
}
|
|
29
|
+
return {
|
|
30
|
+
'minutes': json['minutes'],
|
|
31
|
+
'note': json['note'] == null ? undefined : json['note'],
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
export function AdminGrantMinutesRequestToJSON(json) {
|
|
35
|
+
return AdminGrantMinutesRequestToJSONTyped(json, false);
|
|
36
|
+
}
|
|
37
|
+
export function AdminGrantMinutesRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
38
|
+
if (value == null) {
|
|
39
|
+
return value;
|
|
40
|
+
}
|
|
41
|
+
return {
|
|
42
|
+
'minutes': value['minutes'],
|
|
43
|
+
'note': value['note'],
|
|
44
|
+
};
|
|
45
|
+
}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tivadar AI Backend API
|
|
3
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface AdminSetSubscriptionRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface AdminSetSubscriptionRequest {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof AdminSetSubscriptionRequest
|
|
22
|
+
*/
|
|
23
|
+
planSlug: string;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof AdminSetSubscriptionRequest
|
|
28
|
+
*/
|
|
29
|
+
status?: AdminSetSubscriptionRequestStatusEnum;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {string}
|
|
33
|
+
* @memberof AdminSetSubscriptionRequest
|
|
34
|
+
*/
|
|
35
|
+
billingInterval?: AdminSetSubscriptionRequestBillingIntervalEnum | null;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {string}
|
|
39
|
+
* @memberof AdminSetSubscriptionRequest
|
|
40
|
+
*/
|
|
41
|
+
currency?: string;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {Date}
|
|
45
|
+
* @memberof AdminSetSubscriptionRequest
|
|
46
|
+
*/
|
|
47
|
+
currentPeriodStart?: Date;
|
|
48
|
+
/**
|
|
49
|
+
*
|
|
50
|
+
* @type {Date}
|
|
51
|
+
* @memberof AdminSetSubscriptionRequest
|
|
52
|
+
*/
|
|
53
|
+
currentPeriodEnd?: Date;
|
|
54
|
+
/**
|
|
55
|
+
* Stored on the audit event for context.
|
|
56
|
+
* @type {string}
|
|
57
|
+
* @memberof AdminSetSubscriptionRequest
|
|
58
|
+
*/
|
|
59
|
+
note?: string;
|
|
60
|
+
}
|
|
61
|
+
/**
|
|
62
|
+
* @export
|
|
63
|
+
*/
|
|
64
|
+
export declare const AdminSetSubscriptionRequestStatusEnum: {
|
|
65
|
+
readonly Active: "active";
|
|
66
|
+
readonly Trialing: "trialing";
|
|
67
|
+
readonly Paused: "paused";
|
|
68
|
+
readonly Canceled: "canceled";
|
|
69
|
+
};
|
|
70
|
+
export type AdminSetSubscriptionRequestStatusEnum = typeof AdminSetSubscriptionRequestStatusEnum[keyof typeof AdminSetSubscriptionRequestStatusEnum];
|
|
71
|
+
/**
|
|
72
|
+
* @export
|
|
73
|
+
*/
|
|
74
|
+
export declare const AdminSetSubscriptionRequestBillingIntervalEnum: {
|
|
75
|
+
readonly Monthly: "monthly";
|
|
76
|
+
readonly Yearly: "yearly";
|
|
77
|
+
};
|
|
78
|
+
export type AdminSetSubscriptionRequestBillingIntervalEnum = typeof AdminSetSubscriptionRequestBillingIntervalEnum[keyof typeof AdminSetSubscriptionRequestBillingIntervalEnum];
|
|
79
|
+
/**
|
|
80
|
+
* Check if a given object implements the AdminSetSubscriptionRequest interface.
|
|
81
|
+
*/
|
|
82
|
+
export declare function instanceOfAdminSetSubscriptionRequest(value: object): value is AdminSetSubscriptionRequest;
|
|
83
|
+
export declare function AdminSetSubscriptionRequestFromJSON(json: any): AdminSetSubscriptionRequest;
|
|
84
|
+
export declare function AdminSetSubscriptionRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): AdminSetSubscriptionRequest;
|
|
85
|
+
export declare function AdminSetSubscriptionRequestToJSON(json: any): AdminSetSubscriptionRequest;
|
|
86
|
+
export declare function AdminSetSubscriptionRequestToJSONTyped(value?: AdminSetSubscriptionRequest | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Tivadar AI Backend API
|
|
5
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export const AdminSetSubscriptionRequestStatusEnum = {
|
|
18
|
+
Active: 'active',
|
|
19
|
+
Trialing: 'trialing',
|
|
20
|
+
Paused: 'paused',
|
|
21
|
+
Canceled: 'canceled'
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* @export
|
|
25
|
+
*/
|
|
26
|
+
export const AdminSetSubscriptionRequestBillingIntervalEnum = {
|
|
27
|
+
Monthly: 'monthly',
|
|
28
|
+
Yearly: 'yearly'
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the AdminSetSubscriptionRequest interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfAdminSetSubscriptionRequest(value) {
|
|
34
|
+
if (!('planSlug' in value) || value['planSlug'] === undefined)
|
|
35
|
+
return false;
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
export function AdminSetSubscriptionRequestFromJSON(json) {
|
|
39
|
+
return AdminSetSubscriptionRequestFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
export function AdminSetSubscriptionRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
42
|
+
if (json == null) {
|
|
43
|
+
return json;
|
|
44
|
+
}
|
|
45
|
+
return {
|
|
46
|
+
'planSlug': json['planSlug'],
|
|
47
|
+
'status': json['status'] == null ? undefined : json['status'],
|
|
48
|
+
'billingInterval': json['billingInterval'] == null ? undefined : json['billingInterval'],
|
|
49
|
+
'currency': json['currency'] == null ? undefined : json['currency'],
|
|
50
|
+
'currentPeriodStart': json['currentPeriodStart'] == null ? undefined : (new Date(json['currentPeriodStart'])),
|
|
51
|
+
'currentPeriodEnd': json['currentPeriodEnd'] == null ? undefined : (new Date(json['currentPeriodEnd'])),
|
|
52
|
+
'note': json['note'] == null ? undefined : json['note'],
|
|
53
|
+
};
|
|
54
|
+
}
|
|
55
|
+
export function AdminSetSubscriptionRequestToJSON(json) {
|
|
56
|
+
return AdminSetSubscriptionRequestToJSONTyped(json, false);
|
|
57
|
+
}
|
|
58
|
+
export function AdminSetSubscriptionRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
59
|
+
if (value == null) {
|
|
60
|
+
return value;
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
'planSlug': value['planSlug'],
|
|
64
|
+
'status': value['status'],
|
|
65
|
+
'billingInterval': value['billingInterval'],
|
|
66
|
+
'currency': value['currency'],
|
|
67
|
+
'currentPeriodStart': value['currentPeriodStart'] == null ? value['currentPeriodStart'] : value['currentPeriodStart'].toISOString(),
|
|
68
|
+
'currentPeriodEnd': value['currentPeriodEnd'] == null ? value['currentPeriodEnd'] : value['currentPeriodEnd'].toISOString(),
|
|
69
|
+
'note': value['note'],
|
|
70
|
+
};
|
|
71
|
+
}
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
*/
|
|
17
17
|
export interface CancelSubscriptionRequest {
|
|
18
18
|
/**
|
|
19
|
-
*
|
|
19
|
+
*
|
|
20
20
|
* @type {boolean}
|
|
21
21
|
* @memberof CancelSubscriptionRequest
|
|
22
22
|
*/
|
|
23
23
|
cancelImmediately?: boolean;
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
25
|
+
*
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof CancelSubscriptionRequest
|
|
28
28
|
*/
|
|
@@ -16,13 +16,13 @@
|
|
|
16
16
|
*/
|
|
17
17
|
export interface CheckoutSessionResponse {
|
|
18
18
|
/**
|
|
19
|
-
*
|
|
19
|
+
*
|
|
20
20
|
* @type {string}
|
|
21
21
|
* @memberof CheckoutSessionResponse
|
|
22
22
|
*/
|
|
23
23
|
id: string;
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
25
|
+
*
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof CheckoutSessionResponse
|
|
28
28
|
*/
|
|
@@ -16,30 +16,44 @@
|
|
|
16
16
|
*/
|
|
17
17
|
export interface CreateCheckoutSessionRequest {
|
|
18
18
|
/**
|
|
19
|
-
*
|
|
19
|
+
*
|
|
20
20
|
* @type {string}
|
|
21
21
|
* @memberof CreateCheckoutSessionRequest
|
|
22
22
|
*/
|
|
23
23
|
planSlug: string;
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
25
|
+
*
|
|
26
26
|
* @type {string}
|
|
27
27
|
* @memberof CreateCheckoutSessionRequest
|
|
28
28
|
*/
|
|
29
|
-
|
|
29
|
+
interval: CreateCheckoutSessionRequestIntervalEnum;
|
|
30
30
|
/**
|
|
31
|
-
*
|
|
31
|
+
* ISO-4217 lowercase. Defaults to the org subscription currency or the system default.
|
|
32
32
|
* @type {string}
|
|
33
33
|
* @memberof CreateCheckoutSessionRequest
|
|
34
34
|
*/
|
|
35
|
-
|
|
35
|
+
currency?: string;
|
|
36
36
|
/**
|
|
37
|
-
*
|
|
37
|
+
*
|
|
38
38
|
* @type {string}
|
|
39
39
|
* @memberof CreateCheckoutSessionRequest
|
|
40
40
|
*/
|
|
41
|
-
|
|
41
|
+
successUrl: string;
|
|
42
|
+
/**
|
|
43
|
+
*
|
|
44
|
+
* @type {string}
|
|
45
|
+
* @memberof CreateCheckoutSessionRequest
|
|
46
|
+
*/
|
|
47
|
+
cancelUrl: string;
|
|
42
48
|
}
|
|
49
|
+
/**
|
|
50
|
+
* @export
|
|
51
|
+
*/
|
|
52
|
+
export declare const CreateCheckoutSessionRequestIntervalEnum: {
|
|
53
|
+
readonly Monthly: "monthly";
|
|
54
|
+
readonly Yearly: "yearly";
|
|
55
|
+
};
|
|
56
|
+
export type CreateCheckoutSessionRequestIntervalEnum = typeof CreateCheckoutSessionRequestIntervalEnum[keyof typeof CreateCheckoutSessionRequestIntervalEnum];
|
|
43
57
|
/**
|
|
44
58
|
* Check if a given object implements the CreateCheckoutSessionRequest interface.
|
|
45
59
|
*/
|
|
@@ -11,13 +11,24 @@
|
|
|
11
11
|
* https://openapi-generator.tech
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
|
+
/**
|
|
15
|
+
* @export
|
|
16
|
+
*/
|
|
17
|
+
export const CreateCheckoutSessionRequestIntervalEnum = {
|
|
18
|
+
Monthly: 'monthly',
|
|
19
|
+
Yearly: 'yearly'
|
|
20
|
+
};
|
|
14
21
|
/**
|
|
15
22
|
* Check if a given object implements the CreateCheckoutSessionRequest interface.
|
|
16
23
|
*/
|
|
17
24
|
export function instanceOfCreateCheckoutSessionRequest(value) {
|
|
18
25
|
if (!('planSlug' in value) || value['planSlug'] === undefined)
|
|
19
26
|
return false;
|
|
20
|
-
if (!('
|
|
27
|
+
if (!('interval' in value) || value['interval'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('successUrl' in value) || value['successUrl'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
if (!('cancelUrl' in value) || value['cancelUrl'] === undefined)
|
|
21
32
|
return false;
|
|
22
33
|
return true;
|
|
23
34
|
}
|
|
@@ -30,9 +41,10 @@ export function CreateCheckoutSessionRequestFromJSONTyped(json, ignoreDiscrimina
|
|
|
30
41
|
}
|
|
31
42
|
return {
|
|
32
43
|
'planSlug': json['planSlug'],
|
|
33
|
-
'
|
|
34
|
-
'
|
|
35
|
-
'
|
|
44
|
+
'interval': json['interval'],
|
|
45
|
+
'currency': json['currency'] == null ? undefined : json['currency'],
|
|
46
|
+
'successUrl': json['successUrl'],
|
|
47
|
+
'cancelUrl': json['cancelUrl'],
|
|
36
48
|
};
|
|
37
49
|
}
|
|
38
50
|
export function CreateCheckoutSessionRequestToJSON(json) {
|
|
@@ -44,7 +56,8 @@ export function CreateCheckoutSessionRequestToJSONTyped(value, ignoreDiscriminat
|
|
|
44
56
|
}
|
|
45
57
|
return {
|
|
46
58
|
'planSlug': value['planSlug'],
|
|
47
|
-
'
|
|
59
|
+
'interval': value['interval'],
|
|
60
|
+
'currency': value['currency'],
|
|
48
61
|
'successUrl': value['successUrl'],
|
|
49
62
|
'cancelUrl': value['cancelUrl'],
|
|
50
63
|
};
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tivadar AI Backend API
|
|
3
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { UsageBreakdownByDay } from './UsageBreakdownByDay';
|
|
13
|
+
import type { SubscriptionUsageSummary } from './SubscriptionUsageSummary';
|
|
14
|
+
import type { UsageBreakdownByAgent } from './UsageBreakdownByAgent';
|
|
15
|
+
/**
|
|
16
|
+
*
|
|
17
|
+
* @export
|
|
18
|
+
* @interface CurrentPeriodUsage
|
|
19
|
+
*/
|
|
20
|
+
export interface CurrentPeriodUsage {
|
|
21
|
+
/**
|
|
22
|
+
*
|
|
23
|
+
* @type {Date}
|
|
24
|
+
* @memberof CurrentPeriodUsage
|
|
25
|
+
*/
|
|
26
|
+
periodStart: Date | null;
|
|
27
|
+
/**
|
|
28
|
+
*
|
|
29
|
+
* @type {Date}
|
|
30
|
+
* @memberof CurrentPeriodUsage
|
|
31
|
+
*/
|
|
32
|
+
periodEnd: Date | null;
|
|
33
|
+
/**
|
|
34
|
+
*
|
|
35
|
+
* @type {SubscriptionUsageSummary}
|
|
36
|
+
* @memberof CurrentPeriodUsage
|
|
37
|
+
*/
|
|
38
|
+
usage: SubscriptionUsageSummary;
|
|
39
|
+
/**
|
|
40
|
+
*
|
|
41
|
+
* @type {Array<UsageBreakdownByDay>}
|
|
42
|
+
* @memberof CurrentPeriodUsage
|
|
43
|
+
*/
|
|
44
|
+
byDay: Array<UsageBreakdownByDay>;
|
|
45
|
+
/**
|
|
46
|
+
*
|
|
47
|
+
* @type {Array<UsageBreakdownByAgent>}
|
|
48
|
+
* @memberof CurrentPeriodUsage
|
|
49
|
+
*/
|
|
50
|
+
byAgent: Array<UsageBreakdownByAgent>;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Check if a given object implements the CurrentPeriodUsage interface.
|
|
54
|
+
*/
|
|
55
|
+
export declare function instanceOfCurrentPeriodUsage(value: object): value is CurrentPeriodUsage;
|
|
56
|
+
export declare function CurrentPeriodUsageFromJSON(json: any): CurrentPeriodUsage;
|
|
57
|
+
export declare function CurrentPeriodUsageFromJSONTyped(json: any, ignoreDiscriminator: boolean): CurrentPeriodUsage;
|
|
58
|
+
export declare function CurrentPeriodUsageToJSON(json: any): CurrentPeriodUsage;
|
|
59
|
+
export declare function CurrentPeriodUsageToJSONTyped(value?: CurrentPeriodUsage | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Tivadar AI Backend API
|
|
5
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
import { UsageBreakdownByDayFromJSON, UsageBreakdownByDayToJSON, } from './UsageBreakdownByDay';
|
|
15
|
+
import { SubscriptionUsageSummaryFromJSON, SubscriptionUsageSummaryToJSON, } from './SubscriptionUsageSummary';
|
|
16
|
+
import { UsageBreakdownByAgentFromJSON, UsageBreakdownByAgentToJSON, } from './UsageBreakdownByAgent';
|
|
17
|
+
/**
|
|
18
|
+
* Check if a given object implements the CurrentPeriodUsage interface.
|
|
19
|
+
*/
|
|
20
|
+
export function instanceOfCurrentPeriodUsage(value) {
|
|
21
|
+
if (!('periodStart' in value) || value['periodStart'] === undefined)
|
|
22
|
+
return false;
|
|
23
|
+
if (!('periodEnd' in value) || value['periodEnd'] === undefined)
|
|
24
|
+
return false;
|
|
25
|
+
if (!('usage' in value) || value['usage'] === undefined)
|
|
26
|
+
return false;
|
|
27
|
+
if (!('byDay' in value) || value['byDay'] === undefined)
|
|
28
|
+
return false;
|
|
29
|
+
if (!('byAgent' in value) || value['byAgent'] === undefined)
|
|
30
|
+
return false;
|
|
31
|
+
return true;
|
|
32
|
+
}
|
|
33
|
+
export function CurrentPeriodUsageFromJSON(json) {
|
|
34
|
+
return CurrentPeriodUsageFromJSONTyped(json, false);
|
|
35
|
+
}
|
|
36
|
+
export function CurrentPeriodUsageFromJSONTyped(json, ignoreDiscriminator) {
|
|
37
|
+
if (json == null) {
|
|
38
|
+
return json;
|
|
39
|
+
}
|
|
40
|
+
return {
|
|
41
|
+
'periodStart': (json['periodStart'] == null ? null : new Date(json['periodStart'])),
|
|
42
|
+
'periodEnd': (json['periodEnd'] == null ? null : new Date(json['periodEnd'])),
|
|
43
|
+
'usage': SubscriptionUsageSummaryFromJSON(json['usage']),
|
|
44
|
+
'byDay': (json['byDay'].map(UsageBreakdownByDayFromJSON)),
|
|
45
|
+
'byAgent': (json['byAgent'].map(UsageBreakdownByAgentFromJSON)),
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
export function CurrentPeriodUsageToJSON(json) {
|
|
49
|
+
return CurrentPeriodUsageToJSONTyped(json, false);
|
|
50
|
+
}
|
|
51
|
+
export function CurrentPeriodUsageToJSONTyped(value, ignoreDiscriminator = false) {
|
|
52
|
+
if (value == null) {
|
|
53
|
+
return value;
|
|
54
|
+
}
|
|
55
|
+
return {
|
|
56
|
+
'periodStart': value['periodStart'] == null ? value['periodStart'] : value['periodStart'].toISOString(),
|
|
57
|
+
'periodEnd': value['periodEnd'] == null ? value['periodEnd'] : value['periodEnd'].toISOString(),
|
|
58
|
+
'usage': SubscriptionUsageSummaryToJSON(value['usage']),
|
|
59
|
+
'byDay': (value['byDay'].map(UsageBreakdownByDayToJSON)),
|
|
60
|
+
'byAgent': (value['byAgent'].map(UsageBreakdownByAgentToJSON)),
|
|
61
|
+
};
|
|
62
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tivadar AI Backend API
|
|
3
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface LifecycleResponse
|
|
16
|
+
*/
|
|
17
|
+
export interface LifecycleResponse {
|
|
18
|
+
/**
|
|
19
|
+
*
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof LifecycleResponse
|
|
22
|
+
*/
|
|
23
|
+
subscriptionId: string;
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @type {string}
|
|
27
|
+
* @memberof LifecycleResponse
|
|
28
|
+
*/
|
|
29
|
+
status: string;
|
|
30
|
+
/**
|
|
31
|
+
*
|
|
32
|
+
* @type {boolean}
|
|
33
|
+
* @memberof LifecycleResponse
|
|
34
|
+
*/
|
|
35
|
+
cancelAtPeriodEnd?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
*
|
|
38
|
+
* @type {Date}
|
|
39
|
+
* @memberof LifecycleResponse
|
|
40
|
+
*/
|
|
41
|
+
currentPeriodEnd?: Date | null;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* Check if a given object implements the LifecycleResponse interface.
|
|
45
|
+
*/
|
|
46
|
+
export declare function instanceOfLifecycleResponse(value: object): value is LifecycleResponse;
|
|
47
|
+
export declare function LifecycleResponseFromJSON(json: any): LifecycleResponse;
|
|
48
|
+
export declare function LifecycleResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): LifecycleResponse;
|
|
49
|
+
export declare function LifecycleResponseToJSON(json: any): LifecycleResponse;
|
|
50
|
+
export declare function LifecycleResponseToJSONTyped(value?: LifecycleResponse | null, ignoreDiscriminator?: boolean): any;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Tivadar AI Backend API
|
|
5
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
/**
|
|
15
|
+
* Check if a given object implements the LifecycleResponse interface.
|
|
16
|
+
*/
|
|
17
|
+
export function instanceOfLifecycleResponse(value) {
|
|
18
|
+
if (!('subscriptionId' in value) || value['subscriptionId'] === undefined)
|
|
19
|
+
return false;
|
|
20
|
+
if (!('status' in value) || value['status'] === undefined)
|
|
21
|
+
return false;
|
|
22
|
+
return true;
|
|
23
|
+
}
|
|
24
|
+
export function LifecycleResponseFromJSON(json) {
|
|
25
|
+
return LifecycleResponseFromJSONTyped(json, false);
|
|
26
|
+
}
|
|
27
|
+
export function LifecycleResponseFromJSONTyped(json, ignoreDiscriminator) {
|
|
28
|
+
if (json == null) {
|
|
29
|
+
return json;
|
|
30
|
+
}
|
|
31
|
+
return {
|
|
32
|
+
'subscriptionId': json['subscriptionId'],
|
|
33
|
+
'status': json['status'],
|
|
34
|
+
'cancelAtPeriodEnd': json['cancelAtPeriodEnd'] == null ? undefined : json['cancelAtPeriodEnd'],
|
|
35
|
+
'currentPeriodEnd': json['currentPeriodEnd'] == null ? undefined : (new Date(json['currentPeriodEnd'])),
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
export function LifecycleResponseToJSON(json) {
|
|
39
|
+
return LifecycleResponseToJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
export function LifecycleResponseToJSONTyped(value, ignoreDiscriminator = false) {
|
|
42
|
+
if (value == null) {
|
|
43
|
+
return value;
|
|
44
|
+
}
|
|
45
|
+
return {
|
|
46
|
+
'subscriptionId': value['subscriptionId'],
|
|
47
|
+
'status': value['status'],
|
|
48
|
+
'cancelAtPeriodEnd': value['cancelAtPeriodEnd'],
|
|
49
|
+
'currentPeriodEnd': value['currentPeriodEnd'] == null ? value['currentPeriodEnd'] : value['currentPeriodEnd'].toISOString(),
|
|
50
|
+
};
|
|
51
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Tivadar AI Backend API
|
|
3
|
+
* Unified REST API for Tivadar AI Voice Agents platform
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { PlanCatalogPrice } from './PlanCatalogPrice';
|
|
13
|
+
import type { PlanCatalogEntryOverageInner } from './PlanCatalogEntryOverageInner';
|
|
14
|
+
/**
|
|
15
|
+
*
|
|
16
|
+
* @export
|
|
17
|
+
* @interface PlanCatalogEntry
|
|
18
|
+
*/
|
|
19
|
+
export interface PlanCatalogEntry {
|
|
20
|
+
/**
|
|
21
|
+
*
|
|
22
|
+
* @type {string}
|
|
23
|
+
* @memberof PlanCatalogEntry
|
|
24
|
+
*/
|
|
25
|
+
slug: string;
|
|
26
|
+
/**
|
|
27
|
+
*
|
|
28
|
+
* @type {string}
|
|
29
|
+
* @memberof PlanCatalogEntry
|
|
30
|
+
*/
|
|
31
|
+
name: string;
|
|
32
|
+
/**
|
|
33
|
+
*
|
|
34
|
+
* @type {string}
|
|
35
|
+
* @memberof PlanCatalogEntry
|
|
36
|
+
*/
|
|
37
|
+
description?: string;
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @type {number}
|
|
41
|
+
* @memberof PlanCatalogEntry
|
|
42
|
+
*/
|
|
43
|
+
rank: number;
|
|
44
|
+
/**
|
|
45
|
+
*
|
|
46
|
+
* @type {boolean}
|
|
47
|
+
* @memberof PlanCatalogEntry
|
|
48
|
+
*/
|
|
49
|
+
hasStripeProduct?: boolean;
|
|
50
|
+
/**
|
|
51
|
+
*
|
|
52
|
+
* @type {number}
|
|
53
|
+
* @memberof PlanCatalogEntry
|
|
54
|
+
*/
|
|
55
|
+
includedVoiceMinutes: number;
|
|
56
|
+
/**
|
|
57
|
+
*
|
|
58
|
+
* @type {Array<string>}
|
|
59
|
+
* @memberof PlanCatalogEntry
|
|
60
|
+
*/
|
|
61
|
+
features?: Array<string>;
|
|
62
|
+
/**
|
|
63
|
+
*
|
|
64
|
+
* @type {{ [key: string]: number | null; }}
|
|
65
|
+
* @memberof PlanCatalogEntry
|
|
66
|
+
*/
|
|
67
|
+
limits?: {
|
|
68
|
+
[key: string]: number | null;
|
|
69
|
+
};
|
|
70
|
+
/**
|
|
71
|
+
*
|
|
72
|
+
* @type {Array<PlanCatalogPrice>}
|
|
73
|
+
* @memberof PlanCatalogEntry
|
|
74
|
+
*/
|
|
75
|
+
prices: Array<PlanCatalogPrice>;
|
|
76
|
+
/**
|
|
77
|
+
*
|
|
78
|
+
* @type {Array<PlanCatalogEntryOverageInner>}
|
|
79
|
+
* @memberof PlanCatalogEntry
|
|
80
|
+
*/
|
|
81
|
+
overage: Array<PlanCatalogEntryOverageInner>;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Check if a given object implements the PlanCatalogEntry interface.
|
|
85
|
+
*/
|
|
86
|
+
export declare function instanceOfPlanCatalogEntry(value: object): value is PlanCatalogEntry;
|
|
87
|
+
export declare function PlanCatalogEntryFromJSON(json: any): PlanCatalogEntry;
|
|
88
|
+
export declare function PlanCatalogEntryFromJSONTyped(json: any, ignoreDiscriminator: boolean): PlanCatalogEntry;
|
|
89
|
+
export declare function PlanCatalogEntryToJSON(json: any): PlanCatalogEntry;
|
|
90
|
+
export declare function PlanCatalogEntryToJSONTyped(value?: PlanCatalogEntry | null, ignoreDiscriminator?: boolean): any;
|