← Features / Developer & admin tools

Programmatic credentials

Pipe API keys in from environment variables or a secret manager via filters — credentials never have to be stored in the WordPress database.

How it works

ClassifAI exposes a classifai_provider_credentials filter (and provider-specific variants) that fires immediately before any outbound API request. Returning a credentials array from the filter overrides whatever is currently stored in the database for that provider, which lets administrators source secrets at request time from environment variables, AWS Secrets Manager, Azure Key Vault, HashiCorp Vault, or any custom secret store — without ever pasting the secret into a WordPress settings page.

Filtered credentials are not persisted to the database and are scoped to the current request, which means a leaked database backup contains no usable API keys.

Provider coverage

The filter pattern is supported across the full provider matrix:

  • OpenAI
  • Azure OpenAI, Azure AI Vision, Azure AI Speech
  • Google Gemini
  • IBM Watson
  • Amazon Polly
  • ElevenLabs
  • xAI Grok
  • Together AI
  • Locally hosted backends (Ollama, Stable Diffusion via AUTOMATIC1111)

Performance note

The official documentation recommends caching the secret-store lookup so that high-traffic features (Smart 404, Recommended Content) do not turn into a denial-of-service against the secret manager. A simple in-memory cache keyed by feature is usually enough.

Use cases

  • Enterprise WordPress hosts where database-stored secrets are explicitly disallowed.
  • Multi-environment deployments where staging and production should use different credentials without database divergence.
  • Compliance regimes that require credentials to live exclusively in a centrally managed secret store.

From the WordPress experts at Fueled, formerly 10up.

We’ve been delivering enterprise-grade digital work on WordPress since 2011, building and growing sites for global newsrooms, Fortune 500 marketing teams, ambitious startups, and public-sector clients. Our team helps lead the official WordPress Core AI team and has led and contributed to multiple WordPress core releases.

We also partner directly with organizations to build with AI and bring it into their digital products and marketing — on or off WordPress.

15+

years building enterprise WordPress, since 2011

1M+

active installs across plugins authored by our team

Core

co-leads of the official WordPress AI Team

Multi

WordPress core releases led and contributed to