Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/aiiddqd/ai-connector-openrouter-wordpress/archive/refs/heads/main.zipNo built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.
OpenRouter Connector for WordPress
OpenRouter Connector for WordPress adds an AI provider connector via the WordPress 7.0 Connectors API, so site owners can configure OpenRouter as an AI backend from a native admin screen. The plugin registers an ai_provider connector with api_key authentication, exposes a credentials link, and integrates with the WP AI Client for automatic provider discovery.
WordPress AI API — Documentation
WP Plugin and PHP AI Client SDK
- WordPress AI plugin — the official AI plugin, built on top of the PHP SDK; primary consumer of provider connectors; source of truth for AI features and experiments in WP Admin
- wordpress/php-ai-client on GitHub — provider-agnostic PHP SDK bundled in WP 7.0 core;
AiClient,PromptBuilder, provider registry - wp-ai-client WordPress plugin (deprecated in 7.0+) — the predecessor plugin; REST API endpoints and JS API still active
Core Announcements (WordPress 7.0)
- Introducing the AI Client in WordPress 7.0 —
wp_ai_client_prompt(), builder methods, feature detection, REST integration - Introducing the Connectors API in WordPress 7.0 — connector registration, API key management, admin UI,
wp_connectors_init - WordPress 7.0 Beta 1 announcement — overview of all new features
- WordPress 7.0 Developer Notes (all) — full list of dev notes for the release
Official Provider Plugin Examples
- AI Provider for OpenAI — reference implementation;
AbstractApiProvider,AbstractOpenAiCompatibleModelMetadataDirectory - Call for testing: Community AI connector plugins — guidance for third-party provider plugins
OpenRouter
- OpenRouter API docs — OpenAI-compatible API, model IDs, authentication
- OpenRouter models list — all available models with IDs (format:
provider/model) - OpenRouter API keys — create and manage API keys
Local Development
Prerequisites
- Node.js LTS + npm
@wordpress/envinstalled globally:npm -g i @wordpress/env
The local environment uses WordPress Playground (no Docker required) with WordPress 7.0 RC2 and PHP 8.3.
Start
wp-env start --runtime=playground
- Development site: http://localhost:8888
- Admin:
admin/password
The plugin is automatically mounted and activated.
Stop
wp-env stop
Reset database
wp-env reset
wp-env start --runtime=playground
Update WordPress / re-apply config
wp-env start --runtime=playground --update
Notes
- Debug log is enabled — errors are written to
wp-content/debug.loginside the environment. - If you need WP-CLI or Composer inside the container, switch to the Docker runtime (remove
--runtime=playground). Docker Desktop must be running. - Get started with wp-env — official quick-start guide
- @wordpress/env package reference — full command reference,
.wp-env.jsonschema - Quick and easy local WordPress development with wp-env — WordPress Developer Blog overview