Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions api-docs/auto-generate-docs.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,13 @@

![Click Generate Docs](/images/screenshots/send-request/api-docs/opencollection/1-click-generate-docs.webp)

2. Click the **Generate** button to create the HTML documentation
2. Choose which environments to include in the generated docs. By default all environments in the collection are selected; use the **Select All** checkbox or the per-environment checkboxes to scope the output (for example, to keep `local` or `staging` envs out of docs shared externally). The configuration card alongside the list shows the normalized collection version and the number of folders and requests that will be exported.

Check warning on line 14 in api-docs/auto-generate-docs.mdx

View check run for this annotation

Mintlify / Mintlify Validation (bruno-a6972042) - vale-spellcheck

api-docs/auto-generate-docs.mdx#L14

Did you really mean 'envs'?

3. Click the **Generate** button to create the HTML documentation

![Click Generate Button](/images/screenshots/send-request/api-docs/opencollection/click-generate-2-button.webp)

3. Bruno will generate a HTML documentation file for your collection documentation
4. Bruno will generate a HTML documentation file for your collection documentation

![Generated HTML Documentation](/images/screenshots/send-request/api-docs/opencollection/genarated-docs-htmml.webp)

Expand Down Expand Up @@ -62,7 +64,7 @@
Once generated, you can:

1. **Open locally**: View the HTML file in any browser
2. **Static hosting**: Deploy to GitHub Pages, Netlify, Vercel, or any static host

Check warning on line 67 in api-docs/auto-generate-docs.mdx

View check run for this annotation

Mintlify / Mintlify Validation (bruno-a6972042) - vale-spellcheck

api-docs/auto-generate-docs.mdx#L67

Did you really mean 'Netlify'?

Check warning on line 67 in api-docs/auto-generate-docs.mdx

View check run for this annotation

Mintlify / Mintlify Validation (bruno-a6972042) - vale-spellcheck

api-docs/auto-generate-docs.mdx#L67

Did you really mean 'Vercel'?
3. **Share directly**: Send the HTML file to team members or API consumers
4. **Documentation portal**: Add to your developer portal or docs site

39 changes: 37 additions & 2 deletions variables/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -127,9 +127,44 @@ Once colors are assigned, they appear in multiple places throughout the interfac

This visual system helps prevent mistakes when switching between development, staging, and production environments, especially in fast-paced workflows.

### Variable Data Type
### Variable Data Types

All variables are stored as strings. Bruno does not infer or change the data type of the variable based on the value you set.
<Info>
Typed variables are available in v3.1.0+. Earlier versions stored every variable as a string.
</Info>

Environment, collection, folder, and request variables can be tagged with a data type so they preserve their intended JavaScript type when used in requests and scripts. The supported types are:

- `string` (default)
- `number`
- `boolean`
- `object`

#### Setting the data type from the UI

Open the variables table (collection, folder, request, or environment settings) and use the type selector next to the value to switch between `string`, `number`, `boolean`, and `object`. Bruno coerces the entered text to the selected type at read time and shows a warning if the value can't be parsed as that type.

#### How types are stored in `.bru` files

Non-string types are persisted as an annotation prefix on the line above the variable. The default `string` type has no annotation.

```bash filename="environments/local.bru"
vars {
host: http://localhost:8787
@number
port: 8787
@boolean
debug: true
@object
feature_flags: {"newUi":true,"beta":false}
}
```

The same annotation syntax applies to `vars`, `vars:pre-request`, and `vars:post-response` blocks inside collection, folder, and request `.bru` files.

#### Inference from scripts

When a script sets a variable to a non-string value (for example `bru.setEnvVar('port', 8787)`), Bruno infers the appropriate data type from the value and persists it alongside the variable.

### Debugging Variables in Console

Expand Down