@apideck/unify 0.13.1 → 0.13.3

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 (166) hide show
  1. package/README.md +0 -13
  2. package/docs/sdks/ageddebtors/README.md +2 -0
  3. package/docs/sdks/pipelines/README.md +0 -542
  4. package/lib/config.d.ts +2 -2
  5. package/lib/config.js +2 -2
  6. package/models/components/ageddebtors.d.ts +3 -3
  7. package/models/components/ageddebtors.d.ts.map +1 -1
  8. package/models/components/ageddebtors.js +5 -3
  9. package/models/components/ageddebtors.js.map +1 -1
  10. package/models/components/agedreportfilter.d.ts +5 -0
  11. package/models/components/agedreportfilter.d.ts.map +1 -1
  12. package/models/components/agedreportfilter.js +4 -0
  13. package/models/components/agedreportfilter.js.map +1 -1
  14. package/models/components/balancebyperiod.d.ts +6 -6
  15. package/models/components/balancebyperiod.d.ts.map +1 -1
  16. package/models/components/balancebyperiod.js +6 -4
  17. package/models/components/balancebyperiod.js.map +1 -1
  18. package/models/components/balancebytransaction.d.ts +8 -3
  19. package/models/components/balancebytransaction.d.ts.map +1 -1
  20. package/models/components/balancebytransaction.js +5 -1
  21. package/models/components/balancebytransaction.js.map +1 -1
  22. package/models/components/bill.d.ts +5 -0
  23. package/models/components/bill.d.ts.map +1 -1
  24. package/models/components/bill.js +9 -0
  25. package/models/components/bill.js.map +1 -1
  26. package/models/components/index.d.ts +1 -8
  27. package/models/components/index.d.ts.map +1 -1
  28. package/models/components/index.js +1 -8
  29. package/models/components/index.js.map +1 -1
  30. package/models/components/ledgeraccount.d.ts +5 -0
  31. package/models/components/ledgeraccount.d.ts.map +1 -1
  32. package/models/components/ledgeraccount.js +9 -0
  33. package/models/components/ledgeraccount.js.map +1 -1
  34. package/models/components/outstandingbalancebycurrency.d.ts +5 -0
  35. package/models/components/outstandingbalancebycurrency.d.ts.map +1 -1
  36. package/models/components/outstandingbalancebycurrency.js +4 -0
  37. package/models/components/outstandingbalancebycurrency.js.map +1 -1
  38. package/models/components/outstandingbalancebycustomer.d.ts +40 -0
  39. package/models/components/outstandingbalancebycustomer.d.ts.map +1 -0
  40. package/models/components/{outstandingbalance.js → outstandingbalancebycustomer.js} +17 -17
  41. package/models/components/outstandingbalancebycustomer.js.map +1 -0
  42. package/models/components/supplier.d.ts +5 -0
  43. package/models/components/supplier.d.ts.map +1 -1
  44. package/models/components/supplier.js +9 -0
  45. package/models/components/supplier.js.map +1 -1
  46. package/models/operations/index.d.ts +0 -5
  47. package/models/operations/index.d.ts.map +1 -1
  48. package/models/operations/index.js +0 -5
  49. package/models/operations/index.js.map +1 -1
  50. package/package.json +1 -1
  51. package/sdk/accounting.d.ts +0 -3
  52. package/sdk/accounting.d.ts.map +1 -1
  53. package/sdk/accounting.js +0 -4
  54. package/sdk/accounting.js.map +1 -1
  55. package/sdk/pipelines.d.ts +0 -28
  56. package/sdk/pipelines.d.ts.map +1 -1
  57. package/sdk/pipelines.js +0 -41
  58. package/sdk/pipelines.js.map +1 -1
  59. package/src/lib/config.ts +2 -2
  60. package/src/models/components/ageddebtors.ts +13 -9
  61. package/src/models/components/agedreportfilter.ts +9 -0
  62. package/src/models/components/balancebyperiod.ts +12 -10
  63. package/src/models/components/balancebytransaction.ts +10 -1
  64. package/src/models/components/bill.ts +18 -0
  65. package/src/models/components/index.ts +1 -8
  66. package/src/models/components/ledgeraccount.ts +18 -0
  67. package/src/models/components/outstandingbalancebycurrency.ts +9 -0
  68. package/src/models/components/{outstandingbalance.ts → outstandingbalancebycustomer.ts} +25 -23
  69. package/src/models/components/supplier.ts +18 -0
  70. package/src/models/operations/index.ts +0 -5
  71. package/src/sdk/accounting.ts +0 -6
  72. package/src/sdk/pipelines.ts +0 -73
  73. package/docs/sdks/agedcreditors/README.md +0 -113
  74. package/funcs/accountingAgedCreditorsGet.d.ts +0 -16
  75. package/funcs/accountingAgedCreditorsGet.d.ts.map +0 -1
  76. package/funcs/accountingAgedCreditorsGet.js +0 -122
  77. package/funcs/accountingAgedCreditorsGet.js.map +0 -1
  78. package/funcs/crmPipelinesCreate.d.ts +0 -16
  79. package/funcs/crmPipelinesCreate.d.ts.map +0 -1
  80. package/funcs/crmPipelinesCreate.js +0 -121
  81. package/funcs/crmPipelinesCreate.js.map +0 -1
  82. package/funcs/crmPipelinesDelete.d.ts +0 -16
  83. package/funcs/crmPipelinesDelete.d.ts.map +0 -1
  84. package/funcs/crmPipelinesDelete.js +0 -126
  85. package/funcs/crmPipelinesDelete.js.map +0 -1
  86. package/funcs/crmPipelinesGet.d.ts +0 -16
  87. package/funcs/crmPipelinesGet.d.ts.map +0 -1
  88. package/funcs/crmPipelinesGet.js +0 -127
  89. package/funcs/crmPipelinesGet.js.map +0 -1
  90. package/funcs/crmPipelinesUpdate.d.ts +0 -16
  91. package/funcs/crmPipelinesUpdate.d.ts.map +0 -1
  92. package/funcs/crmPipelinesUpdate.js +0 -127
  93. package/funcs/crmPipelinesUpdate.js.map +0 -1
  94. package/models/components/agedcreditors.d.ts +0 -51
  95. package/models/components/agedcreditors.d.ts.map +0 -1
  96. package/models/components/agedcreditors.js +0 -86
  97. package/models/components/agedcreditors.js.map +0 -1
  98. package/models/components/createpipelineresponse.d.ts +0 -58
  99. package/models/components/createpipelineresponse.d.ts.map +0 -1
  100. package/models/components/createpipelineresponse.js +0 -79
  101. package/models/components/createpipelineresponse.js.map +0 -1
  102. package/models/components/deletepipelineresponse.d.ts +0 -58
  103. package/models/components/deletepipelineresponse.d.ts.map +0 -1
  104. package/models/components/deletepipelineresponse.js +0 -79
  105. package/models/components/deletepipelineresponse.js.map +0 -1
  106. package/models/components/getagedcreditorsresponse.d.ts +0 -58
  107. package/models/components/getagedcreditorsresponse.d.ts.map +0 -1
  108. package/models/components/getagedcreditorsresponse.js +0 -79
  109. package/models/components/getagedcreditorsresponse.js.map +0 -1
  110. package/models/components/getpipelineresponse.d.ts +0 -58
  111. package/models/components/getpipelineresponse.d.ts.map +0 -1
  112. package/models/components/getpipelineresponse.js +0 -79
  113. package/models/components/getpipelineresponse.js.map +0 -1
  114. package/models/components/outstandingbalance.d.ts +0 -40
  115. package/models/components/outstandingbalance.d.ts.map +0 -1
  116. package/models/components/outstandingbalance.js.map +0 -1
  117. package/models/components/pipelineinput.d.ts +0 -117
  118. package/models/components/pipelineinput.d.ts.map +0 -1
  119. package/models/components/pipelineinput.js +0 -133
  120. package/models/components/pipelineinput.js.map +0 -1
  121. package/models/components/updatepipelineresponse.d.ts +0 -58
  122. package/models/components/updatepipelineresponse.d.ts.map +0 -1
  123. package/models/components/updatepipelineresponse.js +0 -79
  124. package/models/components/updatepipelineresponse.js.map +0 -1
  125. package/models/operations/accountingagedcreditorsone.d.ts +0 -125
  126. package/models/operations/accountingagedcreditorsone.d.ts.map +0 -1
  127. package/models/operations/accountingagedcreditorsone.js +0 -153
  128. package/models/operations/accountingagedcreditorsone.js.map +0 -1
  129. package/models/operations/crmpipelinesadd.d.ts +0 -108
  130. package/models/operations/crmpipelinesadd.d.ts.map +0 -1
  131. package/models/operations/crmpipelinesadd.js +0 -149
  132. package/models/operations/crmpipelinesadd.js.map +0 -1
  133. package/models/operations/crmpipelinesdelete.d.ts +0 -111
  134. package/models/operations/crmpipelinesdelete.d.ts.map +0 -1
  135. package/models/operations/crmpipelinesdelete.js +0 -141
  136. package/models/operations/crmpipelinesdelete.js.map +0 -1
  137. package/models/operations/crmpipelinesone.d.ts +0 -116
  138. package/models/operations/crmpipelinesone.d.ts.map +0 -1
  139. package/models/operations/crmpipelinesone.js +0 -141
  140. package/models/operations/crmpipelinesone.js.map +0 -1
  141. package/models/operations/crmpipelinesupdate.d.ts +0 -113
  142. package/models/operations/crmpipelinesupdate.d.ts.map +0 -1
  143. package/models/operations/crmpipelinesupdate.js +0 -151
  144. package/models/operations/crmpipelinesupdate.js.map +0 -1
  145. package/sdk/agedcreditors.d.ts +0 -12
  146. package/sdk/agedcreditors.d.ts.map +0 -1
  147. package/sdk/agedcreditors.js +0 -22
  148. package/sdk/agedcreditors.js.map +0 -1
  149. package/src/funcs/accountingAgedCreditorsGet.ts +0 -193
  150. package/src/funcs/crmPipelinesCreate.ts +0 -179
  151. package/src/funcs/crmPipelinesDelete.ts +0 -185
  152. package/src/funcs/crmPipelinesGet.ts +0 -186
  153. package/src/funcs/crmPipelinesUpdate.ts +0 -186
  154. package/src/models/components/agedcreditors.ts +0 -116
  155. package/src/models/components/createpipelineresponse.ts +0 -119
  156. package/src/models/components/deletepipelineresponse.ts +0 -119
  157. package/src/models/components/getagedcreditorsresponse.ts +0 -119
  158. package/src/models/components/getpipelineresponse.ts +0 -119
  159. package/src/models/components/pipelineinput.ts +0 -233
  160. package/src/models/components/updatepipelineresponse.ts +0 -119
  161. package/src/models/operations/accountingagedcreditorsone.ts +0 -277
  162. package/src/models/operations/crmpipelinesadd.ts +0 -250
  163. package/src/models/operations/crmpipelinesdelete.ts +0 -245
  164. package/src/models/operations/crmpipelinesone.ts +0 -248
  165. package/src/models/operations/crmpipelinesupdate.ts +0 -257
  166. package/src/sdk/agedcreditors.ts +0 -27
@@ -1,119 +0,0 @@
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
- * Pipeline updated
19
- */
20
- export type UpdatePipelineResponse = {
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;
33
- /**
34
- * Unified API resource name
35
- */
36
- resource: string;
37
- /**
38
- * Operation performed
39
- */
40
- operation: string;
41
- data: UnifiedId;
42
- };
43
-
44
- /** @internal */
45
- export const UpdatePipelineResponse$inboundSchema: z.ZodType<
46
- UpdatePipelineResponse,
47
- z.ZodTypeDef,
48
- unknown
49
- > = z.object({
50
- status_code: z.number().int(),
51
- status: z.string(),
52
- service: z.string(),
53
- resource: z.string(),
54
- operation: z.string(),
55
- data: UnifiedId$inboundSchema,
56
- }).transform((v) => {
57
- return remap$(v, {
58
- "status_code": "statusCode",
59
- });
60
- });
61
-
62
- /** @internal */
63
- export type UpdatePipelineResponse$Outbound = {
64
- status_code: number;
65
- status: string;
66
- service: string;
67
- resource: string;
68
- operation: string;
69
- data: UnifiedId$Outbound;
70
- };
71
-
72
- /** @internal */
73
- export const UpdatePipelineResponse$outboundSchema: z.ZodType<
74
- UpdatePipelineResponse$Outbound,
75
- z.ZodTypeDef,
76
- UpdatePipelineResponse
77
- > = z.object({
78
- statusCode: z.number().int(),
79
- status: z.string(),
80
- service: z.string(),
81
- resource: z.string(),
82
- operation: z.string(),
83
- data: UnifiedId$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 UpdatePipelineResponse$ {
95
- /** @deprecated use `UpdatePipelineResponse$inboundSchema` instead. */
96
- export const inboundSchema = UpdatePipelineResponse$inboundSchema;
97
- /** @deprecated use `UpdatePipelineResponse$outboundSchema` instead. */
98
- export const outboundSchema = UpdatePipelineResponse$outboundSchema;
99
- /** @deprecated use `UpdatePipelineResponse$Outbound` instead. */
100
- export type Outbound = UpdatePipelineResponse$Outbound;
101
- }
102
-
103
- export function updatePipelineResponseToJSON(
104
- updatePipelineResponse: UpdatePipelineResponse,
105
- ): string {
106
- return JSON.stringify(
107
- UpdatePipelineResponse$outboundSchema.parse(updatePipelineResponse),
108
- );
109
- }
110
-
111
- export function updatePipelineResponseFromJSON(
112
- jsonString: string,
113
- ): SafeParseResult<UpdatePipelineResponse, SDKValidationError> {
114
- return safeParse(
115
- jsonString,
116
- (x) => UpdatePipelineResponse$inboundSchema.parse(JSON.parse(x)),
117
- `Failed to parse 'UpdatePipelineResponse' from JSON`,
118
- );
119
- }
@@ -1,277 +0,0 @@
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 AccountingAgedCreditorsOneGlobals = {
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 AccountingAgedCreditorsOneRequest = {
24
- /**
25
- * Include raw response. Mostly used for debugging purposes
26
- */
27
- raw?: boolean | undefined;
28
- /**
29
- * Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
30
- */
31
- serviceId?: string | undefined;
32
- /**
33
- * Apply filters
34
- */
35
- filter?: components.AgedReportFilter | undefined;
36
- /**
37
- * Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
38
- */
39
- passThrough?: { [k: string]: any } | undefined;
40
- /**
41
- * 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.
42
- */
43
- fields?: string | null | undefined;
44
- };
45
-
46
- export type AccountingAgedCreditorsOneResponse = {
47
- httpMeta: components.HTTPMetadata;
48
- /**
49
- * Aged Creditors
50
- */
51
- getAgedCreditorsResponse?: components.GetAgedCreditorsResponse | undefined;
52
- /**
53
- * Unexpected error
54
- */
55
- unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
56
- };
57
-
58
- /** @internal */
59
- export const AccountingAgedCreditorsOneGlobals$inboundSchema: z.ZodType<
60
- AccountingAgedCreditorsOneGlobals,
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 AccountingAgedCreditorsOneGlobals$Outbound = {
70
- consumerId?: string | undefined;
71
- appId?: string | undefined;
72
- };
73
-
74
- /** @internal */
75
- export const AccountingAgedCreditorsOneGlobals$outboundSchema: z.ZodType<
76
- AccountingAgedCreditorsOneGlobals$Outbound,
77
- z.ZodTypeDef,
78
- AccountingAgedCreditorsOneGlobals
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 AccountingAgedCreditorsOneGlobals$ {
89
- /** @deprecated use `AccountingAgedCreditorsOneGlobals$inboundSchema` instead. */
90
- export const inboundSchema = AccountingAgedCreditorsOneGlobals$inboundSchema;
91
- /** @deprecated use `AccountingAgedCreditorsOneGlobals$outboundSchema` instead. */
92
- export const outboundSchema =
93
- AccountingAgedCreditorsOneGlobals$outboundSchema;
94
- /** @deprecated use `AccountingAgedCreditorsOneGlobals$Outbound` instead. */
95
- export type Outbound = AccountingAgedCreditorsOneGlobals$Outbound;
96
- }
97
-
98
- export function accountingAgedCreditorsOneGlobalsToJSON(
99
- accountingAgedCreditorsOneGlobals: AccountingAgedCreditorsOneGlobals,
100
- ): string {
101
- return JSON.stringify(
102
- AccountingAgedCreditorsOneGlobals$outboundSchema.parse(
103
- accountingAgedCreditorsOneGlobals,
104
- ),
105
- );
106
- }
107
-
108
- export function accountingAgedCreditorsOneGlobalsFromJSON(
109
- jsonString: string,
110
- ): SafeParseResult<AccountingAgedCreditorsOneGlobals, SDKValidationError> {
111
- return safeParse(
112
- jsonString,
113
- (x) => AccountingAgedCreditorsOneGlobals$inboundSchema.parse(JSON.parse(x)),
114
- `Failed to parse 'AccountingAgedCreditorsOneGlobals' from JSON`,
115
- );
116
- }
117
-
118
- /** @internal */
119
- export const AccountingAgedCreditorsOneRequest$inboundSchema: z.ZodType<
120
- AccountingAgedCreditorsOneRequest,
121
- z.ZodTypeDef,
122
- unknown
123
- > = z.object({
124
- raw: z.boolean().default(false),
125
- serviceId: z.string().optional(),
126
- filter: components.AgedReportFilter$inboundSchema.optional(),
127
- pass_through: z.record(z.any()).optional(),
128
- fields: z.nullable(z.string()).optional(),
129
- }).transform((v) => {
130
- return remap$(v, {
131
- "pass_through": "passThrough",
132
- });
133
- });
134
-
135
- /** @internal */
136
- export type AccountingAgedCreditorsOneRequest$Outbound = {
137
- raw: boolean;
138
- serviceId?: string | undefined;
139
- filter?: components.AgedReportFilter$Outbound | undefined;
140
- pass_through?: { [k: string]: any } | undefined;
141
- fields?: string | null | undefined;
142
- };
143
-
144
- /** @internal */
145
- export const AccountingAgedCreditorsOneRequest$outboundSchema: z.ZodType<
146
- AccountingAgedCreditorsOneRequest$Outbound,
147
- z.ZodTypeDef,
148
- AccountingAgedCreditorsOneRequest
149
- > = z.object({
150
- raw: z.boolean().default(false),
151
- serviceId: z.string().optional(),
152
- filter: components.AgedReportFilter$outboundSchema.optional(),
153
- passThrough: z.record(z.any()).optional(),
154
- fields: z.nullable(z.string()).optional(),
155
- }).transform((v) => {
156
- return remap$(v, {
157
- passThrough: "pass_through",
158
- });
159
- });
160
-
161
- /**
162
- * @internal
163
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
164
- */
165
- export namespace AccountingAgedCreditorsOneRequest$ {
166
- /** @deprecated use `AccountingAgedCreditorsOneRequest$inboundSchema` instead. */
167
- export const inboundSchema = AccountingAgedCreditorsOneRequest$inboundSchema;
168
- /** @deprecated use `AccountingAgedCreditorsOneRequest$outboundSchema` instead. */
169
- export const outboundSchema =
170
- AccountingAgedCreditorsOneRequest$outboundSchema;
171
- /** @deprecated use `AccountingAgedCreditorsOneRequest$Outbound` instead. */
172
- export type Outbound = AccountingAgedCreditorsOneRequest$Outbound;
173
- }
174
-
175
- export function accountingAgedCreditorsOneRequestToJSON(
176
- accountingAgedCreditorsOneRequest: AccountingAgedCreditorsOneRequest,
177
- ): string {
178
- return JSON.stringify(
179
- AccountingAgedCreditorsOneRequest$outboundSchema.parse(
180
- accountingAgedCreditorsOneRequest,
181
- ),
182
- );
183
- }
184
-
185
- export function accountingAgedCreditorsOneRequestFromJSON(
186
- jsonString: string,
187
- ): SafeParseResult<AccountingAgedCreditorsOneRequest, SDKValidationError> {
188
- return safeParse(
189
- jsonString,
190
- (x) => AccountingAgedCreditorsOneRequest$inboundSchema.parse(JSON.parse(x)),
191
- `Failed to parse 'AccountingAgedCreditorsOneRequest' from JSON`,
192
- );
193
- }
194
-
195
- /** @internal */
196
- export const AccountingAgedCreditorsOneResponse$inboundSchema: z.ZodType<
197
- AccountingAgedCreditorsOneResponse,
198
- z.ZodTypeDef,
199
- unknown
200
- > = z.object({
201
- HttpMeta: components.HTTPMetadata$inboundSchema,
202
- GetAgedCreditorsResponse: components.GetAgedCreditorsResponse$inboundSchema
203
- .optional(),
204
- UnexpectedErrorResponse: components.UnexpectedErrorResponse$inboundSchema
205
- .optional(),
206
- }).transform((v) => {
207
- return remap$(v, {
208
- "HttpMeta": "httpMeta",
209
- "GetAgedCreditorsResponse": "getAgedCreditorsResponse",
210
- "UnexpectedErrorResponse": "unexpectedErrorResponse",
211
- });
212
- });
213
-
214
- /** @internal */
215
- export type AccountingAgedCreditorsOneResponse$Outbound = {
216
- HttpMeta: components.HTTPMetadata$Outbound;
217
- GetAgedCreditorsResponse?:
218
- | components.GetAgedCreditorsResponse$Outbound
219
- | undefined;
220
- UnexpectedErrorResponse?:
221
- | components.UnexpectedErrorResponse$Outbound
222
- | undefined;
223
- };
224
-
225
- /** @internal */
226
- export const AccountingAgedCreditorsOneResponse$outboundSchema: z.ZodType<
227
- AccountingAgedCreditorsOneResponse$Outbound,
228
- z.ZodTypeDef,
229
- AccountingAgedCreditorsOneResponse
230
- > = z.object({
231
- httpMeta: components.HTTPMetadata$outboundSchema,
232
- getAgedCreditorsResponse: components.GetAgedCreditorsResponse$outboundSchema
233
- .optional(),
234
- unexpectedErrorResponse: components.UnexpectedErrorResponse$outboundSchema
235
- .optional(),
236
- }).transform((v) => {
237
- return remap$(v, {
238
- httpMeta: "HttpMeta",
239
- getAgedCreditorsResponse: "GetAgedCreditorsResponse",
240
- unexpectedErrorResponse: "UnexpectedErrorResponse",
241
- });
242
- });
243
-
244
- /**
245
- * @internal
246
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
247
- */
248
- export namespace AccountingAgedCreditorsOneResponse$ {
249
- /** @deprecated use `AccountingAgedCreditorsOneResponse$inboundSchema` instead. */
250
- export const inboundSchema = AccountingAgedCreditorsOneResponse$inboundSchema;
251
- /** @deprecated use `AccountingAgedCreditorsOneResponse$outboundSchema` instead. */
252
- export const outboundSchema =
253
- AccountingAgedCreditorsOneResponse$outboundSchema;
254
- /** @deprecated use `AccountingAgedCreditorsOneResponse$Outbound` instead. */
255
- export type Outbound = AccountingAgedCreditorsOneResponse$Outbound;
256
- }
257
-
258
- export function accountingAgedCreditorsOneResponseToJSON(
259
- accountingAgedCreditorsOneResponse: AccountingAgedCreditorsOneResponse,
260
- ): string {
261
- return JSON.stringify(
262
- AccountingAgedCreditorsOneResponse$outboundSchema.parse(
263
- accountingAgedCreditorsOneResponse,
264
- ),
265
- );
266
- }
267
-
268
- export function accountingAgedCreditorsOneResponseFromJSON(
269
- jsonString: string,
270
- ): SafeParseResult<AccountingAgedCreditorsOneResponse, SDKValidationError> {
271
- return safeParse(
272
- jsonString,
273
- (x) =>
274
- AccountingAgedCreditorsOneResponse$inboundSchema.parse(JSON.parse(x)),
275
- `Failed to parse 'AccountingAgedCreditorsOneResponse' from JSON`,
276
- );
277
- }
@@ -1,250 +0,0 @@
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 CrmPipelinesAddGlobals = {
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 CrmPipelinesAddRequest = {
24
- /**
25
- * Include raw response. Mostly used for debugging purposes
26
- */
27
- raw?: boolean | undefined;
28
- /**
29
- * Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
30
- */
31
- serviceId?: string | undefined;
32
- pipeline: components.PipelineInput;
33
- };
34
-
35
- export type CrmPipelinesAddResponse = {
36
- httpMeta: components.HTTPMetadata;
37
- /**
38
- * Pipeline created
39
- */
40
- createPipelineResponse?: components.CreatePipelineResponse | undefined;
41
- /**
42
- * Unexpected error
43
- */
44
- unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
45
- };
46
-
47
- /** @internal */
48
- export const CrmPipelinesAddGlobals$inboundSchema: z.ZodType<
49
- CrmPipelinesAddGlobals,
50
- z.ZodTypeDef,
51
- unknown
52
- > = z.object({
53
- consumerId: z.string().optional(),
54
- appId: z.string().optional(),
55
- });
56
-
57
- /** @internal */
58
- export type CrmPipelinesAddGlobals$Outbound = {
59
- consumerId?: string | undefined;
60
- appId?: string | undefined;
61
- };
62
-
63
- /** @internal */
64
- export const CrmPipelinesAddGlobals$outboundSchema: z.ZodType<
65
- CrmPipelinesAddGlobals$Outbound,
66
- z.ZodTypeDef,
67
- CrmPipelinesAddGlobals
68
- > = z.object({
69
- consumerId: z.string().optional(),
70
- appId: z.string().optional(),
71
- });
72
-
73
- /**
74
- * @internal
75
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
76
- */
77
- export namespace CrmPipelinesAddGlobals$ {
78
- /** @deprecated use `CrmPipelinesAddGlobals$inboundSchema` instead. */
79
- export const inboundSchema = CrmPipelinesAddGlobals$inboundSchema;
80
- /** @deprecated use `CrmPipelinesAddGlobals$outboundSchema` instead. */
81
- export const outboundSchema = CrmPipelinesAddGlobals$outboundSchema;
82
- /** @deprecated use `CrmPipelinesAddGlobals$Outbound` instead. */
83
- export type Outbound = CrmPipelinesAddGlobals$Outbound;
84
- }
85
-
86
- export function crmPipelinesAddGlobalsToJSON(
87
- crmPipelinesAddGlobals: CrmPipelinesAddGlobals,
88
- ): string {
89
- return JSON.stringify(
90
- CrmPipelinesAddGlobals$outboundSchema.parse(crmPipelinesAddGlobals),
91
- );
92
- }
93
-
94
- export function crmPipelinesAddGlobalsFromJSON(
95
- jsonString: string,
96
- ): SafeParseResult<CrmPipelinesAddGlobals, SDKValidationError> {
97
- return safeParse(
98
- jsonString,
99
- (x) => CrmPipelinesAddGlobals$inboundSchema.parse(JSON.parse(x)),
100
- `Failed to parse 'CrmPipelinesAddGlobals' from JSON`,
101
- );
102
- }
103
-
104
- /** @internal */
105
- export const CrmPipelinesAddRequest$inboundSchema: z.ZodType<
106
- CrmPipelinesAddRequest,
107
- z.ZodTypeDef,
108
- unknown
109
- > = z.object({
110
- raw: z.boolean().default(false),
111
- serviceId: z.string().optional(),
112
- Pipeline: components.PipelineInput$inboundSchema,
113
- }).transform((v) => {
114
- return remap$(v, {
115
- "Pipeline": "pipeline",
116
- });
117
- });
118
-
119
- /** @internal */
120
- export type CrmPipelinesAddRequest$Outbound = {
121
- raw: boolean;
122
- serviceId?: string | undefined;
123
- Pipeline: components.PipelineInput$Outbound;
124
- };
125
-
126
- /** @internal */
127
- export const CrmPipelinesAddRequest$outboundSchema: z.ZodType<
128
- CrmPipelinesAddRequest$Outbound,
129
- z.ZodTypeDef,
130
- CrmPipelinesAddRequest
131
- > = z.object({
132
- raw: z.boolean().default(false),
133
- serviceId: z.string().optional(),
134
- pipeline: components.PipelineInput$outboundSchema,
135
- }).transform((v) => {
136
- return remap$(v, {
137
- pipeline: "Pipeline",
138
- });
139
- });
140
-
141
- /**
142
- * @internal
143
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
144
- */
145
- export namespace CrmPipelinesAddRequest$ {
146
- /** @deprecated use `CrmPipelinesAddRequest$inboundSchema` instead. */
147
- export const inboundSchema = CrmPipelinesAddRequest$inboundSchema;
148
- /** @deprecated use `CrmPipelinesAddRequest$outboundSchema` instead. */
149
- export const outboundSchema = CrmPipelinesAddRequest$outboundSchema;
150
- /** @deprecated use `CrmPipelinesAddRequest$Outbound` instead. */
151
- export type Outbound = CrmPipelinesAddRequest$Outbound;
152
- }
153
-
154
- export function crmPipelinesAddRequestToJSON(
155
- crmPipelinesAddRequest: CrmPipelinesAddRequest,
156
- ): string {
157
- return JSON.stringify(
158
- CrmPipelinesAddRequest$outboundSchema.parse(crmPipelinesAddRequest),
159
- );
160
- }
161
-
162
- export function crmPipelinesAddRequestFromJSON(
163
- jsonString: string,
164
- ): SafeParseResult<CrmPipelinesAddRequest, SDKValidationError> {
165
- return safeParse(
166
- jsonString,
167
- (x) => CrmPipelinesAddRequest$inboundSchema.parse(JSON.parse(x)),
168
- `Failed to parse 'CrmPipelinesAddRequest' from JSON`,
169
- );
170
- }
171
-
172
- /** @internal */
173
- export const CrmPipelinesAddResponse$inboundSchema: z.ZodType<
174
- CrmPipelinesAddResponse,
175
- z.ZodTypeDef,
176
- unknown
177
- > = z.object({
178
- HttpMeta: components.HTTPMetadata$inboundSchema,
179
- CreatePipelineResponse: components.CreatePipelineResponse$inboundSchema
180
- .optional(),
181
- UnexpectedErrorResponse: components.UnexpectedErrorResponse$inboundSchema
182
- .optional(),
183
- }).transform((v) => {
184
- return remap$(v, {
185
- "HttpMeta": "httpMeta",
186
- "CreatePipelineResponse": "createPipelineResponse",
187
- "UnexpectedErrorResponse": "unexpectedErrorResponse",
188
- });
189
- });
190
-
191
- /** @internal */
192
- export type CrmPipelinesAddResponse$Outbound = {
193
- HttpMeta: components.HTTPMetadata$Outbound;
194
- CreatePipelineResponse?:
195
- | components.CreatePipelineResponse$Outbound
196
- | undefined;
197
- UnexpectedErrorResponse?:
198
- | components.UnexpectedErrorResponse$Outbound
199
- | undefined;
200
- };
201
-
202
- /** @internal */
203
- export const CrmPipelinesAddResponse$outboundSchema: z.ZodType<
204
- CrmPipelinesAddResponse$Outbound,
205
- z.ZodTypeDef,
206
- CrmPipelinesAddResponse
207
- > = z.object({
208
- httpMeta: components.HTTPMetadata$outboundSchema,
209
- createPipelineResponse: components.CreatePipelineResponse$outboundSchema
210
- .optional(),
211
- unexpectedErrorResponse: components.UnexpectedErrorResponse$outboundSchema
212
- .optional(),
213
- }).transform((v) => {
214
- return remap$(v, {
215
- httpMeta: "HttpMeta",
216
- createPipelineResponse: "CreatePipelineResponse",
217
- unexpectedErrorResponse: "UnexpectedErrorResponse",
218
- });
219
- });
220
-
221
- /**
222
- * @internal
223
- * @deprecated This namespace will be removed in future versions. Use schemas and types that are exported directly from this module.
224
- */
225
- export namespace CrmPipelinesAddResponse$ {
226
- /** @deprecated use `CrmPipelinesAddResponse$inboundSchema` instead. */
227
- export const inboundSchema = CrmPipelinesAddResponse$inboundSchema;
228
- /** @deprecated use `CrmPipelinesAddResponse$outboundSchema` instead. */
229
- export const outboundSchema = CrmPipelinesAddResponse$outboundSchema;
230
- /** @deprecated use `CrmPipelinesAddResponse$Outbound` instead. */
231
- export type Outbound = CrmPipelinesAddResponse$Outbound;
232
- }
233
-
234
- export function crmPipelinesAddResponseToJSON(
235
- crmPipelinesAddResponse: CrmPipelinesAddResponse,
236
- ): string {
237
- return JSON.stringify(
238
- CrmPipelinesAddResponse$outboundSchema.parse(crmPipelinesAddResponse),
239
- );
240
- }
241
-
242
- export function crmPipelinesAddResponseFromJSON(
243
- jsonString: string,
244
- ): SafeParseResult<CrmPipelinesAddResponse, SDKValidationError> {
245
- return safeParse(
246
- jsonString,
247
- (x) => CrmPipelinesAddResponse$inboundSchema.parse(JSON.parse(x)),
248
- `Failed to parse 'CrmPipelinesAddResponse' from JSON`,
249
- );
250
- }