WPCY Template Connector for Elementor template library
Find a file
wenpai d7e15803d3
All checks were successful
Release Plugin / release (push) Successful in 13s
Fix fatal error when installed with other WenPai plugins
The bundled updater declared a shared global class name WenPai_Updater,
which 22 WenPai plugins all ship a copy of. The file-level
class_exists() + return guard is not a safe conditional declaration and
was bypassed under certain opcache states, producing:

  Fatal error: Cannot declare class WenPai_Updater, because the name is
  already in use in .../includes/class-wenpai-updater.php on line 27

Reproduced on a customer site running this plugin alongside WPBridge:
with both active, every wp-admin request returned 500.

Rename the class to WPCY_Template_Connector_Updater so it no longer
occupies a shared name. Renaming one side is sufficient to resolve the
collision, and each plugin now uses the updater version it ships
instead of whichever copy happened to load first.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-07-27 15:18:26 +08:00
.forgejo/workflows Add WenPai updater release integration 2026-06-07 17:13:42 +08:00
includes Fix fatal error when installed with other WenPai plugins 2026-07-27 15:18:26 +08:00
.gitignore Document connector maintenance 2026-06-07 16:25:02 +08:00
README.md Complete plugin metadata 2026-06-07 17:30:26 +08:00
readme.txt Fix fatal error when installed with other WenPai plugins 2026-07-27 15:18:26 +08:00
wpcy-template-connector.php Fix fatal error when installed with other WenPai plugins 2026-07-27 15:18:26 +08:00

WPCY Template Connector

Author: WPCY.COM

Plugin URI: https://wpcy.com

Template API: https://templates.wpcy.net

Update API: https://updates.wenpai.net

Connect Elementor's remote template library to the WPCY template repository.

Plugin metadata

  • Plugin name: WPCY Template Connector
  • Author: WPCY.COM
  • Author URI: https://wpcy.com
  • Requires WordPress: 6.0+
  • Tested up to: 6.8
  • Requires PHP: 7.4+
  • Requires plugin: Elementor
  • License: GPL-2.0-or-later
  • Text domain: wpcy-template-connector

What it intercepts

  • my.elementor.com/api/connect/v1/library/templates
  • my.elementor.com/api/connect/v1/library/get_template_content
  • my.elementor.com/api/v1/templates/info/
  • Elementor Cloud Library resource endpoints

Current behavior

Version 1.0.4 prefers the native-compatible Worker endpoints:

  • GET /api/connect/v1/library/templates returns the Elementor remote template JSON array.
  • GET /api/v1/templates/info/ returns templates, categories, types_data, and config.
  • POST /api/connect/v1/library/get_template_content returns {content, page_settings}.

Legacy /api/templates and /api/template/{id} are still kept as fallback paths.

Updates

The plugin declares Update URI: https://updates.wenpai.net and bundles WenPai updater support so WordPress can receive package updates from the WenPai/FeiCode update channel.

Settings page

Open Elementor → Connector in wp-admin to view connector status, run endpoint diagnostics, and clear Elementor remote template cache.

Install

Copy this directory to:

wp-content/plugins/wpcy-template-connector/

Then activate WPCY Template Connector in WordPress.

Verify

php -l wpcy-template-connector.php
php -l includes/class-wenpai-updater.php

In Elementor, open the Template Library and import a remote template.