@l7mp/tivadar-ai-api-sdk 0.2.9 → 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.
Files changed (146) hide show
  1. package/dist/api-client.d.ts +29 -4
  2. package/dist/api-client.js +22 -3
  3. package/dist/apis/AdminSubscriptionsApi.d.ts +82 -0
  4. package/dist/apis/AdminSubscriptionsApi.js +242 -0
  5. package/dist/apis/SubscriptionApi.d.ts +54 -75
  6. package/dist/apis/SubscriptionApi.js +95 -114
  7. package/dist/apis/VoiceUsageApi.d.ts +31 -0
  8. package/dist/apis/VoiceUsageApi.js +73 -0
  9. package/dist/apis/index.d.ts +2 -0
  10. package/dist/apis/index.js +2 -0
  11. package/dist/esm/api-client.d.ts +29 -4
  12. package/dist/esm/api-client.js +22 -3
  13. package/dist/esm/apis/AdminSubscriptionsApi.d.ts +82 -0
  14. package/dist/esm/apis/AdminSubscriptionsApi.js +238 -0
  15. package/dist/esm/apis/SubscriptionApi.d.ts +54 -75
  16. package/dist/esm/apis/SubscriptionApi.js +96 -115
  17. package/dist/esm/apis/VoiceUsageApi.d.ts +31 -0
  18. package/dist/esm/apis/VoiceUsageApi.js +69 -0
  19. package/dist/esm/apis/index.d.ts +2 -0
  20. package/dist/esm/apis/index.js +2 -0
  21. package/dist/esm/models/AdminGrantMinutesRequest.d.ts +38 -0
  22. package/dist/esm/models/AdminGrantMinutesRequest.js +45 -0
  23. package/dist/esm/models/AdminSetSubscriptionRequest.d.ts +86 -0
  24. package/dist/esm/models/AdminSetSubscriptionRequest.js +71 -0
  25. package/dist/esm/models/BillingPortalRequest.d.ts +1 -1
  26. package/dist/esm/models/BillingPortalResponse.d.ts +1 -1
  27. package/dist/esm/models/CancelSubscriptionRequest.d.ts +2 -2
  28. package/dist/esm/models/CheckoutSessionResponse.d.ts +2 -2
  29. package/dist/esm/models/CreateCheckoutSessionRequest.d.ts +21 -7
  30. package/dist/esm/models/CreateCheckoutSessionRequest.js +18 -5
  31. package/dist/esm/models/CurrentPeriodUsage.d.ts +59 -0
  32. package/dist/esm/models/CurrentPeriodUsage.js +62 -0
  33. package/dist/esm/models/LifecycleResponse.d.ts +50 -0
  34. package/dist/esm/models/LifecycleResponse.js +51 -0
  35. package/dist/esm/models/PauseSubscriptionRequest.d.ts +1 -1
  36. package/dist/esm/models/PlanCatalogEntry.d.ts +90 -0
  37. package/dist/esm/models/PlanCatalogEntry.js +73 -0
  38. package/dist/esm/models/PlanCatalogEntryOverageInner.d.ts +44 -0
  39. package/dist/esm/models/PlanCatalogEntryOverageInner.js +45 -0
  40. package/dist/esm/models/PlanCatalogPrice.d.ts +58 -0
  41. package/dist/esm/models/PlanCatalogPrice.js +60 -0
  42. package/dist/esm/models/SubscriptionPlanSummary.d.ts +83 -0
  43. package/dist/esm/models/SubscriptionPlanSummary.js +70 -0
  44. package/dist/esm/models/SubscriptionPlanSummaryOverageRate.d.ts +38 -0
  45. package/dist/esm/models/SubscriptionPlanSummaryOverageRate.js +43 -0
  46. package/dist/esm/models/SubscriptionStatus.d.ts +103 -10
  47. package/dist/esm/models/SubscriptionStatus.js +58 -9
  48. package/dist/esm/models/SubscriptionUsageSummary.d.ts +56 -0
  49. package/dist/esm/models/SubscriptionUsageSummary.js +57 -0
  50. package/dist/esm/models/UpdatePlanRequest.d.ts +13 -5
  51. package/dist/esm/models/UpdatePlanRequest.js +12 -3
  52. package/dist/esm/models/UsageBreakdownByAgent.d.ts +44 -0
  53. package/dist/esm/models/UsageBreakdownByAgent.js +49 -0
  54. package/dist/esm/models/UsageBreakdownByDay.d.ts +44 -0
  55. package/dist/esm/models/UsageBreakdownByDay.js +51 -0
  56. package/dist/esm/models/UsageHistoryResponse.d.ts +39 -0
  57. package/dist/esm/models/UsageHistoryResponse.js +48 -0
  58. package/dist/esm/models/UsageRecordDto.d.ts +80 -0
  59. package/dist/esm/models/UsageRecordDto.js +65 -0
  60. package/dist/esm/models/VoiceAgentMetadata.d.ts +6 -0
  61. package/dist/esm/models/VoiceAgentMetadata.js +2 -0
  62. package/dist/esm/models/VoiceUsageReportRequest.d.ts +62 -0
  63. package/dist/esm/models/VoiceUsageReportRequest.js +57 -0
  64. package/dist/esm/models/VoiceUsageReportResponse.d.ts +51 -0
  65. package/dist/esm/models/VoiceUsageReportResponse.js +52 -0
  66. package/dist/esm/models/index.d.ts +16 -13
  67. package/dist/esm/models/index.js +16 -13
  68. package/dist/models/AdminGrantMinutesRequest.d.ts +38 -0
  69. package/dist/models/AdminGrantMinutesRequest.js +52 -0
  70. package/dist/models/AdminSetSubscriptionRequest.d.ts +86 -0
  71. package/dist/models/AdminSetSubscriptionRequest.js +79 -0
  72. package/dist/models/BillingPortalRequest.d.ts +1 -1
  73. package/dist/models/BillingPortalResponse.d.ts +1 -1
  74. package/dist/models/CancelSubscriptionRequest.d.ts +2 -2
  75. package/dist/models/CheckoutSessionResponse.d.ts +2 -2
  76. package/dist/models/CreateCheckoutSessionRequest.d.ts +21 -7
  77. package/dist/models/CreateCheckoutSessionRequest.js +19 -5
  78. package/dist/models/CurrentPeriodUsage.d.ts +59 -0
  79. package/dist/models/CurrentPeriodUsage.js +69 -0
  80. package/dist/models/LifecycleResponse.d.ts +50 -0
  81. package/dist/models/LifecycleResponse.js +58 -0
  82. package/dist/models/PauseSubscriptionRequest.d.ts +1 -1
  83. package/dist/models/PlanCatalogEntry.d.ts +90 -0
  84. package/dist/models/PlanCatalogEntry.js +80 -0
  85. package/dist/models/PlanCatalogEntryOverageInner.d.ts +44 -0
  86. package/dist/models/PlanCatalogEntryOverageInner.js +52 -0
  87. package/dist/models/PlanCatalogPrice.d.ts +58 -0
  88. package/dist/models/PlanCatalogPrice.js +68 -0
  89. package/dist/models/SubscriptionPlanSummary.d.ts +83 -0
  90. package/dist/models/SubscriptionPlanSummary.js +77 -0
  91. package/dist/models/SubscriptionPlanSummaryOverageRate.d.ts +38 -0
  92. package/dist/models/SubscriptionPlanSummaryOverageRate.js +50 -0
  93. package/dist/models/SubscriptionStatus.d.ts +103 -10
  94. package/dist/models/SubscriptionStatus.js +59 -9
  95. package/dist/models/SubscriptionUsageSummary.d.ts +56 -0
  96. package/dist/models/SubscriptionUsageSummary.js +64 -0
  97. package/dist/models/UpdatePlanRequest.d.ts +13 -5
  98. package/dist/models/UpdatePlanRequest.js +13 -3
  99. package/dist/models/UsageBreakdownByAgent.d.ts +44 -0
  100. package/dist/models/UsageBreakdownByAgent.js +56 -0
  101. package/dist/models/UsageBreakdownByDay.d.ts +44 -0
  102. package/dist/models/UsageBreakdownByDay.js +58 -0
  103. package/dist/models/UsageHistoryResponse.d.ts +39 -0
  104. package/dist/models/UsageHistoryResponse.js +55 -0
  105. package/dist/models/UsageRecordDto.d.ts +80 -0
  106. package/dist/models/UsageRecordDto.js +72 -0
  107. package/dist/models/VoiceAgentMetadata.d.ts +6 -0
  108. package/dist/models/VoiceAgentMetadata.js +2 -0
  109. package/dist/models/VoiceUsageReportRequest.d.ts +62 -0
  110. package/dist/models/VoiceUsageReportRequest.js +64 -0
  111. package/dist/models/VoiceUsageReportResponse.d.ts +51 -0
  112. package/dist/models/VoiceUsageReportResponse.js +59 -0
  113. package/dist/models/index.d.ts +16 -13
  114. package/dist/models/index.js +16 -13
  115. package/package.json +1 -1
  116. package/src/api-client.ts +42 -6
  117. package/src/apis/AdminSubscriptionsApi.ts +327 -0
  118. package/src/apis/SubscriptionApi.ts +130 -162
  119. package/src/apis/VoiceUsageApi.ts +86 -0
  120. package/src/apis/index.ts +2 -0
  121. package/src/models/AdminGrantMinutesRequest.ts +74 -0
  122. package/src/models/AdminSetSubscriptionRequest.ts +136 -0
  123. package/src/models/BillingPortalRequest.ts +1 -1
  124. package/src/models/BillingPortalResponse.ts +1 -1
  125. package/src/models/CancelSubscriptionRequest.ts +2 -2
  126. package/src/models/CheckoutSessionResponse.ts +2 -2
  127. package/src/models/CreateCheckoutSessionRequest.ts +33 -12
  128. package/src/models/CurrentPeriodUsage.ts +124 -0
  129. package/src/models/LifecycleResponse.ts +91 -0
  130. package/src/models/PauseSubscriptionRequest.ts +1 -1
  131. package/src/models/PlanCatalogEntry.ts +158 -0
  132. package/src/models/PlanCatalogEntryOverageInner.ts +81 -0
  133. package/src/models/PlanCatalogPrice.ts +103 -0
  134. package/src/models/SubscriptionPlanSummary.ts +143 -0
  135. package/src/models/SubscriptionPlanSummaryOverageRate.ts +73 -0
  136. package/src/models/SubscriptionStatus.ts +150 -32
  137. package/src/models/SubscriptionUsageSummary.ts +101 -0
  138. package/src/models/UpdatePlanRequest.ts +20 -8
  139. package/src/models/UsageBreakdownByAgent.ts +83 -0
  140. package/src/models/UsageBreakdownByDay.ts +84 -0
  141. package/src/models/UsageHistoryResponse.ts +83 -0
  142. package/src/models/UsageRecordDto.ts +133 -0
  143. package/src/models/VoiceAgentMetadata.ts +8 -0
  144. package/src/models/VoiceUsageReportRequest.ts +108 -0
  145. package/src/models/VoiceUsageReportResponse.ts +99 -0
  146. package/src/models/index.ts +16 -13
@@ -0,0 +1,80 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Tivadar AI Backend API
6
+ * Unified REST API for Tivadar AI Voice Agents platform
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfPlanCatalogEntry = instanceOfPlanCatalogEntry;
17
+ exports.PlanCatalogEntryFromJSON = PlanCatalogEntryFromJSON;
18
+ exports.PlanCatalogEntryFromJSONTyped = PlanCatalogEntryFromJSONTyped;
19
+ exports.PlanCatalogEntryToJSON = PlanCatalogEntryToJSON;
20
+ exports.PlanCatalogEntryToJSONTyped = PlanCatalogEntryToJSONTyped;
21
+ const PlanCatalogPrice_1 = require("./PlanCatalogPrice");
22
+ const PlanCatalogEntryOverageInner_1 = require("./PlanCatalogEntryOverageInner");
23
+ /**
24
+ * Check if a given object implements the PlanCatalogEntry interface.
25
+ */
26
+ function instanceOfPlanCatalogEntry(value) {
27
+ if (!('slug' in value) || value['slug'] === undefined)
28
+ return false;
29
+ if (!('name' in value) || value['name'] === undefined)
30
+ return false;
31
+ if (!('rank' in value) || value['rank'] === undefined)
32
+ return false;
33
+ if (!('includedVoiceMinutes' in value) || value['includedVoiceMinutes'] === undefined)
34
+ return false;
35
+ if (!('prices' in value) || value['prices'] === undefined)
36
+ return false;
37
+ if (!('overage' in value) || value['overage'] === undefined)
38
+ return false;
39
+ return true;
40
+ }
41
+ function PlanCatalogEntryFromJSON(json) {
42
+ return PlanCatalogEntryFromJSONTyped(json, false);
43
+ }
44
+ function PlanCatalogEntryFromJSONTyped(json, ignoreDiscriminator) {
45
+ if (json == null) {
46
+ return json;
47
+ }
48
+ return {
49
+ 'slug': json['slug'],
50
+ 'name': json['name'],
51
+ 'description': json['description'] == null ? undefined : json['description'],
52
+ 'rank': json['rank'],
53
+ 'hasStripeProduct': json['hasStripeProduct'] == null ? undefined : json['hasStripeProduct'],
54
+ 'includedVoiceMinutes': json['includedVoiceMinutes'],
55
+ 'features': json['features'] == null ? undefined : json['features'],
56
+ 'limits': json['limits'] == null ? undefined : json['limits'],
57
+ 'prices': (json['prices'].map(PlanCatalogPrice_1.PlanCatalogPriceFromJSON)),
58
+ 'overage': (json['overage'].map(PlanCatalogEntryOverageInner_1.PlanCatalogEntryOverageInnerFromJSON)),
59
+ };
60
+ }
61
+ function PlanCatalogEntryToJSON(json) {
62
+ return PlanCatalogEntryToJSONTyped(json, false);
63
+ }
64
+ function PlanCatalogEntryToJSONTyped(value, ignoreDiscriminator = false) {
65
+ if (value == null) {
66
+ return value;
67
+ }
68
+ return {
69
+ 'slug': value['slug'],
70
+ 'name': value['name'],
71
+ 'description': value['description'],
72
+ 'rank': value['rank'],
73
+ 'hasStripeProduct': value['hasStripeProduct'],
74
+ 'includedVoiceMinutes': value['includedVoiceMinutes'],
75
+ 'features': value['features'],
76
+ 'limits': value['limits'],
77
+ 'prices': (value['prices'].map(PlanCatalogPrice_1.PlanCatalogPriceToJSON)),
78
+ 'overage': (value['overage'].map(PlanCatalogEntryOverageInner_1.PlanCatalogEntryOverageInnerToJSON)),
79
+ };
80
+ }
@@ -0,0 +1,44 @@
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 PlanCatalogEntryOverageInner
16
+ */
17
+ export interface PlanCatalogEntryOverageInner {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof PlanCatalogEntryOverageInner
22
+ */
23
+ currency?: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof PlanCatalogEntryOverageInner
28
+ */
29
+ priceId?: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof PlanCatalogEntryOverageInner
34
+ */
35
+ unitAmountDecimal?: string | null;
36
+ }
37
+ /**
38
+ * Check if a given object implements the PlanCatalogEntryOverageInner interface.
39
+ */
40
+ export declare function instanceOfPlanCatalogEntryOverageInner(value: object): value is PlanCatalogEntryOverageInner;
41
+ export declare function PlanCatalogEntryOverageInnerFromJSON(json: any): PlanCatalogEntryOverageInner;
42
+ export declare function PlanCatalogEntryOverageInnerFromJSONTyped(json: any, ignoreDiscriminator: boolean): PlanCatalogEntryOverageInner;
43
+ export declare function PlanCatalogEntryOverageInnerToJSON(json: any): PlanCatalogEntryOverageInner;
44
+ export declare function PlanCatalogEntryOverageInnerToJSONTyped(value?: PlanCatalogEntryOverageInner | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,52 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Tivadar AI Backend API
6
+ * Unified REST API for Tivadar AI Voice Agents platform
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfPlanCatalogEntryOverageInner = instanceOfPlanCatalogEntryOverageInner;
17
+ exports.PlanCatalogEntryOverageInnerFromJSON = PlanCatalogEntryOverageInnerFromJSON;
18
+ exports.PlanCatalogEntryOverageInnerFromJSONTyped = PlanCatalogEntryOverageInnerFromJSONTyped;
19
+ exports.PlanCatalogEntryOverageInnerToJSON = PlanCatalogEntryOverageInnerToJSON;
20
+ exports.PlanCatalogEntryOverageInnerToJSONTyped = PlanCatalogEntryOverageInnerToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the PlanCatalogEntryOverageInner interface.
23
+ */
24
+ function instanceOfPlanCatalogEntryOverageInner(value) {
25
+ return true;
26
+ }
27
+ function PlanCatalogEntryOverageInnerFromJSON(json) {
28
+ return PlanCatalogEntryOverageInnerFromJSONTyped(json, false);
29
+ }
30
+ function PlanCatalogEntryOverageInnerFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'currency': json['currency'] == null ? undefined : json['currency'],
36
+ 'priceId': json['priceId'] == null ? undefined : json['priceId'],
37
+ 'unitAmountDecimal': json['unitAmountDecimal'] == null ? undefined : json['unitAmountDecimal'],
38
+ };
39
+ }
40
+ function PlanCatalogEntryOverageInnerToJSON(json) {
41
+ return PlanCatalogEntryOverageInnerToJSONTyped(json, false);
42
+ }
43
+ function PlanCatalogEntryOverageInnerToJSONTyped(value, ignoreDiscriminator = false) {
44
+ if (value == null) {
45
+ return value;
46
+ }
47
+ return {
48
+ 'currency': value['currency'],
49
+ 'priceId': value['priceId'],
50
+ 'unitAmountDecimal': value['unitAmountDecimal'],
51
+ };
52
+ }
@@ -0,0 +1,58 @@
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 PlanCatalogPrice
16
+ */
17
+ export interface PlanCatalogPrice {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof PlanCatalogPrice
22
+ */
23
+ interval: PlanCatalogPriceIntervalEnum;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof PlanCatalogPrice
28
+ */
29
+ currency: string;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof PlanCatalogPrice
34
+ */
35
+ priceId: string;
36
+ /**
37
+ *
38
+ * @type {number}
39
+ * @memberof PlanCatalogPrice
40
+ */
41
+ unitAmount?: number | null;
42
+ }
43
+ /**
44
+ * @export
45
+ */
46
+ export declare const PlanCatalogPriceIntervalEnum: {
47
+ readonly Monthly: "monthly";
48
+ readonly Yearly: "yearly";
49
+ };
50
+ export type PlanCatalogPriceIntervalEnum = typeof PlanCatalogPriceIntervalEnum[keyof typeof PlanCatalogPriceIntervalEnum];
51
+ /**
52
+ * Check if a given object implements the PlanCatalogPrice interface.
53
+ */
54
+ export declare function instanceOfPlanCatalogPrice(value: object): value is PlanCatalogPrice;
55
+ export declare function PlanCatalogPriceFromJSON(json: any): PlanCatalogPrice;
56
+ export declare function PlanCatalogPriceFromJSONTyped(json: any, ignoreDiscriminator: boolean): PlanCatalogPrice;
57
+ export declare function PlanCatalogPriceToJSON(json: any): PlanCatalogPrice;
58
+ export declare function PlanCatalogPriceToJSONTyped(value?: PlanCatalogPrice | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,68 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Tivadar AI Backend API
6
+ * Unified REST API for Tivadar AI Voice Agents platform
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.PlanCatalogPriceIntervalEnum = void 0;
17
+ exports.instanceOfPlanCatalogPrice = instanceOfPlanCatalogPrice;
18
+ exports.PlanCatalogPriceFromJSON = PlanCatalogPriceFromJSON;
19
+ exports.PlanCatalogPriceFromJSONTyped = PlanCatalogPriceFromJSONTyped;
20
+ exports.PlanCatalogPriceToJSON = PlanCatalogPriceToJSON;
21
+ exports.PlanCatalogPriceToJSONTyped = PlanCatalogPriceToJSONTyped;
22
+ /**
23
+ * @export
24
+ */
25
+ exports.PlanCatalogPriceIntervalEnum = {
26
+ Monthly: 'monthly',
27
+ Yearly: 'yearly'
28
+ };
29
+ /**
30
+ * Check if a given object implements the PlanCatalogPrice interface.
31
+ */
32
+ function instanceOfPlanCatalogPrice(value) {
33
+ if (!('interval' in value) || value['interval'] === undefined)
34
+ return false;
35
+ if (!('currency' in value) || value['currency'] === undefined)
36
+ return false;
37
+ if (!('priceId' in value) || value['priceId'] === undefined)
38
+ return false;
39
+ return true;
40
+ }
41
+ function PlanCatalogPriceFromJSON(json) {
42
+ return PlanCatalogPriceFromJSONTyped(json, false);
43
+ }
44
+ function PlanCatalogPriceFromJSONTyped(json, ignoreDiscriminator) {
45
+ if (json == null) {
46
+ return json;
47
+ }
48
+ return {
49
+ 'interval': json['interval'],
50
+ 'currency': json['currency'],
51
+ 'priceId': json['priceId'],
52
+ 'unitAmount': json['unitAmount'] == null ? undefined : json['unitAmount'],
53
+ };
54
+ }
55
+ function PlanCatalogPriceToJSON(json) {
56
+ return PlanCatalogPriceToJSONTyped(json, false);
57
+ }
58
+ function PlanCatalogPriceToJSONTyped(value, ignoreDiscriminator = false) {
59
+ if (value == null) {
60
+ return value;
61
+ }
62
+ return {
63
+ 'interval': value['interval'],
64
+ 'currency': value['currency'],
65
+ 'priceId': value['priceId'],
66
+ 'unitAmount': value['unitAmount'],
67
+ };
68
+ }
@@ -0,0 +1,83 @@
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 { SubscriptionPlanSummaryOverageRate } from './SubscriptionPlanSummaryOverageRate';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface SubscriptionPlanSummary
17
+ */
18
+ export interface SubscriptionPlanSummary {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof SubscriptionPlanSummary
23
+ */
24
+ slug: string;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof SubscriptionPlanSummary
29
+ */
30
+ name: string;
31
+ /**
32
+ *
33
+ * @type {string}
34
+ * @memberof SubscriptionPlanSummary
35
+ */
36
+ description?: string;
37
+ /**
38
+ *
39
+ * @type {number}
40
+ * @memberof SubscriptionPlanSummary
41
+ */
42
+ rank: number;
43
+ /**
44
+ *
45
+ * @type {boolean}
46
+ * @memberof SubscriptionPlanSummary
47
+ */
48
+ hasStripeProduct?: boolean;
49
+ /**
50
+ * Voice minutes included per billing period before overage.
51
+ * @type {number}
52
+ * @memberof SubscriptionPlanSummary
53
+ */
54
+ includedVoiceMinutes: number;
55
+ /**
56
+ *
57
+ * @type {Array<string>}
58
+ * @memberof SubscriptionPlanSummary
59
+ */
60
+ features: Array<string>;
61
+ /**
62
+ *
63
+ * @type {{ [key: string]: number | null; }}
64
+ * @memberof SubscriptionPlanSummary
65
+ */
66
+ limits: {
67
+ [key: string]: number | null;
68
+ };
69
+ /**
70
+ *
71
+ * @type {SubscriptionPlanSummaryOverageRate}
72
+ * @memberof SubscriptionPlanSummary
73
+ */
74
+ overageRate?: SubscriptionPlanSummaryOverageRate | null;
75
+ }
76
+ /**
77
+ * Check if a given object implements the SubscriptionPlanSummary interface.
78
+ */
79
+ export declare function instanceOfSubscriptionPlanSummary(value: object): value is SubscriptionPlanSummary;
80
+ export declare function SubscriptionPlanSummaryFromJSON(json: any): SubscriptionPlanSummary;
81
+ export declare function SubscriptionPlanSummaryFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubscriptionPlanSummary;
82
+ export declare function SubscriptionPlanSummaryToJSON(json: any): SubscriptionPlanSummary;
83
+ export declare function SubscriptionPlanSummaryToJSONTyped(value?: SubscriptionPlanSummary | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,77 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Tivadar AI Backend API
6
+ * Unified REST API for Tivadar AI Voice Agents platform
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfSubscriptionPlanSummary = instanceOfSubscriptionPlanSummary;
17
+ exports.SubscriptionPlanSummaryFromJSON = SubscriptionPlanSummaryFromJSON;
18
+ exports.SubscriptionPlanSummaryFromJSONTyped = SubscriptionPlanSummaryFromJSONTyped;
19
+ exports.SubscriptionPlanSummaryToJSON = SubscriptionPlanSummaryToJSON;
20
+ exports.SubscriptionPlanSummaryToJSONTyped = SubscriptionPlanSummaryToJSONTyped;
21
+ const SubscriptionPlanSummaryOverageRate_1 = require("./SubscriptionPlanSummaryOverageRate");
22
+ /**
23
+ * Check if a given object implements the SubscriptionPlanSummary interface.
24
+ */
25
+ function instanceOfSubscriptionPlanSummary(value) {
26
+ if (!('slug' in value) || value['slug'] === undefined)
27
+ return false;
28
+ if (!('name' in value) || value['name'] === undefined)
29
+ return false;
30
+ if (!('rank' in value) || value['rank'] === undefined)
31
+ return false;
32
+ if (!('includedVoiceMinutes' in value) || value['includedVoiceMinutes'] === undefined)
33
+ return false;
34
+ if (!('features' in value) || value['features'] === undefined)
35
+ return false;
36
+ if (!('limits' in value) || value['limits'] === undefined)
37
+ return false;
38
+ return true;
39
+ }
40
+ function SubscriptionPlanSummaryFromJSON(json) {
41
+ return SubscriptionPlanSummaryFromJSONTyped(json, false);
42
+ }
43
+ function SubscriptionPlanSummaryFromJSONTyped(json, ignoreDiscriminator) {
44
+ if (json == null) {
45
+ return json;
46
+ }
47
+ return {
48
+ 'slug': json['slug'],
49
+ 'name': json['name'],
50
+ 'description': json['description'] == null ? undefined : json['description'],
51
+ 'rank': json['rank'],
52
+ 'hasStripeProduct': json['hasStripeProduct'] == null ? undefined : json['hasStripeProduct'],
53
+ 'includedVoiceMinutes': json['includedVoiceMinutes'],
54
+ 'features': json['features'],
55
+ 'limits': json['limits'],
56
+ 'overageRate': json['overageRate'] == null ? undefined : (0, SubscriptionPlanSummaryOverageRate_1.SubscriptionPlanSummaryOverageRateFromJSON)(json['overageRate']),
57
+ };
58
+ }
59
+ function SubscriptionPlanSummaryToJSON(json) {
60
+ return SubscriptionPlanSummaryToJSONTyped(json, false);
61
+ }
62
+ function SubscriptionPlanSummaryToJSONTyped(value, ignoreDiscriminator = false) {
63
+ if (value == null) {
64
+ return value;
65
+ }
66
+ return {
67
+ 'slug': value['slug'],
68
+ 'name': value['name'],
69
+ 'description': value['description'],
70
+ 'rank': value['rank'],
71
+ 'hasStripeProduct': value['hasStripeProduct'],
72
+ 'includedVoiceMinutes': value['includedVoiceMinutes'],
73
+ 'features': value['features'],
74
+ 'limits': value['limits'],
75
+ 'overageRate': (0, SubscriptionPlanSummaryOverageRate_1.SubscriptionPlanSummaryOverageRateToJSON)(value['overageRate']),
76
+ };
77
+ }
@@ -0,0 +1,38 @@
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 SubscriptionPlanSummaryOverageRate
16
+ */
17
+ export interface SubscriptionPlanSummaryOverageRate {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof SubscriptionPlanSummaryOverageRate
22
+ */
23
+ currency?: string;
24
+ /**
25
+ * Stripe unit amount per metered unit, as a decimal string.
26
+ * @type {string}
27
+ * @memberof SubscriptionPlanSummaryOverageRate
28
+ */
29
+ unitAmountDecimal?: string | null;
30
+ }
31
+ /**
32
+ * Check if a given object implements the SubscriptionPlanSummaryOverageRate interface.
33
+ */
34
+ export declare function instanceOfSubscriptionPlanSummaryOverageRate(value: object): value is SubscriptionPlanSummaryOverageRate;
35
+ export declare function SubscriptionPlanSummaryOverageRateFromJSON(json: any): SubscriptionPlanSummaryOverageRate;
36
+ export declare function SubscriptionPlanSummaryOverageRateFromJSONTyped(json: any, ignoreDiscriminator: boolean): SubscriptionPlanSummaryOverageRate;
37
+ export declare function SubscriptionPlanSummaryOverageRateToJSON(json: any): SubscriptionPlanSummaryOverageRate;
38
+ export declare function SubscriptionPlanSummaryOverageRateToJSONTyped(value?: SubscriptionPlanSummaryOverageRate | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,50 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Tivadar AI Backend API
6
+ * Unified REST API for Tivadar AI Voice Agents platform
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.instanceOfSubscriptionPlanSummaryOverageRate = instanceOfSubscriptionPlanSummaryOverageRate;
17
+ exports.SubscriptionPlanSummaryOverageRateFromJSON = SubscriptionPlanSummaryOverageRateFromJSON;
18
+ exports.SubscriptionPlanSummaryOverageRateFromJSONTyped = SubscriptionPlanSummaryOverageRateFromJSONTyped;
19
+ exports.SubscriptionPlanSummaryOverageRateToJSON = SubscriptionPlanSummaryOverageRateToJSON;
20
+ exports.SubscriptionPlanSummaryOverageRateToJSONTyped = SubscriptionPlanSummaryOverageRateToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the SubscriptionPlanSummaryOverageRate interface.
23
+ */
24
+ function instanceOfSubscriptionPlanSummaryOverageRate(value) {
25
+ return true;
26
+ }
27
+ function SubscriptionPlanSummaryOverageRateFromJSON(json) {
28
+ return SubscriptionPlanSummaryOverageRateFromJSONTyped(json, false);
29
+ }
30
+ function SubscriptionPlanSummaryOverageRateFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'currency': json['currency'] == null ? undefined : json['currency'],
36
+ 'unitAmountDecimal': json['unitAmountDecimal'] == null ? undefined : json['unitAmountDecimal'],
37
+ };
38
+ }
39
+ function SubscriptionPlanSummaryOverageRateToJSON(json) {
40
+ return SubscriptionPlanSummaryOverageRateToJSONTyped(json, false);
41
+ }
42
+ function SubscriptionPlanSummaryOverageRateToJSONTyped(value, ignoreDiscriminator = false) {
43
+ if (value == null) {
44
+ return value;
45
+ }
46
+ return {
47
+ 'currency': value['currency'],
48
+ 'unitAmountDecimal': value['unitAmountDecimal'],
49
+ };
50
+ }