@polar-sh/sdk 0.17.4 → 0.18.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/FUNCTIONS.md +106 -0
- package/README.md +181 -30
- package/RUNTIMES.md +22 -0
- package/docs/sdks/checkouts/README.md +1 -1
- package/hooks/hooks.d.ts.map +1 -1
- package/hooks/hooks.js +18 -0
- package/hooks/hooks.js.map +1 -1
- package/hooks/types.d.ts +3 -0
- package/hooks/types.d.ts.map +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/config.js.map +1 -1
- package/models/components/benefit.d.ts +2 -3
- package/models/components/benefit.d.ts.map +1 -1
- package/models/components/benefit.js +0 -3
- package/models/components/benefit.js.map +1 -1
- package/models/components/benefitadssubscriber.d.ts +7 -7
- package/models/components/benefitadssubscriber.d.ts.map +1 -1
- package/models/components/benefitadssubscriber.js +11 -11
- package/models/components/benefitadssubscriber.js.map +1 -1
- package/models/components/benefitgrant.d.ts +4 -5
- package/models/components/benefitgrant.d.ts.map +1 -1
- package/models/components/benefitgrant.js +0 -5
- package/models/components/benefitgrant.js.map +1 -1
- package/models/components/benefitgrantwebhook.d.ts +8 -9
- package/models/components/benefitgrantwebhook.d.ts.map +1 -1
- package/models/components/benefitgrantwebhook.js +0 -9
- package/models/components/benefitgrantwebhook.js.map +1 -1
- package/models/components/benefittype.d.ts +0 -3
- package/models/components/benefittype.d.ts.map +1 -1
- package/models/components/benefittype.js +0 -1
- package/models/components/benefittype.js.map +1 -1
- package/models/components/checkoutlinkproduct.d.ts +2 -24
- package/models/components/checkoutlinkproduct.d.ts.map +1 -1
- package/models/components/checkoutlinkproduct.js +3 -27
- package/models/components/checkoutlinkproduct.js.map +1 -1
- package/models/components/checkoutproduct.d.ts +2 -24
- package/models/components/checkoutproduct.d.ts.map +1 -1
- package/models/components/checkoutproduct.js +3 -27
- package/models/components/checkoutproduct.js.map +1 -1
- package/models/components/index.d.ts +0 -15
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +0 -15
- package/models/components/index.js.map +1 -1
- package/models/components/listresourceuserbenefit.d.ts +0 -9
- package/models/components/listresourceuserbenefit.d.ts.map +1 -1
- package/models/components/listresourceuserbenefit.js +0 -13
- package/models/components/listresourceuserbenefit.js.map +1 -1
- package/models/components/oauth2client.js +2 -2
- package/models/components/oauth2client.js.map +1 -1
- package/models/components/oauth2clientconfiguration.js +2 -2
- package/models/components/oauth2clientconfiguration.js.map +1 -1
- package/models/components/oauth2clientconfigurationupdate.js +2 -2
- package/models/components/oauth2clientconfigurationupdate.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/scope.d.ts +0 -6
- package/models/components/scope.d.ts.map +1 -1
- package/models/components/scope.js +0 -2
- package/models/components/scope.js.map +1 -1
- package/models/components/userorderproduct.d.ts +2 -24
- package/models/components/userorderproduct.d.ts.map +1 -1
- package/models/components/userorderproduct.js +3 -27
- package/models/components/userorderproduct.js.map +1 -1
- package/models/components/usersubscriptionproduct.d.ts +2 -24
- package/models/components/usersubscriptionproduct.d.ts.map +1 -1
- package/models/components/usersubscriptionproduct.js +3 -27
- package/models/components/usersubscriptionproduct.js.map +1 -1
- package/models/operations/benefitsupdate.d.ts +4 -4
- package/models/operations/benefitsupdate.d.ts.map +1 -1
- package/models/operations/benefitsupdate.js +0 -4
- package/models/operations/benefitsupdate.js.map +1 -1
- package/models/operations/index.d.ts +0 -8
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +0 -8
- package/models/operations/index.js.map +1 -1
- package/models/operations/usersbenefitsget.d.ts +2 -6
- package/models/operations/usersbenefitsget.d.ts.map +1 -1
- package/models/operations/usersbenefitsget.js +0 -6
- package/models/operations/usersbenefitsget.js.map +1 -1
- package/package.json +1 -3
- package/sdk/sdk.d.ts +0 -3
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +0 -5
- package/sdk/sdk.js.map +1 -1
- package/src/hooks/hooks.ts +20 -0
- package/src/hooks/types.ts +9 -0
- package/src/lib/config.ts +3 -3
- package/src/models/components/benefit.ts +0 -10
- package/src/models/components/benefitadssubscriber.ts +12 -15
- package/src/models/components/benefitgrant.ts +0 -14
- package/src/models/components/benefitgrantwebhook.ts +0 -22
- package/src/models/components/benefittype.ts +0 -1
- package/src/models/components/checkoutlinkproduct.ts +4 -68
- package/src/models/components/checkoutproduct.ts +4 -66
- package/src/models/components/index.ts +0 -15
- package/src/models/components/listresourceuserbenefit.ts +0 -30
- package/src/models/components/oauth2client.ts +2 -2
- package/src/models/components/oauth2clientconfiguration.ts +2 -2
- package/src/models/components/oauth2clientconfigurationupdate.ts +2 -2
- package/src/models/components/organizationfeaturesettings.ts +0 -9
- package/src/models/components/scope.ts +0 -2
- package/src/models/components/userorderproduct.ts +4 -60
- package/src/models/components/usersubscriptionproduct.ts +4 -68
- package/src/models/operations/benefitsupdate.ts +0 -8
- package/src/models/operations/index.ts +0 -8
- package/src/models/operations/usersbenefitsget.ts +0 -12
- package/src/sdk/sdk.ts +0 -6
- package/src/types/index.ts +1 -0
- package/src/types/webhooks.ts +7 -0
- package/types/index.d.ts +1 -0
- package/types/index.d.ts.map +1 -1
- package/types/webhooks.d.ts +4 -0
- package/types/webhooks.d.ts.map +1 -0
- package/types/webhooks.js +6 -0
- package/types/webhooks.js.map +1 -0
- package/docs/sdks/articles/README.md +0 -724
- package/funcs/articlesCreate.d.ts +0 -16
- package/funcs/articlesCreate.d.ts.map +0 -1
- package/funcs/articlesCreate.js +0 -99
- package/funcs/articlesCreate.js.map +0 -1
- package/funcs/articlesDelete.d.ts +0 -16
- package/funcs/articlesDelete.d.ts.map +0 -1
- package/funcs/articlesDelete.js +0 -105
- package/funcs/articlesDelete.js.map +0 -1
- package/funcs/articlesExport.d.ts +0 -16
- package/funcs/articlesExport.d.ts.map +0 -1
- package/funcs/articlesExport.js +0 -103
- package/funcs/articlesExport.js.map +0 -1
- package/funcs/articlesGet.d.ts +0 -17
- package/funcs/articlesGet.d.ts.map +0 -1
- package/funcs/articlesGet.js +0 -105
- package/funcs/articlesGet.js.map +0 -1
- package/funcs/articlesList.d.ts +0 -19
- package/funcs/articlesList.d.ts.map +0 -1
- package/funcs/articlesList.js +0 -138
- package/funcs/articlesList.js.map +0 -1
- package/funcs/articlesPreview.d.ts +0 -16
- package/funcs/articlesPreview.d.ts.map +0 -1
- package/funcs/articlesPreview.js +0 -106
- package/funcs/articlesPreview.js.map +0 -1
- package/funcs/articlesReceivers.d.ts +0 -17
- package/funcs/articlesReceivers.d.ts.map +0 -1
- package/funcs/articlesReceivers.js +0 -105
- package/funcs/articlesReceivers.js.map +0 -1
- package/funcs/articlesSend.d.ts +0 -16
- package/funcs/articlesSend.d.ts.map +0 -1
- package/funcs/articlesSend.js +0 -105
- package/funcs/articlesSend.js.map +0 -1
- package/funcs/articlesUpdate.d.ts +0 -17
- package/funcs/articlesUpdate.d.ts.map +0 -1
- package/funcs/articlesUpdate.js +0 -106
- package/funcs/articlesUpdate.js.map +0 -1
- package/models/components/article.d.ts +0 -68
- package/models/components/article.d.ts.map +0 -1
- package/models/components/article.js +0 -129
- package/models/components/article.js.map +0 -1
- package/models/components/articlebyline.d.ts +0 -28
- package/models/components/articlebyline.d.ts.map +0 -1
- package/models/components/articlebyline.js +0 -50
- package/models/components/articlebyline.js.map +0 -1
- package/models/components/articlecreate.d.ts +0 -93
- package/models/components/articlecreate.d.ts.map +0 -1
- package/models/components/articlecreate.js +0 -112
- package/models/components/articlecreate.js.map +0 -1
- package/models/components/articlepreview.d.ts +0 -32
- package/models/components/articlepreview.d.ts.map +0 -1
- package/models/components/articlepreview.js +0 -59
- package/models/components/articlepreview.js.map +0 -1
- package/models/components/articlereceivers.d.ts +0 -33
- package/models/components/articlereceivers.d.ts.map +0 -1
- package/models/components/articlereceivers.js +0 -76
- package/models/components/articlereceivers.js.map +0 -1
- package/models/components/articleupdate.d.ts +0 -85
- package/models/components/articleupdate.d.ts.map +0 -1
- package/models/components/articleupdate.js +0 -108
- package/models/components/articleupdate.js.map +0 -1
- package/models/components/articlevisibility.d.ts +0 -31
- package/models/components/articlevisibility.d.ts.map +0 -1
- package/models/components/articlevisibility.js +0 -51
- package/models/components/articlevisibility.js.map +0 -1
- package/models/components/benefitarticles.d.ts +0 -100
- package/models/components/benefitarticles.d.ts.map +0 -1
- package/models/components/benefitarticles.js +0 -107
- package/models/components/benefitarticles.js.map +0 -1
- package/models/components/benefitarticlesproperties.d.ts +0 -35
- package/models/components/benefitarticlesproperties.d.ts.map +0 -1
- package/models/components/benefitarticlesproperties.js +0 -68
- package/models/components/benefitarticlesproperties.js.map +0 -1
- package/models/components/benefitarticlessubscriber.d.ts +0 -99
- package/models/components/benefitarticlessubscriber.d.ts.map +0 -1
- package/models/components/benefitarticlessubscriber.js +0 -113
- package/models/components/benefitarticlessubscriber.js.map +0 -1
- package/models/components/benefitarticlessubscriberproperties.d.ts +0 -35
- package/models/components/benefitarticlessubscriberproperties.d.ts.map +0 -1
- package/models/components/benefitarticlessubscriberproperties.js +0 -68
- package/models/components/benefitarticlessubscriberproperties.js.map +0 -1
- package/models/components/benefitarticlesupdate.d.ts +0 -57
- package/models/components/benefitarticlesupdate.d.ts.map +0 -1
- package/models/components/benefitarticlesupdate.js +0 -79
- package/models/components/benefitarticlesupdate.js.map +0 -1
- package/models/components/benefitgrantarticlesproperties.d.ts +0 -25
- package/models/components/benefitgrantarticlesproperties.d.ts.map +0 -1
- package/models/components/benefitgrantarticlesproperties.js +0 -55
- package/models/components/benefitgrantarticlesproperties.js.map +0 -1
- package/models/components/bylineprofile.d.ts +0 -31
- package/models/components/bylineprofile.d.ts.map +0 -1
- package/models/components/bylineprofile.js +0 -70
- package/models/components/bylineprofile.js.map +0 -1
- package/models/components/listresourcearticle.d.ts +0 -33
- package/models/components/listresourcearticle.d.ts.map +0 -1
- package/models/components/listresourcearticle.js +0 -63
- package/models/components/listresourcearticle.js.map +0 -1
- package/models/operations/articlesdelete.d.ts +0 -29
- package/models/operations/articlesdelete.d.ts.map +0 -1
- package/models/operations/articlesdelete.js +0 -59
- package/models/operations/articlesdelete.js.map +0 -1
- package/models/operations/articlesexport.d.ts +0 -29
- package/models/operations/articlesexport.d.ts.map +0 -1
- package/models/operations/articlesexport.js +0 -68
- package/models/operations/articlesexport.js.map +0 -1
- package/models/operations/articlesget.d.ts +0 -29
- package/models/operations/articlesget.d.ts.map +0 -1
- package/models/operations/articlesget.js +0 -59
- package/models/operations/articlesget.js.map +0 -1
- package/models/operations/articleslist.d.ts +0 -141
- package/models/operations/articleslist.d.ts.map +0 -1
- package/models/operations/articleslist.js +0 -184
- package/models/operations/articleslist.js.map +0 -1
- package/models/operations/articlespreview.d.ts +0 -32
- package/models/operations/articlespreview.d.ts.map +0 -1
- package/models/operations/articlespreview.js +0 -71
- package/models/operations/articlespreview.js.map +0 -1
- package/models/operations/articlesreceivers.d.ts +0 -29
- package/models/operations/articlesreceivers.d.ts.map +0 -1
- package/models/operations/articlesreceivers.js +0 -59
- package/models/operations/articlesreceivers.js.map +0 -1
- package/models/operations/articlessend.d.ts +0 -29
- package/models/operations/articlessend.d.ts.map +0 -1
- package/models/operations/articlessend.js +0 -59
- package/models/operations/articlessend.js.map +0 -1
- package/models/operations/articlesupdate.d.ts +0 -32
- package/models/operations/articlesupdate.d.ts.map +0 -1
- package/models/operations/articlesupdate.js +0 -71
- package/models/operations/articlesupdate.js.map +0 -1
- package/sdk/articles.d.ts +0 -72
- package/sdk/articles.d.ts.map +0 -1
- package/sdk/articles.js +0 -103
- package/sdk/articles.js.map +0 -1
- package/src/funcs/articlesCreate.ts +0 -131
- package/src/funcs/articlesDelete.ts +0 -144
- package/src/funcs/articlesExport.ts +0 -136
- package/src/funcs/articlesGet.ts +0 -141
- package/src/funcs/articlesList.ts +0 -205
- package/src/funcs/articlesPreview.ts +0 -145
- package/src/funcs/articlesReceivers.ts +0 -138
- package/src/funcs/articlesSend.ts +0 -144
- package/src/funcs/articlesUpdate.ts +0 -145
- package/src/models/components/article.ts +0 -187
- package/src/models/components/articlebyline.ts +0 -33
- package/src/models/components/articlecreate.ts +0 -191
- package/src/models/components/articlepreview.ts +0 -65
- package/src/models/components/articlereceivers.ts +0 -87
- package/src/models/components/articleupdate.ts +0 -179
- package/src/models/components/articlevisibility.ts +0 -34
- package/src/models/components/benefitarticles.ts +0 -175
- package/src/models/components/benefitarticlesproperties.ts +0 -81
- package/src/models/components/benefitarticlessubscriber.ts +0 -189
- package/src/models/components/benefitarticlessubscriberproperties.ts +0 -86
- package/src/models/components/benefitarticlesupdate.ts +0 -102
- package/src/models/components/benefitgrantarticlesproperties.ts +0 -60
- package/src/models/components/bylineprofile.ts +0 -75
- package/src/models/components/listresourcearticle.ts +0 -82
- package/src/models/operations/articlesdelete.ts +0 -66
- package/src/models/operations/articlesexport.ts +0 -75
- package/src/models/operations/articlesget.ts +0 -66
- package/src/models/operations/articleslist.ts +0 -342
- package/src/models/operations/articlespreview.ts +0 -80
- package/src/models/operations/articlesreceivers.ts +0 -66
- package/src/models/operations/articlessend.ts +0 -66
- package/src/models/operations/articlesupdate.ts +0 -80
- package/src/sdk/articles.ts +0 -173
|
@@ -61,9 +61,6 @@ function usersBenefitsGetRequestFromJSON(jsonString) {
|
|
|
61
61
|
}
|
|
62
62
|
/** @internal */
|
|
63
63
|
exports.UsersBenefitsGetResponseUsersBenefitsGet$inboundSchema = z.union([
|
|
64
|
-
components.BenefitArticlesSubscriber$inboundSchema.and(z.object({ type: z.literal("articles") }).transform((v) => ({
|
|
65
|
-
type: v.type,
|
|
66
|
-
}))),
|
|
67
64
|
components.BenefitAdsSubscriber$inboundSchema.and(z.object({ type: z.literal("ads") }).transform((v) => ({ type: v.type }))),
|
|
68
65
|
components.BenefitDiscordSubscriber$inboundSchema.and(z.object({ type: z.literal("discord") }).transform((v) => ({
|
|
69
66
|
type: v.type,
|
|
@@ -83,9 +80,6 @@ exports.UsersBenefitsGetResponseUsersBenefitsGet$inboundSchema = z.union([
|
|
|
83
80
|
]);
|
|
84
81
|
/** @internal */
|
|
85
82
|
exports.UsersBenefitsGetResponseUsersBenefitsGet$outboundSchema = z.union([
|
|
86
|
-
components.BenefitArticlesSubscriber$outboundSchema.and(z.object({ type: z.literal("articles") }).transform((v) => ({
|
|
87
|
-
type: v.type,
|
|
88
|
-
}))),
|
|
89
83
|
components.BenefitAdsSubscriber$outboundSchema.and(z.object({ type: z.literal("ads") }).transform((v) => ({ type: v.type }))),
|
|
90
84
|
components.BenefitDiscordSubscriber$outboundSchema.and(z.object({ type: z.literal("discord") }).transform((v) => ({
|
|
91
85
|
type: v.type,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usersbenefitsget.js","sourceRoot":"","sources":["../../src/models/operations/usersbenefitsget.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"usersbenefitsget.js","sourceRoot":"","sources":["../../src/models/operations/usersbenefitsget.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;AAgEH,sEAMC;AAED,0EAQC;AAwGD,wGASC;AAED,4GAcC;AA/MD,uCAAyB;AACzB,qDAAiD;AAEjD,mEAAqD;AAuBrD,gBAAgB;AACH,QAAA,qCAAqC,GAI9C,CAAC,CAAC,MAAM,CAAC;IACX,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;CACf,CAAC,CAAC;AAOH,gBAAgB;AACH,QAAA,sCAAsC,GAI/C,CAAC,CAAC,MAAM,CAAC;IACX,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE;CACf,CAAC,CAAC;AAEH;;;GAGG;AACH,IAAiB,wBAAwB,CAOxC;AAPD,WAAiB,wBAAwB;IACvC,uEAAuE;IAC1D,sCAAa,GAAG,6CAAqC,CAAC;IACnE,wEAAwE;I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zD,yFAAyF;IAC5E,wDAAc,GACzB,+DAAuD,CAAC;AAG5D,CAAC,EATgB,yCAAyC,yDAAzC,yCAAyC,QASzD;AAED,SAAgB,8CAA8C,CAC5D,wCAC0C;IAE1C,OAAO,IAAI,CAAC,SAAS,CACnB,+DAAuD,CAAC,KAAK,CAC3D,wCAAwC,CACzC,CACF,CAAC;AACJ,CAAC;AAED,SAAgB,gDAAgD,CAC9D,UAAkB;IAKlB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CACJ,8DAAsD,CAAC,KAAK,CAC1D,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CACd,EACH,sEAAsE,CACvE,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@polar-sh/sdk",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0",
|
|
4
4
|
"author": "Speakeasy",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -14,8 +14,6 @@
|
|
|
14
14
|
"prepublishOnly": "npm run build"
|
|
15
15
|
},
|
|
16
16
|
"peerDependencies": {
|
|
17
|
-
"react": "^18 || ^19",
|
|
18
|
-
"react-dom": "^18 || ^19",
|
|
19
17
|
"zod": ">= 3"
|
|
20
18
|
},
|
|
21
19
|
"devDependencies": {
|
package/sdk/sdk.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ClientSDK } from "../lib/sdks.js";
|
|
2
2
|
import { Advertisements } from "./advertisements.js";
|
|
3
|
-
import { Articles } from "./articles.js";
|
|
4
3
|
import { Benefits } from "./benefits.js";
|
|
5
4
|
import { CheckoutLinks } from "./checkoutlinks.js";
|
|
6
5
|
import { Checkouts } from "./checkouts.js";
|
|
@@ -28,8 +27,6 @@ export declare class Polar extends ClientSDK {
|
|
|
28
27
|
get organizations(): Organizations;
|
|
29
28
|
private _subscriptions?;
|
|
30
29
|
get subscriptions(): Subscriptions;
|
|
31
|
-
private _articles?;
|
|
32
|
-
get articles(): Articles;
|
|
33
30
|
private _advertisements?;
|
|
34
31
|
get advertisements(): Advertisements;
|
|
35
32
|
private _oauth2?;
|
package/sdk/sdk.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.d.ts","sourceRoot":"","sources":["../src/sdk/sdk.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"sdk.d.ts","sourceRoot":"","sources":["../src/sdk/sdk.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AACjD,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AACnE,OAAO,EAAE,KAAK,EAAE,MAAM,YAAY,CAAC;AACnC,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAC/C,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AACvC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAAE,aAAa,EAAE,MAAM,oB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AAC,CAAc;IACnC,IAAI,WAAW,IAAI,WAAW,CAE7B;IAED,OAAO,CAAC,cAAc,CAAC,CAAgB;IACvC,IAAI,aAAa,IAAI,aAAa,CAEjC;IAED,OAAO,CAAC,aAAa,CAAC,CAAe;IACrC,IAAI,YAAY,IAAI,YAAY,CAE/B;IAED,OAAO,CAAC,UAAU,CAAC,CAAY;IAC/B,IAAI,SAAS,IAAI,SAAS,CAEzB;CACF"}
|
package/sdk/sdk.js
CHANGED
|
@@ -6,7 +6,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
6
|
exports.Polar = void 0;
|
|
7
7
|
const sdks_js_1 = require("../lib/sdks.js");
|
|
8
8
|
const advertisements_js_1 = require("./advertisements.js");
|
|
9
|
-
const articles_js_1 = require("./articles.js");
|
|
10
9
|
const benefits_js_1 = require("./benefits.js");
|
|
11
10
|
const checkoutlinks_js_1 = require("./checkoutlinks.js");
|
|
12
11
|
const checkouts_js_1 = require("./checkouts.js");
|
|
@@ -44,10 +43,6 @@ class Polar extends sdks_js_1.ClientSDK {
|
|
|
44
43
|
var _a;
|
|
45
44
|
return ((_a = this._subscriptions) !== null && _a !== void 0 ? _a : (this._subscriptions = new subscriptions_js_1.Subscriptions(this._options)));
|
|
46
45
|
}
|
|
47
|
-
get articles() {
|
|
48
|
-
var _a;
|
|
49
|
-
return ((_a = this._articles) !== null && _a !== void 0 ? _a : (this._articles = new articles_js_1.Articles(this._options)));
|
|
50
|
-
}
|
|
51
46
|
get advertisements() {
|
|
52
47
|
var _a;
|
|
53
48
|
return ((_a = this._advertisements) !== null && _a !== void 0 ? _a : (this._advertisements = new advertisements_js_1.Advertisements(this._options)));
|
package/sdk/sdk.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sdk.js","sourceRoot":"","sources":["../src/sdk/sdk.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,4CAA2C;AAC3C,2DAAqD;AACrD,+CAAyC;AACzC
|
|
1
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AAY,oCAAjB,IAAI,CAAC,YAAY,GAAK,IAAI,4BAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IAChE,CAAC;IAGD,IAAI,aAAa;;QACf,OAAO,OAAC,IAAI,CAAC,cAAc,oCAAnB,IAAI,CAAC,cAAc,GAAK,IAAI,gCAAa,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IACpE,CAAC;IAGD,IAAI,YAAY;;QACd,OAAO,OAAC,IAAI,CAAC,aAAa,oCAAlB,IAAI,CAAC,aAAa,GAAK,IAAI,8BAAY,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IAClE,CAAC;IAGD,IAAI,SAAS;;QACX,OAAO,OAAC,IAAI,CAAC,UAAU,oCAAf,IAAI,CAAC,UAAU,GAAK,IAAI,wBAAS,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IAC5D,CAAC;CACF;AAvFD,sBAuFC"}
|
package/src/hooks/hooks.ts
CHANGED
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
BeforeCreateRequestHook,
|
|
13
13
|
BeforeRequestContext,
|
|
14
14
|
BeforeRequestHook,
|
|
15
|
+
Hook,
|
|
15
16
|
Hooks,
|
|
16
17
|
SDKInitHook,
|
|
17
18
|
SDKInitOptions,
|
|
@@ -27,6 +28,25 @@ export class SDKHooks implements Hooks {
|
|
|
27
28
|
afterErrorHooks: AfterErrorHook[] = [];
|
|
28
29
|
|
|
29
30
|
constructor() {
|
|
31
|
+
const presetHooks: Array<Hook> = [];
|
|
32
|
+
|
|
33
|
+
for (const hook of presetHooks) {
|
|
34
|
+
if ("sdkInit" in hook) {
|
|
35
|
+
this.registerSDKInitHook(hook);
|
|
36
|
+
}
|
|
37
|
+
if ("beforeCreateRequest" in hook) {
|
|
38
|
+
this.registerBeforeCreateRequestHook(hook);
|
|
39
|
+
}
|
|
40
|
+
if ("beforeRequest" in hook) {
|
|
41
|
+
this.registerBeforeRequestHook(hook);
|
|
42
|
+
}
|
|
43
|
+
if ("afterSuccess" in hook) {
|
|
44
|
+
this.registerAfterSuccessHook(hook);
|
|
45
|
+
}
|
|
46
|
+
if ("afterError" in hook) {
|
|
47
|
+
this.registerAfterErrorHook(hook);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
30
50
|
initHooks(this);
|
|
31
51
|
}
|
|
32
52
|
|
package/src/hooks/types.ts
CHANGED
|
@@ -5,10 +5,12 @@
|
|
|
5
5
|
import { HTTPClient, RequestInput } from "../lib/http.js";
|
|
6
6
|
import { RetryConfig } from "../lib/retries.js";
|
|
7
7
|
import { SecurityState } from "../lib/security.js";
|
|
8
|
+
import { WebhookRecipient } from "../types/webhooks.js";
|
|
8
9
|
|
|
9
10
|
export type HookContext = {
|
|
10
11
|
operationID: string;
|
|
11
12
|
oAuth2Scopes?: string[];
|
|
13
|
+
webhookRecipient?: WebhookRecipient;
|
|
12
14
|
securitySource?: any | (() => Promise<any>);
|
|
13
15
|
retryConfig: RetryConfig;
|
|
14
16
|
resolvedSecurity: SecurityState | null;
|
|
@@ -100,3 +102,10 @@ export interface Hooks {
|
|
|
100
102
|
/** Registers a hook to be used by the SDK for the after error event. */
|
|
101
103
|
registerAfterErrorHook(hook: AfterErrorHook): void;
|
|
102
104
|
}
|
|
105
|
+
|
|
106
|
+
export type Hook =
|
|
107
|
+
| SDKInitHook
|
|
108
|
+
| BeforeCreateRequestHook
|
|
109
|
+
| BeforeRequestHook
|
|
110
|
+
| AfterSuccessHook
|
|
111
|
+
| AfterErrorHook;
|
package/src/lib/config.ts
CHANGED
|
@@ -60,7 +60,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
60
60
|
export const SDK_METADATA = {
|
|
61
61
|
language: "typescript",
|
|
62
62
|
openapiDocVersion: "0.1.0",
|
|
63
|
-
sdkVersion: "0.
|
|
64
|
-
genVersion: "2.
|
|
65
|
-
userAgent: "speakeasy-sdk/typescript 0.
|
|
63
|
+
sdkVersion: "0.18.0",
|
|
64
|
+
genVersion: "2.474.15",
|
|
65
|
+
userAgent: "speakeasy-sdk/typescript 0.18.0 2.474.15 0.1.0 @polar-sh/sdk",
|
|
66
66
|
} as const;
|
|
@@ -12,12 +12,6 @@ import {
|
|
|
12
12
|
BenefitAds$Outbound,
|
|
13
13
|
BenefitAds$outboundSchema,
|
|
14
14
|
} from "./benefitads.js";
|
|
15
|
-
import {
|
|
16
|
-
BenefitArticles,
|
|
17
|
-
BenefitArticles$inboundSchema,
|
|
18
|
-
BenefitArticles$Outbound,
|
|
19
|
-
BenefitArticles$outboundSchema,
|
|
20
|
-
} from "./benefitarticles.js";
|
|
21
15
|
import {
|
|
22
16
|
BenefitCustom,
|
|
23
17
|
BenefitCustom$inboundSchema,
|
|
@@ -50,7 +44,6 @@ import {
|
|
|
50
44
|
} from "./benefitlicensekeys.js";
|
|
51
45
|
|
|
52
46
|
export type Benefit =
|
|
53
|
-
| BenefitArticles
|
|
54
47
|
| BenefitAds
|
|
55
48
|
| BenefitDiscord
|
|
56
49
|
| BenefitGitHubRepository
|
|
@@ -61,7 +54,6 @@ export type Benefit =
|
|
|
61
54
|
/** @internal */
|
|
62
55
|
export const Benefit$inboundSchema: z.ZodType<Benefit, z.ZodTypeDef, unknown> =
|
|
63
56
|
z.union([
|
|
64
|
-
BenefitArticles$inboundSchema,
|
|
65
57
|
BenefitAds$inboundSchema,
|
|
66
58
|
BenefitDiscord$inboundSchema,
|
|
67
59
|
BenefitGitHubRepository$inboundSchema,
|
|
@@ -72,7 +64,6 @@ export const Benefit$inboundSchema: z.ZodType<Benefit, z.ZodTypeDef, unknown> =
|
|
|
72
64
|
|
|
73
65
|
/** @internal */
|
|
74
66
|
export type Benefit$Outbound =
|
|
75
|
-
| BenefitArticles$Outbound
|
|
76
67
|
| BenefitAds$Outbound
|
|
77
68
|
| BenefitDiscord$Outbound
|
|
78
69
|
| BenefitGitHubRepository$Outbound
|
|
@@ -86,7 +77,6 @@ export const Benefit$outboundSchema: z.ZodType<
|
|
|
86
77
|
z.ZodTypeDef,
|
|
87
78
|
Benefit
|
|
88
79
|
> = z.union([
|
|
89
|
-
BenefitArticles$outboundSchema,
|
|
90
80
|
BenefitAds$outboundSchema,
|
|
91
81
|
BenefitDiscord$outboundSchema,
|
|
92
82
|
BenefitGitHubRepository$outboundSchema,
|
|
@@ -27,12 +27,10 @@ import {
|
|
|
27
27
|
Organization$outboundSchema,
|
|
28
28
|
} from "./organization.js";
|
|
29
29
|
|
|
30
|
-
export const
|
|
30
|
+
export const Type = {
|
|
31
31
|
Ads: "ads",
|
|
32
32
|
} as const;
|
|
33
|
-
export type
|
|
34
|
-
typeof BenefitAdsSubscriberType
|
|
35
|
-
>;
|
|
33
|
+
export type Type = ClosedEnum<typeof Type>;
|
|
36
34
|
|
|
37
35
|
export type BenefitAdsSubscriber = {
|
|
38
36
|
/**
|
|
@@ -73,24 +71,23 @@ export type BenefitAdsSubscriber = {
|
|
|
73
71
|
};
|
|
74
72
|
|
|
75
73
|
/** @internal */
|
|
76
|
-
export const
|
|
77
|
-
|
|
78
|
-
|
|
74
|
+
export const Type$inboundSchema: z.ZodNativeEnum<typeof Type> = z.nativeEnum(
|
|
75
|
+
Type,
|
|
76
|
+
);
|
|
79
77
|
|
|
80
78
|
/** @internal */
|
|
81
|
-
export const
|
|
82
|
-
|
|
83
|
-
> = BenefitAdsSubscriberType$inboundSchema;
|
|
79
|
+
export const Type$outboundSchema: z.ZodNativeEnum<typeof Type> =
|
|
80
|
+
Type$inboundSchema;
|
|
84
81
|
|
|
85
82
|
/**
|
|
86
83
|
* @internal
|
|
87
84
|
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
88
85
|
*/
|
|
89
|
-
export namespace
|
|
90
|
-
/** @deprecated use `
|
|
91
|
-
export const inboundSchema =
|
|
92
|
-
/** @deprecated use `
|
|
93
|
-
export const outboundSchema =
|
|
86
|
+
export namespace Type$ {
|
|
87
|
+
/** @deprecated use `Type$inboundSchema` instead. */
|
|
88
|
+
export const inboundSchema = Type$inboundSchema;
|
|
89
|
+
/** @deprecated use `Type$outboundSchema` instead. */
|
|
90
|
+
export const outboundSchema = Type$outboundSchema;
|
|
94
91
|
}
|
|
95
92
|
|
|
96
93
|
/** @internal */
|
|
@@ -13,12 +13,6 @@ import {
|
|
|
13
13
|
BenefitGrantAdsProperties$Outbound,
|
|
14
14
|
BenefitGrantAdsProperties$outboundSchema,
|
|
15
15
|
} from "./benefitgrantadsproperties.js";
|
|
16
|
-
import {
|
|
17
|
-
BenefitGrantArticlesProperties,
|
|
18
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
19
|
-
BenefitGrantArticlesProperties$Outbound,
|
|
20
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
21
|
-
} from "./benefitgrantarticlesproperties.js";
|
|
22
16
|
import {
|
|
23
17
|
BenefitGrantCustomProperties,
|
|
24
18
|
BenefitGrantCustomProperties$inboundSchema,
|
|
@@ -52,7 +46,6 @@ import {
|
|
|
52
46
|
|
|
53
47
|
export type Properties =
|
|
54
48
|
| BenefitGrantCustomProperties
|
|
55
|
-
| BenefitGrantArticlesProperties
|
|
56
49
|
| BenefitGrantDownloadablesProperties
|
|
57
50
|
| BenefitGrantAdsProperties
|
|
58
51
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -106,7 +99,6 @@ export type BenefitGrant = {
|
|
|
106
99
|
benefitId: string;
|
|
107
100
|
properties:
|
|
108
101
|
| BenefitGrantCustomProperties
|
|
109
|
-
| BenefitGrantArticlesProperties
|
|
110
102
|
| BenefitGrantDownloadablesProperties
|
|
111
103
|
| BenefitGrantAdsProperties
|
|
112
104
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -121,7 +113,6 @@ export const Properties$inboundSchema: z.ZodType<
|
|
|
121
113
|
unknown
|
|
122
114
|
> = z.union([
|
|
123
115
|
BenefitGrantCustomProperties$inboundSchema,
|
|
124
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
125
116
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
126
117
|
BenefitGrantAdsProperties$inboundSchema,
|
|
127
118
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -132,7 +123,6 @@ export const Properties$inboundSchema: z.ZodType<
|
|
|
132
123
|
/** @internal */
|
|
133
124
|
export type Properties$Outbound =
|
|
134
125
|
| BenefitGrantCustomProperties$Outbound
|
|
135
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
136
126
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
137
127
|
| BenefitGrantAdsProperties$Outbound
|
|
138
128
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -146,7 +136,6 @@ export const Properties$outboundSchema: z.ZodType<
|
|
|
146
136
|
Properties
|
|
147
137
|
> = z.union([
|
|
148
138
|
BenefitGrantCustomProperties$outboundSchema,
|
|
149
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
150
139
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
151
140
|
BenefitGrantAdsProperties$outboundSchema,
|
|
152
141
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -206,7 +195,6 @@ export const BenefitGrant$inboundSchema: z.ZodType<
|
|
|
206
195
|
benefit_id: z.string(),
|
|
207
196
|
properties: z.union([
|
|
208
197
|
BenefitGrantCustomProperties$inboundSchema,
|
|
209
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
210
198
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
211
199
|
BenefitGrantAdsProperties$inboundSchema,
|
|
212
200
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -243,7 +231,6 @@ export type BenefitGrant$Outbound = {
|
|
|
243
231
|
benefit_id: string;
|
|
244
232
|
properties:
|
|
245
233
|
| BenefitGrantCustomProperties$Outbound
|
|
246
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
247
234
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
248
235
|
| BenefitGrantAdsProperties$Outbound
|
|
249
236
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -270,7 +257,6 @@ export const BenefitGrant$outboundSchema: z.ZodType<
|
|
|
270
257
|
benefitId: z.string(),
|
|
271
258
|
properties: z.union([
|
|
272
259
|
BenefitGrantCustomProperties$outboundSchema,
|
|
273
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
274
260
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
275
261
|
BenefitGrantAdsProperties$outboundSchema,
|
|
276
262
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -19,12 +19,6 @@ import {
|
|
|
19
19
|
BenefitGrantAdsProperties$Outbound,
|
|
20
20
|
BenefitGrantAdsProperties$outboundSchema,
|
|
21
21
|
} from "./benefitgrantadsproperties.js";
|
|
22
|
-
import {
|
|
23
|
-
BenefitGrantArticlesProperties,
|
|
24
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
25
|
-
BenefitGrantArticlesProperties$Outbound,
|
|
26
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
27
|
-
} from "./benefitgrantarticlesproperties.js";
|
|
28
22
|
import {
|
|
29
23
|
BenefitGrantCustomProperties,
|
|
30
24
|
BenefitGrantCustomProperties$inboundSchema,
|
|
@@ -58,7 +52,6 @@ import {
|
|
|
58
52
|
|
|
59
53
|
export type BenefitGrantWebhookProperties =
|
|
60
54
|
| BenefitGrantCustomProperties
|
|
61
|
-
| BenefitGrantArticlesProperties
|
|
62
55
|
| BenefitGrantDownloadablesProperties
|
|
63
56
|
| BenefitGrantAdsProperties
|
|
64
57
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -67,7 +60,6 @@ export type BenefitGrantWebhookProperties =
|
|
|
67
60
|
|
|
68
61
|
export type PreviousProperties =
|
|
69
62
|
| BenefitGrantCustomProperties
|
|
70
|
-
| BenefitGrantArticlesProperties
|
|
71
63
|
| BenefitGrantDownloadablesProperties
|
|
72
64
|
| BenefitGrantAdsProperties
|
|
73
65
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -121,7 +113,6 @@ export type BenefitGrantWebhook = {
|
|
|
121
113
|
benefitId: string;
|
|
122
114
|
properties:
|
|
123
115
|
| BenefitGrantCustomProperties
|
|
124
|
-
| BenefitGrantArticlesProperties
|
|
125
116
|
| BenefitGrantDownloadablesProperties
|
|
126
117
|
| BenefitGrantAdsProperties
|
|
127
118
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -130,7 +121,6 @@ export type BenefitGrantWebhook = {
|
|
|
130
121
|
benefit: Benefit;
|
|
131
122
|
previousProperties?:
|
|
132
123
|
| BenefitGrantCustomProperties
|
|
133
|
-
| BenefitGrantArticlesProperties
|
|
134
124
|
| BenefitGrantDownloadablesProperties
|
|
135
125
|
| BenefitGrantAdsProperties
|
|
136
126
|
| BenefitGrantLicenseKeysProperties
|
|
@@ -147,7 +137,6 @@ export const BenefitGrantWebhookProperties$inboundSchema: z.ZodType<
|
|
|
147
137
|
unknown
|
|
148
138
|
> = z.union([
|
|
149
139
|
BenefitGrantCustomProperties$inboundSchema,
|
|
150
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
151
140
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
152
141
|
BenefitGrantAdsProperties$inboundSchema,
|
|
153
142
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -158,7 +147,6 @@ export const BenefitGrantWebhookProperties$inboundSchema: z.ZodType<
|
|
|
158
147
|
/** @internal */
|
|
159
148
|
export type BenefitGrantWebhookProperties$Outbound =
|
|
160
149
|
| BenefitGrantCustomProperties$Outbound
|
|
161
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
162
150
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
163
151
|
| BenefitGrantAdsProperties$Outbound
|
|
164
152
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -172,7 +160,6 @@ export const BenefitGrantWebhookProperties$outboundSchema: z.ZodType<
|
|
|
172
160
|
BenefitGrantWebhookProperties
|
|
173
161
|
> = z.union([
|
|
174
162
|
BenefitGrantCustomProperties$outboundSchema,
|
|
175
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
176
163
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
177
164
|
BenefitGrantAdsProperties$outboundSchema,
|
|
178
165
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -220,7 +207,6 @@ export const PreviousProperties$inboundSchema: z.ZodType<
|
|
|
220
207
|
unknown
|
|
221
208
|
> = z.union([
|
|
222
209
|
BenefitGrantCustomProperties$inboundSchema,
|
|
223
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
224
210
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
225
211
|
BenefitGrantAdsProperties$inboundSchema,
|
|
226
212
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -231,7 +217,6 @@ export const PreviousProperties$inboundSchema: z.ZodType<
|
|
|
231
217
|
/** @internal */
|
|
232
218
|
export type PreviousProperties$Outbound =
|
|
233
219
|
| BenefitGrantCustomProperties$Outbound
|
|
234
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
235
220
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
236
221
|
| BenefitGrantAdsProperties$Outbound
|
|
237
222
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -245,7 +230,6 @@ export const PreviousProperties$outboundSchema: z.ZodType<
|
|
|
245
230
|
PreviousProperties
|
|
246
231
|
> = z.union([
|
|
247
232
|
BenefitGrantCustomProperties$outboundSchema,
|
|
248
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
249
233
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
250
234
|
BenefitGrantAdsProperties$outboundSchema,
|
|
251
235
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -309,7 +293,6 @@ export const BenefitGrantWebhook$inboundSchema: z.ZodType<
|
|
|
309
293
|
benefit_id: z.string(),
|
|
310
294
|
properties: z.union([
|
|
311
295
|
BenefitGrantCustomProperties$inboundSchema,
|
|
312
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
313
296
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
314
297
|
BenefitGrantAdsProperties$inboundSchema,
|
|
315
298
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -320,7 +303,6 @@ export const BenefitGrantWebhook$inboundSchema: z.ZodType<
|
|
|
320
303
|
previous_properties: z.nullable(
|
|
321
304
|
z.union([
|
|
322
305
|
BenefitGrantCustomProperties$inboundSchema,
|
|
323
|
-
BenefitGrantArticlesProperties$inboundSchema,
|
|
324
306
|
BenefitGrantDownloadablesProperties$inboundSchema,
|
|
325
307
|
BenefitGrantAdsProperties$inboundSchema,
|
|
326
308
|
BenefitGrantLicenseKeysProperties$inboundSchema,
|
|
@@ -359,7 +341,6 @@ export type BenefitGrantWebhook$Outbound = {
|
|
|
359
341
|
benefit_id: string;
|
|
360
342
|
properties:
|
|
361
343
|
| BenefitGrantCustomProperties$Outbound
|
|
362
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
363
344
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
364
345
|
| BenefitGrantAdsProperties$Outbound
|
|
365
346
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -368,7 +349,6 @@ export type BenefitGrantWebhook$Outbound = {
|
|
|
368
349
|
benefit: Benefit$Outbound;
|
|
369
350
|
previous_properties?:
|
|
370
351
|
| BenefitGrantCustomProperties$Outbound
|
|
371
|
-
| BenefitGrantArticlesProperties$Outbound
|
|
372
352
|
| BenefitGrantDownloadablesProperties$Outbound
|
|
373
353
|
| BenefitGrantAdsProperties$Outbound
|
|
374
354
|
| BenefitGrantLicenseKeysProperties$Outbound
|
|
@@ -397,7 +377,6 @@ export const BenefitGrantWebhook$outboundSchema: z.ZodType<
|
|
|
397
377
|
benefitId: z.string(),
|
|
398
378
|
properties: z.union([
|
|
399
379
|
BenefitGrantCustomProperties$outboundSchema,
|
|
400
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
401
380
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
402
381
|
BenefitGrantAdsProperties$outboundSchema,
|
|
403
382
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -408,7 +387,6 @@ export const BenefitGrantWebhook$outboundSchema: z.ZodType<
|
|
|
408
387
|
previousProperties: z.nullable(
|
|
409
388
|
z.union([
|
|
410
389
|
BenefitGrantCustomProperties$outboundSchema,
|
|
411
|
-
BenefitGrantArticlesProperties$outboundSchema,
|
|
412
390
|
BenefitGrantDownloadablesProperties$outboundSchema,
|
|
413
391
|
BenefitGrantAdsProperties$outboundSchema,
|
|
414
392
|
BenefitGrantLicenseKeysProperties$outboundSchema,
|
|
@@ -7,12 +7,6 @@ import { remap as remap$ } from "../../lib/primitives.js";
|
|
|
7
7
|
import { safeParse } from "../../lib/schemas.js";
|
|
8
8
|
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
9
|
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
-
import {
|
|
11
|
-
BenefitArticles,
|
|
12
|
-
BenefitArticles$inboundSchema,
|
|
13
|
-
BenefitArticles$Outbound,
|
|
14
|
-
BenefitArticles$outboundSchema,
|
|
15
|
-
} from "./benefitarticles.js";
|
|
16
10
|
import {
|
|
17
11
|
BenefitBase,
|
|
18
12
|
BenefitBase$inboundSchema,
|
|
@@ -32,8 +26,6 @@ import {
|
|
|
32
26
|
ProductPrice$outboundSchema,
|
|
33
27
|
} from "./productprice.js";
|
|
34
28
|
|
|
35
|
-
export type CheckoutLinkProductBenefits = BenefitBase | BenefitArticles;
|
|
36
|
-
|
|
37
29
|
/**
|
|
38
30
|
* Product data for a checkout link.
|
|
39
31
|
*/
|
|
@@ -77,65 +69,13 @@ export type CheckoutLinkProduct = {
|
|
|
77
69
|
/**
|
|
78
70
|
* List of benefits granted by the product.
|
|
79
71
|
*/
|
|
80
|
-
benefits: Array<BenefitBase
|
|
72
|
+
benefits: Array<BenefitBase>;
|
|
81
73
|
/**
|
|
82
74
|
* List of medias associated to the product.
|
|
83
75
|
*/
|
|
84
76
|
medias: Array<ProductMediaFileRead>;
|
|
85
77
|
};
|
|
86
78
|
|
|
87
|
-
/** @internal */
|
|
88
|
-
export const CheckoutLinkProductBenefits$inboundSchema: z.ZodType<
|
|
89
|
-
CheckoutLinkProductBenefits,
|
|
90
|
-
z.ZodTypeDef,
|
|
91
|
-
unknown
|
|
92
|
-
> = z.union([BenefitBase$inboundSchema, BenefitArticles$inboundSchema]);
|
|
93
|
-
|
|
94
|
-
/** @internal */
|
|
95
|
-
export type CheckoutLinkProductBenefits$Outbound =
|
|
96
|
-
| BenefitBase$Outbound
|
|
97
|
-
| BenefitArticles$Outbound;
|
|
98
|
-
|
|
99
|
-
/** @internal */
|
|
100
|
-
export const CheckoutLinkProductBenefits$outboundSchema: z.ZodType<
|
|
101
|
-
CheckoutLinkProductBenefits$Outbound,
|
|
102
|
-
z.ZodTypeDef,
|
|
103
|
-
CheckoutLinkProductBenefits
|
|
104
|
-
> = z.union([BenefitBase$outboundSchema, BenefitArticles$outboundSchema]);
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* @internal
|
|
108
|
-
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
109
|
-
*/
|
|
110
|
-
export namespace CheckoutLinkProductBenefits$ {
|
|
111
|
-
/** @deprecated use `CheckoutLinkProductBenefits$inboundSchema` instead. */
|
|
112
|
-
export const inboundSchema = CheckoutLinkProductBenefits$inboundSchema;
|
|
113
|
-
/** @deprecated use `CheckoutLinkProductBenefits$outboundSchema` instead. */
|
|
114
|
-
export const outboundSchema = CheckoutLinkProductBenefits$outboundSchema;
|
|
115
|
-
/** @deprecated use `CheckoutLinkProductBenefits$Outbound` instead. */
|
|
116
|
-
export type Outbound = CheckoutLinkProductBenefits$Outbound;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
export function checkoutLinkProductBenefitsToJSON(
|
|
120
|
-
checkoutLinkProductBenefits: CheckoutLinkProductBenefits,
|
|
121
|
-
): string {
|
|
122
|
-
return JSON.stringify(
|
|
123
|
-
CheckoutLinkProductBenefits$outboundSchema.parse(
|
|
124
|
-
checkoutLinkProductBenefits,
|
|
125
|
-
),
|
|
126
|
-
);
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
export function checkoutLinkProductBenefitsFromJSON(
|
|
130
|
-
jsonString: string,
|
|
131
|
-
): SafeParseResult<CheckoutLinkProductBenefits, SDKValidationError> {
|
|
132
|
-
return safeParse(
|
|
133
|
-
jsonString,
|
|
134
|
-
(x) => CheckoutLinkProductBenefits$inboundSchema.parse(JSON.parse(x)),
|
|
135
|
-
`Failed to parse 'CheckoutLinkProductBenefits' from JSON`,
|
|
136
|
-
);
|
|
137
|
-
}
|
|
138
|
-
|
|
139
79
|
/** @internal */
|
|
140
80
|
export const CheckoutLinkProduct$inboundSchema: z.ZodType<
|
|
141
81
|
CheckoutLinkProduct,
|
|
@@ -153,9 +93,7 @@ export const CheckoutLinkProduct$inboundSchema: z.ZodType<
|
|
|
153
93
|
is_archived: z.boolean(),
|
|
154
94
|
organization_id: z.string(),
|
|
155
95
|
prices: z.array(ProductPrice$inboundSchema),
|
|
156
|
-
benefits: z.array(
|
|
157
|
-
z.union([BenefitBase$inboundSchema, BenefitArticles$inboundSchema]),
|
|
158
|
-
),
|
|
96
|
+
benefits: z.array(BenefitBase$inboundSchema),
|
|
159
97
|
medias: z.array(ProductMediaFileRead$inboundSchema),
|
|
160
98
|
}).transform((v) => {
|
|
161
99
|
return remap$(v, {
|
|
@@ -178,7 +116,7 @@ export type CheckoutLinkProduct$Outbound = {
|
|
|
178
116
|
is_archived: boolean;
|
|
179
117
|
organization_id: string;
|
|
180
118
|
prices: Array<ProductPrice$Outbound>;
|
|
181
|
-
benefits: Array<BenefitBase$Outbound
|
|
119
|
+
benefits: Array<BenefitBase$Outbound>;
|
|
182
120
|
medias: Array<ProductMediaFileRead$Outbound>;
|
|
183
121
|
};
|
|
184
122
|
|
|
@@ -197,9 +135,7 @@ export const CheckoutLinkProduct$outboundSchema: z.ZodType<
|
|
|
197
135
|
isArchived: z.boolean(),
|
|
198
136
|
organizationId: z.string(),
|
|
199
137
|
prices: z.array(ProductPrice$outboundSchema),
|
|
200
|
-
benefits: z.array(
|
|
201
|
-
z.union([BenefitBase$outboundSchema, BenefitArticles$outboundSchema]),
|
|
202
|
-
),
|
|
138
|
+
benefits: z.array(BenefitBase$outboundSchema),
|
|
203
139
|
medias: z.array(ProductMediaFileRead$outboundSchema),
|
|
204
140
|
}).transform((v) => {
|
|
205
141
|
return remap$(v, {
|