@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.
- package/README.md +14 -1
- package/docs/sdks/bankaccounts/README.md +564 -0
- package/examples/accountingTaxRatesList.example.ts +1 -1
- package/examples/package-lock.json +1 -1
- package/funcs/accountingBankAccountsCreate.d.ts +18 -0
- package/funcs/accountingBankAccountsCreate.d.ts.map +1 -0
- package/funcs/accountingBankAccountsCreate.js +139 -0
- package/funcs/accountingBankAccountsCreate.js.map +1 -0
- package/funcs/accountingBankAccountsDelete.d.ts +18 -0
- package/funcs/accountingBankAccountsDelete.d.ts.map +1 -0
- package/funcs/accountingBankAccountsDelete.js +142 -0
- package/funcs/accountingBankAccountsDelete.js.map +1 -0
- package/funcs/accountingBankAccountsGet.d.ts +18 -0
- package/funcs/accountingBankAccountsGet.d.ts.map +1 -0
- package/funcs/accountingBankAccountsGet.js +143 -0
- package/funcs/accountingBankAccountsGet.js.map +1 -0
- package/funcs/accountingBankAccountsList.d.ts +21 -0
- package/funcs/accountingBankAccountsList.d.ts.map +1 -0
- package/funcs/accountingBankAccountsList.js +168 -0
- package/funcs/accountingBankAccountsList.js.map +1 -0
- package/funcs/accountingBankAccountsUpdate.d.ts +18 -0
- package/funcs/accountingBankAccountsUpdate.d.ts.map +1 -0
- package/funcs/accountingBankAccountsUpdate.js +145 -0
- package/funcs/accountingBankAccountsUpdate.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +4 -4
- package/lib/config.js +4 -4
- package/models/components/accountingbankaccount.d.ts +348 -0
- package/models/components/accountingbankaccount.d.ts.map +1 -0
- package/models/components/accountingbankaccount.js +298 -0
- package/models/components/accountingbankaccount.js.map +1 -0
- package/models/components/bankaccountsfilter.d.ts +72 -0
- package/models/components/bankaccountsfilter.d.ts.map +1 -0
- package/models/components/bankaccountsfilter.js +94 -0
- package/models/components/bankaccountsfilter.js.map +1 -0
- package/models/components/bankaccountssort.d.ts +70 -0
- package/models/components/bankaccountssort.d.ts.map +1 -0
- package/models/components/bankaccountssort.js +95 -0
- package/models/components/bankaccountssort.js.map +1 -0
- package/models/components/createbankaccountresponse.d.ts +61 -0
- package/models/components/createbankaccountresponse.d.ts.map +1 -0
- package/models/components/createbankaccountresponse.js +89 -0
- package/models/components/createbankaccountresponse.js.map +1 -0
- package/models/components/deletebankaccountresponse.d.ts +61 -0
- package/models/components/deletebankaccountresponse.d.ts.map +1 -0
- package/models/components/deletebankaccountresponse.js +89 -0
- package/models/components/deletebankaccountresponse.js.map +1 -0
- package/models/components/getbankaccountresponse.d.ts +58 -0
- package/models/components/getbankaccountresponse.d.ts.map +1 -0
- package/models/components/getbankaccountresponse.js +89 -0
- package/models/components/getbankaccountresponse.js.map +1 -0
- package/models/components/getbankaccountsresponse.d.ts +70 -0
- package/models/components/getbankaccountsresponse.d.ts.map +1 -0
- package/models/components/getbankaccountsresponse.js +95 -0
- package/models/components/getbankaccountsresponse.js.map +1 -0
- package/models/components/index.d.ts +8 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +8 -0
- package/models/components/index.js.map +1 -1
- package/models/components/logsfilter.d.ts +8 -0
- package/models/components/logsfilter.d.ts.map +1 -1
- package/models/components/logsfilter.js +4 -0
- package/models/components/logsfilter.js.map +1 -1
- package/models/components/updatebankaccountresponse.d.ts +61 -0
- package/models/components/updatebankaccountresponse.d.ts.map +1 -0
- package/models/components/updatebankaccountresponse.js +89 -0
- package/models/components/updatebankaccountresponse.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/accountingbankaccountsadd.d.ts +118 -0
- package/models/operations/accountingbankaccountsadd.d.ts.map +1 -0
- package/models/operations/accountingbankaccountsadd.js +163 -0
- package/models/operations/accountingbankaccountsadd.js.map +1 -0
- package/models/operations/accountingbankaccountsall.d.ts +150 -0
- package/models/operations/accountingbankaccountsall.d.ts.map +1 -0
- package/models/operations/accountingbankaccountsall.js +173 -0
- package/models/operations/accountingbankaccountsall.js.map +1 -0
- package/models/operations/accountingbankaccountsdelete.d.ts +121 -0
- package/models/operations/accountingbankaccountsdelete.d.ts.map +1 -0
- package/models/operations/accountingbankaccountsdelete.js +155 -0
- package/models/operations/accountingbankaccountsdelete.js.map +1 -0
- package/models/operations/accountingbankaccountsone.d.ts +126 -0
- package/models/operations/accountingbankaccountsone.d.ts.map +1 -0
- package/models/operations/accountingbankaccountsone.js +157 -0
- package/models/operations/accountingbankaccountsone.js.map +1 -0
- package/models/operations/accountingbankaccountsupdate.d.ts +123 -0
- package/models/operations/accountingbankaccountsupdate.d.ts.map +1 -0
- package/models/operations/accountingbankaccountsupdate.js +165 -0
- package/models/operations/accountingbankaccountsupdate.js.map +1 -0
- package/models/operations/index.d.ts +5 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +5 -0
- package/models/operations/index.js.map +1 -1
- package/package.json +1 -1
- package/sdk/accounting.d.ts +3 -0
- package/sdk/accounting.d.ts.map +1 -1
- package/sdk/accounting.js +4 -0
- package/sdk/accounting.js.map +1 -1
- package/sdk/bankaccounts.d.ts +43 -0
- package/sdk/bankaccounts.d.ts.map +1 -0
- package/sdk/bankaccounts.js +63 -0
- package/sdk/bankaccounts.js.map +1 -0
- package/src/__tests__/bankaccounts.test.ts +293 -0
- package/src/funcs/accountingBankAccountsCreate.ts +225 -0
- package/src/funcs/accountingBankAccountsDelete.ts +231 -0
- package/src/funcs/accountingBankAccountsGet.ts +230 -0
- package/src/funcs/accountingBankAccountsList.ts +303 -0
- package/src/funcs/accountingBankAccountsUpdate.ts +234 -0
- package/src/lib/config.ts +4 -4
- package/src/models/components/accountingbankaccount.ts +576 -0
- package/src/models/components/bankaccountsfilter.ts +113 -0
- package/src/models/components/bankaccountssort.ts +113 -0
- package/src/models/components/createbankaccountresponse.ts +122 -0
- package/src/models/components/deletebankaccountresponse.ts +122 -0
- package/src/models/components/getbankaccountresponse.ts +119 -0
- package/src/models/components/getbankaccountsresponse.ts +145 -0
- package/src/models/components/index.ts +8 -0
- package/src/models/components/logsfilter.ts +12 -0
- package/src/models/components/updatebankaccountresponse.ts +122 -0
- package/src/models/errors/index.ts +1 -0
- package/src/models/operations/accountingbankaccountsadd.ts +271 -0
- package/src/models/operations/accountingbankaccountsall.ts +309 -0
- package/src/models/operations/accountingbankaccountsdelete.ts +274 -0
- package/src/models/operations/accountingbankaccountsone.ts +273 -0
- package/src/models/operations/accountingbankaccountsupdate.ts +286 -0
- package/src/models/operations/index.ts +5 -0
- package/src/sdk/accounting.ts +6 -0
- package/src/sdk/bankaccounts.ts +105 -0
|
@@ -0,0 +1,309 @@
|
|
|
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 * as components from "../components/index.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
|
|
12
|
+
export type AccountingBankAccountsAllGlobals = {
|
|
13
|
+
/**
|
|
14
|
+
* ID of the consumer which you want to get or push data from
|
|
15
|
+
*/
|
|
16
|
+
consumerId?: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* The ID of your Unify application
|
|
19
|
+
*/
|
|
20
|
+
appId?: string | undefined;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export type AccountingBankAccountsAllRequest = {
|
|
24
|
+
/**
|
|
25
|
+
* Include raw response. Mostly used for debugging purposes
|
|
26
|
+
*/
|
|
27
|
+
raw?: boolean | undefined;
|
|
28
|
+
/**
|
|
29
|
+
* ID of the consumer which you want to get or push data from
|
|
30
|
+
*/
|
|
31
|
+
consumerId?: string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* The ID of your Unify application
|
|
34
|
+
*/
|
|
35
|
+
appId?: string | undefined;
|
|
36
|
+
/**
|
|
37
|
+
* Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
|
|
38
|
+
*/
|
|
39
|
+
serviceId?: string | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.
|
|
42
|
+
*/
|
|
43
|
+
cursor?: string | null | undefined;
|
|
44
|
+
/**
|
|
45
|
+
* Number of results to return. Minimum 1, Maximum 200, Default 20
|
|
46
|
+
*/
|
|
47
|
+
limit?: number | undefined;
|
|
48
|
+
/**
|
|
49
|
+
* Apply filters
|
|
50
|
+
*/
|
|
51
|
+
filter?: components.BankAccountsFilter | undefined;
|
|
52
|
+
/**
|
|
53
|
+
* Apply sorting
|
|
54
|
+
*/
|
|
55
|
+
sort?: components.BankAccountsSort | undefined;
|
|
56
|
+
/**
|
|
57
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
58
|
+
*/
|
|
59
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
60
|
+
/**
|
|
61
|
+
* The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. <br /><br />Example: `fields=name,email,addresses.city`<br /><br />In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded.
|
|
62
|
+
*/
|
|
63
|
+
fields?: string | null | undefined;
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
export type AccountingBankAccountsAllResponse = {
|
|
67
|
+
httpMeta: components.HTTPMetadata;
|
|
68
|
+
/**
|
|
69
|
+
* Bank Accounts
|
|
70
|
+
*/
|
|
71
|
+
getBankAccountsResponse?: components.GetBankAccountsResponse | undefined;
|
|
72
|
+
/**
|
|
73
|
+
* Unexpected error
|
|
74
|
+
*/
|
|
75
|
+
unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
/** @internal */
|
|
79
|
+
export const AccountingBankAccountsAllGlobals$inboundSchema: z.ZodType<
|
|
80
|
+
AccountingBankAccountsAllGlobals,
|
|
81
|
+
z.ZodTypeDef,
|
|
82
|
+
unknown
|
|
83
|
+
> = z.object({
|
|
84
|
+
consumerId: z.string().optional(),
|
|
85
|
+
appId: z.string().optional(),
|
|
86
|
+
});
|
|
87
|
+
|
|
88
|
+
/** @internal */
|
|
89
|
+
export type AccountingBankAccountsAllGlobals$Outbound = {
|
|
90
|
+
consumerId?: string | undefined;
|
|
91
|
+
appId?: string | undefined;
|
|
92
|
+
};
|
|
93
|
+
|
|
94
|
+
/** @internal */
|
|
95
|
+
export const AccountingBankAccountsAllGlobals$outboundSchema: z.ZodType<
|
|
96
|
+
AccountingBankAccountsAllGlobals$Outbound,
|
|
97
|
+
z.ZodTypeDef,
|
|
98
|
+
AccountingBankAccountsAllGlobals
|
|
99
|
+
> = z.object({
|
|
100
|
+
consumerId: z.string().optional(),
|
|
101
|
+
appId: z.string().optional(),
|
|
102
|
+
});
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* @internal
|
|
106
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
107
|
+
*/
|
|
108
|
+
export namespace AccountingBankAccountsAllGlobals$ {
|
|
109
|
+
/** @deprecated use `AccountingBankAccountsAllGlobals$inboundSchema` instead. */
|
|
110
|
+
export const inboundSchema = AccountingBankAccountsAllGlobals$inboundSchema;
|
|
111
|
+
/** @deprecated use `AccountingBankAccountsAllGlobals$outboundSchema` instead. */
|
|
112
|
+
export const outboundSchema = AccountingBankAccountsAllGlobals$outboundSchema;
|
|
113
|
+
/** @deprecated use `AccountingBankAccountsAllGlobals$Outbound` instead. */
|
|
114
|
+
export type Outbound = AccountingBankAccountsAllGlobals$Outbound;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export function accountingBankAccountsAllGlobalsToJSON(
|
|
118
|
+
accountingBankAccountsAllGlobals: AccountingBankAccountsAllGlobals,
|
|
119
|
+
): string {
|
|
120
|
+
return JSON.stringify(
|
|
121
|
+
AccountingBankAccountsAllGlobals$outboundSchema.parse(
|
|
122
|
+
accountingBankAccountsAllGlobals,
|
|
123
|
+
),
|
|
124
|
+
);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
export function accountingBankAccountsAllGlobalsFromJSON(
|
|
128
|
+
jsonString: string,
|
|
129
|
+
): SafeParseResult<AccountingBankAccountsAllGlobals, SDKValidationError> {
|
|
130
|
+
return safeParse(
|
|
131
|
+
jsonString,
|
|
132
|
+
(x) => AccountingBankAccountsAllGlobals$inboundSchema.parse(JSON.parse(x)),
|
|
133
|
+
`Failed to parse 'AccountingBankAccountsAllGlobals' from JSON`,
|
|
134
|
+
);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
/** @internal */
|
|
138
|
+
export const AccountingBankAccountsAllRequest$inboundSchema: z.ZodType<
|
|
139
|
+
AccountingBankAccountsAllRequest,
|
|
140
|
+
z.ZodTypeDef,
|
|
141
|
+
unknown
|
|
142
|
+
> = z.object({
|
|
143
|
+
raw: z.boolean().default(false),
|
|
144
|
+
consumerId: z.string().optional(),
|
|
145
|
+
appId: z.string().optional(),
|
|
146
|
+
serviceId: z.string().optional(),
|
|
147
|
+
cursor: z.nullable(z.string()).optional(),
|
|
148
|
+
limit: z.number().int().default(20),
|
|
149
|
+
filter: components.BankAccountsFilter$inboundSchema.optional(),
|
|
150
|
+
sort: components.BankAccountsSort$inboundSchema.optional(),
|
|
151
|
+
pass_through: z.record(z.any()).optional(),
|
|
152
|
+
fields: z.nullable(z.string()).optional(),
|
|
153
|
+
}).transform((v) => {
|
|
154
|
+
return remap$(v, {
|
|
155
|
+
"pass_through": "passThrough",
|
|
156
|
+
});
|
|
157
|
+
});
|
|
158
|
+
|
|
159
|
+
/** @internal */
|
|
160
|
+
export type AccountingBankAccountsAllRequest$Outbound = {
|
|
161
|
+
raw: boolean;
|
|
162
|
+
consumerId?: string | undefined;
|
|
163
|
+
appId?: string | undefined;
|
|
164
|
+
serviceId?: string | undefined;
|
|
165
|
+
cursor?: string | null | undefined;
|
|
166
|
+
limit: number;
|
|
167
|
+
filter?: components.BankAccountsFilter$Outbound | undefined;
|
|
168
|
+
sort?: components.BankAccountsSort$Outbound | undefined;
|
|
169
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
170
|
+
fields?: string | null | undefined;
|
|
171
|
+
};
|
|
172
|
+
|
|
173
|
+
/** @internal */
|
|
174
|
+
export const AccountingBankAccountsAllRequest$outboundSchema: z.ZodType<
|
|
175
|
+
AccountingBankAccountsAllRequest$Outbound,
|
|
176
|
+
z.ZodTypeDef,
|
|
177
|
+
AccountingBankAccountsAllRequest
|
|
178
|
+
> = z.object({
|
|
179
|
+
raw: z.boolean().default(false),
|
|
180
|
+
consumerId: z.string().optional(),
|
|
181
|
+
appId: z.string().optional(),
|
|
182
|
+
serviceId: z.string().optional(),
|
|
183
|
+
cursor: z.nullable(z.string()).optional(),
|
|
184
|
+
limit: z.number().int().default(20),
|
|
185
|
+
filter: components.BankAccountsFilter$outboundSchema.optional(),
|
|
186
|
+
sort: components.BankAccountsSort$outboundSchema.optional(),
|
|
187
|
+
passThrough: z.record(z.any()).optional(),
|
|
188
|
+
fields: z.nullable(z.string()).optional(),
|
|
189
|
+
}).transform((v) => {
|
|
190
|
+
return remap$(v, {
|
|
191
|
+
passThrough: "pass_through",
|
|
192
|
+
});
|
|
193
|
+
});
|
|
194
|
+
|
|
195
|
+
/**
|
|
196
|
+
* @internal
|
|
197
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
198
|
+
*/
|
|
199
|
+
export namespace AccountingBankAccountsAllRequest$ {
|
|
200
|
+
/** @deprecated use `AccountingBankAccountsAllRequest$inboundSchema` instead. */
|
|
201
|
+
export const inboundSchema = AccountingBankAccountsAllRequest$inboundSchema;
|
|
202
|
+
/** @deprecated use `AccountingBankAccountsAllRequest$outboundSchema` instead. */
|
|
203
|
+
export const outboundSchema = AccountingBankAccountsAllRequest$outboundSchema;
|
|
204
|
+
/** @deprecated use `AccountingBankAccountsAllRequest$Outbound` instead. */
|
|
205
|
+
export type Outbound = AccountingBankAccountsAllRequest$Outbound;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
export function accountingBankAccountsAllRequestToJSON(
|
|
209
|
+
accountingBankAccountsAllRequest: AccountingBankAccountsAllRequest,
|
|
210
|
+
): string {
|
|
211
|
+
return JSON.stringify(
|
|
212
|
+
AccountingBankAccountsAllRequest$outboundSchema.parse(
|
|
213
|
+
accountingBankAccountsAllRequest,
|
|
214
|
+
),
|
|
215
|
+
);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
export function accountingBankAccountsAllRequestFromJSON(
|
|
219
|
+
jsonString: string,
|
|
220
|
+
): SafeParseResult<AccountingBankAccountsAllRequest, SDKValidationError> {
|
|
221
|
+
return safeParse(
|
|
222
|
+
jsonString,
|
|
223
|
+
(x) => AccountingBankAccountsAllRequest$inboundSchema.parse(JSON.parse(x)),
|
|
224
|
+
`Failed to parse 'AccountingBankAccountsAllRequest' from JSON`,
|
|
225
|
+
);
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
/** @internal */
|
|
229
|
+
export const AccountingBankAccountsAllResponse$inboundSchema: z.ZodType<
|
|
230
|
+
AccountingBankAccountsAllResponse,
|
|
231
|
+
z.ZodTypeDef,
|
|
232
|
+
unknown
|
|
233
|
+
> = z.object({
|
|
234
|
+
HttpMeta: components.HTTPMetadata$inboundSchema,
|
|
235
|
+
GetBankAccountsResponse: components.GetBankAccountsResponse$inboundSchema
|
|
236
|
+
.optional(),
|
|
237
|
+
UnexpectedErrorResponse: components.UnexpectedErrorResponse$inboundSchema
|
|
238
|
+
.optional(),
|
|
239
|
+
}).transform((v) => {
|
|
240
|
+
return remap$(v, {
|
|
241
|
+
"HttpMeta": "httpMeta",
|
|
242
|
+
"GetBankAccountsResponse": "getBankAccountsResponse",
|
|
243
|
+
"UnexpectedErrorResponse": "unexpectedErrorResponse",
|
|
244
|
+
});
|
|
245
|
+
});
|
|
246
|
+
|
|
247
|
+
/** @internal */
|
|
248
|
+
export type AccountingBankAccountsAllResponse$Outbound = {
|
|
249
|
+
HttpMeta: components.HTTPMetadata$Outbound;
|
|
250
|
+
GetBankAccountsResponse?:
|
|
251
|
+
| components.GetBankAccountsResponse$Outbound
|
|
252
|
+
| undefined;
|
|
253
|
+
UnexpectedErrorResponse?:
|
|
254
|
+
| components.UnexpectedErrorResponse$Outbound
|
|
255
|
+
| undefined;
|
|
256
|
+
};
|
|
257
|
+
|
|
258
|
+
/** @internal */
|
|
259
|
+
export const AccountingBankAccountsAllResponse$outboundSchema: z.ZodType<
|
|
260
|
+
AccountingBankAccountsAllResponse$Outbound,
|
|
261
|
+
z.ZodTypeDef,
|
|
262
|
+
AccountingBankAccountsAllResponse
|
|
263
|
+
> = z.object({
|
|
264
|
+
httpMeta: components.HTTPMetadata$outboundSchema,
|
|
265
|
+
getBankAccountsResponse: components.GetBankAccountsResponse$outboundSchema
|
|
266
|
+
.optional(),
|
|
267
|
+
unexpectedErrorResponse: components.UnexpectedErrorResponse$outboundSchema
|
|
268
|
+
.optional(),
|
|
269
|
+
}).transform((v) => {
|
|
270
|
+
return remap$(v, {
|
|
271
|
+
httpMeta: "HttpMeta",
|
|
272
|
+
getBankAccountsResponse: "GetBankAccountsResponse",
|
|
273
|
+
unexpectedErrorResponse: "UnexpectedErrorResponse",
|
|
274
|
+
});
|
|
275
|
+
});
|
|
276
|
+
|
|
277
|
+
/**
|
|
278
|
+
* @internal
|
|
279
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
280
|
+
*/
|
|
281
|
+
export namespace AccountingBankAccountsAllResponse$ {
|
|
282
|
+
/** @deprecated use `AccountingBankAccountsAllResponse$inboundSchema` instead. */
|
|
283
|
+
export const inboundSchema = AccountingBankAccountsAllResponse$inboundSchema;
|
|
284
|
+
/** @deprecated use `AccountingBankAccountsAllResponse$outboundSchema` instead. */
|
|
285
|
+
export const outboundSchema =
|
|
286
|
+
AccountingBankAccountsAllResponse$outboundSchema;
|
|
287
|
+
/** @deprecated use `AccountingBankAccountsAllResponse$Outbound` instead. */
|
|
288
|
+
export type Outbound = AccountingBankAccountsAllResponse$Outbound;
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
export function accountingBankAccountsAllResponseToJSON(
|
|
292
|
+
accountingBankAccountsAllResponse: AccountingBankAccountsAllResponse,
|
|
293
|
+
): string {
|
|
294
|
+
return JSON.stringify(
|
|
295
|
+
AccountingBankAccountsAllResponse$outboundSchema.parse(
|
|
296
|
+
accountingBankAccountsAllResponse,
|
|
297
|
+
),
|
|
298
|
+
);
|
|
299
|
+
}
|
|
300
|
+
|
|
301
|
+
export function accountingBankAccountsAllResponseFromJSON(
|
|
302
|
+
jsonString: string,
|
|
303
|
+
): SafeParseResult<AccountingBankAccountsAllResponse, SDKValidationError> {
|
|
304
|
+
return safeParse(
|
|
305
|
+
jsonString,
|
|
306
|
+
(x) => AccountingBankAccountsAllResponse$inboundSchema.parse(JSON.parse(x)),
|
|
307
|
+
`Failed to parse 'AccountingBankAccountsAllResponse' from JSON`,
|
|
308
|
+
);
|
|
309
|
+
}
|
|
@@ -0,0 +1,274 @@
|
|
|
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 * as components from "../components/index.js";
|
|
10
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
11
|
+
|
|
12
|
+
export type AccountingBankAccountsDeleteGlobals = {
|
|
13
|
+
/**
|
|
14
|
+
* ID of the consumer which you want to get or push data from
|
|
15
|
+
*/
|
|
16
|
+
consumerId?: string | undefined;
|
|
17
|
+
/**
|
|
18
|
+
* The ID of your Unify application
|
|
19
|
+
*/
|
|
20
|
+
appId?: string | undefined;
|
|
21
|
+
};
|
|
22
|
+
|
|
23
|
+
export type AccountingBankAccountsDeleteRequest = {
|
|
24
|
+
/**
|
|
25
|
+
* ID of the record you are acting upon.
|
|
26
|
+
*/
|
|
27
|
+
id: string;
|
|
28
|
+
/**
|
|
29
|
+
* ID of the consumer which you want to get or push data from
|
|
30
|
+
*/
|
|
31
|
+
consumerId?: string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* The ID of your Unify application
|
|
34
|
+
*/
|
|
35
|
+
appId?: string | undefined;
|
|
36
|
+
/**
|
|
37
|
+
* Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
|
|
38
|
+
*/
|
|
39
|
+
serviceId?: string | undefined;
|
|
40
|
+
/**
|
|
41
|
+
* Include raw response. Mostly used for debugging purposes
|
|
42
|
+
*/
|
|
43
|
+
raw?: boolean | undefined;
|
|
44
|
+
};
|
|
45
|
+
|
|
46
|
+
export type AccountingBankAccountsDeleteResponse = {
|
|
47
|
+
httpMeta: components.HTTPMetadata;
|
|
48
|
+
/**
|
|
49
|
+
* Bank Account deleted
|
|
50
|
+
*/
|
|
51
|
+
deleteBankAccountResponse?: components.DeleteBankAccountResponse | undefined;
|
|
52
|
+
/**
|
|
53
|
+
* Unexpected error
|
|
54
|
+
*/
|
|
55
|
+
unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
/** @internal */
|
|
59
|
+
export const AccountingBankAccountsDeleteGlobals$inboundSchema: z.ZodType<
|
|
60
|
+
AccountingBankAccountsDeleteGlobals,
|
|
61
|
+
z.ZodTypeDef,
|
|
62
|
+
unknown
|
|
63
|
+
> = z.object({
|
|
64
|
+
consumerId: z.string().optional(),
|
|
65
|
+
appId: z.string().optional(),
|
|
66
|
+
});
|
|
67
|
+
|
|
68
|
+
/** @internal */
|
|
69
|
+
export type AccountingBankAccountsDeleteGlobals$Outbound = {
|
|
70
|
+
consumerId?: string | undefined;
|
|
71
|
+
appId?: string | undefined;
|
|
72
|
+
};
|
|
73
|
+
|
|
74
|
+
/** @internal */
|
|
75
|
+
export const AccountingBankAccountsDeleteGlobals$outboundSchema: z.ZodType<
|
|
76
|
+
AccountingBankAccountsDeleteGlobals$Outbound,
|
|
77
|
+
z.ZodTypeDef,
|
|
78
|
+
AccountingBankAccountsDeleteGlobals
|
|
79
|
+
> = z.object({
|
|
80
|
+
consumerId: z.string().optional(),
|
|
81
|
+
appId: z.string().optional(),
|
|
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 AccountingBankAccountsDeleteGlobals$ {
|
|
89
|
+
/** @deprecated use `AccountingBankAccountsDeleteGlobals$inboundSchema` instead. */
|
|
90
|
+
export const inboundSchema =
|
|
91
|
+
AccountingBankAccountsDeleteGlobals$inboundSchema;
|
|
92
|
+
/** @deprecated use `AccountingBankAccountsDeleteGlobals$outboundSchema` instead. */
|
|
93
|
+
export const outboundSchema =
|
|
94
|
+
AccountingBankAccountsDeleteGlobals$outboundSchema;
|
|
95
|
+
/** @deprecated use `AccountingBankAccountsDeleteGlobals$Outbound` instead. */
|
|
96
|
+
export type Outbound = AccountingBankAccountsDeleteGlobals$Outbound;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export function accountingBankAccountsDeleteGlobalsToJSON(
|
|
100
|
+
accountingBankAccountsDeleteGlobals: AccountingBankAccountsDeleteGlobals,
|
|
101
|
+
): string {
|
|
102
|
+
return JSON.stringify(
|
|
103
|
+
AccountingBankAccountsDeleteGlobals$outboundSchema.parse(
|
|
104
|
+
accountingBankAccountsDeleteGlobals,
|
|
105
|
+
),
|
|
106
|
+
);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
export function accountingBankAccountsDeleteGlobalsFromJSON(
|
|
110
|
+
jsonString: string,
|
|
111
|
+
): SafeParseResult<AccountingBankAccountsDeleteGlobals, SDKValidationError> {
|
|
112
|
+
return safeParse(
|
|
113
|
+
jsonString,
|
|
114
|
+
(x) =>
|
|
115
|
+
AccountingBankAccountsDeleteGlobals$inboundSchema.parse(JSON.parse(x)),
|
|
116
|
+
`Failed to parse 'AccountingBankAccountsDeleteGlobals' from JSON`,
|
|
117
|
+
);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/** @internal */
|
|
121
|
+
export const AccountingBankAccountsDeleteRequest$inboundSchema: z.ZodType<
|
|
122
|
+
AccountingBankAccountsDeleteRequest,
|
|
123
|
+
z.ZodTypeDef,
|
|
124
|
+
unknown
|
|
125
|
+
> = z.object({
|
|
126
|
+
id: z.string(),
|
|
127
|
+
consumerId: z.string().optional(),
|
|
128
|
+
appId: z.string().optional(),
|
|
129
|
+
serviceId: z.string().optional(),
|
|
130
|
+
raw: z.boolean().default(false),
|
|
131
|
+
});
|
|
132
|
+
|
|
133
|
+
/** @internal */
|
|
134
|
+
export type AccountingBankAccountsDeleteRequest$Outbound = {
|
|
135
|
+
id: string;
|
|
136
|
+
consumerId?: string | undefined;
|
|
137
|
+
appId?: string | undefined;
|
|
138
|
+
serviceId?: string | undefined;
|
|
139
|
+
raw: boolean;
|
|
140
|
+
};
|
|
141
|
+
|
|
142
|
+
/** @internal */
|
|
143
|
+
export const AccountingBankAccountsDeleteRequest$outboundSchema: z.ZodType<
|
|
144
|
+
AccountingBankAccountsDeleteRequest$Outbound,
|
|
145
|
+
z.ZodTypeDef,
|
|
146
|
+
AccountingBankAccountsDeleteRequest
|
|
147
|
+
> = z.object({
|
|
148
|
+
id: z.string(),
|
|
149
|
+
consumerId: z.string().optional(),
|
|
150
|
+
appId: z.string().optional(),
|
|
151
|
+
serviceId: z.string().optional(),
|
|
152
|
+
raw: z.boolean().default(false),
|
|
153
|
+
});
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* @internal
|
|
157
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
158
|
+
*/
|
|
159
|
+
export namespace AccountingBankAccountsDeleteRequest$ {
|
|
160
|
+
/** @deprecated use `AccountingBankAccountsDeleteRequest$inboundSchema` instead. */
|
|
161
|
+
export const inboundSchema =
|
|
162
|
+
AccountingBankAccountsDeleteRequest$inboundSchema;
|
|
163
|
+
/** @deprecated use `AccountingBankAccountsDeleteRequest$outboundSchema` instead. */
|
|
164
|
+
export const outboundSchema =
|
|
165
|
+
AccountingBankAccountsDeleteRequest$outboundSchema;
|
|
166
|
+
/** @deprecated use `AccountingBankAccountsDeleteRequest$Outbound` instead. */
|
|
167
|
+
export type Outbound = AccountingBankAccountsDeleteRequest$Outbound;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
export function accountingBankAccountsDeleteRequestToJSON(
|
|
171
|
+
accountingBankAccountsDeleteRequest: AccountingBankAccountsDeleteRequest,
|
|
172
|
+
): string {
|
|
173
|
+
return JSON.stringify(
|
|
174
|
+
AccountingBankAccountsDeleteRequest$outboundSchema.parse(
|
|
175
|
+
accountingBankAccountsDeleteRequest,
|
|
176
|
+
),
|
|
177
|
+
);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
export function accountingBankAccountsDeleteRequestFromJSON(
|
|
181
|
+
jsonString: string,
|
|
182
|
+
): SafeParseResult<AccountingBankAccountsDeleteRequest, SDKValidationError> {
|
|
183
|
+
return safeParse(
|
|
184
|
+
jsonString,
|
|
185
|
+
(x) =>
|
|
186
|
+
AccountingBankAccountsDeleteRequest$inboundSchema.parse(JSON.parse(x)),
|
|
187
|
+
`Failed to parse 'AccountingBankAccountsDeleteRequest' from JSON`,
|
|
188
|
+
);
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
/** @internal */
|
|
192
|
+
export const AccountingBankAccountsDeleteResponse$inboundSchema: z.ZodType<
|
|
193
|
+
AccountingBankAccountsDeleteResponse,
|
|
194
|
+
z.ZodTypeDef,
|
|
195
|
+
unknown
|
|
196
|
+
> = z.object({
|
|
197
|
+
HttpMeta: components.HTTPMetadata$inboundSchema,
|
|
198
|
+
DeleteBankAccountResponse: components.DeleteBankAccountResponse$inboundSchema
|
|
199
|
+
.optional(),
|
|
200
|
+
UnexpectedErrorResponse: components.UnexpectedErrorResponse$inboundSchema
|
|
201
|
+
.optional(),
|
|
202
|
+
}).transform((v) => {
|
|
203
|
+
return remap$(v, {
|
|
204
|
+
"HttpMeta": "httpMeta",
|
|
205
|
+
"DeleteBankAccountResponse": "deleteBankAccountResponse",
|
|
206
|
+
"UnexpectedErrorResponse": "unexpectedErrorResponse",
|
|
207
|
+
});
|
|
208
|
+
});
|
|
209
|
+
|
|
210
|
+
/** @internal */
|
|
211
|
+
export type AccountingBankAccountsDeleteResponse$Outbound = {
|
|
212
|
+
HttpMeta: components.HTTPMetadata$Outbound;
|
|
213
|
+
DeleteBankAccountResponse?:
|
|
214
|
+
| components.DeleteBankAccountResponse$Outbound
|
|
215
|
+
| undefined;
|
|
216
|
+
UnexpectedErrorResponse?:
|
|
217
|
+
| components.UnexpectedErrorResponse$Outbound
|
|
218
|
+
| undefined;
|
|
219
|
+
};
|
|
220
|
+
|
|
221
|
+
/** @internal */
|
|
222
|
+
export const AccountingBankAccountsDeleteResponse$outboundSchema: z.ZodType<
|
|
223
|
+
AccountingBankAccountsDeleteResponse$Outbound,
|
|
224
|
+
z.ZodTypeDef,
|
|
225
|
+
AccountingBankAccountsDeleteResponse
|
|
226
|
+
> = z.object({
|
|
227
|
+
httpMeta: components.HTTPMetadata$outboundSchema,
|
|
228
|
+
deleteBankAccountResponse: components.DeleteBankAccountResponse$outboundSchema
|
|
229
|
+
.optional(),
|
|
230
|
+
unexpectedErrorResponse: components.UnexpectedErrorResponse$outboundSchema
|
|
231
|
+
.optional(),
|
|
232
|
+
}).transform((v) => {
|
|
233
|
+
return remap$(v, {
|
|
234
|
+
httpMeta: "HttpMeta",
|
|
235
|
+
deleteBankAccountResponse: "DeleteBankAccountResponse",
|
|
236
|
+
unexpectedErrorResponse: "UnexpectedErrorResponse",
|
|
237
|
+
});
|
|
238
|
+
});
|
|
239
|
+
|
|
240
|
+
/**
|
|
241
|
+
* @internal
|
|
242
|
+
* @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
|
|
243
|
+
*/
|
|
244
|
+
export namespace AccountingBankAccountsDeleteResponse$ {
|
|
245
|
+
/** @deprecated use `AccountingBankAccountsDeleteResponse$inboundSchema` instead. */
|
|
246
|
+
export const inboundSchema =
|
|
247
|
+
AccountingBankAccountsDeleteResponse$inboundSchema;
|
|
248
|
+
/** @deprecated use `AccountingBankAccountsDeleteResponse$outboundSchema` instead. */
|
|
249
|
+
export const outboundSchema =
|
|
250
|
+
AccountingBankAccountsDeleteResponse$outboundSchema;
|
|
251
|
+
/** @deprecated use `AccountingBankAccountsDeleteResponse$Outbound` instead. */
|
|
252
|
+
export type Outbound = AccountingBankAccountsDeleteResponse$Outbound;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
export function accountingBankAccountsDeleteResponseToJSON(
|
|
256
|
+
accountingBankAccountsDeleteResponse: AccountingBankAccountsDeleteResponse,
|
|
257
|
+
): string {
|
|
258
|
+
return JSON.stringify(
|
|
259
|
+
AccountingBankAccountsDeleteResponse$outboundSchema.parse(
|
|
260
|
+
accountingBankAccountsDeleteResponse,
|
|
261
|
+
),
|
|
262
|
+
);
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
export function accountingBankAccountsDeleteResponseFromJSON(
|
|
266
|
+
jsonString: string,
|
|
267
|
+
): SafeParseResult<AccountingBankAccountsDeleteResponse, SDKValidationError> {
|
|
268
|
+
return safeParse(
|
|
269
|
+
jsonString,
|
|
270
|
+
(x) =>
|
|
271
|
+
AccountingBankAccountsDeleteResponse$inboundSchema.parse(JSON.parse(x)),
|
|
272
|
+
`Failed to parse 'AccountingBankAccountsDeleteResponse' from JSON`,
|
|
273
|
+
);
|
|
274
|
+
}
|