@tangle-network/agent-integrations 0.27.0 → 0.29.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/README.md +40 -0
- package/dist/bin/tangle-catalog-runtime.js +4 -2
- package/dist/bin/tangle-catalog-runtime.js.map +1 -1
- package/dist/catalog.d.ts +1 -0
- package/dist/catalog.js +4 -2
- package/dist/chunk-H4XYLS7T.js +75 -0
- package/dist/chunk-H4XYLS7T.js.map +1 -0
- package/dist/{chunk-ICSBYCE2.js → chunk-TUX6MJJ4.js} +15 -83
- package/dist/chunk-TUX6MJJ4.js.map +1 -0
- package/dist/chunk-YOKNZY2N.js +284 -0
- package/dist/chunk-YOKNZY2N.js.map +1 -0
- package/dist/consumer.d.ts +8 -0
- package/dist/consumer.js +12 -0
- package/dist/consumer.js.map +1 -0
- package/dist/errors-Bg3_rxnQ.d.ts +32 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +20 -10
- package/dist/registry.d.ts +241 -77
- package/dist/registry.js +4 -2
- package/dist/router-BncoovUh.d.ts +149 -0
- package/dist/runtime.d.ts +1 -0
- package/dist/runtime.js +4 -2
- package/dist/specs.d.ts +2 -1
- package/dist/stripe/index.d.ts +812 -0
- package/dist/stripe/index.js +866 -0
- package/dist/stripe/index.js.map +1 -0
- package/dist/tangle-catalog-runtime.d.ts +2 -1
- package/dist/tangle-catalog-runtime.js +4 -2
- package/dist/webhooks/index.d.ts +3 -148
- package/package.json +22 -10
- package/dist/chunk-ICSBYCE2.js.map +0 -1
package/dist/registry.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { C as ConnectorAdapter, R as ResolvedDataSource, d as ConnectorCredentials } from './tangle-id-CTU4kGId.js';
|
|
2
|
+
import './errors-Bg3_rxnQ.js';
|
|
2
3
|
import './connect/index.js';
|
|
3
4
|
import './middleware/index.js';
|
|
4
5
|
import './connectors/index.js';
|
|
@@ -450,6 +451,245 @@ declare class TangleIntegrationsClient {
|
|
|
450
451
|
}
|
|
451
452
|
declare function createTangleIntegrationsClient(options: TangleIntegrationsClientOptions): TangleIntegrationsClient;
|
|
452
453
|
|
|
454
|
+
type IntegrationHealthcheckStatus = 'healthy' | 'degraded' | 'unhealthy' | 'unknown';
|
|
455
|
+
interface IntegrationHealthcheckCheck {
|
|
456
|
+
id: string;
|
|
457
|
+
status: IntegrationHealthcheckStatus;
|
|
458
|
+
message: string;
|
|
459
|
+
metadata?: Record<string, unknown>;
|
|
460
|
+
}
|
|
461
|
+
interface IntegrationHealthcheckResult {
|
|
462
|
+
connectionId: string;
|
|
463
|
+
providerId: string;
|
|
464
|
+
connectorId: string;
|
|
465
|
+
status: IntegrationHealthcheckStatus;
|
|
466
|
+
checkedAt: string;
|
|
467
|
+
checks: IntegrationHealthcheckCheck[];
|
|
468
|
+
metadata?: Record<string, unknown>;
|
|
469
|
+
}
|
|
470
|
+
interface IntegrationHealthcheckStore {
|
|
471
|
+
put(result: IntegrationHealthcheckResult): Promise<void> | void;
|
|
472
|
+
get(connectionId: string): Promise<IntegrationHealthcheckResult | undefined> | IntegrationHealthcheckResult | undefined;
|
|
473
|
+
list(): Promise<IntegrationHealthcheckResult[]> | IntegrationHealthcheckResult[];
|
|
474
|
+
}
|
|
475
|
+
declare class InMemoryIntegrationHealthcheckStore implements IntegrationHealthcheckStore {
|
|
476
|
+
private readonly results;
|
|
477
|
+
put(result: IntegrationHealthcheckResult): void;
|
|
478
|
+
get(connectionId: string): IntegrationHealthcheckResult | undefined;
|
|
479
|
+
list(): IntegrationHealthcheckResult[];
|
|
480
|
+
}
|
|
481
|
+
declare function runIntegrationHealthcheck(input: {
|
|
482
|
+
connection: IntegrationConnection;
|
|
483
|
+
connector?: IntegrationConnector;
|
|
484
|
+
registry?: IntegrationRegistry;
|
|
485
|
+
test?: (connection: IntegrationConnection, connector: IntegrationConnector) => Promise<IntegrationActionResult | boolean> | IntegrationActionResult | boolean;
|
|
486
|
+
audit?: IntegrationAuditSink;
|
|
487
|
+
now?: () => Date;
|
|
488
|
+
}): Promise<IntegrationHealthcheckResult>;
|
|
489
|
+
declare function runIntegrationHealthchecks(input: {
|
|
490
|
+
connections: IntegrationConnection[];
|
|
491
|
+
registry?: IntegrationRegistry;
|
|
492
|
+
store?: IntegrationHealthcheckStore;
|
|
493
|
+
audit?: IntegrationAuditSink;
|
|
494
|
+
now?: () => Date;
|
|
495
|
+
test?: (connection: IntegrationConnection, connector: IntegrationConnector) => Promise<IntegrationActionResult | boolean> | IntegrationActionResult | boolean;
|
|
496
|
+
}): Promise<IntegrationHealthcheckResult[]>;
|
|
497
|
+
declare function healthcheckRequest(action?: string): IntegrationActionRequest;
|
|
498
|
+
|
|
499
|
+
/**
|
|
500
|
+
* @stable Integration Hub consumer client.
|
|
501
|
+
*
|
|
502
|
+
* The third client-shaped surface a product needs, alongside the two that
|
|
503
|
+
* already ship:
|
|
504
|
+
*
|
|
505
|
+
* - `createTangleIntegrationsClient` (`client.ts`) — the *invoke* client.
|
|
506
|
+
* Capability-token auth, runs INSIDE a sandbox / generated app, single
|
|
507
|
+
* endpoint `/v1/integrations/invoke`.
|
|
508
|
+
* - `startConnectFlow` / `finishConnectFlow` (`connect/index.ts`) — the
|
|
509
|
+
* *user-consent* flow, mirrors `/cross-site/*`.
|
|
510
|
+
* - **this** — the S2S *management* client. A product BACKEND (blueprint-
|
|
511
|
+
* agent, sandbox, gtm-agent, tax-agent, legal-agent, evals, …) drives the
|
|
512
|
+
* `/v1/integrations/{resolve-manifest,grants,capabilities/bundle,
|
|
513
|
+
* healthchecks/run}` management surface on `id.tangle.tools` on behalf of
|
|
514
|
+
* an identified user.
|
|
515
|
+
*
|
|
516
|
+
* Every consumer needs the identical client — the wire protocol, the
|
|
517
|
+
* `{ success, data }` envelope, the auth header shape are all platform-owned.
|
|
518
|
+
* Re-implementing a bespoke fetch loop per product forks the protocol and the
|
|
519
|
+
* copies drift. This module is that shared implementation. It mirrors the
|
|
520
|
+
* `connect/index.ts` design rule one-for-one: DO NOT invent the wire protocol
|
|
521
|
+
* — speak exactly what `products/platform/api/src/routes/integrations.ts`
|
|
522
|
+
* serves.
|
|
523
|
+
*
|
|
524
|
+
* Two auth modes — the route layer (`authMiddleware`) accepts either:
|
|
525
|
+
*
|
|
526
|
+
* - `service` — a `svc_*` service token + `X-Service-Name`. The acting
|
|
527
|
+
* user travels in `X-Platform-User-Id`. The platform honors that header
|
|
528
|
+
* only for service tokens whose `SERVICE_SCOPES` set contains
|
|
529
|
+
* `impersonate:user`; a token without it is rejected (403). Reaches the
|
|
530
|
+
* four management paths the platform allowlists for service tokens.
|
|
531
|
+
* - `user-key` — a per-user `sk-tan-*` API key (minted via the connect
|
|
532
|
+
* flow). The key identifies the user; no impersonation header. Reaches
|
|
533
|
+
* every route the user themselves can.
|
|
534
|
+
*
|
|
535
|
+
* The capability-token `invoke` endpoint is intentionally NOT exposed here —
|
|
536
|
+
* that is `createTangleIntegrationsClient`'s job and uses a different auth.
|
|
537
|
+
*/
|
|
538
|
+
|
|
539
|
+
type IntegrationHubAuth = {
|
|
540
|
+
mode: 'service';
|
|
541
|
+
/** The `svc_*` token issued to this product. */
|
|
542
|
+
serviceToken: string;
|
|
543
|
+
/** Registered service name — sent as `X-Service-Name`. Required
|
|
544
|
+
* because one token may be shared across services, in which case the
|
|
545
|
+
* platform demands the header to disambiguate. */
|
|
546
|
+
serviceName: string;
|
|
547
|
+
} | {
|
|
548
|
+
mode: 'user-key';
|
|
549
|
+
/** A per-user `sk-tan-*` key bound to the acting user. */
|
|
550
|
+
apiKey: string;
|
|
551
|
+
};
|
|
552
|
+
interface IntegrationHubClientOptions {
|
|
553
|
+
/** The product / consumer identifier (e.g. `blueprint-agent`). Sent as the
|
|
554
|
+
* `product` field of resolve-manifest calls; recorded platform-side. */
|
|
555
|
+
product: string;
|
|
556
|
+
/** Service-token or per-user-key auth. */
|
|
557
|
+
auth: IntegrationHubAuth;
|
|
558
|
+
/** Platform base URL. Defaults to `https://id.tangle.tools`. */
|
|
559
|
+
endpoint?: string;
|
|
560
|
+
/** Injected for tests. Defaults to the global `fetch`. */
|
|
561
|
+
fetchImpl?: typeof fetch;
|
|
562
|
+
/** Per-request timeout in ms. Default 10_000. */
|
|
563
|
+
timeoutMs?: number;
|
|
564
|
+
/** Max attempts on transient (network / 502 / 503 / 504) failures.
|
|
565
|
+
* Default 2 — i.e. one retry. */
|
|
566
|
+
maxAttempts?: number;
|
|
567
|
+
}
|
|
568
|
+
/** Thrown for every non-2xx response and every transport failure. Carries the
|
|
569
|
+
* HTTP status and the platform error code so callers can branch precisely
|
|
570
|
+
* (`403` + `impersonate` → the service token lacks the scope; `409` /
|
|
571
|
+
* `missing_connection` → prompt the user to connect). */
|
|
572
|
+
declare class IntegrationHubRequestError extends Error {
|
|
573
|
+
readonly name = "IntegrationHubRequestError";
|
|
574
|
+
/** HTTP status, or 0 for a network-level failure. */
|
|
575
|
+
readonly status: number;
|
|
576
|
+
/** Platform error code (`VALIDATION_ERROR`, `scope_missing`, …) or
|
|
577
|
+
* `network_error` / `http_error` when no structured code was returned. */
|
|
578
|
+
readonly code: string;
|
|
579
|
+
/** `METHOD /path` the request targeted. */
|
|
580
|
+
readonly endpoint: string;
|
|
581
|
+
/** True when the failure class is transient and a retry could succeed. */
|
|
582
|
+
readonly retryable: boolean;
|
|
583
|
+
constructor(input: {
|
|
584
|
+
status: number;
|
|
585
|
+
code: string;
|
|
586
|
+
message: string;
|
|
587
|
+
endpoint: string;
|
|
588
|
+
retryable: boolean;
|
|
589
|
+
});
|
|
590
|
+
}
|
|
591
|
+
interface ResolveManifestInput {
|
|
592
|
+
/** The acting user — the connection owner. */
|
|
593
|
+
userId: string;
|
|
594
|
+
manifest: IntegrationManifest;
|
|
595
|
+
/** Overrides the client-level `product` for this call. */
|
|
596
|
+
product?: string;
|
|
597
|
+
}
|
|
598
|
+
interface CreateGrantsInput {
|
|
599
|
+
/** The acting user — the connection owner. */
|
|
600
|
+
userId: string;
|
|
601
|
+
/** Who the grant is FOR (the sandbox / agent / app that will invoke). */
|
|
602
|
+
grantee: IntegrationActor;
|
|
603
|
+
manifest: IntegrationManifest;
|
|
604
|
+
metadata?: Record<string, unknown>;
|
|
605
|
+
}
|
|
606
|
+
interface ListGrantsInput {
|
|
607
|
+
/** The acting user — the connection owner. */
|
|
608
|
+
userId: string;
|
|
609
|
+
/** Optional grantee filter; both fields travel together as query params. */
|
|
610
|
+
grantee?: IntegrationActor;
|
|
611
|
+
}
|
|
612
|
+
interface MintCapabilityBundleInput {
|
|
613
|
+
/** The acting user — must own every connection behind the grants. */
|
|
614
|
+
userId: string;
|
|
615
|
+
/** Who the capability bundle is issued TO (the sandbox / agent process). */
|
|
616
|
+
subject: IntegrationActor;
|
|
617
|
+
/** Mint from every grant of a manifest … */
|
|
618
|
+
manifestId?: string;
|
|
619
|
+
/** … or from an explicit grant id list. Exactly one of the two is required. */
|
|
620
|
+
grantIds?: string[];
|
|
621
|
+
grantee?: IntegrationActor;
|
|
622
|
+
/** Bundle TTL in ms. Platform clamps to [1s, 60m]; default 15m. */
|
|
623
|
+
ttlMs?: number;
|
|
624
|
+
}
|
|
625
|
+
interface CapabilityBundleResult {
|
|
626
|
+
bundle: IntegrationSandboxBundle;
|
|
627
|
+
/** Bridge environment variables to inject into the sandbox process —
|
|
628
|
+
* `buildIntegrationBridgeEnvironment(bundle)`, computed platform-side. */
|
|
629
|
+
env: Record<string, string>;
|
|
630
|
+
}
|
|
631
|
+
interface CheckConnectorInput {
|
|
632
|
+
/** The acting user. */
|
|
633
|
+
userId: string;
|
|
634
|
+
/** Connector to probe — `github`, `google-calendar`, `tangle-id`, … */
|
|
635
|
+
connectorId: string;
|
|
636
|
+
/** Defaults to `read`. */
|
|
637
|
+
mode?: IntegrationRequirementMode;
|
|
638
|
+
requiredScopes?: string[];
|
|
639
|
+
requiredActions?: string[];
|
|
640
|
+
}
|
|
641
|
+
interface CheckConnectorResult {
|
|
642
|
+
/** True when the user has an active connection satisfying the requirement. */
|
|
643
|
+
connected: boolean;
|
|
644
|
+
/** The satisfying connection, present iff `connected`. */
|
|
645
|
+
connection?: IntegrationConnection;
|
|
646
|
+
/** The full requirement resolution — status, missing scopes/actions, message. */
|
|
647
|
+
resolution: IntegrationRequirementResolution;
|
|
648
|
+
}
|
|
649
|
+
/**
|
|
650
|
+
* S2S management client for the `id.tangle.tools` integration hub. One per
|
|
651
|
+
* product; methods are stateless and safe to call concurrently.
|
|
652
|
+
*/
|
|
653
|
+
declare class IntegrationHubClient {
|
|
654
|
+
private readonly endpoint;
|
|
655
|
+
private readonly product;
|
|
656
|
+
private readonly auth;
|
|
657
|
+
private readonly fetchImpl;
|
|
658
|
+
private readonly timeoutMs;
|
|
659
|
+
private readonly maxAttempts;
|
|
660
|
+
constructor(options: IntegrationHubClientOptions);
|
|
661
|
+
/**
|
|
662
|
+
* Resolve a manifest against a user's connections. The returned
|
|
663
|
+
* `ready` / `missing` split is the canonical way to ask "does this user
|
|
664
|
+
* have the connections this work needs" — the raw connection list is not
|
|
665
|
+
* reachable by a service token by design.
|
|
666
|
+
*/
|
|
667
|
+
resolveManifest(input: ResolveManifestInput): Promise<IntegrationManifestResolution>;
|
|
668
|
+
/**
|
|
669
|
+
* Convenience over {@link resolveManifest} — probe a single connector and
|
|
670
|
+
* get back a boolean plus the satisfying connection. The Surface-A quest
|
|
671
|
+
* primitive ("is the user's GitHub linked?").
|
|
672
|
+
*/
|
|
673
|
+
checkConnector(input: CheckConnectorInput): Promise<CheckConnectorResult>;
|
|
674
|
+
/** Create grants for every satisfiable requirement of a manifest. The
|
|
675
|
+
* platform rejects the call if any non-optional requirement is missing a
|
|
676
|
+
* connection. */
|
|
677
|
+
createGrants(input: CreateGrantsInput): Promise<IntegrationGrant[]>;
|
|
678
|
+
/** List the acting user's grants, optionally filtered to one grantee. */
|
|
679
|
+
listGrants(input: ListGrantsInput): Promise<IntegrationGrant[]>;
|
|
680
|
+
/** Mint a short-lived capability bundle for a sandbox / agent process.
|
|
681
|
+
* Provider credentials never leave the platform — the bundle carries only
|
|
682
|
+
* scoped, expiring capability tokens. */
|
|
683
|
+
mintCapabilityBundle(input: MintCapabilityBundleInput): Promise<CapabilityBundleResult>;
|
|
684
|
+
/** Run live healthchecks across all of the acting user's connections. */
|
|
685
|
+
runHealthchecks(input: {
|
|
686
|
+
userId: string;
|
|
687
|
+
}): Promise<IntegrationHealthcheckResult[]>;
|
|
688
|
+
private buildHeaders;
|
|
689
|
+
private request;
|
|
690
|
+
}
|
|
691
|
+
declare function createIntegrationHubClient(options: IntegrationHubClientOptions): IntegrationHubClient;
|
|
692
|
+
|
|
453
693
|
interface ConsentSummary {
|
|
454
694
|
title: string;
|
|
455
695
|
body: string;
|
|
@@ -675,37 +915,6 @@ declare function filterDiscoveryByWorkspaceScopes(discovery: WorkspaceCapability
|
|
|
675
915
|
denyByDefault?: boolean;
|
|
676
916
|
}): WorkspaceCapabilityDiscovery;
|
|
677
917
|
|
|
678
|
-
type IntegrationErrorCode = 'missing_connection' | 'missing_grant' | 'approval_required' | 'approval_denied' | 'connection_revoked' | 'connection_expired' | 'scope_missing' | 'action_denied' | 'action_not_found' | 'trigger_not_found' | 'provider_rate_limited' | 'provider_auth_failed' | 'provider_unavailable' | 'provider_error' | 'capability_expired' | 'capability_invalid' | 'manifest_invalid' | 'passthrough_disabled' | 'input_invalid' | 'unknown';
|
|
679
|
-
interface IntegrationUserAction {
|
|
680
|
-
type: 'connect' | 'reconnect' | 'approve' | 'retry' | 'contact_support' | 'change_request';
|
|
681
|
-
label: string;
|
|
682
|
-
connectorId?: string;
|
|
683
|
-
approvalId?: string;
|
|
684
|
-
}
|
|
685
|
-
declare class IntegrationRuntimeError extends Error {
|
|
686
|
-
readonly code: IntegrationErrorCode;
|
|
687
|
-
readonly status: number;
|
|
688
|
-
readonly userAction?: IntegrationUserAction;
|
|
689
|
-
readonly metadata?: Record<string, unknown>;
|
|
690
|
-
constructor(input: {
|
|
691
|
-
code: IntegrationErrorCode;
|
|
692
|
-
message: string;
|
|
693
|
-
status?: number;
|
|
694
|
-
userAction?: IntegrationUserAction;
|
|
695
|
-
metadata?: Record<string, unknown>;
|
|
696
|
-
});
|
|
697
|
-
}
|
|
698
|
-
interface NormalizedIntegrationError {
|
|
699
|
-
ok: false;
|
|
700
|
-
code: IntegrationErrorCode;
|
|
701
|
-
message: string;
|
|
702
|
-
status: number;
|
|
703
|
-
userAction?: IntegrationUserAction;
|
|
704
|
-
metadata?: Record<string, unknown>;
|
|
705
|
-
}
|
|
706
|
-
declare function normalizeIntegrationError(error: unknown): NormalizedIntegrationError;
|
|
707
|
-
declare function statusForCode(code: IntegrationErrorCode): number;
|
|
708
|
-
|
|
709
918
|
interface IntegrationWorkflowDefinition {
|
|
710
919
|
id: string;
|
|
711
920
|
title?: string;
|
|
@@ -858,51 +1067,6 @@ declare class DefaultIntegrationActionGuard implements IntegrationActionGuard {
|
|
|
858
1067
|
}
|
|
859
1068
|
declare function createDefaultIntegrationActionGuard(options?: ConstructorParameters<typeof DefaultIntegrationActionGuard>[0]): DefaultIntegrationActionGuard;
|
|
860
1069
|
|
|
861
|
-
type IntegrationHealthcheckStatus = 'healthy' | 'degraded' | 'unhealthy' | 'unknown';
|
|
862
|
-
interface IntegrationHealthcheckCheck {
|
|
863
|
-
id: string;
|
|
864
|
-
status: IntegrationHealthcheckStatus;
|
|
865
|
-
message: string;
|
|
866
|
-
metadata?: Record<string, unknown>;
|
|
867
|
-
}
|
|
868
|
-
interface IntegrationHealthcheckResult {
|
|
869
|
-
connectionId: string;
|
|
870
|
-
providerId: string;
|
|
871
|
-
connectorId: string;
|
|
872
|
-
status: IntegrationHealthcheckStatus;
|
|
873
|
-
checkedAt: string;
|
|
874
|
-
checks: IntegrationHealthcheckCheck[];
|
|
875
|
-
metadata?: Record<string, unknown>;
|
|
876
|
-
}
|
|
877
|
-
interface IntegrationHealthcheckStore {
|
|
878
|
-
put(result: IntegrationHealthcheckResult): Promise<void> | void;
|
|
879
|
-
get(connectionId: string): Promise<IntegrationHealthcheckResult | undefined> | IntegrationHealthcheckResult | undefined;
|
|
880
|
-
list(): Promise<IntegrationHealthcheckResult[]> | IntegrationHealthcheckResult[];
|
|
881
|
-
}
|
|
882
|
-
declare class InMemoryIntegrationHealthcheckStore implements IntegrationHealthcheckStore {
|
|
883
|
-
private readonly results;
|
|
884
|
-
put(result: IntegrationHealthcheckResult): void;
|
|
885
|
-
get(connectionId: string): IntegrationHealthcheckResult | undefined;
|
|
886
|
-
list(): IntegrationHealthcheckResult[];
|
|
887
|
-
}
|
|
888
|
-
declare function runIntegrationHealthcheck(input: {
|
|
889
|
-
connection: IntegrationConnection;
|
|
890
|
-
connector?: IntegrationConnector;
|
|
891
|
-
registry?: IntegrationRegistry;
|
|
892
|
-
test?: (connection: IntegrationConnection, connector: IntegrationConnector) => Promise<IntegrationActionResult | boolean> | IntegrationActionResult | boolean;
|
|
893
|
-
audit?: IntegrationAuditSink;
|
|
894
|
-
now?: () => Date;
|
|
895
|
-
}): Promise<IntegrationHealthcheckResult>;
|
|
896
|
-
declare function runIntegrationHealthchecks(input: {
|
|
897
|
-
connections: IntegrationConnection[];
|
|
898
|
-
registry?: IntegrationRegistry;
|
|
899
|
-
store?: IntegrationHealthcheckStore;
|
|
900
|
-
audit?: IntegrationAuditSink;
|
|
901
|
-
now?: () => Date;
|
|
902
|
-
test?: (connection: IntegrationConnection, connector: IntegrationConnector) => Promise<IntegrationActionResult | boolean> | IntegrationActionResult | boolean;
|
|
903
|
-
}): Promise<IntegrationHealthcheckResult[]>;
|
|
904
|
-
declare function healthcheckRequest(action?: string): IntegrationActionRequest;
|
|
905
|
-
|
|
906
1070
|
interface ManifestValidationIssue {
|
|
907
1071
|
path: string;
|
|
908
1072
|
message: string;
|
|
@@ -2162,4 +2326,4 @@ declare function createHttpIntegrationProvider(options: HttpIntegrationProviderO
|
|
|
2162
2326
|
declare function signCapability(capability: IntegrationCapability, secret: string): string;
|
|
2163
2327
|
declare function verifyCapabilityToken(token: string, secret: string): IntegrationCapability;
|
|
2164
2328
|
|
|
2165
|
-
export { type HealthcheckSpec as $, type TangleCatalogHttpAuthResolverRequest as A, type TangleCatalogInstalledPackageExecutorOptions as B, type TangleCatalogRuntimeHandlerOptions as C, type ComposeIntegrationRegistryOptions, type TangleCatalogRuntimeHttpRequest as D, type TangleCatalogRuntimeHttpResponse as E, type TangleCatalogRuntimeInvocation as F, type TangleCatalogRuntimeModuleAction as G, type TangleCatalogRuntimePackageCoverageOptions as H, type IntegrationCatalogView as I, type IntegrationCatalogSource, type IntegrationRegistry, type IntegrationRegistryConflict, type IntegrationRegistryEntry, type IntegrationRegistrySourceRef, type IntegrationRegistrySummary, type IntegrationSupportTier, type TangleCatalogRuntimePackageCoverageRow as J, auditTangleCatalogRuntimePackages as K, createTangleCatalogCredentialAuthResolver as L, type McpToolDefinition as M, createTangleCatalogHttpAuthResolver as N, createTangleCatalogInstalledPackageExecutor as O, createTangleCatalogRuntimeHandler as P, signTangleCatalogRuntimeRequest as Q, tangleCatalogAuthValue as R, verifyTangleCatalogRuntimeSignature as S, TANGLE_CATALOG_RUNTIME_SIGNATURE_HEADER as T, type ApiKeyAuthSpec as U, type ConsoleStep as V, type CredentialFieldSpec as W, type CredentialValidationInput as X, type CredentialValidationResult as Y, type CustomAuthSpec as Z, type HealthcheckPlan as _, type IntegrationToolDefinition as a, type GatewayCatalogProviderOptions as a$, type HmacAuthSpec as a0, INTEGRATION_FAMILIES as a1, type IntegrationAuthMode as a2, type IntegrationAuthSpec as a3, type IntegrationFamilyId as a4, type IntegrationFamilySpec as a5, type IntegrationLifecycleSpec as a6, type IntegrationPlannerHints as a7, type IntegrationSetupSpec as a8, type IntegrationSpec as a9, validateIntegrationSpec as aA, ACTIVEPIECES_OVERRIDES as aB, ACTIVEPIECES_PUBLIC_CATALOG_URL as aC, ACTIVEPIECES_RUNTIME_SIGNATURE_HEADER as aD, type ActivepiecesCatalogAuthField as aE, type ActivepiecesCatalogEntry as aF, type ActivepiecesExecutorInvocation as aG, type ActivepiecesExecutorProviderOptions as aH, type ActivepiecesHttpExecutorOptions as aI, type ActivepiecesPieceOverride as aJ, type ActivepiecesRuntimeRequest as aK, ApprovalBackedPolicyEngine as aL, type ApprovalBackedPolicyOptions as aM, CANONICAL_INTEGRATION_ACTIONS as aN, type CanonicalIntegrationActionId as aO, type CanonicalLaunchConnectorOptions as aP, type CatalogExecutorInvocation as aQ, type CatalogExecutorProviderOptions as aR, type CompleteAuthRequest as aS, type ConnectionCredentialResolverOptions as aT, type ConnectorAdapterProviderOptions as aU, type ConsentSummary as aV, DEFAULT_INTEGRATION_BRIDGE_ENV as aW, DefaultIntegrationActionGuard as aX, type DiscoverWorkspaceCapabilitiesInput as aY, type GatewayCatalogAction as aZ, type GatewayCatalogEntry as a_, type IntegrationSpecStatus as aa, type IntegrationSpecValidationIssue as ab, type IntegrationSpecValidationResult as ac, type NoneAuthSpec as ad, type NormalizedPermission as ae, type OAuth2AuthSpec as af, type PermissionDescriptor as ag, type PostSetupCheck as ah, type Quirk as ai, type RenderSpecOptions as aj, type RenderedConsoleStep as ak, type ScopeDescriptor as al, assertValidIntegrationSpec as am, buildHealthcheckPlan as an, consoleStepsToText as ao, getIntegrationFamily as ap, getIntegrationSpec as aq, integrationSpecToConnector as ar, listExecutableIntegrationSpecs as as, listIntegrationSpecs as at, renderAgentToolDescription as au, renderConsoleSteps as av, renderRunbookMarkdown as aw, specAuthToConnectorAuth as ax, validateCredentialFormat as ay, validateCredentialSet as az, type IntegrationToolSearchFilters as b, type IntegrationProvider as b$, type GatewayCatalogTrigger as b0, type GraphqlOperationSpec as b1, type HttpIntegrationProviderOptions as b2, type ImportCatalogOptions as b3, InMemoryConnectionStore as b4, InMemoryIntegrationApprovalStore as b5, InMemoryIntegrationAuditStore as b6, InMemoryIntegrationEventStore as b7, InMemoryIntegrationHealthcheckStore as b8, InMemoryIntegrationIdempotencyStore as b9, type IntegrationConnection as bA, type IntegrationConnectionStore as bB, type IntegrationConnector as bC, type IntegrationConnectorAction as bD, type IntegrationConnectorCategory as bE, type IntegrationConnectorTrigger as bF, type IntegrationCoveragePriority as bG, type IntegrationCoverageSpec as bH, type IntegrationDataClass as bI, IntegrationError as bJ, type IntegrationErrorCode as bK, type IntegrationEventStore as bL, type IntegrationGuardContext as bM, type IntegrationHealthcheckCheck as bN, type IntegrationHealthcheckResult as bO, type IntegrationHealthcheckStatus as bP, type IntegrationHealthcheckStore as bQ, IntegrationHub as bR, type IntegrationHubOptions as bS, type IntegrationIdempotencyRecord as bT, type IntegrationIdempotencyStore as bU, type IntegrationInvocationEnvelope as bV, type IntegrationInvocationEnvelopeValidationOptions as bW, type IntegrationPolicyDecision as bX, type IntegrationPolicyEffect as bY, type IntegrationPolicyEngine as bZ, type IntegrationPolicyRule as b_, InMemoryIntegrationSecretStore as ba, InMemoryIntegrationWorkflowStore as bb, type InferIntegrationRequirementsOptions as bc, type InstalledIntegrationWorkflow as bd, type IntegrationActionGuard as be, type IntegrationActionPack as bf, type IntegrationActionRequest as bg, type IntegrationActionResult as bh, type IntegrationActionRisk as bi, type IntegrationActor as bj, type IntegrationApprovalFilter as bk, type IntegrationApprovalRecord as bl, type IntegrationApprovalRequest as bm, type IntegrationApprovalResolution as bn, type IntegrationApprovalStatus as bo, type IntegrationApprovalStore as bp, type IntegrationAuditEvent as bq, type IntegrationAuditEventType as br, type IntegrationAuditFilter as bs, type IntegrationAuditSink as bt, type IntegrationAuditStore as bu, buildDefaultIntegrationRegistry, type IntegrationBridgePayload as bv, type IntegrationBridgeToolBinding as bw, type IntegrationCapability as bx, type IntegrationCatalogFreshnessOptions as by, type IntegrationCatalogFreshnessResult as bz, type IntegrationToolSearchResult as c, type TangleIntegrationsClientOptions as c$, type IntegrationProviderKind as c0, type IntegrationRateLimitDecision as c1, type IntegrationRateLimiter as c2, IntegrationRuntimeError as c3, IntegrationSandboxHost as c4, type IntegrationSandboxHostHub as c5, type IntegrationSandboxHostOptions as c6, type IntegrationSecretStore as c7, type IntegrationTriggerEvent as c8, type IntegrationTriggerSubscription as c9, type StartAuthResult as cA, type StartedTangleCatalogRuntimeNodeServer as cB, StaticIntegrationPolicyEngine as cC, type StaticIntegrationPolicyOptions as cD, type StoredIntegrationEvent as cE, TANGLE_INTEGRATIONS_CATALOG_PROVIDER_ID as cF, TANGLE_INTEGRATIONS_CATALOG_SOURCE as cG, type TangleCatalogExecutorInvocation as cH, type TangleCatalogExecutorProviderOptions as cI, type TangleCatalogHttpExecutorInvocation as cJ, type TangleCatalogHttpExecutorOptions as cK, type TangleCatalogRuntimeActionRequest as cL, type TangleCatalogRuntimeNodeServerOptions as cM, type TangleCatalogRuntimePackageManifest as cN, type TangleCatalogRuntimePackageManifestOptions as cO, type TangleCatalogRuntimePiece as cP, type TangleCatalogRuntimeRequest as cQ, type TangleCatalogTriggerInvocation as cR, type TangleIntegrationCatalogEntry as cS, type TangleIntegrationCatalogFreshnessOptions as cT, type TangleIntegrationCatalogFreshnessResult as cU, type TangleIntegrationContract as cV, type TangleIntegrationContractStatus as cW, type TangleIntegrationImplementationKind as cX, type TangleIntegrationInvokeInput as cY, type TangleIntegrationInvokeResult as cZ, TangleIntegrationsClient as c_, type IntegrationUserAction as ca, canonicalConnectorId, type IntegrationWebhookReceiverResult as cb, type IntegrationWorkflowDefinition as cc, IntegrationWorkflowRuntime as cd, type IntegrationWorkflowRuntimeHub as ce, type IntegrationWorkflowRuntimeOptions as cf, type IntegrationWorkflowStore as cg, type InvokeWithCapabilityRequest as ch, type IssueCapabilityRequest as ci, type IssuedIntegrationCapability as cj, type ManifestValidationIssue as ck, type ManifestValidationResult as cl, type McpCatalog as cm, type McpCatalogTool as cn, type MissingRequirementExplanation as co, composeIntegrationRegistry, type NormalizedIntegrationError as cp, type NormalizedIntegrationResult as cq, type OpenApiDocument as cr, type OpenApiOperation as cs, PROVIDER_PASSTHROUGH_ACTION as ct, type PlatformIntegrationPolicyPresetOptions as cu, type ProviderHttpRequestInput as cv, type ProviderPassthroughPolicy as cw, type RenderConsentOptions as cx, type SecretRef as cy, type StartAuthRequest as cz, buildIntegrationCatalogView as d, listTangleIntegrationContracts as d$, type WorkspaceCapability as d0, type WorkspaceCapabilityDiscovery as d1, type WorkspaceToolSchema as d2, type WorkspaceTrigger as d3, adapterManifestsToConnectors as d4, assertValidIntegrationManifest as d5, auditIntegrationCatalogFreshness as d6, auditTangleIntegrationCatalogFreshness as d7, buildActivepiecesConnectors as d8, buildActivepiecesRuntimeRequest as d9, createIntegrationWorkflowRuntime as dA, createMockIntegrationProvider as dB, createPlatformIntegrationPolicyPreset as dC, createTangleCatalogExecutorProvider as dD, createTangleCatalogHttpExecutor as dE, createTangleCatalogRuntimeNodeRequestListener as dF, createTangleIntegrationsClient as dG, decodeIntegrationBridgePayload as dH, discoverWorkspaceCapabilities as dI, dispatchIntegrationInvocation as dJ, encodeIntegrationBridgePayload as dK, explainMissingRequirements as dL, extractActivepiecesPublicPieceCount as dM, extractExternalCatalogPublicCount as dN, filterDiscoveryByWorkspaceScopes as dO, getActivepiecesOverride as dP, healthcheckRequest as dQ, importGraphqlConnector as dR, importMcpConnector as dS, importOpenApiConnector as dT, inferIntegrationManifestFromTools as dU, integrationCoverageChecklistMarkdown as dV, invocationRequestFromEnvelope as dW, listActivepiecesCatalogEntries as dX, listIntegrationCoverageSpecs as dY, listTangleIntegrationCatalogEntries as dZ, listTangleIntegrationCatalogRuntimePackages as d_, buildApprovalRequest as da, buildCanonicalLaunchConnectors as db, buildIntegrationBridgeEnvironment as dc, buildIntegrationBridgePayload as dd, buildIntegrationCoverageConnectors as de, buildIntegrationInvocationEnvelope as df, buildTangleCatalogRuntimePackageManifest as dg, buildTangleCatalogRuntimeRequest as dh, buildTangleIntegrationCatalogConnectors as di, calendarExercisePlannerManifest as dj, canonicalActionConnectorId as dk, createActivepiecesExecutorProvider as dl, createActivepiecesHttpExecutor as dm, createApprovalBackedPolicyEngine as dn, createAuditingActionGuard as dp, createCatalogExecutorProvider as dq, createConnectionCredentialResolver as dr, createConnectorAdapterCatalogSource as ds, createConnectorAdapterProvider as dt, createCredentialBackedAdapterProvider as du, createDefaultIntegrationActionGuard as dv, createDefaultIntegrationPolicyEngine as dw, createGatewayCatalogProvider as dx, createHttpIntegrationProvider as dy, createIntegrationAuditEvent as dz, buildIntegrationToolCatalog as e, manifestToConnector as e0, normalizeGatewayCatalog as e1, normalizeIntegrationError as e2, normalizeIntegrationResult as e3, parseIntegrationBridgeEnvironment as e4, receiveIntegrationWebhook as e5, redactApprovalRequest as e6, redactCapability as e7, redactIntegrationBridgePayload as e8, redactInvocationEnvelope as e9, renderApprovalCopy as ea, renderConsentSummary as eb, renderTangleCatalogRuntimePnpmAddCommand as ec, resolveConnectionCredentials as ed, resolveIntegrationApproval as ee, revokeConnection as ef, runIntegrationHealthcheck as eg, runIntegrationHealthchecks as eh, sanitizeAuditConnection as ei, sanitizeConnection as ej, signActivepiecesRuntimeRequest as ek, signCapability as el, startTangleCatalogRuntimeNodeServer as em, statusForCode as en, storedEventToTriggerEvent as eo, validateIntegrationInvocationEnvelope as ep, validateIntegrationManifest as eq, validateProviderPassthroughRequest as er, verifyActivepiecesRuntimeSignature as es, verifyCapabilityToken as et, InMemoryIntegrationGrantStore as f, type IntegrationCapabilityBinding as g, type IntegrationGrant as h, integrationToolName as i, inferIntegrationSupportTier, type IntegrationGrantStore as j, type IntegrationManifest as k, type IntegrationManifestResolution as l, type IntegrationRequirement as m, type IntegrationRequirementMode as n, type IntegrationRequirementResolution as o, parseIntegrationToolName as p, type IntegrationRequirementStatus as q, IntegrationRuntime as r, searchIntegrationTools as s, summarizeIntegrationRegistry, toMcpTools as t, type IntegrationRuntimeHub as u, type IntegrationRuntimeOptions as v, type IntegrationSandboxBundle as w, createIntegrationRuntime as x, type TangleCatalogAuthResolverOptions as y, type TangleCatalogHttpAuthResolverOptions as z };
|
|
2329
|
+
export { createTangleCatalogInstalledPackageExecutor as $, type CreateGrantsInput as A, type IntegrationHubAuth as B, type CapabilityBundleResult as C, type ComposeIntegrationRegistryOptions, IntegrationHubClient as D, type IntegrationHubClientOptions as E, IntegrationHubRequestError as F, type MintCapabilityBundleInput as G, createIntegrationHubClient as H, type IntegrationCatalogView as I, type IntegrationCatalogSource, type IntegrationRegistry, type IntegrationRegistryConflict, type IntegrationRegistryEntry, type IntegrationRegistrySourceRef, type IntegrationRegistrySummary, type IntegrationSupportTier, type TangleCatalogAuthResolverOptions as J, type TangleCatalogHttpAuthResolverOptions as K, type ListGrantsInput as L, type McpToolDefinition as M, type TangleCatalogHttpAuthResolverRequest as N, type TangleCatalogInstalledPackageExecutorOptions as O, type TangleCatalogRuntimeHandlerOptions as P, type TangleCatalogRuntimeHttpRequest as Q, type ResolveManifestInput as R, type TangleCatalogRuntimeHttpResponse as S, TANGLE_CATALOG_RUNTIME_SIGNATURE_HEADER as T, type TangleCatalogRuntimeInvocation as U, type TangleCatalogRuntimeModuleAction as V, type TangleCatalogRuntimePackageCoverageOptions as W, type TangleCatalogRuntimePackageCoverageRow as X, auditTangleCatalogRuntimePackages as Y, createTangleCatalogCredentialAuthResolver as Z, createTangleCatalogHttpAuthResolver as _, type IntegrationToolDefinition as a, type CanonicalLaunchConnectorOptions as a$, createTangleCatalogRuntimeHandler as a0, signTangleCatalogRuntimeRequest as a1, tangleCatalogAuthValue as a2, verifyTangleCatalogRuntimeSignature as a3, type ApiKeyAuthSpec as a4, type ConsoleStep as a5, type CredentialFieldSpec as a6, type CredentialValidationInput as a7, type CredentialValidationResult as a8, type CustomAuthSpec as a9, consoleStepsToText as aA, getIntegrationFamily as aB, getIntegrationSpec as aC, integrationSpecToConnector as aD, listExecutableIntegrationSpecs as aE, listIntegrationSpecs as aF, renderAgentToolDescription as aG, renderConsoleSteps as aH, renderRunbookMarkdown as aI, specAuthToConnectorAuth as aJ, validateCredentialFormat as aK, validateCredentialSet as aL, validateIntegrationSpec as aM, ACTIVEPIECES_OVERRIDES as aN, ACTIVEPIECES_PUBLIC_CATALOG_URL as aO, ACTIVEPIECES_RUNTIME_SIGNATURE_HEADER as aP, type ActivepiecesCatalogAuthField as aQ, type ActivepiecesCatalogEntry as aR, type ActivepiecesExecutorInvocation as aS, type ActivepiecesExecutorProviderOptions as aT, type ActivepiecesHttpExecutorOptions as aU, type ActivepiecesPieceOverride as aV, type ActivepiecesRuntimeRequest as aW, ApprovalBackedPolicyEngine as aX, type ApprovalBackedPolicyOptions as aY, CANONICAL_INTEGRATION_ACTIONS as aZ, type CanonicalIntegrationActionId as a_, type HealthcheckPlan as aa, type HealthcheckSpec as ab, type HmacAuthSpec as ac, INTEGRATION_FAMILIES as ad, type IntegrationAuthMode as ae, type IntegrationAuthSpec as af, type IntegrationFamilyId as ag, type IntegrationFamilySpec as ah, type IntegrationLifecycleSpec as ai, type IntegrationPlannerHints as aj, type IntegrationSetupSpec as ak, type IntegrationSpec as al, type IntegrationSpecStatus as am, type IntegrationSpecValidationIssue as an, type IntegrationSpecValidationResult as ao, type NoneAuthSpec as ap, type NormalizedPermission as aq, type OAuth2AuthSpec as ar, type PermissionDescriptor as as, type PostSetupCheck as at, type Quirk as au, type RenderSpecOptions as av, type RenderedConsoleStep as aw, type ScopeDescriptor as ax, assertValidIntegrationSpec as ay, buildHealthcheckPlan as az, type IntegrationToolSearchFilters as b, type IntegrationHealthcheckStore as b$, type CatalogExecutorInvocation as b0, type CatalogExecutorProviderOptions as b1, type CompleteAuthRequest as b2, type ConnectionCredentialResolverOptions as b3, type ConnectorAdapterProviderOptions as b4, type ConsentSummary as b5, DEFAULT_INTEGRATION_BRIDGE_ENV as b6, DefaultIntegrationActionGuard as b7, type DiscoverWorkspaceCapabilitiesInput as b8, type GatewayCatalogAction as b9, type IntegrationApprovalStatus as bA, type IntegrationApprovalStore as bB, type IntegrationAuditEvent as bC, type IntegrationAuditEventType as bD, type IntegrationAuditFilter as bE, type IntegrationAuditSink as bF, type IntegrationAuditStore as bG, type IntegrationBridgePayload as bH, type IntegrationBridgeToolBinding as bI, type IntegrationCapability as bJ, type IntegrationCatalogFreshnessOptions as bK, type IntegrationCatalogFreshnessResult as bL, type IntegrationConnection as bM, type IntegrationConnectionStore as bN, type IntegrationConnector as bO, type IntegrationConnectorAction as bP, type IntegrationConnectorCategory as bQ, type IntegrationConnectorTrigger as bR, type IntegrationCoveragePriority as bS, type IntegrationCoverageSpec as bT, type IntegrationDataClass as bU, IntegrationError as bV, type IntegrationEventStore as bW, type IntegrationGuardContext as bX, type IntegrationHealthcheckCheck as bY, type IntegrationHealthcheckResult as bZ, type IntegrationHealthcheckStatus as b_, type GatewayCatalogEntry as ba, type GatewayCatalogProviderOptions as bb, type GatewayCatalogTrigger as bc, type GraphqlOperationSpec as bd, type HttpIntegrationProviderOptions as be, type ImportCatalogOptions as bf, InMemoryConnectionStore as bg, InMemoryIntegrationApprovalStore as bh, InMemoryIntegrationAuditStore as bi, InMemoryIntegrationEventStore as bj, InMemoryIntegrationHealthcheckStore as bk, InMemoryIntegrationIdempotencyStore as bl, InMemoryIntegrationSecretStore as bm, InMemoryIntegrationWorkflowStore as bn, type InferIntegrationRequirementsOptions as bo, type InstalledIntegrationWorkflow as bp, type IntegrationActionGuard as bq, type IntegrationActionPack as br, type IntegrationActionRequest as bs, type IntegrationActionResult as bt, type IntegrationActionRisk as bu, buildDefaultIntegrationRegistry, type IntegrationActor as bv, type IntegrationApprovalFilter as bw, type IntegrationApprovalRecord as bx, type IntegrationApprovalRequest as by, type IntegrationApprovalResolution as bz, type IntegrationToolSearchResult as c, type TangleIntegrationCatalogFreshnessOptions as c$, IntegrationHub as c0, type IntegrationHubOptions as c1, type IntegrationIdempotencyRecord as c2, type IntegrationIdempotencyStore as c3, type IntegrationInvocationEnvelope as c4, type IntegrationInvocationEnvelopeValidationOptions as c5, type IntegrationPolicyDecision as c6, type IntegrationPolicyEffect as c7, type IntegrationPolicyEngine as c8, type IntegrationPolicyRule as c9, type OpenApiOperation as cA, PROVIDER_PASSTHROUGH_ACTION as cB, type PlatformIntegrationPolicyPresetOptions as cC, type ProviderHttpRequestInput as cD, type ProviderPassthroughPolicy as cE, type RenderConsentOptions as cF, type SecretRef as cG, type StartAuthRequest as cH, type StartAuthResult as cI, type StartedTangleCatalogRuntimeNodeServer as cJ, StaticIntegrationPolicyEngine as cK, type StaticIntegrationPolicyOptions as cL, type StoredIntegrationEvent as cM, TANGLE_INTEGRATIONS_CATALOG_PROVIDER_ID as cN, TANGLE_INTEGRATIONS_CATALOG_SOURCE as cO, type TangleCatalogExecutorInvocation as cP, type TangleCatalogExecutorProviderOptions as cQ, type TangleCatalogHttpExecutorInvocation as cR, type TangleCatalogHttpExecutorOptions as cS, type TangleCatalogRuntimeActionRequest as cT, type TangleCatalogRuntimeNodeServerOptions as cU, type TangleCatalogRuntimePackageManifest as cV, type TangleCatalogRuntimePackageManifestOptions as cW, type TangleCatalogRuntimePiece as cX, type TangleCatalogRuntimeRequest as cY, type TangleCatalogTriggerInvocation as cZ, type TangleIntegrationCatalogEntry as c_, type IntegrationProvider as ca, canonicalConnectorId, type IntegrationProviderKind as cb, type IntegrationRateLimitDecision as cc, type IntegrationRateLimiter as cd, IntegrationSandboxHost as ce, type IntegrationSandboxHostHub as cf, type IntegrationSandboxHostOptions as cg, type IntegrationSecretStore as ch, type IntegrationTriggerEvent as ci, type IntegrationTriggerSubscription as cj, type IntegrationWebhookReceiverResult as ck, type IntegrationWorkflowDefinition as cl, IntegrationWorkflowRuntime as cm, type IntegrationWorkflowRuntimeHub as cn, type IntegrationWorkflowRuntimeOptions as co, composeIntegrationRegistry, type IntegrationWorkflowStore as cp, type InvokeWithCapabilityRequest as cq, type IssueCapabilityRequest as cr, type IssuedIntegrationCapability as cs, type ManifestValidationIssue as ct, type ManifestValidationResult as cu, type McpCatalog as cv, type McpCatalogTool as cw, type MissingRequirementExplanation as cx, type NormalizedIntegrationResult as cy, type OpenApiDocument as cz, buildIntegrationCatalogView as d, importOpenApiConnector as d$, type TangleIntegrationCatalogFreshnessResult as d0, type TangleIntegrationContract as d1, type TangleIntegrationContractStatus as d2, type TangleIntegrationImplementationKind as d3, type TangleIntegrationInvokeInput as d4, type TangleIntegrationInvokeResult as d5, TangleIntegrationsClient as d6, type TangleIntegrationsClientOptions as d7, type WorkspaceCapability as d8, type WorkspaceCapabilityDiscovery as d9, createConnectorAdapterCatalogSource as dA, createConnectorAdapterProvider as dB, createCredentialBackedAdapterProvider as dC, createDefaultIntegrationActionGuard as dD, createDefaultIntegrationPolicyEngine as dE, createGatewayCatalogProvider as dF, createHttpIntegrationProvider as dG, createIntegrationAuditEvent as dH, createIntegrationWorkflowRuntime as dI, createMockIntegrationProvider as dJ, createPlatformIntegrationPolicyPreset as dK, createTangleCatalogExecutorProvider as dL, createTangleCatalogHttpExecutor as dM, createTangleCatalogRuntimeNodeRequestListener as dN, createTangleIntegrationsClient as dO, decodeIntegrationBridgePayload as dP, discoverWorkspaceCapabilities as dQ, dispatchIntegrationInvocation as dR, encodeIntegrationBridgePayload as dS, explainMissingRequirements as dT, extractActivepiecesPublicPieceCount as dU, extractExternalCatalogPublicCount as dV, filterDiscoveryByWorkspaceScopes as dW, getActivepiecesOverride as dX, healthcheckRequest as dY, importGraphqlConnector as dZ, importMcpConnector as d_, type WorkspaceToolSchema as da, type WorkspaceTrigger as db, adapterManifestsToConnectors as dc, assertValidIntegrationManifest as dd, auditIntegrationCatalogFreshness as de, auditTangleIntegrationCatalogFreshness as df, buildActivepiecesConnectors as dg, buildActivepiecesRuntimeRequest as dh, buildApprovalRequest as di, buildCanonicalLaunchConnectors as dj, buildIntegrationBridgeEnvironment as dk, buildIntegrationBridgePayload as dl, buildIntegrationCoverageConnectors as dm, buildIntegrationInvocationEnvelope as dn, buildTangleCatalogRuntimePackageManifest as dp, buildTangleCatalogRuntimeRequest as dq, buildTangleIntegrationCatalogConnectors as dr, calendarExercisePlannerManifest as ds, canonicalActionConnectorId as dt, createActivepiecesExecutorProvider as du, createActivepiecesHttpExecutor as dv, createApprovalBackedPolicyEngine as dw, createAuditingActionGuard as dx, createCatalogExecutorProvider as dy, createConnectionCredentialResolver as dz, buildIntegrationToolCatalog as e, inferIntegrationManifestFromTools as e0, integrationCoverageChecklistMarkdown as e1, invocationRequestFromEnvelope as e2, listActivepiecesCatalogEntries as e3, listIntegrationCoverageSpecs as e4, listTangleIntegrationCatalogEntries as e5, listTangleIntegrationCatalogRuntimePackages as e6, listTangleIntegrationContracts as e7, manifestToConnector as e8, normalizeGatewayCatalog as e9, normalizeIntegrationResult as ea, parseIntegrationBridgeEnvironment as eb, receiveIntegrationWebhook as ec, redactApprovalRequest as ed, redactCapability as ee, redactIntegrationBridgePayload as ef, redactInvocationEnvelope as eg, renderApprovalCopy as eh, renderConsentSummary as ei, renderTangleCatalogRuntimePnpmAddCommand as ej, resolveConnectionCredentials as ek, resolveIntegrationApproval as el, revokeConnection as em, runIntegrationHealthcheck as en, runIntegrationHealthchecks as eo, sanitizeAuditConnection as ep, sanitizeConnection as eq, signActivepiecesRuntimeRequest as er, signCapability as es, startTangleCatalogRuntimeNodeServer as et, storedEventToTriggerEvent as eu, validateIntegrationInvocationEnvelope as ev, validateIntegrationManifest as ew, validateProviderPassthroughRequest as ex, verifyActivepiecesRuntimeSignature as ey, verifyCapabilityToken as ez, InMemoryIntegrationGrantStore as f, type IntegrationCapabilityBinding as g, type IntegrationGrant as h, integrationToolName as i, inferIntegrationSupportTier, type IntegrationGrantStore as j, type IntegrationManifest as k, type IntegrationManifestResolution as l, type IntegrationRequirement as m, type IntegrationRequirementMode as n, type IntegrationRequirementResolution as o, parseIntegrationToolName as p, type IntegrationRequirementStatus as q, IntegrationRuntime as r, searchIntegrationTools as s, summarizeIntegrationRegistry, toMcpTools as t, type IntegrationRuntimeHub as u, type IntegrationRuntimeOptions as v, type IntegrationSandboxBundle as w, createIntegrationRuntime as x, type CheckConnectorInput as y, type CheckConnectorResult as z };
|
package/dist/registry.js
CHANGED
|
@@ -4,13 +4,15 @@ import {
|
|
|
4
4
|
composeIntegrationRegistry,
|
|
5
5
|
inferIntegrationSupportTier,
|
|
6
6
|
summarizeIntegrationRegistry
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-TUX6MJJ4.js";
|
|
8
|
+
import "./chunk-P24T3MLM.js";
|
|
8
9
|
import "./chunk-SVQ4PHDZ.js";
|
|
10
|
+
import "./chunk-H4XYLS7T.js";
|
|
11
|
+
import "./chunk-YOKNZY2N.js";
|
|
9
12
|
import "./chunk-4JQ754PA.js";
|
|
10
13
|
import "./chunk-376UBTNB.js";
|
|
11
14
|
import "./chunk-JU25UDN2.js";
|
|
12
15
|
import "./chunk-2TW2QKGZ.js";
|
|
13
|
-
import "./chunk-P24T3MLM.js";
|
|
14
16
|
import "./chunk-ATYHZXLL.js";
|
|
15
17
|
export {
|
|
16
18
|
buildDefaultIntegrationRegistry,
|
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @stable Provider-agnostic inbound webhook router.
|
|
3
|
+
*
|
|
4
|
+
* Consumer hooks a single HTTP handler at `/webhook/:provider/:event`
|
|
5
|
+
* (or whatever pathing they prefer) and forwards the request through
|
|
6
|
+
* `WebhookRouter.handle()`. The router:
|
|
7
|
+
*
|
|
8
|
+
* 1. Resolves the registered provider entry.
|
|
9
|
+
* 2. Calls the provider's `verifySignature(rawBody, headers, secrets)`.
|
|
10
|
+
* Failure → 401 fast, no downstream work.
|
|
11
|
+
* 3. Calls the provider's `parse(rawBody, headers)` to extract zero or
|
|
12
|
+
* more normalized events.
|
|
13
|
+
* 4. Enqueues each event for async processing via the consumer-supplied
|
|
14
|
+
* `deliver(event)` callback (best-effort fire-and-forget — the
|
|
15
|
+
* router does NOT block the HTTP response on the consumer's work).
|
|
16
|
+
* 5. Returns 200 fast with `{received: events.length}`.
|
|
17
|
+
*
|
|
18
|
+
* Replay protection: providers that sign timestamps (Stripe, Slack)
|
|
19
|
+
* already reject stale signatures inside `verifySignature`. For providers
|
|
20
|
+
* that don't (DocuSeal, GDrive push), the router exposes a pluggable
|
|
21
|
+
* `idempotency` hook: if `idempotency.seen(providerEventId)` returns
|
|
22
|
+
* true, the router 200s without invoking `deliver()`. Consumers wire
|
|
23
|
+
* this to a durable kv (D1 / Redis / Postgres unique-index).
|
|
24
|
+
*
|
|
25
|
+
* Why a router and not a per-provider express app: the runtime contract
|
|
26
|
+
* a product cares about is "an inbound event came in, here's the
|
|
27
|
+
* normalized envelope". Verification, parsing, and idempotency-dedup
|
|
28
|
+
* are mechanical and provider-specific — the router owns them. The
|
|
29
|
+
* consumer's `deliver()` is the only place product logic runs.
|
|
30
|
+
*
|
|
31
|
+
* Stability: `@stable` — additions to `WebhookEnvelope` must be
|
|
32
|
+
* additive; the router's HTTP contract (paths, status codes) is frozen
|
|
33
|
+
* at 200 (ok), 400 (bad request), 401 (bad signature), 404 (unknown
|
|
34
|
+
* provider), 405 (provider has no inbound surface).
|
|
35
|
+
*/
|
|
36
|
+
interface WebhookHeaders {
|
|
37
|
+
[name: string]: string | string[] | undefined;
|
|
38
|
+
}
|
|
39
|
+
/** Normalized inbound event the router emits after parsing. */
|
|
40
|
+
interface WebhookEnvelope<TPayload = unknown> {
|
|
41
|
+
/** Provider id (matches the `:provider` path segment). */
|
|
42
|
+
provider: string;
|
|
43
|
+
/** Optional event class — e.g., 'customer.subscription.deleted'. The
|
|
44
|
+
* provider's parser decides. Used for routing inside `deliver()`. */
|
|
45
|
+
eventType: string;
|
|
46
|
+
/** Provider-emitted event id, when present. Used for the idempotency
|
|
47
|
+
* short-circuit. */
|
|
48
|
+
providerEventId?: string;
|
|
49
|
+
/** Wall-clock receive time. */
|
|
50
|
+
receivedAt: number;
|
|
51
|
+
/** Provider payload, normalized to the provider's documented event
|
|
52
|
+
* shape. The router does NOT reshape this — `parse()` is the contract. */
|
|
53
|
+
payload: TPayload;
|
|
54
|
+
/** Headers passed through for downstream handlers that want them
|
|
55
|
+
* (e.g., to extract custom routing metadata). Always lowercased keys. */
|
|
56
|
+
headers: Record<string, string>;
|
|
57
|
+
}
|
|
58
|
+
type SignatureVerification = {
|
|
59
|
+
valid: true;
|
|
60
|
+
} | {
|
|
61
|
+
valid: false;
|
|
62
|
+
reason: string;
|
|
63
|
+
};
|
|
64
|
+
/** Per-provider plug-in. Stateless — the router calls `verifySignature`
|
|
65
|
+
* then `parse` on every request. The provider's HTTP-shape concerns
|
|
66
|
+
* (e.g., raw body required) are documented per provider. */
|
|
67
|
+
interface WebhookProvider {
|
|
68
|
+
/** Stable provider id (`stripe`, `docuseal`, `gdrive`, ...). */
|
|
69
|
+
id: string;
|
|
70
|
+
/** Verify the inbound signature. Receives the EXACT raw body string —
|
|
71
|
+
* consumers MUST preserve raw bytes through their HTTP server (do not
|
|
72
|
+
* parse JSON before forwarding here). */
|
|
73
|
+
verifySignature(input: {
|
|
74
|
+
rawBody: string;
|
|
75
|
+
headers: WebhookHeaders;
|
|
76
|
+
secret: string;
|
|
77
|
+
}): SignatureVerification;
|
|
78
|
+
/** Parse the validated raw body into zero or more normalized events.
|
|
79
|
+
* A single push payload may carry multiple events (e.g., Slack bulk
|
|
80
|
+
* delivery). Return [] to ack the push as a no-op. */
|
|
81
|
+
parse(input: {
|
|
82
|
+
rawBody: string;
|
|
83
|
+
headers: WebhookHeaders;
|
|
84
|
+
now?: number;
|
|
85
|
+
}): WebhookEnvelope[] | Promise<WebhookEnvelope[]>;
|
|
86
|
+
}
|
|
87
|
+
interface WebhookIdempotencyStore {
|
|
88
|
+
/** Returns true if this providerEventId has been processed already.
|
|
89
|
+
* Implementations should be O(1) (Redis SETNX, D1 UNIQUE constraint). */
|
|
90
|
+
seen(providerEventId: string): Promise<boolean> | boolean;
|
|
91
|
+
/** Marks a providerEventId as processed. Called AFTER `deliver()` has
|
|
92
|
+
* been invoked. */
|
|
93
|
+
remember(providerEventId: string, ttlMs: number): Promise<void> | void;
|
|
94
|
+
}
|
|
95
|
+
interface WebhookRouterOptions {
|
|
96
|
+
/** Provider registry. Pass any number of providers; routing is by id. */
|
|
97
|
+
providers: WebhookProvider[];
|
|
98
|
+
/** Async callback invoked with every accepted event. Fire-and-forget
|
|
99
|
+
* from the router's perspective — the HTTP response is sent before
|
|
100
|
+
* this resolves. Throws are caught and reported via `onError`. */
|
|
101
|
+
deliver(event: WebhookEnvelope): Promise<void> | void;
|
|
102
|
+
/** Resolve the signing secret for a provider id at request time. The
|
|
103
|
+
* router never holds secrets — the consumer's vault resolves them. */
|
|
104
|
+
resolveSecret(providerId: string, headers: WebhookHeaders): Promise<string | null> | string | null;
|
|
105
|
+
/** Optional idempotency-dedup hook. Required for providers that don't
|
|
106
|
+
* sign timestamps in their signature scheme (DocuSeal, Drive push). */
|
|
107
|
+
idempotency?: WebhookIdempotencyStore;
|
|
108
|
+
/** TTL on idempotency entries. Default 7 days — long enough that a
|
|
109
|
+
* provider's normal retry-window can't re-deliver. */
|
|
110
|
+
idempotencyTtlMs?: number;
|
|
111
|
+
/** Surface delivery errors. Default: console.error. */
|
|
112
|
+
onError?(err: unknown, context: {
|
|
113
|
+
provider: string;
|
|
114
|
+
eventType?: string;
|
|
115
|
+
providerEventId?: string;
|
|
116
|
+
}): void;
|
|
117
|
+
/** Override `now()` for tests. */
|
|
118
|
+
now?(): number;
|
|
119
|
+
}
|
|
120
|
+
interface WebhookRouterRequest {
|
|
121
|
+
providerId: string;
|
|
122
|
+
rawBody: string;
|
|
123
|
+
headers: WebhookHeaders;
|
|
124
|
+
}
|
|
125
|
+
interface WebhookRouterResponse {
|
|
126
|
+
status: number;
|
|
127
|
+
body: unknown;
|
|
128
|
+
headers?: Record<string, string>;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* Router instance. Stateless aside from the provider registry — safe to
|
|
132
|
+
* share across requests; build once per process.
|
|
133
|
+
*/
|
|
134
|
+
declare class WebhookRouter {
|
|
135
|
+
private readonly providers;
|
|
136
|
+
private readonly deliver;
|
|
137
|
+
private readonly resolveSecret;
|
|
138
|
+
private readonly idempotency?;
|
|
139
|
+
private readonly idempotencyTtlMs;
|
|
140
|
+
private readonly onError;
|
|
141
|
+
private readonly nowFn;
|
|
142
|
+
constructor(opts: WebhookRouterOptions);
|
|
143
|
+
/** Process one inbound webhook request. Pure with respect to side-
|
|
144
|
+
* effects on the router instance — safe to call concurrently. */
|
|
145
|
+
handle(request: WebhookRouterRequest): Promise<WebhookRouterResponse>;
|
|
146
|
+
private deliverEach;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
export { type SignatureVerification as S, type WebhookProvider as W, type WebhookEnvelope as a, type WebhookHeaders as b, type WebhookIdempotencyStore as c, WebhookRouter as d, type WebhookRouterOptions as e, type WebhookRouterRequest as f, type WebhookRouterResponse as g };
|
package/dist/runtime.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
export { f as InMemoryIntegrationGrantStore, g as IntegrationCapabilityBinding, h as IntegrationGrant, j as IntegrationGrantStore, k as IntegrationManifest, l as IntegrationManifestResolution, m as IntegrationRequirement, n as IntegrationRequirementMode, o as IntegrationRequirementResolution, q as IntegrationRequirementStatus, r as IntegrationRuntime, u as IntegrationRuntimeHub, v as IntegrationRuntimeOptions, w as IntegrationSandboxBundle, x as createIntegrationRuntime } from './registry.js';
|
|
2
2
|
import './tangle-id-CTU4kGId.js';
|
|
3
|
+
import './errors-Bg3_rxnQ.js';
|
|
3
4
|
import './connect/index.js';
|
|
4
5
|
import './middleware/index.js';
|
|
5
6
|
import './connectors/index.js';
|
package/dist/runtime.js
CHANGED
|
@@ -2,13 +2,15 @@ import {
|
|
|
2
2
|
InMemoryIntegrationGrantStore,
|
|
3
3
|
IntegrationRuntime,
|
|
4
4
|
createIntegrationRuntime
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-TUX6MJJ4.js";
|
|
6
|
+
import "./chunk-P24T3MLM.js";
|
|
6
7
|
import "./chunk-SVQ4PHDZ.js";
|
|
8
|
+
import "./chunk-H4XYLS7T.js";
|
|
9
|
+
import "./chunk-YOKNZY2N.js";
|
|
7
10
|
import "./chunk-4JQ754PA.js";
|
|
8
11
|
import "./chunk-376UBTNB.js";
|
|
9
12
|
import "./chunk-JU25UDN2.js";
|
|
10
13
|
import "./chunk-2TW2QKGZ.js";
|
|
11
|
-
import "./chunk-P24T3MLM.js";
|
|
12
14
|
import "./chunk-ATYHZXLL.js";
|
|
13
15
|
export {
|
|
14
16
|
InMemoryIntegrationGrantStore,
|
package/dist/specs.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { a4 as ApiKeyAuthSpec, a5 as ConsoleStep, a6 as CredentialFieldSpec, a7 as CredentialValidationInput, a8 as CredentialValidationResult, a9 as CustomAuthSpec, aa as HealthcheckPlan, ab as HealthcheckSpec, ac as HmacAuthSpec, ad as INTEGRATION_FAMILIES, ae as IntegrationAuthMode, af as IntegrationAuthSpec, ag as IntegrationFamilyId, ah as IntegrationFamilySpec, ai as IntegrationLifecycleSpec, aj as IntegrationPlannerHints, ak as IntegrationSetupSpec, al as IntegrationSpec, am as IntegrationSpecStatus, an as IntegrationSpecValidationIssue, ao as IntegrationSpecValidationResult, ap as NoneAuthSpec, aq as NormalizedPermission, ar as OAuth2AuthSpec, as as PermissionDescriptor, at as PostSetupCheck, au as Quirk, av as RenderSpecOptions, aw as RenderedConsoleStep, ax as ScopeDescriptor, ay as assertValidIntegrationSpec, az as buildHealthcheckPlan, aA as consoleStepsToText, aB as getIntegrationFamily, aC as getIntegrationSpec, aD as integrationSpecToConnector, aE as listExecutableIntegrationSpecs, aF as listIntegrationSpecs, aG as renderAgentToolDescription, aH as renderConsoleSteps, aI as renderRunbookMarkdown, aJ as specAuthToConnectorAuth, aK as validateCredentialFormat, aL as validateCredentialSet, aM as validateIntegrationSpec } from './registry.js';
|
|
2
2
|
import './tangle-id-CTU4kGId.js';
|
|
3
|
+
import './errors-Bg3_rxnQ.js';
|
|
3
4
|
import './connect/index.js';
|
|
4
5
|
import './middleware/index.js';
|
|
5
6
|
import './connectors/index.js';
|