@moovio/sdk 26.4.0 → 26.4.2
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 +2 -2
- package/README.md +73 -59
- package/bin/mcp-server.js +1107 -271
- package/bin/mcp-server.js.map +55 -31
- package/funcs/filesUpload.d.ts.map +1 -1
- package/funcs/filesUpload.js +3 -1
- package/funcs/filesUpload.js.map +1 -1
- package/funcs/googlePayLinkToken.d.ts +3 -1
- package/funcs/googlePayLinkToken.d.ts.map +1 -1
- package/funcs/googlePayLinkToken.js +3 -1
- package/funcs/googlePayLinkToken.js.map +1 -1
- package/funcs/transferConfigCreate.d.ts +15 -0
- package/funcs/transferConfigCreate.d.ts.map +1 -0
- package/funcs/transferConfigCreate.js +128 -0
- package/funcs/transferConfigCreate.js.map +1 -0
- package/funcs/transferConfigGet.d.ts +14 -0
- package/funcs/transferConfigGet.d.ts.map +1 -0
- package/funcs/transferConfigGet.js +122 -0
- package/funcs/transferConfigGet.js.map +1 -0
- package/funcs/transferConfigUpdate.d.ts +15 -0
- package/funcs/transferConfigUpdate.d.ts.map +1 -0
- package/funcs/transferConfigUpdate.js +126 -0
- package/funcs/transferConfigUpdate.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/lib/config.js.map +1 -1
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.d.ts.map +1 -1
- package/mcp-server/server.js +7 -1
- package/mcp-server/server.js.map +1 -1
- package/mcp-server/tools/googlePayLinkToken.d.ts.map +1 -1
- package/mcp-server/tools/googlePayLinkToken.js +3 -1
- package/mcp-server/tools/googlePayLinkToken.js.map +1 -1
- package/mcp-server/tools/transferConfigCreate.d.ts +8 -0
- package/mcp-server/tools/transferConfigCreate.d.ts.map +1 -0
- package/mcp-server/tools/transferConfigCreate.js +62 -0
- package/mcp-server/tools/transferConfigCreate.js.map +1 -0
- package/mcp-server/tools/transferConfigGet.d.ts +8 -0
- package/mcp-server/tools/transferConfigGet.d.ts.map +1 -0
- package/mcp-server/tools/transferConfigGet.js +62 -0
- package/mcp-server/tools/transferConfigGet.js.map +1 -0
- package/mcp-server/tools/transferConfigUpdate.d.ts +8 -0
- package/mcp-server/tools/transferConfigUpdate.d.ts.map +1 -0
- package/mcp-server/tools/transferConfigUpdate.js +62 -0
- package/mcp-server/tools/transferConfigUpdate.js.map +1 -0
- package/models/components/createdtransfer.d.ts +4 -1
- package/models/components/createdtransfer.d.ts.map +1 -1
- package/models/components/createdtransfer.js +3 -0
- package/models/components/createdtransfer.js.map +1 -1
- package/models/components/createpaymentlink.d.ts +13 -0
- package/models/components/createpaymentlink.d.ts.map +1 -1
- package/models/components/createpaymentlink.js.map +1 -1
- package/models/components/createtippresets.d.ts +36 -0
- package/models/components/createtippresets.d.ts.map +1 -0
- package/models/components/createtippresets.js +64 -0
- package/models/components/createtippresets.js.map +1 -0
- package/models/components/createtransfer.d.ts +3 -3
- package/models/components/createtransfer.d.ts.map +1 -1
- package/models/components/createtransfer.js +3 -0
- package/models/components/createtransfer.js.map +1 -1
- package/models/components/createtransferamountdetails.d.ts +21 -0
- package/models/components/createtransferamountdetails.d.ts.map +1 -0
- package/models/components/createtransferamountdetails.js +59 -0
- package/models/components/createtransferamountdetails.js.map +1 -0
- package/models/components/createtransferamountdetailsvalidationerror.d.ts +17 -0
- package/models/components/createtransferamountdetailsvalidationerror.d.ts.map +1 -0
- package/models/components/createtransferamountdetailsvalidationerror.js +58 -0
- package/models/components/createtransferamountdetailsvalidationerror.js.map +1 -0
- package/models/components/createtransferconfig.d.ts +18 -0
- package/models/components/createtransferconfig.d.ts.map +1 -0
- package/models/components/{googlepayintermediatesigningkey.js → createtransferconfig.js} +13 -14
- package/models/components/createtransferconfig.js.map +1 -0
- package/models/components/fileuploadmetadata.d.ts +28 -0
- package/models/components/fileuploadmetadata.d.ts.map +1 -0
- package/models/components/fileuploadmetadata.js +69 -0
- package/models/components/fileuploadmetadata.js.map +1 -0
- package/models/components/fileuploadrequestmultipart.d.ts +5 -8
- package/models/components/fileuploadrequestmultipart.d.ts.map +1 -1
- package/models/components/fileuploadrequestmultipart.js +3 -2
- package/models/components/fileuploadrequestmultipart.js.map +1 -1
- package/models/components/googlepayassurancedetails.d.ts +28 -0
- package/models/components/googlepayassurancedetails.d.ts.map +1 -0
- package/models/components/googlepayassurancedetails.js +60 -0
- package/models/components/googlepayassurancedetails.js.map +1 -0
- package/models/components/googlepaybillingaddress.d.ts +73 -0
- package/models/components/googlepaybillingaddress.d.ts.map +1 -0
- package/models/components/googlepaybillingaddress.js +76 -0
- package/models/components/googlepaybillingaddress.js.map +1 -0
- package/models/components/googlepaycardinfo.d.ts +91 -0
- package/models/components/googlepaycardinfo.d.ts.map +1 -0
- package/models/components/googlepaycardinfo.js +98 -0
- package/models/components/googlepaycardinfo.js.map +1 -0
- package/models/components/googlepaypaymentmethoddata.d.ts +65 -0
- package/models/components/googlepaypaymentmethoddata.d.ts.map +1 -0
- package/models/components/googlepaypaymentmethoddata.js +76 -0
- package/models/components/googlepaypaymentmethoddata.js.map +1 -0
- package/models/components/googlepaytokenizationdata.d.ts +47 -0
- package/models/components/googlepaytokenizationdata.d.ts.map +1 -0
- package/models/components/googlepaytokenizationdata.js +70 -0
- package/models/components/googlepaytokenizationdata.js.map +1 -0
- package/models/components/index.d.ts +16 -2
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +16 -2
- package/models/components/index.js.map +1 -1
- package/models/components/linkedgooglepaypaymentmethod.d.ts +5 -10
- package/models/components/linkedgooglepaypaymentmethod.d.ts.map +1 -1
- package/models/components/linkedgooglepaypaymentmethod.js +4 -11
- package/models/components/linkedgooglepaypaymentmethod.js.map +1 -1
- package/models/components/linkgooglepay.d.ts +17 -9
- package/models/components/linkgooglepay.d.ts.map +1 -1
- package/models/components/linkgooglepay.js +5 -3
- package/models/components/linkgooglepay.js.map +1 -1
- package/models/components/paymentlink.d.ts +10 -0
- package/models/components/paymentlink.d.ts.map +1 -1
- package/models/components/paymentlink.js.map +1 -1
- package/models/components/paymentlinkcustomeroptions.d.ts +5 -0
- package/models/components/paymentlinkcustomeroptions.d.ts.map +1 -1
- package/models/components/paymentlinkcustomeroptions.js +2 -0
- package/models/components/paymentlinkcustomeroptions.js.map +1 -1
- package/models/components/puttippresets.d.ts +36 -0
- package/models/components/puttippresets.d.ts.map +1 -0
- package/models/components/puttippresets.js +64 -0
- package/models/components/puttippresets.js.map +1 -0
- package/models/components/puttransferconfig.d.ts +18 -0
- package/models/components/puttransferconfig.d.ts.map +1 -0
- package/models/components/puttransferconfig.js +59 -0
- package/models/components/puttransferconfig.js.map +1 -0
- package/models/components/tipcalculationbasis.d.ts +26 -0
- package/models/components/tipcalculationbasis.d.ts.map +1 -0
- package/models/components/tipcalculationbasis.js +56 -0
- package/models/components/tipcalculationbasis.js.map +1 -0
- package/models/components/tippresets.d.ts +39 -0
- package/models/components/tippresets.d.ts.map +1 -0
- package/models/components/tippresets.js +64 -0
- package/models/components/tippresets.js.map +1 -0
- package/models/components/transfer.d.ts +3 -3
- package/models/components/transfer.d.ts.map +1 -1
- package/models/components/transfer.js +3 -0
- package/models/components/transfer.js.map +1 -1
- package/models/components/transferamountdetails.d.ts +21 -0
- package/models/components/transferamountdetails.d.ts.map +1 -0
- package/models/components/transferamountdetails.js +59 -0
- package/models/components/transferamountdetails.js.map +1 -0
- package/models/components/transferconfig.d.ts +24 -0
- package/models/components/transferconfig.d.ts.map +1 -0
- package/models/components/{googlepaytoken.js → transferconfig.js} +13 -19
- package/models/components/transferconfig.js.map +1 -0
- package/models/components/transferdestination.d.ts +6 -0
- package/models/components/transferdestination.d.ts.map +1 -1
- package/models/components/transferdestination.js +3 -0
- package/models/components/transferdestination.js.map +1 -1
- package/models/components/transfersource.d.ts +6 -0
- package/models/components/transfersource.d.ts.map +1 -1
- package/models/components/transfersource.js +3 -0
- package/models/components/transfersource.js.map +1 -1
- package/models/components/webhookdata.d.ts +2 -2
- package/models/components/webhookdata.d.ts.map +1 -1
- package/models/components/webhookdata.js +2 -2
- package/models/components/webhookdata.js.map +1 -1
- package/models/components/webhookdatabankaccountcreated.d.ts +3 -0
- package/models/components/webhookdatabankaccountcreated.d.ts.map +1 -1
- package/models/components/webhookdatabankaccountcreated.js +3 -0
- package/models/components/webhookdatabankaccountcreated.js.map +1 -1
- 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/linkgooglepayerror.d.ts +14 -5
- package/models/errors/linkgooglepayerror.d.ts.map +1 -1
- package/models/errors/linkgooglepayerror.js +10 -4
- package/models/errors/linkgooglepayerror.js.map +1 -1
- package/models/errors/transfer.d.ts +3 -6
- package/models/errors/transfer.d.ts.map +1 -1
- package/models/errors/transfer.js +4 -0
- package/models/errors/transfer.js.map +1 -1
- package/models/errors/transferconfigvalidationerror.d.ts +43 -0
- package/models/errors/transferconfigvalidationerror.d.ts.map +1 -0
- package/models/errors/transferconfigvalidationerror.js +99 -0
- package/models/errors/transferconfigvalidationerror.js.map +1 -0
- package/models/errors/transfervalidationerror.d.ts +3 -0
- package/models/errors/transfervalidationerror.d.ts.map +1 -1
- package/models/errors/transfervalidationerror.js +6 -0
- package/models/errors/transfervalidationerror.js.map +1 -1
- package/models/operations/createtransferconfig.d.ts +42 -0
- package/models/operations/createtransferconfig.d.ts.map +1 -0
- package/models/operations/createtransferconfig.js +98 -0
- package/models/operations/createtransferconfig.js.map +1 -0
- package/models/operations/gettransferconfig.d.ts +37 -0
- package/models/operations/gettransferconfig.d.ts.map +1 -0
- package/models/operations/gettransferconfig.js +88 -0
- package/models/operations/gettransferconfig.js.map +1 -0
- package/models/operations/index.d.ts +3 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +3 -0
- package/models/operations/index.js.map +1 -1
- package/models/operations/updatetransferconfig.d.ts +39 -0
- package/models/operations/updatetransferconfig.d.ts.map +1 -0
- package/models/operations/updatetransferconfig.js +98 -0
- package/models/operations/updatetransferconfig.js.map +1 -0
- package/package.json +1 -1
- package/sdk/googlepay.d.ts +3 -1
- package/sdk/googlepay.d.ts.map +1 -1
- package/sdk/googlepay.js +3 -1
- package/sdk/googlepay.js.map +1 -1
- 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/sdk/transferconfig.d.ts +17 -0
- package/sdk/transferconfig.d.ts.map +1 -0
- package/sdk/transferconfig.js +33 -0
- package/sdk/transferconfig.js.map +1 -0
- package/src/funcs/filesUpload.ts +13 -2
- package/src/funcs/googlePayLinkToken.ts +3 -1
- package/src/funcs/transferConfigCreate.ts +187 -0
- package/src/funcs/transferConfigGet.ts +172 -0
- package/src/funcs/transferConfigUpdate.ts +185 -0
- package/src/lib/config.ts +3 -3
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +7 -1
- package/src/mcp-server/tools/googlePayLinkToken.ts +3 -1
- package/src/mcp-server/tools/transferConfigCreate.ts +35 -0
- package/src/mcp-server/tools/transferConfigGet.ts +35 -0
- package/src/mcp-server/tools/transferConfigUpdate.ts +35 -0
- package/src/models/components/createdtransfer.ts +11 -1
- package/src/models/components/createpaymentlink.ts +13 -0
- package/src/models/components/createtippresets.ts +83 -0
- package/src/models/components/createtransfer.ts +10 -3
- package/src/models/components/createtransferamountdetails.ts +62 -0
- package/src/models/components/createtransferamountdetailsvalidationerror.ts +59 -0
- package/src/models/components/createtransferconfig.ts +57 -0
- package/src/models/components/fileuploadmetadata.ts +73 -0
- package/src/models/components/fileuploadrequestmultipart.ts +12 -10
- package/src/models/components/googlepayassurancedetails.ts +64 -0
- package/src/models/components/googlepaybillingaddress.ts +125 -0
- package/src/models/components/googlepaycardinfo.ts +153 -0
- package/src/models/components/googlepaypaymentmethoddata.ts +120 -0
- package/src/models/components/googlepaytokenizationdata.ts +91 -0
- package/src/models/components/index.ts +16 -2
- package/src/models/components/linkedgooglepaypaymentmethod.ts +11 -22
- package/src/models/components/linkgooglepay.ts +25 -15
- package/src/models/components/paymentlink.ts +10 -0
- package/src/models/components/paymentlinkcustomeroptions.ts +7 -0
- package/src/models/components/puttippresets.ts +79 -0
- package/src/models/components/puttransferconfig.ts +57 -0
- package/src/models/components/tipcalculationbasis.ts +35 -0
- package/src/models/components/tippresets.ts +82 -0
- package/src/models/components/transfer.ts +10 -3
- package/src/models/components/transferamountdetails.ts +60 -0
- package/src/models/components/transferconfig.ts +59 -0
- package/src/models/components/transferdestination.ts +13 -0
- package/src/models/components/transfersource.ts +13 -0
- package/src/models/components/webhookdata.ts +4 -4
- package/src/models/components/webhookdatabankaccountcreated.ts +9 -0
- package/src/models/errors/index.ts +1 -0
- package/src/models/errors/linkgooglepayerror.ts +24 -8
- package/src/models/errors/transfer.ts +6 -6
- package/src/models/errors/transferconfigvalidationerror.ts +110 -0
- package/src/models/errors/transfervalidationerror.ts +14 -0
- package/src/models/operations/createtransferconfig.ts +129 -0
- package/src/models/operations/gettransferconfig.ts +110 -0
- package/src/models/operations/index.ts +3 -0
- package/src/models/operations/updatetransferconfig.ts +126 -0
- package/src/sdk/googlepay.ts +3 -1
- package/src/sdk/sdk.ts +6 -0
- package/src/sdk/transferconfig.ts +54 -0
- package/models/components/googlepayintermediatesigningkey.d.ts +0 -28
- package/models/components/googlepayintermediatesigningkey.d.ts.map +0 -1
- package/models/components/googlepayintermediatesigningkey.js.map +0 -1
- package/models/components/googlepaytoken.d.ts +0 -44
- package/models/components/googlepaytoken.d.ts.map +0 -1
- package/models/components/googlepaytoken.js.map +0 -1
- package/src/models/components/googlepayintermediatesigningkey.ts +0 -66
- package/src/models/components/googlepaytoken.ts +0 -85
|
@@ -12,6 +12,12 @@ import {
|
|
|
12
12
|
Amount$Outbound,
|
|
13
13
|
Amount$outboundSchema,
|
|
14
14
|
} from "./amount.js";
|
|
15
|
+
import {
|
|
16
|
+
CreateTransferAmountDetails,
|
|
17
|
+
CreateTransferAmountDetails$inboundSchema,
|
|
18
|
+
CreateTransferAmountDetails$Outbound,
|
|
19
|
+
CreateTransferAmountDetails$outboundSchema,
|
|
20
|
+
} from "./createtransferamountdetails.js";
|
|
15
21
|
import {
|
|
16
22
|
CreateTransferDestination,
|
|
17
23
|
CreateTransferDestination$inboundSchema,
|
|
@@ -59,9 +65,6 @@ export type CreateTransfer = {
|
|
|
59
65
|
* Free-form key-value pair list. Useful for storing information that is not captured elsewhere.
|
|
60
66
|
*/
|
|
61
67
|
metadata?: { [k: string]: string } | undefined;
|
|
62
|
-
/**
|
|
63
|
-
* Optional sales tax amount. `transfer.amount.value` should be inclusive of any sales tax and represents the total amount charged.
|
|
64
|
-
*/
|
|
65
68
|
salesTaxAmount?: Amount | undefined;
|
|
66
69
|
/**
|
|
67
70
|
* Optional alias from a foreign/external system which can be used to reference this resource.
|
|
@@ -74,6 +77,7 @@ export type CreateTransfer = {
|
|
|
74
77
|
* When line items are provided, their total plus sales tax must equal the transfer amount.
|
|
75
78
|
*/
|
|
76
79
|
lineItems?: CreateTransferLineItems | undefined;
|
|
80
|
+
amountDetails?: CreateTransferAmountDetails | undefined;
|
|
77
81
|
};
|
|
78
82
|
|
|
79
83
|
/** @internal */
|
|
@@ -91,6 +95,7 @@ export const CreateTransfer$inboundSchema: z.ZodType<
|
|
|
91
95
|
salesTaxAmount: Amount$inboundSchema.optional(),
|
|
92
96
|
foreignID: z.string().optional(),
|
|
93
97
|
lineItems: CreateTransferLineItems$inboundSchema.optional(),
|
|
98
|
+
amountDetails: CreateTransferAmountDetails$inboundSchema.optional(),
|
|
94
99
|
});
|
|
95
100
|
/** @internal */
|
|
96
101
|
export type CreateTransfer$Outbound = {
|
|
@@ -103,6 +108,7 @@ export type CreateTransfer$Outbound = {
|
|
|
103
108
|
salesTaxAmount?: Amount$Outbound | undefined;
|
|
104
109
|
foreignID?: string | undefined;
|
|
105
110
|
lineItems?: CreateTransferLineItems$Outbound | undefined;
|
|
111
|
+
amountDetails?: CreateTransferAmountDetails$Outbound | undefined;
|
|
106
112
|
};
|
|
107
113
|
|
|
108
114
|
/** @internal */
|
|
@@ -120,6 +126,7 @@ export const CreateTransfer$outboundSchema: z.ZodType<
|
|
|
120
126
|
salesTaxAmount: Amount$outboundSchema.optional(),
|
|
121
127
|
foreignID: z.string().optional(),
|
|
122
128
|
lineItems: CreateTransferLineItems$outboundSchema.optional(),
|
|
129
|
+
amountDetails: CreateTransferAmountDetails$outboundSchema.optional(),
|
|
123
130
|
});
|
|
124
131
|
|
|
125
132
|
export function createTransferToJSON(createTransfer: CreateTransfer): string {
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import {
|
|
10
|
+
AmountDecimal,
|
|
11
|
+
AmountDecimal$inboundSchema,
|
|
12
|
+
AmountDecimal$Outbound,
|
|
13
|
+
AmountDecimal$outboundSchema,
|
|
14
|
+
} from "./amountdecimal.js";
|
|
15
|
+
|
|
16
|
+
export type CreateTransferAmountDetails = {
|
|
17
|
+
/**
|
|
18
|
+
* The amount of tip applied to the transfer.
|
|
19
|
+
*/
|
|
20
|
+
tip?: AmountDecimal | undefined;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
/** @internal */
|
|
24
|
+
export const CreateTransferAmountDetails$inboundSchema: z.ZodType<
|
|
25
|
+
CreateTransferAmountDetails,
|
|
26
|
+
z.ZodTypeDef,
|
|
27
|
+
unknown
|
|
28
|
+
> = z.object({
|
|
29
|
+
tip: AmountDecimal$inboundSchema.optional(),
|
|
30
|
+
});
|
|
31
|
+
/** @internal */
|
|
32
|
+
export type CreateTransferAmountDetails$Outbound = {
|
|
33
|
+
tip?: AmountDecimal$Outbound | undefined;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
/** @internal */
|
|
37
|
+
export const CreateTransferAmountDetails$outboundSchema: z.ZodType<
|
|
38
|
+
CreateTransferAmountDetails$Outbound,
|
|
39
|
+
z.ZodTypeDef,
|
|
40
|
+
CreateTransferAmountDetails
|
|
41
|
+
> = z.object({
|
|
42
|
+
tip: AmountDecimal$outboundSchema.optional(),
|
|
43
|
+
});
|
|
44
|
+
|
|
45
|
+
export function createTransferAmountDetailsToJSON(
|
|
46
|
+
createTransferAmountDetails: CreateTransferAmountDetails,
|
|
47
|
+
): string {
|
|
48
|
+
return JSON.stringify(
|
|
49
|
+
CreateTransferAmountDetails$outboundSchema.parse(
|
|
50
|
+
createTransferAmountDetails,
|
|
51
|
+
),
|
|
52
|
+
);
|
|
53
|
+
}
|
|
54
|
+
export function createTransferAmountDetailsFromJSON(
|
|
55
|
+
jsonString: string,
|
|
56
|
+
): SafeParseResult<CreateTransferAmountDetails, SDKValidationError> {
|
|
57
|
+
return safeParse(
|
|
58
|
+
jsonString,
|
|
59
|
+
(x) => CreateTransferAmountDetails$inboundSchema.parse(JSON.parse(x)),
|
|
60
|
+
`Failed to parse 'CreateTransferAmountDetails' from JSON`,
|
|
61
|
+
);
|
|
62
|
+
}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
export type CreateTransferAmountDetailsValidationError = {
|
|
11
|
+
tip?: string | undefined;
|
|
12
|
+
};
|
|
13
|
+
|
|
14
|
+
/** @internal */
|
|
15
|
+
export const CreateTransferAmountDetailsValidationError$inboundSchema:
|
|
16
|
+
z.ZodType<CreateTransferAmountDetailsValidationError, z.ZodTypeDef, unknown> =
|
|
17
|
+
z.object({
|
|
18
|
+
tip: z.string().optional(),
|
|
19
|
+
});
|
|
20
|
+
/** @internal */
|
|
21
|
+
export type CreateTransferAmountDetailsValidationError$Outbound = {
|
|
22
|
+
tip?: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/** @internal */
|
|
26
|
+
export const CreateTransferAmountDetailsValidationError$outboundSchema:
|
|
27
|
+
z.ZodType<
|
|
28
|
+
CreateTransferAmountDetailsValidationError$Outbound,
|
|
29
|
+
z.ZodTypeDef,
|
|
30
|
+
CreateTransferAmountDetailsValidationError
|
|
31
|
+
> = z.object({
|
|
32
|
+
tip: z.string().optional(),
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
export function createTransferAmountDetailsValidationErrorToJSON(
|
|
36
|
+
createTransferAmountDetailsValidationError:
|
|
37
|
+
CreateTransferAmountDetailsValidationError,
|
|
38
|
+
): string {
|
|
39
|
+
return JSON.stringify(
|
|
40
|
+
CreateTransferAmountDetailsValidationError$outboundSchema.parse(
|
|
41
|
+
createTransferAmountDetailsValidationError,
|
|
42
|
+
),
|
|
43
|
+
);
|
|
44
|
+
}
|
|
45
|
+
export function createTransferAmountDetailsValidationErrorFromJSON(
|
|
46
|
+
jsonString: string,
|
|
47
|
+
): SafeParseResult<
|
|
48
|
+
CreateTransferAmountDetailsValidationError,
|
|
49
|
+
SDKValidationError
|
|
50
|
+
> {
|
|
51
|
+
return safeParse(
|
|
52
|
+
jsonString,
|
|
53
|
+
(x) =>
|
|
54
|
+
CreateTransferAmountDetailsValidationError$inboundSchema.parse(
|
|
55
|
+
JSON.parse(x),
|
|
56
|
+
),
|
|
57
|
+
`Failed to parse 'CreateTransferAmountDetailsValidationError' from JSON`,
|
|
58
|
+
);
|
|
59
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
import {
|
|
10
|
+
CreateTipPresets,
|
|
11
|
+
CreateTipPresets$inboundSchema,
|
|
12
|
+
CreateTipPresets$Outbound,
|
|
13
|
+
CreateTipPresets$outboundSchema,
|
|
14
|
+
} from "./createtippresets.js";
|
|
15
|
+
|
|
16
|
+
export type CreateTransferConfig = {
|
|
17
|
+
tipPresets?: CreateTipPresets | undefined;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/** @internal */
|
|
21
|
+
export const CreateTransferConfig$inboundSchema: z.ZodType<
|
|
22
|
+
CreateTransferConfig,
|
|
23
|
+
z.ZodTypeDef,
|
|
24
|
+
unknown
|
|
25
|
+
> = z.object({
|
|
26
|
+
tipPresets: CreateTipPresets$inboundSchema.optional(),
|
|
27
|
+
});
|
|
28
|
+
/** @internal */
|
|
29
|
+
export type CreateTransferConfig$Outbound = {
|
|
30
|
+
tipPresets?: CreateTipPresets$Outbound | undefined;
|
|
31
|
+
};
|
|
32
|
+
|
|
33
|
+
/** @internal */
|
|
34
|
+
export const CreateTransferConfig$outboundSchema: z.ZodType<
|
|
35
|
+
CreateTransferConfig$Outbound,
|
|
36
|
+
z.ZodTypeDef,
|
|
37
|
+
CreateTransferConfig
|
|
38
|
+
> = z.object({
|
|
39
|
+
tipPresets: CreateTipPresets$outboundSchema.optional(),
|
|
40
|
+
});
|
|
41
|
+
|
|
42
|
+
export function createTransferConfigToJSON(
|
|
43
|
+
createTransferConfig: CreateTransferConfig,
|
|
44
|
+
): string {
|
|
45
|
+
return JSON.stringify(
|
|
46
|
+
CreateTransferConfig$outboundSchema.parse(createTransferConfig),
|
|
47
|
+
);
|
|
48
|
+
}
|
|
49
|
+
export function createTransferConfigFromJSON(
|
|
50
|
+
jsonString: string,
|
|
51
|
+
): SafeParseResult<CreateTransferConfig, SDKValidationError> {
|
|
52
|
+
return safeParse(
|
|
53
|
+
jsonString,
|
|
54
|
+
(x) => CreateTransferConfig$inboundSchema.parse(JSON.parse(x)),
|
|
55
|
+
`Failed to parse 'CreateTransferConfig' from JSON`,
|
|
56
|
+
);
|
|
57
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
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 { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Additional metadata to be stored with the file.
|
|
13
|
+
*/
|
|
14
|
+
export type FileUploadMetadata = {
|
|
15
|
+
/**
|
|
16
|
+
* The representative ID that the file is for. Required when filePurpose is `representativeVerification`.
|
|
17
|
+
*/
|
|
18
|
+
representativeId?: string | undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Comments or notes about the file.
|
|
21
|
+
*/
|
|
22
|
+
comment?: string | undefined;
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/** @internal */
|
|
26
|
+
export const FileUploadMetadata$inboundSchema: z.ZodType<
|
|
27
|
+
FileUploadMetadata,
|
|
28
|
+
z.ZodTypeDef,
|
|
29
|
+
unknown
|
|
30
|
+
> = z.object({
|
|
31
|
+
representative_id: z.string().optional(),
|
|
32
|
+
comment: z.string().optional(),
|
|
33
|
+
}).transform((v) => {
|
|
34
|
+
return remap$(v, {
|
|
35
|
+
"representative_id": "representativeId",
|
|
36
|
+
});
|
|
37
|
+
});
|
|
38
|
+
/** @internal */
|
|
39
|
+
export type FileUploadMetadata$Outbound = {
|
|
40
|
+
representative_id?: string | undefined;
|
|
41
|
+
comment?: string | undefined;
|
|
42
|
+
};
|
|
43
|
+
|
|
44
|
+
/** @internal */
|
|
45
|
+
export const FileUploadMetadata$outboundSchema: z.ZodType<
|
|
46
|
+
FileUploadMetadata$Outbound,
|
|
47
|
+
z.ZodTypeDef,
|
|
48
|
+
FileUploadMetadata
|
|
49
|
+
> = z.object({
|
|
50
|
+
representativeId: z.string().optional(),
|
|
51
|
+
comment: z.string().optional(),
|
|
52
|
+
}).transform((v) => {
|
|
53
|
+
return remap$(v, {
|
|
54
|
+
representativeId: "representative_id",
|
|
55
|
+
});
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
export function fileUploadMetadataToJSON(
|
|
59
|
+
fileUploadMetadata: FileUploadMetadata,
|
|
60
|
+
): string {
|
|
61
|
+
return JSON.stringify(
|
|
62
|
+
FileUploadMetadata$outboundSchema.parse(fileUploadMetadata),
|
|
63
|
+
);
|
|
64
|
+
}
|
|
65
|
+
export function fileUploadMetadataFromJSON(
|
|
66
|
+
jsonString: string,
|
|
67
|
+
): SafeParseResult<FileUploadMetadata, SDKValidationError> {
|
|
68
|
+
return safeParse(
|
|
69
|
+
jsonString,
|
|
70
|
+
(x) => FileUploadMetadata$inboundSchema.parse(JSON.parse(x)),
|
|
71
|
+
`Failed to parse 'FileUploadMetadata' from JSON`,
|
|
72
|
+
);
|
|
73
|
+
}
|
|
@@ -12,6 +12,12 @@ import {
|
|
|
12
12
|
FilePurpose$inboundSchema,
|
|
13
13
|
FilePurpose$outboundSchema,
|
|
14
14
|
} from "./filepurpose.js";
|
|
15
|
+
import {
|
|
16
|
+
FileUploadMetadata,
|
|
17
|
+
FileUploadMetadata$inboundSchema,
|
|
18
|
+
FileUploadMetadata$Outbound,
|
|
19
|
+
FileUploadMetadata$outboundSchema,
|
|
20
|
+
} from "./fileuploadmetadata.js";
|
|
15
21
|
|
|
16
22
|
export type FileUploadRequestMultiPartFile = {
|
|
17
23
|
fileName: string;
|
|
@@ -20,7 +26,7 @@ export type FileUploadRequestMultiPartFile = {
|
|
|
20
26
|
|
|
21
27
|
export type FileUploadRequestMultiPart = {
|
|
22
28
|
/**
|
|
23
|
-
* The file to
|
|
29
|
+
* The file to upload. Valid types are `csv`, `png`, `jpeg`, `pdf`.
|
|
24
30
|
*/
|
|
25
31
|
file: FileUploadRequestMultiPartFile | Blob;
|
|
26
32
|
/**
|
|
@@ -28,13 +34,9 @@ export type FileUploadRequestMultiPart = {
|
|
|
28
34
|
*/
|
|
29
35
|
filePurpose: FilePurpose;
|
|
30
36
|
/**
|
|
31
|
-
* Additional metadata to be stored with the file
|
|
32
|
-
*
|
|
33
|
-
* @remarks
|
|
34
|
-
*
|
|
35
|
-
* Valid keys are `representative_id`, `comment`, `requirement_id`, `error_code`.
|
|
37
|
+
* Additional metadata to be stored with the file.
|
|
36
38
|
*/
|
|
37
|
-
metadata?:
|
|
39
|
+
metadata?: FileUploadMetadata | undefined;
|
|
38
40
|
};
|
|
39
41
|
|
|
40
42
|
/** @internal */
|
|
@@ -99,13 +101,13 @@ export const FileUploadRequestMultiPart$inboundSchema: z.ZodType<
|
|
|
99
101
|
> = z.object({
|
|
100
102
|
file: z.lazy(() => FileUploadRequestMultiPartFile$inboundSchema),
|
|
101
103
|
filePurpose: FilePurpose$inboundSchema,
|
|
102
|
-
metadata:
|
|
104
|
+
metadata: FileUploadMetadata$inboundSchema.optional(),
|
|
103
105
|
});
|
|
104
106
|
/** @internal */
|
|
105
107
|
export type FileUploadRequestMultiPart$Outbound = {
|
|
106
108
|
file: FileUploadRequestMultiPartFile$Outbound | Blob;
|
|
107
109
|
filePurpose: string;
|
|
108
|
-
metadata?:
|
|
110
|
+
metadata?: FileUploadMetadata$Outbound | undefined;
|
|
109
111
|
};
|
|
110
112
|
|
|
111
113
|
/** @internal */
|
|
@@ -118,7 +120,7 @@ export const FileUploadRequestMultiPart$outboundSchema: z.ZodType<
|
|
|
118
120
|
blobLikeSchema,
|
|
119
121
|
),
|
|
120
122
|
filePurpose: FilePurpose$outboundSchema,
|
|
121
|
-
metadata:
|
|
123
|
+
metadata: FileUploadMetadata$outboundSchema.optional(),
|
|
122
124
|
});
|
|
123
125
|
|
|
124
126
|
export function fileUploadRequestMultiPartToJSON(
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* 3-D Secure assurance details from Google Pay.
|
|
12
|
+
*/
|
|
13
|
+
export type GooglePayAssuranceDetails = {
|
|
14
|
+
/**
|
|
15
|
+
* Whether the card is verified via 3-D Secure authentication.
|
|
16
|
+
*/
|
|
17
|
+
cardHolderAuthenticated?: boolean | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* Whether the returned payment credential can be used for a transaction.
|
|
20
|
+
*/
|
|
21
|
+
accountVerified?: boolean | undefined;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
/** @internal */
|
|
25
|
+
export const GooglePayAssuranceDetails$inboundSchema: z.ZodType<
|
|
26
|
+
GooglePayAssuranceDetails,
|
|
27
|
+
z.ZodTypeDef,
|
|
28
|
+
unknown
|
|
29
|
+
> = z.object({
|
|
30
|
+
cardHolderAuthenticated: z.boolean().optional(),
|
|
31
|
+
accountVerified: z.boolean().optional(),
|
|
32
|
+
});
|
|
33
|
+
/** @internal */
|
|
34
|
+
export type GooglePayAssuranceDetails$Outbound = {
|
|
35
|
+
cardHolderAuthenticated?: boolean | undefined;
|
|
36
|
+
accountVerified?: boolean | undefined;
|
|
37
|
+
};
|
|
38
|
+
|
|
39
|
+
/** @internal */
|
|
40
|
+
export const GooglePayAssuranceDetails$outboundSchema: z.ZodType<
|
|
41
|
+
GooglePayAssuranceDetails$Outbound,
|
|
42
|
+
z.ZodTypeDef,
|
|
43
|
+
GooglePayAssuranceDetails
|
|
44
|
+
> = z.object({
|
|
45
|
+
cardHolderAuthenticated: z.boolean().optional(),
|
|
46
|
+
accountVerified: z.boolean().optional(),
|
|
47
|
+
});
|
|
48
|
+
|
|
49
|
+
export function googlePayAssuranceDetailsToJSON(
|
|
50
|
+
googlePayAssuranceDetails: GooglePayAssuranceDetails,
|
|
51
|
+
): string {
|
|
52
|
+
return JSON.stringify(
|
|
53
|
+
GooglePayAssuranceDetails$outboundSchema.parse(googlePayAssuranceDetails),
|
|
54
|
+
);
|
|
55
|
+
}
|
|
56
|
+
export function googlePayAssuranceDetailsFromJSON(
|
|
57
|
+
jsonString: string,
|
|
58
|
+
): SafeParseResult<GooglePayAssuranceDetails, SDKValidationError> {
|
|
59
|
+
return safeParse(
|
|
60
|
+
jsonString,
|
|
61
|
+
(x) => GooglePayAssuranceDetails$inboundSchema.parse(JSON.parse(x)),
|
|
62
|
+
`Failed to parse 'GooglePayAssuranceDetails' from JSON`,
|
|
63
|
+
);
|
|
64
|
+
}
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
7
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
8
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Billing address as returned by Google Pay.
|
|
12
|
+
*
|
|
13
|
+
* @remarks
|
|
14
|
+
*
|
|
15
|
+
* Refer to [Google's documentation](https://developers.google.com/pay/api/web/reference/response-objects#Address)
|
|
16
|
+
* for more information.
|
|
17
|
+
*/
|
|
18
|
+
export type GooglePayBillingAddress = {
|
|
19
|
+
/**
|
|
20
|
+
* First line of the street address.
|
|
21
|
+
*/
|
|
22
|
+
address1?: string | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Second line of the street address.
|
|
25
|
+
*/
|
|
26
|
+
address2?: string | undefined;
|
|
27
|
+
/**
|
|
28
|
+
* Third line of the street address.
|
|
29
|
+
*/
|
|
30
|
+
address3?: string | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* City, town, neighborhood, or suburb.
|
|
33
|
+
*/
|
|
34
|
+
locality?: string | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* State, province, or region.
|
|
37
|
+
*/
|
|
38
|
+
administrativeArea?: string | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* Postal or ZIP code.
|
|
41
|
+
*/
|
|
42
|
+
postalCode?: string | undefined;
|
|
43
|
+
/**
|
|
44
|
+
* ISO 3166-1 alpha-2 country code.
|
|
45
|
+
*/
|
|
46
|
+
countryCode?: string | undefined;
|
|
47
|
+
/**
|
|
48
|
+
* Name of the cardholder.
|
|
49
|
+
*/
|
|
50
|
+
name?: string | undefined;
|
|
51
|
+
/**
|
|
52
|
+
* Phone number.
|
|
53
|
+
*/
|
|
54
|
+
phoneNumber?: string | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* Sorting code (used in some countries).
|
|
57
|
+
*/
|
|
58
|
+
sortingCode?: string | undefined;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/** @internal */
|
|
62
|
+
export const GooglePayBillingAddress$inboundSchema: z.ZodType<
|
|
63
|
+
GooglePayBillingAddress,
|
|
64
|
+
z.ZodTypeDef,
|
|
65
|
+
unknown
|
|
66
|
+
> = z.object({
|
|
67
|
+
address1: z.string().optional(),
|
|
68
|
+
address2: z.string().optional(),
|
|
69
|
+
address3: z.string().optional(),
|
|
70
|
+
locality: z.string().optional(),
|
|
71
|
+
administrativeArea: z.string().optional(),
|
|
72
|
+
postalCode: z.string().optional(),
|
|
73
|
+
countryCode: z.string().optional(),
|
|
74
|
+
name: z.string().optional(),
|
|
75
|
+
phoneNumber: z.string().optional(),
|
|
76
|
+
sortingCode: z.string().optional(),
|
|
77
|
+
});
|
|
78
|
+
/** @internal */
|
|
79
|
+
export type GooglePayBillingAddress$Outbound = {
|
|
80
|
+
address1?: string | undefined;
|
|
81
|
+
address2?: string | undefined;
|
|
82
|
+
address3?: string | undefined;
|
|
83
|
+
locality?: string | undefined;
|
|
84
|
+
administrativeArea?: string | undefined;
|
|
85
|
+
postalCode?: string | undefined;
|
|
86
|
+
countryCode?: string | undefined;
|
|
87
|
+
name?: string | undefined;
|
|
88
|
+
phoneNumber?: string | undefined;
|
|
89
|
+
sortingCode?: string | undefined;
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
/** @internal */
|
|
93
|
+
export const GooglePayBillingAddress$outboundSchema: z.ZodType<
|
|
94
|
+
GooglePayBillingAddress$Outbound,
|
|
95
|
+
z.ZodTypeDef,
|
|
96
|
+
GooglePayBillingAddress
|
|
97
|
+
> = z.object({
|
|
98
|
+
address1: z.string().optional(),
|
|
99
|
+
address2: z.string().optional(),
|
|
100
|
+
address3: z.string().optional(),
|
|
101
|
+
locality: z.string().optional(),
|
|
102
|
+
administrativeArea: z.string().optional(),
|
|
103
|
+
postalCode: z.string().optional(),
|
|
104
|
+
countryCode: z.string().optional(),
|
|
105
|
+
name: z.string().optional(),
|
|
106
|
+
phoneNumber: z.string().optional(),
|
|
107
|
+
sortingCode: z.string().optional(),
|
|
108
|
+
});
|
|
109
|
+
|
|
110
|
+
export function googlePayBillingAddressToJSON(
|
|
111
|
+
googlePayBillingAddress: GooglePayBillingAddress,
|
|
112
|
+
): string {
|
|
113
|
+
return JSON.stringify(
|
|
114
|
+
GooglePayBillingAddress$outboundSchema.parse(googlePayBillingAddress),
|
|
115
|
+
);
|
|
116
|
+
}
|
|
117
|
+
export function googlePayBillingAddressFromJSON(
|
|
118
|
+
jsonString: string,
|
|
119
|
+
): SafeParseResult<GooglePayBillingAddress, SDKValidationError> {
|
|
120
|
+
return safeParse(
|
|
121
|
+
jsonString,
|
|
122
|
+
(x) => GooglePayBillingAddress$inboundSchema.parse(JSON.parse(x)),
|
|
123
|
+
`Failed to parse 'GooglePayBillingAddress' from JSON`,
|
|
124
|
+
);
|
|
125
|
+
}
|