@moovio/sdk 0.16.3 → 0.16.5
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 +62 -44
- package/bin/mcp-server.js +1897 -591
- package/bin/mcp-server.js.map +41 -12
- package/docs/sdks/products/README.md +592 -0
- package/examples/package-lock.json +1 -1
- package/funcs/productsCreate.d.ts +15 -0
- package/funcs/productsCreate.d.ts.map +1 -0
- package/funcs/productsCreate.js +138 -0
- package/funcs/productsCreate.js.map +1 -0
- package/funcs/productsDisable.d.ts +17 -0
- package/funcs/productsDisable.d.ts.map +1 -0
- package/funcs/productsDisable.js +139 -0
- package/funcs/productsDisable.js.map +1 -0
- package/funcs/productsGet.d.ts +14 -0
- package/funcs/productsGet.d.ts.map +1 -0
- package/funcs/productsGet.js +126 -0
- package/funcs/productsGet.js.map +1 -0
- package/funcs/productsList.d.ts +14 -0
- package/funcs/productsList.d.ts.map +1 -0
- package/funcs/productsList.js +127 -0
- package/funcs/productsList.js.map +1 -0
- package/funcs/productsUpdate.d.ts +15 -0
- package/funcs/productsUpdate.d.ts.map +1 -0
- package/funcs/productsUpdate.js +142 -0
- package/funcs/productsUpdate.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.d.ts.map +1 -1
- package/mcp-server/server.js +11 -1
- package/mcp-server/server.js.map +1 -1
- package/mcp-server/tools/productsCreate.d.ts +8 -0
- package/mcp-server/tools/productsCreate.d.ts.map +1 -0
- package/mcp-server/tools/productsCreate.js +62 -0
- package/mcp-server/tools/productsCreate.js.map +1 -0
- package/mcp-server/tools/productsDisable.d.ts +8 -0
- package/mcp-server/tools/productsDisable.d.ts.map +1 -0
- package/mcp-server/tools/productsDisable.js +63 -0
- package/mcp-server/tools/productsDisable.js.map +1 -0
- package/mcp-server/tools/productsGet.d.ts +8 -0
- package/mcp-server/tools/productsGet.d.ts.map +1 -0
- package/mcp-server/tools/productsGet.js +62 -0
- package/mcp-server/tools/productsGet.js.map +1 -0
- package/mcp-server/tools/productsList.d.ts +8 -0
- package/mcp-server/tools/productsList.d.ts.map +1 -0
- package/mcp-server/tools/productsList.js +62 -0
- package/mcp-server/tools/productsList.js.map +1 -0
- package/mcp-server/tools/productsUpdate.d.ts +8 -0
- package/mcp-server/tools/productsUpdate.d.ts.map +1 -0
- package/mcp-server/tools/productsUpdate.js +62 -0
- package/mcp-server/tools/productsUpdate.js.map +1 -0
- package/models/components/amountdecimalvalidationerror.d.ts +31 -0
- package/models/components/amountdecimalvalidationerror.d.ts.map +1 -0
- package/models/components/amountdecimalvalidationerror.js +71 -0
- package/models/components/amountdecimalvalidationerror.js.map +1 -0
- package/models/components/assignproductimage.d.ts +32 -0
- package/models/components/assignproductimage.d.ts.map +1 -0
- package/models/components/assignproductimage.js +69 -0
- package/models/components/assignproductimage.js.map +1 -0
- package/models/components/assignproductimagevalidationerror.d.ts +29 -0
- package/models/components/assignproductimagevalidationerror.d.ts.map +1 -0
- package/models/components/assignproductimagevalidationerror.js +69 -0
- package/models/components/assignproductimagevalidationerror.js.map +1 -0
- package/models/components/createproductoption.d.ts +54 -0
- package/models/components/createproductoption.d.ts.map +1 -0
- package/models/components/createproductoption.js +76 -0
- package/models/components/createproductoption.js.map +1 -0
- package/models/components/createproductoptiongroup.d.ts +60 -0
- package/models/components/createproductoptiongroup.d.ts.map +1 -0
- package/models/components/createproductoptiongroup.js +78 -0
- package/models/components/createproductoptiongroup.js.map +1 -0
- package/models/components/feeproperties.d.ts +6 -0
- package/models/components/feeproperties.d.ts.map +1 -1
- package/models/components/feeproperties.js +3 -0
- package/models/components/feeproperties.js.map +1 -1
- package/models/components/index.d.ts +13 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +13 -0
- package/models/components/index.js.map +1 -1
- package/models/components/partnerpricing.d.ts +8 -4
- package/models/components/partnerpricing.d.ts.map +1 -1
- package/models/components/partnerpricing.js +2 -2
- package/models/components/partnerpricing.js.map +1 -1
- package/models/components/partnerpricingagreement.d.ts +7 -3
- package/models/components/partnerpricingagreement.d.ts.map +1 -1
- package/models/components/partnerpricingagreement.js +2 -2
- package/models/components/partnerpricingagreement.js.map +1 -1
- package/models/components/product.d.ts +81 -0
- package/models/components/product.d.ts.map +1 -0
- package/models/components/product.js +88 -0
- package/models/components/product.js.map +1 -0
- package/models/components/productimagemetadata.d.ts +42 -0
- package/models/components/productimagemetadata.d.ts.map +1 -0
- package/models/components/productimagemetadata.js +73 -0
- package/models/components/productimagemetadata.js.map +1 -0
- package/models/components/productoption.d.ts +57 -0
- package/models/components/productoption.d.ts.map +1 -0
- package/models/components/productoption.js +76 -0
- package/models/components/productoption.js.map +1 -0
- package/models/components/productoptiongroup.d.ts +63 -0
- package/models/components/productoptiongroup.d.ts.map +1 -0
- package/models/components/productoptiongroup.js +78 -0
- package/models/components/productoptiongroup.js.map +1 -0
- package/models/components/productoptiongroupvalidationerror.d.ts +42 -0
- package/models/components/productoptiongroupvalidationerror.d.ts.map +1 -0
- package/models/components/productoptiongroupvalidationerror.js +78 -0
- package/models/components/productoptiongroupvalidationerror.js.map +1 -0
- package/models/components/productoptionvalidationerror.d.ts +40 -0
- package/models/components/productoptionvalidationerror.d.ts.map +1 -0
- package/models/components/productoptionvalidationerror.js +76 -0
- package/models/components/productoptionvalidationerror.js.map +1 -0
- package/models/components/productrequest.d.ts +61 -0
- package/models/components/productrequest.d.ts.map +1 -0
- package/models/components/productrequest.js +80 -0
- package/models/components/productrequest.js.map +1 -0
- package/models/components/volumerange.d.ts +51 -0
- package/models/components/volumerange.d.ts.map +1 -0
- package/models/components/volumerange.js +76 -0
- package/models/components/volumerange.js.map +1 -0
- package/models/errors/index.d.ts +1 -0
- package/models/errors/index.d.ts.map +1 -1
- package/models/errors/index.js +1 -0
- package/models/errors/index.js.map +1 -1
- package/models/errors/productrequestvalidationerror.d.ts +61 -0
- package/models/errors/productrequestvalidationerror.d.ts.map +1 -0
- package/models/errors/productrequestvalidationerror.js +105 -0
- package/models/errors/productrequestvalidationerror.js.map +1 -0
- package/models/operations/createproduct.d.ts +101 -0
- package/models/operations/createproduct.d.ts.map +1 -0
- package/models/operations/createproduct.js +155 -0
- package/models/operations/createproduct.js.map +1 -0
- package/models/operations/disableproduct.d.ts +98 -0
- package/models/operations/disableproduct.d.ts.map +1 -0
- package/models/operations/disableproduct.js +142 -0
- package/models/operations/disableproduct.js.map +1 -0
- package/models/operations/getproduct.d.ts +101 -0
- package/models/operations/getproduct.d.ts.map +1 -0
- package/models/operations/getproduct.js +147 -0
- package/models/operations/getproduct.js.map +1 -0
- package/models/operations/index.d.ts +5 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +5 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/listproducts.d.ts +103 -0
- package/models/operations/listproducts.d.ts.map +1 -0
- package/models/operations/listproducts.js +149 -0
- package/models/operations/listproducts.js.map +1 -0
- package/models/operations/updateproduct.d.ts +103 -0
- package/models/operations/updateproduct.d.ts.map +1 -0
- package/models/operations/updateproduct.js +157 -0
- package/models/operations/updateproduct.js.map +1 -0
- package/package.json +1 -1
- package/sdk/products.d.ts +27 -0
- package/sdk/products.d.ts.map +1 -0
- package/sdk/products.js +49 -0
- package/sdk/products.js.map +1 -0
- package/sdk/sdk.d.ts +3 -0
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +4 -0
- package/sdk/sdk.js.map +1 -1
- package/src/funcs/productsCreate.ts +200 -0
- package/src/funcs/productsDisable.ts +199 -0
- package/src/funcs/productsGet.ts +182 -0
- package/src/funcs/productsList.ts +182 -0
- package/src/funcs/productsUpdate.ts +206 -0
- package/src/lib/config.ts +2 -2
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +11 -1
- package/src/mcp-server/tools/productsCreate.ts +35 -0
- package/src/mcp-server/tools/productsDisable.ts +35 -0
- package/src/mcp-server/tools/productsGet.ts +35 -0
- package/src/mcp-server/tools/productsList.ts +35 -0
- package/src/mcp-server/tools/productsUpdate.ts +35 -0
- package/src/models/components/amountdecimalvalidationerror.ts +72 -0
- package/src/models/components/assignproductimage.ts +69 -0
- package/src/models/components/assignproductimagevalidationerror.ts +69 -0
- package/src/models/components/createproductoption.ts +102 -0
- package/src/models/components/createproductoptiongroup.ts +110 -0
- package/src/models/components/feeproperties.ts +13 -0
- package/src/models/components/index.ts +13 -0
- package/src/models/components/partnerpricing.ts +10 -6
- package/src/models/components/partnerpricingagreement.ts +9 -5
- package/src/models/components/product.ts +148 -0
- package/src/models/components/productimagemetadata.ts +83 -0
- package/src/models/components/productoption.ts +101 -0
- package/src/models/components/productoptiongroup.ts +113 -0
- package/src/models/components/productoptiongroupvalidationerror.ts +91 -0
- package/src/models/components/productoptionvalidationerror.ts +88 -0
- package/src/models/components/productrequest.ts +117 -0
- package/src/models/components/volumerange.ts +95 -0
- package/src/models/errors/index.ts +1 -0
- package/src/models/errors/productrequestvalidationerror.ts +124 -0
- package/src/models/operations/createproduct.ts +231 -0
- package/src/models/operations/disableproduct.ts +216 -0
- package/src/models/operations/getproduct.ts +223 -0
- package/src/models/operations/index.ts +5 -0
- package/src/models/operations/listproducts.ts +227 -0
- package/src/models/operations/updateproduct.ts +235 -0
- package/src/sdk/products.ts +86 -0
- package/src/sdk/sdk.ts +6 -0
|
@@ -0,0 +1,223 @@
|
|
|
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 { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import * as components from "../components/index.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
|
|
12
|
+
export type GetProductGlobals = {
|
|
13
|
+
/**
|
|
14
|
+
* Specify an API version.
|
|
15
|
+
*
|
|
16
|
+
* @remarks
|
|
17
|
+
*
|
|
18
|
+
* API versioning follows the format `vYYYY.QQ.BB`, where
|
|
19
|
+
* - `YYYY` is the year
|
|
20
|
+
* - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
|
|
21
|
+
* - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
|
|
22
|
+
* - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
|
|
23
|
+
*
|
|
24
|
+
* The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
|
|
25
|
+
*/
|
|
26
|
+
xMoovVersion?: string | undefined;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export type GetProductRequest = {
|
|
30
|
+
accountID: string;
|
|
31
|
+
productID: string;
|
|
32
|
+
};
|
|
33
|
+
|
|
34
|
+
export type GetProductResponse = {
|
|
35
|
+
headers: { [k: string]: Array<string> };
|
|
36
|
+
result: components.Product;
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
/** @internal */
|
|
40
|
+
export const GetProductGlobals$inboundSchema: z.ZodType<
|
|
41
|
+
GetProductGlobals,
|
|
42
|
+
z.ZodTypeDef,
|
|
43
|
+
unknown
|
|
44
|
+
> = z.object({
|
|
45
|
+
"x-moov-version": z.string().default("v2024.01.00"),
|
|
46
|
+
}).transform((v) => {
|
|
47
|
+
return remap$(v, {
|
|
48
|
+
"x-moov-version": "xMoovVersion",
|
|
49
|
+
});
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
/** @internal */
|
|
53
|
+
export type GetProductGlobals$Outbound = {
|
|
54
|
+
"x-moov-version": string;
|
|
55
|
+
};
|
|
56
|
+
|
|
57
|
+
/** @internal */
|
|
58
|
+
export const GetProductGlobals$outboundSchema: z.ZodType<
|
|
59
|
+
GetProductGlobals$Outbound,
|
|
60
|
+
z.ZodTypeDef,
|
|
61
|
+
GetProductGlobals
|
|
62
|
+
> = z.object({
|
|
63
|
+
xMoovVersion: z.string().default("v2024.01.00"),
|
|
64
|
+
}).transform((v) => {
|
|
65
|
+
return remap$(v, {
|
|
66
|
+
xMoovVersion: "x-moov-version",
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* @internal
|
|
72
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
73
|
+
*/
|
|
74
|
+
export namespace GetProductGlobals$ {
|
|
75
|
+
/** @deprecated use `GetProductGlobals$inboundSchema` instead. */
|
|
76
|
+
export const inboundSchema = GetProductGlobals$inboundSchema;
|
|
77
|
+
/** @deprecated use `GetProductGlobals$outboundSchema` instead. */
|
|
78
|
+
export const outboundSchema = GetProductGlobals$outboundSchema;
|
|
79
|
+
/** @deprecated use `GetProductGlobals$Outbound` instead. */
|
|
80
|
+
export type Outbound = GetProductGlobals$Outbound;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
export function getProductGlobalsToJSON(
|
|
84
|
+
getProductGlobals: GetProductGlobals,
|
|
85
|
+
): string {
|
|
86
|
+
return JSON.stringify(
|
|
87
|
+
GetProductGlobals$outboundSchema.parse(getProductGlobals),
|
|
88
|
+
);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
export function getProductGlobalsFromJSON(
|
|
92
|
+
jsonString: string,
|
|
93
|
+
): SafeParseResult<GetProductGlobals, SDKValidationError> {
|
|
94
|
+
return safeParse(
|
|
95
|
+
jsonString,
|
|
96
|
+
(x) => GetProductGlobals$inboundSchema.parse(JSON.parse(x)),
|
|
97
|
+
`Failed to parse 'GetProductGlobals' from JSON`,
|
|
98
|
+
);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
/** @internal */
|
|
102
|
+
export const GetProductRequest$inboundSchema: z.ZodType<
|
|
103
|
+
GetProductRequest,
|
|
104
|
+
z.ZodTypeDef,
|
|
105
|
+
unknown
|
|
106
|
+
> = z.object({
|
|
107
|
+
accountID: z.string(),
|
|
108
|
+
productID: z.string(),
|
|
109
|
+
});
|
|
110
|
+
|
|
111
|
+
/** @internal */
|
|
112
|
+
export type GetProductRequest$Outbound = {
|
|
113
|
+
accountID: string;
|
|
114
|
+
productID: string;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
/** @internal */
|
|
118
|
+
export const GetProductRequest$outboundSchema: z.ZodType<
|
|
119
|
+
GetProductRequest$Outbound,
|
|
120
|
+
z.ZodTypeDef,
|
|
121
|
+
GetProductRequest
|
|
122
|
+
> = z.object({
|
|
123
|
+
accountID: z.string(),
|
|
124
|
+
productID: z.string(),
|
|
125
|
+
});
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* @internal
|
|
129
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
130
|
+
*/
|
|
131
|
+
export namespace GetProductRequest$ {
|
|
132
|
+
/** @deprecated use `GetProductRequest$inboundSchema` instead. */
|
|
133
|
+
export const inboundSchema = GetProductRequest$inboundSchema;
|
|
134
|
+
/** @deprecated use `GetProductRequest$outboundSchema` instead. */
|
|
135
|
+
export const outboundSchema = GetProductRequest$outboundSchema;
|
|
136
|
+
/** @deprecated use `GetProductRequest$Outbound` instead. */
|
|
137
|
+
export type Outbound = GetProductRequest$Outbound;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
export function getProductRequestToJSON(
|
|
141
|
+
getProductRequest: GetProductRequest,
|
|
142
|
+
): string {
|
|
143
|
+
return JSON.stringify(
|
|
144
|
+
GetProductRequest$outboundSchema.parse(getProductRequest),
|
|
145
|
+
);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
export function getProductRequestFromJSON(
|
|
149
|
+
jsonString: string,
|
|
150
|
+
): SafeParseResult<GetProductRequest, SDKValidationError> {
|
|
151
|
+
return safeParse(
|
|
152
|
+
jsonString,
|
|
153
|
+
(x) => GetProductRequest$inboundSchema.parse(JSON.parse(x)),
|
|
154
|
+
`Failed to parse 'GetProductRequest' from JSON`,
|
|
155
|
+
);
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/** @internal */
|
|
159
|
+
export const GetProductResponse$inboundSchema: z.ZodType<
|
|
160
|
+
GetProductResponse,
|
|
161
|
+
z.ZodTypeDef,
|
|
162
|
+
unknown
|
|
163
|
+
> = z.object({
|
|
164
|
+
Headers: z.record(z.array(z.string())),
|
|
165
|
+
Result: components.Product$inboundSchema,
|
|
166
|
+
}).transform((v) => {
|
|
167
|
+
return remap$(v, {
|
|
168
|
+
"Headers": "headers",
|
|
169
|
+
"Result": "result",
|
|
170
|
+
});
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
/** @internal */
|
|
174
|
+
export type GetProductResponse$Outbound = {
|
|
175
|
+
Headers: { [k: string]: Array<string> };
|
|
176
|
+
Result: components.Product$Outbound;
|
|
177
|
+
};
|
|
178
|
+
|
|
179
|
+
/** @internal */
|
|
180
|
+
export const GetProductResponse$outboundSchema: z.ZodType<
|
|
181
|
+
GetProductResponse$Outbound,
|
|
182
|
+
z.ZodTypeDef,
|
|
183
|
+
GetProductResponse
|
|
184
|
+
> = z.object({
|
|
185
|
+
headers: z.record(z.array(z.string())),
|
|
186
|
+
result: components.Product$outboundSchema,
|
|
187
|
+
}).transform((v) => {
|
|
188
|
+
return remap$(v, {
|
|
189
|
+
headers: "Headers",
|
|
190
|
+
result: "Result",
|
|
191
|
+
});
|
|
192
|
+
});
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* @internal
|
|
196
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
197
|
+
*/
|
|
198
|
+
export namespace GetProductResponse$ {
|
|
199
|
+
/** @deprecated use `GetProductResponse$inboundSchema` instead. */
|
|
200
|
+
export const inboundSchema = GetProductResponse$inboundSchema;
|
|
201
|
+
/** @deprecated use `GetProductResponse$outboundSchema` instead. */
|
|
202
|
+
export const outboundSchema = GetProductResponse$outboundSchema;
|
|
203
|
+
/** @deprecated use `GetProductResponse$Outbound` instead. */
|
|
204
|
+
export type Outbound = GetProductResponse$Outbound;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export function getProductResponseToJSON(
|
|
208
|
+
getProductResponse: GetProductResponse,
|
|
209
|
+
): string {
|
|
210
|
+
return JSON.stringify(
|
|
211
|
+
GetProductResponse$outboundSchema.parse(getProductResponse),
|
|
212
|
+
);
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
export function getProductResponseFromJSON(
|
|
216
|
+
jsonString: string,
|
|
217
|
+
): SafeParseResult<GetProductResponse, SDKValidationError> {
|
|
218
|
+
return safeParse(
|
|
219
|
+
jsonString,
|
|
220
|
+
(x) => GetProductResponse$inboundSchema.parse(JSON.parse(x)),
|
|
221
|
+
`Failed to parse 'GetProductResponse' from JSON`,
|
|
222
|
+
);
|
|
223
|
+
}
|
|
@@ -15,6 +15,7 @@ export * from "./createcancellation.js";
|
|
|
15
15
|
export * from "./createfeeplanagreements.js";
|
|
16
16
|
export * from "./createonboardinginvite.js";
|
|
17
17
|
export * from "./createpaymentlink.js";
|
|
18
|
+
export * from "./createproduct.js";
|
|
18
19
|
export * from "./createreceipts.js";
|
|
19
20
|
export * from "./createrepresentative.js";
|
|
20
21
|
export * from "./createreversal.js";
|
|
@@ -34,6 +35,7 @@ export * from "./disablebankaccount.js";
|
|
|
34
35
|
export * from "./disablecapability.js";
|
|
35
36
|
export * from "./disablecard.js";
|
|
36
37
|
export * from "./disablepaymentlink.js";
|
|
38
|
+
export * from "./disableproduct.js";
|
|
37
39
|
export * from "./disconnectaccount.js";
|
|
38
40
|
export * from "./generateendtoendkey.js";
|
|
39
41
|
export * from "./getaccount.js";
|
|
@@ -64,6 +66,7 @@ export * from "./getonboardinginvite.js";
|
|
|
64
66
|
export * from "./getpaymentlink.js";
|
|
65
67
|
export * from "./getpaymentlinkqrcode.js";
|
|
66
68
|
export * from "./getpaymentmethod.js";
|
|
69
|
+
export * from "./getproduct.js";
|
|
67
70
|
export * from "./getpublicimage.js";
|
|
68
71
|
export * from "./getrefund.js";
|
|
69
72
|
export * from "./getrepresentative.js";
|
|
@@ -111,6 +114,7 @@ export * from "./listpartnerpricing.js";
|
|
|
111
114
|
export * from "./listpartnerpricingagreements.js";
|
|
112
115
|
export * from "./listpaymentlinks.js";
|
|
113
116
|
export * from "./listpaymentmethods.js";
|
|
117
|
+
export * from "./listproducts.js";
|
|
114
118
|
export * from "./listreceipts.js";
|
|
115
119
|
export * from "./listrefunds.js";
|
|
116
120
|
export * from "./listrepresentatives.js";
|
|
@@ -142,6 +146,7 @@ export * from "./updatecard.js";
|
|
|
142
146
|
export * from "./updatedisputeevidence.js";
|
|
143
147
|
export * from "./updateissuedcard.js";
|
|
144
148
|
export * from "./updatepaymentlink.js";
|
|
149
|
+
export * from "./updateproduct.js";
|
|
145
150
|
export * from "./updaterepresentative.js";
|
|
146
151
|
export * from "./updateschedule.js";
|
|
147
152
|
export * from "./updatesweepconfig.js";
|
|
@@ -0,0 +1,227 @@
|
|
|
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 { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import * as components from "../components/index.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
|
|
12
|
+
export type ListProductsGlobals = {
|
|
13
|
+
/**
|
|
14
|
+
* Specify an API version.
|
|
15
|
+
*
|
|
16
|
+
* @remarks
|
|
17
|
+
*
|
|
18
|
+
* API versioning follows the format `vYYYY.QQ.BB`, where
|
|
19
|
+
* - `YYYY` is the year
|
|
20
|
+
* - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
|
|
21
|
+
* - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
|
|
22
|
+
* - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
|
|
23
|
+
*
|
|
24
|
+
* The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
|
|
25
|
+
*/
|
|
26
|
+
xMoovVersion?: string | undefined;
|
|
27
|
+
};
|
|
28
|
+
|
|
29
|
+
export type ListProductsRequest = {
|
|
30
|
+
accountID: string;
|
|
31
|
+
skip?: number | undefined;
|
|
32
|
+
count?: number | undefined;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
export type ListProductsResponse = {
|
|
36
|
+
headers: { [k: string]: Array<string> };
|
|
37
|
+
result: Array<components.Product>;
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
/** @internal */
|
|
41
|
+
export const ListProductsGlobals$inboundSchema: z.ZodType<
|
|
42
|
+
ListProductsGlobals,
|
|
43
|
+
z.ZodTypeDef,
|
|
44
|
+
unknown
|
|
45
|
+
> = z.object({
|
|
46
|
+
"x-moov-version": z.string().default("v2024.01.00"),
|
|
47
|
+
}).transform((v) => {
|
|
48
|
+
return remap$(v, {
|
|
49
|
+
"x-moov-version": "xMoovVersion",
|
|
50
|
+
});
|
|
51
|
+
});
|
|
52
|
+
|
|
53
|
+
/** @internal */
|
|
54
|
+
export type ListProductsGlobals$Outbound = {
|
|
55
|
+
"x-moov-version": string;
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
/** @internal */
|
|
59
|
+
export const ListProductsGlobals$outboundSchema: z.ZodType<
|
|
60
|
+
ListProductsGlobals$Outbound,
|
|
61
|
+
z.ZodTypeDef,
|
|
62
|
+
ListProductsGlobals
|
|
63
|
+
> = z.object({
|
|
64
|
+
xMoovVersion: z.string().default("v2024.01.00"),
|
|
65
|
+
}).transform((v) => {
|
|
66
|
+
return remap$(v, {
|
|
67
|
+
xMoovVersion: "x-moov-version",
|
|
68
|
+
});
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* @internal
|
|
73
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
74
|
+
*/
|
|
75
|
+
export namespace ListProductsGlobals$ {
|
|
76
|
+
/** @deprecated use `ListProductsGlobals$inboundSchema` instead. */
|
|
77
|
+
export const inboundSchema = ListProductsGlobals$inboundSchema;
|
|
78
|
+
/** @deprecated use `ListProductsGlobals$outboundSchema` instead. */
|
|
79
|
+
export const outboundSchema = ListProductsGlobals$outboundSchema;
|
|
80
|
+
/** @deprecated use `ListProductsGlobals$Outbound` instead. */
|
|
81
|
+
export type Outbound = ListProductsGlobals$Outbound;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export function listProductsGlobalsToJSON(
|
|
85
|
+
listProductsGlobals: ListProductsGlobals,
|
|
86
|
+
): string {
|
|
87
|
+
return JSON.stringify(
|
|
88
|
+
ListProductsGlobals$outboundSchema.parse(listProductsGlobals),
|
|
89
|
+
);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
export function listProductsGlobalsFromJSON(
|
|
93
|
+
jsonString: string,
|
|
94
|
+
): SafeParseResult<ListProductsGlobals, SDKValidationError> {
|
|
95
|
+
return safeParse(
|
|
96
|
+
jsonString,
|
|
97
|
+
(x) => ListProductsGlobals$inboundSchema.parse(JSON.parse(x)),
|
|
98
|
+
`Failed to parse 'ListProductsGlobals' from JSON`,
|
|
99
|
+
);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/** @internal */
|
|
103
|
+
export const ListProductsRequest$inboundSchema: z.ZodType<
|
|
104
|
+
ListProductsRequest,
|
|
105
|
+
z.ZodTypeDef,
|
|
106
|
+
unknown
|
|
107
|
+
> = z.object({
|
|
108
|
+
accountID: z.string(),
|
|
109
|
+
skip: z.number().int().optional(),
|
|
110
|
+
count: z.number().int().optional(),
|
|
111
|
+
});
|
|
112
|
+
|
|
113
|
+
/** @internal */
|
|
114
|
+
export type ListProductsRequest$Outbound = {
|
|
115
|
+
accountID: string;
|
|
116
|
+
skip?: number | undefined;
|
|
117
|
+
count?: number | undefined;
|
|
118
|
+
};
|
|
119
|
+
|
|
120
|
+
/** @internal */
|
|
121
|
+
export const ListProductsRequest$outboundSchema: z.ZodType<
|
|
122
|
+
ListProductsRequest$Outbound,
|
|
123
|
+
z.ZodTypeDef,
|
|
124
|
+
ListProductsRequest
|
|
125
|
+
> = z.object({
|
|
126
|
+
accountID: z.string(),
|
|
127
|
+
skip: z.number().int().optional(),
|
|
128
|
+
count: z.number().int().optional(),
|
|
129
|
+
});
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* @internal
|
|
133
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
134
|
+
*/
|
|
135
|
+
export namespace ListProductsRequest$ {
|
|
136
|
+
/** @deprecated use `ListProductsRequest$inboundSchema` instead. */
|
|
137
|
+
export const inboundSchema = ListProductsRequest$inboundSchema;
|
|
138
|
+
/** @deprecated use `ListProductsRequest$outboundSchema` instead. */
|
|
139
|
+
export const outboundSchema = ListProductsRequest$outboundSchema;
|
|
140
|
+
/** @deprecated use `ListProductsRequest$Outbound` instead. */
|
|
141
|
+
export type Outbound = ListProductsRequest$Outbound;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
export function listProductsRequestToJSON(
|
|
145
|
+
listProductsRequest: ListProductsRequest,
|
|
146
|
+
): string {
|
|
147
|
+
return JSON.stringify(
|
|
148
|
+
ListProductsRequest$outboundSchema.parse(listProductsRequest),
|
|
149
|
+
);
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
export function listProductsRequestFromJSON(
|
|
153
|
+
jsonString: string,
|
|
154
|
+
): SafeParseResult<ListProductsRequest, SDKValidationError> {
|
|
155
|
+
return safeParse(
|
|
156
|
+
jsonString,
|
|
157
|
+
(x) => ListProductsRequest$inboundSchema.parse(JSON.parse(x)),
|
|
158
|
+
`Failed to parse 'ListProductsRequest' from JSON`,
|
|
159
|
+
);
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
/** @internal */
|
|
163
|
+
export const ListProductsResponse$inboundSchema: z.ZodType<
|
|
164
|
+
ListProductsResponse,
|
|
165
|
+
z.ZodTypeDef,
|
|
166
|
+
unknown
|
|
167
|
+
> = z.object({
|
|
168
|
+
Headers: z.record(z.array(z.string())),
|
|
169
|
+
Result: z.array(components.Product$inboundSchema),
|
|
170
|
+
}).transform((v) => {
|
|
171
|
+
return remap$(v, {
|
|
172
|
+
"Headers": "headers",
|
|
173
|
+
"Result": "result",
|
|
174
|
+
});
|
|
175
|
+
});
|
|
176
|
+
|
|
177
|
+
/** @internal */
|
|
178
|
+
export type ListProductsResponse$Outbound = {
|
|
179
|
+
Headers: { [k: string]: Array<string> };
|
|
180
|
+
Result: Array<components.Product$Outbound>;
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
/** @internal */
|
|
184
|
+
export const ListProductsResponse$outboundSchema: z.ZodType<
|
|
185
|
+
ListProductsResponse$Outbound,
|
|
186
|
+
z.ZodTypeDef,
|
|
187
|
+
ListProductsResponse
|
|
188
|
+
> = z.object({
|
|
189
|
+
headers: z.record(z.array(z.string())),
|
|
190
|
+
result: z.array(components.Product$outboundSchema),
|
|
191
|
+
}).transform((v) => {
|
|
192
|
+
return remap$(v, {
|
|
193
|
+
headers: "Headers",
|
|
194
|
+
result: "Result",
|
|
195
|
+
});
|
|
196
|
+
});
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* @internal
|
|
200
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
201
|
+
*/
|
|
202
|
+
export namespace ListProductsResponse$ {
|
|
203
|
+
/** @deprecated use `ListProductsResponse$inboundSchema` instead. */
|
|
204
|
+
export const inboundSchema = ListProductsResponse$inboundSchema;
|
|
205
|
+
/** @deprecated use `ListProductsResponse$outboundSchema` instead. */
|
|
206
|
+
export const outboundSchema = ListProductsResponse$outboundSchema;
|
|
207
|
+
/** @deprecated use `ListProductsResponse$Outbound` instead. */
|
|
208
|
+
export type Outbound = ListProductsResponse$Outbound;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
export function listProductsResponseToJSON(
|
|
212
|
+
listProductsResponse: ListProductsResponse,
|
|
213
|
+
): string {
|
|
214
|
+
return JSON.stringify(
|
|
215
|
+
ListProductsResponse$outboundSchema.parse(listProductsResponse),
|
|
216
|
+
);
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
export function listProductsResponseFromJSON(
|
|
220
|
+
jsonString: string,
|
|
221
|
+
): SafeParseResult<ListProductsResponse, SDKValidationError> {
|
|
222
|
+
return safeParse(
|
|
223
|
+
jsonString,
|
|
224
|
+
(x) => ListProductsResponse$inboundSchema.parse(JSON.parse(x)),
|
|
225
|
+
`Failed to parse 'ListProductsResponse' from JSON`,
|
|
226
|
+
);
|
|
227
|
+
}
|