Skip to main content

WordFex Plugin for WordPress

WordFex automatically syncs new WordPress user registration data with your Perfex CRM installation using the Perfex REST API. Every time a user or customer registers on your WordPress site, their data is pushed to Perfex CRM as either a Customer or a Lead.

Overviewโ€‹

  • Author: Themesic
  • Sync Targets: Perfex CRM Customers or Leads
  • Integration Method: Perfex REST API

Requirementsโ€‹

Before installing WordFex, ensure you have the following:

  • A working WordPress installation (self-hosted)
  • An active Perfex CRM installation
  • The Perfex REST API module installed and activated in Perfex CRM (separate purchase)
warning

The Perfex REST API module is required for WordFex to function. It must be purchased and installed separately in your Perfex CRM instance.

Installationโ€‹

  1. Extract the downloaded archive and locate the upload.zip file.
  2. In your WordPress admin panel, navigate to Plugins โ†’ Add New.
  3. Click Upload Plugin, select the upload.zip file, and press Install Now.
  4. Click Activate to enable the plugin.
  5. After activation, a new WordFex menu item will appear under Settings in the WordPress admin sidebar.

Configurationโ€‹

Navigate to Settings โ†’ WordFex in your WordPress admin panel. You will need to configure the following settings:

1. Perfex Installation URLโ€‹

Enter the base URL of your Perfex CRM installation.

info

Use your Perfex installation URL โ€” not the admin panel URL. For example, use https://crm.example.com rather than https://crm.example.com/admin.

2. Perfex API Keyโ€‹

Generate an API key from your Perfex CRM:

  1. Log in to your Perfex CRM admin panel.
  2. Navigate to the REST API Module โ†’ API โ†’ API Management.
  3. Click Create new token.
  4. Copy the generated token and paste it into the Perfex API Key field in WordFex settings.

3. Sync Methodโ€‹

Choose how new registrations are synced with Perfex CRM:

ValueBehavior
customersNew registrations sync as Perfex Customers
leadsNew registrations sync as Perfex Leads

4. Leads Group Nameโ€‹

Set the Lead Group ID for synced leads. This field accepts the numeric ID of the target lead group in Perfex CRM.

  • The default value is 1 (the primary lead group).
  • To use a custom group, create a new group in Perfex CRM (e.g., "Website") and enter its numeric ID here.
tip

This setting is only used when the Sync Method is set to leads. It is ignored when syncing with Customers.

After configuring all fields, click Save Changes. Data will now sync automatically on every new user or customer registration.

Troubleshootingโ€‹

WordFex logs output to the following file on your server:

/wp-content/plugins/wordfex/lastoutput.txt

Review this file if syncing is not working as expected. Below are common error messages and their solutions:

"Wrong number of segments"โ€‹

Cause: The API key is invalid or incorrectly copied.

Solution: Verify that the API key in WordFex settings matches the token generated in Perfex CRM. Re-copy the token without any trailing spaces.

"Malformed UTF-8 Characters"โ€‹

Cause: The API key contains invalid characters or was corrupted during copy-paste.

Solution: Generate a new API token in Perfex CRM and paste it again.

HTML response containing "The action you have requested is not allowed."โ€‹

Cause: Perfex CRM's CSRF protection is blocking API requests.

Solution: You have two options:

  1. Replace the /application/config/config.php file in your Perfex CRM installation with the version provided by the REST API module.
  2. Add an exception for the /api/ endpoints in your CSRF protection configuration.
warning

Modifying CSRF settings affects your CRM's security. Only apply changes recommended by the REST API module documentation.

Customizationsโ€‹

Need to sync custom WordPress or WooCommerce fields with Perfex CRM? Contact Themesic support for custom field mapping solutions.

Supportโ€‹

If you encounter any issues or need assistance, visit the Themesic support portal:

https://themesic.com/support