# BT.envs ## Function returns the currently valid environment variable object. ## Syntax ```bt BT.envs() ``` ## Parameters | Parameters | Type | Required | Default value | Description | | ------ | ------ | ------ | ------ | ------ | | None | - | No | None | No parameters required. | ## Return Value | Type | Description | | ------ | ------ | | Object | Returns the dynamic key-value object that combines OS environment variables and BT runtime overlay. See below for field rules. | ## Return object field `BT.envs()` returns a dynamic object, not a fixed structure object. Object fields come from current OS environment variables and BT runtime overlay. | Field | Type | Must exist | Description | | ------ | ------ | ------ | ------ | | Any environment variable name | String | No | A valid environment variable value. The field name is the environment variable name, such as `PATH`, `BT_MODE`. When the variable does not exist or is obscured by `BT.remove_env(name)`, this field does not exist and the read result is `empty`. | ## Examples ```bt BT.set_env('BT_MODE', 'dev') envs = BT.envs() result = envs.BT_MODE // Output: dev print result ``` ## Notes - BT.envs() will traverse OS environment variables as needed, which may result in more string allocations. - Variables that have been obscured by the remove_env removal flag will not appear in the returned object. - The overlay written by `BT.set_env(name, value)` will overwrite the OS environment variable with the same name.