Skip to content

PersistentAI API Documentation / @persistentai/fireflow-trpc / client / createTRPCClient

Function: createTRPCClient()

createTRPCClient(opts?): TRPCClient<BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ edge: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ updateAnchors: MutationProcedure<{ input: { anchors: ...[]; edgeId: string; flowId: string; version: number; }; meta: object; output: { anchors: ...[]; edgeId: string; stale: boolean; version: number; }; }>; }>>; flow: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addFieldObjectPort: MutationProcedure<{ input: { config?: any; flowId: string; key: string; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; addNode: MutationProcedure<{ input: { flowId: string; metadata?: ... | ...; nodeType: string; portsConfig?: ... | ...; position: { x: ...; y: ...; }; }; meta: object; output: INode; }>; addNodeFromTemplate: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; targetNodeType: string; templateRef: { branch?: ...; uri: ...; workspaceId: ...; }; }; meta: object; output: INode; }>; appendElementArrayPort: MutationProcedure<{ input: { flowId: string; nodeId: string; portId: string; value?: any; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; connectPorts: MutationProcedure<{ input: { flowId: string; metadata?: ... | ...; sourceNodeId: string; sourcePortId: string; targetNodeId: string; targetPortId: string; }; meta: object; output: { edgeId: string; metadata: EdgeMetadata; sourceNodeId: string; sourcePortId: string; targetNodeId: string; targetPortId: string; }; }>; create: MutationProcedure<{ input: { description?: ... | ...; name: string; tags?: ... | ...; }; meta: object; output: FlowMetadata; }>; createAtPath: MutationProcedure<{ input: { branchName?: ... | ...; description?: ... | ...; name: string; parentPath: string; tags?: ... | ...; workspaceId: string; }; meta: object; output: { createdAt: Date; description: ... | ...; flowId: string; name: string; path: string; updatedAt: Date; }; }>; delete: MutationProcedure<{ input: { flowId: string; }; meta: object; output: { success: boolean; }; }>; deleteAtPath: MutationProcedure<{ input: { branchName?: ... | ...; flowPath: string; workspaceId: string; }; meta: object; output: { success: boolean; }; }>; edit: MutationProcedure<{ input: { description?: ... | ...; flowId: string; name?: ... | ...; tags?: ... | ...; }; meta: object; output: Flow; }>; fork: MutationProcedure<{ input: { flowId: string; name?: ... | ...; }; meta: object; output: FlowMetadata; }>; get: QueryProcedure<{ input: { flowId: string; }; meta: object; output: Flow; }>; getByRef: QueryProcedure<{ input: { ref: { path: ...; ref?: ...; workspaceId: ...; }; }; meta: object; output: IFlow; }>; getMeta: QueryProcedure<{ input: { flowId: string; }; meta: object; output: { canFork: boolean; createdAt: Date; description?: ... | ...; forkRule?: ... | ...; id?: ... | ...; isPublic?: ... | ... | ...; metadata?: ... | ...; name: string; ownerID?: ... | ...; parentId?: ... | ...; schemaVersion?: ... | ...; tags?: ... | ...; updatedAt: Date; version?: ... | ...; }; }>; list: QueryProcedure<{ input: void; meta: object; output: object[]; }>; openFromVfs: MutationProcedure<{ input: { ref: { path: ...; ref?: ...; workspaceId: ...; }; }; meta: object; output: { description: ... | ...; flowId: string; isNew: boolean; name: string; path: string; }; }>; pasteNodes: MutationProcedure<{ input: { clipboardData: { edges: ...; nodes: ...; timestamp?: ...; }; flowId: string; pastePosition: { x: ...; y: ...; }; virtualOrigin?: ... | ...; }; meta: object; output: { createdEdges: ...[]; createdNodes: ...[]; edgeCount: number; nodeCount: number; nodeIdMapping: {[k: ...]: ...; }; skippedEdges: ...[]; success: boolean; }; }>; removeEdge: MutationProcedure<{ input: { edgeId: string; flowId: string; }; meta: object; output: { removedEdgeId: string; success: boolean; }; }>; removeElementArrayPort: MutationProcedure<{ input: { flowId: string; index: number; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; removeFieldObjectPort: MutationProcedure<{ input: { flowId: string; key: string; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; removeNode: MutationProcedure<{ input: { flowId: string; nodeId: string; }; meta: object; output: { removedNodeId: string; success: boolean; }; }>; saveAtPath: MutationProcedure<{ input: { branchName?: ... | ...; description?: ... | ...; flowId: string; flowPath: string; name?: ... | ...; tags?: ... | ...; workspaceId: string; }; meta: object; output: { derivedEventsCount: number; description: ... | ...; flowId: string; name: string; path: string; updatedAt: Date; }; }>; setForkRule: MutationProcedure<{ input: { flowId: string; forkRule?: ... | ...; }; meta: object; output: { forkRule: Record<..., ...>; success: boolean; }; }>; setPublic: MutationProcedure<{ input: { flowId: string; isPublic: boolean; }; meta: object; output: { isPublic: boolean; success: boolean; }; }>; subscribeToEvents: SubscriptionProcedure<{ input: { eventTypes?: ... | ...; flowId: string; lastEventId?: ... | ... | ...; }; meta: object; output: AsyncIterable<TrackedData<...>>; }>; updateItemConfigArrayPort: MutationProcedure<{ input: { flowId: string; itemConfig?: any; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; updateNodeParent: MutationProcedure<{ input: { flowId: string; nodeId: string; parentNodeId?: ... | ...; position: { x: ...; y: ...; }; version: number; }; meta: object; output: { flowId: string; nodeId: string; parentNodeId: ... | ...; position: { x: ...; y: ...; }; version: number; }; }>; updateNodePosition: MutationProcedure<{ input: { flowId: string; nodeId: string; position: { x: ...; y: ...; }; version: number; }; meta: object; output: { flowId: ...; nodeId: ...; position: ...; requestedVersion?: ...; version: ...; } | { flowId: ...; nodeId: ...; position: ...; requestedVersion: ...; version: ...; }; }>; updateNodeTitle: MutationProcedure<{ input: { flowId: string; nodeId: string; title?: ... | ...; version: number; }; meta: object; output: { flowId: string; nodeId: string; title: string; version: number; }; }>; updateNodeUI: MutationProcedure<{ input: { flowId: string; nodeId: string; ui: { dimensions?: ...; position?: ...; state?: ...; style?: ...; title?: ...; }; version: number; }; meta: object; output: { flowId: string; nodeId: string; ui: ... | ...; version: number; }; }>; updatePortUI: MutationProcedure<{ input: { flowId: string; nodeId: string; nodeVersion: number; portId: string; ui: Record<..., ...>; }; meta: object; output: { flowId: string; nodeId: string; port: IPort<...>; }; }>; updatePortValue: MutationProcedure<{ input: { flowId: string; nodeId: string; nodeVersion: number; portId: string; value?: any; }; meta: object; output: { flowId: string; nodeId: string; port: IPort<...>; }; }>; }>>; mcp: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addPromptToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; promptName: string; serverId: string; }; meta: object; output: INode; }>; addResourceToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; resourceName: string; serverId: string; }; meta: object; output: INode; }>; addToolToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; serverId: string; toolName: string; }; meta: object; output: INode; }>; buildPromptNode: QueryProcedure<{ input: { promptName: string; serverId: string; }; meta: object; output: INode; }>; buildResourceNode: QueryProcedure<{ input: { resourceName: string; serverId: string; }; meta: object; output: INode; }>; buildToolNode: QueryProcedure<{ input: { serverId: string; toolName: string; }; meta: object; output: INode; }>; createServer: MutationProcedure<{ input: { authHeaders: ...[]; title: string; url: string; }; meta: object; output: MCPServer; }>; deleteServer: MutationProcedure<{ input: { id: string; }; meta: object; output: { success: true; }; }>; getAllNodesForServer: QueryProcedure<{ input: { serverId: string; }; meta: object; output: AllNodesResponse; }>; listServers: QueryProcedure<{ input: void; meta: object; output: MCPServer[]; }>; serverCapabilities: QueryProcedure<{ input: { serverId: string; }; meta: object; output: ServerCapabilities; }>; updateServer: MutationProcedure<{ input: { authHeaders: ...[]; id: string; title: string; url: string; }; meta: object; output: MCPServer; }>; }>>; nodeRegistry: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getCategories: QueryProcedure<{ input: void; meta: object; output: string[]; }>; getCategorizedNodes: QueryProcedure<{ input: void; meta: object; output: CategorizedNodes[]; }>; getNodesByCategory: QueryProcedure<{ input: string; meta: object; output: CategorizedNodes | undefined; }>; getNodeType: QueryProcedure<{ input: string; meta: object; output: INode; }>; listAvailableTypes: QueryProcedure<{ input: void; meta: object; output: NodeMetadataWithPorts[]; }>; searchNodes: QueryProcedure<{ input: string; meta: object; output: CategorizedNodes[]; }>; }>>; secrets: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getSecretTypes: QueryProcedure<{ input: void; meta: object; output: {[k: string]: object; }; }>; }>>; users: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ demo: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ createDemoSession: MutationProcedure<...>; }>>; profile: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getDemoExpiration: QueryProcedure<...>; getProfile: QueryProcedure<...>; isDemo: QueryProcedure<...>; listExternalAccounts: QueryProcedure<...>; }>>; }>>; vfs: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ confirmation: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ respond: MutationProcedure<...>; }>>; file: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ commitFile: MutationProcedure<...>; createDirectory: MutationProcedure<...>; createTyped: MutationProcedure<...>; fileDelete: MutationProcedure<...>; getDownloadUrl: QueryProcedure<...>; getUploadUrl: QueryProcedure<...>; info: QueryProcedure<...>; list: QueryProcedure<...>; listChildren: QueryProcedure<...>; move: MutationProcedure<...>; write: MutationProcedure<...>; }>>; fileType: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ list: QueryProcedure<...>; }>>; git: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ checkout: MutationProcedure<...>; commit: MutationProcedure<...>; createBranch: MutationProcedure<...>; deleteBranch: MutationProcedure<...>; diff: QueryProcedure<...>; listBranches: QueryProcedure<...>; log: QueryProcedure<...>; merge: MutationProcedure<...>; status: QueryProcedure<...>; }>>; node: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ read: QueryProcedure<...>; }>>; subscription: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ events: SubscriptionProcedure<...>; }>>; upload: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ abort: MutationProcedure<...>; complete: MutationProcedure<...>; initiate: MutationProcedure<...>; }>>; workspace: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addCollaborator: MutationProcedure<...>; create: MutationProcedure<...>; get: QueryProcedure<...>; getPersonal: QueryProcedure<...>; list: QueryProcedure<...>; listCollaborators: QueryProcedure<...>; removeCollaborator: MutationProcedure<...>; update: MutationProcedure<...>; workspaceDelete: MutationProcedure<...>; }>>; }>>; }>>>

Defined in: packages/fireflow-trpc/client/trpc.ts:60

Parameters

opts?

auth?

AuthOptions

superjsonCustom?

typeof default

url

string

wsClientCallbacks?

{ onClose?: (cause?) => void; onError?: (err?) => void; onOpen?: () => void; }

wsClientCallbacks.onClose?

(cause?) => void

wsClientCallbacks.onError?

(err?) => void

wsClientCallbacks.onOpen?

() => void

Returns

TRPCClient<BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ edge: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ updateAnchors: MutationProcedure<{ input: { anchors: ...[]; edgeId: string; flowId: string; version: number; }; meta: object; output: { anchors: ...[]; edgeId: string; stale: boolean; version: number; }; }>; }>>; flow: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addFieldObjectPort: MutationProcedure<{ input: { config?: any; flowId: string; key: string; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; addNode: MutationProcedure<{ input: { flowId: string; metadata?: ... | ...; nodeType: string; portsConfig?: ... | ...; position: { x: ...; y: ...; }; }; meta: object; output: INode; }>; addNodeFromTemplate: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; targetNodeType: string; templateRef: { branch?: ...; uri: ...; workspaceId: ...; }; }; meta: object; output: INode; }>; appendElementArrayPort: MutationProcedure<{ input: { flowId: string; nodeId: string; portId: string; value?: any; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; connectPorts: MutationProcedure<{ input: { flowId: string; metadata?: ... | ...; sourceNodeId: string; sourcePortId: string; targetNodeId: string; targetPortId: string; }; meta: object; output: { edgeId: string; metadata: EdgeMetadata; sourceNodeId: string; sourcePortId: string; targetNodeId: string; targetPortId: string; }; }>; create: MutationProcedure<{ input: { description?: ... | ...; name: string; tags?: ... | ...; }; meta: object; output: FlowMetadata; }>; createAtPath: MutationProcedure<{ input: { branchName?: ... | ...; description?: ... | ...; name: string; parentPath: string; tags?: ... | ...; workspaceId: string; }; meta: object; output: { createdAt: Date; description: ... | ...; flowId: string; name: string; path: string; updatedAt: Date; }; }>; delete: MutationProcedure<{ input: { flowId: string; }; meta: object; output: { success: boolean; }; }>; deleteAtPath: MutationProcedure<{ input: { branchName?: ... | ...; flowPath: string; workspaceId: string; }; meta: object; output: { success: boolean; }; }>; edit: MutationProcedure<{ input: { description?: ... | ...; flowId: string; name?: ... | ...; tags?: ... | ...; }; meta: object; output: Flow; }>; fork: MutationProcedure<{ input: { flowId: string; name?: ... | ...; }; meta: object; output: FlowMetadata; }>; get: QueryProcedure<{ input: { flowId: string; }; meta: object; output: Flow; }>; getByRef: QueryProcedure<{ input: { ref: { path: ...; ref?: ...; workspaceId: ...; }; }; meta: object; output: IFlow; }>; getMeta: QueryProcedure<{ input: { flowId: string; }; meta: object; output: { canFork: boolean; createdAt: Date; description?: ... | ...; forkRule?: ... | ...; id?: ... | ...; isPublic?: ... | ... | ...; metadata?: ... | ...; name: string; ownerID?: ... | ...; parentId?: ... | ...; schemaVersion?: ... | ...; tags?: ... | ...; updatedAt: Date; version?: ... | ...; }; }>; list: QueryProcedure<{ input: void; meta: object; output: object[]; }>; openFromVfs: MutationProcedure<{ input: { ref: { path: ...; ref?: ...; workspaceId: ...; }; }; meta: object; output: { description: ... | ...; flowId: string; isNew: boolean; name: string; path: string; }; }>; pasteNodes: MutationProcedure<{ input: { clipboardData: { edges: ...; nodes: ...; timestamp?: ...; }; flowId: string; pastePosition: { x: ...; y: ...; }; virtualOrigin?: ... | ...; }; meta: object; output: { createdEdges: ...[]; createdNodes: ...[]; edgeCount: number; nodeCount: number; nodeIdMapping: {[k: ...]: ...; }; skippedEdges: ...[]; success: boolean; }; }>; removeEdge: MutationProcedure<{ input: { edgeId: string; flowId: string; }; meta: object; output: { removedEdgeId: string; success: boolean; }; }>; removeElementArrayPort: MutationProcedure<{ input: { flowId: string; index: number; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; removeFieldObjectPort: MutationProcedure<{ input: { flowId: string; key: string; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; removeNode: MutationProcedure<{ input: { flowId: string; nodeId: string; }; meta: object; output: { removedNodeId: string; success: boolean; }; }>; saveAtPath: MutationProcedure<{ input: { branchName?: ... | ...; description?: ... | ...; flowId: string; flowPath: string; name?: ... | ...; tags?: ... | ...; workspaceId: string; }; meta: object; output: { derivedEventsCount: number; description: ... | ...; flowId: string; name: string; path: string; updatedAt: Date; }; }>; setForkRule: MutationProcedure<{ input: { flowId: string; forkRule?: ... | ...; }; meta: object; output: { forkRule: Record<..., ...>; success: boolean; }; }>; setPublic: MutationProcedure<{ input: { flowId: string; isPublic: boolean; }; meta: object; output: { isPublic: boolean; success: boolean; }; }>; subscribeToEvents: SubscriptionProcedure<{ input: { eventTypes?: ... | ...; flowId: string; lastEventId?: ... | ... | ...; }; meta: object; output: AsyncIterable<TrackedData<...>>; }>; updateItemConfigArrayPort: MutationProcedure<{ input: { flowId: string; itemConfig?: any; nodeId: string; portId: string; }; meta: object; output: { flowId: string; node: INode; nodeId: string; }; }>; updateNodeParent: MutationProcedure<{ input: { flowId: string; nodeId: string; parentNodeId?: ... | ...; position: { x: ...; y: ...; }; version: number; }; meta: object; output: { flowId: string; nodeId: string; parentNodeId: ... | ...; position: { x: ...; y: ...; }; version: number; }; }>; updateNodePosition: MutationProcedure<{ input: { flowId: string; nodeId: string; position: { x: ...; y: ...; }; version: number; }; meta: object; output: { flowId: ...; nodeId: ...; position: ...; requestedVersion?: ...; version: ...; } | { flowId: ...; nodeId: ...; position: ...; requestedVersion: ...; version: ...; }; }>; updateNodeTitle: MutationProcedure<{ input: { flowId: string; nodeId: string; title?: ... | ...; version: number; }; meta: object; output: { flowId: string; nodeId: string; title: string; version: number; }; }>; updateNodeUI: MutationProcedure<{ input: { flowId: string; nodeId: string; ui: { dimensions?: ...; position?: ...; state?: ...; style?: ...; title?: ...; }; version: number; }; meta: object; output: { flowId: string; nodeId: string; ui: ... | ...; version: number; }; }>; updatePortUI: MutationProcedure<{ input: { flowId: string; nodeId: string; nodeVersion: number; portId: string; ui: Record<..., ...>; }; meta: object; output: { flowId: string; nodeId: string; port: IPort<...>; }; }>; updatePortValue: MutationProcedure<{ input: { flowId: string; nodeId: string; nodeVersion: number; portId: string; value?: any; }; meta: object; output: { flowId: string; nodeId: string; port: IPort<...>; }; }>; }>>; mcp: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addPromptToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; promptName: string; serverId: string; }; meta: object; output: INode; }>; addResourceToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; resourceName: string; serverId: string; }; meta: object; output: INode; }>; addToolToFlow: MutationProcedure<{ input: { flowId: string; position: { x: ...; y: ...; }; serverId: string; toolName: string; }; meta: object; output: INode; }>; buildPromptNode: QueryProcedure<{ input: { promptName: string; serverId: string; }; meta: object; output: INode; }>; buildResourceNode: QueryProcedure<{ input: { resourceName: string; serverId: string; }; meta: object; output: INode; }>; buildToolNode: QueryProcedure<{ input: { serverId: string; toolName: string; }; meta: object; output: INode; }>; createServer: MutationProcedure<{ input: { authHeaders: ...[]; title: string; url: string; }; meta: object; output: MCPServer; }>; deleteServer: MutationProcedure<{ input: { id: string; }; meta: object; output: { success: true; }; }>; getAllNodesForServer: QueryProcedure<{ input: { serverId: string; }; meta: object; output: AllNodesResponse; }>; listServers: QueryProcedure<{ input: void; meta: object; output: MCPServer[]; }>; serverCapabilities: QueryProcedure<{ input: { serverId: string; }; meta: object; output: ServerCapabilities; }>; updateServer: MutationProcedure<{ input: { authHeaders: ...[]; id: string; title: string; url: string; }; meta: object; output: MCPServer; }>; }>>; nodeRegistry: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getCategories: QueryProcedure<{ input: void; meta: object; output: string[]; }>; getCategorizedNodes: QueryProcedure<{ input: void; meta: object; output: CategorizedNodes[]; }>; getNodesByCategory: QueryProcedure<{ input: string; meta: object; output: CategorizedNodes | undefined; }>; getNodeType: QueryProcedure<{ input: string; meta: object; output: INode; }>; listAvailableTypes: QueryProcedure<{ input: void; meta: object; output: NodeMetadataWithPorts[]; }>; searchNodes: QueryProcedure<{ input: string; meta: object; output: CategorizedNodes[]; }>; }>>; secrets: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getSecretTypes: QueryProcedure<{ input: void; meta: object; output: {[k: string]: object; }; }>; }>>; users: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ demo: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ createDemoSession: MutationProcedure<...>; }>>; profile: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ getDemoExpiration: QueryProcedure<...>; getProfile: QueryProcedure<...>; isDemo: QueryProcedure<...>; listExternalAccounts: QueryProcedure<...>; }>>; }>>; vfs: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: "PARSE_ERROR" | "BAD_REQUEST" | "INTERNAL_SERVER_ERROR" | "NOT_IMPLEMENTED" | "BAD_GATEWAY" | "SERVICE_UNAVAILABLE" | "GATEWAY_TIMEOUT" | "UNAUTHORIZED" | "PAYMENT_REQUIRED" | "FORBIDDEN" | "NOT_FOUND" | "METHOD_NOT_SUPPORTED" | "TIMEOUT" | "CONFLICT" | "PRECONDITION_FAILED" | "PAYLOAD_TOO_LARGE" | "UNSUPPORTED_MEDIA_TYPE" | "UNPROCESSABLE_CONTENT" | "PRECONDITION_REQUIRED" | "TOO_MANY_REQUESTS" | "CLIENT_CLOSED_REQUEST"; httpStatus: number; path?: string; stack?: string; zodError: typeToFlattenedError<any, string> | null; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ confirmation: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ respond: MutationProcedure<...>; }>>; file: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ commitFile: MutationProcedure<...>; createDirectory: MutationProcedure<...>; createTyped: MutationProcedure<...>; fileDelete: MutationProcedure<...>; getDownloadUrl: QueryProcedure<...>; getUploadUrl: QueryProcedure<...>; info: QueryProcedure<...>; list: QueryProcedure<...>; listChildren: QueryProcedure<...>; move: MutationProcedure<...>; write: MutationProcedure<...>; }>>; fileType: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ list: QueryProcedure<...>; }>>; git: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ checkout: MutationProcedure<...>; commit: MutationProcedure<...>; createBranch: MutationProcedure<...>; deleteBranch: MutationProcedure<...>; diff: QueryProcedure<...>; listBranches: QueryProcedure<...>; log: QueryProcedure<...>; merge: MutationProcedure<...>; status: QueryProcedure<...>; }>>; node: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ read: QueryProcedure<...>; }>>; subscription: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ events: SubscriptionProcedure<...>; }>>; upload: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ abort: MutationProcedure<...>; complete: MutationProcedure<...>; initiate: MutationProcedure<...>; }>>; workspace: BuiltRouter<{ ctx: AppContext; errorShape: { code: TRPC_ERROR_CODE_NUMBER; data: { code: ...; httpStatus: ...; path?: ...; stack?: ...; zodError: ...; }; message: string; }; meta: object; transformer: true; }, DecorateCreateRouterOptions<{ addCollaborator: MutationProcedure<...>; create: MutationProcedure<...>; get: QueryProcedure<...>; getPersonal: QueryProcedure<...>; list: QueryProcedure<...>; listCollaborators: QueryProcedure<...>; removeCollaborator: MutationProcedure<...>; update: MutationProcedure<...>; workspaceDelete: MutationProcedure<...>; }>>; }>>; }>>>

Licensed under BUSL-1.1