@apideck/unify 0.29.8 → 0.29.9

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 (130) hide show
  1. package/README.md +14 -1
  2. package/docs/sdks/bankaccounts/README.md +564 -0
  3. package/examples/accountingTaxRatesList.example.ts +1 -1
  4. package/examples/package-lock.json +1 -1
  5. package/funcs/accountingBankAccountsCreate.d.ts +18 -0
  6. package/funcs/accountingBankAccountsCreate.d.ts.map +1 -0
  7. package/funcs/accountingBankAccountsCreate.js +139 -0
  8. package/funcs/accountingBankAccountsCreate.js.map +1 -0
  9. package/funcs/accountingBankAccountsDelete.d.ts +18 -0
  10. package/funcs/accountingBankAccountsDelete.d.ts.map +1 -0
  11. package/funcs/accountingBankAccountsDelete.js +142 -0
  12. package/funcs/accountingBankAccountsDelete.js.map +1 -0
  13. package/funcs/accountingBankAccountsGet.d.ts +18 -0
  14. package/funcs/accountingBankAccountsGet.d.ts.map +1 -0
  15. package/funcs/accountingBankAccountsGet.js +143 -0
  16. package/funcs/accountingBankAccountsGet.js.map +1 -0
  17. package/funcs/accountingBankAccountsList.d.ts +21 -0
  18. package/funcs/accountingBankAccountsList.d.ts.map +1 -0
  19. package/funcs/accountingBankAccountsList.js +168 -0
  20. package/funcs/accountingBankAccountsList.js.map +1 -0
  21. package/funcs/accountingBankAccountsUpdate.d.ts +18 -0
  22. package/funcs/accountingBankAccountsUpdate.d.ts.map +1 -0
  23. package/funcs/accountingBankAccountsUpdate.js +145 -0
  24. package/funcs/accountingBankAccountsUpdate.js.map +1 -0
  25. package/jsr.json +1 -1
  26. package/lib/config.d.ts +4 -4
  27. package/lib/config.js +4 -4
  28. package/models/components/accountingbankaccount.d.ts +348 -0
  29. package/models/components/accountingbankaccount.d.ts.map +1 -0
  30. package/models/components/accountingbankaccount.js +298 -0
  31. package/models/components/accountingbankaccount.js.map +1 -0
  32. package/models/components/bankaccountsfilter.d.ts +72 -0
  33. package/models/components/bankaccountsfilter.d.ts.map +1 -0
  34. package/models/components/bankaccountsfilter.js +94 -0
  35. package/models/components/bankaccountsfilter.js.map +1 -0
  36. package/models/components/bankaccountssort.d.ts +70 -0
  37. package/models/components/bankaccountssort.d.ts.map +1 -0
  38. package/models/components/bankaccountssort.js +95 -0
  39. package/models/components/bankaccountssort.js.map +1 -0
  40. package/models/components/createbankaccountresponse.d.ts +61 -0
  41. package/models/components/createbankaccountresponse.d.ts.map +1 -0
  42. package/models/components/createbankaccountresponse.js +89 -0
  43. package/models/components/createbankaccountresponse.js.map +1 -0
  44. package/models/components/deletebankaccountresponse.d.ts +61 -0
  45. package/models/components/deletebankaccountresponse.d.ts.map +1 -0
  46. package/models/components/deletebankaccountresponse.js +89 -0
  47. package/models/components/deletebankaccountresponse.js.map +1 -0
  48. package/models/components/getbankaccountresponse.d.ts +58 -0
  49. package/models/components/getbankaccountresponse.d.ts.map +1 -0
  50. package/models/components/getbankaccountresponse.js +89 -0
  51. package/models/components/getbankaccountresponse.js.map +1 -0
  52. package/models/components/getbankaccountsresponse.d.ts +70 -0
  53. package/models/components/getbankaccountsresponse.d.ts.map +1 -0
  54. package/models/components/getbankaccountsresponse.js +95 -0
  55. package/models/components/getbankaccountsresponse.js.map +1 -0
  56. package/models/components/index.d.ts +8 -0
  57. package/models/components/index.d.ts.map +1 -1
  58. package/models/components/index.js +8 -0
  59. package/models/components/index.js.map +1 -1
  60. package/models/components/logsfilter.d.ts +8 -0
  61. package/models/components/logsfilter.d.ts.map +1 -1
  62. package/models/components/logsfilter.js +4 -0
  63. package/models/components/logsfilter.js.map +1 -1
  64. package/models/components/updatebankaccountresponse.d.ts +61 -0
  65. package/models/components/updatebankaccountresponse.d.ts.map +1 -0
  66. package/models/components/updatebankaccountresponse.js +89 -0
  67. package/models/components/updatebankaccountresponse.js.map +1 -0
  68. package/models/errors/index.d.ts +1 -0
  69. package/models/errors/index.d.ts.map +1 -1
  70. package/models/errors/index.js +1 -0
  71. package/models/errors/index.js.map +1 -1
  72. package/models/operations/accountingbankaccountsadd.d.ts +118 -0
  73. package/models/operations/accountingbankaccountsadd.d.ts.map +1 -0
  74. package/models/operations/accountingbankaccountsadd.js +163 -0
  75. package/models/operations/accountingbankaccountsadd.js.map +1 -0
  76. package/models/operations/accountingbankaccountsall.d.ts +150 -0
  77. package/models/operations/accountingbankaccountsall.d.ts.map +1 -0
  78. package/models/operations/accountingbankaccountsall.js +173 -0
  79. package/models/operations/accountingbankaccountsall.js.map +1 -0
  80. package/models/operations/accountingbankaccountsdelete.d.ts +121 -0
  81. package/models/operations/accountingbankaccountsdelete.d.ts.map +1 -0
  82. package/models/operations/accountingbankaccountsdelete.js +155 -0
  83. package/models/operations/accountingbankaccountsdelete.js.map +1 -0
  84. package/models/operations/accountingbankaccountsone.d.ts +126 -0
  85. package/models/operations/accountingbankaccountsone.d.ts.map +1 -0
  86. package/models/operations/accountingbankaccountsone.js +157 -0
  87. package/models/operations/accountingbankaccountsone.js.map +1 -0
  88. package/models/operations/accountingbankaccountsupdate.d.ts +123 -0
  89. package/models/operations/accountingbankaccountsupdate.d.ts.map +1 -0
  90. package/models/operations/accountingbankaccountsupdate.js +165 -0
  91. package/models/operations/accountingbankaccountsupdate.js.map +1 -0
  92. package/models/operations/index.d.ts +5 -0
  93. package/models/operations/index.d.ts.map +1 -1
  94. package/models/operations/index.js +5 -0
  95. package/models/operations/index.js.map +1 -1
  96. package/package.json +1 -1
  97. package/sdk/accounting.d.ts +3 -0
  98. package/sdk/accounting.d.ts.map +1 -1
  99. package/sdk/accounting.js +4 -0
  100. package/sdk/accounting.js.map +1 -1
  101. package/sdk/bankaccounts.d.ts +43 -0
  102. package/sdk/bankaccounts.d.ts.map +1 -0
  103. package/sdk/bankaccounts.js +63 -0
  104. package/sdk/bankaccounts.js.map +1 -0
  105. package/src/__tests__/bankaccounts.test.ts +293 -0
  106. package/src/funcs/accountingBankAccountsCreate.ts +225 -0
  107. package/src/funcs/accountingBankAccountsDelete.ts +231 -0
  108. package/src/funcs/accountingBankAccountsGet.ts +230 -0
  109. package/src/funcs/accountingBankAccountsList.ts +303 -0
  110. package/src/funcs/accountingBankAccountsUpdate.ts +234 -0
  111. package/src/lib/config.ts +4 -4
  112. package/src/models/components/accountingbankaccount.ts +576 -0
  113. package/src/models/components/bankaccountsfilter.ts +113 -0
  114. package/src/models/components/bankaccountssort.ts +113 -0
  115. package/src/models/components/createbankaccountresponse.ts +122 -0
  116. package/src/models/components/deletebankaccountresponse.ts +122 -0
  117. package/src/models/components/getbankaccountresponse.ts +119 -0
  118. package/src/models/components/getbankaccountsresponse.ts +145 -0
  119. package/src/models/components/index.ts +8 -0
  120. package/src/models/components/logsfilter.ts +12 -0
  121. package/src/models/components/updatebankaccountresponse.ts +122 -0
  122. package/src/models/errors/index.ts +1 -0
  123. package/src/models/operations/accountingbankaccountsadd.ts +271 -0
  124. package/src/models/operations/accountingbankaccountsall.ts +309 -0
  125. package/src/models/operations/accountingbankaccountsdelete.ts +274 -0
  126. package/src/models/operations/accountingbankaccountsone.ts +273 -0
  127. package/src/models/operations/accountingbankaccountsupdate.ts +286 -0
  128. package/src/models/operations/index.ts +5 -0
  129. package/src/sdk/accounting.ts +6 -0
  130. package/src/sdk/bankaccounts.ts +105 -0
@@ -0,0 +1,113 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { safeParse } from "../../lib/schemas.js";
7
+ import { ClosedEnum } from "../../types/enums.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ SortDirection,
12
+ SortDirection$inboundSchema,
13
+ SortDirection$outboundSchema,
14
+ } from "./sortdirection.js";
15
+
16
+ /**
17
+ * The field to sort by
18
+ */
19
+ export const SortBy = {
20
+ CreatedAt: "created_at",
21
+ UpdatedAt: "updated_at",
22
+ } as const;
23
+ /**
24
+ * The field to sort by
25
+ */
26
+ export type SortBy = ClosedEnum<typeof SortBy>;
27
+
28
+ export type BankAccountsSort = {
29
+ /**
30
+ * The field to sort by
31
+ */
32
+ by?: SortBy | undefined;
33
+ /**
34
+ * The direction in which to sort the results
35
+ */
36
+ direction?: SortDirection | undefined;
37
+ };
38
+
39
+ /** @internal */
40
+ export const SortBy$inboundSchema: z.ZodNativeEnum<typeof SortBy> = z
41
+ .nativeEnum(SortBy);
42
+
43
+ /** @internal */
44
+ export const SortBy$outboundSchema: z.ZodNativeEnum<typeof SortBy> =
45
+ SortBy$inboundSchema;
46
+
47
+ /**
48
+ * @internal
49
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
50
+ */
51
+ export namespace SortBy$ {
52
+ /** @deprecated use `SortBy$inboundSchema` instead. */
53
+ export const inboundSchema = SortBy$inboundSchema;
54
+ /** @deprecated use `SortBy$outboundSchema` instead. */
55
+ export const outboundSchema = SortBy$outboundSchema;
56
+ }
57
+
58
+ /** @internal */
59
+ export const BankAccountsSort$inboundSchema: z.ZodType<
60
+ BankAccountsSort,
61
+ z.ZodTypeDef,
62
+ unknown
63
+ > = z.object({
64
+ by: SortBy$inboundSchema.default("updated_at"),
65
+ direction: SortDirection$inboundSchema.default("asc"),
66
+ });
67
+
68
+ /** @internal */
69
+ export type BankAccountsSort$Outbound = {
70
+ by: string;
71
+ direction: string;
72
+ };
73
+
74
+ /** @internal */
75
+ export const BankAccountsSort$outboundSchema: z.ZodType<
76
+ BankAccountsSort$Outbound,
77
+ z.ZodTypeDef,
78
+ BankAccountsSort
79
+ > = z.object({
80
+ by: SortBy$outboundSchema.default("updated_at"),
81
+ direction: SortDirection$outboundSchema.default("asc"),
82
+ });
83
+
84
+ /**
85
+ * @internal
86
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
87
+ */
88
+ export namespace BankAccountsSort$ {
89
+ /** @deprecated use `BankAccountsSort$inboundSchema` instead. */
90
+ export const inboundSchema = BankAccountsSort$inboundSchema;
91
+ /** @deprecated use `BankAccountsSort$outboundSchema` instead. */
92
+ export const outboundSchema = BankAccountsSort$outboundSchema;
93
+ /** @deprecated use `BankAccountsSort$Outbound` instead. */
94
+ export type Outbound = BankAccountsSort$Outbound;
95
+ }
96
+
97
+ export function bankAccountsSortToJSON(
98
+ bankAccountsSort: BankAccountsSort,
99
+ ): string {
100
+ return JSON.stringify(
101
+ BankAccountsSort$outboundSchema.parse(bankAccountsSort),
102
+ );
103
+ }
104
+
105
+ export function bankAccountsSortFromJSON(
106
+ jsonString: string,
107
+ ): SafeParseResult<BankAccountsSort, SDKValidationError> {
108
+ return safeParse(
109
+ jsonString,
110
+ (x) => BankAccountsSort$inboundSchema.parse(JSON.parse(x)),
111
+ `Failed to parse 'BankAccountsSort' from JSON`,
112
+ );
113
+ }
@@ -0,0 +1,122 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ UnifiedId,
12
+ UnifiedId$inboundSchema,
13
+ UnifiedId$Outbound,
14
+ UnifiedId$outboundSchema,
15
+ } from "./unifiedid.js";
16
+
17
+ /**
18
+ * Bank Account created
19
+ */
20
+ export type CreateBankAccountResponse = {
21
+ /**
22
+ * HTTP Response Status Code
23
+ */
24
+ statusCode: number;
25
+ /**
26
+ * HTTP Response Status
27
+ */
28
+ status: string;
29
+ /**
30
+ * Apideck ID of service provider
31
+ */
32
+ service?: string | undefined;
33
+ /**
34
+ * Unified API resource name
35
+ */
36
+ resource?: string | undefined;
37
+ /**
38
+ * Operation performed
39
+ */
40
+ operation?: string | undefined;
41
+ /**
42
+ * A object containing a unique identifier for the resource that was created, updated, or deleted.
43
+ */
44
+ data: UnifiedId;
45
+ };
46
+
47
+ /** @internal */
48
+ export const CreateBankAccountResponse$inboundSchema: z.ZodType<
49
+ CreateBankAccountResponse,
50
+ z.ZodTypeDef,
51
+ unknown
52
+ > = z.object({
53
+ status_code: z.number().int(),
54
+ status: z.string(),
55
+ service: z.string().optional(),
56
+ resource: z.string().optional(),
57
+ operation: z.string().optional(),
58
+ data: UnifiedId$inboundSchema,
59
+ }).transform((v) => {
60
+ return remap$(v, {
61
+ "status_code": "statusCode",
62
+ });
63
+ });
64
+
65
+ /** @internal */
66
+ export type CreateBankAccountResponse$Outbound = {
67
+ status_code: number;
68
+ status: string;
69
+ service?: string | undefined;
70
+ resource?: string | undefined;
71
+ operation?: string | undefined;
72
+ data: UnifiedId$Outbound;
73
+ };
74
+
75
+ /** @internal */
76
+ export const CreateBankAccountResponse$outboundSchema: z.ZodType<
77
+ CreateBankAccountResponse$Outbound,
78
+ z.ZodTypeDef,
79
+ CreateBankAccountResponse
80
+ > = z.object({
81
+ statusCode: z.number().int(),
82
+ status: z.string(),
83
+ service: z.string().optional(),
84
+ resource: z.string().optional(),
85
+ operation: z.string().optional(),
86
+ data: UnifiedId$outboundSchema,
87
+ }).transform((v) => {
88
+ return remap$(v, {
89
+ statusCode: "status_code",
90
+ });
91
+ });
92
+
93
+ /**
94
+ * @internal
95
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
96
+ */
97
+ export namespace CreateBankAccountResponse$ {
98
+ /** @deprecated use `CreateBankAccountResponse$inboundSchema` instead. */
99
+ export const inboundSchema = CreateBankAccountResponse$inboundSchema;
100
+ /** @deprecated use `CreateBankAccountResponse$outboundSchema` instead. */
101
+ export const outboundSchema = CreateBankAccountResponse$outboundSchema;
102
+ /** @deprecated use `CreateBankAccountResponse$Outbound` instead. */
103
+ export type Outbound = CreateBankAccountResponse$Outbound;
104
+ }
105
+
106
+ export function createBankAccountResponseToJSON(
107
+ createBankAccountResponse: CreateBankAccountResponse,
108
+ ): string {
109
+ return JSON.stringify(
110
+ CreateBankAccountResponse$outboundSchema.parse(createBankAccountResponse),
111
+ );
112
+ }
113
+
114
+ export function createBankAccountResponseFromJSON(
115
+ jsonString: string,
116
+ ): SafeParseResult<CreateBankAccountResponse, SDKValidationError> {
117
+ return safeParse(
118
+ jsonString,
119
+ (x) => CreateBankAccountResponse$inboundSchema.parse(JSON.parse(x)),
120
+ `Failed to parse 'CreateBankAccountResponse' from JSON`,
121
+ );
122
+ }
@@ -0,0 +1,122 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ UnifiedId,
12
+ UnifiedId$inboundSchema,
13
+ UnifiedId$Outbound,
14
+ UnifiedId$outboundSchema,
15
+ } from "./unifiedid.js";
16
+
17
+ /**
18
+ * Bank Account deleted
19
+ */
20
+ export type DeleteBankAccountResponse = {
21
+ /**
22
+ * HTTP Response Status Code
23
+ */
24
+ statusCode: number;
25
+ /**
26
+ * HTTP Response Status
27
+ */
28
+ status: string;
29
+ /**
30
+ * Apideck ID of service provider
31
+ */
32
+ service?: string | undefined;
33
+ /**
34
+ * Unified API resource name
35
+ */
36
+ resource?: string | undefined;
37
+ /**
38
+ * Operation performed
39
+ */
40
+ operation?: string | undefined;
41
+ /**
42
+ * A object containing a unique identifier for the resource that was created, updated, or deleted.
43
+ */
44
+ data: UnifiedId;
45
+ };
46
+
47
+ /** @internal */
48
+ export const DeleteBankAccountResponse$inboundSchema: z.ZodType<
49
+ DeleteBankAccountResponse,
50
+ z.ZodTypeDef,
51
+ unknown
52
+ > = z.object({
53
+ status_code: z.number().int(),
54
+ status: z.string(),
55
+ service: z.string().optional(),
56
+ resource: z.string().optional(),
57
+ operation: z.string().optional(),
58
+ data: UnifiedId$inboundSchema,
59
+ }).transform((v) => {
60
+ return remap$(v, {
61
+ "status_code": "statusCode",
62
+ });
63
+ });
64
+
65
+ /** @internal */
66
+ export type DeleteBankAccountResponse$Outbound = {
67
+ status_code: number;
68
+ status: string;
69
+ service?: string | undefined;
70
+ resource?: string | undefined;
71
+ operation?: string | undefined;
72
+ data: UnifiedId$Outbound;
73
+ };
74
+
75
+ /** @internal */
76
+ export const DeleteBankAccountResponse$outboundSchema: z.ZodType<
77
+ DeleteBankAccountResponse$Outbound,
78
+ z.ZodTypeDef,
79
+ DeleteBankAccountResponse
80
+ > = z.object({
81
+ statusCode: z.number().int(),
82
+ status: z.string(),
83
+ service: z.string().optional(),
84
+ resource: z.string().optional(),
85
+ operation: z.string().optional(),
86
+ data: UnifiedId$outboundSchema,
87
+ }).transform((v) => {
88
+ return remap$(v, {
89
+ statusCode: "status_code",
90
+ });
91
+ });
92
+
93
+ /**
94
+ * @internal
95
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
96
+ */
97
+ export namespace DeleteBankAccountResponse$ {
98
+ /** @deprecated use `DeleteBankAccountResponse$inboundSchema` instead. */
99
+ export const inboundSchema = DeleteBankAccountResponse$inboundSchema;
100
+ /** @deprecated use `DeleteBankAccountResponse$outboundSchema` instead. */
101
+ export const outboundSchema = DeleteBankAccountResponse$outboundSchema;
102
+ /** @deprecated use `DeleteBankAccountResponse$Outbound` instead. */
103
+ export type Outbound = DeleteBankAccountResponse$Outbound;
104
+ }
105
+
106
+ export function deleteBankAccountResponseToJSON(
107
+ deleteBankAccountResponse: DeleteBankAccountResponse,
108
+ ): string {
109
+ return JSON.stringify(
110
+ DeleteBankAccountResponse$outboundSchema.parse(deleteBankAccountResponse),
111
+ );
112
+ }
113
+
114
+ export function deleteBankAccountResponseFromJSON(
115
+ jsonString: string,
116
+ ): SafeParseResult<DeleteBankAccountResponse, SDKValidationError> {
117
+ return safeParse(
118
+ jsonString,
119
+ (x) => DeleteBankAccountResponse$inboundSchema.parse(JSON.parse(x)),
120
+ `Failed to parse 'DeleteBankAccountResponse' from JSON`,
121
+ );
122
+ }
@@ -0,0 +1,119 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ AccountingBankAccount,
12
+ AccountingBankAccount$inboundSchema,
13
+ AccountingBankAccount$Outbound,
14
+ AccountingBankAccount$outboundSchema,
15
+ } from "./accountingbankaccount.js";
16
+
17
+ /**
18
+ * Bank Account
19
+ */
20
+ export type GetBankAccountResponse = {
21
+ /**
22
+ * HTTP Response Status Code
23
+ */
24
+ statusCode: number;
25
+ /**
26
+ * HTTP Response Status
27
+ */
28
+ status: string;
29
+ /**
30
+ * Apideck ID of service provider
31
+ */
32
+ service?: string | undefined;
33
+ /**
34
+ * Unified API resource name
35
+ */
36
+ resource?: string | undefined;
37
+ /**
38
+ * Operation performed
39
+ */
40
+ operation?: string | undefined;
41
+ data: AccountingBankAccount;
42
+ };
43
+
44
+ /** @internal */
45
+ export const GetBankAccountResponse$inboundSchema: z.ZodType<
46
+ GetBankAccountResponse,
47
+ z.ZodTypeDef,
48
+ unknown
49
+ > = z.object({
50
+ status_code: z.number().int(),
51
+ status: z.string(),
52
+ service: z.string().optional(),
53
+ resource: z.string().optional(),
54
+ operation: z.string().optional(),
55
+ data: AccountingBankAccount$inboundSchema,
56
+ }).transform((v) => {
57
+ return remap$(v, {
58
+ "status_code": "statusCode",
59
+ });
60
+ });
61
+
62
+ /** @internal */
63
+ export type GetBankAccountResponse$Outbound = {
64
+ status_code: number;
65
+ status: string;
66
+ service?: string | undefined;
67
+ resource?: string | undefined;
68
+ operation?: string | undefined;
69
+ data: AccountingBankAccount$Outbound;
70
+ };
71
+
72
+ /** @internal */
73
+ export const GetBankAccountResponse$outboundSchema: z.ZodType<
74
+ GetBankAccountResponse$Outbound,
75
+ z.ZodTypeDef,
76
+ GetBankAccountResponse
77
+ > = z.object({
78
+ statusCode: z.number().int(),
79
+ status: z.string(),
80
+ service: z.string().optional(),
81
+ resource: z.string().optional(),
82
+ operation: z.string().optional(),
83
+ data: AccountingBankAccount$outboundSchema,
84
+ }).transform((v) => {
85
+ return remap$(v, {
86
+ statusCode: "status_code",
87
+ });
88
+ });
89
+
90
+ /**
91
+ * @internal
92
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
93
+ */
94
+ export namespace GetBankAccountResponse$ {
95
+ /** @deprecated use `GetBankAccountResponse$inboundSchema` instead. */
96
+ export const inboundSchema = GetBankAccountResponse$inboundSchema;
97
+ /** @deprecated use `GetBankAccountResponse$outboundSchema` instead. */
98
+ export const outboundSchema = GetBankAccountResponse$outboundSchema;
99
+ /** @deprecated use `GetBankAccountResponse$Outbound` instead. */
100
+ export type Outbound = GetBankAccountResponse$Outbound;
101
+ }
102
+
103
+ export function getBankAccountResponseToJSON(
104
+ getBankAccountResponse: GetBankAccountResponse,
105
+ ): string {
106
+ return JSON.stringify(
107
+ GetBankAccountResponse$outboundSchema.parse(getBankAccountResponse),
108
+ );
109
+ }
110
+
111
+ export function getBankAccountResponseFromJSON(
112
+ jsonString: string,
113
+ ): SafeParseResult<GetBankAccountResponse, SDKValidationError> {
114
+ return safeParse(
115
+ jsonString,
116
+ (x) => GetBankAccountResponse$inboundSchema.parse(JSON.parse(x)),
117
+ `Failed to parse 'GetBankAccountResponse' from JSON`,
118
+ );
119
+ }
@@ -0,0 +1,145 @@
1
+ /*
2
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
+ */
4
+
5
+ import * as z from "zod";
6
+ import { remap as remap$ } from "../../lib/primitives.js";
7
+ import { safeParse } from "../../lib/schemas.js";
8
+ import { Result as SafeParseResult } from "../../types/fp.js";
9
+ import { SDKValidationError } from "../errors/sdkvalidationerror.js";
10
+ import {
11
+ AccountingBankAccount,
12
+ AccountingBankAccount$inboundSchema,
13
+ AccountingBankAccount$Outbound,
14
+ AccountingBankAccount$outboundSchema,
15
+ } from "./accountingbankaccount.js";
16
+ import {
17
+ Links,
18
+ Links$inboundSchema,
19
+ Links$Outbound,
20
+ Links$outboundSchema,
21
+ } from "./links.js";
22
+ import {
23
+ Meta,
24
+ Meta$inboundSchema,
25
+ Meta$Outbound,
26
+ Meta$outboundSchema,
27
+ } from "./meta.js";
28
+
29
+ /**
30
+ * Bank Accounts
31
+ */
32
+ export type GetBankAccountsResponse = {
33
+ /**
34
+ * HTTP Response Status Code
35
+ */
36
+ statusCode: number;
37
+ /**
38
+ * HTTP Response Status
39
+ */
40
+ status: string;
41
+ /**
42
+ * Apideck ID of service provider
43
+ */
44
+ service?: string | undefined;
45
+ /**
46
+ * Unified API resource name
47
+ */
48
+ resource?: string | undefined;
49
+ /**
50
+ * Operation performed
51
+ */
52
+ operation?: string | undefined;
53
+ data: Array<AccountingBankAccount>;
54
+ /**
55
+ * Response metadata
56
+ */
57
+ meta?: Meta | undefined;
58
+ /**
59
+ * Links to navigate to previous or next pages through the API
60
+ */
61
+ links?: Links | undefined;
62
+ };
63
+
64
+ /** @internal */
65
+ export const GetBankAccountsResponse$inboundSchema: z.ZodType<
66
+ GetBankAccountsResponse,
67
+ z.ZodTypeDef,
68
+ unknown
69
+ > = z.object({
70
+ status_code: z.number().int(),
71
+ status: z.string(),
72
+ service: z.string().optional(),
73
+ resource: z.string().optional(),
74
+ operation: z.string().optional(),
75
+ data: z.array(AccountingBankAccount$inboundSchema),
76
+ meta: Meta$inboundSchema.optional(),
77
+ links: Links$inboundSchema.optional(),
78
+ }).transform((v) => {
79
+ return remap$(v, {
80
+ "status_code": "statusCode",
81
+ });
82
+ });
83
+
84
+ /** @internal */
85
+ export type GetBankAccountsResponse$Outbound = {
86
+ status_code: number;
87
+ status: string;
88
+ service?: string | undefined;
89
+ resource?: string | undefined;
90
+ operation?: string | undefined;
91
+ data: Array<AccountingBankAccount$Outbound>;
92
+ meta?: Meta$Outbound | undefined;
93
+ links?: Links$Outbound | undefined;
94
+ };
95
+
96
+ /** @internal */
97
+ export const GetBankAccountsResponse$outboundSchema: z.ZodType<
98
+ GetBankAccountsResponse$Outbound,
99
+ z.ZodTypeDef,
100
+ GetBankAccountsResponse
101
+ > = z.object({
102
+ statusCode: z.number().int(),
103
+ status: z.string(),
104
+ service: z.string().optional(),
105
+ resource: z.string().optional(),
106
+ operation: z.string().optional(),
107
+ data: z.array(AccountingBankAccount$outboundSchema),
108
+ meta: Meta$outboundSchema.optional(),
109
+ links: Links$outboundSchema.optional(),
110
+ }).transform((v) => {
111
+ return remap$(v, {
112
+ statusCode: "status_code",
113
+ });
114
+ });
115
+
116
+ /**
117
+ * @internal
118
+ * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
119
+ */
120
+ export namespace GetBankAccountsResponse$ {
121
+ /** @deprecated use `GetBankAccountsResponse$inboundSchema` instead. */
122
+ export const inboundSchema = GetBankAccountsResponse$inboundSchema;
123
+ /** @deprecated use `GetBankAccountsResponse$outboundSchema` instead. */
124
+ export const outboundSchema = GetBankAccountsResponse$outboundSchema;
125
+ /** @deprecated use `GetBankAccountsResponse$Outbound` instead. */
126
+ export type Outbound = GetBankAccountsResponse$Outbound;
127
+ }
128
+
129
+ export function getBankAccountsResponseToJSON(
130
+ getBankAccountsResponse: GetBankAccountsResponse,
131
+ ): string {
132
+ return JSON.stringify(
133
+ GetBankAccountsResponse$outboundSchema.parse(getBankAccountsResponse),
134
+ );
135
+ }
136
+
137
+ export function getBankAccountsResponseFromJSON(
138
+ jsonString: string,
139
+ ): SafeParseResult<GetBankAccountsResponse, SDKValidationError> {
140
+ return safeParse(
141
+ jsonString,
142
+ (x) => GetBankAccountsResponse$inboundSchema.parse(JSON.parse(x)),
143
+ `Failed to parse 'GetBankAccountsResponse' from JSON`,
144
+ );
145
+ }
@@ -2,6 +2,7 @@
2
2
  * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
3
  */
4
4
 
5
+ export * from "./accountingbankaccount.js";
5
6
  export * from "./accountingdepartment.js";
6
7
  export * from "./accountingdepartmentsfilter.js";
7
8
  export * from "./accountinglocation.js";
@@ -35,6 +36,8 @@ export * from "./balancesheet.js";
35
36
  export * from "./balancesheetfilter.js";
36
37
  export * from "./bankaccount.js";
37
38
  export * from "./bankaccount1.js";
39
+ export * from "./bankaccountsfilter.js";
40
+ export * from "./bankaccountssort.js";
38
41
  export * from "./bankfeedaccount.js";
39
42
  export * from "./bankfeedstatement.js";
40
43
  export * from "./benefit.js";
@@ -85,6 +88,7 @@ export * from "./createactivityresponse.js";
85
88
  export * from "./createapplicantresponse.js";
86
89
  export * from "./createapplicationresponse.js";
87
90
  export * from "./createattachmentresponse.js";
91
+ export * from "./createbankaccountresponse.js";
88
92
  export * from "./createbankfeedaccountresponse.js";
89
93
  export * from "./createbankfeedstatementresponse.js";
90
94
  export * from "./createbillpaymentresponse.js";
@@ -158,6 +162,7 @@ export * from "./deleteactivityresponse.js";
158
162
  export * from "./deleteapplicantresponse.js";
159
163
  export * from "./deleteapplicationresponse.js";
160
164
  export * from "./deleteattachmentresponse.js";
165
+ export * from "./deletebankaccountresponse.js";
161
166
  export * from "./deletebankfeedaccountresponse.js";
162
167
  export * from "./deletebankfeedstatementresponse.js";
163
168
  export * from "./deletebillpaymentresponse.js";
@@ -264,6 +269,8 @@ export * from "./getapplicationsresponse.js";
264
269
  export * from "./getattachmentresponse.js";
265
270
  export * from "./getattachmentsresponse.js";
266
271
  export * from "./getbalancesheetresponse.js";
272
+ export * from "./getbankaccountresponse.js";
273
+ export * from "./getbankaccountsresponse.js";
267
274
  export * from "./getbankfeedaccountresponse.js";
268
275
  export * from "./getbankfeedaccountsresponse.js";
269
276
  export * from "./getbankfeedstatementresponse.js";
@@ -508,6 +515,7 @@ export * from "./updateaccountinglocationresponse.js";
508
515
  export * from "./updateactivityresponse.js";
509
516
  export * from "./updateapplicantresponse.js";
510
517
  export * from "./updateapplicationresponse.js";
518
+ export * from "./updatebankaccountresponse.js";
511
519
  export * from "./updatebankfeedaccountresponse.js";
512
520
  export * from "./updatebankfeedstatementresponse.js";
513
521
  export * from "./updatebillpaymentresponse.js";