---
title: "vuer.base"
section: "Python API"
order: 3
description: "Python API reference for vuer.base"
---

# vuer.base

## default_handler

```python
async def default_handler(request, ws)
```

[Source](https://github.com/vuer-ai/vuer-docs/blob/docs/v0.0.52/vuer/base.py#L14)

## websocket_handler

```python
async def websocket_handler(request, handler, **ws_kwargs)
```

[Source](https://github.com/vuer-ai/vuer-docs/blob/docs/v0.0.52/vuer/base.py#L19)

## handle_file_request

```python
async def handle_file_request(request, root, filename=None)
```

[Source](https://github.com/vuer-ai/vuer-docs/blob/docs/v0.0.52/vuer/base.py#L40)

## Server

```python
class Server
```

[Source](https://github.com/vuer-ai/vuer-docs/blob/docs/v0.0.52/vuer/base.py#L52)

Base TCP server

```python
WEBSOCKET_MAX_SIZE: int = Proto(2 ** 28, env='WEBSOCKET_MAX_SIZE', help='maximum size for websocket requests.')
```

```python
REQUEST_MAX_SIZE: int = Proto(2 ** 28, env='REQUEST_MAX_SIZE', help='maximum size for requests.')
```

## Server.run

```python
def run(self)
```

[Source](https://github.com/vuer-ai/vuer-docs/blob/docs/v0.0.52/vuer/base.py#L115)

```python
host = Proto(env='HOST', default='localhost')
```

```python
cors = Proto(help='Enable CORS', default='*')
```

```python
port = Proto(env='PORT', default=8012)
```

```python
cert = Proto(None, dtype=str, help='the path to the SSL certificate')
```

```python
key = Proto(None, dtype=str, help='the path to the SSL key')
```

```python
ca_cert = Proto(None, dtype=str, help='the trusted root CA certificates')
```
