Connect local WordPress to cloud services
Cloud Gateway bridges your WordPress installation with LemonX services for licensing, entitlements, AI routing and advanced product capabilities.
LemonX Cloud Gateway connects WordPress websites with the cloud-powered services required to run advanced AI, licensing, product entitlement, usage tracking, secure updates and premium LemonX workflows.
It gives developers a controlled bridge between a self-hosted WordPress site and LemonX cloud services — without forcing every sensitive operation to live directly inside the WordPress database.
Site-bound · License-aware · Usage-tracked · Built for secure WordPress AI workflows
LemonX Cloud Gateway is the secure service layer that helps LemonX-powered WordPress sites communicate with LemonX cloud infrastructure. It can support license verification, plan entitlements, AI gateway routing, usage quotas, secure update checks, premium feature access, agency site management and enterprise-level controls.
For developers, Cloud Gateway provides a predictable way to connect local WordPress functionality with cloud-based capabilities while preserving permission checks, site identity, product access and usage visibility.
Cloud Gateway bridges your WordPress installation with LemonX services for licensing, entitlements, AI routing and advanced product capabilities.
Product access can be checked against license status, plan level, site identity and enabled modules.
AI calls, translation volume, indexing requests, MCP actions, report generation and cloud tasks can be measured and controlled.
Agencies, developers and enterprise teams can manage advanced workflows across one site or many sites.
A normal WordPress plugin can store options, render admin pages and run local PHP code. But an AI-powered growth suite needs more: license validation, usage controls, AI provider routing, plan-based entitlements, secure update delivery, cloud-based processing, multi-site account awareness and reliable service orchestration.
Cloud Gateway provides that missing layer.
LemonX Cloud Gateway sits between the local WordPress site and LemonX cloud services. It does not replace WordPress. It extends WordPress with secure, plan-aware, cloud-connected capabilities.
Runs inside WordPress and handles local admin UI, settings, content workflows, permissions, REST API, MCP tools and module logic.
Verifies the local user, site token, API key, MCP session or gateway credential before requests are made.
Confirms which WordPress site is communicating with the gateway and whether it is authorized.
Checks whether the site has access to requested products and premium features.
Records and limits AI calls, translation usage, indexing actions, cloud operations and other measured events.
Provides advanced LemonX services such as AI routing, secure update validation, premium processing and enterprise workflows.
Returns structured responses to WordPress and records important actions for visibility, debugging and auditability.
Cloud Gateway can verify whether a WordPress site has a valid LemonX license, whether the license is active, whether the site is bound to the license and whether the current plan allows the requested feature.
Entitlements define what a site, license, plan or account is allowed to use. Cloud Gateway can help LemonX modules determine whether specific features should be enabled.
Cloud Gateway can record and return usage data so users and developers understand how product limits are being consumed.
Cloud Gateway can help route AI requests to supported models and providers based on product context, plan level, usage limits, fallback rules and availability.
Cloud Gateway can help verify update eligibility, deliver premium update metadata and ensure that licensed users receive appropriate plugin and theme updates.
Agencies often manage multiple WordPress sites. Cloud Gateway can provide a shared account layer that tracks site activations, licenses, usage, entitlements and product access across client properties.
Enterprise teams may need stronger controls over AI providers, usage, permissions, cloud connectivity and auditability. Cloud Gateway can support enterprise governance features that go beyond normal plugin settings.
A LemonX module initiates a cloud-connected action such as license verification, AI routing, usage sync or entitlement check.
WordPress verifies the local user, capability, nonce, API key, MCP context or background task permission.
The plugin prepares a request with site identity, product context, feature request and authentication data.
Cloud Gateway confirms that the request comes from a recognized and authorized site.
The gateway verifies whether the site, plan and product are allowed to use the requested feature.
The gateway checks whether the requested action is within allowed usage limits.
The requested cloud-connected operation is performed.
The gateway returns success, data, task ID, usage update or error information.
The local plugin updates the admin UI, task status, report, usage panel or activity log.
The following endpoints are developer-facing examples that describe the type of resources Cloud Gateway may expose or support. Final endpoint names should match the active LemonX implementation.
POST /gateway/v1/license/activate POST /gateway/v1/license/deactivate GET /gateway/v1/license/status POST /gateway/v1/license/refresh
GET /gateway/v1/entitlements POST /gateway/v1/entitlements/check GET /gateway/v1/products GET /gateway/v1/features
POST /gateway/v1/usage/record GET /gateway/v1/usage/summary GET /gateway/v1/usage/limits GET /gateway/v1/usage/history
POST /gateway/v1/ai/generate POST /gateway/v1/ai/route GET /gateway/v1/ai/providers GET /gateway/v1/ai/models
POST /gateway/v1/sites/register GET /gateway/v1/sites/status POST /gateway/v1/sites/sync POST /gateway/v1/sites/disconnect
GET /gateway/v1/updates/check GET /gateway/v1/updates/package POST /gateway/v1/updates/verify
GET /gateway/v1/agency/sites GET /gateway/v1/agency/usage GET /gateway/v1/agency/entitlements GET /gateway/v1/agency/reports
Developers may also access gateway-related state through LemonX local REST API endpoints inside WordPress. These endpoints can help admin dashboards, agency tools and integrations inspect gateway status without calling the cloud directly.
GET /wp-json/lemonx/v1/pro/cloud/status GET /wp-json/lemonx/v1/pro/license GET /wp-json/lemonx/v1/pro/entitlements GET /wp-json/lemonx/v1/pro/usage POST /wp-json/lemonx/v1/pro/license/activate POST /wp-json/lemonx/v1/pro/license/deactivate POST /wp-json/lemonx/v1/pro/cloud/sync
Cloud Gateway authentication should confirm the local site identity, account/license state and request integrity. The gateway should not rely on user-provided data alone.
{
"success": true,
"entitlement": {
"feature": "aeo.ai_citation_tracking",
"allowed": true,
"plan": "agency",
"expires_at": "2027-07-04T00:00:00Z"
}
}{
"success": false,
"error": {
"code": "entitlement_required",
"message": "This feature requires LemonX AEO Pro.",
"required_plan": "pro"
}
}Usage tracking should be reliable, but it should not make the user experience slow or fragile. Some usage events can be recorded synchronously, while others can be queued and synced in batches.
{
"event": "ai.generation.completed",
"site_id": "site_123",
"product": "code",
"feature": "page_generation",
"model": "premium-model",
"units": 1,
"tokens_input": 2400,
"tokens_output": 1800,
"timestamp": "2026-07-04T10:00:00Z"
}Different LemonX workflows may need different AI models. A bulk translation task, an AEO analysis, a page generation request and an MCP content edit may not require the same provider, speed, cost or quality level.
Cloud Gateway can support product-aware AI routing.
LemonX Pro and premium product modules may require secure update checks. Cloud Gateway can help verify whether a site is allowed to receive a specific update package or release channel.
Agencies can connect multiple client sites under one account and monitor activation status, plan access and product availability.
Agencies can understand which sites are using the most AI, translation, indexing or MCP activity.
Cloud Gateway can support centralized report access, helping agencies show SEO, translation, MCP and growth activity.
Agencies can allocate license seats or product access across client websites.
When an agency plan changes, connected sites can refresh entitlements through Cloud Gateway.
Agencies can detect disconnected sites, expired licenses, failed syncs or usage warnings.
Enterprise accounts can define which AI providers are allowed.
Organizations can limit AI, translation or cloud usage by department, site or project.
Enterprise teams can export logs for security review and compliance workflows.
Certain plans may route AI or cloud workflows through approved infrastructure.
Administrators can enable or disable product features across multiple properties.
Gateway can help identify plan level, support priority and service context.
| Error Code | Meaning | Recommended Action |
|---|---|---|
| gateway_unavailable | Gateway cannot be reached | Retry later or check connection |
| invalid_site | Site identity is missing or invalid | Reconnect site |
| license_invalid | License key is invalid | Check license |
| license_expired | License is expired | Renew license |
| entitlement_required | Feature is not included in plan | Upgrade plan |
| quota_exceeded | Usage limit reached | Upgrade or wait for reset |
| signature_invalid | Request signature failed | Check token and request signing |
| token_expired | Gateway token expired | Refresh token |
| product_inactive | Required product is inactive | Enable product |
| provider_unavailable | AI provider route failed | Retry or use fallback |
| update_not_allowed | Site cannot access update | Check license and channel |
| rate_limited | Too many requests | Reduce request frequency |
Best Practice: Error messages should help developers fix the problem without exposing sensitive information.
Developers and site owners need visibility into whether Cloud Gateway is connected and functioning. Health checks help diagnose licensing, entitlement, update, usage and AI gateway issues.
{
"success": true,
"gateway": {
"connected": true,
"last_sync": "2026-07-04T10:00:00Z",
"license": "active",
"entitlements": "synced",
"usage": "synced",
"cloud_token": "valid"
},
"products": {
"aeo": "active",
"code": "active",
"verto": "active",
"mcp": "active",
"pro": "active"
}
}Gateway credentials should only be used server-side.
Do not rely only on domain names. Use site-bound identity where possible.
Use request signing for license, entitlement, usage and secure update actions.
Avoid running expensive tasks before verifying access.
Prevent runaway automation and unexpected costs.
Retry transient gateway errors, but avoid infinite loops.
If a non-critical gateway sync fails, keep the admin UI usable and show a clear warning.
Use request IDs to debug issues across WordPress and cloud services.
Staging sites should use separate identities, usage records and update channels.
Only send data required for the requested cloud workflow.
Cloud Gateway should be designed around data minimization. Some workflows require only license and site metadata. Others may require AI prompt data, translation content or usage details. Developers should understand what each workflow sends.
Developer Recommendation: For each gateway-connected workflow, document what data is sent, why it is needed and how it is protected.
Best when the task can be completed entirely inside WordPress.
Best when the task requires account, license, cloud, usage or advanced service context.
Summary: Use WordPress locally when local execution is enough. Use Cloud Gateway when the workflow needs secure cloud-connected context.
Result: Users only see features available to their plan.
Result: AI usage stays visible and controlled.
Result: Translation workflows follow plan, language and provider rules.
Result: Premium updates are delivered only to eligible sites.
Result: Agencies can monitor client sites from one account layer.
Use LemonX Cloud Gateway to connect local WordPress functionality with secure licensing, AI routing, usage tracking, premium access and agency-ready cloud services.
Keep WordPress local where it should be local. Use Cloud Gateway where licensing, entitlements, usage, AI routing, secure updates and multi-site workflows need a trusted cloud layer.