Skip to main content

Authentication

auth:
type: bearer # basic | bearer | apikey | oauth2

Prefer *_file fields over inline secrets.

Basic

auth:
type: basic
username: myuser
password_file: /path/to/password.txt

Bearer

auth:
type: bearer
token_file: /path/to/token.txt

API key

auth:
type: apikey
api_key: your_api_key_here
api_key_header: X-API-Key # default

OAuth2

auth:
type: oauth2
token: your_access_token
auth_url: https://api.example.com/oauth/token
refresh_token: your_refresh_token

Template: examples/templates/bearer-auth.yaml. See also protected APIs.