# IServerConfig

## Content

# Interface: IServerConfig

## Table of contents

### Properties

- [allowRequest](IServerConfig#allowrequest)
- [cors](IServerConfig#cors)
- [httpServer](IServerConfig#httpserver)
- [maxDecompressedMessageSize](IServerConfig#maxdecompressedmessagesize)
- [maxHttpBufferSize](IServerConfig#maxhttpbuffersize)
- [path](IServerConfig#path)
- [port](IServerConfig#port)
- [socketIoAdapter](IServerConfig#socketioadapter)

## Properties

### <a id="allowrequest" name="allowrequest"></a> allowRequest

• `Optional` **allowRequest**: `any`

Forwarded directly to the Socket.IO `allowRequest` option.
Use this to control whether a handshake or upgrade request should be accepted.

**`see`** https://socket.io/docs/v4/server-options/#allowrequest

___

### <a id="cors" name="cors"></a> cors

• `Optional` **cors**: `any`

Forwarded directly to the Socket.IO `cors` option.
Use this to configure CORS behavior for Socket.IO HTTP requests.

**`see`** https://socket.io/docs/v4/handling-cors/

___

### <a id="httpserver" name="httpserver"></a> httpServer

• `Optional` **httpServer**: `Server` \| `Server` \| `Http2SecureServer` \| `Http2Server`

___

### <a id="maxdecompressedmessagesize" name="maxdecompressedmessagesize"></a> maxDecompressedMessageSize

• `Optional` **maxDecompressedMessageSize**: `number`

The maximum allowed size in bytes after a compressed message is decompressed.
Exceeding this limit reports a message error without crashing the server process.
Defaults to the current Node.js maximum string length, or 512 MiB when the runtime does not expose that limit.

___

### <a id="maxhttpbuffersize" name="maxhttpbuffersize"></a> maxHttpBufferSize

• `Optional` **maxHttpBufferSize**: `number`

The maximum incoming message size in bytes.
Socket.IO will close the connection when a payload exceeds this value.
Defaults to 512 MiB.

___

### <a id="path" name="path"></a> path

• `Optional` **path**: `string`

The request path for the server. Defaults to '/collaboration/'.

___

### <a id="port" name="port"></a> port

• `Optional` **port**: `number`

___

### <a id="socketioadapter" name="socketioadapter"></a> socketIoAdapter

• `Optional` **socketIoAdapter**: `any`

Custom Socket.IO adapter for multi-node/distributed deployments.
Allows integration with various message brokers (Redis, MongoDB, PostgreSQL, etc.)
to enable message broadcasting across multiple server instances.

**`see`** https://socket.io/docs/v4/adapter/
