@lssm/lib.contracts 0.0.0-canary-20251217052941 → 0.0.0-canary-20251217060433
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/app-config/app-config.feature.d.ts +11 -0
- package/dist/app-config/branding.d.ts +55 -0
- package/dist/app-config/contracts.d.ts +244 -0
- package/dist/app-config/docs/app-config.docblock.d.ts +6 -0
- package/dist/app-config/events.d.ts +122 -0
- package/dist/app-config/index.d.ts +9 -0
- package/dist/app-config/lifecycle-contracts.d.ts +382 -0
- package/dist/app-config/lifecycle.d.ts +27 -0
- package/dist/app-config/runtime.d.ts +114 -0
- package/dist/app-config/spec.d.ts +175 -0
- package/dist/app-config/validation.d.ts +47 -0
- package/dist/capabilities/docs/capabilities.docblock.d.ts +6 -0
- package/dist/capabilities/openbanking.d.ts +9 -0
- package/dist/capabilities.d.ts +48 -0
- package/dist/client/index.d.ts +6 -0
- package/dist/client/react/drivers/rn-reusables.d.ts +22 -0
- package/dist/client/react/drivers/shadcn.d.ts +12 -0
- package/dist/client/react/feature-render.d.ts +19 -0
- package/dist/client/react/form-render.d.ts +91 -0
- package/dist/client/react/index.d.ts +5 -0
- package/dist/contract-registry/index.d.ts +3 -0
- package/dist/contract-registry/schemas.d.ts +124 -0
- package/dist/contract-registry/types.d.ts +46 -0
- package/dist/contracts-adapter-hydration.d.ts +15 -0
- package/dist/contracts-adapter-input.d.ts +10 -0
- package/dist/data-views/docs/data-views.docblock.d.ts +6 -0
- package/dist/data-views/query-generator.d.ts +39 -0
- package/dist/data-views/runtime.d.ts +26 -0
- package/dist/data-views.d.ts +131 -0
- package/dist/docs/PUBLISHING.docblock.d.ts +6 -0
- package/dist/docs/accessibility_wcag_compliance_specs.docblock.d.ts +6 -0
- package/dist/docs/index.d.ts +6 -0
- package/dist/docs/meta.docs.d.ts +6 -0
- package/dist/docs/presentations.d.ts +33 -0
- package/dist/docs/registry.d.ts +24 -0
- package/dist/docs/tech/PHASE_1_QUICKSTART.docblock.d.ts +6 -0
- package/dist/docs/tech/PHASE_2_AI_NATIVE_OPERATIONS.docblock.d.ts +6 -0
- package/dist/docs/tech/PHASE_3_AUTO_EVOLUTION.docblock.d.ts +6 -0
- package/dist/docs/tech/PHASE_4_PERSONALIZATION_ENGINE.docblock.d.ts +6 -0
- package/dist/docs/tech/PHASE_5_ZERO_TOUCH_OPERATIONS.docblock.d.ts +6 -0
- package/dist/docs/tech/auth/better-auth-nextjs.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/README.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/create-subscription.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/graphql-typed-outputs.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/migrations.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/openapi-export.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/ops-to-presentation-linking.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/overlays.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/tests.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/themes.docblock.d.ts +6 -0
- package/dist/docs/tech/contracts/vertical-pocket-family-office.docblock.d.ts +6 -0
- package/dist/docs/tech/lifecycle-stage-system.docblock.d.ts +6 -0
- package/dist/docs/tech/llm/llm-integration.docblock.d.ts +7 -0
- package/dist/docs/tech/mcp-endpoints.docblock.d.ts +6 -0
- package/dist/docs/tech/presentation-runtime.docblock.d.ts +6 -0
- package/dist/docs/tech/schema/README.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/learning-events.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/learning-journeys.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/platform-admin-panel.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/project-access-teams.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/project-routing.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/sandbox-unlogged.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/team-invitations.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/workspace-ops.docblock.d.ts +6 -0
- package/dist/docs/tech/studio/workspaces.docblock.d.ts +6 -0
- package/dist/docs/tech/telemetry-ingest.docblock.d.ts +6 -0
- package/dist/docs/tech/templates/runtime.docblock.d.ts +6 -0
- package/dist/docs/tech/vscode-extension.docblock.d.ts +6 -0
- package/dist/docs/tech/workflows/overview.docblock.d.ts +6 -0
- package/dist/docs/tech-contracts.docs.d.ts +6 -0
- package/dist/docs/types.d.ts +41 -0
- package/dist/events.d.ts +47 -0
- package/dist/experiments/docs/experiments.docblock.d.ts +6 -0
- package/dist/experiments/evaluator.d.ts +37 -0
- package/dist/experiments/spec-resolver.d.ts +16 -0
- package/dist/experiments/spec.d.ts +89 -0
- package/dist/features.d.ts +96 -0
- package/dist/forms/docs/forms.docblock.d.ts +6 -0
- package/dist/forms.d.ts +258 -0
- package/dist/index.d.ts +127 -0
- package/dist/install.d.ts +76 -0
- package/dist/integrations/binding.d.ts +17 -0
- package/dist/integrations/connection.d.ts +51 -0
- package/dist/integrations/contracts.d.ts +435 -0
- package/dist/integrations/docs/integrations.docblock.d.ts +6 -0
- package/dist/integrations/health.d.ts +21 -0
- package/dist/integrations/index.d.ts +34 -0
- package/dist/integrations/openbanking/contracts/accounts.d.ts +287 -0
- package/dist/integrations/openbanking/contracts/balances.d.ts +163 -0
- package/dist/integrations/openbanking/contracts/index.d.ts +10 -0
- package/dist/integrations/openbanking/contracts/transactions.d.ts +211 -0
- package/dist/integrations/openbanking/guards.d.ts +12 -0
- package/dist/integrations/openbanking/models.d.ts +228 -0
- package/dist/integrations/openbanking/openbanking.feature.d.ts +11 -0
- package/dist/integrations/openbanking/telemetry.d.ts +15 -0
- package/dist/integrations/providers/calendar.d.ts +78 -0
- package/dist/integrations/providers/elevenlabs.d.ts +7 -0
- package/dist/integrations/providers/email.d.ts +86 -0
- package/dist/integrations/providers/embedding.d.ts +24 -0
- package/dist/integrations/providers/gcs-storage.d.ts +7 -0
- package/dist/integrations/providers/gmail.d.ts +7 -0
- package/dist/integrations/providers/google-calendar.d.ts +7 -0
- package/dist/integrations/providers/impls/elevenlabs-voice.d.ts +20 -0
- package/dist/integrations/providers/impls/gcs-storage.d.ts +24 -0
- package/dist/integrations/providers/impls/gmail-inbound.d.ts +26 -0
- package/dist/integrations/providers/impls/gmail-outbound.d.ts +18 -0
- package/dist/integrations/providers/impls/google-calendar.d.ts +23 -0
- package/dist/integrations/providers/impls/index.d.ts +15 -0
- package/dist/integrations/providers/impls/mistral-embedding.d.ts +23 -0
- package/dist/integrations/providers/impls/mistral-llm.d.ts +31 -0
- package/dist/integrations/providers/impls/postmark-email.d.ts +19 -0
- package/dist/integrations/providers/impls/powens-client.d.ts +124 -0
- package/dist/integrations/providers/impls/powens-openbanking.d.ts +27 -0
- package/dist/integrations/providers/impls/provider-factory.d.ts +26 -0
- package/dist/integrations/providers/impls/qdrant-vector.d.ts +24 -0
- package/dist/integrations/providers/impls/stripe-payments.d.ts +28 -0
- package/dist/integrations/providers/impls/twilio-sms.d.ts +20 -0
- package/dist/integrations/providers/index.d.ts +22 -0
- package/dist/integrations/providers/llm.d.ts +82 -0
- package/dist/integrations/providers/mistral.d.ts +7 -0
- package/dist/integrations/providers/openbanking.d.ts +128 -0
- package/dist/integrations/providers/payments.d.ts +109 -0
- package/dist/integrations/providers/postmark.d.ts +7 -0
- package/dist/integrations/providers/powens.d.ts +7 -0
- package/dist/integrations/providers/qdrant.d.ts +7 -0
- package/dist/integrations/providers/registry.d.ts +11 -0
- package/dist/integrations/providers/sms.d.ts +34 -0
- package/dist/integrations/providers/storage.d.ts +60 -0
- package/dist/integrations/providers/stripe.d.ts +7 -0
- package/dist/integrations/providers/twilio-sms.d.ts +7 -0
- package/dist/integrations/providers/vector-store.d.ts +43 -0
- package/dist/integrations/providers/voice.d.ts +34 -0
- package/dist/integrations/runtime.d.ts +99 -0
- package/dist/integrations/secrets/aws-secret-manager.d.ts +31 -0
- package/dist/integrations/secrets/env-secret-provider.d.ts +31 -0
- package/dist/integrations/secrets/gcp-secret-manager.d.ts +32 -0
- package/dist/integrations/secrets/gcp-secret-manager.js +1 -1
- package/dist/integrations/secrets/index.d.ts +7 -0
- package/dist/integrations/secrets/manager.d.ts +47 -0
- package/dist/integrations/secrets/provider.d.ts +52 -0
- package/dist/integrations/secrets/scaleway-secret-manager.d.ts +38 -0
- package/dist/integrations/spec.d.ts +79 -0
- package/dist/jobs/define-job.d.ts +18 -0
- package/dist/jobs/gcp-cloud-tasks.d.ts +41 -0
- package/dist/jobs/gcp-pubsub.d.ts +25 -0
- package/dist/jobs/handlers/gmail-sync-handler.d.ts +9 -0
- package/dist/jobs/handlers/index.d.ts +9 -0
- package/dist/jobs/handlers/ping-handler.d.ts +10 -0
- package/dist/jobs/handlers/storage-document-handler.d.ts +12 -0
- package/dist/jobs/index.d.ts +3 -0
- package/dist/jobs/memory-queue.d.ts +18 -0
- package/dist/jobs/queue.d.ts +131 -0
- package/dist/jobs/scaleway-sqs-queue.d.ts +30 -0
- package/dist/jsonschema.d.ts +27 -0
- package/dist/knowledge/binding.d.ts +25 -0
- package/dist/knowledge/contracts.d.ts +316 -0
- package/dist/knowledge/docs/knowledge.docblock.d.ts +6 -0
- package/dist/knowledge/index.d.ts +10 -0
- package/dist/knowledge/ingestion/document-processor.d.ts +24 -0
- package/dist/knowledge/ingestion/embedding-service.d.ts +12 -0
- package/dist/knowledge/ingestion/gmail-adapter.d.ts +18 -0
- package/dist/knowledge/ingestion/index.d.ts +6 -0
- package/dist/knowledge/ingestion/storage-adapter.d.ts +15 -0
- package/dist/knowledge/ingestion/vector-indexer.d.ts +18 -0
- package/dist/knowledge/query/index.d.ts +2 -0
- package/dist/knowledge/query/service.d.ts +29 -0
- package/dist/knowledge/runtime.d.ts +32 -0
- package/dist/knowledge/source.d.ts +32 -0
- package/dist/knowledge/spaces/email-threads.d.ts +7 -0
- package/dist/knowledge/spaces/financial-docs.d.ts +7 -0
- package/dist/knowledge/spaces/financial-overview.d.ts +7 -0
- package/dist/knowledge/spaces/index.d.ts +7 -0
- package/dist/knowledge/spaces/product-canon.d.ts +7 -0
- package/dist/knowledge/spaces/support-faq.d.ts +7 -0
- package/dist/knowledge/spaces/uploaded-docs.d.ts +7 -0
- package/dist/knowledge/spec.d.ts +52 -0
- package/dist/llm/exporters.d.ts +67 -0
- package/dist/llm/index.d.ts +4 -0
- package/dist/llm/prompts.d.ts +51 -0
- package/dist/llm/types.d.ts +213 -0
- package/dist/markdown.d.ts +21 -0
- package/dist/migrations.d.ts +52 -0
- package/dist/onboarding-base.d.ts +137 -0
- package/dist/openapi.d.ts +31 -0
- package/dist/openbanking/docs/openbanking.docblock.d.ts +6 -0
- package/dist/ownership.d.ts +75 -0
- package/dist/policy/docs/policy.docblock.d.ts +6 -0
- package/dist/policy/engine.d.ts +39 -0
- package/dist/policy/opa-adapter.d.ts +45 -0
- package/dist/policy/spec.d.ts +114 -0
- package/dist/presentations/docs/presentations-conventions.docblock.d.ts +6 -0
- package/dist/presentations.backcompat.d.ts +7 -0
- package/dist/presentations.d.ts +98 -0
- package/dist/presentations.v2.d.ts +114 -0
- package/dist/prompt.d.ts +60 -0
- package/dist/promptRegistry.d.ts +15 -0
- package/dist/regenerator/adapters.d.ts +19 -0
- package/dist/regenerator/docs/regenerator.docblock.d.ts +6 -0
- package/dist/regenerator/executor.d.ts +70 -0
- package/dist/regenerator/index.d.ts +7 -0
- package/dist/regenerator/service.d.ts +33 -0
- package/dist/regenerator/sinks.d.ts +26 -0
- package/dist/regenerator/types.d.ts +107 -0
- package/dist/regenerator/utils.d.ts +9 -0
- package/dist/registry.d.ts +73 -0
- package/dist/resources.d.ts +64 -0
- package/dist/schema-to-markdown.d.ts +54 -0
- package/dist/server/graphql-pothos.d.ts +27 -0
- package/dist/server/index.d.ts +9 -0
- package/dist/server/mcp/createMcpServer.d.ts +15 -0
- package/dist/server/mcp/mcpTypes.d.ts +29 -0
- package/dist/server/mcp/registerPresentations.d.ts +7 -0
- package/dist/server/mcp/registerPrompts.d.ts +8 -0
- package/dist/server/mcp/registerResources.d.ts +8 -0
- package/dist/server/mcp/registerTools.d.ts +8 -0
- package/dist/server/provider-mcp.d.ts +2 -0
- package/dist/server/rest-elysia.d.ts +40 -0
- package/dist/server/rest-express.d.ts +16 -0
- package/dist/server/rest-generic.d.ts +32 -0
- package/dist/server/rest-next-app.d.ts +35 -0
- package/dist/server/rest-next-mcp.d.ts +11 -0
- package/dist/server/rest-next-pages.d.ts +9 -0
- package/dist/spec.d.ts +195 -0
- package/dist/telemetry/anomaly.d.ts +27 -0
- package/dist/telemetry/docs/telemetry.docblock.d.ts +6 -0
- package/dist/telemetry/index.d.ts +4 -0
- package/dist/telemetry/spec.d.ts +98 -0
- package/dist/telemetry/tracker.d.ts +51 -0
- package/dist/tests/index.d.ts +3 -0
- package/dist/tests/runner.d.ts +43 -0
- package/dist/tests/spec.d.ts +89 -0
- package/dist/themes.d.ts +55 -0
- package/dist/translations/catalog.d.ts +28 -0
- package/dist/translations/tenant.d.ts +15 -0
- package/dist/types/all.d.ts +60 -0
- package/dist/types.d.ts +88 -0
- package/dist/workflow/adapters/db-adapter.d.ts +34 -0
- package/dist/workflow/adapters/file-adapter.d.ts +14 -0
- package/dist/workflow/adapters/index.d.ts +4 -0
- package/dist/workflow/adapters/memory-store.d.ts +18 -0
- package/dist/workflow/expression.d.ts +9 -0
- package/dist/workflow/index.d.ts +10 -0
- package/dist/workflow/runner.d.ts +74 -0
- package/dist/workflow/sla-monitor.d.ts +20 -0
- package/dist/workflow/spec.d.ts +99 -0
- package/dist/workflow/state.d.ts +35 -0
- package/dist/workflow/validation.d.ts +28 -0
- package/package.json +250 -250
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { EventSpec } from "./events.js";
|
|
2
|
+
import { ResourceRefDescriptor } from "./resources.js";
|
|
3
|
+
import { AnyContractSpec, ContractSpec, EmitDecl } from "./spec.js";
|
|
4
|
+
import { HandlerCtx } from "./types.js";
|
|
5
|
+
import { SpecRegistry } from "./registry.js";
|
|
6
|
+
import { AnySchemaModel, ZodSchemaModel } from "@lssm/lib.schema";
|
|
7
|
+
import * as z$1 from "zod";
|
|
8
|
+
|
|
9
|
+
//#region src/install.d.ts
|
|
10
|
+
/** Infer input/output types from a ContractSpec */
|
|
11
|
+
type SpecInput<Spec extends AnyContractSpec> = Spec['io']['input'];
|
|
12
|
+
type ZodSpecInput<Spec extends AnyContractSpec> = ZodSchemaModel<SpecInput<Spec> extends null ? AnySchemaModel : NonNullable<SpecInput<Spec>>>;
|
|
13
|
+
type SpecOutput<Spec extends AnyContractSpec> = Spec['io']['output'];
|
|
14
|
+
type ResourceItem<O extends ResourceRefDescriptor<boolean>> = Record<O['varName'] extends string ? O['varName'] : 'id', string | number>;
|
|
15
|
+
type ResourceRefOut<O> = O extends ResourceRefDescriptor<boolean> ? O['many'] extends true ? ResourceItem<O>[] : ResourceItem<O> : never;
|
|
16
|
+
type RuntimeSpecOutput<Spec extends AnyContractSpec> = SpecOutput<Spec> extends AnySchemaModel ? ZodSchemaModel<SpecOutput<Spec>> : ResourceRefOut<SpecOutput<Spec>>;
|
|
17
|
+
/** Handler signature derived from the Spec */
|
|
18
|
+
type HandlerFor<Spec extends AnyContractSpec> = (args: ZodSpecInput<Spec>, ctx: HandlerCtx) => Promise<RuntimeSpecOutput<Spec>>;
|
|
19
|
+
/** Typed event param from Spec.sideEffects.emits */
|
|
20
|
+
type EventParam<S extends ContractSpec<AnySchemaModel, AnySchemaModel | ResourceRefDescriptor<boolean>>> = S extends {
|
|
21
|
+
sideEffects?: {
|
|
22
|
+
emits?: readonly (infer E)[];
|
|
23
|
+
};
|
|
24
|
+
} ? E extends {
|
|
25
|
+
name: string;
|
|
26
|
+
version: number;
|
|
27
|
+
payload: AnySchemaModel;
|
|
28
|
+
} ? {
|
|
29
|
+
name: E['name'];
|
|
30
|
+
version: E['version'];
|
|
31
|
+
payload: z$1.infer<ReturnType<E['payload']['getZod']>>;
|
|
32
|
+
} : never : never;
|
|
33
|
+
/** Build a type union of allowed events for a spec */
|
|
34
|
+
type AllowedEventUnion<S extends ContractSpec<AnySchemaModel, AnySchemaModel | ResourceRefDescriptor<boolean>>> = S['sideEffects'] extends {
|
|
35
|
+
emits: readonly EmitDecl[];
|
|
36
|
+
} ? { [K in keyof S['sideEffects']['emits']]: S['sideEffects']['emits'][K] extends {
|
|
37
|
+
ref: EventSpec<infer P>;
|
|
38
|
+
} ? {
|
|
39
|
+
name: S['sideEffects']['emits'][K]['ref']['name'];
|
|
40
|
+
version: S['sideEffects']['emits'][K]['ref']['version'];
|
|
41
|
+
payload: z$1.infer<ReturnType<P['getZod']>>;
|
|
42
|
+
} : S['sideEffects']['emits'][K] extends {
|
|
43
|
+
name: infer N extends string;
|
|
44
|
+
version: infer V extends number;
|
|
45
|
+
payload: infer Q extends AnySchemaModel;
|
|
46
|
+
} ? {
|
|
47
|
+
name: N;
|
|
48
|
+
version: V;
|
|
49
|
+
payload: z$1.infer<ReturnType<Q['getZod']>>;
|
|
50
|
+
} : never }[number] : never;
|
|
51
|
+
/** Typed emit for a given spec (validates at runtime through ctx.__emitGuard__). */
|
|
52
|
+
declare function makeEmit<S extends AnyContractSpec>(_spec: S, ctx: HandlerCtx): {
|
|
53
|
+
/** Le plus sûr : typé via EventSpec (pas besoin de tuple dans le spec) */
|
|
54
|
+
ref: <T extends AnySchemaModel>(ev: EventSpec<T>, payload: ZodSchemaModel<T>) => Promise<void>;
|
|
55
|
+
/** Nom/version explicites (runtime-checked par la guard) */
|
|
56
|
+
named: (name: string, version: number, payload: unknown) => Promise<void>;
|
|
57
|
+
/** Compat : objet (bénéficie du typing si votre spec a un tuple `as const`) */
|
|
58
|
+
object: (evt: AllowedEventUnion<S>) => Promise<void>;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Register the Spec and bind the handler in one call, with full type inference.
|
|
62
|
+
* Returns the registry for chaining.
|
|
63
|
+
*/
|
|
64
|
+
declare function installOp<S extends AnyContractSpec>(reg: SpecRegistry, spec: S, handler: HandlerFor<S>): SpecRegistry;
|
|
65
|
+
/**
|
|
66
|
+
* Curried variant if you prefer building a module installer.
|
|
67
|
+
* const install = op(BeginSignupSpec, handler);
|
|
68
|
+
* install(reg);
|
|
69
|
+
*/
|
|
70
|
+
declare function op<S extends AnyContractSpec>(spec: S, handler: HandlerFor<AnyContractSpec>): {
|
|
71
|
+
spec: S;
|
|
72
|
+
handler: HandlerFor<AnyContractSpec>;
|
|
73
|
+
install: (reg: SpecRegistry) => SpecRegistry;
|
|
74
|
+
};
|
|
75
|
+
//#endregion
|
|
76
|
+
export { EventParam, HandlerFor, RuntimeSpecOutput, SpecInput, SpecOutput, ZodSpecInput, installOp, makeEmit, op };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
//#region src/integrations/binding.d.ts
|
|
2
|
+
interface AppIntegrationBinding {
|
|
3
|
+
/** Which slot this binding satisfies. */
|
|
4
|
+
slotId: string;
|
|
5
|
+
/** Which IntegrationConnection to use. */
|
|
6
|
+
connectionId: string;
|
|
7
|
+
/** Optional: scope to specific workflows/features. */
|
|
8
|
+
scope?: {
|
|
9
|
+
workflows?: string[];
|
|
10
|
+
features?: string[];
|
|
11
|
+
operations?: string[];
|
|
12
|
+
};
|
|
13
|
+
/** Priority when multiple connections provide same capability. */
|
|
14
|
+
priority?: number;
|
|
15
|
+
}
|
|
16
|
+
//#endregion
|
|
17
|
+
export { AppIntegrationBinding };
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { IntegrationOwnershipMode } from "./spec.js";
|
|
2
|
+
|
|
3
|
+
//#region src/integrations/connection.d.ts
|
|
4
|
+
type ConnectionStatus = 'connected' | 'disconnected' | 'error' | 'unknown';
|
|
5
|
+
interface IntegrationConnectionHealth {
|
|
6
|
+
status: ConnectionStatus;
|
|
7
|
+
checkedAt?: Date;
|
|
8
|
+
latencyMs?: number;
|
|
9
|
+
errorCode?: string;
|
|
10
|
+
errorMessage?: string;
|
|
11
|
+
}
|
|
12
|
+
interface IntegrationUsageMetrics {
|
|
13
|
+
requestCount?: number;
|
|
14
|
+
successCount?: number;
|
|
15
|
+
errorCount?: number;
|
|
16
|
+
lastUsed?: Date;
|
|
17
|
+
lastSuccessAt?: Date;
|
|
18
|
+
lastErrorAt?: Date;
|
|
19
|
+
lastErrorCode?: string;
|
|
20
|
+
}
|
|
21
|
+
interface IntegrationConnectionMeta {
|
|
22
|
+
id: string;
|
|
23
|
+
tenantId: string;
|
|
24
|
+
/** Reference to IntegrationSpec. */
|
|
25
|
+
integrationKey: string;
|
|
26
|
+
integrationVersion: number;
|
|
27
|
+
/** Human-readable label (e.g., "Production Stripe"). */
|
|
28
|
+
label: string;
|
|
29
|
+
environment?: string;
|
|
30
|
+
createdAt: string | Date;
|
|
31
|
+
updatedAt: string | Date;
|
|
32
|
+
}
|
|
33
|
+
interface IntegrationConnection {
|
|
34
|
+
meta: IntegrationConnectionMeta;
|
|
35
|
+
/** Ownership mode indicating who controls credentials. */
|
|
36
|
+
ownershipMode: IntegrationOwnershipMode;
|
|
37
|
+
/** External provider account/project identifier (BYOK scenarios). */
|
|
38
|
+
externalAccountId?: string;
|
|
39
|
+
/** Encrypted configuration matching IntegrationSpec.configSchema. */
|
|
40
|
+
config: Record<string, unknown>;
|
|
41
|
+
/** Reference to external secret store entry containing credentials. */
|
|
42
|
+
secretProvider: string;
|
|
43
|
+
secretRef: string;
|
|
44
|
+
status: ConnectionStatus;
|
|
45
|
+
/** Last health check result. */
|
|
46
|
+
health?: IntegrationConnectionHealth;
|
|
47
|
+
/** Usage tracking. */
|
|
48
|
+
usage?: IntegrationUsageMetrics;
|
|
49
|
+
}
|
|
50
|
+
//#endregion
|
|
51
|
+
export { ConnectionStatus, IntegrationConnection, IntegrationConnectionHealth, IntegrationConnectionMeta, IntegrationUsageMetrics };
|
|
@@ -0,0 +1,435 @@
|
|
|
1
|
+
import { ContractSpec } from "../spec.js";
|
|
2
|
+
import { SpecRegistry } from "../registry.js";
|
|
3
|
+
import * as _lssm_lib_schema461 from "@lssm/lib.schema";
|
|
4
|
+
import { SchemaModel } from "@lssm/lib.schema";
|
|
5
|
+
|
|
6
|
+
//#region src/integrations/contracts.d.ts
|
|
7
|
+
declare const CreateIntegrationConnection: ContractSpec<SchemaModel<{
|
|
8
|
+
tenantId: {
|
|
9
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
10
|
+
isOptional: false;
|
|
11
|
+
};
|
|
12
|
+
integrationKey: {
|
|
13
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
14
|
+
isOptional: false;
|
|
15
|
+
};
|
|
16
|
+
integrationVersion: {
|
|
17
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
18
|
+
isOptional: false;
|
|
19
|
+
};
|
|
20
|
+
label: {
|
|
21
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
22
|
+
isOptional: false;
|
|
23
|
+
};
|
|
24
|
+
ownershipMode: {
|
|
25
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
26
|
+
isOptional: false;
|
|
27
|
+
};
|
|
28
|
+
externalAccountId: {
|
|
29
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
30
|
+
isOptional: true;
|
|
31
|
+
};
|
|
32
|
+
secretProvider: {
|
|
33
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
34
|
+
isOptional: false;
|
|
35
|
+
};
|
|
36
|
+
secretRef: {
|
|
37
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
38
|
+
isOptional: false;
|
|
39
|
+
};
|
|
40
|
+
environment: {
|
|
41
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
42
|
+
isOptional: true;
|
|
43
|
+
};
|
|
44
|
+
config: {
|
|
45
|
+
type: _lssm_lib_schema461.FieldType<Record<string, unknown>, Record<string, unknown>>;
|
|
46
|
+
isOptional: false;
|
|
47
|
+
};
|
|
48
|
+
}>, SchemaModel<{
|
|
49
|
+
id: {
|
|
50
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
51
|
+
isOptional: false;
|
|
52
|
+
};
|
|
53
|
+
tenantId: {
|
|
54
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
55
|
+
isOptional: false;
|
|
56
|
+
};
|
|
57
|
+
integrationKey: {
|
|
58
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
59
|
+
isOptional: false;
|
|
60
|
+
};
|
|
61
|
+
integrationVersion: {
|
|
62
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
63
|
+
isOptional: false;
|
|
64
|
+
};
|
|
65
|
+
label: {
|
|
66
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
67
|
+
isOptional: false;
|
|
68
|
+
};
|
|
69
|
+
ownershipMode: {
|
|
70
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
71
|
+
isOptional: false;
|
|
72
|
+
};
|
|
73
|
+
externalAccountId: {
|
|
74
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
75
|
+
isOptional: true;
|
|
76
|
+
};
|
|
77
|
+
secretProvider: {
|
|
78
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
79
|
+
isOptional: false;
|
|
80
|
+
};
|
|
81
|
+
secretRef: {
|
|
82
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
83
|
+
isOptional: false;
|
|
84
|
+
};
|
|
85
|
+
status: {
|
|
86
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
87
|
+
isOptional: false;
|
|
88
|
+
};
|
|
89
|
+
environment: {
|
|
90
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
91
|
+
isOptional: true;
|
|
92
|
+
};
|
|
93
|
+
healthStatus: {
|
|
94
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
95
|
+
isOptional: true;
|
|
96
|
+
};
|
|
97
|
+
healthCheckedAt: {
|
|
98
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
99
|
+
isOptional: true;
|
|
100
|
+
};
|
|
101
|
+
healthLatencyMs: {
|
|
102
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
103
|
+
isOptional: true;
|
|
104
|
+
};
|
|
105
|
+
healthErrorCode: {
|
|
106
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
107
|
+
isOptional: true;
|
|
108
|
+
};
|
|
109
|
+
healthErrorMessage: {
|
|
110
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
111
|
+
isOptional: true;
|
|
112
|
+
};
|
|
113
|
+
usageRequestCount: {
|
|
114
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
115
|
+
isOptional: true;
|
|
116
|
+
};
|
|
117
|
+
usageSuccessCount: {
|
|
118
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
119
|
+
isOptional: true;
|
|
120
|
+
};
|
|
121
|
+
usageErrorCount: {
|
|
122
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
123
|
+
isOptional: true;
|
|
124
|
+
};
|
|
125
|
+
usageLastUsedAt: {
|
|
126
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
127
|
+
isOptional: true;
|
|
128
|
+
};
|
|
129
|
+
usageLastErrorAt: {
|
|
130
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
131
|
+
isOptional: true;
|
|
132
|
+
};
|
|
133
|
+
usageLastErrorCode: {
|
|
134
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
135
|
+
isOptional: true;
|
|
136
|
+
};
|
|
137
|
+
createdAt: {
|
|
138
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
139
|
+
isOptional: true;
|
|
140
|
+
};
|
|
141
|
+
updatedAt: {
|
|
142
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
143
|
+
isOptional: true;
|
|
144
|
+
};
|
|
145
|
+
}>, undefined>;
|
|
146
|
+
declare const UpdateIntegrationConnection: ContractSpec<SchemaModel<{
|
|
147
|
+
connectionId: {
|
|
148
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
149
|
+
isOptional: false;
|
|
150
|
+
};
|
|
151
|
+
label: {
|
|
152
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
153
|
+
isOptional: true;
|
|
154
|
+
};
|
|
155
|
+
status: {
|
|
156
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
157
|
+
isOptional: true;
|
|
158
|
+
};
|
|
159
|
+
ownershipMode: {
|
|
160
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
161
|
+
isOptional: true;
|
|
162
|
+
};
|
|
163
|
+
externalAccountId: {
|
|
164
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
165
|
+
isOptional: true;
|
|
166
|
+
};
|
|
167
|
+
secretProvider: {
|
|
168
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
169
|
+
isOptional: true;
|
|
170
|
+
};
|
|
171
|
+
secretRef: {
|
|
172
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
173
|
+
isOptional: true;
|
|
174
|
+
};
|
|
175
|
+
config: {
|
|
176
|
+
type: _lssm_lib_schema461.FieldType<Record<string, unknown>, Record<string, unknown>>;
|
|
177
|
+
isOptional: true;
|
|
178
|
+
};
|
|
179
|
+
}>, SchemaModel<{
|
|
180
|
+
id: {
|
|
181
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
182
|
+
isOptional: false;
|
|
183
|
+
};
|
|
184
|
+
tenantId: {
|
|
185
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
186
|
+
isOptional: false;
|
|
187
|
+
};
|
|
188
|
+
integrationKey: {
|
|
189
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
190
|
+
isOptional: false;
|
|
191
|
+
};
|
|
192
|
+
integrationVersion: {
|
|
193
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
194
|
+
isOptional: false;
|
|
195
|
+
};
|
|
196
|
+
label: {
|
|
197
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
198
|
+
isOptional: false;
|
|
199
|
+
};
|
|
200
|
+
ownershipMode: {
|
|
201
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
202
|
+
isOptional: false;
|
|
203
|
+
};
|
|
204
|
+
externalAccountId: {
|
|
205
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
206
|
+
isOptional: true;
|
|
207
|
+
};
|
|
208
|
+
secretProvider: {
|
|
209
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
210
|
+
isOptional: false;
|
|
211
|
+
};
|
|
212
|
+
secretRef: {
|
|
213
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
214
|
+
isOptional: false;
|
|
215
|
+
};
|
|
216
|
+
status: {
|
|
217
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
218
|
+
isOptional: false;
|
|
219
|
+
};
|
|
220
|
+
environment: {
|
|
221
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
222
|
+
isOptional: true;
|
|
223
|
+
};
|
|
224
|
+
healthStatus: {
|
|
225
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
226
|
+
isOptional: true;
|
|
227
|
+
};
|
|
228
|
+
healthCheckedAt: {
|
|
229
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
230
|
+
isOptional: true;
|
|
231
|
+
};
|
|
232
|
+
healthLatencyMs: {
|
|
233
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
234
|
+
isOptional: true;
|
|
235
|
+
};
|
|
236
|
+
healthErrorCode: {
|
|
237
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
238
|
+
isOptional: true;
|
|
239
|
+
};
|
|
240
|
+
healthErrorMessage: {
|
|
241
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
242
|
+
isOptional: true;
|
|
243
|
+
};
|
|
244
|
+
usageRequestCount: {
|
|
245
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
246
|
+
isOptional: true;
|
|
247
|
+
};
|
|
248
|
+
usageSuccessCount: {
|
|
249
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
250
|
+
isOptional: true;
|
|
251
|
+
};
|
|
252
|
+
usageErrorCount: {
|
|
253
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
254
|
+
isOptional: true;
|
|
255
|
+
};
|
|
256
|
+
usageLastUsedAt: {
|
|
257
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
258
|
+
isOptional: true;
|
|
259
|
+
};
|
|
260
|
+
usageLastErrorAt: {
|
|
261
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
262
|
+
isOptional: true;
|
|
263
|
+
};
|
|
264
|
+
usageLastErrorCode: {
|
|
265
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
266
|
+
isOptional: true;
|
|
267
|
+
};
|
|
268
|
+
createdAt: {
|
|
269
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
270
|
+
isOptional: true;
|
|
271
|
+
};
|
|
272
|
+
updatedAt: {
|
|
273
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
274
|
+
isOptional: true;
|
|
275
|
+
};
|
|
276
|
+
}>, undefined>;
|
|
277
|
+
declare const DeleteIntegrationConnection: ContractSpec<SchemaModel<{
|
|
278
|
+
connectionId: {
|
|
279
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
280
|
+
isOptional: false;
|
|
281
|
+
};
|
|
282
|
+
}>, SchemaModel<{
|
|
283
|
+
success: {
|
|
284
|
+
type: _lssm_lib_schema461.FieldType<boolean, boolean>;
|
|
285
|
+
isOptional: false;
|
|
286
|
+
};
|
|
287
|
+
}>, undefined>;
|
|
288
|
+
declare const ListIntegrationConnections: ContractSpec<SchemaModel<{
|
|
289
|
+
tenantId: {
|
|
290
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
291
|
+
isOptional: false;
|
|
292
|
+
};
|
|
293
|
+
category: {
|
|
294
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
295
|
+
isOptional: true;
|
|
296
|
+
};
|
|
297
|
+
status: {
|
|
298
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
299
|
+
isOptional: true;
|
|
300
|
+
};
|
|
301
|
+
}>, SchemaModel<{
|
|
302
|
+
connections: {
|
|
303
|
+
type: SchemaModel<{
|
|
304
|
+
id: {
|
|
305
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
306
|
+
isOptional: false;
|
|
307
|
+
};
|
|
308
|
+
tenantId: {
|
|
309
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
310
|
+
isOptional: false;
|
|
311
|
+
};
|
|
312
|
+
integrationKey: {
|
|
313
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
314
|
+
isOptional: false;
|
|
315
|
+
};
|
|
316
|
+
integrationVersion: {
|
|
317
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
318
|
+
isOptional: false;
|
|
319
|
+
};
|
|
320
|
+
label: {
|
|
321
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
322
|
+
isOptional: false;
|
|
323
|
+
};
|
|
324
|
+
ownershipMode: {
|
|
325
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
326
|
+
isOptional: false;
|
|
327
|
+
};
|
|
328
|
+
externalAccountId: {
|
|
329
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
330
|
+
isOptional: true;
|
|
331
|
+
};
|
|
332
|
+
secretProvider: {
|
|
333
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
334
|
+
isOptional: false;
|
|
335
|
+
};
|
|
336
|
+
secretRef: {
|
|
337
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
338
|
+
isOptional: false;
|
|
339
|
+
};
|
|
340
|
+
status: {
|
|
341
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
342
|
+
isOptional: false;
|
|
343
|
+
};
|
|
344
|
+
environment: {
|
|
345
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
346
|
+
isOptional: true;
|
|
347
|
+
};
|
|
348
|
+
healthStatus: {
|
|
349
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
350
|
+
isOptional: true;
|
|
351
|
+
};
|
|
352
|
+
healthCheckedAt: {
|
|
353
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
354
|
+
isOptional: true;
|
|
355
|
+
};
|
|
356
|
+
healthLatencyMs: {
|
|
357
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
358
|
+
isOptional: true;
|
|
359
|
+
};
|
|
360
|
+
healthErrorCode: {
|
|
361
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
362
|
+
isOptional: true;
|
|
363
|
+
};
|
|
364
|
+
healthErrorMessage: {
|
|
365
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
366
|
+
isOptional: true;
|
|
367
|
+
};
|
|
368
|
+
usageRequestCount: {
|
|
369
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
370
|
+
isOptional: true;
|
|
371
|
+
};
|
|
372
|
+
usageSuccessCount: {
|
|
373
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
374
|
+
isOptional: true;
|
|
375
|
+
};
|
|
376
|
+
usageErrorCount: {
|
|
377
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
378
|
+
isOptional: true;
|
|
379
|
+
};
|
|
380
|
+
usageLastUsedAt: {
|
|
381
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
382
|
+
isOptional: true;
|
|
383
|
+
};
|
|
384
|
+
usageLastErrorAt: {
|
|
385
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
386
|
+
isOptional: true;
|
|
387
|
+
};
|
|
388
|
+
usageLastErrorCode: {
|
|
389
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
390
|
+
isOptional: true;
|
|
391
|
+
};
|
|
392
|
+
createdAt: {
|
|
393
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
394
|
+
isOptional: true;
|
|
395
|
+
};
|
|
396
|
+
updatedAt: {
|
|
397
|
+
type: _lssm_lib_schema461.FieldType<Date, string>;
|
|
398
|
+
isOptional: true;
|
|
399
|
+
};
|
|
400
|
+
}>;
|
|
401
|
+
isOptional: false;
|
|
402
|
+
isArray: true;
|
|
403
|
+
};
|
|
404
|
+
}>, undefined>;
|
|
405
|
+
declare const TestIntegrationConnection: ContractSpec<SchemaModel<{
|
|
406
|
+
connectionId: {
|
|
407
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
408
|
+
isOptional: false;
|
|
409
|
+
};
|
|
410
|
+
}>, SchemaModel<{
|
|
411
|
+
success: {
|
|
412
|
+
type: _lssm_lib_schema461.FieldType<boolean, boolean>;
|
|
413
|
+
isOptional: false;
|
|
414
|
+
};
|
|
415
|
+
status: {
|
|
416
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
417
|
+
isOptional: true;
|
|
418
|
+
};
|
|
419
|
+
latencyMs: {
|
|
420
|
+
type: _lssm_lib_schema461.FieldType<number, number>;
|
|
421
|
+
isOptional: true;
|
|
422
|
+
};
|
|
423
|
+
error: {
|
|
424
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
425
|
+
isOptional: true;
|
|
426
|
+
};
|
|
427
|
+
errorCode: {
|
|
428
|
+
type: _lssm_lib_schema461.FieldType<string, string>;
|
|
429
|
+
isOptional: true;
|
|
430
|
+
};
|
|
431
|
+
}>, undefined>;
|
|
432
|
+
declare const integrationContracts: Record<string, ContractSpec<any, any>>;
|
|
433
|
+
declare function registerIntegrationContracts(registry: SpecRegistry): SpecRegistry;
|
|
434
|
+
//#endregion
|
|
435
|
+
export { CreateIntegrationConnection, DeleteIntegrationConnection, ListIntegrationConnections, TestIntegrationConnection, UpdateIntegrationConnection, integrationContracts, registerIntegrationContracts };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { IntegrationConnectionHealth } from "./connection.js";
|
|
2
|
+
import { IntegrationContext, IntegrationTelemetryEmitter } from "./runtime.js";
|
|
3
|
+
|
|
4
|
+
//#region src/integrations/health.d.ts
|
|
5
|
+
interface IntegrationHealthCheckResult extends IntegrationConnectionHealth {
|
|
6
|
+
metadata?: Record<string, string>;
|
|
7
|
+
}
|
|
8
|
+
type IntegrationHealthCheckExecutor = (context: IntegrationContext) => Promise<void>;
|
|
9
|
+
interface IntegrationHealthServiceOptions {
|
|
10
|
+
telemetry?: IntegrationTelemetryEmitter;
|
|
11
|
+
now?: () => Date;
|
|
12
|
+
}
|
|
13
|
+
declare class IntegrationHealthService {
|
|
14
|
+
private readonly telemetry?;
|
|
15
|
+
private readonly nowFn;
|
|
16
|
+
constructor(options?: IntegrationHealthServiceOptions);
|
|
17
|
+
check(context: IntegrationContext, executor: IntegrationHealthCheckExecutor): Promise<IntegrationHealthCheckResult>;
|
|
18
|
+
private emitTelemetry;
|
|
19
|
+
}
|
|
20
|
+
//#endregion
|
|
21
|
+
export { IntegrationHealthCheckExecutor, IntegrationHealthCheckResult, IntegrationHealthService, IntegrationHealthServiceOptions };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { IntegrationByokSetup, IntegrationCapabilityMapping, IntegrationCategory, IntegrationConfigSchema, IntegrationHealthCheck, IntegrationMeta, IntegrationOwnershipMode, IntegrationSecretSchema, IntegrationSpec, IntegrationSpecRegistry, makeIntegrationSpecKey } from "./spec.js";
|
|
2
|
+
import { ConnectionStatus, IntegrationConnection, IntegrationConnectionHealth, IntegrationConnectionMeta, IntegrationUsageMetrics } from "./connection.js";
|
|
3
|
+
import { AppIntegrationBinding } from "./binding.js";
|
|
4
|
+
import { CapturePaymentInput, CreateCustomerInput, CreatePaymentIntentInput, ListInvoicesQuery, ListTransactionsQuery, Money, PaymentCustomer, PaymentIntent, PaymentIntentStatus, PaymentInvoice, PaymentRefund, PaymentTransaction, PaymentsProvider, RefundPaymentInput } from "./providers/payments.js";
|
|
5
|
+
import { LLMChatOptions, LLMContentPart, LLMMessage, LLMProvider, LLMResponse, LLMRole, LLMStreamChunk, LLMTextPart, LLMTokenUsage, LLMToolCallPart, LLMToolDefinition, LLMToolResultPart, TokenCountResult } from "./providers/llm.js";
|
|
6
|
+
import { EmbeddingDocument, EmbeddingProvider, EmbeddingResult, EmbeddingVector } from "./providers/embedding.js";
|
|
7
|
+
import { VectorDeleteRequest, VectorDocument, VectorSearchQuery, VectorSearchResult, VectorStoreProvider, VectorUpsertRequest } from "./providers/vector-store.js";
|
|
8
|
+
import { EmailAddress, EmailAttachment, EmailInboundProvider, EmailMessage, EmailMessagesSinceQuery, EmailOutboundMessage, EmailOutboundProvider, EmailOutboundResult, EmailThread, EmailThreadListQuery } from "./providers/email.js";
|
|
9
|
+
import { CalendarAttendee, CalendarEvent, CalendarEventInput, CalendarEventUpdateInput, CalendarListEventsQuery, CalendarListEventsResult, CalendarProvider, CalendarReminder } from "./providers/calendar.js";
|
|
10
|
+
import { SendSmsInput, SmsDeliveryStatus, SmsMessage, SmsProvider } from "./providers/sms.js";
|
|
11
|
+
import { Voice, VoiceProvider, VoiceSynthesisInput, VoiceSynthesisResult } from "./providers/voice.js";
|
|
12
|
+
import { DeleteObjectInput, GetObjectResult, ListObjectsQuery, ListObjectsResult, ObjectStorageProvider, PutObjectInput, SignedUrlOptions, StorageObjectBody, StorageObjectMetadata } from "./providers/storage.js";
|
|
13
|
+
import { registerStripeIntegration, stripeIntegrationSpec } from "./providers/stripe.js";
|
|
14
|
+
import { postmarkIntegrationSpec, registerPostmarkIntegration } from "./providers/postmark.js";
|
|
15
|
+
import { qdrantIntegrationSpec, registerQdrantIntegration } from "./providers/qdrant.js";
|
|
16
|
+
import { mistralIntegrationSpec, registerMistralIntegration } from "./providers/mistral.js";
|
|
17
|
+
import { elevenLabsIntegrationSpec, registerElevenLabsIntegration } from "./providers/elevenlabs.js";
|
|
18
|
+
import { gmailIntegrationSpec, registerGmailIntegration } from "./providers/gmail.js";
|
|
19
|
+
import { googleCalendarIntegrationSpec, registerGoogleCalendarIntegration } from "./providers/google-calendar.js";
|
|
20
|
+
import { registerTwilioSmsIntegration, twilioSmsIntegrationSpec } from "./providers/twilio-sms.js";
|
|
21
|
+
import { gcsStorageIntegrationSpec, registerGcsStorageIntegration } from "./providers/gcs-storage.js";
|
|
22
|
+
import { powensIntegrationSpec, registerPowensIntegration } from "./providers/powens.js";
|
|
23
|
+
import { OpenBankingAccountBalance, OpenBankingAccountDetails, OpenBankingAccountOwnership, OpenBankingAccountSummary, OpenBankingBalanceType, OpenBankingConnectionStatus, OpenBankingGetAccountDetailsParams, OpenBankingGetBalancesParams, OpenBankingGetConnectionStatusParams, OpenBankingListAccountsParams, OpenBankingListAccountsResult, OpenBankingListTransactionsParams, OpenBankingListTransactionsResult, OpenBankingProvider, OpenBankingTransaction } from "./providers/openbanking.js";
|
|
24
|
+
import { createDefaultIntegrationSpecRegistry } from "./providers/registry.js";
|
|
25
|
+
import "./providers/index.js";
|
|
26
|
+
import { AccountBalanceRecord, BankAccountRecord, BankTransactionRecord } from "./openbanking/models.js";
|
|
27
|
+
import { OpenBankingGetAccount, OpenBankingListAccounts, OpenBankingSyncAccounts } from "./openbanking/contracts/accounts.js";
|
|
28
|
+
import { OpenBankingListTransactions, OpenBankingSyncTransactions } from "./openbanking/contracts/transactions.js";
|
|
29
|
+
import { OpenBankingGetBalances, OpenBankingRefreshBalances } from "./openbanking/contracts/balances.js";
|
|
30
|
+
import { OpenBankingFeature } from "./openbanking/openbanking.feature.js";
|
|
31
|
+
import { registerOpenBankingContracts } from "./openbanking/contracts/index.js";
|
|
32
|
+
import { OpenBankingGuardResult, assertPrimaryOpenBankingReady, ensurePrimaryOpenBankingIntegration } from "./openbanking/guards.js";
|
|
33
|
+
import { OPENBANKING_PII_FIELDS, OPENBANKING_TELEMETRY_EVENTS, OpenBankingTelemetryEvent, redactOpenBankingTelemetryPayload } from "./openbanking/telemetry.js";
|
|
34
|
+
export { AccountBalanceRecord, AppIntegrationBinding, BankAccountRecord, BankTransactionRecord, CalendarAttendee, CalendarEvent, CalendarEventInput, CalendarEventUpdateInput, CalendarListEventsQuery, CalendarListEventsResult, CalendarProvider, CalendarReminder, CapturePaymentInput, ConnectionStatus, CreateCustomerInput, CreatePaymentIntentInput, DeleteObjectInput, EmailAddress, EmailAttachment, EmailInboundProvider, EmailMessage, EmailMessagesSinceQuery, EmailOutboundMessage, EmailOutboundProvider, EmailOutboundResult, EmailThread, EmailThreadListQuery, EmbeddingDocument, EmbeddingProvider, EmbeddingResult, EmbeddingVector, GetObjectResult, IntegrationByokSetup, IntegrationCapabilityMapping, IntegrationCategory, IntegrationConfigSchema, IntegrationConnection, IntegrationConnectionHealth, IntegrationConnectionMeta, IntegrationHealthCheck, IntegrationMeta, IntegrationOwnershipMode, IntegrationSecretSchema, IntegrationSpec, IntegrationSpecRegistry, IntegrationUsageMetrics, LLMChatOptions, LLMContentPart, LLMMessage, LLMProvider, LLMResponse, LLMRole, LLMStreamChunk, LLMTextPart, LLMTokenUsage, LLMToolCallPart, LLMToolDefinition, LLMToolResultPart, ListInvoicesQuery, ListObjectsQuery, ListObjectsResult, ListTransactionsQuery, Money, OPENBANKING_PII_FIELDS, OPENBANKING_TELEMETRY_EVENTS, ObjectStorageProvider, OpenBankingAccountBalance, OpenBankingAccountDetails, OpenBankingAccountOwnership, OpenBankingAccountSummary, OpenBankingBalanceType, OpenBankingConnectionStatus, OpenBankingFeature, OpenBankingGetAccount, OpenBankingGetAccountDetailsParams, OpenBankingGetBalances, OpenBankingGetBalancesParams, OpenBankingGetConnectionStatusParams, OpenBankingGuardResult, OpenBankingListAccounts, OpenBankingListAccountsParams, OpenBankingListAccountsResult, OpenBankingListTransactions, OpenBankingListTransactionsParams, OpenBankingListTransactionsResult, OpenBankingProvider, OpenBankingRefreshBalances, OpenBankingSyncAccounts, OpenBankingSyncTransactions, OpenBankingTelemetryEvent, OpenBankingTransaction, PaymentCustomer, PaymentIntent, PaymentIntentStatus, PaymentInvoice, PaymentRefund, PaymentTransaction, PaymentsProvider, PutObjectInput, RefundPaymentInput, SendSmsInput, SignedUrlOptions, SmsDeliveryStatus, SmsMessage, SmsProvider, StorageObjectBody, StorageObjectMetadata, TokenCountResult, VectorDeleteRequest, VectorDocument, VectorSearchQuery, VectorSearchResult, VectorStoreProvider, VectorUpsertRequest, Voice, VoiceProvider, VoiceSynthesisInput, VoiceSynthesisResult, assertPrimaryOpenBankingReady, createDefaultIntegrationSpecRegistry, elevenLabsIntegrationSpec, ensurePrimaryOpenBankingIntegration, gcsStorageIntegrationSpec, gmailIntegrationSpec, googleCalendarIntegrationSpec, makeIntegrationSpecKey, mistralIntegrationSpec, postmarkIntegrationSpec, powensIntegrationSpec, qdrantIntegrationSpec, redactOpenBankingTelemetryPayload, registerElevenLabsIntegration, registerGcsStorageIntegration, registerGmailIntegration, registerGoogleCalendarIntegration, registerMistralIntegration, registerOpenBankingContracts, registerPostmarkIntegration, registerPowensIntegration, registerQdrantIntegration, registerStripeIntegration, registerTwilioSmsIntegration, stripeIntegrationSpec, twilioSmsIntegrationSpec };
|