@superdurable/connector-intuit-quickbooks 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.
package/dist/index.d.ts CHANGED
@@ -1,11 +1,12 @@
1
1
  import { ProviderRequest, ProviderResponse } from '@superdurable/connectors-sdk/providerhttp';
2
2
  import * as _superdurable_connectors_sdk from '@superdurable/connectors-sdk';
3
- import { Query, Call, QueryAttempt, Mutation, MutationAttempt, Failure, ReceiptDraft, MutationStepConfig, MutationResult, QueryStepConfig, QueryResult, MutationStep, QueryStep, MutationDefinition, QueryDefinition } from '@superdurable/connectors-sdk';
4
- import { F as FindCustomerInput, a as FindCustomerOutput, C as CreateCustomerInput, b as CreateCustomerOutput, c as CreateInvoiceInput, d as CreateInvoiceOutput, G as GetInvoiceInput, I as Invoice, L as ListInvoicesInput, e as InvoicePage, S as SendInvoiceInput, R as RecordPaymentInput, P as Payment, f as Config, g as CredentialSource, h as Connection, O as Operations } from './connection-DfEHGjAp.js';
5
- export { i as ConfigSchema, j as CreateCustomerInputSchema, k as CreateCustomerOutputSchema, l as CreateInvoiceInputSchema, m as CreateInvoiceOutputSchema, n as Credentials, o as Customer, p as CustomerSchema, q as FindCustomerInputSchema, r as FindCustomerOutputSchema, s as GetInvoiceInputSchema, t as InvoiceLine, u as InvoiceLineInput, v as InvoiceLineInputSchema, w as InvoiceLineSchema, x as InvoicePageSchema, y as InvoiceSchema, z as ListInvoicesInputSchema, A as PaymentApplication, B as PaymentApplicationSchema, D as PaymentSchema, E as RecordPaymentInputSchema, H as SendInvoiceInputSchema, J as decodeCredentials, K as decodeSharedCredentials, M as newConnection, N as newConnectionWithOperations, Q as newProjectCredentialProvider } from './connection-DfEHGjAp.js';
3
+ import { Query, Call, QueryAttempt, Mutation, MutationAttempt, TriggerLogger, Failure, ReceiptDraft, MutationStepConfig, MutationResult, QueryStepConfig, QueryResult, MutationStep, QueryStep, MutationDefinition, QueryDefinition, ConnectorConfigurationUI, TriggerDefinition, TriggerBindingDefinition, TriggerEvent, ConnectionRef, TriggerContext, TriggerTarget, TriggerRunner } from '@superdurable/connectors-sdk';
4
+ import { F as FindCustomerInput, a as FindCustomerOutput, C as CreateCustomerInput, b as CreateCustomerOutput, c as CreateInvoiceInput, d as CreateInvoiceOutput, G as GetInvoiceInput, I as Invoice, L as ListInvoicesInput, e as InvoicePage, S as SendInvoiceInput, R as RecordPaymentInput, P as Payment, f as Config, g as CredentialSource, h as Connection, O as Operations } from './connection-yvzYeBut.js';
5
+ export { i as ConfigSchema, j as CreateCustomerInputSchema, k as CreateCustomerOutputSchema, l as CreateInvoiceInputSchema, m as CreateInvoiceOutputSchema, n as Credentials, o as Customer, p as CustomerSchema, q as FindCustomerInputSchema, r as FindCustomerOutputSchema, s as GetInvoiceInputSchema, t as InvoiceLine, u as InvoiceLineInput, v as InvoiceLineInputSchema, w as InvoiceLineSchema, x as InvoicePageSchema, y as InvoiceSchema, z as ListInvoicesInputSchema, A as PaymentApplication, B as PaymentApplicationSchema, D as PaymentSchema, E as RecordPaymentInputSchema, H as SendInvoiceInputSchema, J as decodeCredentials, K as decodeSharedCredentials, M as newConnection, N as newConnectionWithOperations, Q as newProjectCredentialProvider } from './connection-yvzYeBut.js';
6
6
  import { StepTarget } from '@superdurable/dex';
7
7
  import { LoadedProject } from '@superdurable/connectors-sdk/projectconfig';
8
- import 'zod';
8
+ import { z } from 'zod';
9
+ import { ChangeFetcher, Cursor, ChangePage, CursorStore, Runner } from '@superdurable/connectors-sdk/pollingtrigger';
9
10
 
10
11
  /** Resolve one customer by exact email or display name. */
11
12
  declare class FindCustomerOperation implements Query<FindCustomerInput, FindCustomerOutput> {
@@ -35,7 +36,7 @@ declare class ListInvoicesOperation implements Query<ListInvoicesInput, InvoiceP
35
36
  declare class CreateCustomerOperation implements Mutation<CreateCustomerInput, CreateCustomerOutput> {
36
37
  private readonly client;
37
38
  /** Bind one client. */ constructor(client: QuickBooksClient);
38
- /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
39
+ /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
39
40
  /** Use Dex Call ID as QuickBooks requestid. */ idempotencyKey(callID: string): string;
40
41
  /** Validate, create, and confirm an accepted write if necessary. */
41
42
  invoke(call: Call, input: CreateCustomerInput): Promise<MutationAttempt<CreateCustomerOutput>>;
@@ -44,7 +45,7 @@ declare class CreateCustomerOperation implements Mutation<CreateCustomerInput, C
44
45
  declare class CreateInvoiceOperation implements Mutation<CreateInvoiceInput, CreateInvoiceOutput> {
45
46
  private readonly client;
46
47
  /** Bind one client. */ constructor(client: QuickBooksClient);
47
- /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
48
+ /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
48
49
  /** Use Dex Call ID as QuickBooks requestid. */ idempotencyKey(callID: string): string;
49
50
  /** Validate, create, and read back an accepted invoice if necessary. */
50
51
  invoke(call: Call, input: CreateInvoiceInput): Promise<MutationAttempt<CreateInvoiceOutput>>;
@@ -53,7 +54,7 @@ declare class CreateInvoiceOperation implements Mutation<CreateInvoiceInput, Cre
53
54
  declare class SendInvoiceOperation implements Mutation<SendInvoiceInput, Invoice> {
54
55
  private readonly client;
55
56
  /** Bind one client. */ constructor(client: QuickBooksClient);
56
- /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
57
+ /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
57
58
  /** Use Dex Call ID as QuickBooks requestid. */ idempotencyKey(callID: string): string;
58
59
  /** Send and confirm one invoice delivery. */
59
60
  invoke(call: Call, input: SendInvoiceInput): Promise<MutationAttempt<Invoice>>;
@@ -62,7 +63,7 @@ declare class SendInvoiceOperation implements Mutation<SendInvoiceInput, Invoice
62
63
  declare class RecordPaymentOperation implements Mutation<RecordPaymentInput, Payment> {
63
64
  private readonly client;
64
65
  /** Bind one client. */ constructor(client: QuickBooksClient);
65
- /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.QueryDefinition;
66
+ /** Return the manifest definition. */ definition(): _superdurable_connectors_sdk.MutationDefinition;
66
67
  /** Use Dex Call ID as QuickBooks requestid. */ idempotencyKey(callID: string): string;
67
68
  /** Record and confirm one payment. */
68
69
  invoke(call: Call, input: RecordPaymentInput): Promise<MutationAttempt<Payment>>;
@@ -76,6 +77,12 @@ interface QuickBooksClientOptions {
76
77
  now?: () => Date;
77
78
  /** Loopback HTTP endpoint for the connector's runnable example. */
78
79
  localProviderURL?: string;
80
+ /**
81
+ * Receives the invoiceChanged runner's records: seeds, reseeds, failed polls, rate-limit pauses, and the durable
82
+ * inboxes newProjectInvoiceTriggerRunner opens. Records carry binding identity and never invoice payloads or
83
+ * credentials. Omitted uses defaultTriggerLogger. Operation Steps do not log.
84
+ */
85
+ logger?: TriggerLogger;
79
86
  }
80
87
  /** One classified provider exchange. */
81
88
  interface QuickBooksExchange {
@@ -104,7 +111,12 @@ interface QuickBooksRequest {
104
111
  declare class QuickBooksClient {
105
112
  private readonly credentials;
106
113
  private readonly endpoint;
107
- private readonly environment;
114
+ /** The connection's QuickBooks environment, which selects the API host. */
115
+ readonly environment: 'production' | 'sandbox';
116
+ /** Delay between invoiceChanged polls in milliseconds, at least 5 seconds; 30 seconds by default. */
117
+ readonly pollIntervalMs: number;
118
+ /** Receives the invoiceChanged runner's and durable inboxes' records. */
119
+ readonly triggerLogger: TriggerLogger;
108
120
  private readonly configuredRealmID;
109
121
  private readonly maxResponseBytes;
110
122
  private readonly send;
@@ -450,7 +462,199 @@ declare const RecordPaymentMetadata: {
450
462
  readonly authorization: "required";
451
463
  };
452
464
 
453
- /** Open a named QuickBooks project connection with generated OAuth credential decoders. */
465
+ /**
466
+ * Open a named QuickBooks project connection with generated OAuth credential decoders. options, such as an
467
+ * invoiceChanged logger or a local provider URL for verification, apply to the connection's client.
468
+ */
454
469
  declare function newProjectConnection(project: LoadedProject, connectionName: string, options?: QuickBooksClientOptions): Connection<Operations>;
455
470
 
456
- export { Config, Connection, ConnectorID, CreateCustomerBranch, CreateCustomerBranchCreated, CreateCustomerBranchDefect, CreateCustomerBranchNameConflict, CreateCustomerBranchProviderRejected, CreateCustomerBranchUncertain, CreateCustomerDefinition, CreateCustomerInput, CreateCustomerMetadata, CreateCustomerOutput, type CreateCustomerStepConfig, CreateInvoiceBranch, CreateInvoiceBranchCreated, CreateInvoiceBranchDefect, CreateInvoiceBranchProviderRejected, CreateInvoiceBranchUncertain, CreateInvoiceDefinition, CreateInvoiceInput, CreateInvoiceMetadata, CreateInvoiceOutput, type CreateInvoiceStepConfig, CredentialSource, FindCustomerBranch, FindCustomerBranchAmbiguous, FindCustomerBranchDefect, FindCustomerBranchFound, FindCustomerBranchInvalidResponse, FindCustomerBranchNotFound, FindCustomerBranchProviderRejected, FindCustomerDefinition, FindCustomerInput, FindCustomerMetadata, FindCustomerOutput, type FindCustomerStepConfig, GetInvoiceBranch, GetInvoiceBranchDefect, GetInvoiceBranchFound, GetInvoiceBranchInvalidResponse, GetInvoiceBranchNotFound, GetInvoiceBranchProviderRejected, GetInvoiceDefinition, GetInvoiceInput, GetInvoiceMetadata, type GetInvoiceStepConfig, Invoice, InvoicePage, ListInvoicesBranch, ListInvoicesBranchDefect, ListInvoicesBranchInvalidResponse, ListInvoicesBranchListed, ListInvoicesBranchProviderRejected, ListInvoicesDefinition, ListInvoicesInput, ListInvoicesMetadata, type ListInvoicesStepConfig, Payment, ProviderID, QuickBooksClient, type QuickBooksClientOptions, RecordPaymentBranch, RecordPaymentBranchDefect, RecordPaymentBranchProviderRejected, RecordPaymentBranchRecorded, RecordPaymentBranchUncertain, RecordPaymentDefinition, RecordPaymentInput, RecordPaymentMetadata, type RecordPaymentStepConfig, SendInvoiceBranch, SendInvoiceBranchDefect, SendInvoiceBranchProviderRejected, SendInvoiceBranchSent, SendInvoiceBranchUncertain, SendInvoiceDefinition, SendInvoiceInput, SendInvoiceMetadata, type SendInvoiceStepConfig, newCreateCustomerStep, newCreateInvoiceStep, newFindCustomerStep, newGetInvoiceStep, newListInvoicesStep, newProjectConnection, newRecordPaymentStep, newSendInvoiceStep };
471
+ /** An invoice at its first version: QuickBooks reports SyncToken 0. */
472
+ declare const InvoiceChangeCreated = "created";
473
+ /**
474
+ * Any later version, including an edit, an applied payment that lowers Balance, an email that sets EmailStatus,
475
+ * and a void that zeroes the amounts. An invoice created and edited between two polls arrives once, as updated.
476
+ */
477
+ declare const InvoiceChangeUpdated = "updated";
478
+ /** The derived kind of one invoiceChanged delivery. */
479
+ type InvoiceChangeKind = typeof InvoiceChangeCreated | typeof InvoiceChangeUpdated;
480
+ /**
481
+ * The invoiceChanged binding configuration. A binding watches every invoice of the connection's company, so it has
482
+ * no fields; an application narrows the changes it starts Flows for in its Trigger target's accept function.
483
+ */
484
+ declare const InvoiceChangedTriggerConfigurationSchema: z.ZodObject<{}, z.core.$strict>;
485
+ /** The validated invoiceChanged binding configuration. */
486
+ type InvoiceChangedTriggerConfiguration = z.infer<typeof InvoiceChangedTriggerConfigurationSchema>;
487
+ /**
488
+ * One invoice version read by the invoiceChanged poll; field names match the Go connector. QuickBooks's invoice
489
+ * query does not return deleted invoices, so a deletion is never delivered.
490
+ */
491
+ declare const InvoiceChangedEventSchema: z.ZodObject<{
492
+ realmId: z.ZodString;
493
+ environment: z.ZodString;
494
+ changeKind: z.ZodEnum<{
495
+ created: "created";
496
+ updated: "updated";
497
+ }>;
498
+ invoice: z.ZodObject<{
499
+ invoiceId: z.ZodString;
500
+ syncToken: z.ZodOptional<z.ZodString>;
501
+ docNumber: z.ZodOptional<z.ZodString>;
502
+ customerId: z.ZodString;
503
+ customerName: z.ZodOptional<z.ZodString>;
504
+ txnDate: z.ZodOptional<z.ZodString>;
505
+ dueDate: z.ZodOptional<z.ZodString>;
506
+ currencyCode: z.ZodOptional<z.ZodString>;
507
+ exchangeRate: z.ZodOptional<z.ZodString>;
508
+ lines: z.ZodNullable<z.ZodArray<z.ZodObject<{
509
+ lineId: z.ZodOptional<z.ZodString>;
510
+ detailType: z.ZodString;
511
+ description: z.ZodOptional<z.ZodString>;
512
+ amount: z.ZodOptional<z.ZodString>;
513
+ itemId: z.ZodOptional<z.ZodString>;
514
+ itemName: z.ZodOptional<z.ZodString>;
515
+ quantity: z.ZodOptional<z.ZodString>;
516
+ unitPrice: z.ZodOptional<z.ZodString>;
517
+ taxCodeId: z.ZodOptional<z.ZodString>;
518
+ serviceDate: z.ZodOptional<z.ZodString>;
519
+ }, z.core.$strict>>>;
520
+ totalAmount: z.ZodString;
521
+ totalTax: z.ZodOptional<z.ZodString>;
522
+ balance: z.ZodString;
523
+ emailStatus: z.ZodOptional<z.ZodString>;
524
+ billEmail: z.ZodOptional<z.ZodString>;
525
+ deliveredAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
526
+ customerMemo: z.ZodOptional<z.ZodString>;
527
+ privateNote: z.ZodOptional<z.ZodString>;
528
+ linkedPaymentIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
529
+ createdAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
530
+ updatedAt: z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>>>;
531
+ }, z.core.$strict>;
532
+ }, z.core.$strip>;
533
+ /** One created or changed QuickBooks invoice version. */
534
+ type InvoiceChangedEvent = z.infer<typeof InvoiceChangedEventSchema>;
535
+ /** Manifest definition of invoiceChanged. */
536
+ declare const InvoiceChangedTriggerDefinition: TriggerDefinition;
537
+ /** One static application binding of invoiceChanged. */
538
+ interface InvoiceChangedTriggerBindingConfig {
539
+ /** Static connection name. */ connectionName: string;
540
+ /** Static binding name. */ bindingName: string;
541
+ /** Connector Studio configuration units; invoiceChanged has none, so omit it. */ configurationUI?: ConnectorConfigurationUI;
542
+ }
543
+ /** Declare a static invoiceChanged binding for Flow Definition tooling and Dex Web. */
544
+ declare function defineInvoiceChangedTriggerBinding(config: InvoiceChangedTriggerBindingConfig): TriggerBindingDefinition;
545
+
546
+ /** How far before the newest delivered LastUpdatedTime each invoiceChanged poll rereads, in milliseconds. */
547
+ declare const InvoiceChangeLookbackMs = 30000;
548
+ /** The most invoice versions the invoiceChanged cursor remembers inside the lookback window. */
549
+ declare const MaximumSeenInvoiceVersions = 1000;
550
+ /** Thrown for an invoiceChanged cursor token that is not a valid Go cursor document. */
551
+ declare class InvoiceChangeCursorInvalidError extends Error {
552
+ /** Describe the rejected token without echoing it. */
553
+ constructor(message?: string);
554
+ }
555
+
556
+ /** The MAXRESULTS of each invoiceChanged query; QuickBooks itself accepts up to 1000. */
557
+ declare const InvoiceChangePageSize = 100;
558
+ /** Name one invoice version as "<Id>:<SyncToken>", as the cursor stores it. */
559
+ declare function invoiceVersionKey(invoice: Invoice): string;
560
+ /**
561
+ * Return the Trigger event ID, a hash of the environment, company, Id, SyncToken, and LastUpdatedTime second. It is
562
+ * a pure function of the invoice version, so a refetch after a crash yields the same ID.
563
+ */
564
+ declare function invoiceChangeEventId(realmId: string, environment: string, invoice: Invoice): string;
565
+ /**
566
+ * Polls one company's invoices ordered by MetaData.LastUpdatedTime for the poll Trigger kit, at parity with the Go
567
+ * connector: the cursor is a LastUpdatedTime window rereading 30 seconds before the newest change and the
568
+ * "<Id>:<SyncToken>" versions delivered inside it, encoded as Go's cursor document byte for byte. A poller owns one
569
+ * fetcher and calls it one poll at a time.
570
+ */
571
+ declare class InvoiceChangeFetcher implements ChangeFetcher<TriggerEvent<InvoiceChangedEvent>> {
572
+ private readonly client;
573
+ private readonly connection;
574
+ /** Bind the fetcher to one connection's client. */
575
+ constructor(client: QuickBooksClient, connection: ConnectionRef);
576
+ /**
577
+ * Record every version in the 30 seconds before the newest LastUpdatedTime as the baseline, so existing invoices
578
+ * are never delivered; an empty company delivers its first invoice.
579
+ */
580
+ seedCursor(context: TriggerContext): Promise<Cursor>;
581
+ /**
582
+ * Read one page of invoices changed at or after the window's lower bound, oldest first, skipping versions already
583
+ * delivered or baselined. An undecodable cursor, one for another company or environment, or a QuickBooks
584
+ * validation Fault for the watermark query rejects with markCursorInvalid, so the kit records a new baseline; a
585
+ * 429 rejects with markRateLimited.
586
+ */
587
+ fetchChanges(context: TriggerContext, cursor: Cursor): Promise<ChangePage<TriggerEvent<InvoiceChangedEvent>>>;
588
+ private queryInvoices;
589
+ }
590
+
591
+ /** Binds one invoiceChanged binding to its application target and cursor. */
592
+ interface InvoiceChangedTriggerRoute {
593
+ /** The stable application binding name, unique within the runner. */ bindingName: string;
594
+ /** The binding configuration; it has no fields today, so a binding watches every invoice. */ configuration?: InvoiceChangedTriggerConfiguration;
595
+ /**
596
+ * Routes each invoice change into the application. A durable target from newDurableTriggerTarget records each
597
+ * change before the cursor commits past it; any other target consumes it first.
598
+ */
599
+ target: TriggerTarget<InvoiceChangedEvent>;
600
+ /**
601
+ * Stores the binding's watermark, such as LoadedProject.pollCursorStore. Omitted keeps it in memory, so every
602
+ * process start records a new baseline and changes made while stopped are lost.
603
+ */
604
+ cursor?: CursorStore;
605
+ }
606
+ /** Configures every QuickBooks Trigger binding polled through one connection. */
607
+ interface InvoiceTriggerRunnerConfig {
608
+ /** A connection from newConnection with a QuickBooksClient or from newProjectConnection; a mock has no client. */ connection: Connection;
609
+ /** The invoiceChanged bindings; at least one is required. */ invoiceChangedRoutes: InvoiceChangedTriggerRoute[];
610
+ }
611
+ /**
612
+ * Create one poll runner for the configured invoiceChanged bindings. run replays each durable target, records a
613
+ * baseline for a binding without a cursor, then polls every binding each pollInterval with jitter, one QuickBooks
614
+ * query of at most 100 invoices per request and at most ten pages per poll. Each poll rereads the 30 seconds before
615
+ * the newest change delivered, so a write QuickBooks made visible after an earlier poll still arrives. A 429 pauses
616
+ * every binding of the connection for Retry-After, or 60 seconds without it; other failures back off per binding. A
617
+ * cursor for another company or environment, or a QuickBooks validation Fault for the watermark query, records a
618
+ * new baseline and logs a WARN record; changes in that gap are not delivered. Delivery is at least once, and each
619
+ * invoice version keeps one Trigger event ID. Throws for a missing or mock connection, no routes, a blank binding
620
+ * name, a missing target, or an invalid configuration.
621
+ */
622
+ declare function newInvoiceTriggerRunner(config: InvoiceTriggerRunnerConfig): Runner;
623
+ /** Validate an invoiceChanged configuration; throws for any field, since the binding has none. */
624
+ declare function parseInvoiceChangedTriggerConfiguration(configuration: unknown): InvoiceChangedTriggerConfiguration;
625
+ /** Decode a replayed Trigger inbox payload that the Go or TypeScript connector recorded. */
626
+ declare function decodeInvoiceChangedEventPayload(payloadJSON: string): InvoiceChangedEvent;
627
+ /** Selects one invoiceChanged binding of the project configuration. */
628
+ interface ProjectInvoiceChangedTriggerRoute {
629
+ /** The binding name. */ bindingName: string;
630
+ /** Routes each change into the application, usually newDexFlowTriggerTarget. */ target: TriggerTarget<InvoiceChangedEvent>;
631
+ }
632
+ /** Selects QuickBooks Trigger bindings of the project configuration. */
633
+ interface ProjectInvoiceTriggerRunnerConfig {
634
+ /** The invoiceChanged bindings; at least one is required. */ invoiceChangedRoutes: ProjectInvoiceChangedTriggerRoute[];
635
+ }
636
+ /**
637
+ * Create a durable runner for invoiceChanged bindings of the loaded project. connection is the project connection
638
+ * from newProjectConnection(project, name); its client options, such as logger, also apply to the durable inboxes.
639
+ * Each route records changes in its binding's project Trigger inbox before its watermark commits in the binding's
640
+ * project poll cursor, so a restarted or replaced replica neither misses nor repeats a change. A binding without
641
+ * saved configuration is valid. Throws as newInvoiceTriggerRunner does and for an invalid saved configuration.
642
+ */
643
+ declare function newProjectInvoiceTriggerRunner(project: LoadedProject, connection: Connection, config: ProjectInvoiceTriggerRunnerConfig): Runner;
644
+ /** Configuration of one in-memory invoiceChanged Trigger. */
645
+ interface InvoiceChangedTriggerConfig {
646
+ /** A connection with a QuickBooksClient. */ connection: Connection;
647
+ /** Static connection name; must equal the connection's name. */ connectionName: string;
648
+ /** Static binding name. */ bindingName: string;
649
+ /** The binding configuration; it has no fields today. */ configuration?: InvoiceChangedTriggerConfiguration;
650
+ /** Routes accepted changes into the application. */ target: TriggerTarget<InvoiceChangedEvent>;
651
+ }
652
+ /**
653
+ * Create one invoiceChanged Trigger with an in-memory cursor, as Go's generated NewInvoiceChangedTrigger. It has no
654
+ * project storage, so it records a new baseline on every start and changes made while it is stopped are lost; use
655
+ * newProjectInvoiceTriggerRunner for durable delivery. Throws when connectionName differs from the connection's
656
+ * name, for a mock connection, or for an invalid configuration.
657
+ */
658
+ declare function newInvoiceChangedTrigger(config: InvoiceChangedTriggerConfig): TriggerRunner;
659
+
660
+ export { Config, Connection, ConnectorID, CreateCustomerBranch, CreateCustomerBranchCreated, CreateCustomerBranchDefect, CreateCustomerBranchNameConflict, CreateCustomerBranchProviderRejected, CreateCustomerBranchUncertain, CreateCustomerDefinition, CreateCustomerInput, CreateCustomerMetadata, CreateCustomerOutput, type CreateCustomerStepConfig, CreateInvoiceBranch, CreateInvoiceBranchCreated, CreateInvoiceBranchDefect, CreateInvoiceBranchProviderRejected, CreateInvoiceBranchUncertain, CreateInvoiceDefinition, CreateInvoiceInput, CreateInvoiceMetadata, CreateInvoiceOutput, type CreateInvoiceStepConfig, CredentialSource, FindCustomerBranch, FindCustomerBranchAmbiguous, FindCustomerBranchDefect, FindCustomerBranchFound, FindCustomerBranchInvalidResponse, FindCustomerBranchNotFound, FindCustomerBranchProviderRejected, FindCustomerDefinition, FindCustomerInput, FindCustomerMetadata, FindCustomerOutput, type FindCustomerStepConfig, GetInvoiceBranch, GetInvoiceBranchDefect, GetInvoiceBranchFound, GetInvoiceBranchInvalidResponse, GetInvoiceBranchNotFound, GetInvoiceBranchProviderRejected, GetInvoiceDefinition, GetInvoiceInput, GetInvoiceMetadata, type GetInvoiceStepConfig, Invoice, InvoiceChangeCreated, InvoiceChangeCursorInvalidError, InvoiceChangeFetcher, type InvoiceChangeKind, InvoiceChangeLookbackMs, InvoiceChangePageSize, InvoiceChangeUpdated, type InvoiceChangedEvent, InvoiceChangedEventSchema, type InvoiceChangedTriggerBindingConfig, type InvoiceChangedTriggerConfig, type InvoiceChangedTriggerConfiguration, InvoiceChangedTriggerConfigurationSchema, InvoiceChangedTriggerDefinition, type InvoiceChangedTriggerRoute, InvoicePage, type InvoiceTriggerRunnerConfig, ListInvoicesBranch, ListInvoicesBranchDefect, ListInvoicesBranchInvalidResponse, ListInvoicesBranchListed, ListInvoicesBranchProviderRejected, ListInvoicesDefinition, ListInvoicesInput, ListInvoicesMetadata, type ListInvoicesStepConfig, MaximumSeenInvoiceVersions, Payment, type ProjectInvoiceChangedTriggerRoute, type ProjectInvoiceTriggerRunnerConfig, ProviderID, QuickBooksClient, type QuickBooksClientOptions, RecordPaymentBranch, RecordPaymentBranchDefect, RecordPaymentBranchProviderRejected, RecordPaymentBranchRecorded, RecordPaymentBranchUncertain, RecordPaymentDefinition, RecordPaymentInput, RecordPaymentMetadata, type RecordPaymentStepConfig, SendInvoiceBranch, SendInvoiceBranchDefect, SendInvoiceBranchProviderRejected, SendInvoiceBranchSent, SendInvoiceBranchUncertain, SendInvoiceDefinition, SendInvoiceInput, SendInvoiceMetadata, type SendInvoiceStepConfig, decodeInvoiceChangedEventPayload, defineInvoiceChangedTriggerBinding, invoiceChangeEventId, invoiceVersionKey, newCreateCustomerStep, newCreateInvoiceStep, newFindCustomerStep, newGetInvoiceStep, newInvoiceChangedTrigger, newInvoiceTriggerRunner, newListInvoicesStep, newProjectConnection, newProjectInvoiceTriggerRunner, newRecordPaymentStep, newSendInvoiceStep, parseInvoiceChangedTriggerConfiguration };