AI Provider for Anthropic Max
Anthropic provider for the WordPress AI Client using Claude Max OAuth tokens with account pool rotation.
by Ultimate Multisite Community · github.com/ultimate-multisite/ai-provider-for-anthropic-max · website
Install
The author publishes release zips, so WP-CLI can install straight from GitHub:
wp plugin install https://github.com/ultimate-multisite/ai-provider-for-anthropic-max/releases/download/v1.3.1/ai-provider-for-anthropic-max-1.3.1.zipReadme
=== AI Provider for Anthropic Max === Contributors: superdav42 Tags: ai, anthropic, claude, openai, oauth Requires at least: 6.9 Tested up to: 7.1 Stable tag: 1.3.1 Requires PHP: 7.4 License: GPL-2.0-or-later License URI: https://www.gnu.org/licenses/gpl-2.0.html
Multi-provider OAuth account pool for the WordPress AI Client. Anthropic Max, OpenAI ChatGPT/Codex, and Google AI Pro.
== Description ==
This plugin extends the WordPress AI Client with OAuth-based account pools for paid AI subscriptions, so you can use your existing Anthropic Claude Max, OpenAI ChatGPT/Codex, or Google AI Pro plan from WordPress without per-token API billing.
Supported providers:
- Anthropic Max -- OAuth (PKCE) flow with
claude.ai. Pool with rotation, refresh, and cooldowns. Wired into the AI Client SDK asultimate-ai-connector-anthropic-max(full text/image/tool support). - OpenAI ChatGPT / Codex -- OAuth flow with
auth.openai.com. Paste the auth code from the localhost callback. Wired into the AI Client SDK asultimate-ai-connector-chatgpt-codex(text generation + tool use). - Google AI Pro / Ultra / Workspace Gemini -- OAuth PKCE flow with
accounts.google.com, using the Gemini CLI's published OAuth client. After signing in, paste the code shown on Google'scodeassist.google.comlanding page. Wired into the AI Client SDK asultimate-ai-connector-google-ai-pro(text generation; Imagen image generation is out of scope for the OAuth bearer flow and remains in the canonicalai-provider-for-googleplugin).
Pool features (all providers):
- Pool rotation -- Multiple accounts per provider with automatic failover.
- Auto-refresh -- Expired tokens are refreshed automatically when refresh tokens are available.
- Rate-limit cooldowns -- Rate-limited accounts rotate out and re-enter the pool after a configurable cooldown.
- Health checks -- Per-provider
/healthendpoint reports account status. - Connectors page -- Manage all three providers from
Settings > Connectorswith one card each.
Requirements by WordPress version:
- WordPress 7.0+ -- The AI Client SDK is included in core. This plugin works on its own.
- WordPress 6.9 -- Requires the AI Experiments plugin for the SDK.
How it works:
- Install and activate the plugin.
- Go to Settings > Connectors. You will see three cards: Anthropic Max, OpenAI ChatGPT/Codex, Google AI Pro.
- Click Set up on any card and authorize in a browser, then paste the returned code (OpenAI uses an in-page device code flow; Google shows the code on
codeassist.google.com). - Add as many accounts per provider as you like for pool rotation.
The plugin registers Anthropic Max as a separate provider (ultimate-ai-connector-anthropic-max) in the AI Client SDK and coexists with the standard API-key-based Anthropic provider.
== Installation ==
- Upload the plugin files to
/wp-content/plugins/ai-provider-for-anthropic-max/. - Activate the plugin through the 'Plugins' menu in WordPress.
- WordPress 6.9 only: Ensure the AI Experiments plugin is active.
- Go to Settings > Connectors and set up your Claude Max account(s).
== Frequently Asked Questions ==
= What is a Claude Max subscription? =
Claude Max is Anthropic's premium subscription plan that provides access to Claude models without per-token API billing. This plugin lets you use those subscription tokens within WordPress.
= Can I use this alongside the standard Anthropic provider? =
Yes. This plugin registers as "Anthropic Max" (ultimate-ai-connector-anthropic-max), separate from the standard "Anthropic" (anthropic) provider. Both can be active simultaneously.
= Why add multiple accounts? =
Multiple accounts provide failover. If one account hits a rate limit, the plugin automatically switches to the next available account.
= How are tokens stored? =
OAuth tokens are stored in the WordPress options table. Only site administrators with manage_options capability can manage the account pool.
== Changelog ==
= 1.3.1 = Version 1.3.1 - Released on 2026-08-19
- Improved: WordPress compatibility metadata now reflects testing through WordPress 7.1.
= 1.3.0 = Version 1.3.0 - Released on 2026-06-03
- New: Expanded the provider pool experience so OpenAI ChatGPT/Codex and Google AI Pro join the existing Anthropic Max OAuth pool workflow.
- New: Added full tool-support behavior for ChatGPT Codex in connector-supported operations.
- New: Removed the Cursor Pro provider and its setup pathways so only supported OAuth providers remain.
- Fix: Improved DELETE/refresh connector endpoints to validate emails and payloads more safely, including better save/remove failure handling.
- Fix: Added a manual OAuth fallback path for sandboxed setups so users can continue connecting accounts.
- Fix: Repaired Google AI Pro OAuth behavior and wired the provider integration for reliable SDK use.
- Fix: Fixed Anthropic tool-use payload handling for empty array and round-trip thinking signatures.
- Improved: Added tag-triggered release and deployment workflow, plus build/packaging tracking updates for release publishing.
- Improved: Synced release tooling metadata and updated static-analysis and planning config files used during CI and release prep.
= Unreleased =
- FIX: Google AI Pro OAuth flow was completely broken in 1.2.0. The configured OAuth client id (
681255809395-oo8ft6t5t0rnmhfqgpnkqtev5b9a2i5j.apps.googleusercontent.com) did not exist — Google returnedinvalid_client: The OAuth client was not found.Replaced with the live Gemini CLI Code Assist client id (oo8ft2oprdrnp9e3aqf6av3hmdib135j), added the matchingclient_secret(public per Google's installed-app spec — embedded in the open-source Gemini CLI), swapped the discontinued OOB redirect (urn:ietf:wg:oauth:2.0:oob, deprecated by Google 2022-10-03) for the Gemini CLI'shttps://codeassist.google.com/authcodepaste-code landing page, switched the scopes to the exact set used by Gemini CLI (cloud-platform,userinfo.email,userinfo.profile), switched the token endpoint content type toapplication/x-www-form-urlencoded(Google rejects JSON bodies), and replaced the API-key health-check endpoint withhttps://www.googleapis.com/oauth2/v2/userinfo(works with OAuth bearer tokens). - NEW: Google AI Pro is now wired into the AI Client SDK as
ultimate-ai-connector-google-ai-pro(text generation, function calling, web search). The newGoogleAiProProvider,GoogleOAuthRequestAuthentication,GoogleAiProModelMetadataDirectory, andGoogleAiProTextGenerationModelclasses mirror the patterns in the canonical WordPress.orgai-provider-for-googleplugin so request/response shapes are identical; only the auth header swaps fromX-Goog-Api-KeytoAuthorization: Bearer. Imagen image generation is intentionally out of scope here — OAuth bearer with thecloud-platformscope does not currently expose Imagen throughgenerativelanguage.googleapis.com, so the canonicalai-provider-for-googleplugin remains the recommended path for API-key-billed Imagen usage. - NEW:
ProviderConfig::$clientSecretfield for OAuth client types that require a secret on token exchange (Google). Anthropic and OpenAI use PKCE-only and leave it empty. Wired throughProviderPool::exchangeCode()andrefreshTokens()so the secret is sent when present. - REMOVED: Cursor Pro provider. The
cursorprovider entry, its Connectors card, themanual-tokenadd form, and the/anthropic-max-pool/v1/{provider}/manualREST route have all been removed. Anthropic Max, OpenAI ChatGPT/Codex, and Google AI Pro remain. If any sites stored data under theanthropic_max_oauth_pool_cursoroption key it is no longer read and can be deleted manually.
= 1.2.0 =
- NEW: multi-provider OAuth pool support. Adds OpenAI ChatGPT/Codex and Google AI Pro alongside Anthropic Max.
- Transient success/error feedback (add account, refresh, remove, health check) is dispatched on the
@wordpress/noticesstore and rendered by the global SnackbarList outside the card subtree, matching WP-core's connector pattern. Inline error display uses a plain banner withrole="alert"instead ofNotice. Persistent bodyNoticecomponents carry explicitpolitenessandspokenMessageprops. This avoids a deps-array race inside@wordpress/componentsuseSpokenMessagethat surfaced as "Cannot read properties of undefined (reading 'length')" during the device-code success-flip on add-account. - NEW: per-provider REST routes under
/anthropic-max-pool/v1/{provider}/(accounts,authorize,exchange,accounts/remove,accounts/refresh,health) plus a top-level/providersindex endpoint. Legacy/anthropic-max-pool/v1/accounts(and friends) remain Anthropic-only and unchanged for backward compatibility. - NEW:
src/OAuthPool/ProviderConfig.phpdeclares per-provider OAuth parameters (client id, endpoints, scopes, redirect, user-agent, health-check URL);ProviderPool.phpimplements the generic per-provider pool (load/save/list/add/remove/refresh/rotate/health);PoolRegistry.phpis the memoised pool factory.PoolManageris now a thin facade over the registry for the Anthropic pool, preserving every public method and constant used by 1.0/1.1 callers. - NEW: Connectors page now renders three cards (Anthropic Max, OpenAI ChatGPT/Codex, Google AI Pro) with provider-specific badges and OAuth forms.
- Stored option keys for new providers (
anthropic_max_oauth_pool_openai,..._google) are namespaced; the existinganthropic_max_oauth_poolkey for Anthropic is unchanged, so 1.1.0 installs upgrade in place with zero migration. - AI Client SDK provider classes for Google are out of scope for this release; pool storage and rotation are fully wired, and SDK integration ships in a follow-up.
= 1.1.0 =
- BREAKING: renamed the AI Client provider id from
anthropic-maxtoultimate-ai-connector-anthropic-maxfor consistency with the sister plugins (ultimate-ai-connector-webllm,ultimate-ai-connector-compatible-endpoints) and to claim the namespace properly. Code that calledAiClient::defaultRegistry()->getProvider('anthropic-max')must update the id. Stored OAuth tokens, REST endpoints, and option keys are unchanged so existing setups continue to work. - Improved: the JS-side
registerConnector()slug now matches the PHP provider id, so the WP core Connectors page renders one card instead of two (a previously-hidden duplicate auto-registered card with the generic API-key form is now suppressed). - Fix: re-assert our
registerConnector()call across multiple ticks (microtask + 0/50/250/1000 ms) so the WP coreregisterDefaultConnectors()auto-register can't clobber the custom card with the generic API-key UI. Necessary because matching the slug exposes us to the same race the other Ultimate-Multisite connector plugins hit. The proper upstream fix is in https://github.com/WordPress/gutenberg/pull/77116 — once that ships in a Gutenberg release, this workaround can be removed. - Fix: use
logoprop instead oficonfor ConnectorItem and add the MAX text icon to the registration config so the connector page renders the icon correctly.
= 1.0.0 =
- Initial release.
- OAuth PKCE flow for Claude Max authentication.
- Account pool with automatic rotation and rate-limit cooldowns.
- Auto-refresh of expired tokens.
- React-based Connectors page UI.
- Health check endpoint for monitoring account status.
- Full Anthropic Messages API support (text, images, documents, tools, web search).
Read the full README on GitHub →
Releases
| Tag | Published | Asset | Downloads |
|---|---|---|---|
| v1.3.1 | Aug 20, 2026 | ai-provider-for-anthropic-max-1.3.1.zip | 0 |
| v1.3.0 | Jun 3, 2026 | ai-provider-for-anthropic-max-1.3.0.zip | 1 |
| v1.3.0 | Jun 3, 2026 | ai-provider-for-anthropic-max.zip | 38 |
| v1.1.0 | Apr 9, 2026 | ai-provider-for-anthropic-max.zip | 78 |
Active-site estimate ≈60 comes from the median of recent superseded releases. Method.