Types glossary
Constants and interfaces below are exported from @gloocan/cat-inspector (unless noted as Socket.IO-only payloads matching the same shapes).
CatMode
'service' | 'api_candidate' | 'api' — see Cat modes.
QaFileWireMode and QaMediaUploadTarget
QaFileWireMode:'ref' | 'url'— catalog + RPC file placeholder strategy.QaMediaUploadTarget:'admin' | 'host'— hint for where tenant UI uploads before emitting__qaFileUrl.
ParamKind
'json' | 'file' | 'files' — classifies a parameter for QA file pickers and materialization.
RegistryParam
| Field | Type | Role |
|---|---|---|
name | string | Positional parameter name. |
type | string | Declared / inferred type string for catalog. |
kind | ParamKind? | Optional classification. |
filePaths | string[]? | Nested single-file paths inside object params. |
fileArrayPaths | string[]? | Nested multi-file paths. |
qaFileWire | QaFileWireMode? | Echoed wire hint for QA UI. |
qaMediaUpload | QaMediaUploadTarget? | Echoed upload target hint. |
RegistryEntry
| Field | Type | Role |
|---|---|---|
mode | CatMode | Service vs Express. |
className, method | string | Display names from fnKey. |
style | class or function | Instance vs direct function invoke. |
body | string | Source text snippet (may be redacted from snapshots). |
params | RegistryParam[] | Positional metadata. |
declaredReturn | string | Return type string. |
returns | ReturnEntry[] | Labeled return branches. |
errors | ErrorEntry[] | Labeled error branches. |
children, parents | string[] | Relationship keys. |
route, httpMethod, pipelineId, pipelineIndex | nullable | Express routing metadata. |
apiResponses | ApiResponseEntry[] | Labeled HTTP response slots. |
serviceLinks | string[] | Linked service fnKeys from analysis. |
paramsJsonSchema, returnJsonSchema | Record<string, unknown> | null | Optional JSON Schemas. |
invokeKind | 'rpc' | 'http_synthetic' | RPC vs HTTP bridge execution. |
originalFn | Function | Host-only callable (not on wire). |
ReturnEntry / ErrorEntry / ApiResponseEntry
| Type | Key fields |
|---|---|
ReturnEntry | label, type, status: 'pending' | 'resolved'. |
ErrorEntry | label, type, message, status. |
ApiResponseEntry | label, statusCode, bodyShape, status. |
RpcErrorDetail
| Field | Type |
|---|---|
message | string |
stack | string | null |
layer | 'validation' | 'expected' | 'unexpected' |
code | string? |
RpcResponse
| Field | Type |
|---|---|
type | 'RPC_RESPONSE' |
requestId, fnKey | string |
status | 'ok' | 'error' |
result | unknown |
returnType | string |
returnShape | string | null |
label | string | null |
duration | string |
error | RpcErrorDetail | null |
artifacts | RpcArtifactRef[]? |
BootstrapEvent
Adds to the core bootstrap payload: optional qaFileWire, qaMediaUpload, fileUrl, qaMediaUploadHostUploadUrl, qaHostMediaUploadViaSocket (see Protocol bootstrap).
Inspector events (discriminated union)
InspectorWireEvent covers shapes including:
| Variant | Distinguisher |
|---|---|
| Bootstrap | event: 'BOOTSTRAP' |
| Return resolved | event: 'RETURN_RESOLVED' |
| Error thrown | event: 'ERROR_THROWN' |
| API response | event: 'API_RESPONSE' |
| Middleware next | event: 'MIDDLEWARE_NEXT' |
| RPC executed | event: 'RPC_EXECUTED' |
| RPC response | type: 'RPC_RESPONSE' |
| Coverage report | type: 'COVERAGE_REPORT' |
| Job progress | event: 'JOB_PROGRESS' |
Each carries protocolVersion where applicable.