@collective-intelligence/extensions-sdk 0.1.4 → 0.1.6
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 +206 -5
- package/dist/components/authoring-core.d.ts +2 -2
- package/dist/components/base.d.ts +1 -1
- package/dist/components/connectors.d.ts +59 -0
- package/dist/components/declaration.d.ts +3 -2
- package/dist/components/executable-authoring.d.ts +13 -1
- package/dist/components/external-application.d.ts +37 -2
- package/dist/components/knowledge.d.ts +30 -0
- package/dist/components/messaging.d.ts +128 -0
- package/dist/components/metadata-authoring.d.ts +22 -3
- package/dist/components/organization-group.d.ts +38 -0
- package/dist/components/workflows.d.ts +7 -0
- package/dist/index.d.ts +8 -4
- package/dist/index.js +1 -1
- package/dist/package/definition.d.ts +3 -3
- package/dist/package/primitive-readers.d.ts +51 -0
- package/package.json +1 -1
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import type { PackageCodecSource, PackageDecoderSource } from "../schema/source.js";
|
|
2
|
-
import type { ClassDeclaration, ClassDeclaredComponent, ComponentManifest, ComponentPresentation, DeclaredComponent, DecoderSource, MetadataComponentManifest } from "./authoring-core.js";
|
|
2
|
+
import type { ClassDeclaration, ClassDeclaredComponent, ComponentManifest, ComponentPresentation, DeclarationReference, DeclaredComponent, DecoderSource, MetadataComponentManifest } from "./authoring-core.js";
|
|
3
3
|
import type { DomainDeclaration, DomainTemplateDeclaration, SkillTemplateDeclaration } from "./catalog.js";
|
|
4
4
|
import type { KnowledgeConnectorInstanceDeclaration, DatasetConnectorInstanceDeclaration } from "./connector-instances.js";
|
|
5
5
|
import type { DatasetParserDeclaration, ExternalDatasetProviderDeclaration, ManagedDatasetProviderDeclaration } from "./connectors.js";
|
|
6
6
|
import type { DatasetParserImplementation } from "./dataset-parser.js";
|
|
7
7
|
import type { ExternalDatasetProviderImplementation, ManagedDatasetProviderImplementation } from "./datasets.js";
|
|
8
8
|
import type { ExternalAppGatewayDeclaration } from "./external-app-gateway.js";
|
|
9
|
-
import type { ExternalApplicationDeclaration } from "./external-application.js";
|
|
9
|
+
import type { ExternalApplicationDeclaration, ExternalApplicationRole } from "./external-application.js";
|
|
10
10
|
import type { KnowledgeEntitySchemaDeclaration, KnowledgePolicyDeclaration, KnowledgeRelationSchemaDeclaration } from "./knowledge.js";
|
|
11
11
|
import type { LifecycleOptions } from "./lifecycle.js";
|
|
12
|
+
import type { OrganizationGroupDeclaration } from "./organization-group.js";
|
|
12
13
|
import type { StudioAppDeclaration, StudioComponentDeclaration } from "./studio.js";
|
|
13
14
|
import type { RemoteToolCollectionDeclaration, RemoteToolCollectionDefinition, ToolCollectionDeclaration } from "./tools.js";
|
|
14
15
|
import type { WorkflowDeclaration, WorkflowFieldCollectionDeclaration, WorkflowNodeCollectionDeclaration, WorkflowTemplateDeclaration, WorkflowTemplateGraphDefinition } from "./workflows.js";
|
|
@@ -26,7 +27,25 @@ export declare const declareExternalDatasetProvider: <Constructor extends new ()
|
|
|
26
27
|
export type DatasetParserClassDeclaration<Constructor extends new () => DatasetParserImplementation = new () => DatasetParserImplementation> = ClassDeclaration<DatasetParserDeclaration, Constructor>;
|
|
27
28
|
export declare const declareDatasetParser: <Constructor extends new () => DatasetParserImplementation>(input: DatasetParserClassDeclaration<Constructor>) => ClassDeclaredComponent<DatasetParserDeclaration, Constructor>;
|
|
28
29
|
export declare const declareDomainTemplate: (input: MetadataClassDeclaration<DomainTemplateDeclaration>) => DeclaredComponent<DomainTemplateDeclaration>;
|
|
29
|
-
|
|
30
|
+
type ExternalApplicationDefinitionInput<Key extends string> = Omit<MetadataDefinition<ExternalApplicationDeclaration>, "grants" | "roles"> & Readonly<{
|
|
31
|
+
grants?: readonly Readonly<{
|
|
32
|
+
group: DeclarationReference<"organizationGroup">;
|
|
33
|
+
lifecycle: LifecycleOptions;
|
|
34
|
+
role: NoInfer<Key>;
|
|
35
|
+
}>[];
|
|
36
|
+
roles?: readonly ExternalApplicationRole<Key>[];
|
|
37
|
+
}>;
|
|
38
|
+
/**
|
|
39
|
+
* Declares an external application. `Key` is inferred from the `key` of each
|
|
40
|
+
* declared role, so `parent` and the `role` of a Grant accept only a declared
|
|
41
|
+
* role key.
|
|
42
|
+
*/
|
|
43
|
+
export declare const declareExternalApplication: <Key extends string>(input: MetadataClassDeclaration<ExternalApplicationDeclaration, ExternalApplicationDefinitionInput<Key>>) => DeclaredComponent<ExternalApplicationDeclaration>;
|
|
44
|
+
type OrganizationGroupDefinitionInput = Omit<MetadataDefinition<OrganizationGroupDeclaration>, "parent"> & Readonly<{
|
|
45
|
+
parent?: DeclarationReference<"organizationGroup">;
|
|
46
|
+
}>;
|
|
47
|
+
/** Declares a Group Tree materialized by package install. */
|
|
48
|
+
export declare const declareOrganizationGroup: (input: MetadataClassDeclaration<OrganizationGroupDeclaration, OrganizationGroupDefinitionInput>) => DeclaredComponent<OrganizationGroupDeclaration>;
|
|
30
49
|
export declare const declareSkillTemplate: (input: MetadataClassDeclaration<SkillTemplateDeclaration>) => DeclaredComponent<SkillTemplateDeclaration>;
|
|
31
50
|
type KnowledgeEntityDefinitionInput<Schema> = Omit<MetadataDefinition<KnowledgeEntitySchemaDeclaration>, "schema"> & Readonly<{
|
|
32
51
|
schema: DecoderSource<Schema>;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import type { PackagePrimitiveBase } from "./base.js";
|
|
2
|
+
import type { LifecycleOptions } from "./lifecycle.js";
|
|
3
|
+
/** A Group below the root of a Group Tree. `key` is one FQN segment. */
|
|
4
|
+
export type OrganizationSubgroup = Readonly<{
|
|
5
|
+
description?: string;
|
|
6
|
+
displayName: string;
|
|
7
|
+
key: string;
|
|
8
|
+
subgroups?: readonly OrganizationSubgroup[];
|
|
9
|
+
}>;
|
|
10
|
+
/**
|
|
11
|
+
* Portable Group Tree: one root Group and its nested subgroups. The tree is
|
|
12
|
+
* one primitive, so every subgroup takes the version and lifecycle of the root.
|
|
13
|
+
*/
|
|
14
|
+
export type OrganizationGroupDeclaration = PackagePrimitiveBase<"organizationGroup"> & Readonly<{
|
|
15
|
+
lifecycle: LifecycleOptions;
|
|
16
|
+
/** FQN of the Group that holds the root, in any package. */
|
|
17
|
+
parent?: string;
|
|
18
|
+
subgroups?: readonly OrganizationSubgroup[];
|
|
19
|
+
}>;
|
|
20
|
+
/** The most characters that the FQN of a Group holds: the host storage limit. */
|
|
21
|
+
export declare const organizationGroupFqnMaxLength = 320;
|
|
22
|
+
/**
|
|
23
|
+
* Shared authoring and serialized admission invariant for subgroup keys and
|
|
24
|
+
* for the length of every Group FQN of the tree.
|
|
25
|
+
*/
|
|
26
|
+
export declare const organizationGroupViolation: ({ fqn, subgroups }: Pick<OrganizationGroupDeclaration, "fqn" | "subgroups">) => string | undefined;
|
|
27
|
+
type OrganizationGroupNode = Readonly<{
|
|
28
|
+
description: string | undefined;
|
|
29
|
+
displayName: string;
|
|
30
|
+
fqn: string;
|
|
31
|
+
parentFqn: string | undefined;
|
|
32
|
+
}>;
|
|
33
|
+
/**
|
|
34
|
+
* Every Group of a Group Tree, parents first. The FQN of a subgroup is the FQN
|
|
35
|
+
* of its parent, a dot, and its `key`; hosts take FQNs from this list only.
|
|
36
|
+
*/
|
|
37
|
+
export declare const organizationGroupNodes: ({ description, displayName, fqn, parent, subgroups }: Pick<OrganizationGroupDeclaration, "description" | "displayName" | "fqn" | "parent" | "subgroups">) => readonly OrganizationGroupNode[];
|
|
38
|
+
export {};
|
|
@@ -193,6 +193,13 @@ export type WorkflowReusableDependencyDeclaration = Readonly<{
|
|
|
193
193
|
export type WorkflowNodeExecutionContract = Readonly<{
|
|
194
194
|
itemModes?: readonly ("all_items" | "each_item" | "single")[];
|
|
195
195
|
mainOutputPort?: string;
|
|
196
|
+
/**
|
|
197
|
+
* `false`: the host never repeats an attempt whose result it does not have
|
|
198
|
+
* (a timeout, a failure of unknown kind), because the call can have reached
|
|
199
|
+
* its target: a sent message, a paid call. Absent, the host can repeat such an attempt when the author
|
|
200
|
+
* set retries.
|
|
201
|
+
*/
|
|
202
|
+
repeatable?: boolean;
|
|
196
203
|
resumable?: boolean;
|
|
197
204
|
sideEffect: "external" | "none" | "read" | "write";
|
|
198
205
|
testable?: boolean;
|
package/dist/index.d.ts
CHANGED
|
@@ -12,13 +12,13 @@ export type { OperationDomainDeclaration, PortableGatewayDeclarations, PortableO
|
|
|
12
12
|
export type { PackageCodec, PackageCodecSource, PackageDecoder, PackageDecoderSource, PackageSchemaDefinition, PackageSchemaIssue, PackageSchemaProjections, PackageSchemaResult, PackageSchemaSource, SchemaDirection, SchemaValue, SchemaWire } from "./schema/source.js";
|
|
13
13
|
export type { JsonSchemaDocument, PackageSchemaProjection, ProjectionFidelity } from "./schema/projection.js";
|
|
14
14
|
export type { ConsumerProfile, ConsumerProfileDiagnostic, ConsumerProfileId } from "./schema/profiles.js";
|
|
15
|
-
export { declareKnowledgeEntityAdapter, declareConnection, declareDocumentsConnector, declareKnowledgeConnector, declareKnowledgeConnectorOAuth, declareEventListener, declareFieldTransformer, declareNotificationChannel, declareKnowledgeRelationAdapter, declareTool, declareToolSettingsOptions, declareWorkflowField, declareOrganizationSso, declareEmailProvider } from "./components/executable-authoring.js";
|
|
15
|
+
export { declareKnowledgeEntityAdapter, declareConnection, declareDocumentsConnector, declareKnowledgeConnector, declareKnowledgeConnectorOAuth, declareEventListener, declareFieldTransformer, declareNotificationChannel, declareKnowledgeRelationAdapter, declareTool, declareToolSettingsOptions, declareWorkflowField, declareOrganizationSso, declareEmailProvider, declareInboundMessagingProvider, declareOutboundMessagingProvider } from "./components/executable-authoring.js";
|
|
16
16
|
export { declareWorkflowNode } from "./components/workflow-node-authoring.js";
|
|
17
17
|
export { resolveWorkflowNodePorts, WorkflowPortIssueCodes } from "./components/workflow-ports.js";
|
|
18
18
|
export type { WorkflowNodePortsContract, WorkflowPortIssue, WorkflowPortIssueCode, WorkflowResolvedPorts } from "./components/workflow-ports.js";
|
|
19
19
|
export { workflowSchemaAt } from "./components/workflow-schema.js";
|
|
20
20
|
export type { WorkflowSchemaLocation } from "./components/workflow-schema.js";
|
|
21
|
-
export { declareDatasetParser, declareDomain, declareDomainTemplate, declareExternalApplication, declareExternalAppGateway, declareExternalDatasetProvider, declareKnowledgeEntitySchema, declareKnowledgePolicy, declareKnowledgeRelationSchema, declareManagedDatasetProvider, declareRemoteToolCollection, declareSkillTemplate, declareStudioApp, declareStudioComponent, declareToolCollection, declareWorkflow, declareWorkflowFieldCollection, declareWorkflowNodeCollection, declareWorkflowTemplate } from "./components/metadata-authoring.js";
|
|
21
|
+
export { declareDatasetParser, declareDomain, declareDomainTemplate, declareExternalApplication, declareExternalAppGateway, declareExternalDatasetProvider, declareKnowledgeEntitySchema, declareKnowledgePolicy, declareKnowledgeRelationSchema, declareManagedDatasetProvider, declareOrganizationGroup, declareRemoteToolCollection, declareSkillTemplate, declareStudioApp, declareStudioComponent, declareToolCollection, declareWorkflow, declareWorkflowFieldCollection, declareWorkflowNodeCollection, declareWorkflowTemplate } from "./components/metadata-authoring.js";
|
|
22
22
|
export { DATASET_TABLE_TEMPLATE_PHYSICAL_CODES, DATASET_TABLE_TEMPLATE_SEMANTIC_ROLES, declareDatasetBlueprint, declareDatasetTableTemplate, rejectUnsupportedDatasetTableTemplate } from "./components/templates.js";
|
|
23
23
|
export { declarePackage } from "./package/definition.js";
|
|
24
24
|
export { normalizeNotificationChannelCapabilities } from "./components/notification-channel-capabilities.js";
|
|
@@ -44,7 +44,10 @@ export type { BuildAttemptResult, ExtensionReleaseArchiveEntry, ExtensionRelease
|
|
|
44
44
|
export type { BindingScope, ConnectionReference, PackagePrimitiveBase, PackagePrimitiveKind } from "./components/base.js";
|
|
45
45
|
export type { LifecycleDeployMode, LifecycleOptions } from "./components/lifecycle.js";
|
|
46
46
|
export type { CatalogTags, DomainDeclaration, DomainTemplateDeclaration, SkillTemplateDeclaration } from "./components/catalog.js";
|
|
47
|
-
export
|
|
47
|
+
export { externalApplicationViolation } from "./components/external-application.js";
|
|
48
|
+
export type { ExternalApplicationDeclaration, ExternalApplicationGrant, ExternalApplicationRole, ExternalApplicationType, ExternalApplicationUserClass } from "./components/external-application.js";
|
|
49
|
+
export { organizationGroupFqnMaxLength, organizationGroupNodes, organizationGroupViolation } from "./components/organization-group.js";
|
|
50
|
+
export type { OrganizationGroupDeclaration, OrganizationSubgroup } from "./components/organization-group.js";
|
|
48
51
|
export { declareAgent, declareSkill, duplicateToolBinding, toolBindingDeclaration } from "./components/agents.js";
|
|
49
52
|
export type { AgentActivityPolicy, AgentAudience, AgentAudienceDeclaration, AgentDeclaration, AgentDefinitionInput, AgentMemberAudience, AgentModelTier, DeclaredToolBindings, KnowledgeScopeSelection, SkillDeclaration, SkillDefinitionInput, ToolBinding, ToolBindingApproval, ToolBindingDeclaration, ToolBindingKnowledgeScope } from "./components/agents.js";
|
|
50
53
|
export type { DocumentsDeltaCursorExpired, DocumentsDeltaItem, DocumentsDeltaPage, DocumentsDeltaRequest, DocumentsDrive, DocumentsDrivesPage, DocumentsFolder, DocumentsFoldersPage, DocumentsFetchedContent, DocumentsRootAncestry, DocumentsSource, KnowledgeEntityAdapterDeclaration, ConnectionDeclaration, DatasetParserDeclaration, ExternalDatasetProviderDeclaration, KnowledgeConnectorContribution, KnowledgeConnectorBindingExtraConfig, KnowledgeConnectorDeclaration, KnowledgeConnectorFieldMapRule, KnowledgeEntitySchemaCapability, KnowledgeConnectorOAuthDeclaration, KnowledgeConnectorOAuthTokens, KnowledgeConnectorRemoteReference, EventListenerDeclaration, EventListenerInternalOccurrence, EventListenerPollRequest, EventListenerPollResult, EventListenerWebhookRequest, KnowledgePredefinedSchedule, ManagedDatasetProviderDeclaration, KnowledgeRelationAdapterDeclaration, KnowledgeRelationSchemaCapability } from "./components/connectors.js";
|
|
@@ -57,7 +60,8 @@ export type { JsonObject, JsonPrimitive, JsonValue } from "./foundation/json.js"
|
|
|
57
60
|
export type { Bounds, Compatibility, ConnectorContext, DatasetAggregateOperation, DatasetBindingMode, DatasetDefinition, DatasetDeleteInput, DatasetDeleteResult, DatasetHealth, DatasetIngestInput, DatasetIngestMode, DatasetIngestResult, DatasetInspectInput, DatasetInspectResult, DatasetFilter, DatasetOperation, DatasetOrder, DatasetPredicate, DatasetPredicateOperator, DatasetQueryIntent, DatasetTimeBucket, DatasetProviderCapabilities, DatasetProviderError, DatasetProviderResult, DatasetProvisionInput, DatasetProvisionResult, DatasetRecordPage, DatasetResultPage, DatasetScalarType, DatasetSourceItem, DatasetSourceLocation, DatasetValue, DefinitionProposal, DiscoverDefinitionInput, ExternalDatasetBinding, ListSourcesInput, QueryInput, Readiness, ReadinessInput, SafeDiagnostic, SourcePage } from "./components/datasets.js";
|
|
58
61
|
export type { DatasetParserAnalysis, DatasetParserColumnType, DatasetParserDefinition, DatasetParserDiagnostic, DatasetParserError, DatasetParserField, DatasetParserInput, DatasetParserRecord, DatasetParserRecordValue, DatasetParserRecords, DatasetParserRecordsInput, DatasetParserResult } from "./components/dataset-parser.js";
|
|
59
62
|
export type { DatasetParserClassDeclaration, ExternalDatasetProviderClassDeclaration, ManagedDatasetProviderClassDeclaration } from "./components/metadata-authoring.js";
|
|
60
|
-
export type { EmailProviderDeclaration, OrganizationSsoDeclaration } from "./components/connectors.js";
|
|
63
|
+
export type { EmailProviderDeclaration, InboundMessagingProviderDefinition, OrganizationSsoDeclaration, OutboundMessagingProviderDeclaration } from "./components/connectors.js";
|
|
64
|
+
export type { ConversationReference, InboundAttachment, InboundMessage, MessageReceipt, OutboundMessage } from "./components/messaging.js";
|
|
61
65
|
export { parsePackageManifest } from "./package/parse-manifest.js";
|
|
62
66
|
export { WorkflowEditorWidgets, WorkflowTemplateKinds, WorkflowTriggerLifecycleAdapterIds } from "./components/workflows.js";
|
|
63
67
|
export { parseWorkflowTriggerActivation } from "./package/workflow-readers.js";
|