@moovio/sdk 0.10.11 → 0.10.13
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 +43 -19
- package/bin/mcp-server.js +1582 -1001
- package/bin/mcp-server.js.map +32 -21
- package/docs/sdks/accountterminalapplications/README.md +375 -0
- package/docs/sdks/terminalapplications/README.md +12 -12
- package/funcs/accountTerminalApplicationsGet.d.ts +16 -0
- package/funcs/accountTerminalApplicationsGet.d.ts.map +1 -0
- package/funcs/accountTerminalApplicationsGet.js +121 -0
- package/funcs/accountTerminalApplicationsGet.js.map +1 -0
- package/funcs/{terminalConfigurationsGet.d.ts → accountTerminalApplicationsGetConfiguration.d.ts} +3 -3
- package/funcs/accountTerminalApplicationsGetConfiguration.d.ts.map +1 -0
- package/funcs/{terminalConfigurationsGet.js → accountTerminalApplicationsGetConfiguration.js} +4 -4
- package/funcs/accountTerminalApplicationsGetConfiguration.js.map +1 -0
- package/funcs/accountTerminalApplicationsLink.d.ts +17 -0
- package/funcs/accountTerminalApplicationsLink.d.ts.map +1 -0
- package/funcs/accountTerminalApplicationsLink.js +138 -0
- package/funcs/accountTerminalApplicationsLink.js.map +1 -0
- package/funcs/accountTerminalApplicationsList.d.ts +16 -0
- package/funcs/accountTerminalApplicationsList.d.ts.map +1 -0
- package/funcs/accountTerminalApplicationsList.js +120 -0
- package/funcs/accountTerminalApplicationsList.js.map +1 -0
- package/funcs/terminalApplicationsCreate.d.ts +1 -1
- package/funcs/terminalApplicationsCreate.js +1 -1
- package/funcs/terminalApplicationsDelete.d.ts +1 -1
- package/funcs/terminalApplicationsDelete.js +1 -1
- package/funcs/terminalApplicationsGet.d.ts +1 -1
- package/funcs/terminalApplicationsGet.js +1 -1
- package/funcs/terminalApplicationsList.d.ts +1 -1
- package/funcs/terminalApplicationsList.js +1 -1
- package/jsr.json +1 -1
- package/lib/config.d.ts +3 -3
- package/lib/config.js +3 -3
- package/mcp-server/mcp-server.js +1 -1
- package/mcp-server/server.d.ts.map +1 -1
- package/mcp-server/server.js +9 -3
- package/mcp-server/server.js.map +1 -1
- package/mcp-server/tools/accountTerminalApplicationsGet.d.ts +8 -0
- package/mcp-server/tools/accountTerminalApplicationsGet.d.ts.map +1 -0
- package/mcp-server/tools/accountTerminalApplicationsGet.js +65 -0
- package/mcp-server/tools/accountTerminalApplicationsGet.js.map +1 -0
- package/mcp-server/tools/{terminalConfigurationsGet.d.ts → accountTerminalApplicationsGetConfiguration.d.ts} +2 -2
- package/mcp-server/tools/accountTerminalApplicationsGetConfiguration.d.ts.map +1 -0
- package/mcp-server/tools/{terminalConfigurationsGet.js → accountTerminalApplicationsGetConfiguration.js} +7 -7
- package/mcp-server/tools/accountTerminalApplicationsGetConfiguration.js.map +1 -0
- package/mcp-server/tools/accountTerminalApplicationsLink.d.ts +8 -0
- package/mcp-server/tools/accountTerminalApplicationsLink.d.ts.map +1 -0
- package/mcp-server/tools/accountTerminalApplicationsLink.js +65 -0
- package/mcp-server/tools/accountTerminalApplicationsLink.js.map +1 -0
- package/mcp-server/tools/accountTerminalApplicationsList.d.ts +8 -0
- package/mcp-server/tools/accountTerminalApplicationsList.d.ts.map +1 -0
- package/mcp-server/tools/accountTerminalApplicationsList.js +65 -0
- package/mcp-server/tools/accountTerminalApplicationsList.js.map +1 -0
- package/mcp-server/tools/terminalApplicationsCreate.js +1 -1
- package/mcp-server/tools/terminalApplicationsCreate.js.map +1 -1
- package/mcp-server/tools/terminalApplicationsDelete.js +1 -1
- package/mcp-server/tools/terminalApplicationsDelete.js.map +1 -1
- package/mcp-server/tools/terminalApplicationsGet.js +1 -1
- package/mcp-server/tools/terminalApplicationsGet.js.map +1 -1
- package/mcp-server/tools/terminalApplicationsList.js +1 -1
- package/mcp-server/tools/terminalApplicationsList.js.map +1 -1
- package/models/components/index.d.ts +1 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +1 -0
- package/models/components/index.js.map +1 -1
- package/models/components/linkaccountterminalapplication.d.ts +35 -0
- package/models/components/linkaccountterminalapplication.d.ts.map +1 -0
- package/models/components/linkaccountterminalapplication.js +69 -0
- package/models/components/linkaccountterminalapplication.js.map +1 -0
- package/models/errors/accountterminalapplicationerror.d.ts +31 -0
- package/models/errors/accountterminalapplicationerror.d.ts.map +1 -0
- package/models/errors/accountterminalapplicationerror.js +79 -0
- package/models/errors/accountterminalapplicationerror.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/operations/createtransfer.d.ts +1 -1
- package/models/operations/getaccountterminalapplication.d.ts +101 -0
- package/models/operations/getaccountterminalapplication.d.ts.map +1 -0
- package/models/operations/getaccountterminalapplication.js +147 -0
- package/models/operations/getaccountterminalapplication.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/initiaterefund.d.ts +1 -1
- package/models/operations/linkaccountterminalapplication.d.ts +101 -0
- package/models/operations/linkaccountterminalapplication.d.ts.map +1 -0
- package/models/operations/linkaccountterminalapplication.js +155 -0
- package/models/operations/linkaccountterminalapplication.js.map +1 -0
- package/models/operations/listaccountterminalapplications.d.ts +99 -0
- package/models/operations/listaccountterminalapplications.d.ts.map +1 -0
- package/models/operations/listaccountterminalapplications.js +145 -0
- package/models/operations/listaccountterminalapplications.js.map +1 -0
- package/package.json +3 -3
- package/sdk/accountterminalapplications.d.ts +33 -0
- package/sdk/accountterminalapplications.d.ts.map +1 -0
- package/sdk/accountterminalapplications.js +52 -0
- package/sdk/accountterminalapplications.js.map +1 -0
- package/sdk/sdk.d.ts +3 -3
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +3 -3
- package/sdk/sdk.js.map +1 -1
- package/sdk/terminalapplications.d.ts +4 -4
- package/sdk/terminalapplications.js +4 -4
- package/src/funcs/accountTerminalApplicationsGet.ts +184 -0
- package/src/funcs/{terminalConfigurationsGet.ts → accountTerminalApplicationsGetConfiguration.ts} +2 -2
- package/src/funcs/accountTerminalApplicationsLink.ts +205 -0
- package/src/funcs/accountTerminalApplicationsList.ts +179 -0
- package/src/funcs/terminalApplicationsCreate.ts +1 -1
- package/src/funcs/terminalApplicationsDelete.ts +1 -1
- package/src/funcs/terminalApplicationsGet.ts +1 -1
- package/src/funcs/terminalApplicationsList.ts +1 -1
- package/src/lib/config.ts +3 -3
- package/src/mcp-server/mcp-server.ts +1 -1
- package/src/mcp-server/server.ts +9 -3
- package/src/mcp-server/tools/accountTerminalApplicationsGet.ts +40 -0
- package/src/mcp-server/tools/{terminalConfigurationsGet.ts → accountTerminalApplicationsGetConfiguration.ts} +8 -5
- package/src/mcp-server/tools/accountTerminalApplicationsLink.ts +39 -0
- package/src/mcp-server/tools/accountTerminalApplicationsList.ts +40 -0
- package/src/mcp-server/tools/terminalApplicationsCreate.ts +1 -1
- package/src/mcp-server/tools/terminalApplicationsDelete.ts +1 -1
- package/src/mcp-server/tools/terminalApplicationsGet.ts +1 -1
- package/src/mcp-server/tools/terminalApplicationsList.ts +1 -1
- package/src/models/components/index.ts +1 -0
- package/src/models/components/linkaccountterminalapplication.ts +74 -0
- package/src/models/errors/accountterminalapplicationerror.ts +71 -0
- package/src/models/errors/index.ts +1 -0
- package/src/models/operations/createtransfer.ts +1 -1
- package/src/models/operations/getaccountterminalapplication.ts +238 -0
- package/src/models/operations/index.ts +3 -0
- package/src/models/operations/initiaterefund.ts +1 -1
- package/src/models/operations/linkaccountterminalapplication.ts +250 -0
- package/src/models/operations/listaccountterminalapplications.ts +242 -0
- package/src/sdk/accountterminalapplications.ts +81 -0
- package/src/sdk/sdk.ts +5 -6
- package/src/sdk/terminalapplications.ts +4 -4
- package/docs/sdks/terminalconfigurations/README.md +0 -98
- package/funcs/terminalConfigurationsGet.d.ts.map +0 -1
- package/funcs/terminalConfigurationsGet.js.map +0 -1
- package/mcp-server/tools/terminalConfigurationsGet.d.ts.map +0 -1
- package/mcp-server/tools/terminalConfigurationsGet.js.map +0 -1
- package/sdk/terminalconfigurations.d.ts +0 -12
- package/sdk/terminalconfigurations.d.ts.map +0 -1
- package/sdk/terminalconfigurations.js +0 -22
- package/sdk/terminalconfigurations.js.map +0 -1
- package/src/sdk/terminalconfigurations.ts +0 -27
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,+CAAyC;AACzC,qDAA+C;AAC/C,+CAAyC;AACzC,2DAAqD;AACrD,6CAAuC;AACvC,uDAAiD;AACjD,+CAAyC;AACzC,uDAAiD;AACjD,qDAA+C;AAC/C,yCAAmC;AACnC,+CAAyC;AACzC,mEAA6D;AAC7D,6DAAuD;AACvD,6DAAuD;AACvD,+CAAyC;AACzC,yCAAmC;AACnC,mDAA6C;AAC7C,uDAAiD;AACjD,qEAA+D;AAC/D,mDAA6C;AAC7C,uDAAiD;AACjD,2DAAqD;AACrD,uCAAiC;AACjC,+CAAyC;AACzC,6DAAuD;AACvD,mDAA6C;AAC7C,2CAAqC;AACrC,uEAAiE;AACjE,
|
|
1
|
+
{"version":3,"file":"sdk.js","sourceRoot":"","sources":["../src/sdk/sdk.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,4CAA2C;AAC3C,+CAAyC;AACzC,qFAA+E;AAC/E,qDAA+C;AAC/C,+CAAyC;AACzC,2DAAqD;AACrD,6CAAuC;AACvC,uDAAiD;AACjD,+CAAyC;AACzC,uDAAiD;AACjD,qDAA+C;AAC/C,yCAAmC;AACnC,+CAAyC;AACzC,mEAA6D;AAC7D,6DAAuD;AACvD,6DAAuD;AACvD,+CAAyC;AACzC,yCAAmC;AACnC,mDAA6C;AAC7C,uDAAiD;AACjD,qEAA+D;AAC/D,mDAA6C;AAC7C,uDAAiD;AAC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,GAAK,IAAI,cAAI,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IAClD,CAAC;IAGD,IAAI,QAAQ;QACV,OAAO,CAAC,IAAI,CAAC,SAAS,KAAd,IAAI,CAAC,SAAS,GAAK,IAAI,sBAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,EAAC,CAAC;IAC1D,CAAC;IAGD,IAAI,oBAAoB;QACtB,OAAO,CAAC,IAAI,CAAC,qBAAqB,KAA1B,IAAI,CAAC,qBAAqB,GAAK,IAAI,8CAAoB,CAC7D,IAAI,CAAC,QAAQ,CACd,EAAC,CAAC;IACL,CAAC;CACF;AA1KD,oBA0KC"}
|
|
@@ -6,28 +6,28 @@ export declare class TerminalApplications extends ClientSDK {
|
|
|
6
6
|
* Create a new terminal application.
|
|
7
7
|
*
|
|
8
8
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
9
|
-
* you'll need to specify the `/
|
|
9
|
+
* you'll need to specify the `/terminal-applications.write` scope.
|
|
10
10
|
*/
|
|
11
11
|
create(request: components.CreateTerminalApplication, options?: RequestOptions): Promise<operations.CreateTerminalApplicationResponse>;
|
|
12
12
|
/**
|
|
13
13
|
* List all the terminal applications for a Moov Account.
|
|
14
14
|
*
|
|
15
15
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
16
|
-
* you'll need to specify the `/
|
|
16
|
+
* you'll need to specify the `/terminal-applications.read` scope.
|
|
17
17
|
*/
|
|
18
18
|
list(request: operations.ListTerminalApplicationsRequest, options?: RequestOptions): Promise<operations.ListTerminalApplicationsResponse>;
|
|
19
19
|
/**
|
|
20
20
|
* Fetch a specific terminal application.
|
|
21
21
|
*
|
|
22
22
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
23
|
-
* you'll need to specify the `/
|
|
23
|
+
* you'll need to specify the `/terminal-applications.read` scope.
|
|
24
24
|
*/
|
|
25
25
|
get(request: operations.GetTerminalApplicationRequest, options?: RequestOptions): Promise<operations.GetTerminalApplicationResponse>;
|
|
26
26
|
/**
|
|
27
27
|
* Delete a specific terminal application.
|
|
28
28
|
*
|
|
29
29
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
30
|
-
* you'll need to specify the `/
|
|
30
|
+
* you'll need to specify the `/terminal-applications.write` scope.
|
|
31
31
|
*/
|
|
32
32
|
delete(request: operations.DeleteTerminalApplicationRequest, options?: RequestOptions): Promise<operations.DeleteTerminalApplicationResponse | undefined>;
|
|
33
33
|
}
|
|
@@ -15,7 +15,7 @@ class TerminalApplications extends sdks_js_1.ClientSDK {
|
|
|
15
15
|
* Create a new terminal application.
|
|
16
16
|
*
|
|
17
17
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
18
|
-
* you'll need to specify the `/
|
|
18
|
+
* you'll need to specify the `/terminal-applications.write` scope.
|
|
19
19
|
*/
|
|
20
20
|
async create(request, options) {
|
|
21
21
|
return (0, fp_js_1.unwrapAsync)((0, terminalApplicationsCreate_js_1.terminalApplicationsCreate)(this, request, options));
|
|
@@ -24,7 +24,7 @@ class TerminalApplications extends sdks_js_1.ClientSDK {
|
|
|
24
24
|
* List all the terminal applications for a Moov Account.
|
|
25
25
|
*
|
|
26
26
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
27
|
-
* you'll need to specify the `/
|
|
27
|
+
* you'll need to specify the `/terminal-applications.read` scope.
|
|
28
28
|
*/
|
|
29
29
|
async list(request, options) {
|
|
30
30
|
return (0, fp_js_1.unwrapAsync)((0, terminalApplicationsList_js_1.terminalApplicationsList)(this, request, options));
|
|
@@ -33,7 +33,7 @@ class TerminalApplications extends sdks_js_1.ClientSDK {
|
|
|
33
33
|
* Fetch a specific terminal application.
|
|
34
34
|
*
|
|
35
35
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
36
|
-
* you'll need to specify the `/
|
|
36
|
+
* you'll need to specify the `/terminal-applications.read` scope.
|
|
37
37
|
*/
|
|
38
38
|
async get(request, options) {
|
|
39
39
|
return (0, fp_js_1.unwrapAsync)((0, terminalApplicationsGet_js_1.terminalApplicationsGet)(this, request, options));
|
|
@@ -42,7 +42,7 @@ class TerminalApplications extends sdks_js_1.ClientSDK {
|
|
|
42
42
|
* Delete a specific terminal application.
|
|
43
43
|
*
|
|
44
44
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
45
|
-
* you'll need to specify the `/
|
|
45
|
+
* you'll need to specify the `/terminal-applications.write` scope.
|
|
46
46
|
*/
|
|
47
47
|
async delete(request, options) {
|
|
48
48
|
return (0, fp_js_1.unwrapAsync)((0, terminalApplicationsDelete_js_1.terminalApplicationsDelete)(this, request, options));
|
|
@@ -0,0 +1,184 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { MoovCore } from "../core.js";
|
|
6
|
+
import { encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import { APIError } from "../models/errors/apierror.js";
|
|
14
|
+
import {
|
|
15
|
+
ConnectionError,
|
|
16
|
+
InvalidRequestError,
|
|
17
|
+
RequestAbortedError,
|
|
18
|
+
RequestTimeoutError,
|
|
19
|
+
UnexpectedClientError,
|
|
20
|
+
} from "../models/errors/httpclienterrors.js";
|
|
21
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
22
|
+
import * as operations from "../models/operations/index.js";
|
|
23
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
24
|
+
import { Result } from "../types/fp.js";
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Verifies if a specific Terminal Application is linked to an Account. This endpoint acts as a validation check for the link's existence.
|
|
28
|
+
*
|
|
29
|
+
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
30
|
+
* you'll need to specify the `/accounts/{accountID}/terminal-applications.read` scope.
|
|
31
|
+
*/
|
|
32
|
+
export function accountTerminalApplicationsGet(
|
|
33
|
+
client: MoovCore,
|
|
34
|
+
request: operations.GetAccountTerminalApplicationRequest,
|
|
35
|
+
options?: RequestOptions,
|
|
36
|
+
): APIPromise<
|
|
37
|
+
Result<
|
|
38
|
+
operations.GetAccountTerminalApplicationResponse,
|
|
39
|
+
| APIError
|
|
40
|
+
| SDKValidationError
|
|
41
|
+
| UnexpectedClientError
|
|
42
|
+
| InvalidRequestError
|
|
43
|
+
| RequestAbortedError
|
|
44
|
+
| RequestTimeoutError
|
|
45
|
+
| ConnectionError
|
|
46
|
+
>
|
|
47
|
+
> {
|
|
48
|
+
return new APIPromise($do(
|
|
49
|
+
client,
|
|
50
|
+
request,
|
|
51
|
+
options,
|
|
52
|
+
));
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
async function $do(
|
|
56
|
+
client: MoovCore,
|
|
57
|
+
request: operations.GetAccountTerminalApplicationRequest,
|
|
58
|
+
options?: RequestOptions,
|
|
59
|
+
): Promise<
|
|
60
|
+
[
|
|
61
|
+
Result<
|
|
62
|
+
operations.GetAccountTerminalApplicationResponse,
|
|
63
|
+
| APIError
|
|
64
|
+
| SDKValidationError
|
|
65
|
+
| UnexpectedClientError
|
|
66
|
+
| InvalidRequestError
|
|
67
|
+
| RequestAbortedError
|
|
68
|
+
| RequestTimeoutError
|
|
69
|
+
| ConnectionError
|
|
70
|
+
>,
|
|
71
|
+
APICall,
|
|
72
|
+
]
|
|
73
|
+
> {
|
|
74
|
+
const parsed = safeParse(
|
|
75
|
+
request,
|
|
76
|
+
(value) =>
|
|
77
|
+
operations.GetAccountTerminalApplicationRequest$outboundSchema.parse(
|
|
78
|
+
value,
|
|
79
|
+
),
|
|
80
|
+
"Input validation failed",
|
|
81
|
+
);
|
|
82
|
+
if (!parsed.ok) {
|
|
83
|
+
return [parsed, { status: "invalid" }];
|
|
84
|
+
}
|
|
85
|
+
const payload = parsed.value;
|
|
86
|
+
const body = null;
|
|
87
|
+
|
|
88
|
+
const pathParams = {
|
|
89
|
+
accountID: encodeSimple("accountID", payload.accountID, {
|
|
90
|
+
explode: false,
|
|
91
|
+
charEncoding: "percent",
|
|
92
|
+
}),
|
|
93
|
+
terminalApplicationID: encodeSimple(
|
|
94
|
+
"terminalApplicationID",
|
|
95
|
+
payload.terminalApplicationID,
|
|
96
|
+
{ explode: false, charEncoding: "percent" },
|
|
97
|
+
),
|
|
98
|
+
};
|
|
99
|
+
|
|
100
|
+
const path = pathToFunc(
|
|
101
|
+
"/accounts/{accountID}/terminal-applications/{terminalApplicationID}",
|
|
102
|
+
)(pathParams);
|
|
103
|
+
|
|
104
|
+
const headers = new Headers(compactMap({
|
|
105
|
+
Accept: "application/json",
|
|
106
|
+
"x-moov-version": encodeSimple(
|
|
107
|
+
"x-moov-version",
|
|
108
|
+
client._options.xMoovVersion,
|
|
109
|
+
{ explode: false, charEncoding: "none" },
|
|
110
|
+
),
|
|
111
|
+
}));
|
|
112
|
+
|
|
113
|
+
const securityInput = await extractSecurity(client._options.security);
|
|
114
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
115
|
+
|
|
116
|
+
const context = {
|
|
117
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
118
|
+
operationID: "getAccountTerminalApplication",
|
|
119
|
+
oAuth2Scopes: [],
|
|
120
|
+
|
|
121
|
+
resolvedSecurity: requestSecurity,
|
|
122
|
+
|
|
123
|
+
securitySource: client._options.security,
|
|
124
|
+
retryConfig: options?.retries
|
|
125
|
+
|| client._options.retryConfig
|
|
126
|
+
|| { strategy: "none" },
|
|
127
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
128
|
+
};
|
|
129
|
+
|
|
130
|
+
const requestRes = client._createRequest(context, {
|
|
131
|
+
security: requestSecurity,
|
|
132
|
+
method: "GET",
|
|
133
|
+
baseURL: options?.serverURL,
|
|
134
|
+
path: path,
|
|
135
|
+
headers: headers,
|
|
136
|
+
body: body,
|
|
137
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
138
|
+
}, options);
|
|
139
|
+
if (!requestRes.ok) {
|
|
140
|
+
return [requestRes, { status: "invalid" }];
|
|
141
|
+
}
|
|
142
|
+
const req = requestRes.value;
|
|
143
|
+
|
|
144
|
+
const doResult = await client._do(req, {
|
|
145
|
+
context,
|
|
146
|
+
errorCodes: ["401", "403", "404", "429", "4XX", "500", "504", "5XX"],
|
|
147
|
+
retryConfig: context.retryConfig,
|
|
148
|
+
retryCodes: context.retryCodes,
|
|
149
|
+
});
|
|
150
|
+
if (!doResult.ok) {
|
|
151
|
+
return [doResult, { status: "request-error", request: req }];
|
|
152
|
+
}
|
|
153
|
+
const response = doResult.value;
|
|
154
|
+
|
|
155
|
+
const responseFields = {
|
|
156
|
+
HttpMeta: { Response: response, Request: req },
|
|
157
|
+
};
|
|
158
|
+
|
|
159
|
+
const [result] = await M.match<
|
|
160
|
+
operations.GetAccountTerminalApplicationResponse,
|
|
161
|
+
| APIError
|
|
162
|
+
| SDKValidationError
|
|
163
|
+
| UnexpectedClientError
|
|
164
|
+
| InvalidRequestError
|
|
165
|
+
| RequestAbortedError
|
|
166
|
+
| RequestTimeoutError
|
|
167
|
+
| ConnectionError
|
|
168
|
+
>(
|
|
169
|
+
M.json(
|
|
170
|
+
200,
|
|
171
|
+
operations.GetAccountTerminalApplicationResponse$inboundSchema,
|
|
172
|
+
{ hdrs: true, key: "Result" },
|
|
173
|
+
),
|
|
174
|
+
M.fail([401, 403, 404, 429]),
|
|
175
|
+
M.fail([500, 504]),
|
|
176
|
+
M.fail("4XX"),
|
|
177
|
+
M.fail("5XX"),
|
|
178
|
+
)(response, { extraFields: responseFields });
|
|
179
|
+
if (!result.ok) {
|
|
180
|
+
return [result, { status: "complete", request: req, response }];
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
return [result, { status: "complete", request: req, response }];
|
|
184
|
+
}
|
package/src/funcs/{terminalConfigurationsGet.ts → accountTerminalApplicationsGetConfiguration.ts}
RENAMED
|
@@ -24,12 +24,12 @@ import { APICall, APIPromise } from "../types/async.js";
|
|
|
24
24
|
import { Result } from "../types/fp.js";
|
|
25
25
|
|
|
26
26
|
/**
|
|
27
|
-
* Fetch the configuration for a given Terminal Application
|
|
27
|
+
* Fetch the configuration for a given Terminal Application linked to a specific Account.
|
|
28
28
|
*
|
|
29
29
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
30
30
|
* you'll need to specify the `/accounts/{accountID}/terminal-configuration.read` scope.
|
|
31
31
|
*/
|
|
32
|
-
export function
|
|
32
|
+
export function accountTerminalApplicationsGetConfiguration(
|
|
33
33
|
client: MoovCore,
|
|
34
34
|
request: operations.GetTerminalConfigurationRequest,
|
|
35
35
|
options?: RequestOptions,
|
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { MoovCore } from "../core.js";
|
|
6
|
+
import { encodeJSON, encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import { APIError } from "../models/errors/apierror.js";
|
|
14
|
+
import {
|
|
15
|
+
ConnectionError,
|
|
16
|
+
InvalidRequestError,
|
|
17
|
+
RequestAbortedError,
|
|
18
|
+
RequestTimeoutError,
|
|
19
|
+
UnexpectedClientError,
|
|
20
|
+
} from "../models/errors/httpclienterrors.js";
|
|
21
|
+
import * as errors from "../models/errors/index.js";
|
|
22
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
23
|
+
import * as operations from "../models/operations/index.js";
|
|
24
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
25
|
+
import { Result } from "../types/fp.js";
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Link an account with a terminal application.
|
|
29
|
+
*
|
|
30
|
+
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
31
|
+
* you'll need to specify the `/accounts/{accountID}/terminal-applications.write` scope.
|
|
32
|
+
*/
|
|
33
|
+
export function accountTerminalApplicationsLink(
|
|
34
|
+
client: MoovCore,
|
|
35
|
+
request: operations.LinkAccountTerminalApplicationRequest,
|
|
36
|
+
options?: RequestOptions,
|
|
37
|
+
): APIPromise<
|
|
38
|
+
Result<
|
|
39
|
+
operations.LinkAccountTerminalApplicationResponse,
|
|
40
|
+
| errors.GenericError
|
|
41
|
+
| errors.AccountTerminalApplicationError
|
|
42
|
+
| APIError
|
|
43
|
+
| SDKValidationError
|
|
44
|
+
| UnexpectedClientError
|
|
45
|
+
| InvalidRequestError
|
|
46
|
+
| RequestAbortedError
|
|
47
|
+
| RequestTimeoutError
|
|
48
|
+
| ConnectionError
|
|
49
|
+
>
|
|
50
|
+
> {
|
|
51
|
+
return new APIPromise($do(
|
|
52
|
+
client,
|
|
53
|
+
request,
|
|
54
|
+
options,
|
|
55
|
+
));
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
async function $do(
|
|
59
|
+
client: MoovCore,
|
|
60
|
+
request: operations.LinkAccountTerminalApplicationRequest,
|
|
61
|
+
options?: RequestOptions,
|
|
62
|
+
): Promise<
|
|
63
|
+
[
|
|
64
|
+
Result<
|
|
65
|
+
operations.LinkAccountTerminalApplicationResponse,
|
|
66
|
+
| errors.GenericError
|
|
67
|
+
| errors.AccountTerminalApplicationError
|
|
68
|
+
| APIError
|
|
69
|
+
| SDKValidationError
|
|
70
|
+
| UnexpectedClientError
|
|
71
|
+
| InvalidRequestError
|
|
72
|
+
| RequestAbortedError
|
|
73
|
+
| RequestTimeoutError
|
|
74
|
+
| ConnectionError
|
|
75
|
+
>,
|
|
76
|
+
APICall,
|
|
77
|
+
]
|
|
78
|
+
> {
|
|
79
|
+
const parsed = safeParse(
|
|
80
|
+
request,
|
|
81
|
+
(value) =>
|
|
82
|
+
operations.LinkAccountTerminalApplicationRequest$outboundSchema.parse(
|
|
83
|
+
value,
|
|
84
|
+
),
|
|
85
|
+
"Input validation failed",
|
|
86
|
+
);
|
|
87
|
+
if (!parsed.ok) {
|
|
88
|
+
return [parsed, { status: "invalid" }];
|
|
89
|
+
}
|
|
90
|
+
const payload = parsed.value;
|
|
91
|
+
const body = encodeJSON("body", payload.LinkAccountTerminalApplication, {
|
|
92
|
+
explode: true,
|
|
93
|
+
});
|
|
94
|
+
|
|
95
|
+
const pathParams = {
|
|
96
|
+
accountID: encodeSimple("accountID", payload.accountID, {
|
|
97
|
+
explode: false,
|
|
98
|
+
charEncoding: "percent",
|
|
99
|
+
}),
|
|
100
|
+
};
|
|
101
|
+
|
|
102
|
+
const path = pathToFunc("/accounts/{accountID}/terminal-applications")(
|
|
103
|
+
pathParams,
|
|
104
|
+
);
|
|
105
|
+
|
|
106
|
+
const headers = new Headers(compactMap({
|
|
107
|
+
"Content-Type": "application/json",
|
|
108
|
+
Accept: "application/json",
|
|
109
|
+
"x-moov-version": encodeSimple(
|
|
110
|
+
"x-moov-version",
|
|
111
|
+
client._options.xMoovVersion,
|
|
112
|
+
{ explode: false, charEncoding: "none" },
|
|
113
|
+
),
|
|
114
|
+
}));
|
|
115
|
+
|
|
116
|
+
const securityInput = await extractSecurity(client._options.security);
|
|
117
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
118
|
+
|
|
119
|
+
const context = {
|
|
120
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
121
|
+
operationID: "linkAccountTerminalApplication",
|
|
122
|
+
oAuth2Scopes: [],
|
|
123
|
+
|
|
124
|
+
resolvedSecurity: requestSecurity,
|
|
125
|
+
|
|
126
|
+
securitySource: client._options.security,
|
|
127
|
+
retryConfig: options?.retries
|
|
128
|
+
|| client._options.retryConfig
|
|
129
|
+
|| { strategy: "none" },
|
|
130
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
131
|
+
};
|
|
132
|
+
|
|
133
|
+
const requestRes = client._createRequest(context, {
|
|
134
|
+
security: requestSecurity,
|
|
135
|
+
method: "POST",
|
|
136
|
+
baseURL: options?.serverURL,
|
|
137
|
+
path: path,
|
|
138
|
+
headers: headers,
|
|
139
|
+
body: body,
|
|
140
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
141
|
+
}, options);
|
|
142
|
+
if (!requestRes.ok) {
|
|
143
|
+
return [requestRes, { status: "invalid" }];
|
|
144
|
+
}
|
|
145
|
+
const req = requestRes.value;
|
|
146
|
+
|
|
147
|
+
const doResult = await client._do(req, {
|
|
148
|
+
context,
|
|
149
|
+
errorCodes: [
|
|
150
|
+
"400",
|
|
151
|
+
"401",
|
|
152
|
+
"403",
|
|
153
|
+
"404",
|
|
154
|
+
"409",
|
|
155
|
+
"422",
|
|
156
|
+
"429",
|
|
157
|
+
"4XX",
|
|
158
|
+
"500",
|
|
159
|
+
"504",
|
|
160
|
+
"5XX",
|
|
161
|
+
],
|
|
162
|
+
retryConfig: context.retryConfig,
|
|
163
|
+
retryCodes: context.retryCodes,
|
|
164
|
+
});
|
|
165
|
+
if (!doResult.ok) {
|
|
166
|
+
return [doResult, { status: "request-error", request: req }];
|
|
167
|
+
}
|
|
168
|
+
const response = doResult.value;
|
|
169
|
+
|
|
170
|
+
const responseFields = {
|
|
171
|
+
HttpMeta: { Response: response, Request: req },
|
|
172
|
+
};
|
|
173
|
+
|
|
174
|
+
const [result] = await M.match<
|
|
175
|
+
operations.LinkAccountTerminalApplicationResponse,
|
|
176
|
+
| errors.GenericError
|
|
177
|
+
| errors.AccountTerminalApplicationError
|
|
178
|
+
| APIError
|
|
179
|
+
| SDKValidationError
|
|
180
|
+
| UnexpectedClientError
|
|
181
|
+
| InvalidRequestError
|
|
182
|
+
| RequestAbortedError
|
|
183
|
+
| RequestTimeoutError
|
|
184
|
+
| ConnectionError
|
|
185
|
+
>(
|
|
186
|
+
M.json(
|
|
187
|
+
200,
|
|
188
|
+
operations.LinkAccountTerminalApplicationResponse$inboundSchema,
|
|
189
|
+
{ hdrs: true, key: "Result" },
|
|
190
|
+
),
|
|
191
|
+
M.jsonErr([400, 409], errors.GenericError$inboundSchema, { hdrs: true }),
|
|
192
|
+
M.jsonErr(422, errors.AccountTerminalApplicationError$inboundSchema, {
|
|
193
|
+
hdrs: true,
|
|
194
|
+
}),
|
|
195
|
+
M.fail([401, 403, 404, 429]),
|
|
196
|
+
M.fail([500, 504]),
|
|
197
|
+
M.fail("4XX"),
|
|
198
|
+
M.fail("5XX"),
|
|
199
|
+
)(response, { extraFields: responseFields });
|
|
200
|
+
if (!result.ok) {
|
|
201
|
+
return [result, { status: "complete", request: req, response }];
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
return [result, { status: "complete", request: req, response }];
|
|
205
|
+
}
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { MoovCore } from "../core.js";
|
|
6
|
+
import { encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import { APIError } from "../models/errors/apierror.js";
|
|
14
|
+
import {
|
|
15
|
+
ConnectionError,
|
|
16
|
+
InvalidRequestError,
|
|
17
|
+
RequestAbortedError,
|
|
18
|
+
RequestTimeoutError,
|
|
19
|
+
UnexpectedClientError,
|
|
20
|
+
} from "../models/errors/httpclienterrors.js";
|
|
21
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
22
|
+
import * as operations from "../models/operations/index.js";
|
|
23
|
+
import { APICall, APIPromise } from "../types/async.js";
|
|
24
|
+
import { Result } from "../types/fp.js";
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Retrieve all terminal applications linked to a specific account.
|
|
28
|
+
*
|
|
29
|
+
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
30
|
+
* you'll need to specify the `/accounts/{accountID}/terminal-applications.read` scope.
|
|
31
|
+
*/
|
|
32
|
+
export function accountTerminalApplicationsList(
|
|
33
|
+
client: MoovCore,
|
|
34
|
+
request: operations.ListAccountTerminalApplicationsRequest,
|
|
35
|
+
options?: RequestOptions,
|
|
36
|
+
): APIPromise<
|
|
37
|
+
Result<
|
|
38
|
+
operations.ListAccountTerminalApplicationsResponse,
|
|
39
|
+
| APIError
|
|
40
|
+
| SDKValidationError
|
|
41
|
+
| UnexpectedClientError
|
|
42
|
+
| InvalidRequestError
|
|
43
|
+
| RequestAbortedError
|
|
44
|
+
| RequestTimeoutError
|
|
45
|
+
| ConnectionError
|
|
46
|
+
>
|
|
47
|
+
> {
|
|
48
|
+
return new APIPromise($do(
|
|
49
|
+
client,
|
|
50
|
+
request,
|
|
51
|
+
options,
|
|
52
|
+
));
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
async function $do(
|
|
56
|
+
client: MoovCore,
|
|
57
|
+
request: operations.ListAccountTerminalApplicationsRequest,
|
|
58
|
+
options?: RequestOptions,
|
|
59
|
+
): Promise<
|
|
60
|
+
[
|
|
61
|
+
Result<
|
|
62
|
+
operations.ListAccountTerminalApplicationsResponse,
|
|
63
|
+
| APIError
|
|
64
|
+
| SDKValidationError
|
|
65
|
+
| UnexpectedClientError
|
|
66
|
+
| InvalidRequestError
|
|
67
|
+
| RequestAbortedError
|
|
68
|
+
| RequestTimeoutError
|
|
69
|
+
| ConnectionError
|
|
70
|
+
>,
|
|
71
|
+
APICall,
|
|
72
|
+
]
|
|
73
|
+
> {
|
|
74
|
+
const parsed = safeParse(
|
|
75
|
+
request,
|
|
76
|
+
(value) =>
|
|
77
|
+
operations.ListAccountTerminalApplicationsRequest$outboundSchema.parse(
|
|
78
|
+
value,
|
|
79
|
+
),
|
|
80
|
+
"Input validation failed",
|
|
81
|
+
);
|
|
82
|
+
if (!parsed.ok) {
|
|
83
|
+
return [parsed, { status: "invalid" }];
|
|
84
|
+
}
|
|
85
|
+
const payload = parsed.value;
|
|
86
|
+
const body = null;
|
|
87
|
+
|
|
88
|
+
const pathParams = {
|
|
89
|
+
accountID: encodeSimple("accountID", payload.accountID, {
|
|
90
|
+
explode: false,
|
|
91
|
+
charEncoding: "percent",
|
|
92
|
+
}),
|
|
93
|
+
};
|
|
94
|
+
|
|
95
|
+
const path = pathToFunc("/accounts/{accountID}/terminal-applications")(
|
|
96
|
+
pathParams,
|
|
97
|
+
);
|
|
98
|
+
|
|
99
|
+
const headers = new Headers(compactMap({
|
|
100
|
+
Accept: "application/json",
|
|
101
|
+
"x-moov-version": encodeSimple(
|
|
102
|
+
"x-moov-version",
|
|
103
|
+
client._options.xMoovVersion,
|
|
104
|
+
{ explode: false, charEncoding: "none" },
|
|
105
|
+
),
|
|
106
|
+
}));
|
|
107
|
+
|
|
108
|
+
const securityInput = await extractSecurity(client._options.security);
|
|
109
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
110
|
+
|
|
111
|
+
const context = {
|
|
112
|
+
baseURL: options?.serverURL ?? client._baseURL ?? "",
|
|
113
|
+
operationID: "listAccountTerminalApplications",
|
|
114
|
+
oAuth2Scopes: [],
|
|
115
|
+
|
|
116
|
+
resolvedSecurity: requestSecurity,
|
|
117
|
+
|
|
118
|
+
securitySource: client._options.security,
|
|
119
|
+
retryConfig: options?.retries
|
|
120
|
+
|| client._options.retryConfig
|
|
121
|
+
|| { strategy: "none" },
|
|
122
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
123
|
+
};
|
|
124
|
+
|
|
125
|
+
const requestRes = client._createRequest(context, {
|
|
126
|
+
security: requestSecurity,
|
|
127
|
+
method: "GET",
|
|
128
|
+
baseURL: options?.serverURL,
|
|
129
|
+
path: path,
|
|
130
|
+
headers: headers,
|
|
131
|
+
body: body,
|
|
132
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
133
|
+
}, options);
|
|
134
|
+
if (!requestRes.ok) {
|
|
135
|
+
return [requestRes, { status: "invalid" }];
|
|
136
|
+
}
|
|
137
|
+
const req = requestRes.value;
|
|
138
|
+
|
|
139
|
+
const doResult = await client._do(req, {
|
|
140
|
+
context,
|
|
141
|
+
errorCodes: ["401", "403", "429", "4XX", "500", "504", "5XX"],
|
|
142
|
+
retryConfig: context.retryConfig,
|
|
143
|
+
retryCodes: context.retryCodes,
|
|
144
|
+
});
|
|
145
|
+
if (!doResult.ok) {
|
|
146
|
+
return [doResult, { status: "request-error", request: req }];
|
|
147
|
+
}
|
|
148
|
+
const response = doResult.value;
|
|
149
|
+
|
|
150
|
+
const responseFields = {
|
|
151
|
+
HttpMeta: { Response: response, Request: req },
|
|
152
|
+
};
|
|
153
|
+
|
|
154
|
+
const [result] = await M.match<
|
|
155
|
+
operations.ListAccountTerminalApplicationsResponse,
|
|
156
|
+
| APIError
|
|
157
|
+
| SDKValidationError
|
|
158
|
+
| UnexpectedClientError
|
|
159
|
+
| InvalidRequestError
|
|
160
|
+
| RequestAbortedError
|
|
161
|
+
| RequestTimeoutError
|
|
162
|
+
| ConnectionError
|
|
163
|
+
>(
|
|
164
|
+
M.json(
|
|
165
|
+
200,
|
|
166
|
+
operations.ListAccountTerminalApplicationsResponse$inboundSchema,
|
|
167
|
+
{ hdrs: true, key: "Result" },
|
|
168
|
+
),
|
|
169
|
+
M.fail([401, 403, 429]),
|
|
170
|
+
M.fail([500, 504]),
|
|
171
|
+
M.fail("4XX"),
|
|
172
|
+
M.fail("5XX"),
|
|
173
|
+
)(response, { extraFields: responseFields });
|
|
174
|
+
if (!result.ok) {
|
|
175
|
+
return [result, { status: "complete", request: req, response }];
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
return [result, { status: "complete", request: req, response }];
|
|
179
|
+
}
|
|
@@ -29,7 +29,7 @@ import { Result } from "../types/fp.js";
|
|
|
29
29
|
* Create a new terminal application.
|
|
30
30
|
*
|
|
31
31
|
* To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
|
|
32
|
-
* you'll need to specify the `/
|
|
32
|
+
* you'll need to specify the `/terminal-applications.write` scope.
|
|
33
33
|
*/
|
|
34
34
|
export function terminalApplicationsCreate(
|
|
35
35
|
client: MoovCore,
|