@superdurable/connector-adobe-marketo 0.1.0 → 0.2.0

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.
@@ -0,0 +1,518 @@
1
+ import { RefreshingCredentialProvider, SecretString, Query, Mutation, ConnectionRef } from '@superdurable/connectors-sdk';
2
+ import { z } from 'zod';
3
+ import { Codec } from '@superdurable/dex';
4
+
5
+ /** A signed 64-bit JSON integer. Values outside the safe number range retain their decimal token. */
6
+ type SignedInteger = number | Readonly<{
7
+ rawJSON: string;
8
+ }>;
9
+ /** Decode one signed Go integer from a safe number or a native raw JSON number token. */
10
+ declare function decodeSignedInteger(value: unknown): SignedInteger;
11
+ /** Read provider JSON with the original syntax of every numeric token for typed field validation. */
12
+ declare function parseJSONNumberTokens(text: string): unknown;
13
+ /** Decode JSON while retaining exact decimal tokens for integers outside JavaScript's safe range. */
14
+ declare function parseExactIntegerJSON(text: string): unknown;
15
+ /** JSON-wire codec for records with signed integer fields. An optional decoder validates the application type. */
16
+ declare function exactIntegerJSONCodec<T>(decode?: (value: unknown) => T): Codec<T>;
17
+ /** Connector configuration; omitted fields use manifest defaults. */
18
+ interface Config {
19
+ /** Non-secret subscription REST endpoint from https://app.marketo.com/ > Admin > Integration > Web Services > REST API > Endpoint. Copy the complete HTTPS URL ending in /rest, such as https://123-ABC-456.mktorest.com/rest; blank prevents requests. */
20
+ restEndpoint: string;
21
+ /** Non-secret Identity URL from https://app.marketo.com/ > Admin > Integration > Web Services > REST API > Identity, followed by /oauth/token. Enter a complete HTTPS URL ending in /identity/oauth/token on the same subscription host as restEndpoint; blank prevents token minting. */
22
+ tokenEndpoint: string;
23
+ /** Maximum duration of one Marketo API request as a positive Go duration. Leave blank for the displayed default; increase only for slow provider responses. Runtime value in milliseconds. */
24
+ timeoutMs?: number;
25
+ /** Maximum bytes in one complete Marketo response as a positive integer. Leave blank for the displayed default; increase only for unusually large responses. */
26
+ maxResponseBytes?: number;
27
+ }
28
+ /** Runtime schema for manifest configuration. */
29
+ declare const ConfigSchema: z.ZodObject<{
30
+ restEndpoint: z.ZodString;
31
+ tokenEndpoint: z.ZodString;
32
+ timeoutMs: z.ZodOptional<z.ZodNumber>;
33
+ maxResponseBytes: z.ZodOptional<z.ZodNumber>;
34
+ }, z.core.$strip>;
35
+ /** Private connector credentials resolved by the host. */
36
+ interface Credentials {
37
+ /** Secret short-lived token derived from the custom service's Client ID and Client Secret. Leave blank for automatic minting; never paste a token. */
38
+ accessToken?: SecretString;
39
+ /** Non-secret Client ID from https://app.marketo.com/ > Admin > Integration > LaunchPoint > your Custom service > View Details. Copy the complete value; blank prevents token minting. */
40
+ clientId: string;
41
+ /** Secret Client Secret from https://app.marketo.com/ > Admin > Integration > LaunchPoint > your Custom service > View Details. Store only in Dex Web; blank prevents token minting. */
42
+ clientSecret: SecretString;
43
+ }
44
+ /** Stored credential material that fails the connector credential checks, so no retry can succeed. */
45
+ declare class CredentialMaterialError extends TypeError {
46
+ constructor(message: string);
47
+ }
48
+ /** Report malformed stored credential material, also behind the SDK provider's decoding TypeError. */
49
+ declare function isCredentialMaterialError(error: unknown): boolean;
50
+ /** Decode private credential fields for the connector. */
51
+ declare function decodeCredentials(value: unknown): Credentials;
52
+ /** Decode shared credential fields for the connector. */
53
+ declare function decodeSharedCredentials(value: unknown): Credentials;
54
+ /** Host-owned source of private connector credentials. */
55
+ type CredentialSource = RefreshingCredentialProvider<Credentials>;
56
+ /** GetOpportunityByExternalIDInput identifies one opportunity by its stable external key. */
57
+ interface GetOpportunityByExternalIDInput {
58
+ /** ExternalOpportunityID is the key supplied when the opportunity was created. */
59
+ "externalOpportunityId": string;
60
+ }
61
+ /** OpportunityProfile contains only the provider GUID and name. */
62
+ interface OpportunityProfile {
63
+ /** MarketoGUID is the provider opportunity identifier. */
64
+ "marketoGUID": string;
65
+ /** Name is the opportunity display name. */
66
+ "name": string;
67
+ }
68
+ /** CreateOpportunityInput creates an opportunity under an external identifier. */
69
+ interface CreateOpportunityInput {
70
+ /** ExternalOpportunityID is a stable, unique key in the source system. */
71
+ "externalOpportunityId": string;
72
+ /** Name is the display name to create. */
73
+ "name": string;
74
+ }
75
+ /** OpportunityWriteResult identifies a created or updated opportunity. */
76
+ interface OpportunityWriteResult {
77
+ /** MarketoGUID is the provider opportunity identifier. */
78
+ "marketoGUID": string;
79
+ /** Status is created or updated. */
80
+ "status": string;
81
+ }
82
+ /** UpsertOpportunityInput replaces an opportunity's name by external identifier. */
83
+ interface UpsertOpportunityInput {
84
+ /** ExternalOpportunityID is the stable deduplication key. */
85
+ "externalOpportunityId": string;
86
+ /** Name is the display name to create or replace. */
87
+ "name": string;
88
+ }
89
+ /** DeleteOpportunityInput identifies an opportunity to remove by external key. */
90
+ interface DeleteOpportunityInput {
91
+ /** ExternalOpportunityID is the stable deduplication key. */
92
+ "externalOpportunityId": string;
93
+ }
94
+ /** DeletedOpportunity confirms the target opportunity is absent. */
95
+ interface DeletedOpportunity {
96
+ /** Deleted is true for both removed and already-absent opportunities. */
97
+ "deleted": boolean;
98
+ }
99
+ /** GetCompanyByExternalIDInput identifies one company by its stable external key. */
100
+ interface GetCompanyByExternalIDInput {
101
+ /** ExternalCompanyID is the key supplied when the company was created. */
102
+ "externalCompanyId": string;
103
+ }
104
+ /** CompanyProfile contains only the provider ID and display name. */
105
+ interface CompanyProfile {
106
+ /** ID is the Marketo company ID. */
107
+ "id": SignedInteger;
108
+ /** Company is the company display name. */
109
+ "company": string;
110
+ }
111
+ /** CreateCompanyInput creates a company under an external identifier. */
112
+ interface CreateCompanyInput {
113
+ /** ExternalCompanyID is a stable, unique key in the source system. */
114
+ "externalCompanyId": string;
115
+ /** Company is the display name to create. */
116
+ "company": string;
117
+ }
118
+ /** CompanyWriteResult identifies a created or updated company. */
119
+ interface CompanyWriteResult {
120
+ /** ID is the Marketo company ID. */
121
+ "id": SignedInteger;
122
+ /** Status is created or updated. */
123
+ "status": string;
124
+ }
125
+ /** UpsertCompanyInput replaces a company's name by external identifier. */
126
+ interface UpsertCompanyInput {
127
+ /** ExternalCompanyID is the stable deduplication key. */
128
+ "externalCompanyId": string;
129
+ /** Company is the display name to create or replace. */
130
+ "company": string;
131
+ }
132
+ /** DeleteCompanyInput identifies a company to remove by external key. */
133
+ interface DeleteCompanyInput {
134
+ /** ExternalCompanyID is the stable deduplication key. */
135
+ "externalCompanyId": string;
136
+ }
137
+ /** DeletedCompany confirms the target company is absent. */
138
+ interface DeletedCompany {
139
+ /** Deleted is true for both removed and already-absent companies. */
140
+ "deleted": boolean;
141
+ }
142
+ /** GetActivityPagingTokenInput selects the first activity timestamp to read. */
143
+ interface GetActivityPagingTokenInput {
144
+ /** SinceDatetime is an RFC 3339 timestamp with a timezone. */
145
+ "sinceDatetime": string;
146
+ }
147
+ /** ActivityPagingToken is a Marketo cursor for activity queries. */
148
+ interface ActivityPagingToken {
149
+ /** NextPageToken is passed to ListActivities. */
150
+ "nextPageToken": string;
151
+ }
152
+ /** ListActivityTypesInput requests all activity types in a subscription. */
153
+ interface ListActivityTypesInput {
154
+ }
155
+ /** ActivityType identifies an activity kind without exposing its attribute schema. */
156
+ interface ActivityType {
157
+ /** ID is the Marketo activity type ID. */
158
+ "id": SignedInteger;
159
+ /** Name is the activity type's display name. */
160
+ "name": string;
161
+ }
162
+ /** ActivityTypes contains the subscription's available activity types. */
163
+ interface ActivityTypes {
164
+ /** Types contains only IDs and display names. */
165
+ "types": Array<ActivityType> | null;
166
+ }
167
+ /** ListActivitiesInput selects one page and up to ten activity types. */
168
+ interface ListActivitiesInput {
169
+ /** NextPageToken comes from GetActivityPagingToken or the preceding page. */
170
+ "nextPageToken": string;
171
+ /** ActivityTypeIDs contains one to ten IDs from ListActivityTypes. */
172
+ "activityTypeIds": Array<SignedInteger> | null;
173
+ }
174
+ /** ActivityMetadata omits provider attributes, form fields, and URL values. */
175
+ interface ActivityMetadata {
176
+ /** MarketoGUID uniquely identifies an activity; older responses use the numeric ID. */
177
+ "marketoGUID": string;
178
+ /** LeadID identifies the lead associated with the activity. */
179
+ "leadId": SignedInteger;
180
+ /** ActivityTypeID identifies the activity type. */
181
+ "activityTypeId": SignedInteger;
182
+ /** ActivityDate is the provider timestamp. */
183
+ "activityDate": string;
184
+ }
185
+ /** ActivityPage contains safe activity metadata and the next cursor. */
186
+ interface ActivityPage {
187
+ /** Activities contains one page of activity metadata. */
188
+ "activities": Array<ActivityMetadata> | null;
189
+ /** NextPageToken is the cursor for the following page. */
190
+ "nextPageToken": string;
191
+ /** MoreResult is true while Marketo has more records in this result set. */
192
+ "moreResult": boolean;
193
+ }
194
+ /** CreateLeadInput creates one lead using an email as Marketo's deduplication key. */
195
+ interface CreateLeadInput {
196
+ /** Email is the lead's exact ASCII email address and is omitted from results. */
197
+ "email": string;
198
+ /** FirstName is the lead's first name when supplied. */
199
+ "firstName"?: string | undefined;
200
+ /** LastName is the lead's last name when supplied. */
201
+ "lastName"?: string | undefined;
202
+ }
203
+ /** CreatedLead identifies a lead accepted by Marketo. */
204
+ interface CreatedLead {
205
+ /** ID is the Marketo lead ID. */
206
+ "id": SignedInteger;
207
+ /** Status is created. */
208
+ "status": string;
209
+ }
210
+ /** UpsertLeadByEmailInput creates or updates one lead matched by email. */
211
+ interface UpsertLeadByEmailInput {
212
+ /** Email is the exact lookup address and is never returned in the result. */
213
+ "email": string;
214
+ /** FirstName replaces the first name when supplied. */
215
+ "firstName"?: string | undefined;
216
+ /** LastName replaces the last name when supplied. */
217
+ "lastName"?: string | undefined;
218
+ }
219
+ /** SyncedLead identifies a lead created or updated by Marketo. */
220
+ interface SyncedLead {
221
+ /** ID is the Marketo lead ID. */
222
+ "id": SignedInteger;
223
+ /** Status is created or updated. */
224
+ "status": string;
225
+ }
226
+ /** GetLeadInput selects one non-secret positive Marketo lead ID. */
227
+ interface GetLeadInput {
228
+ /** LeadID is the ID shown on a lead detail page or returned by a lead query. */
229
+ "leadId": SignedInteger;
230
+ }
231
+ /** LeadProfile contains the selected ID and optional names, excluding email and other fields. */
232
+ interface LeadProfile {
233
+ /** ID is the Marketo lead ID. */
234
+ "id": SignedInteger;
235
+ /** FirstName is the lead's first name, or empty when absent. */
236
+ "firstName": string;
237
+ /** LastName is the lead's last name, or empty when absent. */
238
+ "lastName": string;
239
+ }
240
+ /** FindLeadsByEmailInput selects a page of Marketo leads with one exact email. */
241
+ interface FindLeadsByEmailInput {
242
+ /** Email is the address to match; it is sent as a query value and excluded from results. */
243
+ "email": string;
244
+ /** NextPageToken is an opaque token returned by a previous page; blank starts a search. */
245
+ "nextPageToken"?: string | undefined;
246
+ }
247
+ /** LeadProfilesPage contains matching IDs and names without email addresses. */
248
+ interface LeadProfilesPage {
249
+ /** Leads contains the matching lead profiles. */
250
+ "leads": Array<LeadProfile> | null;
251
+ /** NextPageToken selects the next page, or is blank when no more results remain. */
252
+ "nextPageToken": string;
253
+ }
254
+ /** UpdateLeadInput replaces selected fields on an existing lead. */
255
+ interface UpdateLeadInput {
256
+ /** LeadID is the positive ID of the existing lead. */
257
+ "leadId": SignedInteger;
258
+ /** FirstName replaces the first name when supplied. */
259
+ "firstName"?: string | undefined;
260
+ /** LastName replaces the last name when supplied. */
261
+ "lastName"?: string | undefined;
262
+ }
263
+ /** UpdatedLead identifies an accepted lead update. */
264
+ interface UpdatedLead {
265
+ /** ID is the lead ID. */
266
+ "id": SignedInteger;
267
+ /** Status is Marketo's update status. */
268
+ "status": string;
269
+ }
270
+ /** Runtime validator for GetOpportunityByExternalIDInput. */
271
+ declare const GetOpportunityByExternalIDInputSchema: z.ZodObject<{
272
+ externalOpportunityId: z.ZodString;
273
+ }, z.core.$strict>;
274
+ /** Runtime validator for OpportunityProfile. */
275
+ declare const OpportunityProfileSchema: z.ZodObject<{
276
+ marketoGUID: z.ZodString;
277
+ name: z.ZodString;
278
+ }, z.core.$strict>;
279
+ /** Runtime validator for CreateOpportunityInput. */
280
+ declare const CreateOpportunityInputSchema: z.ZodObject<{
281
+ externalOpportunityId: z.ZodString;
282
+ name: z.ZodString;
283
+ }, z.core.$strict>;
284
+ /** Runtime validator for OpportunityWriteResult. */
285
+ declare const OpportunityWriteResultSchema: z.ZodObject<{
286
+ marketoGUID: z.ZodString;
287
+ status: z.ZodString;
288
+ }, z.core.$strict>;
289
+ /** Runtime validator for UpsertOpportunityInput. */
290
+ declare const UpsertOpportunityInputSchema: z.ZodObject<{
291
+ externalOpportunityId: z.ZodString;
292
+ name: z.ZodString;
293
+ }, z.core.$strict>;
294
+ /** Runtime validator for DeleteOpportunityInput. */
295
+ declare const DeleteOpportunityInputSchema: z.ZodObject<{
296
+ externalOpportunityId: z.ZodString;
297
+ }, z.core.$strict>;
298
+ /** Runtime validator for DeletedOpportunity. */
299
+ declare const DeletedOpportunitySchema: z.ZodObject<{
300
+ deleted: z.ZodBoolean;
301
+ }, z.core.$strict>;
302
+ /** Runtime validator for GetCompanyByExternalIDInput. */
303
+ declare const GetCompanyByExternalIDInputSchema: z.ZodObject<{
304
+ externalCompanyId: z.ZodString;
305
+ }, z.core.$strict>;
306
+ /** Runtime validator for CompanyProfile. */
307
+ declare const CompanyProfileSchema: z.ZodObject<{
308
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
309
+ rawJSON: string;
310
+ }>, unknown>>;
311
+ company: z.ZodString;
312
+ }, z.core.$strict>;
313
+ /** Runtime validator for CreateCompanyInput. */
314
+ declare const CreateCompanyInputSchema: z.ZodObject<{
315
+ externalCompanyId: z.ZodString;
316
+ company: z.ZodString;
317
+ }, z.core.$strict>;
318
+ /** Runtime validator for CompanyWriteResult. */
319
+ declare const CompanyWriteResultSchema: z.ZodObject<{
320
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
321
+ rawJSON: string;
322
+ }>, unknown>>;
323
+ status: z.ZodString;
324
+ }, z.core.$strict>;
325
+ /** Runtime validator for UpsertCompanyInput. */
326
+ declare const UpsertCompanyInputSchema: z.ZodObject<{
327
+ externalCompanyId: z.ZodString;
328
+ company: z.ZodString;
329
+ }, z.core.$strict>;
330
+ /** Runtime validator for DeleteCompanyInput. */
331
+ declare const DeleteCompanyInputSchema: z.ZodObject<{
332
+ externalCompanyId: z.ZodString;
333
+ }, z.core.$strict>;
334
+ /** Runtime validator for DeletedCompany. */
335
+ declare const DeletedCompanySchema: z.ZodObject<{
336
+ deleted: z.ZodBoolean;
337
+ }, z.core.$strict>;
338
+ /** Runtime validator for GetActivityPagingTokenInput. */
339
+ declare const GetActivityPagingTokenInputSchema: z.ZodObject<{
340
+ sinceDatetime: z.ZodString;
341
+ }, z.core.$strict>;
342
+ /** Runtime validator for ActivityPagingToken. */
343
+ declare const ActivityPagingTokenSchema: z.ZodObject<{
344
+ nextPageToken: z.ZodString;
345
+ }, z.core.$strict>;
346
+ /** Runtime validator for ListActivityTypesInput. */
347
+ declare const ListActivityTypesInputSchema: z.ZodObject<{}, z.core.$strict>;
348
+ /** Runtime validator for ActivityType. */
349
+ declare const ActivityTypeSchema: z.ZodObject<{
350
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
351
+ rawJSON: string;
352
+ }>, unknown>>;
353
+ name: z.ZodString;
354
+ }, z.core.$strict>;
355
+ /** Runtime validator for ActivityTypes. */
356
+ declare const ActivityTypesSchema: z.ZodObject<{
357
+ types: z.ZodNullable<z.ZodArray<z.ZodObject<{
358
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
359
+ rawJSON: string;
360
+ }>, unknown>>;
361
+ name: z.ZodString;
362
+ }, z.core.$strict>>>;
363
+ }, z.core.$strict>;
364
+ /** Runtime validator for ListActivitiesInput. */
365
+ declare const ListActivitiesInputSchema: z.ZodObject<{
366
+ nextPageToken: z.ZodString;
367
+ activityTypeIds: z.ZodNullable<z.ZodArray<z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
368
+ rawJSON: string;
369
+ }>, unknown>>>>;
370
+ }, z.core.$strict>;
371
+ /** Runtime validator for ActivityMetadata. */
372
+ declare const ActivityMetadataSchema: z.ZodObject<{
373
+ marketoGUID: z.ZodString;
374
+ leadId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
375
+ rawJSON: string;
376
+ }>, unknown>>;
377
+ activityTypeId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
378
+ rawJSON: string;
379
+ }>, unknown>>;
380
+ activityDate: z.ZodString;
381
+ }, z.core.$strict>;
382
+ /** Runtime validator for ActivityPage. */
383
+ declare const ActivityPageSchema: z.ZodObject<{
384
+ activities: z.ZodNullable<z.ZodArray<z.ZodObject<{
385
+ marketoGUID: z.ZodString;
386
+ leadId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
387
+ rawJSON: string;
388
+ }>, unknown>>;
389
+ activityTypeId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
390
+ rawJSON: string;
391
+ }>, unknown>>;
392
+ activityDate: z.ZodString;
393
+ }, z.core.$strict>>>;
394
+ nextPageToken: z.ZodString;
395
+ moreResult: z.ZodBoolean;
396
+ }, z.core.$strict>;
397
+ /** Runtime validator for CreateLeadInput. */
398
+ declare const CreateLeadInputSchema: z.ZodObject<{
399
+ email: z.ZodString;
400
+ firstName: z.ZodOptional<z.ZodString>;
401
+ lastName: z.ZodOptional<z.ZodString>;
402
+ }, z.core.$strict>;
403
+ /** Runtime validator for CreatedLead. */
404
+ declare const CreatedLeadSchema: z.ZodObject<{
405
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
406
+ rawJSON: string;
407
+ }>, unknown>>;
408
+ status: z.ZodString;
409
+ }, z.core.$strict>;
410
+ /** Runtime validator for UpsertLeadByEmailInput. */
411
+ declare const UpsertLeadByEmailInputSchema: z.ZodObject<{
412
+ email: z.ZodString;
413
+ firstName: z.ZodOptional<z.ZodString>;
414
+ lastName: z.ZodOptional<z.ZodString>;
415
+ }, z.core.$strict>;
416
+ /** Runtime validator for SyncedLead. */
417
+ declare const SyncedLeadSchema: z.ZodObject<{
418
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
419
+ rawJSON: string;
420
+ }>, unknown>>;
421
+ status: z.ZodString;
422
+ }, z.core.$strict>;
423
+ /** Runtime validator for GetLeadInput. */
424
+ declare const GetLeadInputSchema: z.ZodObject<{
425
+ leadId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
426
+ rawJSON: string;
427
+ }>, unknown>>;
428
+ }, z.core.$strict>;
429
+ /** Runtime validator for LeadProfile. */
430
+ declare const LeadProfileSchema: z.ZodObject<{
431
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
432
+ rawJSON: string;
433
+ }>, unknown>>;
434
+ firstName: z.ZodString;
435
+ lastName: z.ZodString;
436
+ }, z.core.$strict>;
437
+ /** Runtime validator for FindLeadsByEmailInput. */
438
+ declare const FindLeadsByEmailInputSchema: z.ZodObject<{
439
+ email: z.ZodString;
440
+ nextPageToken: z.ZodOptional<z.ZodString>;
441
+ }, z.core.$strict>;
442
+ /** Runtime validator for LeadProfilesPage. */
443
+ declare const LeadProfilesPageSchema: z.ZodObject<{
444
+ leads: z.ZodNullable<z.ZodArray<z.ZodObject<{
445
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
446
+ rawJSON: string;
447
+ }>, unknown>>;
448
+ firstName: z.ZodString;
449
+ lastName: z.ZodString;
450
+ }, z.core.$strict>>>;
451
+ nextPageToken: z.ZodString;
452
+ }, z.core.$strict>;
453
+ /** Runtime validator for UpdateLeadInput. */
454
+ declare const UpdateLeadInputSchema: z.ZodObject<{
455
+ leadId: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
456
+ rawJSON: string;
457
+ }>, unknown>>;
458
+ firstName: z.ZodOptional<z.ZodString>;
459
+ lastName: z.ZodOptional<z.ZodString>;
460
+ }, z.core.$strict>;
461
+ /** Runtime validator for UpdatedLead. */
462
+ declare const UpdatedLeadSchema: z.ZodObject<{
463
+ id: z.ZodPipe<z.ZodUnknown, z.ZodTransform<number | Readonly<{
464
+ rawJSON: string;
465
+ }>, unknown>>;
466
+ status: z.ZodString;
467
+ }, z.core.$strict>;
468
+
469
+ /** Typed operations supplied by a client or mock. */
470
+ interface Operations {
471
+ /** Invoke getOpportunityByExternalID through this connection. */
472
+ getOpportunityByExternalID(): Query<GetOpportunityByExternalIDInput, OpportunityProfile>;
473
+ /** Invoke createOpportunity through this connection. */
474
+ createOpportunity(): Mutation<CreateOpportunityInput, OpportunityWriteResult>;
475
+ /** Invoke upsertOpportunity through this connection. */
476
+ upsertOpportunity(): Mutation<UpsertOpportunityInput, OpportunityWriteResult>;
477
+ /** Invoke deleteOpportunity through this connection. */
478
+ deleteOpportunity(): Mutation<DeleteOpportunityInput, DeletedOpportunity>;
479
+ /** Invoke getCompanyByExternalID through this connection. */
480
+ getCompanyByExternalID(): Query<GetCompanyByExternalIDInput, CompanyProfile>;
481
+ /** Invoke createCompany through this connection. */
482
+ createCompany(): Mutation<CreateCompanyInput, CompanyWriteResult>;
483
+ /** Invoke upsertCompany through this connection. */
484
+ upsertCompany(): Mutation<UpsertCompanyInput, CompanyWriteResult>;
485
+ /** Invoke deleteCompany through this connection. */
486
+ deleteCompany(): Mutation<DeleteCompanyInput, DeletedCompany>;
487
+ /** Invoke getActivityPagingToken through this connection. */
488
+ getActivityPagingToken(): Query<GetActivityPagingTokenInput, ActivityPagingToken>;
489
+ /** Invoke listActivityTypes through this connection. */
490
+ listActivityTypes(): Query<ListActivityTypesInput, ActivityTypes>;
491
+ /** Invoke listActivities through this connection. */
492
+ listActivities(): Query<ListActivitiesInput, ActivityPage>;
493
+ /** Invoke createLead through this connection. */
494
+ createLead(): Mutation<CreateLeadInput, CreatedLead>;
495
+ /** Invoke upsertLeadByEmail through this connection. */
496
+ upsertLeadByEmail(): Mutation<UpsertLeadByEmailInput, SyncedLead>;
497
+ /** Invoke getLead through this connection. */
498
+ getLead(): Query<GetLeadInput, LeadProfile>;
499
+ /** Invoke findLeadsByEmail through this connection. */
500
+ findLeadsByEmail(): Query<FindLeadsByEmailInput, LeadProfilesPage>;
501
+ /** Invoke updateLead through this connection. */
502
+ updateLead(): Mutation<UpdateLeadInput, UpdatedLead>;
503
+ }
504
+ /** Named connector connection kept outside Flow state. */
505
+ declare class Connection<BoundOperations = Operations> {
506
+ /** Stable provider and connection name. */
507
+ readonly reference: ConnectionRef;
508
+ /** Bound provider operations. */
509
+ readonly operations: BoundOperations;
510
+ /** Validate a reference and bind operations. */
511
+ constructor(reference: ConnectionRef, operations: BoundOperations);
512
+ }
513
+ /** Bind a client to a named connection. */
514
+ declare function newConnection(client: Operations, reference: ConnectionRef): Connection;
515
+ /** Bind scripted operations to a named connection. */
516
+ declare function newConnectionWithOperations(operations: Operations, reference: ConnectionRef): Connection;
517
+
518
+ export { DeletedCompanySchema as $, type ActivityPagingToken as A, type ActivityMetadata as B, type CreateCompanyInput as C, type DeleteCompanyInput as D, ActivityMetadataSchema as E, type FindLeadsByEmailInput as F, type GetActivityPagingTokenInput as G, ActivityPageSchema as H, ActivityPagingTokenSchema as I, type ActivityType as J, ActivityTypeSchema as K, type LeadProfilesPage as L, ActivityTypesSchema as M, CompanyProfileSchema as N, type OpportunityWriteResult as O, CompanyWriteResultSchema as P, ConfigSchema as Q, CreateCompanyInputSchema as R, type SyncedLead as S, CreateLeadInputSchema as T, type UpdateLeadInput as U, CreateOpportunityInputSchema as V, CreatedLeadSchema as W, CredentialMaterialError as X, type Credentials as Y, DeleteCompanyInputSchema as Z, DeleteOpportunityInputSchema as _, type CompanyWriteResult as a, DeletedOpportunitySchema as a0, FindLeadsByEmailInputSchema as a1, GetActivityPagingTokenInputSchema as a2, GetCompanyByExternalIDInputSchema as a3, GetLeadInputSchema as a4, GetOpportunityByExternalIDInputSchema as a5, LeadProfileSchema as a6, LeadProfilesPageSchema as a7, ListActivitiesInputSchema as a8, ListActivityTypesInputSchema as a9, OpportunityProfileSchema as aa, OpportunityWriteResultSchema as ab, SyncedLeadSchema as ac, UpdateLeadInputSchema as ad, UpdatedLeadSchema as ae, UpsertCompanyInputSchema as af, UpsertLeadByEmailInputSchema as ag, UpsertOpportunityInputSchema as ah, decodeCredentials as ai, decodeSharedCredentials as aj, decodeSignedInteger as ak, exactIntegerJSONCodec as al, isCredentialMaterialError as am, newConnection as an, newConnectionWithOperations as ao, parseExactIntegerJSON as ap, parseJSONNumberTokens as aq, Connection as b, type CreateLeadInput as c, type CreatedLead as d, type CreateOpportunityInput as e, type DeletedCompany as f, type DeleteOpportunityInput as g, type DeletedOpportunity as h, type GetCompanyByExternalIDInput as i, type CompanyProfile as j, type GetLeadInput as k, type LeadProfile as l, type GetOpportunityByExternalIDInput as m, type OpportunityProfile as n, type ListActivitiesInput as o, type ActivityPage as p, type ListActivityTypesInput as q, type ActivityTypes as r, type UpdatedLead as s, type UpsertCompanyInput as t, type UpsertLeadByEmailInput as u, type UpsertOpportunityInput as v, type Operations as w, type SignedInteger as x, type Config as y, type CredentialSource as z };