Skip to content

@codesoul-co/hypha-mcp / catalog

Using this module

Use the Catalog module for registering and resolving versioned capabilities or implementations. It exports 6 classes, 4 constants, 1 function, 11 interfaces, 2 types.

Import from the package entrypoint

ts
import {
  InMemoryMCPCapabilityCatalogStore,
  InMemoryToolContractSnapshotStore,
  MCPCapabilityCatalog,
  MCPSchemaCache,
  RedisMCPCapabilityCatalogStore,
  RedisToolContractSnapshotStore,
  mcpCapabilityRecordDefinition,
  mcpCapabilityRecordExample,
} from '@codesoul-co/hypha-mcp';

import type {
  MCPCapabilityApprovalRequest,
  MCPCapabilityCatalogOptions,
  MCPCapabilityCatalogStore,
  MCPCapabilityListRequest,
  MCPCapabilityQuarantineRequest,
  MCPCapabilityRecord,
  MCPCapabilityRef,
  MCPCatalogSnapshot,
} from '@codesoul-co/hypha-mcp';

// The complete export list is documented below.

Usage patterns

  • Use the 13 type/interface exports as static contracts in application code, adapters, or tests. Import them with import type; they do not exist at runtime.
  • The module exposes 6 classes as constructable runtime implementations. Each symbol entry lists its constructor and public methods.
  • The module exposes 1 function as direct operation entrypoints. Every overload, required/optional parameter, and return type is documented below.
  • The 4 constant/enum exports provide stable values, schemas, definitions, or defaults. Reuse these exports instead of copying internal values into an application.

Public exports

SymbolKindSignatureDescription
InMemoryMCPCapabilityCatalogStoreclassnew InMemoryMCPCapabilityCatalogStore(): InMemoryMCPCapabilityCatalogStoreIn Memory MCP Capability Catalog Store class with 3 public constructor or member entries; its exact declarations are listed below.
InMemoryToolContractSnapshotStoreclassnew InMemoryToolContractSnapshotStore(): InMemoryToolContractSnapshotStoreIn Memory Tool Contract Snapshot Store class with 3 public constructor or member entries; its exact declarations are listed below.
MCPCapabilityCatalogclassnew MCPCapabilityCatalog(options: MCPCapabilityCatalogOptions): MCPCapabilityCatalogMCP Capability Catalog class with 10 public constructor or member entries; its exact declarations are listed below.
MCPSchemaCacheclassnew MCPSchemaCache(options?: MCPSchemaCacheOptions): MCPSchemaCacheMCP Schema Cache class with 5 public constructor or member entries; its exact declarations are listed below.
RedisMCPCapabilityCatalogStoreclassnew RedisMCPCapabilityCatalogStore(client: RedisLikeMCPStoreClient, namespace?: string): RedisMCPCapabilityCatalogStoreMulti-worker catalog store. Redis key operations are idempotent per capability id.
RedisToolContractSnapshotStoreclassnew RedisToolContractSnapshotStore(client: Pick<RedisLikeMCPStoreClient, "get" | "set">, namespace?: string): RedisToolContractSnapshotStoreRedis Tool Contract Snapshot Store class with 3 public constructor or member entries; its exact declarations are listed below.
mcpCapabilityRecordDefinitionconstantconst mcpCapabilityRecordDefinition: SpecSchemaDefinition<MCPCapabilityRecord>MCP Capability Record Definition constant exported by the catalog module.
mcpCapabilityRecordExampleconstantconst mcpCapabilityRecordExample: MCPCapabilityRecordValid example value for MCP Capability Record.
mcpCapabilityRecordJsonSchemaconstantconst mcpCapabilityRecordJsonSchema: JsonSchemaJSON Schema for MCP Capability Record.
mcpCapabilityRecordSchemaconstantconst mcpCapabilityRecordSchema: ZodType<MCPCapabilityRecord, ZodTypeDef, MCPCapabilityRecord>Runtime schema for MCP Capability Record.
normalizeMCPToolOutputfunctionnormalizeMCPToolOutput(result: unknown): unknownMCP CallToolResult is a transport envelope. A declared Tool output schema applies to structuredContent, not to the protocol's content/isError fields.
MCPCapabilityApprovalRequestinterfaceinterface MCPCapabilityApprovalRequest extends MCPCapabilityRefMCP Capability Approval Request interface with 8 public fields or methods.
MCPCapabilityCatalogOptionsinterfaceinterface MCPCapabilityCatalogOptionsMCP Capability Catalog Options interface with 10 public fields or methods.
MCPCapabilityCatalogStoreinterfaceinterface MCPCapabilityCatalogStoreMCP Capability Catalog Store interface with 2 public fields or methods.
MCPCapabilityListRequestinterfaceinterface MCPCapabilityListRequestMCP Capability List Request interface with 9 public fields or methods.
MCPCapabilityQuarantineRequestinterfaceinterface MCPCapabilityQuarantineRequest extends MCPCapabilityRefMCP Capability Quarantine Request interface with 5 public fields or methods.
MCPCapabilityRecordinterfaceinterface MCPCapabilityRecordMCP Capability Record interface with 21 public fields or methods.
MCPCapabilityRefinterfaceinterface MCPCapabilityRefMCP Capability Ref interface with 4 public fields or methods.
MCPCatalogSnapshotinterfaceinterface MCPCatalogSnapshotMCP Catalog Snapshot interface with 7 public fields or methods.
MCPSchemaCacheEntryinterfaceinterface MCPSchemaCacheEntryMCP Schema Cache Entry interface with 7 public fields or methods.
MCPSchemaCacheOptionsinterfaceinterface MCPSchemaCacheOptionsMCP Schema Cache Options interface with 2 public fields or methods.
RedisLikeMCPStoreClientinterfaceinterface RedisLikeMCPStoreClientRedis Like MCP Store Client interface with 5 public fields or methods.
MCPCapabilityDriftTypetypetype MCPCapabilityDriftType = 'description_changed' | 'input_schema_changed' | 'output_schema_changed' | 'annotations_changed' | 'capability_added' | 'capability_removed' | 'server_identity_changed' | 'protocol_version_changed'Public type alias for MCP Capability Drift Type; the declaration contains its complete type expression.
MCPCapabilityKindtypetype MCPCapabilityKind = 'tool' | 'resource' | 'prompt'Public type alias for MCP Capability Kind; the declaration contains its complete type expression.

InMemoryMCPCapabilityCatalogStore

In Memory MCP Capability Catalog Store class with 3 public constructor or member entries; its exact declarations are listed below.

  • Kind: class
  • Import: import { InMemoryMCPCapabilityCatalogStore } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class InMemoryMCPCapabilityCatalogStore implements MCPCapabilityCatalogStore {
    list(serverId?: string): Promise<MCPCapabilityRecord[]>;
    save(record: MCPCapabilityRecord, options?: {
            expected?: MCPCapabilityRecord | null;
        }): Promise<boolean>;
}

Public members

MemberKindSignatureDescription
constructorconstructor(): InMemoryMCPCapabilityCatalogStoreCreates an instance of this class.
listmethodlist(serverId?: string): Promise<MCPCapabilityRecord[]>Public method; parameters and return type are shown in the signature.
savemethodsave(record: MCPCapabilityRecord, options?: { expected?: MCPCapabilityRecord | null; }): Promise<boolean>Public method; parameters and return type are shown in the signature.

InMemoryToolContractSnapshotStore

In Memory Tool Contract Snapshot Store class with 3 public constructor or member entries; its exact declarations are listed below.

  • Kind: class
  • Import: import { InMemoryToolContractSnapshotStore } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class InMemoryToolContractSnapshotStore implements ToolContractSnapshotStore {
    get(snapshotId: string): Promise<ToolContractSnapshot | null>;
    save(snapshot: ToolContractSnapshot): Promise<void>;
}

Public members

MemberKindSignatureDescription
constructorconstructor(): InMemoryToolContractSnapshotStoreCreates an instance of this class.
getmethodget(snapshotId: string): Promise<ToolContractSnapshot | null>Public method; parameters and return type are shown in the signature.
savemethodsave(snapshot: ToolContractSnapshot): Promise<void>Public method; parameters and return type are shown in the signature.

MCPCapabilityCatalog

MCP Capability Catalog class with 10 public constructor or member entries; its exact declarations are listed below.

  • Kind: class
  • Import: import { MCPCapabilityCatalog } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class MCPCapabilityCatalog {
    readonly snapshotStore: ToolContractSnapshotStore;
    constructor(options: MCPCapabilityCatalogOptions);
    bindConnectionManager(manager: MCPConnectionManager): () => void;
    refresh(serverId: string, reason?: string): Promise<MCPCatalogSnapshot>;
    getCapability(ref: MCPCapabilityRef): Promise<MCPCapabilityRecord | null>;
    list(request?: MCPCapabilityListRequest): Promise<MCPCapabilityRecord[]>;
    quarantine(request: MCPCapabilityQuarantineRequest): Promise<void>;
    approveRevision(request: MCPCapabilityApprovalRequest): Promise<void>;
    importTools(registry: ToolRegistry, refs: MCPCapabilityRef[], context?: Partial<ToolCallContext>): Promise<ToolSpec[]>;
    snapshot(runId: string, refs: MCPCapabilityRef[]): Promise<ToolContractSnapshot>;
}

Public members

MemberKindSignatureDescription
approveRevisionmethodapproveRevision(request: MCPCapabilityApprovalRequest): Promise<void>Public method; parameters and return type are shown in the signature.
bindConnectionManagermethodbindConnectionManager(manager: MCPConnectionManager): () => voidPublic method; parameters and return type are shown in the signature.
constructorconstructor(options: MCPCapabilityCatalogOptions): MCPCapabilityCatalogCreates an instance of this class.
getCapabilitymethodgetCapability(ref: MCPCapabilityRef): Promise<MCPCapabilityRecord | null>Public method; parameters and return type are shown in the signature.
importToolsmethodimportTools(registry: ToolRegistry, refs: MCPCapabilityRef[], context?: Partial<ToolCallContext>): Promise<ToolSpec[]>Public method; parameters and return type are shown in the signature.
listmethodlist(request?: MCPCapabilityListRequest): Promise<MCPCapabilityRecord[]>Public method; parameters and return type are shown in the signature.
quarantinemethodquarantine(request: MCPCapabilityQuarantineRequest): Promise<void>Public method; parameters and return type are shown in the signature.
refreshmethodrefresh(serverId: string, reason?: string): Promise<MCPCatalogSnapshot>Public method; parameters and return type are shown in the signature.
snapshotmethodsnapshot(runId: string, refs: MCPCapabilityRef[]): Promise<ToolContractSnapshot>Public method; parameters and return type are shown in the signature.
snapshotStorepropertyreadonly snapshotStore: ToolContractSnapshotStorePublic property; its type, readonly modifier and optionality are shown in the signature.

MCPSchemaCache

MCP Schema Cache class with 5 public constructor or member entries; its exact declarations are listed below.

  • Kind: class
  • Import: import { MCPSchemaCache } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class MCPSchemaCache {
    constructor(options?: MCPSchemaCacheOptions);
    get(ref: MCPCapabilityRef & {
            protocolVersion?: string;
        }): MCPSchemaCacheEntry | null;
    set(record: MCPCapabilityRecord): MCPSchemaCacheEntry;
    invalidate(serverId: string, capabilityId?: string): number;
    size(): number;
}

Public members

MemberKindSignatureDescription
constructorconstructor(options?: MCPSchemaCacheOptions): MCPSchemaCacheCreates an instance of this class.
getmethodget(ref: MCPCapabilityRef & { protocolVersion?: string; }): MCPSchemaCacheEntry | nullPublic method; parameters and return type are shown in the signature.
invalidatemethodinvalidate(serverId: string, capabilityId?: string): numberPublic method; parameters and return type are shown in the signature.
setmethodset(record: MCPCapabilityRecord): MCPSchemaCacheEntryPublic method; parameters and return type are shown in the signature.
sizemethodsize(): numberPublic method; parameters and return type are shown in the signature.

RedisMCPCapabilityCatalogStore

Multi-worker catalog store. Redis key operations are idempotent per capability id.

  • Kind: class
  • Import: import { RedisMCPCapabilityCatalogStore } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class RedisMCPCapabilityCatalogStore implements MCPCapabilityCatalogStore {
    constructor(client: RedisLikeMCPStoreClient, namespace?: string);
    list(serverId?: string): Promise<MCPCapabilityRecord[]>;
    save(record: MCPCapabilityRecord, options?: {
            expected?: MCPCapabilityRecord | null;
        }): Promise<boolean>;
}

Public members

MemberKindSignatureDescription
constructorconstructor(client: RedisLikeMCPStoreClient, namespace?: string): RedisMCPCapabilityCatalogStoreCreates an instance of this class.
listmethodlist(serverId?: string): Promise<MCPCapabilityRecord[]>Public method; parameters and return type are shown in the signature.
savemethodsave(record: MCPCapabilityRecord, options?: { expected?: MCPCapabilityRecord | null; }): Promise<boolean>Public method; parameters and return type are shown in the signature.

RedisToolContractSnapshotStore

Redis Tool Contract Snapshot Store class with 3 public constructor or member entries; its exact declarations are listed below.

  • Kind: class
  • Import: import { RedisToolContractSnapshotStore } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare class RedisToolContractSnapshotStore implements ToolContractSnapshotStore {
    constructor(client: Pick<RedisLikeMCPStoreClient, 'get' | 'set'>, namespace?: string);
    get(snapshotId: string): Promise<ToolContractSnapshot | null>;
    save(snapshot: ToolContractSnapshot): Promise<void>;
}

Public members

MemberKindSignatureDescription
constructorconstructor(client: Pick<RedisLikeMCPStoreClient, "get" | "set">, namespace?: string): RedisToolContractSnapshotStoreCreates an instance of this class.
getmethodget(snapshotId: string): Promise<ToolContractSnapshot | null>Public method; parameters and return type are shown in the signature.
savemethodsave(snapshot: ToolContractSnapshot): Promise<void>Public method; parameters and return type are shown in the signature.

mcpCapabilityRecordDefinition

MCP Capability Record Definition constant exported by the catalog module.

  • Kind: constant
  • Import: import { mcpCapabilityRecordDefinition } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare const mcpCapabilityRecordDefinition: SpecSchemaDefinition<MCPCapabilityRecord>;

mcpCapabilityRecordExample

Valid example value for MCP Capability Record.

  • Kind: constant
  • Import: import { mcpCapabilityRecordExample } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare const mcpCapabilityRecordExample: MCPCapabilityRecord;

mcpCapabilityRecordJsonSchema

JSON Schema for MCP Capability Record.

  • Kind: constant
  • Import: import { mcpCapabilityRecordJsonSchema } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare const mcpCapabilityRecordJsonSchema: JsonSchema;

mcpCapabilityRecordSchema

Runtime schema for MCP Capability Record.

  • Kind: constant
  • Import: import { mcpCapabilityRecordSchema } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare const mcpCapabilityRecordSchema: ZodType<MCPCapabilityRecord, ZodTypeDef, MCPCapabilityRecord>;

normalizeMCPToolOutput

MCP CallToolResult is a transport envelope. A declared Tool output schema applies to structuredContent, not to the protocol's content/isError fields.

  • Kind: function
  • Import: import { normalizeMCPToolOutput } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export declare function normalizeMCPToolOutput(result: unknown): unknown;

Call signature

text
normalizeMCPToolOutput(result: unknown): unknown

MCP CallToolResult is a transport envelope. A declared Tool output schema applies to structuredContent, not to the protocol's content/isError fields.

Parameters

ParameterTypeRequiredDescription
resultunknownYesRequired parameter; accepted values are defined by the type column.

Returns

  • Type: unknown
  • Description: The return contract is defined by the type shown above.

MCPCapabilityApprovalRequest

MCP Capability Approval Request interface with 8 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityApprovalRequest } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityApprovalRequest extends MCPCapabilityRef {
    approvedBy: string;
    expiresAt?: string;
    restrictions?: string[];
    sideEffectLevel?: SideEffectLevel;
}

Contract members

MemberKindSignatureDescription
approvedBypropertyapprovedBy: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityHashpropertycapabilityHash?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityIdpropertycapabilityId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
expiresAtpropertyexpiresAt?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
kindpropertykind?: MCPCapabilityKindPublic property; its type, readonly modifier and optionality are shown in the signature.
restrictionspropertyrestrictions?: string[]Public property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
sideEffectLevelpropertysideEffectLevel?: SideEffectLevelPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPCapabilityCatalogOptions

MCP Capability Catalog Options interface with 10 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityCatalogOptions } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityCatalogOptions {
    integration: MCPIntegrationSpec;
    gateway: MCPGateway;
    trustPolicy: MCPTrustPolicySpec;
    driftPolicy: MCPCapabilityDriftPolicySpec;
    store?: MCPCapabilityCatalogStore;
    schemaCache?: MCPSchemaCache;
    snapshotStore?: ToolContractSnapshotStore;
    now?: () => string;
    onEvent?: (type: string, payload: Record<string, unknown>) => Promise<void> | void;
    telemetry?: TelemetryRecorder;
}

Contract members

MemberKindSignatureDescription
driftPolicypropertydriftPolicy: MCPCapabilityDriftPolicySpecPublic property; its type, readonly modifier and optionality are shown in the signature.
gatewaypropertygateway: MCPGatewayPublic property; its type, readonly modifier and optionality are shown in the signature.
integrationpropertyintegration: MCPIntegrationSpecPublic property; its type, readonly modifier and optionality are shown in the signature.
nowmethodnow?(): stringPublic method; parameters and return type are shown in the signature.
onEventmethodonEvent?(type: string, payload: Record<string, unknown>): Promise<void> | voidPublic method; parameters and return type are shown in the signature.
schemaCachepropertyschemaCache?: MCPSchemaCachePublic property; its type, readonly modifier and optionality are shown in the signature.
snapshotStorepropertysnapshotStore?: ToolContractSnapshotStorePublic property; its type, readonly modifier and optionality are shown in the signature.
storepropertystore?: MCPCapabilityCatalogStorePublic property; its type, readonly modifier and optionality are shown in the signature.
telemetrypropertytelemetry?: TelemetryRecorderPublic property; its type, readonly modifier and optionality are shown in the signature.
trustPolicypropertytrustPolicy: MCPTrustPolicySpecPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPCapabilityCatalogStore

MCP Capability Catalog Store interface with 2 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityCatalogStore } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityCatalogStore {
    list(serverId?: string): Promise<MCPCapabilityRecord[]>;
    save(record: MCPCapabilityRecord, options?: {
        expected?: MCPCapabilityRecord | null;
    }): Promise<boolean>;
}

Contract members

MemberKindSignatureDescription
listmethodlist(serverId?: string): Promise<MCPCapabilityRecord[]>Public method; parameters and return type are shown in the signature.
savemethodsave(record: MCPCapabilityRecord, options?: { expected?: MCPCapabilityRecord | null; }): Promise<boolean>Public method; parameters and return type are shown in the signature.

MCPCapabilityListRequest

MCP Capability List Request interface with 9 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityListRequest } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityListRequest {
    serverId?: string;
    kind?: MCPCapabilityKind;
    states?: MCPCapabilityRecord['driftState'][];
    permissionScopes?: string[];
    tags?: string[];
    query?: string;
    loadDescriptors?: boolean;
    schemaTokenBudget?: number;
    limit?: number;
}

Contract members

MemberKindSignatureDescription
kindpropertykind?: MCPCapabilityKindPublic property; its type, readonly modifier and optionality are shown in the signature.
limitpropertylimit?: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
loadDescriptorspropertyloadDescriptors?: booleanPublic property; its type, readonly modifier and optionality are shown in the signature.
permissionScopespropertypermissionScopes?: string[]Public property; its type, readonly modifier and optionality are shown in the signature.
querypropertyquery?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
schemaTokenBudgetpropertyschemaTokenBudget?: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
statespropertystates?: ("quarantined" | "approved" | "changed" | "removed" | "stable" | "new")[]Public property; its type, readonly modifier and optionality are shown in the signature.
tagspropertytags?: string[]Public property; its type, readonly modifier and optionality are shown in the signature.

MCPCapabilityQuarantineRequest

MCP Capability Quarantine Request interface with 5 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityQuarantineRequest } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityQuarantineRequest extends MCPCapabilityRef {
    reason: string;
}

Contract members

MemberKindSignatureDescription
capabilityHashpropertycapabilityHash?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityIdpropertycapabilityId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
kindpropertykind?: MCPCapabilityKindPublic property; its type, readonly modifier and optionality are shown in the signature.
reasonpropertyreason: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPCapabilityRecord

MCP Capability Record interface with 21 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityRecord } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityRecord {
    id: string;
    serverId: string;
    kind: MCPCapabilityKind;
    remoteName: string;
    stableToolId?: string;
    protocolVersion?: string;
    capabilityVersion?: string;
    capabilityHash: string;
    schemaHash?: string;
    descriptorHash: string;
    descriptor: Record<string, unknown>;
    normalizedToolSpec?: ToolSpec;
    trust: MCPCapabilityTrustRecord;
    driftState: 'stable' | 'new' | 'changed' | 'removed' | 'quarantined' | 'approved';
    driftTypes?: MCPCapabilityDriftType[];
    firstSeenAt: string;
    lastSeenAt: string;
    approvedAt?: string;
    approvalExpiresAt?: string;
    removedAt?: string;
    metadata?: Record<string, unknown>;
}

Contract members

MemberKindSignatureDescription
approvalExpiresAtpropertyapprovalExpiresAt?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
approvedAtpropertyapprovedAt?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityHashpropertycapabilityHash: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityVersionpropertycapabilityVersion?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
descriptorpropertydescriptor: Record<string, unknown>Public property; its type, readonly modifier and optionality are shown in the signature.
descriptorHashpropertydescriptorHash: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
driftStatepropertydriftState: "quarantined" | "approved" | "changed" | "removed" | "stable" | "new"Public property; its type, readonly modifier and optionality are shown in the signature.
driftTypespropertydriftTypes?: MCPCapabilityDriftType[]Public property; its type, readonly modifier and optionality are shown in the signature.
firstSeenAtpropertyfirstSeenAt: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
idpropertyid: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
kindpropertykind: MCPCapabilityKindPublic property; its type, readonly modifier and optionality are shown in the signature.
lastSeenAtpropertylastSeenAt: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
metadatapropertymetadata?: Record<string, unknown>Public property; its type, readonly modifier and optionality are shown in the signature.
normalizedToolSpecpropertynormalizedToolSpec?: ToolSpecPublic property; its type, readonly modifier and optionality are shown in the signature.
protocolVersionpropertyprotocolVersion?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
remoteNamepropertyremoteName: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
removedAtpropertyremovedAt?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
schemaHashpropertyschemaHash?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
stableToolIdpropertystableToolId?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
trustpropertytrust: MCPCapabilityTrustRecordPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPCapabilityRef

MCP Capability Ref interface with 4 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCapabilityRef } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCapabilityRef {
    serverId: string;
    capabilityId: string;
    kind?: MCPCapabilityKind;
    capabilityHash?: string;
}

Contract members

MemberKindSignatureDescription
capabilityHashpropertycapabilityHash?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityIdpropertycapabilityId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
kindpropertykind?: MCPCapabilityKindPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPCatalogSnapshot

MCP Catalog Snapshot interface with 7 public fields or methods.

  • Kind: interface
  • Import: import type { MCPCatalogSnapshot } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPCatalogSnapshot {
    id: string;
    serverId: string;
    revision: string;
    createdAt: string;
    reason?: string;
    capabilities: MCPCapabilityRecord[];
    drift: Array<{
        capabilityId: string;
        previousHash?: string;
        currentHash?: string;
        types: MCPCapabilityDriftType[];
    }>;
}

Contract members

MemberKindSignatureDescription
capabilitiespropertycapabilities: MCPCapabilityRecord[]Public property; its type, readonly modifier and optionality are shown in the signature.
createdAtpropertycreatedAt: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
driftpropertydrift: { capabilityId: string; previousHash?: string; currentHash?: string; types: MCPCapabilityDriftType[]; }[]Public property; its type, readonly modifier and optionality are shown in the signature.
idpropertyid: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
reasonpropertyreason?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
revisionpropertyrevision: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPSchemaCacheEntry

MCP Schema Cache Entry interface with 7 public fields or methods.

  • Kind: interface
  • Import: import type { MCPSchemaCacheEntry } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPSchemaCacheEntry {
    key: string;
    serverId: string;
    capabilityId: string;
    capabilityHash: string;
    protocolVersion?: string;
    schema?: JsonSchema;
    cachedAt: string;
}

Contract members

MemberKindSignatureDescription
cachedAtpropertycachedAt: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityHashpropertycapabilityHash: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
capabilityIdpropertycapabilityId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
keypropertykey: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
protocolVersionpropertyprotocolVersion?: stringPublic property; its type, readonly modifier and optionality are shown in the signature.
schemapropertyschema?: JsonSchemaPublic property; its type, readonly modifier and optionality are shown in the signature.
serverIdpropertyserverId: stringPublic property; its type, readonly modifier and optionality are shown in the signature.

MCPSchemaCacheOptions

MCP Schema Cache Options interface with 2 public fields or methods.

  • Kind: interface
  • Import: import type { MCPSchemaCacheOptions } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface MCPSchemaCacheOptions {
    maxEntries?: number;
    now?: () => string;
}

Contract members

MemberKindSignatureDescription
maxEntriespropertymaxEntries?: numberPublic property; its type, readonly modifier and optionality are shown in the signature.
nowmethodnow?(): stringPublic method; parameters and return type are shown in the signature.

RedisLikeMCPStoreClient

Redis Like MCP Store Client interface with 5 public fields or methods.

  • Kind: interface
  • Import: import type { RedisLikeMCPStoreClient } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export interface RedisLikeMCPStoreClient {
    get(key: string): Promise<string | null>;
    set(key: string, value: string): Promise<unknown>;
    sadd(key: string, ...members: string[]): Promise<number>;
    smembers(key: string): Promise<string[]>;
    eval?(script: string, numberOfKeys: number, ...args: Array<string | number>): Promise<number | string | null>;
}

Contract members

MemberKindSignatureDescription
evalmethodeval?(script: string, numberOfKeys: number, ...args: Array<string | number>): Promise<number | string | null>Public method; parameters and return type are shown in the signature.
getmethodget(key: string): Promise<string | null>Public method; parameters and return type are shown in the signature.
saddmethodsadd(key: string, ...members: string[]): Promise<number>Public method; parameters and return type are shown in the signature.
setmethodset(key: string, value: string): Promise<unknown>Public method; parameters and return type are shown in the signature.
smembersmethodsmembers(key: string): Promise<string[]>Public method; parameters and return type are shown in the signature.

MCPCapabilityDriftType

Public type alias for MCP Capability Drift Type; the declaration contains its complete type expression.

  • Kind: type
  • Import: import type { MCPCapabilityDriftType } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export type MCPCapabilityDriftType = 'description_changed' | 'input_schema_changed' | 'output_schema_changed' | 'annotations_changed' | 'capability_added' | 'capability_removed' | 'server_identity_changed' | 'protocol_version_changed';

MCPCapabilityKind

Public type alias for MCP Capability Kind; the declaration contains its complete type expression.

  • Kind: type
  • Import: import type { MCPCapabilityKind } from '@codesoul-co/hypha-mcp';
  • Source module: catalog

Declaration

text
export type MCPCapabilityKind = 'tool' | 'resource' | 'prompt';