@polar-sh/sdk 0.8.2 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -6
- package/docs/sdks/products/README.md +2 -2
- package/funcs/advertisementsList.js +2 -2
- package/funcs/advertisementsList.js.map +1 -1
- package/funcs/articlesList.js +2 -2
- package/funcs/articlesList.js.map +1 -1
- package/funcs/benefitsGrants.js +2 -2
- package/funcs/benefitsGrants.js.map +1 -1
- package/funcs/benefitsList.js +2 -2
- package/funcs/benefitsList.js.map +1 -1
- package/funcs/externalOrganizationsList.js +2 -2
- package/funcs/externalOrganizationsList.js.map +1 -1
- package/funcs/filesList.js +2 -2
- package/funcs/filesList.js.map +1 -1
- package/funcs/licenseKeysList.js +2 -2
- package/funcs/licenseKeysList.js.map +1 -1
- package/funcs/oauth2ClientsList.js +2 -2
- package/funcs/oauth2ClientsList.js.map +1 -1
- package/funcs/ordersList.js +2 -2
- package/funcs/ordersList.js.map +1 -1
- package/funcs/organizationsList.js +2 -2
- package/funcs/organizationsList.js.map +1 -1
- package/funcs/productsList.js +2 -2
- package/funcs/productsList.js.map +1 -1
- package/funcs/repositoriesList.js +2 -2
- package/funcs/repositoriesList.js.map +1 -1
- package/funcs/subscriptionsList.js +2 -2
- package/funcs/subscriptionsList.js.map +1 -1
- package/funcs/usersAdvertisementsList.js +2 -2
- package/funcs/usersAdvertisementsList.js.map +1 -1
- package/funcs/usersBenefitsList.js +2 -2
- package/funcs/usersBenefitsList.js.map +1 -1
- package/funcs/usersDownloadablesList.js +2 -2
- package/funcs/usersDownloadablesList.js.map +1 -1
- package/funcs/usersLicenseKeysList.js +2 -2
- package/funcs/usersLicenseKeysList.js.map +1 -1
- package/funcs/usersOrdersList.js +2 -2
- package/funcs/usersOrdersList.js.map +1 -1
- package/funcs/usersSubscriptionsList.js +2 -2
- package/funcs/usersSubscriptionsList.js.map +1 -1
- package/lib/config.d.ts +16 -5
- package/lib/config.d.ts.map +1 -1
- package/lib/config.js +18 -12
- package/lib/config.js.map +1 -1
- package/models/components/bodysubscriptionsimport.d.ts +2 -2
- package/models/components/bodysubscriptionsimport.d.ts.map +1 -1
- package/models/components/bodysubscriptionsimport.js +2 -0
- package/models/components/bodysubscriptionsimport.js.map +1 -1
- package/models/components/index.d.ts +9 -3
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +9 -3
- package/models/components/index.js.map +1 -1
- package/models/components/ordersubscription.d.ts +7 -0
- package/models/components/ordersubscription.d.ts.map +1 -1
- package/models/components/ordersubscription.js +9 -0
- package/models/components/ordersubscription.js.map +1 -1
- package/models/components/organizationfeaturesettings.d.ts +0 -5
- package/models/components/organizationfeaturesettings.d.ts.map +1 -1
- package/models/components/organizationfeaturesettings.js +0 -4
- package/models/components/organizationfeaturesettings.js.map +1 -1
- package/models/components/productonetimecreate.d.ts +23 -3
- package/models/components/productonetimecreate.d.ts.map +1 -1
- package/models/components/productonetimecreate.js +33 -4
- package/models/components/productonetimecreate.js.map +1 -1
- package/models/components/productpriceinput.d.ts +3 -11
- package/models/components/productpriceinput.d.ts.map +1 -1
- package/models/components/productpriceinput.js +5 -13
- package/models/components/productpriceinput.js.map +1 -1
- package/models/components/productpriceonetime.d.ts +4 -71
- package/models/components/productpriceonetime.d.ts.map +1 -1
- package/models/components/productpriceonetime.js +11 -57
- package/models/components/productpriceonetime.js.map +1 -1
- package/models/components/productpriceonetimecustom.d.ts +124 -0
- package/models/components/productpriceonetimecustom.d.ts.map +1 -0
- package/models/components/productpriceonetimecustom.js +130 -0
- package/models/components/productpriceonetimecustom.js.map +1 -0
- package/models/components/productpriceonetimecustomcreate.d.ts +71 -0
- package/models/components/productpriceonetimecustomcreate.d.ts.map +1 -0
- package/models/components/productpriceonetimecustomcreate.js +91 -0
- package/models/components/productpriceonetimecustomcreate.js.map +1 -0
- package/models/components/productpriceonetimefixed.d.ts +114 -0
- package/models/components/productpriceonetimefixed.d.ts.map +1 -0
- package/models/components/productpriceonetimefixed.js +122 -0
- package/models/components/productpriceonetimefixed.js.map +1 -0
- package/models/components/productpriceonetimefixedcreate.d.ts +61 -0
- package/models/components/productpriceonetimefixedcreate.d.ts.map +1 -0
- package/models/components/{productpriceonetimecreate.js → productpriceonetimefixedcreate.js} +25 -25
- package/models/components/productpriceonetimefixedcreate.js.map +1 -0
- package/models/components/productpriceoutput.d.ts +3 -11
- package/models/components/productpriceoutput.d.ts.map +1 -1
- package/models/components/productpriceoutput.js +5 -13
- package/models/components/productpriceoutput.js.map +1 -1
- package/models/components/productpricerecurringcreate.d.ts +7 -7
- package/models/components/productpricerecurringcreate.d.ts.map +1 -1
- package/models/components/productpricerecurringcreate.js +9 -9
- package/models/components/productpricerecurringcreate.js.map +1 -1
- package/models/components/productpricerecurringcustom.d.ts +130 -0
- package/models/components/productpricerecurringcustom.d.ts.map +1 -0
- package/models/components/productpricerecurringcustom.js +135 -0
- package/models/components/productpricerecurringcustom.js.map +1 -0
- package/models/components/productpricerecurringfixed.d.ts +120 -0
- package/models/components/productpricerecurringfixed.d.ts.map +1 -0
- package/models/components/productpricerecurringfixed.js +128 -0
- package/models/components/productpricerecurringfixed.js.map +1 -0
- package/models/components/productpricerecurringinput.d.ts +31 -0
- package/models/components/productpricerecurringinput.d.ts.map +1 -0
- package/models/components/productpricerecurringinput.js +62 -0
- package/models/components/productpricerecurringinput.js.map +1 -0
- package/models/components/productpricerecurringoutput.d.ts +31 -0
- package/models/components/productpricerecurringoutput.d.ts.map +1 -0
- package/models/components/productpricerecurringoutput.js +62 -0
- package/models/components/productpricerecurringoutput.js.map +1 -0
- package/models/components/productupdate.d.ts +15 -14
- package/models/components/productupdate.d.ts.map +1 -1
- package/models/components/productupdate.js +20 -16
- package/models/components/productupdate.js.map +1 -1
- package/models/components/subscriptioninput.d.ts +7 -0
- package/models/components/subscriptioninput.d.ts.map +1 -1
- package/models/components/subscriptioninput.js +9 -0
- package/models/components/subscriptioninput.js.map +1 -1
- package/models/components/subscriptionoutput.d.ts +7 -0
- package/models/components/subscriptionoutput.d.ts.map +1 -1
- package/models/components/subscriptionoutput.js +9 -0
- package/models/components/subscriptionoutput.js.map +1 -1
- package/models/components/subscriptionrecurringinterval.d.ts +28 -0
- package/models/components/{productpricerecurringinterval.d.ts.map → subscriptionrecurringinterval.d.ts.map} +1 -1
- package/models/components/{productpricerecurringinterval.js → subscriptionrecurringinterval.js} +12 -12
- package/models/components/{productpricerecurringinterval.js.map → subscriptionrecurringinterval.js.map} +1 -1
- package/models/components/subscriptionsortproperty.d.ts +6 -6
- package/models/components/subscriptionsortproperty.js +2 -2
- package/models/components/subscriptionsortproperty.js.map +1 -1
- package/models/components/userordersubscription.d.ts +7 -0
- package/models/components/userordersubscription.d.ts.map +1 -1
- package/models/components/userordersubscription.js +9 -0
- package/models/components/userordersubscription.js.map +1 -1
- package/models/components/usersubscription.d.ts +10 -0
- package/models/components/usersubscription.d.ts.map +1 -1
- package/models/components/usersubscription.js +9 -0
- package/models/components/usersubscription.js.map +1 -1
- package/models/components/usersubscriptionsortproperty.d.ts +6 -6
- package/models/components/usersubscriptionsortproperty.js +2 -2
- package/models/components/usersubscriptionsortproperty.js.map +1 -1
- package/package.json +1 -1
- package/src/funcs/advertisementsList.ts +2 -2
- package/src/funcs/articlesList.ts +2 -2
- package/src/funcs/benefitsGrants.ts +2 -2
- package/src/funcs/benefitsList.ts +2 -2
- package/src/funcs/externalOrganizationsList.ts +2 -2
- package/src/funcs/filesList.ts +2 -2
- package/src/funcs/licenseKeysList.ts +2 -2
- package/src/funcs/oauth2ClientsList.ts +2 -2
- package/src/funcs/ordersList.ts +2 -2
- package/src/funcs/organizationsList.ts +2 -2
- package/src/funcs/productsList.ts +2 -2
- package/src/funcs/repositoriesList.ts +2 -2
- package/src/funcs/subscriptionsList.ts +2 -2
- package/src/funcs/usersAdvertisementsList.ts +2 -2
- package/src/funcs/usersBenefitsList.ts +2 -2
- package/src/funcs/usersDownloadablesList.ts +2 -2
- package/src/funcs/usersLicenseKeysList.ts +2 -2
- package/src/funcs/usersOrdersList.ts +2 -2
- package/src/funcs/usersSubscriptionsList.ts +2 -2
- package/src/lib/config.ts +18 -12
- package/src/models/components/bodysubscriptionsimport.ts +4 -2
- package/src/models/components/index.ts +9 -3
- package/src/models/components/ordersubscription.ts +19 -0
- package/src/models/components/organizationfeaturesettings.ts +0 -9
- package/src/models/components/productonetimecreate.ts +69 -9
- package/src/models/components/productpriceinput.ts +13 -29
- package/src/models/components/productpriceonetime.ts +27 -115
- package/src/models/components/productpriceonetimecustom.ts +201 -0
- package/src/models/components/productpriceonetimecustomcreate.ts +122 -0
- package/src/models/components/productpriceonetimefixed.ts +182 -0
- package/src/models/components/productpriceonetimefixedcreate.ts +103 -0
- package/src/models/components/productpriceoutput.ts +13 -29
- package/src/models/components/productpricerecurringcreate.ts +18 -18
- package/src/models/components/productpricerecurringcustom.ts +216 -0
- package/src/models/components/productpricerecurringfixed.ts +191 -0
- package/src/models/components/productpricerecurringinput.ts +75 -0
- package/src/models/components/productpricerecurringoutput.ts +75 -0
- package/src/models/components/productupdate.ts +49 -32
- package/src/models/components/subscriptioninput.ts +19 -0
- package/src/models/components/subscriptionoutput.ts +19 -0
- package/src/models/components/subscriptionrecurringinterval.ts +35 -0
- package/src/models/components/subscriptionsortproperty.ts +2 -2
- package/src/models/components/userordersubscription.ts +19 -0
- package/src/models/components/usersubscription.ts +22 -0
- package/src/models/components/usersubscriptionsortproperty.ts +2 -2
- package/models/components/productpriceonetimecreate.d.ts +0 -61
- package/models/components/productpriceonetimecreate.d.ts.map +0 -1
- package/models/components/productpriceonetimecreate.js.map +0 -1
- package/models/components/productpricerecurring.d.ts +0 -96
- package/models/components/productpricerecurring.d.ts.map +0 -1
- package/models/components/productpricerecurring.js +0 -105
- package/models/components/productpricerecurring.js.map +0 -1
- package/models/components/productpricerecurringinterval.d.ts +0 -28
- package/src/models/components/productpriceonetimecreate.ts +0 -102
- package/src/models/components/productpricerecurring.ts +0 -161
- package/src/models/components/productpricerecurringinterval.ts +0 -35
|
@@ -0,0 +1,191 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
8
|
+
import {
|
|
9
|
+
SubscriptionRecurringInterval,
|
|
10
|
+
SubscriptionRecurringInterval$inboundSchema,
|
|
11
|
+
SubscriptionRecurringInterval$outboundSchema,
|
|
12
|
+
} from "./subscriptionrecurringinterval.js";
|
|
13
|
+
|
|
14
|
+
export const AmountType = {
|
|
15
|
+
Fixed: "fixed",
|
|
16
|
+
} as const;
|
|
17
|
+
export type AmountType = ClosedEnum<typeof AmountType>;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* The type of the price.
|
|
21
|
+
*/
|
|
22
|
+
export const ProductPriceRecurringFixedType = {
|
|
23
|
+
Recurring: "recurring",
|
|
24
|
+
} as const;
|
|
25
|
+
/**
|
|
26
|
+
* The type of the price.
|
|
27
|
+
*/
|
|
28
|
+
export type ProductPriceRecurringFixedType = ClosedEnum<
|
|
29
|
+
typeof ProductPriceRecurringFixedType
|
|
30
|
+
>;
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* A recurring price for a product, i.e. a subscription.
|
|
34
|
+
*/
|
|
35
|
+
export type ProductPriceRecurringFixed = {
|
|
36
|
+
/**
|
|
37
|
+
* Creation timestamp of the object.
|
|
38
|
+
*/
|
|
39
|
+
createdAt: Date;
|
|
40
|
+
/**
|
|
41
|
+
* Last modification timestamp of the object.
|
|
42
|
+
*/
|
|
43
|
+
modifiedAt: Date | null;
|
|
44
|
+
/**
|
|
45
|
+
* The ID of the price.
|
|
46
|
+
*/
|
|
47
|
+
id: string;
|
|
48
|
+
amountType?: "fixed" | undefined;
|
|
49
|
+
/**
|
|
50
|
+
* The currency.
|
|
51
|
+
*/
|
|
52
|
+
priceCurrency: string;
|
|
53
|
+
/**
|
|
54
|
+
* Whether the price is archived and no longer available.
|
|
55
|
+
*/
|
|
56
|
+
isArchived: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* The price in cents.
|
|
59
|
+
*/
|
|
60
|
+
priceAmount: number;
|
|
61
|
+
/**
|
|
62
|
+
* The type of the price.
|
|
63
|
+
*/
|
|
64
|
+
type?: "recurring" | undefined;
|
|
65
|
+
/**
|
|
66
|
+
* The recurring interval of the price.
|
|
67
|
+
*/
|
|
68
|
+
recurringInterval: SubscriptionRecurringInterval;
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/** @internal */
|
|
72
|
+
export const AmountType$inboundSchema: z.ZodNativeEnum<typeof AmountType> = z
|
|
73
|
+
.nativeEnum(AmountType);
|
|
74
|
+
|
|
75
|
+
/** @internal */
|
|
76
|
+
export const AmountType$outboundSchema: z.ZodNativeEnum<typeof AmountType> =
|
|
77
|
+
AmountType$inboundSchema;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* @internal
|
|
81
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
82
|
+
*/
|
|
83
|
+
export namespace AmountType$ {
|
|
84
|
+
/** @deprecated use `AmountType$inboundSchema` instead. */
|
|
85
|
+
export const inboundSchema = AmountType$inboundSchema;
|
|
86
|
+
/** @deprecated use `AmountType$outboundSchema` instead. */
|
|
87
|
+
export const outboundSchema = AmountType$outboundSchema;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/** @internal */
|
|
91
|
+
export const ProductPriceRecurringFixedType$inboundSchema: z.ZodNativeEnum<
|
|
92
|
+
typeof ProductPriceRecurringFixedType
|
|
93
|
+
> = z.nativeEnum(ProductPriceRecurringFixedType);
|
|
94
|
+
|
|
95
|
+
/** @internal */
|
|
96
|
+
export const ProductPriceRecurringFixedType$outboundSchema: z.ZodNativeEnum<
|
|
97
|
+
typeof ProductPriceRecurringFixedType
|
|
98
|
+
> = ProductPriceRecurringFixedType$inboundSchema;
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* @internal
|
|
102
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
103
|
+
*/
|
|
104
|
+
export namespace ProductPriceRecurringFixedType$ {
|
|
105
|
+
/** @deprecated use `ProductPriceRecurringFixedType$inboundSchema` instead. */
|
|
106
|
+
export const inboundSchema = ProductPriceRecurringFixedType$inboundSchema;
|
|
107
|
+
/** @deprecated use `ProductPriceRecurringFixedType$outboundSchema` instead. */
|
|
108
|
+
export const outboundSchema = ProductPriceRecurringFixedType$outboundSchema;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
/** @internal */
|
|
112
|
+
export const ProductPriceRecurringFixed$inboundSchema: z.ZodType<
|
|
113
|
+
ProductPriceRecurringFixed,
|
|
114
|
+
z.ZodTypeDef,
|
|
115
|
+
unknown
|
|
116
|
+
> = z.object({
|
|
117
|
+
created_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
118
|
+
modified_at: z.nullable(
|
|
119
|
+
z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
120
|
+
),
|
|
121
|
+
id: z.string(),
|
|
122
|
+
amount_type: z.literal("fixed").optional(),
|
|
123
|
+
price_currency: z.string(),
|
|
124
|
+
is_archived: z.boolean(),
|
|
125
|
+
price_amount: z.number().int(),
|
|
126
|
+
type: z.literal("recurring").optional(),
|
|
127
|
+
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
128
|
+
}).transform((v) => {
|
|
129
|
+
return remap$(v, {
|
|
130
|
+
"created_at": "createdAt",
|
|
131
|
+
"modified_at": "modifiedAt",
|
|
132
|
+
"amount_type": "amountType",
|
|
133
|
+
"price_currency": "priceCurrency",
|
|
134
|
+
"is_archived": "isArchived",
|
|
135
|
+
"price_amount": "priceAmount",
|
|
136
|
+
"recurring_interval": "recurringInterval",
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
|
|
140
|
+
/** @internal */
|
|
141
|
+
export type ProductPriceRecurringFixed$Outbound = {
|
|
142
|
+
created_at: string;
|
|
143
|
+
modified_at: string | null;
|
|
144
|
+
id: string;
|
|
145
|
+
amount_type: "fixed";
|
|
146
|
+
price_currency: string;
|
|
147
|
+
is_archived: boolean;
|
|
148
|
+
price_amount: number;
|
|
149
|
+
type: "recurring";
|
|
150
|
+
recurring_interval: string;
|
|
151
|
+
};
|
|
152
|
+
|
|
153
|
+
/** @internal */
|
|
154
|
+
export const ProductPriceRecurringFixed$outboundSchema: z.ZodType<
|
|
155
|
+
ProductPriceRecurringFixed$Outbound,
|
|
156
|
+
z.ZodTypeDef,
|
|
157
|
+
ProductPriceRecurringFixed
|
|
158
|
+
> = z.object({
|
|
159
|
+
createdAt: z.date().transform(v => v.toISOString()),
|
|
160
|
+
modifiedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
161
|
+
id: z.string(),
|
|
162
|
+
amountType: z.literal("fixed").default("fixed"),
|
|
163
|
+
priceCurrency: z.string(),
|
|
164
|
+
isArchived: z.boolean(),
|
|
165
|
+
priceAmount: z.number().int(),
|
|
166
|
+
type: z.literal("recurring").default("recurring"),
|
|
167
|
+
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
168
|
+
}).transform((v) => {
|
|
169
|
+
return remap$(v, {
|
|
170
|
+
createdAt: "created_at",
|
|
171
|
+
modifiedAt: "modified_at",
|
|
172
|
+
amountType: "amount_type",
|
|
173
|
+
priceCurrency: "price_currency",
|
|
174
|
+
isArchived: "is_archived",
|
|
175
|
+
priceAmount: "price_amount",
|
|
176
|
+
recurringInterval: "recurring_interval",
|
|
177
|
+
});
|
|
178
|
+
});
|
|
179
|
+
|
|
180
|
+
/**
|
|
181
|
+
* @internal
|
|
182
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
183
|
+
*/
|
|
184
|
+
export namespace ProductPriceRecurringFixed$ {
|
|
185
|
+
/** @deprecated use `ProductPriceRecurringFixed$inboundSchema` instead. */
|
|
186
|
+
export const inboundSchema = ProductPriceRecurringFixed$inboundSchema;
|
|
187
|
+
/** @deprecated use `ProductPriceRecurringFixed$outboundSchema` instead. */
|
|
188
|
+
export const outboundSchema = ProductPriceRecurringFixed$outboundSchema;
|
|
189
|
+
/** @deprecated use `ProductPriceRecurringFixed$Outbound` instead. */
|
|
190
|
+
export type Outbound = ProductPriceRecurringFixed$Outbound;
|
|
191
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import {
|
|
7
|
+
ProductPriceRecurringCustom,
|
|
8
|
+
ProductPriceRecurringCustom$inboundSchema,
|
|
9
|
+
ProductPriceRecurringCustom$Outbound,
|
|
10
|
+
ProductPriceRecurringCustom$outboundSchema,
|
|
11
|
+
} from "./productpricerecurringcustom.js";
|
|
12
|
+
import {
|
|
13
|
+
ProductPriceRecurringFixed,
|
|
14
|
+
ProductPriceRecurringFixed$inboundSchema,
|
|
15
|
+
ProductPriceRecurringFixed$Outbound,
|
|
16
|
+
ProductPriceRecurringFixed$outboundSchema,
|
|
17
|
+
} from "./productpricerecurringfixed.js";
|
|
18
|
+
|
|
19
|
+
export type ProductPriceRecurringInput =
|
|
20
|
+
| (ProductPriceRecurringFixed & { amountType: "fixed" })
|
|
21
|
+
| (ProductPriceRecurringCustom & { amountType: "custom" });
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
export const ProductPriceRecurringInput$inboundSchema: z.ZodType<
|
|
25
|
+
ProductPriceRecurringInput,
|
|
26
|
+
z.ZodTypeDef,
|
|
27
|
+
unknown
|
|
28
|
+
> = z.union([
|
|
29
|
+
ProductPriceRecurringFixed$inboundSchema.and(
|
|
30
|
+
z.object({ amount_type: z.literal("fixed") }).transform((v) => ({
|
|
31
|
+
amountType: v.amount_type,
|
|
32
|
+
})),
|
|
33
|
+
),
|
|
34
|
+
ProductPriceRecurringCustom$inboundSchema.and(
|
|
35
|
+
z.object({ amount_type: z.literal("custom") }).transform((v) => ({
|
|
36
|
+
amountType: v.amount_type,
|
|
37
|
+
})),
|
|
38
|
+
),
|
|
39
|
+
]);
|
|
40
|
+
|
|
41
|
+
/** @internal */
|
|
42
|
+
export type ProductPriceRecurringInput$Outbound =
|
|
43
|
+
| (ProductPriceRecurringFixed$Outbound & { amount_type: "fixed" })
|
|
44
|
+
| (ProductPriceRecurringCustom$Outbound & { amount_type: "custom" });
|
|
45
|
+
|
|
46
|
+
/** @internal */
|
|
47
|
+
export const ProductPriceRecurringInput$outboundSchema: z.ZodType<
|
|
48
|
+
ProductPriceRecurringInput$Outbound,
|
|
49
|
+
z.ZodTypeDef,
|
|
50
|
+
ProductPriceRecurringInput
|
|
51
|
+
> = z.union([
|
|
52
|
+
ProductPriceRecurringFixed$outboundSchema.and(
|
|
53
|
+
z.object({ amountType: z.literal("fixed") }).transform((v) => ({
|
|
54
|
+
amount_type: v.amountType,
|
|
55
|
+
})),
|
|
56
|
+
),
|
|
57
|
+
ProductPriceRecurringCustom$outboundSchema.and(
|
|
58
|
+
z.object({ amountType: z.literal("custom") }).transform((v) => ({
|
|
59
|
+
amount_type: v.amountType,
|
|
60
|
+
})),
|
|
61
|
+
),
|
|
62
|
+
]);
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* @internal
|
|
66
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
67
|
+
*/
|
|
68
|
+
export namespace ProductPriceRecurringInput$ {
|
|
69
|
+
/** @deprecated use `ProductPriceRecurringInput$inboundSchema` instead. */
|
|
70
|
+
export const inboundSchema = ProductPriceRecurringInput$inboundSchema;
|
|
71
|
+
/** @deprecated use `ProductPriceRecurringInput$outboundSchema` instead. */
|
|
72
|
+
export const outboundSchema = ProductPriceRecurringInput$outboundSchema;
|
|
73
|
+
/** @deprecated use `ProductPriceRecurringInput$Outbound` instead. */
|
|
74
|
+
export type Outbound = ProductPriceRecurringInput$Outbound;
|
|
75
|
+
}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import {
|
|
7
|
+
ProductPriceRecurringCustom,
|
|
8
|
+
ProductPriceRecurringCustom$inboundSchema,
|
|
9
|
+
ProductPriceRecurringCustom$Outbound,
|
|
10
|
+
ProductPriceRecurringCustom$outboundSchema,
|
|
11
|
+
} from "./productpricerecurringcustom.js";
|
|
12
|
+
import {
|
|
13
|
+
ProductPriceRecurringFixed,
|
|
14
|
+
ProductPriceRecurringFixed$inboundSchema,
|
|
15
|
+
ProductPriceRecurringFixed$Outbound,
|
|
16
|
+
ProductPriceRecurringFixed$outboundSchema,
|
|
17
|
+
} from "./productpricerecurringfixed.js";
|
|
18
|
+
|
|
19
|
+
export type ProductPriceRecurringOutput =
|
|
20
|
+
| (ProductPriceRecurringFixed & { amountType: "fixed" })
|
|
21
|
+
| (ProductPriceRecurringCustom & { amountType: "custom" });
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
export const ProductPriceRecurringOutput$inboundSchema: z.ZodType<
|
|
25
|
+
ProductPriceRecurringOutput,
|
|
26
|
+
z.ZodTypeDef,
|
|
27
|
+
unknown
|
|
28
|
+
> = z.union([
|
|
29
|
+
ProductPriceRecurringFixed$inboundSchema.and(
|
|
30
|
+
z.object({ amount_type: z.literal("fixed") }).transform((v) => ({
|
|
31
|
+
amountType: v.amount_type,
|
|
32
|
+
})),
|
|
33
|
+
),
|
|
34
|
+
ProductPriceRecurringCustom$inboundSchema.and(
|
|
35
|
+
z.object({ amount_type: z.literal("custom") }).transform((v) => ({
|
|
36
|
+
amountType: v.amount_type,
|
|
37
|
+
})),
|
|
38
|
+
),
|
|
39
|
+
]);
|
|
40
|
+
|
|
41
|
+
/** @internal */
|
|
42
|
+
export type ProductPriceRecurringOutput$Outbound =
|
|
43
|
+
| (ProductPriceRecurringFixed$Outbound & { amount_type: "fixed" })
|
|
44
|
+
| (ProductPriceRecurringCustom$Outbound & { amount_type: "custom" });
|
|
45
|
+
|
|
46
|
+
/** @internal */
|
|
47
|
+
export const ProductPriceRecurringOutput$outboundSchema: z.ZodType<
|
|
48
|
+
ProductPriceRecurringOutput$Outbound,
|
|
49
|
+
z.ZodTypeDef,
|
|
50
|
+
ProductPriceRecurringOutput
|
|
51
|
+
> = z.union([
|
|
52
|
+
ProductPriceRecurringFixed$outboundSchema.and(
|
|
53
|
+
z.object({ amountType: z.literal("fixed") }).transform((v) => ({
|
|
54
|
+
amount_type: v.amountType,
|
|
55
|
+
})),
|
|
56
|
+
),
|
|
57
|
+
ProductPriceRecurringCustom$outboundSchema.and(
|
|
58
|
+
z.object({ amountType: z.literal("custom") }).transform((v) => ({
|
|
59
|
+
amount_type: v.amountType,
|
|
60
|
+
})),
|
|
61
|
+
),
|
|
62
|
+
]);
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* @internal
|
|
66
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
67
|
+
*/
|
|
68
|
+
export namespace ProductPriceRecurringOutput$ {
|
|
69
|
+
/** @deprecated use `ProductPriceRecurringOutput$inboundSchema` instead. */
|
|
70
|
+
export const inboundSchema = ProductPriceRecurringOutput$inboundSchema;
|
|
71
|
+
/** @deprecated use `ProductPriceRecurringOutput$outboundSchema` instead. */
|
|
72
|
+
export const outboundSchema = ProductPriceRecurringOutput$outboundSchema;
|
|
73
|
+
/** @deprecated use `ProductPriceRecurringOutput$Outbound` instead. */
|
|
74
|
+
export type Outbound = ProductPriceRecurringOutput$Outbound;
|
|
75
|
+
}
|
|
@@ -11,11 +11,17 @@ import {
|
|
|
11
11
|
ExistingProductPrice$outboundSchema,
|
|
12
12
|
} from "./existingproductprice.js";
|
|
13
13
|
import {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
} from "./
|
|
14
|
+
ProductPriceOneTimeCustomCreate,
|
|
15
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
16
|
+
ProductPriceOneTimeCustomCreate$Outbound,
|
|
17
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
18
|
+
} from "./productpriceonetimecustomcreate.js";
|
|
19
|
+
import {
|
|
20
|
+
ProductPriceOneTimeFixedCreate,
|
|
21
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
22
|
+
ProductPriceOneTimeFixedCreate$Outbound,
|
|
23
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
24
|
+
} from "./productpriceonetimefixedcreate.js";
|
|
19
25
|
import {
|
|
20
26
|
ProductPriceRecurringCreate,
|
|
21
27
|
ProductPriceRecurringCreate$inboundSchema,
|
|
@@ -23,10 +29,11 @@ import {
|
|
|
23
29
|
ProductPriceRecurringCreate$outboundSchema,
|
|
24
30
|
} from "./productpricerecurringcreate.js";
|
|
25
31
|
|
|
26
|
-
export type
|
|
32
|
+
export type ProductUpdatePrices =
|
|
27
33
|
| ExistingProductPrice
|
|
28
|
-
|
|
|
29
|
-
| ProductPriceRecurringCreate
|
|
34
|
+
| ProductPriceOneTimeFixedCreate
|
|
35
|
+
| ProductPriceRecurringCreate
|
|
36
|
+
| ProductPriceOneTimeCustomCreate;
|
|
30
37
|
|
|
31
38
|
/**
|
|
32
39
|
* Schema to update a product.
|
|
@@ -51,8 +58,9 @@ export type ProductUpdate = {
|
|
|
51
58
|
prices?:
|
|
52
59
|
| Array<
|
|
53
60
|
| ExistingProductPrice
|
|
54
|
-
|
|
|
61
|
+
| ProductPriceOneTimeFixedCreate
|
|
55
62
|
| ProductPriceRecurringCreate
|
|
63
|
+
| ProductPriceOneTimeCustomCreate
|
|
56
64
|
>
|
|
57
65
|
| null
|
|
58
66
|
| undefined;
|
|
@@ -63,41 +71,47 @@ export type ProductUpdate = {
|
|
|
63
71
|
};
|
|
64
72
|
|
|
65
73
|
/** @internal */
|
|
66
|
-
export const
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
74
|
+
export const ProductUpdatePrices$inboundSchema: z.ZodType<
|
|
75
|
+
ProductUpdatePrices,
|
|
76
|
+
z.ZodTypeDef,
|
|
77
|
+
unknown
|
|
78
|
+
> = z.union([
|
|
79
|
+
ExistingProductPrice$inboundSchema,
|
|
80
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
81
|
+
ProductPriceRecurringCreate$inboundSchema,
|
|
82
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
83
|
+
]);
|
|
72
84
|
|
|
73
85
|
/** @internal */
|
|
74
|
-
export type
|
|
86
|
+
export type ProductUpdatePrices$Outbound =
|
|
75
87
|
| ExistingProductPrice$Outbound
|
|
76
|
-
|
|
|
77
|
-
| ProductPriceRecurringCreate$Outbound
|
|
88
|
+
| ProductPriceOneTimeFixedCreate$Outbound
|
|
89
|
+
| ProductPriceRecurringCreate$Outbound
|
|
90
|
+
| ProductPriceOneTimeCustomCreate$Outbound;
|
|
78
91
|
|
|
79
92
|
/** @internal */
|
|
80
|
-
export const
|
|
81
|
-
|
|
93
|
+
export const ProductUpdatePrices$outboundSchema: z.ZodType<
|
|
94
|
+
ProductUpdatePrices$Outbound,
|
|
82
95
|
z.ZodTypeDef,
|
|
83
|
-
|
|
96
|
+
ProductUpdatePrices
|
|
84
97
|
> = z.union([
|
|
85
98
|
ExistingProductPrice$outboundSchema,
|
|
86
|
-
|
|
99
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
87
100
|
ProductPriceRecurringCreate$outboundSchema,
|
|
101
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
88
102
|
]);
|
|
89
103
|
|
|
90
104
|
/**
|
|
91
105
|
* @internal
|
|
92
106
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
93
107
|
*/
|
|
94
|
-
export namespace
|
|
95
|
-
/** @deprecated use `
|
|
96
|
-
export const inboundSchema =
|
|
97
|
-
/** @deprecated use `
|
|
98
|
-
export const outboundSchema =
|
|
99
|
-
/** @deprecated use `
|
|
100
|
-
export type Outbound =
|
|
108
|
+
export namespace ProductUpdatePrices$ {
|
|
109
|
+
/** @deprecated use `ProductUpdatePrices$inboundSchema` instead. */
|
|
110
|
+
export const inboundSchema = ProductUpdatePrices$inboundSchema;
|
|
111
|
+
/** @deprecated use `ProductUpdatePrices$outboundSchema` instead. */
|
|
112
|
+
export const outboundSchema = ProductUpdatePrices$outboundSchema;
|
|
113
|
+
/** @deprecated use `ProductUpdatePrices$Outbound` instead. */
|
|
114
|
+
export type Outbound = ProductUpdatePrices$Outbound;
|
|
101
115
|
}
|
|
102
116
|
|
|
103
117
|
/** @internal */
|
|
@@ -114,8 +128,9 @@ export const ProductUpdate$inboundSchema: z.ZodType<
|
|
|
114
128
|
z.array(
|
|
115
129
|
z.union([
|
|
116
130
|
ExistingProductPrice$inboundSchema,
|
|
117
|
-
|
|
131
|
+
ProductPriceOneTimeFixedCreate$inboundSchema,
|
|
118
132
|
ProductPriceRecurringCreate$inboundSchema,
|
|
133
|
+
ProductPriceOneTimeCustomCreate$inboundSchema,
|
|
119
134
|
]),
|
|
120
135
|
),
|
|
121
136
|
).optional(),
|
|
@@ -136,8 +151,9 @@ export type ProductUpdate$Outbound = {
|
|
|
136
151
|
prices?:
|
|
137
152
|
| Array<
|
|
138
153
|
| ExistingProductPrice$Outbound
|
|
139
|
-
|
|
|
154
|
+
| ProductPriceOneTimeFixedCreate$Outbound
|
|
140
155
|
| ProductPriceRecurringCreate$Outbound
|
|
156
|
+
| ProductPriceOneTimeCustomCreate$Outbound
|
|
141
157
|
>
|
|
142
158
|
| null
|
|
143
159
|
| undefined;
|
|
@@ -158,8 +174,9 @@ export const ProductUpdate$outboundSchema: z.ZodType<
|
|
|
158
174
|
z.array(
|
|
159
175
|
z.union([
|
|
160
176
|
ExistingProductPrice$outboundSchema,
|
|
161
|
-
|
|
177
|
+
ProductPriceOneTimeFixedCreate$outboundSchema,
|
|
162
178
|
ProductPriceRecurringCreate$outboundSchema,
|
|
179
|
+
ProductPriceOneTimeCustomCreate$outboundSchema,
|
|
163
180
|
]),
|
|
164
181
|
),
|
|
165
182
|
).optional(),
|
|
@@ -16,6 +16,11 @@ import {
|
|
|
16
16
|
ProductPriceInput$Outbound,
|
|
17
17
|
ProductPriceInput$outboundSchema,
|
|
18
18
|
} from "./productpriceinput.js";
|
|
19
|
+
import {
|
|
20
|
+
SubscriptionRecurringInterval,
|
|
21
|
+
SubscriptionRecurringInterval$inboundSchema,
|
|
22
|
+
SubscriptionRecurringInterval$outboundSchema,
|
|
23
|
+
} from "./subscriptionrecurringinterval.js";
|
|
19
24
|
import {
|
|
20
25
|
SubscriptionStatus,
|
|
21
26
|
SubscriptionStatus$inboundSchema,
|
|
@@ -41,6 +46,9 @@ export type SubscriptionInput = {
|
|
|
41
46
|
* The ID of the object.
|
|
42
47
|
*/
|
|
43
48
|
id: string;
|
|
49
|
+
amount: number | null;
|
|
50
|
+
currency: string | null;
|
|
51
|
+
recurringInterval: SubscriptionRecurringInterval;
|
|
44
52
|
status: SubscriptionStatus;
|
|
45
53
|
currentPeriodStart: Date;
|
|
46
54
|
currentPeriodEnd: Date | null;
|
|
@@ -69,6 +77,9 @@ export const SubscriptionInput$inboundSchema: z.ZodType<
|
|
|
69
77
|
z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
70
78
|
),
|
|
71
79
|
id: z.string(),
|
|
80
|
+
amount: z.nullable(z.number().int()),
|
|
81
|
+
currency: z.nullable(z.string()),
|
|
82
|
+
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
72
83
|
status: SubscriptionStatus$inboundSchema,
|
|
73
84
|
current_period_start: z.string().datetime({ offset: true }).transform(v =>
|
|
74
85
|
new Date(v)
|
|
@@ -93,6 +104,7 @@ export const SubscriptionInput$inboundSchema: z.ZodType<
|
|
|
93
104
|
return remap$(v, {
|
|
94
105
|
"created_at": "createdAt",
|
|
95
106
|
"modified_at": "modifiedAt",
|
|
107
|
+
"recurring_interval": "recurringInterval",
|
|
96
108
|
"current_period_start": "currentPeriodStart",
|
|
97
109
|
"current_period_end": "currentPeriodEnd",
|
|
98
110
|
"cancel_at_period_end": "cancelAtPeriodEnd",
|
|
@@ -109,6 +121,9 @@ export type SubscriptionInput$Outbound = {
|
|
|
109
121
|
created_at: string;
|
|
110
122
|
modified_at: string | null;
|
|
111
123
|
id: string;
|
|
124
|
+
amount: number | null;
|
|
125
|
+
currency: string | null;
|
|
126
|
+
recurring_interval: string;
|
|
112
127
|
status: string;
|
|
113
128
|
current_period_start: string;
|
|
114
129
|
current_period_end: string | null;
|
|
@@ -132,6 +147,9 @@ export const SubscriptionInput$outboundSchema: z.ZodType<
|
|
|
132
147
|
createdAt: z.date().transform(v => v.toISOString()),
|
|
133
148
|
modifiedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
134
149
|
id: z.string(),
|
|
150
|
+
amount: z.nullable(z.number().int()),
|
|
151
|
+
currency: z.nullable(z.string()),
|
|
152
|
+
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
135
153
|
status: SubscriptionStatus$outboundSchema,
|
|
136
154
|
currentPeriodStart: z.date().transform(v => v.toISOString()),
|
|
137
155
|
currentPeriodEnd: z.nullable(z.date().transform(v => v.toISOString())),
|
|
@@ -148,6 +166,7 @@ export const SubscriptionInput$outboundSchema: z.ZodType<
|
|
|
148
166
|
return remap$(v, {
|
|
149
167
|
createdAt: "created_at",
|
|
150
168
|
modifiedAt: "modified_at",
|
|
169
|
+
recurringInterval: "recurring_interval",
|
|
151
170
|
currentPeriodStart: "current_period_start",
|
|
152
171
|
currentPeriodEnd: "current_period_end",
|
|
153
172
|
cancelAtPeriodEnd: "cancel_at_period_end",
|
|
@@ -16,6 +16,11 @@ import {
|
|
|
16
16
|
ProductPriceOutput$Outbound,
|
|
17
17
|
ProductPriceOutput$outboundSchema,
|
|
18
18
|
} from "./productpriceoutput.js";
|
|
19
|
+
import {
|
|
20
|
+
SubscriptionRecurringInterval,
|
|
21
|
+
SubscriptionRecurringInterval$inboundSchema,
|
|
22
|
+
SubscriptionRecurringInterval$outboundSchema,
|
|
23
|
+
} from "./subscriptionrecurringinterval.js";
|
|
19
24
|
import {
|
|
20
25
|
SubscriptionStatus,
|
|
21
26
|
SubscriptionStatus$inboundSchema,
|
|
@@ -41,6 +46,9 @@ export type SubscriptionOutput = {
|
|
|
41
46
|
* The ID of the object.
|
|
42
47
|
*/
|
|
43
48
|
id: string;
|
|
49
|
+
amount: number | null;
|
|
50
|
+
currency: string | null;
|
|
51
|
+
recurringInterval: SubscriptionRecurringInterval;
|
|
44
52
|
status: SubscriptionStatus;
|
|
45
53
|
currentPeriodStart: Date;
|
|
46
54
|
currentPeriodEnd: Date | null;
|
|
@@ -69,6 +77,9 @@ export const SubscriptionOutput$inboundSchema: z.ZodType<
|
|
|
69
77
|
z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
70
78
|
),
|
|
71
79
|
id: z.string(),
|
|
80
|
+
amount: z.nullable(z.number().int()),
|
|
81
|
+
currency: z.nullable(z.string()),
|
|
82
|
+
recurring_interval: SubscriptionRecurringInterval$inboundSchema,
|
|
72
83
|
status: SubscriptionStatus$inboundSchema,
|
|
73
84
|
current_period_start: z.string().datetime({ offset: true }).transform(v =>
|
|
74
85
|
new Date(v)
|
|
@@ -93,6 +104,7 @@ export const SubscriptionOutput$inboundSchema: z.ZodType<
|
|
|
93
104
|
return remap$(v, {
|
|
94
105
|
"created_at": "createdAt",
|
|
95
106
|
"modified_at": "modifiedAt",
|
|
107
|
+
"recurring_interval": "recurringInterval",
|
|
96
108
|
"current_period_start": "currentPeriodStart",
|
|
97
109
|
"current_period_end": "currentPeriodEnd",
|
|
98
110
|
"cancel_at_period_end": "cancelAtPeriodEnd",
|
|
@@ -109,6 +121,9 @@ export type SubscriptionOutput$Outbound = {
|
|
|
109
121
|
created_at: string;
|
|
110
122
|
modified_at: string | null;
|
|
111
123
|
id: string;
|
|
124
|
+
amount: number | null;
|
|
125
|
+
currency: string | null;
|
|
126
|
+
recurring_interval: string;
|
|
112
127
|
status: string;
|
|
113
128
|
current_period_start: string;
|
|
114
129
|
current_period_end: string | null;
|
|
@@ -132,6 +147,9 @@ export const SubscriptionOutput$outboundSchema: z.ZodType<
|
|
|
132
147
|
createdAt: z.date().transform(v => v.toISOString()),
|
|
133
148
|
modifiedAt: z.nullable(z.date().transform(v => v.toISOString())),
|
|
134
149
|
id: z.string(),
|
|
150
|
+
amount: z.nullable(z.number().int()),
|
|
151
|
+
currency: z.nullable(z.string()),
|
|
152
|
+
recurringInterval: SubscriptionRecurringInterval$outboundSchema,
|
|
135
153
|
status: SubscriptionStatus$outboundSchema,
|
|
136
154
|
currentPeriodStart: z.date().transform(v => v.toISOString()),
|
|
137
155
|
currentPeriodEnd: z.nullable(z.date().transform(v => v.toISOString())),
|
|
@@ -148,6 +166,7 @@ export const SubscriptionOutput$outboundSchema: z.ZodType<
|
|
|
148
166
|
return remap$(v, {
|
|
149
167
|
createdAt: "created_at",
|
|
150
168
|
modifiedAt: "modified_at",
|
|
169
|
+
recurringInterval: "recurring_interval",
|
|
151
170
|
currentPeriodStart: "current_period_start",
|
|
152
171
|
currentPeriodEnd: "current_period_end",
|
|
153
172
|
cancelAtPeriodEnd: "cancel_at_period_end",
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { ClosedEnum } from "../../types/enums.js";
|
|
7
|
+
|
|
8
|
+
export const SubscriptionRecurringInterval = {
|
|
9
|
+
Month: "month",
|
|
10
|
+
Year: "year",
|
|
11
|
+
} as const;
|
|
12
|
+
export type SubscriptionRecurringInterval = ClosedEnum<
|
|
13
|
+
typeof SubscriptionRecurringInterval
|
|
14
|
+
>;
|
|
15
|
+
|
|
16
|
+
/** @internal */
|
|
17
|
+
export const SubscriptionRecurringInterval$inboundSchema: z.ZodNativeEnum<
|
|
18
|
+
typeof SubscriptionRecurringInterval
|
|
19
|
+
> = z.nativeEnum(SubscriptionRecurringInterval);
|
|
20
|
+
|
|
21
|
+
/** @internal */
|
|
22
|
+
export const SubscriptionRecurringInterval$outboundSchema: z.ZodNativeEnum<
|
|
23
|
+
typeof SubscriptionRecurringInterval
|
|
24
|
+
> = SubscriptionRecurringInterval$inboundSchema;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @internal
|
|
28
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
29
|
+
*/
|
|
30
|
+
export namespace SubscriptionRecurringInterval$ {
|
|
31
|
+
/** @deprecated use `SubscriptionRecurringInterval$inboundSchema` instead. */
|
|
32
|
+
export const inboundSchema = SubscriptionRecurringInterval$inboundSchema;
|
|
33
|
+
/** @deprecated use `SubscriptionRecurringInterval$outboundSchema` instead. */
|
|
34
|
+
export const outboundSchema = SubscriptionRecurringInterval$outboundSchema;
|
|
35
|
+
}
|
|
@@ -14,8 +14,8 @@ export const SubscriptionSortProperty = {
|
|
|
14
14
|
MinusStartedAt: "-started_at",
|
|
15
15
|
CurrentPeriodEnd: "current_period_end",
|
|
16
16
|
MinusCurrentPeriodEnd: "-current_period_end",
|
|
17
|
-
|
|
18
|
-
|
|
17
|
+
Amount: "amount",
|
|
18
|
+
MinusAmount: "-amount",
|
|
19
19
|
SubscriptionTierType: "subscription_tier_type",
|
|
20
20
|
MinusSubscriptionTierType: "-subscription_tier_type",
|
|
21
21
|
Product: "product",
|