> ## Documentation Index
> Fetch the complete documentation index at: https://onr.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Conventions

> Punctuation, naming rules, and basic syntax.

When writing Open Next Router DSL configurations, follow these strict conventions to ensure the parser can read your files successfully:

* **One provider per file**: `config/providers/<provider>.conf`
* **File name must match provider name**: e.g., `config/providers/openai.conf` must contain `provider "openai" { ... }`
* **Case-insensitive matching**: Provider matching is completely case-insensitive; everything is normalized to lowercase internally. We strongly recommend using lowercase everywhere in configs.
* **Semicolons are required**: Every statement MUST end with a semicolon `;`.
* **Only blocks use braces**: Blocks like `request`, `upstream`, or `match` use `{}`. Directives themselves do not (nginx-like style).
* **One directive per line**: This is the recommended style for better readability and cleaner git diffs.
* **Comments**: Supported formats are `#`, `//`, or `/* ... */`.

### Example of Good Formatting

```nginx theme={null}
upstream_config {
  base_url = "https://api.example.com";
}

match api = "chat.completions" {
  upstream {
    set_path "/v1/chat/completions";
    set_query stream "true";
  }
  response {
    resp_passthrough;
  }
}
```
