@moovio/sdk 0.22.0 → 0.22.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.
Files changed (79) hide show
  1. package/README.md +130 -134
  2. package/bin/mcp-server.js +945 -1167
  3. package/bin/mcp-server.js.map +11 -17
  4. package/examples/package-lock.json +1 -1
  5. package/funcs/institutionsSearch.d.ts +4 -0
  6. package/funcs/institutionsSearch.d.ts.map +1 -1
  7. package/funcs/institutionsSearch.js +4 -0
  8. package/funcs/institutionsSearch.js.map +1 -1
  9. package/jsr.json +1 -1
  10. package/lib/config.d.ts +3 -3
  11. package/lib/config.js +3 -3
  12. package/mcp-server/mcp-server.js +1 -1
  13. package/mcp-server/server.d.ts.map +1 -1
  14. package/mcp-server/server.js +1 -3
  15. package/mcp-server/server.js.map +1 -1
  16. package/mcp-server/tools/institutionsSearch.d.ts.map +1 -1
  17. package/mcp-server/tools/institutionsSearch.js +3 -1
  18. package/mcp-server/tools/institutionsSearch.js.map +1 -1
  19. package/models/components/index.d.ts +0 -3
  20. package/models/components/index.d.ts.map +1 -1
  21. package/models/components/index.js +0 -3
  22. package/models/components/index.js.map +1 -1
  23. package/models/components/invoicelineitemoption.d.ts +6 -0
  24. package/models/components/invoicelineitemoption.d.ts.map +1 -1
  25. package/models/components/invoicelineitemoption.js +3 -0
  26. package/models/components/invoicelineitemoption.js.map +1 -1
  27. package/models/operations/index.d.ts +0 -1
  28. package/models/operations/index.d.ts.map +1 -1
  29. package/models/operations/index.js +0 -1
  30. package/models/operations/index.js.map +1 -1
  31. package/package.json +1 -1
  32. package/sdk/branding.d.ts +0 -7
  33. package/sdk/branding.d.ts.map +1 -1
  34. package/sdk/branding.js +0 -10
  35. package/sdk/branding.js.map +1 -1
  36. package/sdk/institutions.d.ts +4 -0
  37. package/sdk/institutions.d.ts.map +1 -1
  38. package/sdk/institutions.js +4 -0
  39. package/sdk/institutions.js.map +1 -1
  40. package/src/funcs/institutionsSearch.ts +4 -0
  41. package/src/lib/config.ts +3 -3
  42. package/src/mcp-server/mcp-server.ts +1 -1
  43. package/src/mcp-server/server.ts +1 -3
  44. package/src/mcp-server/tools/institutionsSearch.ts +4 -1
  45. package/src/models/components/index.ts +0 -3
  46. package/src/models/components/invoicelineitemoption.ts +13 -0
  47. package/src/models/operations/index.ts +0 -1
  48. package/src/sdk/branding.ts +0 -18
  49. package/src/sdk/institutions.ts +4 -0
  50. package/funcs/brandingUpdate.d.ts +0 -18
  51. package/funcs/brandingUpdate.d.ts.map +0 -1
  52. package/funcs/brandingUpdate.js +0 -139
  53. package/funcs/brandingUpdate.js.map +0 -1
  54. package/mcp-server/tools/brandingUpdate.d.ts +0 -8
  55. package/mcp-server/tools/brandingUpdate.d.ts.map +0 -1
  56. package/mcp-server/tools/brandingUpdate.js +0 -65
  57. package/mcp-server/tools/brandingUpdate.js.map +0 -1
  58. package/models/components/updatebrand.d.ts +0 -18
  59. package/models/components/updatebrand.d.ts.map +0 -1
  60. package/models/components/updatebrand.js +0 -59
  61. package/models/components/updatebrand.js.map +0 -1
  62. package/models/components/updatecolor.d.ts +0 -17
  63. package/models/components/updatecolor.d.ts.map +0 -1
  64. package/models/components/updatecolor.js +0 -58
  65. package/models/components/updatecolor.js.map +0 -1
  66. package/models/components/updatecolors.d.ts +0 -20
  67. package/models/components/updatecolors.d.ts.map +0 -1
  68. package/models/components/updatecolors.js +0 -61
  69. package/models/components/updatecolors.js.map +0 -1
  70. package/models/operations/updatebrand.d.ts +0 -66
  71. package/models/operations/updatebrand.d.ts.map +0 -1
  72. package/models/operations/updatebrand.js +0 -122
  73. package/models/operations/updatebrand.js.map +0 -1
  74. package/src/funcs/brandingUpdate.ts +0 -201
  75. package/src/mcp-server/tools/brandingUpdate.ts +0 -38
  76. package/src/models/components/updatebrand.ts +0 -53
  77. package/src/models/components/updatecolor.ts +0 -47
  78. package/src/models/components/updatecolors.ts +0 -57
  79. package/src/models/operations/updatebrand.ts +0 -187
@@ -1,61 +0,0 @@
1
- "use strict";
2
- /*
3
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
4
- */
5
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- var desc = Object.getOwnPropertyDescriptor(m, k);
8
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
- desc = { enumerable: true, get: function() { return m[k]; } };
10
- }
11
- Object.defineProperty(o, k2, desc);
12
- }) : (function(o, m, k, k2) {
13
- if (k2 === undefined) k2 = k;
14
- o[k2] = m[k];
15
- }));
16
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
- Object.defineProperty(o, "default", { enumerable: true, value: v });
18
- }) : function(o, v) {
19
- o["default"] = v;
20
- });
21
- var __importStar = (this && this.__importStar) || (function () {
22
- var ownKeys = function(o) {
23
- ownKeys = Object.getOwnPropertyNames || function (o) {
24
- var ar = [];
25
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
- return ar;
27
- };
28
- return ownKeys(o);
29
- };
30
- return function (mod) {
31
- if (mod && mod.__esModule) return mod;
32
- var result = {};
33
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
- __setModuleDefault(result, mod);
35
- return result;
36
- };
37
- })();
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.UpdateColors$outboundSchema = exports.UpdateColors$inboundSchema = void 0;
40
- exports.updateColorsToJSON = updateColorsToJSON;
41
- exports.updateColorsFromJSON = updateColorsFromJSON;
42
- const z = __importStar(require("zod/v3"));
43
- const schemas_js_1 = require("../../lib/schemas.js");
44
- const updatecolor_js_1 = require("./updatecolor.js");
45
- /** @internal */
46
- exports.UpdateColors$inboundSchema = z.object({
47
- dark: updatecolor_js_1.UpdateColor$inboundSchema.optional(),
48
- light: updatecolor_js_1.UpdateColor$inboundSchema.optional(),
49
- });
50
- /** @internal */
51
- exports.UpdateColors$outboundSchema = z.object({
52
- dark: updatecolor_js_1.UpdateColor$outboundSchema.optional(),
53
- light: updatecolor_js_1.UpdateColor$outboundSchema.optional(),
54
- });
55
- function updateColorsToJSON(updateColors) {
56
- return JSON.stringify(exports.UpdateColors$outboundSchema.parse(updateColors));
57
- }
58
- function updateColorsFromJSON(jsonString) {
59
- return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateColors$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateColors' from JSON`);
60
- }
61
- //# sourceMappingURL=updatecolors.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"updatecolors.js","sourceRoot":"","sources":["../../src/models/components/updatecolors.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2CH,gDAEC;AACD,oDAQC;AApDD,0CAA4B;AAC5B,qDAAiD;AAGjD,qDAK0B;AAO1B,gBAAgB;AACH,QAAA,0BAA0B,GAInC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,0CAAyB,CAAC,QAAQ,EAAE;IAC1C,KAAK,EAAE,0CAAyB,CAAC,QAAQ,EAAE;CAC5C,CAAC,CAAC;AAOH,gBAAgB;AACH,QAAA,2BAA2B,GAIpC,CAAC,CAAC,MAAM,CAAC;IACX,IAAI,EAAE,2CAA0B,CAAC,QAAQ,EAAE;IAC3C,KAAK,EAAE,2CAA0B,CAAC,QAAQ,EAAE;CAC7C,CAAC,CAAC;AAEH,SAAgB,kBAAkB,CAAC,YAA0B;IAC3D,OAAO,IAAI,CAAC,SAAS,CAAC,mCAA2B,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC,CAAC;AACzE,CAAC;AACD,SAAgB,oBAAoB,CAClC,UAAkB;IAElB,OAAO,IAAA,sBAAS,EACd,UAAU,EACV,CAAC,CAAC,EAAE,EAAE,CAAC,kCAA0B,CAAC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,EACtD,0CAA0C,CAC3C,CAAC;AACJ,CAAC"}
@@ -1,66 +0,0 @@
1
- import * as z from "zod/v3";
2
- import { Result as SafeParseResult } from "../../types/fp.js";
3
- import * as components from "../components/index.js";
4
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
5
- export type UpdateBrandGlobals = {
6
- /**
7
- * Specify an API version.
8
- *
9
- * @remarks
10
- *
11
- * API versioning follows the format `vYYYY.QQ.BB`, where
12
- * - `YYYY` is the year
13
- * - `QQ` is the two-digit month for the first month of the quarter (e.g., 01, 04, 07, 10)
14
- * - `BB` is the build number, starting at `.01`, for subsequent builds in the same quarter.
15
- * - For example, `v2024.01.00` is the initial release of the first quarter of 2024.
16
- *
17
- * The `latest` version represents the most recent development state. It may include breaking changes and should be treated as a beta release.
18
- * When no version is specified, the API defaults to `v2024.01.00`.
19
- */
20
- xMoovVersion?: string | undefined;
21
- };
22
- export type UpdateBrandRequest = {
23
- accountID: string;
24
- updateBrand: components.UpdateBrand;
25
- };
26
- export type UpdateBrandResponse = {
27
- headers: {
28
- [k: string]: Array<string>;
29
- };
30
- result: components.BrandProperties;
31
- };
32
- /** @internal */
33
- export declare const UpdateBrandGlobals$inboundSchema: z.ZodType<UpdateBrandGlobals, z.ZodTypeDef, unknown>;
34
- /** @internal */
35
- export type UpdateBrandGlobals$Outbound = {
36
- "X-Moov-Version"?: string | undefined;
37
- };
38
- /** @internal */
39
- export declare const UpdateBrandGlobals$outboundSchema: z.ZodType<UpdateBrandGlobals$Outbound, z.ZodTypeDef, UpdateBrandGlobals>;
40
- export declare function updateBrandGlobalsToJSON(updateBrandGlobals: UpdateBrandGlobals): string;
41
- export declare function updateBrandGlobalsFromJSON(jsonString: string): SafeParseResult<UpdateBrandGlobals, SDKValidationError>;
42
- /** @internal */
43
- export declare const UpdateBrandRequest$inboundSchema: z.ZodType<UpdateBrandRequest, z.ZodTypeDef, unknown>;
44
- /** @internal */
45
- export type UpdateBrandRequest$Outbound = {
46
- accountID: string;
47
- UpdateBrand: components.UpdateBrand$Outbound;
48
- };
49
- /** @internal */
50
- export declare const UpdateBrandRequest$outboundSchema: z.ZodType<UpdateBrandRequest$Outbound, z.ZodTypeDef, UpdateBrandRequest>;
51
- export declare function updateBrandRequestToJSON(updateBrandRequest: UpdateBrandRequest): string;
52
- export declare function updateBrandRequestFromJSON(jsonString: string): SafeParseResult<UpdateBrandRequest, SDKValidationError>;
53
- /** @internal */
54
- export declare const UpdateBrandResponse$inboundSchema: z.ZodType<UpdateBrandResponse, z.ZodTypeDef, unknown>;
55
- /** @internal */
56
- export type UpdateBrandResponse$Outbound = {
57
- Headers: {
58
- [k: string]: Array<string>;
59
- };
60
- Result: components.BrandProperties$Outbound;
61
- };
62
- /** @internal */
63
- export declare const UpdateBrandResponse$outboundSchema: z.ZodType<UpdateBrandResponse$Outbound, z.ZodTypeDef, UpdateBrandResponse>;
64
- export declare function updateBrandResponseToJSON(updateBrandResponse: UpdateBrandResponse): string;
65
- export declare function updateBrandResponseFromJSON(jsonString: string): SafeParseResult<UpdateBrandResponse, SDKValidationError>;
66
- //# sourceMappingURL=updatebrand.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"updatebrand.d.ts","sourceRoot":"","sources":["../../src/models/operations/updatebrand.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAG5B,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAC9D,OAAO,KAAK,UAAU,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,kBAAkB,EAAE,MAAM,iCAAiC,CAAC;AAErE,MAAM,MAAM,kBAAkB,GAAG;IAC/B;;;;;;;;;;;;;OAaG;IACH,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACnC,CAAC;AAEF,MAAM,MAAM,kBAAkB,GAAG;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,UAAU,CAAC,WAAW,CAAC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AE,MAAM,GACjB,eAAe,CAAC,kBAAkB,EAAE,kBAAkB,CAAC,CAMzD;AAED,gBAAgB;AAChB,eAAO,MAAM,iCAAiC,EAAE,CAAC,CAAC,OAAO,CACvD,mBAAmB,EACnB,CAAC,CAAC,UAAU,EACZ,OAAO,CASP,CAAC;AACH,gBAAgB;AAChB,MAAM,MAAM,4BAA4B,GAAG;IACzC,OAAO,EAAE;QAAE,CAAC,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC,MAAM,CAAC,CAAA;KAAE,CAAC;IACxC,MAAM,EAAE,UAAU,CAAC,wBAAwB,CAAC;CAC7C,CAAC;AAEF,gBAAgB;AAChB,eAAO,MAAM,kCAAkC,EAAE,CAAC,CAAC,OAAO,CACxD,4BAA4B,EAC5B,CAAC,CAAC,UAAU,EACZ,mBAAmB,CASnB,CAAC;AAEH,wBAAgB,yBAAyB,CACvC,mBAAmB,EAAE,mBAAmB,GACvC,MAAM,CAIR;AACD,wBAAgB,2BAA2B,CACzC,UAAU,EAAE,MAAM,GACjB,eAAe,CAAC,mBAAmB,EAAE,kBAAkB,CAAC,CAM1D"}
@@ -1,122 +0,0 @@
1
- "use strict";
2
- /*
3
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
4
- */
5
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- var desc = Object.getOwnPropertyDescriptor(m, k);
8
- if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
- desc = { enumerable: true, get: function() { return m[k]; } };
10
- }
11
- Object.defineProperty(o, k2, desc);
12
- }) : (function(o, m, k, k2) {
13
- if (k2 === undefined) k2 = k;
14
- o[k2] = m[k];
15
- }));
16
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
- Object.defineProperty(o, "default", { enumerable: true, value: v });
18
- }) : function(o, v) {
19
- o["default"] = v;
20
- });
21
- var __importStar = (this && this.__importStar) || (function () {
22
- var ownKeys = function(o) {
23
- ownKeys = Object.getOwnPropertyNames || function (o) {
24
- var ar = [];
25
- for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
26
- return ar;
27
- };
28
- return ownKeys(o);
29
- };
30
- return function (mod) {
31
- if (mod && mod.__esModule) return mod;
32
- var result = {};
33
- if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
34
- __setModuleDefault(result, mod);
35
- return result;
36
- };
37
- })();
38
- Object.defineProperty(exports, "__esModule", { value: true });
39
- exports.UpdateBrandResponse$outboundSchema = exports.UpdateBrandResponse$inboundSchema = exports.UpdateBrandRequest$outboundSchema = exports.UpdateBrandRequest$inboundSchema = exports.UpdateBrandGlobals$outboundSchema = exports.UpdateBrandGlobals$inboundSchema = void 0;
40
- exports.updateBrandGlobalsToJSON = updateBrandGlobalsToJSON;
41
- exports.updateBrandGlobalsFromJSON = updateBrandGlobalsFromJSON;
42
- exports.updateBrandRequestToJSON = updateBrandRequestToJSON;
43
- exports.updateBrandRequestFromJSON = updateBrandRequestFromJSON;
44
- exports.updateBrandResponseToJSON = updateBrandResponseToJSON;
45
- exports.updateBrandResponseFromJSON = updateBrandResponseFromJSON;
46
- const z = __importStar(require("zod/v3"));
47
- const primitives_js_1 = require("../../lib/primitives.js");
48
- const schemas_js_1 = require("../../lib/schemas.js");
49
- const components = __importStar(require("../components/index.js"));
50
- /** @internal */
51
- exports.UpdateBrandGlobals$inboundSchema = z.object({
52
- "X-Moov-Version": z.string().optional(),
53
- }).transform((v) => {
54
- return (0, primitives_js_1.remap)(v, {
55
- "X-Moov-Version": "xMoovVersion",
56
- });
57
- });
58
- /** @internal */
59
- exports.UpdateBrandGlobals$outboundSchema = z.object({
60
- xMoovVersion: z.string().optional(),
61
- }).transform((v) => {
62
- return (0, primitives_js_1.remap)(v, {
63
- xMoovVersion: "X-Moov-Version",
64
- });
65
- });
66
- function updateBrandGlobalsToJSON(updateBrandGlobals) {
67
- return JSON.stringify(exports.UpdateBrandGlobals$outboundSchema.parse(updateBrandGlobals));
68
- }
69
- function updateBrandGlobalsFromJSON(jsonString) {
70
- return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateBrandGlobals$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateBrandGlobals' from JSON`);
71
- }
72
- /** @internal */
73
- exports.UpdateBrandRequest$inboundSchema = z.object({
74
- accountID: z.string(),
75
- UpdateBrand: components.UpdateBrand$inboundSchema,
76
- }).transform((v) => {
77
- return (0, primitives_js_1.remap)(v, {
78
- "UpdateBrand": "updateBrand",
79
- });
80
- });
81
- /** @internal */
82
- exports.UpdateBrandRequest$outboundSchema = z.object({
83
- accountID: z.string(),
84
- updateBrand: components.UpdateBrand$outboundSchema,
85
- }).transform((v) => {
86
- return (0, primitives_js_1.remap)(v, {
87
- updateBrand: "UpdateBrand",
88
- });
89
- });
90
- function updateBrandRequestToJSON(updateBrandRequest) {
91
- return JSON.stringify(exports.UpdateBrandRequest$outboundSchema.parse(updateBrandRequest));
92
- }
93
- function updateBrandRequestFromJSON(jsonString) {
94
- return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateBrandRequest$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateBrandRequest' from JSON`);
95
- }
96
- /** @internal */
97
- exports.UpdateBrandResponse$inboundSchema = z.object({
98
- Headers: z.record(z.array(z.string())).default({}),
99
- Result: components.BrandProperties$inboundSchema,
100
- }).transform((v) => {
101
- return (0, primitives_js_1.remap)(v, {
102
- "Headers": "headers",
103
- "Result": "result",
104
- });
105
- });
106
- /** @internal */
107
- exports.UpdateBrandResponse$outboundSchema = z.object({
108
- headers: z.record(z.array(z.string())),
109
- result: components.BrandProperties$outboundSchema,
110
- }).transform((v) => {
111
- return (0, primitives_js_1.remap)(v, {
112
- headers: "Headers",
113
- result: "Result",
114
- });
115
- });
116
- function updateBrandResponseToJSON(updateBrandResponse) {
117
- return JSON.stringify(exports.UpdateBrandResponse$outboundSchema.parse(updateBrandResponse));
118
- }
119
- function updateBrandResponseFromJSON(jsonString) {
120
- return (0, schemas_js_1.safeParse)(jsonString, (x) => exports.UpdateBrandResponse$inboundSchema.parse(JSON.parse(x)), `Failed to parse 'UpdateBrandResponse' from JSON`);
121
- }
122
- //# sourceMappingURL=updatebrand.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"updatebrand.js","sourceRoot":"","sources":["../../src/models/operations/updatebrand.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmEH,4DAMC;AACD,gEAQC;AAmCD,4DAMC;AACD,gEAQC;AAqCD,8DAMC;AACD,kEAQC;AAtLD,0CAA4B;AAC5B,2DAA0D;AAC1D,qDAAiD;AAEjD,mEAAqD;AA+BrD,gBAAgB;AACH,QAAA,gCAAgC,GAIzC,CAAC,CAAC,MAAM,CAAC;IACX,gBAAgB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACxC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,gBAAgB,EAAE,cAAc;KACjC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAMH,gBAAgB;AACH,QAAA,iCAAiC,GAI1C,CAAC,CAAC,MAAM,CAAC;IACX,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,EAAE,EAAE;IACjB,OAAO,IAAA,qBAAM,EAAC,CAAC,EAAE;QACf,YAAY,EAAE,gBAAgB;KAC/B,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH,SAAgB,wBAAwB,CACtC,kBAAsC;IAEtC,OAAO,IAAI,CAAC,SAAS,CACnB,yCAAiC,CAAC,KAAK,CAAC,kBAAkB,CAAC,CAC5D,CAAC;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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 {
14
- ConnectionError,
15
- InvalidRequestError,
16
- RequestAbortedError,
17
- RequestTimeoutError,
18
- UnexpectedClientError,
19
- } from "../models/errors/httpclienterrors.js";
20
- import * as errors from "../models/errors/index.js";
21
- import { MoovError } from "../models/errors/mooverror.js";
22
- import { ResponseValidationError } from "../models/errors/responsevalidationerror.js";
23
- import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
24
- import * as operations from "../models/operations/index.js";
25
- import { APICall, APIPromise } from "../types/async.js";
26
- import { Result } from "../types/fp.js";
27
-
28
- /**
29
- * Updates the brand properties for the specified account.
30
- *
31
- * To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
32
- * you'll need to specify the `/accounts/{accountID}/branding.write` scope.
33
- */
34
- export function brandingUpdate(
35
- client: MoovCore,
36
- request: operations.UpdateBrandRequest,
37
- options?: RequestOptions,
38
- ): APIPromise<
39
- Result<
40
- operations.UpdateBrandResponse,
41
- | errors.GenericError
42
- | errors.BrandValidationError
43
- | MoovError
44
- | ResponseValidationError
45
- | ConnectionError
46
- | RequestAbortedError
47
- | RequestTimeoutError
48
- | InvalidRequestError
49
- | UnexpectedClientError
50
- | SDKValidationError
51
- >
52
- > {
53
- return new APIPromise($do(
54
- client,
55
- request,
56
- options,
57
- ));
58
- }
59
-
60
- async function $do(
61
- client: MoovCore,
62
- request: operations.UpdateBrandRequest,
63
- options?: RequestOptions,
64
- ): Promise<
65
- [
66
- Result<
67
- operations.UpdateBrandResponse,
68
- | errors.GenericError
69
- | errors.BrandValidationError
70
- | MoovError
71
- | ResponseValidationError
72
- | ConnectionError
73
- | RequestAbortedError
74
- | RequestTimeoutError
75
- | InvalidRequestError
76
- | UnexpectedClientError
77
- | SDKValidationError
78
- >,
79
- APICall,
80
- ]
81
- > {
82
- const parsed = safeParse(
83
- request,
84
- (value) => operations.UpdateBrandRequest$outboundSchema.parse(value),
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.UpdateBrand, { explode: true });
92
-
93
- const pathParams = {
94
- accountID: encodeSimple("accountID", payload.accountID, {
95
- explode: false,
96
- charEncoding: "percent",
97
- }),
98
- };
99
-
100
- const path = pathToFunc("/accounts/{accountID}/branding")(pathParams);
101
-
102
- const headers = new Headers(compactMap({
103
- "Content-Type": "application/json",
104
- Accept: "application/json",
105
- "X-Moov-Version": encodeSimple(
106
- "X-Moov-Version",
107
- client._options.xMoovVersion,
108
- { explode: false, charEncoding: "none" },
109
- ),
110
- }));
111
-
112
- const securityInput = await extractSecurity(client._options.security);
113
- const requestSecurity = resolveGlobalSecurity(securityInput);
114
-
115
- const context = {
116
- options: client._options,
117
- baseURL: options?.serverURL ?? client._baseURL ?? "",
118
- operationID: "updateBrand",
119
- oAuth2Scopes: null,
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: "PATCH",
133
- baseURL: options?.serverURL,
134
- path: path,
135
- headers: headers,
136
- body: body,
137
- userAgent: client._options.userAgent,
138
- timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
139
- }, options);
140
- if (!requestRes.ok) {
141
- return [requestRes, { status: "invalid" }];
142
- }
143
- const req = requestRes.value;
144
-
145
- const doResult = await client._do(req, {
146
- context,
147
- errorCodes: [
148
- "400",
149
- "401",
150
- "403",
151
- "404",
152
- "409",
153
- "422",
154
- "429",
155
- "4XX",
156
- "500",
157
- "504",
158
- "5XX",
159
- ],
160
- retryConfig: context.retryConfig,
161
- retryCodes: context.retryCodes,
162
- });
163
- if (!doResult.ok) {
164
- return [doResult, { status: "request-error", request: req }];
165
- }
166
- const response = doResult.value;
167
-
168
- const responseFields = {
169
- HttpMeta: { Response: response, Request: req },
170
- };
171
-
172
- const [result] = await M.match<
173
- operations.UpdateBrandResponse,
174
- | errors.GenericError
175
- | errors.BrandValidationError
176
- | MoovError
177
- | ResponseValidationError
178
- | ConnectionError
179
- | RequestAbortedError
180
- | RequestTimeoutError
181
- | InvalidRequestError
182
- | UnexpectedClientError
183
- | SDKValidationError
184
- >(
185
- M.json(200, operations.UpdateBrandResponse$inboundSchema, {
186
- hdrs: true,
187
- key: "Result",
188
- }),
189
- M.jsonErr([400, 409], errors.GenericError$inboundSchema, { hdrs: true }),
190
- M.jsonErr(422, errors.BrandValidationError$inboundSchema, { hdrs: true }),
191
- M.fail([401, 403, 404, 429]),
192
- M.fail([500, 504]),
193
- M.fail("4XX"),
194
- M.fail("5XX"),
195
- )(response, req, { extraFields: responseFields });
196
- if (!result.ok) {
197
- return [result, { status: "complete", request: req, response }];
198
- }
199
-
200
- return [result, { status: "complete", request: req, response }];
201
- }
@@ -1,38 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import { brandingUpdate } from "../../funcs/brandingUpdate.js";
6
- import * as operations from "../../models/operations/index.js";
7
- import { formatResult, ToolDefinition } from "../tools.js";
8
-
9
- const args = {
10
- request: operations.UpdateBrandRequest$inboundSchema,
11
- };
12
-
13
- export const tool$brandingUpdate: ToolDefinition<typeof args> = {
14
- name: "branding-update",
15
- description: `Updates the brand properties for the specified account.
16
-
17
- To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
18
- you'll need to specify the \`/accounts/{accountID}/branding.write\` scope.`,
19
- args,
20
- tool: async (client, args, ctx) => {
21
- const [result, apiCall] = await brandingUpdate(
22
- client,
23
- args.request,
24
- { fetchOptions: { signal: ctx.signal } },
25
- ).$inspect();
26
-
27
- if (!result.ok) {
28
- return {
29
- content: [{ type: "text", text: result.error.message }],
30
- isError: true,
31
- };
32
- }
33
-
34
- const value = result.value.result;
35
-
36
- return formatResult(value, apiCall);
37
- },
38
- };
@@ -1,53 +0,0 @@
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
- UpdateColors,
11
- UpdateColors$inboundSchema,
12
- UpdateColors$Outbound,
13
- UpdateColors$outboundSchema,
14
- } from "./updatecolors.js";
15
-
16
- export type UpdateBrand = {
17
- colors?: UpdateColors | undefined;
18
- };
19
-
20
- /** @internal */
21
- export const UpdateBrand$inboundSchema: z.ZodType<
22
- UpdateBrand,
23
- z.ZodTypeDef,
24
- unknown
25
- > = z.object({
26
- colors: UpdateColors$inboundSchema.optional(),
27
- });
28
- /** @internal */
29
- export type UpdateBrand$Outbound = {
30
- colors?: UpdateColors$Outbound | undefined;
31
- };
32
-
33
- /** @internal */
34
- export const UpdateBrand$outboundSchema: z.ZodType<
35
- UpdateBrand$Outbound,
36
- z.ZodTypeDef,
37
- UpdateBrand
38
- > = z.object({
39
- colors: UpdateColors$outboundSchema.optional(),
40
- });
41
-
42
- export function updateBrandToJSON(updateBrand: UpdateBrand): string {
43
- return JSON.stringify(UpdateBrand$outboundSchema.parse(updateBrand));
44
- }
45
- export function updateBrandFromJSON(
46
- jsonString: string,
47
- ): SafeParseResult<UpdateBrand, SDKValidationError> {
48
- return safeParse(
49
- jsonString,
50
- (x) => UpdateBrand$inboundSchema.parse(JSON.parse(x)),
51
- `Failed to parse 'UpdateBrand' from JSON`,
52
- );
53
- }
@@ -1,47 +0,0 @@
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 UpdateColor = {
11
- accent?: string | undefined;
12
- };
13
-
14
- /** @internal */
15
- export const UpdateColor$inboundSchema: z.ZodType<
16
- UpdateColor,
17
- z.ZodTypeDef,
18
- unknown
19
- > = z.object({
20
- accent: z.string().optional(),
21
- });
22
- /** @internal */
23
- export type UpdateColor$Outbound = {
24
- accent?: string | undefined;
25
- };
26
-
27
- /** @internal */
28
- export const UpdateColor$outboundSchema: z.ZodType<
29
- UpdateColor$Outbound,
30
- z.ZodTypeDef,
31
- UpdateColor
32
- > = z.object({
33
- accent: z.string().optional(),
34
- });
35
-
36
- export function updateColorToJSON(updateColor: UpdateColor): string {
37
- return JSON.stringify(UpdateColor$outboundSchema.parse(updateColor));
38
- }
39
- export function updateColorFromJSON(
40
- jsonString: string,
41
- ): SafeParseResult<UpdateColor, SDKValidationError> {
42
- return safeParse(
43
- jsonString,
44
- (x) => UpdateColor$inboundSchema.parse(JSON.parse(x)),
45
- `Failed to parse 'UpdateColor' from JSON`,
46
- );
47
- }
@@ -1,57 +0,0 @@
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
- UpdateColor,
11
- UpdateColor$inboundSchema,
12
- UpdateColor$Outbound,
13
- UpdateColor$outboundSchema,
14
- } from "./updatecolor.js";
15
-
16
- export type UpdateColors = {
17
- dark?: UpdateColor | undefined;
18
- light?: UpdateColor | undefined;
19
- };
20
-
21
- /** @internal */
22
- export const UpdateColors$inboundSchema: z.ZodType<
23
- UpdateColors,
24
- z.ZodTypeDef,
25
- unknown
26
- > = z.object({
27
- dark: UpdateColor$inboundSchema.optional(),
28
- light: UpdateColor$inboundSchema.optional(),
29
- });
30
- /** @internal */
31
- export type UpdateColors$Outbound = {
32
- dark?: UpdateColor$Outbound | undefined;
33
- light?: UpdateColor$Outbound | undefined;
34
- };
35
-
36
- /** @internal */
37
- export const UpdateColors$outboundSchema: z.ZodType<
38
- UpdateColors$Outbound,
39
- z.ZodTypeDef,
40
- UpdateColors
41
- > = z.object({
42
- dark: UpdateColor$outboundSchema.optional(),
43
- light: UpdateColor$outboundSchema.optional(),
44
- });
45
-
46
- export function updateColorsToJSON(updateColors: UpdateColors): string {
47
- return JSON.stringify(UpdateColors$outboundSchema.parse(updateColors));
48
- }
49
- export function updateColorsFromJSON(
50
- jsonString: string,
51
- ): SafeParseResult<UpdateColors, SDKValidationError> {
52
- return safeParse(
53
- jsonString,
54
- (x) => UpdateColors$inboundSchema.parse(JSON.parse(x)),
55
- `Failed to parse 'UpdateColors' from JSON`,
56
- );
57
- }