Environment variable

Applies to: general

An environment variable is a named setting provided by the operating system to a process, often used for paths, secrets, or configuration.

import os
api_key = os.environ.get("API_KEY")

See also: command-line, shell