mollie-api-typescript 0.3.2 → 0.3.3
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/bin/mcp-server.js +123 -14
- package/bin/mcp-server.js.map +14 -13
- package/dist/commonjs/lib/config.d.ts +3 -3
- package/dist/commonjs/lib/config.js +3 -3
- package/dist/commonjs/lib/config.js.map +1 -1
- package/dist/commonjs/mcp-server/mcp-server.js +1 -1
- package/dist/commonjs/mcp-server/server.js +1 -1
- package/dist/commonjs/models/billingaddress.d.ts +135 -0
- package/dist/commonjs/models/billingaddress.d.ts.map +1 -0
- package/dist/commonjs/models/billingaddress.js +91 -0
- package/dist/commonjs/models/billingaddress.js.map +1 -0
- package/dist/commonjs/models/index.d.ts +1 -0
- package/dist/commonjs/models/index.d.ts.map +1 -1
- package/dist/commonjs/models/index.js +1 -0
- package/dist/commonjs/models/index.js.map +1 -1
- package/dist/commonjs/models/method.d.ts +6 -0
- package/dist/commonjs/models/method.d.ts.map +1 -1
- package/dist/commonjs/models/method.js +2 -0
- package/dist/commonjs/models/method.js.map +1 -1
- package/dist/commonjs/models/methodresponse.d.ts +2 -0
- package/dist/commonjs/models/methodresponse.d.ts.map +1 -1
- package/dist/commonjs/models/methodresponse.js +2 -0
- package/dist/commonjs/models/methodresponse.js.map +1 -1
- package/dist/commonjs/models/operations/updatepayment.d.ts +13 -2
- package/dist/commonjs/models/operations/updatepayment.d.ts.map +1 -1
- package/dist/commonjs/models/operations/updatepayment.js +2 -2
- package/dist/commonjs/models/operations/updatepayment.js.map +1 -1
- package/dist/commonjs/models/paymentmethod.d.ts +2 -0
- package/dist/commonjs/models/paymentmethod.d.ts.map +1 -1
- package/dist/commonjs/models/paymentmethod.js +2 -0
- package/dist/commonjs/models/paymentmethod.js.map +1 -1
- package/dist/commonjs/models/paymentrequest.d.ts +144 -2
- package/dist/commonjs/models/paymentrequest.d.ts.map +1 -1
- package/dist/commonjs/models/paymentrequest.js +54 -3
- package/dist/commonjs/models/paymentrequest.js.map +1 -1
- package/dist/commonjs/models/paymentresponse.d.ts +144 -2
- package/dist/commonjs/models/paymentresponse.d.ts.map +1 -1
- package/dist/commonjs/models/paymentresponse.js +54 -3
- package/dist/commonjs/models/paymentresponse.js.map +1 -1
- package/dist/esm/lib/config.d.ts +3 -3
- package/dist/esm/lib/config.js +3 -3
- package/dist/esm/lib/config.js.map +1 -1
- package/dist/esm/mcp-server/mcp-server.js +1 -1
- package/dist/esm/mcp-server/server.js +1 -1
- package/dist/esm/models/billingaddress.d.ts +135 -0
- package/dist/esm/models/billingaddress.d.ts.map +1 -0
- package/dist/esm/models/billingaddress.js +53 -0
- package/dist/esm/models/billingaddress.js.map +1 -0
- package/dist/esm/models/index.d.ts +1 -0
- package/dist/esm/models/index.d.ts.map +1 -1
- package/dist/esm/models/index.js +1 -0
- package/dist/esm/models/index.js.map +1 -1
- package/dist/esm/models/method.d.ts +6 -0
- package/dist/esm/models/method.d.ts.map +1 -1
- package/dist/esm/models/method.js +2 -0
- package/dist/esm/models/method.js.map +1 -1
- package/dist/esm/models/methodresponse.d.ts +2 -0
- package/dist/esm/models/methodresponse.d.ts.map +1 -1
- package/dist/esm/models/methodresponse.js +2 -0
- package/dist/esm/models/methodresponse.js.map +1 -1
- package/dist/esm/models/operations/updatepayment.d.ts +13 -2
- package/dist/esm/models/operations/updatepayment.d.ts.map +1 -1
- package/dist/esm/models/operations/updatepayment.js +2 -2
- package/dist/esm/models/operations/updatepayment.js.map +1 -1
- package/dist/esm/models/paymentmethod.d.ts +2 -0
- package/dist/esm/models/paymentmethod.d.ts.map +1 -1
- package/dist/esm/models/paymentmethod.js +2 -0
- package/dist/esm/models/paymentmethod.js.map +1 -1
- package/dist/esm/models/paymentrequest.d.ts +144 -2
- package/dist/esm/models/paymentrequest.d.ts.map +1 -1
- package/dist/esm/models/paymentrequest.js +51 -2
- package/dist/esm/models/paymentrequest.js.map +1 -1
- package/dist/esm/models/paymentresponse.d.ts +144 -2
- package/dist/esm/models/paymentresponse.d.ts.map +1 -1
- package/dist/esm/models/paymentresponse.js +51 -2
- package/dist/esm/models/paymentresponse.js.map +1 -1
- package/docs/sdks/customers/README.md +0 -2
- package/docs/sdks/payments/README.md +0 -4
- package/examples/package-lock.json +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/lib/config.ts +3 -3
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +1 -1
- package/src/models/billingaddress.ts +190 -0
- package/src/models/index.ts +1 -0
- package/src/models/method.ts +2 -0
- package/src/models/methodresponse.ts +2 -0
- package/src/models/operations/updatepayment.ts +15 -4
- package/src/models/paymentmethod.ts +2 -0
- package/src/models/paymentrequest.ts +205 -4
- package/src/models/paymentresponse.ts +205 -4
|
@@ -209,6 +209,105 @@ export type PaymentResponseLine = {
|
|
|
209
209
|
recurring?: RecurringLineItem | undefined;
|
|
210
210
|
};
|
|
211
211
|
|
|
212
|
+
/**
|
|
213
|
+
* The customer's billing address details. We advise to provide these details to improve fraud protection and
|
|
214
|
+
*
|
|
215
|
+
* @remarks
|
|
216
|
+
* conversion.
|
|
217
|
+
*
|
|
218
|
+
* Should include `email` or a valid postal address consisting of `streetAndNumber`, `postalCode`, `city` and
|
|
219
|
+
* `country`.
|
|
220
|
+
*
|
|
221
|
+
* Required for payment method `in3`, `klarna`, `billie` and `riverty`.
|
|
222
|
+
*/
|
|
223
|
+
export type PaymentResponseBillingAddress = {
|
|
224
|
+
/**
|
|
225
|
+
* The title of the person, for example *Mr.* or *Mrs.*.
|
|
226
|
+
*/
|
|
227
|
+
title?: string | undefined;
|
|
228
|
+
/**
|
|
229
|
+
* The given name (first name) of the person should be at least two characters and cannot contain only
|
|
230
|
+
*
|
|
231
|
+
* @remarks
|
|
232
|
+
* numbers.
|
|
233
|
+
*
|
|
234
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
235
|
+
*/
|
|
236
|
+
givenName?: string | undefined;
|
|
237
|
+
/**
|
|
238
|
+
* The given family name (surname) of the person should be at least two characters and cannot contain only
|
|
239
|
+
*
|
|
240
|
+
* @remarks
|
|
241
|
+
* numbers.
|
|
242
|
+
*
|
|
243
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
244
|
+
*/
|
|
245
|
+
familyName?: string | undefined;
|
|
246
|
+
/**
|
|
247
|
+
* The name of the organization, in case the addressee is an organization.
|
|
248
|
+
*
|
|
249
|
+
* @remarks
|
|
250
|
+
*
|
|
251
|
+
* Required for payment method `billie`.
|
|
252
|
+
*/
|
|
253
|
+
organizationName?: any | undefined;
|
|
254
|
+
/**
|
|
255
|
+
* A street and street number.
|
|
256
|
+
*
|
|
257
|
+
* @remarks
|
|
258
|
+
*
|
|
259
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
260
|
+
*/
|
|
261
|
+
streetAndNumber?: string | undefined;
|
|
262
|
+
/**
|
|
263
|
+
* Any additional addressing details, for example an apartment number.
|
|
264
|
+
*/
|
|
265
|
+
streetAdditional?: string | undefined;
|
|
266
|
+
/**
|
|
267
|
+
* A postal code. This field may be required if the provided country has a postal code system.
|
|
268
|
+
*
|
|
269
|
+
* @remarks
|
|
270
|
+
*
|
|
271
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
272
|
+
*/
|
|
273
|
+
postalCode?: string | undefined;
|
|
274
|
+
/**
|
|
275
|
+
* A valid e-mail address.
|
|
276
|
+
*
|
|
277
|
+
* @remarks
|
|
278
|
+
*
|
|
279
|
+
* If you provide the email address for a `banktransfer` payment, we will automatically send the instructions
|
|
280
|
+
* email upon payment creation. The language of the email will follow the locale parameter of the payment.
|
|
281
|
+
*
|
|
282
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
283
|
+
*/
|
|
284
|
+
email?: string | undefined;
|
|
285
|
+
/**
|
|
286
|
+
* If provided, it must be in the [E.164](https://en.wikipedia.org/wiki/E.164) format. For example: +31208202070.
|
|
287
|
+
*/
|
|
288
|
+
phone?: string | undefined;
|
|
289
|
+
/**
|
|
290
|
+
* A city name.
|
|
291
|
+
*
|
|
292
|
+
* @remarks
|
|
293
|
+
*
|
|
294
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
295
|
+
*/
|
|
296
|
+
city?: string | undefined;
|
|
297
|
+
/**
|
|
298
|
+
* The top-level administrative subdivision of the country. For example: Noord-Holland.
|
|
299
|
+
*/
|
|
300
|
+
region?: string | undefined;
|
|
301
|
+
/**
|
|
302
|
+
* A country code in [ISO 3166-1 alpha-2](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) format.
|
|
303
|
+
*
|
|
304
|
+
* @remarks
|
|
305
|
+
*
|
|
306
|
+
* Required for payment methods `billie`, `in3`, `klarna` and `riverty`.
|
|
307
|
+
*/
|
|
308
|
+
country?: string | undefined;
|
|
309
|
+
};
|
|
310
|
+
|
|
212
311
|
/**
|
|
213
312
|
* With Mollie Connect you can charge fees on payments that your app is processing on behalf of other Mollie
|
|
214
313
|
*
|
|
@@ -714,7 +813,18 @@ export type PaymentResponse = {
|
|
|
714
813
|
* Required for payment methods `billie`, `in3`, `klarna`, `riverty` and `voucher`.
|
|
715
814
|
*/
|
|
716
815
|
lines?: Array<PaymentResponseLine> | null | undefined;
|
|
717
|
-
|
|
816
|
+
/**
|
|
817
|
+
* The customer's billing address details. We advise to provide these details to improve fraud protection and
|
|
818
|
+
*
|
|
819
|
+
* @remarks
|
|
820
|
+
* conversion.
|
|
821
|
+
*
|
|
822
|
+
* Should include `email` or a valid postal address consisting of `streetAndNumber`, `postalCode`, `city` and
|
|
823
|
+
* `country`.
|
|
824
|
+
*
|
|
825
|
+
* Required for payment method `in3`, `klarna`, `billie` and `riverty`.
|
|
826
|
+
*/
|
|
827
|
+
billingAddress?: PaymentResponseBillingAddress | undefined;
|
|
718
828
|
shippingAddress?: PaymentAddress | undefined;
|
|
719
829
|
/**
|
|
720
830
|
* Allows you to preset the language to be used.
|
|
@@ -1019,6 +1129,95 @@ export function paymentResponseLineFromJSON(
|
|
|
1019
1129
|
);
|
|
1020
1130
|
}
|
|
1021
1131
|
|
|
1132
|
+
/** @internal */
|
|
1133
|
+
export const PaymentResponseBillingAddress$inboundSchema: z.ZodType<
|
|
1134
|
+
PaymentResponseBillingAddress,
|
|
1135
|
+
z.ZodTypeDef,
|
|
1136
|
+
unknown
|
|
1137
|
+
> = z.object({
|
|
1138
|
+
title: z.string().optional(),
|
|
1139
|
+
givenName: z.string().optional(),
|
|
1140
|
+
familyName: z.string().optional(),
|
|
1141
|
+
organizationName: z.any().optional(),
|
|
1142
|
+
streetAndNumber: z.string().optional(),
|
|
1143
|
+
streetAdditional: z.string().optional(),
|
|
1144
|
+
postalCode: z.string().optional(),
|
|
1145
|
+
email: z.string().optional(),
|
|
1146
|
+
phone: z.string().optional(),
|
|
1147
|
+
city: z.string().optional(),
|
|
1148
|
+
region: z.string().optional(),
|
|
1149
|
+
country: z.string().optional(),
|
|
1150
|
+
});
|
|
1151
|
+
|
|
1152
|
+
/** @internal */
|
|
1153
|
+
export type PaymentResponseBillingAddress$Outbound = {
|
|
1154
|
+
title?: string | undefined;
|
|
1155
|
+
givenName?: string | undefined;
|
|
1156
|
+
familyName?: string | undefined;
|
|
1157
|
+
organizationName?: any | undefined;
|
|
1158
|
+
streetAndNumber?: string | undefined;
|
|
1159
|
+
streetAdditional?: string | undefined;
|
|
1160
|
+
postalCode?: string | undefined;
|
|
1161
|
+
email?: string | undefined;
|
|
1162
|
+
phone?: string | undefined;
|
|
1163
|
+
city?: string | undefined;
|
|
1164
|
+
region?: string | undefined;
|
|
1165
|
+
country?: string | undefined;
|
|
1166
|
+
};
|
|
1167
|
+
|
|
1168
|
+
/** @internal */
|
|
1169
|
+
export const PaymentResponseBillingAddress$outboundSchema: z.ZodType<
|
|
1170
|
+
PaymentResponseBillingAddress$Outbound,
|
|
1171
|
+
z.ZodTypeDef,
|
|
1172
|
+
PaymentResponseBillingAddress
|
|
1173
|
+
> = z.object({
|
|
1174
|
+
title: z.string().optional(),
|
|
1175
|
+
givenName: z.string().optional(),
|
|
1176
|
+
familyName: z.string().optional(),
|
|
1177
|
+
organizationName: z.any().optional(),
|
|
1178
|
+
streetAndNumber: z.string().optional(),
|
|
1179
|
+
streetAdditional: z.string().optional(),
|
|
1180
|
+
postalCode: z.string().optional(),
|
|
1181
|
+
email: z.string().optional(),
|
|
1182
|
+
phone: z.string().optional(),
|
|
1183
|
+
city: z.string().optional(),
|
|
1184
|
+
region: z.string().optional(),
|
|
1185
|
+
country: z.string().optional(),
|
|
1186
|
+
});
|
|
1187
|
+
|
|
1188
|
+
/**
|
|
1189
|
+
* @internal
|
|
1190
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
1191
|
+
*/
|
|
1192
|
+
export namespace PaymentResponseBillingAddress$ {
|
|
1193
|
+
/** @deprecated use `PaymentResponseBillingAddress$inboundSchema` instead. */
|
|
1194
|
+
export const inboundSchema = PaymentResponseBillingAddress$inboundSchema;
|
|
1195
|
+
/** @deprecated use `PaymentResponseBillingAddress$outboundSchema` instead. */
|
|
1196
|
+
export const outboundSchema = PaymentResponseBillingAddress$outboundSchema;
|
|
1197
|
+
/** @deprecated use `PaymentResponseBillingAddress$Outbound` instead. */
|
|
1198
|
+
export type Outbound = PaymentResponseBillingAddress$Outbound;
|
|
1199
|
+
}
|
|
1200
|
+
|
|
1201
|
+
export function paymentResponseBillingAddressToJSON(
|
|
1202
|
+
paymentResponseBillingAddress: PaymentResponseBillingAddress,
|
|
1203
|
+
): string {
|
|
1204
|
+
return JSON.stringify(
|
|
1205
|
+
PaymentResponseBillingAddress$outboundSchema.parse(
|
|
1206
|
+
paymentResponseBillingAddress,
|
|
1207
|
+
),
|
|
1208
|
+
);
|
|
1209
|
+
}
|
|
1210
|
+
|
|
1211
|
+
export function paymentResponseBillingAddressFromJSON(
|
|
1212
|
+
jsonString: string,
|
|
1213
|
+
): SafeParseResult<PaymentResponseBillingAddress, SDKValidationError> {
|
|
1214
|
+
return safeParse(
|
|
1215
|
+
jsonString,
|
|
1216
|
+
(x) => PaymentResponseBillingAddress$inboundSchema.parse(JSON.parse(x)),
|
|
1217
|
+
`Failed to parse 'PaymentResponseBillingAddress' from JSON`,
|
|
1218
|
+
);
|
|
1219
|
+
}
|
|
1220
|
+
|
|
1022
1221
|
/** @internal */
|
|
1023
1222
|
export const PaymentResponseApplicationFee$inboundSchema: z.ZodType<
|
|
1024
1223
|
PaymentResponseApplicationFee,
|
|
@@ -1538,7 +1737,8 @@ export const PaymentResponse$inboundSchema: z.ZodType<
|
|
|
1538
1737
|
webhookUrl: z.nullable(z.string()).optional(),
|
|
1539
1738
|
lines: z.nullable(z.array(z.lazy(() => PaymentResponseLine$inboundSchema)))
|
|
1540
1739
|
.optional(),
|
|
1541
|
-
billingAddress:
|
|
1740
|
+
billingAddress: z.lazy(() => PaymentResponseBillingAddress$inboundSchema)
|
|
1741
|
+
.optional(),
|
|
1542
1742
|
shippingAddress: PaymentAddress$inboundSchema.optional(),
|
|
1543
1743
|
locale: z.nullable(LocaleResponse$inboundSchema).optional(),
|
|
1544
1744
|
countryCode: z.nullable(z.string()).optional(),
|
|
@@ -1595,7 +1795,7 @@ export type PaymentResponse$Outbound = {
|
|
|
1595
1795
|
cancelUrl?: string | null | undefined;
|
|
1596
1796
|
webhookUrl?: string | null | undefined;
|
|
1597
1797
|
lines?: Array<PaymentResponseLine$Outbound> | null | undefined;
|
|
1598
|
-
billingAddress?:
|
|
1798
|
+
billingAddress?: PaymentResponseBillingAddress$Outbound | undefined;
|
|
1599
1799
|
shippingAddress?: PaymentAddress$Outbound | undefined;
|
|
1600
1800
|
locale?: string | null | undefined;
|
|
1601
1801
|
countryCode?: string | null | undefined;
|
|
@@ -1649,7 +1849,8 @@ export const PaymentResponse$outboundSchema: z.ZodType<
|
|
|
1649
1849
|
webhookUrl: z.nullable(z.string()).optional(),
|
|
1650
1850
|
lines: z.nullable(z.array(z.lazy(() => PaymentResponseLine$outboundSchema)))
|
|
1651
1851
|
.optional(),
|
|
1652
|
-
billingAddress:
|
|
1852
|
+
billingAddress: z.lazy(() => PaymentResponseBillingAddress$outboundSchema)
|
|
1853
|
+
.optional(),
|
|
1653
1854
|
shippingAddress: PaymentAddress$outboundSchema.optional(),
|
|
1654
1855
|
locale: z.nullable(LocaleResponse$outboundSchema).optional(),
|
|
1655
1856
|
countryCode: z.nullable(z.string()).optional(),
|