Wegly

Сүрөттөө

Wegly connects popular WordPress form builders to the Wegly public API.

With this plugin you can:

  • Send submissions from Contact Form 7, WPForms, and Elementor Forms.
  • Create either leads or deals in Wegly.
  • Configure feeds with a guided wizard directly from the Wegly sidebar menu in the WordPress admin.
  • Map form fields to Wegly fields without writing code.
  • Combine multiple note fields into one readable Markdown note and optionally pin it.
  • Install the Wegly Lead Chatbot and WhatsApp button by pasting their official snippets.
  • Show widgets site-wide, only on selected pages, or everywhere except selected pages.
  • Use different chatbots and WhatsApp buttons on different pages with per-page variations.
  • Collapse individual form feeds or expand and collapse all feeds together.
  • Track existing WhatsApp links and buttons by pasting the official External WhatsApp Tracking snippet.
  • Navigate integrations through a guided tabbed interface and welcome experience.
  • Optionally capture UTM parameters (including utm_medium), click IDs, conversion URL, IP address, and user agent.
  • Store the Wegly API token encrypted in the WordPress database.
  • Review technical delivery logs and clear them directly in the admin panel.

Supported providers

  • Contact Form 7
  • WPForms
  • Elementor Forms

External services

This plugin connects to the Wegly API to send form submissions to your Wegly CRM workspace.

The plugin is free software. Its integrations require an active Wegly service account, which may require a paid subscription. Processing and storing CRM records, publishing widgets, and reporting WhatsApp interactions are provided by the external Wegly service. The plugin does not impose trials or license restrictions on its own included functionality.

API requests and widget scripts are restricted to HTTPS on api.wegly.com.br. Only the three documented widget script paths are accepted. Pasted installation snippets are parsed into validated settings; arbitrary JavaScript is not saved for execution on the site.

The legacy addresses https://api.wegly.com and https://api.wegly.com/v1 are recognized only to migrate old settings to https://api.wegly.com.br. The plugin does not make requests to those legacy addresses.

Form submissions and field configuration

Form submissions go to https://api.wegly.com.br/integrations/external/leads or https://api.wegly.com.br/integrations/external/deals to create CRM records. These server-to-server requests include the configured API token in the Authorization header and the site’s home URL in the Referer header.

Form submissions are sent only when:

  • A site administrator configures the plugin with a valid Wegly API token.
  • At least one feed is enabled.
  • A supported form is submitted.

When an administrator opens the Wegly settings page with a saved API token, the plugin also requests https://api.wegly.com.br/integrations/external/custom-fields to populate the field mapping choices. These read requests send the API token, the site’s home URL, and status/pagination parameters; they do not send form submissions. This lookup does not require an enabled feed.

The data included in form submissions depends on the configured feed and tracking settings:

  • Mapped form field values such as name, email, phone, title, organization, message, and custom fields.
  • Marketing attribution data such as utm_*, gclid, fbclid, fbc, fbp, and ga_client_id.
  • Technical metadata such as the conversion URL, IP address, and browser user agent.

Lead Chatbot and WhatsApp button

When an administrator enables either widget, its public Wegly script loads on frontend pages allowed by that widget’s page rules. The public widget key identifies the configuration published in the customer’s Wegly workspace. Information visitors enter in the widget is sent directly to the Wegly API to capture leads or support WhatsApp contact, according to that configuration. These integrations do not use the form API token and work independently of form feeds.

External WhatsApp Tracking

When an administrator enables External WhatsApp Tracking, its public Wegly script loads on frontend pages to track clicks on existing WhatsApp links and buttons. The public tracking ID identifies the customer’s tracking configuration. The script may send click events, marketing attribution, page URLs, and browser metadata directly to Wegly according to that configuration. This integration works independently of form feeds and the form API token.

For all three public scripts, the visitor’s browser connects directly to the Wegly service. The service receives the visitor’s IP address and the HTTP headers sent by the browser, which may include the user agent and referrer. Visitor consent for these widgets is managed separately from the plugin’s optional form attribution setting.

Service provider and policies

Service provider:

Privacy and local storage

Automatic attribution for connected forms is optional and disabled by default on new installations. Existing saved preferences are preserved. When enabled with an active form feed, the plugin can store attribution cookies for up to 90 days. The cookies are prefixed with wegly_: campaign parameters, gclid, fbclid, page_url, url_conversion, fbc, fbp, and ga_client_id. The plugin can copy identifiers from existing _ga, _fbc, and _fbp cookies; it does not create or delete those original third-party cookies. Stored page URLs omit fragments but may include query parameters.

Disabling automatic tracking stops automatically collected marketing fields, conversion URLs, IP addresses, and user agents from being included in form payloads. The plugin removes its attribution cookies on the visitor’s next page visit and preserves consent preferences. Explicit field mappings and structural form metadata (provider, form ID/hash/name, submission ID, and site URL) remain available. Review your field mappings and cache settings when changing tracking preferences.

Technical delivery logs contain event codes, timestamps, form/feed/submission identifiers, provider, resource, request method, and HTTP status. They do not retain form contents, contact details, visitor IP addresses, tokens, raw errors, or API response bodies. Logs are limited to 100 entries. Entries older than seven days are removed during the next daily WordPress cron run or log access; cron execution depends on site traffic or your configured cron runner. Existing sensitive log fields are removed during the upgrade’s first initialization or the next log access. Administrators can immediately delete all logs from the settings page. Uninstalling deletes plugin settings, logs, and scheduled cleanup tasks, including across a multisite network.

Consent integration for form attribution

The automatic tracking setting is an administrator choice, not proof of visitor consent. Configure your consent management platform before enabling attribution where visitor consent is required. This section applies to the plugin’s local form attribution. The three public Wegly widgets use their own service configuration and are controlled separately in the plugin.

The local script respects an explicit denied value for ad_storage, ad_user_data, or analytics_storage in global Google Consent Mode default/update commands in window.dataLayer. Region-specific defaults are not resolved by the plugin; use the explicit event below for the visitor’s effective choice. Consent changes in the data layer are checked once per second. Initialize consent before the plugin’s script loads to prevent initial collection.

A consent manager can communicate the visitor’s choice using:

window.dispatchEvent(new CustomEvent('wegly:tracking-consent', { detail: { granted: false } }));

Use granted: true to allow attribution again, provided Google Consent Mode is not denying it. A denial from either source takes precedence. The event’s choice is stored in wegly_tracking_cmp_consent; the effective decision is stored in wegly_tracking_consent. Denial clears the plugin’s attribution cookies and the effective denied marker also blocks automatic tracking data in subsequent PHP form submissions. Both preference cookies last up to 90 days and remain when the administrator disables attribution. Without an explicit choice, collection follows the administrator’s automatic tracking setting. Cached pages must still allow the consent script to run.

Server-side integrations can return false from the wegly_tracking_allowed filter (arguments: current permission and normalized submission) to suppress automatic tracking values in form payloads. For example: add_filter('wegly_tracking_allowed', '__return_false');. This filter controls outgoing form data; the browser consent event controls cookie collection. Neither changes manually mapped fields or the independent Wegly widgets.

Орнотуу

  1. Upload the plugin files to the /wp-content/plugins/wegly/ directory, or install the plugin through the WordPress plugins screen.
  2. Activate the plugin through the Plugins screen in WordPress.
  3. Open Wegly directly from the WordPress sidebar.
  4. Enter your Wegly API token.
  5. Create a feed, choose the form provider, select a form, and map the fields you want to send.
  6. Save the settings and submit the form to test the integration.

For External WhatsApp Tracking, open the Rastreamento de WhatsApp Externo tab in Wegly, paste the installation code generated in your Wegly workspace, enable the integration, and save. Clear your site’s cache after saving. The script is loaded in the footer and tracks the existing WhatsApp links and buttons configured in Wegly.

The Lead Chatbot and WhatsApp button have equivalent installation tabs. These three snippet integrations do not require a form feed or the form API token. Their public script endpoints must be available in the Wegly service.

FAQ.KG

Do I need all supported form plugins installed?

No. You only need the form plugin you want to connect. The plugin detects supported providers automatically.

Can I create leads and deals?

Yes. Each feed can be configured to create either a lead or a deal in Wegly.

Does the plugin send tracking data automatically?

Only when automatic tracking is enabled for active form feeds and has not been explicitly denied through the documented consent integration. Review the privacy and consent sections above. The separate Wegly widgets follow their own settings.

How do widget page rules and variations work?

In the Lead Chatbot or WhatsApp button tab, choose all pages, selected pages only, or all pages except the selected ones. The rule applies to both the default component and all its variations. The page picker lists WordPress pages and the site homepage; site-wide rules also cover posts and archives.

Add a variation, select its pages, and paste that component’s official Wegly snippet. An active matching variation replaces the default component. Only one variation per integration can be active on a given page. If no active variation matches, the default component is used. Leave its code blank to display only the configured variations. The integration’s main activation switch controls both the default and variations. These page rules do not affect External WhatsApp Tracking, which keeps its independent site-wide switch.

Can I collapse form feeds without losing their mappings?

Yes. Existing feeds start collapsed with their status, provider, form, and destination visible. Expand one to edit it, or use the expand/collapse-all controls. New feeds open automatically. Collapsing does not change feed settings or mappings.

Does this plugin work without a Wegly account?

No. You need an active Wegly account and a valid API token to send form submissions. Public widget integrations use the installation code generated by the service. A Wegly subscription may be required.

Сын-пикирлер

There are no reviews for this plugin.

Contributors & Developers

“Wegly” is open source software. The following people have contributed to this plugin.

Мүчөлөрү

Translate “Wegly” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Өзгөртүүлөр

1.3.4

  • Sanitize administrative request values and notice nonces before use, with separate validation for JSON feeds, widget snippets, and API tokens.
  • Clarify that installation snippets are displayed as escaped text and frontend resources use the WordPress enqueue APIs.
  • Expand external-service documentation with administrative field lookups, request data, widget activation conditions, and legacy URL migration.

1.3.3

  • Add page inclusion and exclusion rules for Lead Chatbot and WhatsApp button integrations.
  • Add per-page widget variations with one active variation per page and integration.
  • Keep existing widget configurations working site-wide without migration steps.
  • Add collapsible feed cards with summaries and expand/collapse-all controls.
  • Preserve External WhatsApp Tracking, consent and privacy controls, HTTPS snippet validation, translations, and utm_medium attribution when combining the integrations.

1.3.2

  • Fix automatic form attribution when WordPress provides the enabled setting as a string.
  • Preserve boolean tracking settings in frontend configuration and accept the previous enabled representation.
  • Capture utm_medium and send it as marketing.utm_medium, with automatic and explicit mappings for leads and deals.

1.3.1

  • Restrict API requests and widget URLs to the official HTTPS origin; prevent authenticated redirects to other origins.
  • Revalidate stored widget settings while preserving compatible installation snippets from earlier versions.
  • Respect the form tracking setting and explicit consent denial in both browser attribution and outgoing form payloads.
  • Replace detailed request logs with limited technical metadata, seven-day retention, scheduled cleanup, and an administrator-only clear action.
  • Clean plugin data and scheduled events across multisite networks on uninstall.
  • Make the settings interface translatable and improve labels, keyboard focus, integration selection, and status announcements.
  • Document the external service, privacy policy, terms of use, cookie behavior, and consent integration.

1.3.0

  • Add an External WhatsApp Tracking tab with snippet installation and activation controls.
  • Validate the official tracking script URL and public tracking ID before saving.
  • Load the tracker asynchronously with its tracking ID, independently of form feeds and the existing widgets.

1.2.0

  • Add a welcome experience and integration tabs inspired by guided WordPress setup flows.
  • Add validated snippet installation for the Wegly Lead Chatbot.
  • Add validated snippet installation for the Wegly WhatsApp button.
  • Load enabled widgets safely through the WordPress script API.

1.1.0

  • Move Wegly settings to its own top-level WordPress admin menu.
  • Combine multiple fields mapped to a note into labeled Markdown sections.
  • Add a per-feed option to pin the received note.

1.0.0

  • Initial public release.
  • Support for Contact Form 7, WPForms, and Elementor Forms.
  • Lead and deal delivery through the Wegly public API.
  • Guided feed wizard and detailed request logging.
  • Encrypted storage for the Wegly API token.