# Type Alias: TRPCResponseMessage<TData, TError>

> 

> **TRPCResponseMessage**\<`TData`, `TError`\>: `object` & [`TRPCErrorResponse`](https://trpc.io/docs/typedoc/server/rpc/interfaces/TRPCErrorResponse.md)\<`TError`\> \| [`TRPCResultMessage`](https://trpc.io/docs/typedoc/server/rpc/interfaces/TRPCResultMessage.md)\<`TData`\>

Defined in: [packages/server/src/unstable-core-do-not-import/rpc/envelopes.ts:153](https://github.com/trpc/trpc/blob/7c907acfd8b31929214792e3b8c2ad7a8ac72563/packages/server/src/unstable-core-do-not-import/rpc/envelopes.ts#L153)

A response sent over WebSockets, with the id of the call it answers.

## Type declaration

### id

> **id**: [`RequestId`](https://trpc.io/docs/typedoc/server/rpc/namespaces/JSONRPC2/type-aliases/RequestId.md)

## Type Parameters

| Type Parameter | Default type |
| ------ | ------ |
| `TData` | `unknown` |
| `TError` *extends* [`TRPCErrorShape`](https://trpc.io/docs/typedoc/server/index/interfaces/TRPCErrorShape.md) | [`TRPCErrorShape`](https://trpc.io/docs/typedoc/server/index/interfaces/TRPCErrorShape.md) |

## See

https://trpc.io/docs/server/websockets#response
