# Configuration

The proxy can be configured using env variables that must be set up at the time the service starts in order to have any affect. In the following table we list the available variables and their default values if any.

<table><thead><tr><th>Variable</th><th>Default</th><th>Description</th></tr></thead><tbody><tr><td><pre><code>AUTH_TOKENS
</code></pre></td><td></td><td>Comma separated list of valid tokens that can be used to authenticate in the proxy.</td></tr><tr><td><pre><code>QUEUE_PREFIX
</code></pre></td><td><code>bull</code></td><td>Prefix used for all Redis keys used by the queues managed by the proxy.</td></tr><tr><td><pre><code>PORT
</code></pre></td><td><code>8080</code></td><td>Port where the proxy will listen for requests.</td></tr><tr><td><pre><code>REDIS_URI
</code></pre></td><td></td><td>Redis URI string. Either this standalone string or separate Redis™ variables can be used.</td></tr><tr><td><pre><code>REDIS_HOST
</code></pre></td><td><code>localhost</code></td><td>Host where the Redis™ instance is running.</td></tr><tr><td><pre><code>REDIS_PORT
</code></pre></td><td><code>6379</code></td><td>Port used for the Redis™ instance.</td></tr><tr><td><pre><code>REDIS_USERNAME
</code></pre></td><td></td><td>Optiona username for the used Redis™ instance.</td></tr><tr><td><pre><code>REDIS_PASSWORD
</code></pre></td><td></td><td>Password used for the Redis™ instance.</td></tr><tr><td><pre><code>REDIS_TLS
</code></pre></td><td></td><td>Enable TLS when connecting to the Redis™ instance.</td></tr><tr><td><pre><code>QUEUE_CACHE_SIZE
</code></pre></td><td>100</td><td>Maximum number of BullMQ queue instances to keep in the cache.</td></tr><tr><td><pre><code>DEBUG
</code></pre></td><td>false</td><td>Enable debugging logs.</td></tr><tr><td><pre><code>MIN_QUEUE_NAME_LENGTH
</code></pre></td><td>3</td><td>Minimum allowed length for queue names.</td></tr><tr><td><pre><code>MAX_QUEUE_NAME_LENGTH
</code></pre></td><td>100</td><td>Maximum allowed length for queue names.</td></tr><tr><td><pre><code>WORKER_METADATA_KEY
</code></pre></td><td><pre><code><strong>bullmq-proxy:workers
</strong></code></pre></td><td>Redis™ key where to store metadata for registered workers.</td></tr></tbody></table>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.bullmq.net/http-api/configuration.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
