rtb-credentials 0.6.4

OS keychain credential storage. Part of the phpboyscout Rust toolkit.
Documentation
---
title: Reference
description: Every configuration key, store, error variant, Cargo feature and environment variable rtb-credentials reads.
tags:
  - reference
---

# Reference

Exact behaviour of every configuration key, type, error and environment
variable in `rtb-credentials`, including what happens when a value is
wrong.

This tier describes the crate as it is built, at version 0.6.3. For
signatures, generic bounds and trait implementations, the generated API
documentation at [docs.rs/rtb-credentials](https://docs.rs/rtb-credentials)
is the companion to these pages.

| Page | Covers |
|---|---|
| [`CredentialRef` configuration keys]credential-ref.md | The four config keys tool authors expose to operators, their types, defaults, and how unknown keys are handled. |
| [Credential stores]stores.md | `CredentialStore` and the four built-in implementations, including which methods each one refuses. |
| [`Resolver`: `resolve` and `probe`]resolver.md | Constructors, the resolution chain, and exactly which error aborts the walk rather than falling through. |
| [Error variants]errors.md | Every `CredentialError` variant, its `miette` diagnostic code, and what produces it. |
| [Cargo features]cargo-features.md | `default`, `linux-persistent`, and the build-host packages each requires. |
| [Environment variables]environment-variables.md | The variables the crate itself reads, as distinct from the ones a tool configures. |

## What this crate does not read from the environment on its own

`rtb-credentials` reads exactly one environment variable of its own
accord: `CI`. Every other variable it touches is one a tool named
explicitly in a `CredentialRef` through `env` or `fallback_env`.

There is no implicit search of well-known variable names. A credential
with neither `env` nor `fallback_env` set will never be resolved from the
environment, however conventionally named the variable is. The full list
is on the [environment variables](environment-variables.md) page.

## Minimum supported Rust version

The crate declares `rust-version = "1.82"` and `edition = "2021"` in
`Cargo.toml`.

The repository separately pins an exact toolchain in
`rust-toolchain.toml` (`channel = "1.97.1"`). That pin governs
contributors and CI; it is not the minimum a consumer needs. Building
`rtb-credentials` as a dependency requires 1.82 or later.