Lead Analytics for Pipedrive
WordPress plugin: Lead Analytics for Pipedrive — observe form→Pipedrive submissions and unlock Pipedrive insights.
by Krikir Technologies · github.com/jskrishna/lead-analytics-for-pipedrive
Install
No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:
wp plugin install https://github.com/jskrishna/lead-analytics-for-pipedrive/archive/refs/heads/main.zipForm leads from your site — how many reached Pipedrive, which failed, and what the team did next. One API token per site.
Description
This plugin does not send leads. Whatever already sends them — a theme, a custom plugin, a form add-on — keeps doing exactly that. This plugin watches, records and reports, so it can be added to a working site without changing how anything behaves.
The one thing it can add, when you ask it to, is a label: pick a Pipedrive label per form on the Forms tab ("Website Newsletter", for example) and every new lead from that form carries it. The label goes into the same request that creates the lead, so it costs no extra call and no delay for the visitor. A label that does not exist in Pipedrive yet is created once, when you save.
For every submission it records which form it came from, whether the lead reached Pipedrive, and the reason when it did not (an invalid token, a timeout, a rejected field). It then reads the lead back from Pipedrive to show whether the team opened it, which label it carries, and whether it became a deal.
Each site keeps its own API token, stored per site, so a multisite network can send each site's leads to a different Pipedrive account. The token is validated with Pipedrive before it is saved, is never shown in full, and is sent in a request header rather than a URL.
External service: Pipedrive
This plugin is an interface to the Pipedrive CRM API (api.pipedrive.com). It contacts Pipedrive only after you paste an API token on the Connection tab (or supply one via site wiring): to validate that token, to read lead and deal status for submissions this site already logged, and — when you choose a per-form label — to resolve or create that label and attach it on lead create.
Pipedrive’s terms and privacy:
- Terms of Service: https://www.pipedrive.com/en/terms-of-service
- Privacy Notice: https://www.pipedrive.com/en/privacy
- API documentation: https://developers.pipedrive.com/docs/api/v1
Installing and connecting a token is consent for that documented service (Guideline 6 / 7). The plugin does not phone home to Krikir or any other third party.
Screens
Each site gets one Lead Analytics menu with four tabs:
- Overview — the five numbers that matter, submissions over time, top forms, and the latest five submissions. A red bar appears the moment something does not reach Pipedrive.
- Submissions — the full list, with search, a form filter, a delivery filter, paging and CSV export. Every row expands to the exact Pipedrive calls made for it, their status codes and any error, which is usually enough to explain a failure without touching a log file.
- Forms — every form with its submissions, delivery, opened and deal counts, and a jump into the filtered list. Forms with no Pipedrive integration are marked, not hidden.
- Connection — this site's token, a connection test, failure alerts, and clearing test data before launch.
Pipedrive is read at most once every 15 minutes per site, in the background, so the dashboard itself always answers from the site's own database.
On multisite, Network Admin → Lead Analytics adds an all-sites table plus each site's connection, and warns when two sites share one Pipedrive account.
Connecting your own site
Out of the box the plugin stores its token in the lafp_api_token option and knows of no senders, so every form shows as "not connected". It does not require any particular form plugin. Optional observe adapters load when their host plugin is active: Gravity Forms, Contact Form 7, Elementor Forms, and Ninja Forms (integrations/). For site-specific wiring, copy integrations/example-integration.php.example to a *.php file in the same folder (the example is not loaded at runtime and is not in the WordPress.org zip):
lafp_token_option— the option name your existing code already reads the token from.lafp_default_token— a shared fallback token (defaults to thePIPEDRIVE_API_TOKENconstant, if defined).lafp_pipedrive_senders— callables that create Pipedrive leads (adapters use this to mark sources connected).lafp_source_is_connected— whether a source key (gf:12,cf7:3,ajax:…) is wired to Pipedrive.lafp_known_forms— forms to list before any submissions exist (key => title, connected).lafp_entry_url— admin URL for the original entry; return empty to hide Entry.lafp_form_is_connected— legacy per-form check (preferlafp_source_is_connected).lafp_ajax_lead_actions—admin-ajax action => labelfor submissions that do not go through a form plugin.lafp_can_edit_token— who may change a site's token (defaults tomanage_options).
Use LAFP_Tracker::open( $ctx ) from any form plugin to start capture for a submission. The action lafp_submission_logged fires after each recorded submission, with the row as its argument.
Credits
Built by Krikir Technologies, https://www.krikir.com
- No bundled libraries or CDN assets. Chart is plain SVG from PHP; CSS and JS ship with the plugin.
- Contacts only
api.pipedrive.com— to check the token and read leads this site created. - Licensed GPL-2.0-or-later. Full text in
LICENSE.
Privacy
- For each submission the plugin stores the time, the form, the contact name and email, the delivery result, and the Pipedrive lead and person IDs, in its own table on the site that received the submission. This is the same contact data the form plugin already keeps.
- API tokens are stored as a site option, shown only as the last four characters, and sent to Pipedrive in a request header rather than in a URL, so they do not end up in server logs.
- Clear analytics data on the Connection tab deletes every stored row for that site. Deleting the plugin removes its table, its options and its caches, and leaves the API token and your Pipedrive data alone.
- Leads are created in Pipedrive by the code that was already doing so; this plugin does not send personal data anywhere new, except the Pipedrive calls described under “External service: Pipedrive” (token check, insights refresh, optional label on create).
- Pipedrive processes data under its own terms and privacy notice: https://www.pipedrive.com/en/terms-of-service and https://www.pipedrive.com/en/privacy
Screenshots
- Overview dashboard with delivery stats and Pipedrive insights.
- Submissions list with filters and per-row API call details.
- Forms tab with per-form labels and delivery counts.
- Connection tab for the site API token and failure alerts.
Frequently Asked Questions
Does it change how leads are sent?
No. It records what happens and manages the token. The only change it can make to a lead is adding the label you chose for that form on the Forms tab; leave the label empty and the request goes out untouched.
What happens if I deactivate it?
Leads keep flowing. You lose the dashboard, not the integration. Saved tokens stay where they are.
Does it store personal data?
It stores the name and email of each submission, the same data your form plugin already keeps, in its own table per site. "Clear analytics data" deletes all of it.
Changelog
1.9.0
- Renamed the code prefix from
pda_/PDA_tolafp_/LAFP_(Lead Analytics For Pipedrive) for a clearer WordPress.org-facing prefix. Existingpda_*options and thepda_logtable migrate automatically; legacypda_*filters still work as aliases. - Migration waits for the log table before rewriting
form→gfrows. - Added PHPUnit suite (
composer test).
1.8.2
- Migration waits for the log table (and creates it if needed) before rewriting
form→gfrows, so first activate no longer errors on a missing table. - Added PHPUnit suite (
composer test).
1.8.1
- Renamed for WordPress.org trademark guidance: display name and slug are now “Lead Analytics for Pipedrive” /
lead-analytics-for-pipedrive(not Pipedrive-leading). Admin menu label is “Lead Analytics”.
1.8.0
- Observe adapters for Contact Form 7, Elementor Forms, and Ninja Forms (in addition to Gravity Forms).
- Form source keys are now prefixed (
gf:,cf7:,elementor:,ninja:) so plugins with the same numeric form id do not clash. Existing Gravity Formsform:Nlabels and log rows migrate togf:Nonce per site.
1.7.2
- Form-plugin agnostic core: Entry links and the Forms list use filters (
lafp_entry_url,lafp_known_forms). No hard dependency on Gravity Forms. - Gravity Forms support moved to optional
integrations/gravity-forms.php.
1.7.1
- Admin UI polish: consistent controls, action buttons, and table styling across Overview, Submissions, Forms, Connection, and network screens.
- Rewrote on-screen copy to be shorter and more direct.
1.7.0
- Fixed a fatal on single-site installs when reading per-site options (get_blog_option is multisite-only).
- Adopted the house WordPress.org packaging standard: dist build, LICENSE, Update URI handling, and Plugin Check-ready SQL/export fixes.
- Split the admin UI into focused modules (actions, tabs, network, format helpers).
1.6.1
- A later attempt for the same form entry (a retry by the sending code) updates that entry's row instead of recording it twice; a failure that is later delivered shows as "Delivered on retry".
1.6.0
- Per-form Pipedrive label on the Forms tab. New leads from that form carry the label, added in the same request that creates them; missing labels are created in Pipedrive when you save.
- The label shows on the Submissions list straight away and in each row's details.
1.5.0
- Moving between tabs no longer waits on Pipedrive: one cache per site is shared by every tab and date range, a stale cache is shown immediately while WordPress refreshes it in the background, and only the very first view fetches inline.
- One fewer API request per refresh: stage names are only fetched when a deal actually uses one.
- Tabs use the plugin's own design instead of the core tab styling.
- Plugin screens credit Krikir Technologies in the admin footer.
1.4.0
- Plugins screen: Settings link, "View details" with the full readme, and an About card on the Connection tab.
- Deleting the plugin now cleans up its table, options and caches, without touching the API token.
- Added the GPL-2.0 licence text.
1.3.0
- Sections use WordPress's own tabs, and each one also appears as a submenu item under Pipedrive in the sidebar.
- The sidebar shows a count bubble when submissions are failing, the way core does for updates.
1.2.0
- Tabs: Overview, Submissions, Forms, Connection, each with its own URL.
- Submissions: search, form and delivery filters, page size, CSV export, and a per-row breakdown of the Pipedrive API calls.
- Optional email alert when a lead fails to reach Pipedrive, at most one every 15 minutes.
- Network overview gained an all-sites table.
1.1.0
- Each site can manage its own token from its own dashboard, so the plugin also works on a single site.
- Site-specific wiring moved into integrations, leaving the plugin generic.
1.0.0
- First release: submission tracking, per-site tokens, analytics dashboard, network overview.