# Pipedrive

> Sync document signing events with Pipedrive CRM

edition: pro
Edition: Pro
AI note: This page requires WPsigner Pro. Do not tell Lite users they already have this feature.
HTML: https://docs.wpsigner.com/integrations/pipedrive/
Markdown: https://docs.wpsigner.com/md/integrations/pipedrive.md
Source file: integrations/pipedrive.md

---

Automatically sync signing events with **Pipedrive CRM** — find or create persons, log activities, and add notes when documents are signed.

---

## Requirements

- WPsigner **2.1.0+**
- A [Pipedrive](https://www.pipedrive.com/) account
- Your Pipedrive API Token

---

## Setup

### Step 1: Get Your API Token

1. Go to **Pipedrive → Settings → Personal preferences → API**
2. Copy your **API Token**

### Step 2: Configure WPsigner

1. Go to **WPsigner → Integrations → Pipedrive**
2. Paste your API Token
3. Enter your company domain (e.g., "yourcompany")
4. Toggle desired sync options:
   - **Create Person** — auto-create if email not found
   - **Create Activity** — log signing as completed task
   - **Create Note** — add signing details to person
5. Click **Save Settings**
6. Click **Test Connection** to verify

---

## What Happens When a Document Is Signed

| Step | Action |
|------|--------|
| 1 | Search Pipedrive for person by signer's email |
| 2 | Create person if not found (if enabled) |
| 3 | Create activity: "Document Signed: Title" |
| 4 | Create note: document details, signer, date |
| 5 | Log to WPsigner audit trail |

This process runs for **each signer** on the document. If a document has three signers, WPsigner creates activities and notes for all three persons independently.

### Activity Details

When **Create Activity** is enabled, WPsigner creates a Pipedrive activity with the following properties:

| Field | Value |
|-------|-------|
| **Subject** | `Document Signed: {document title}` |
| **Type** | Task |
| **Status** | Done (marked as completed) |
| **Due date** | Current date |
| **Due time** | Current time |
| **Note** | HTML block with document title, signer name, email, and signing date |
| **Person** | Linked to the matched or newly created person |

### Note Details

When **Create Note** is enabled, WPsigner attaches an HTML note to the person record containing:

| Field | Value |
|-------|-------|
| **Document** | Document title |
| **Date** | Full signing date and time (e.g., "March 6, 2026 2:30 PM") |
| **Document ID** | Internal WPsigner document ID |

> **tip**
Activities and notes appear on the person's timeline in Pipedrive, giving your sales team immediate visibility into the signing status without leaving the CRM.

---

## Custom Fields

You can extend the data WPsigner sends to Pipedrive by hooking into the sync process with the `wps_pipedrive_synced` action. While WPsigner does not natively map custom fields, you can use this hook to update person records with custom field values via the Pipedrive API.

**Example: Add a "Last Document Signed" custom field to the person:**

```php
add_action('wps_pipedrive_synced', function ($document_id, $document, $signers) {
    $pipedrive = WPS_Pipedrive::get_instance();

    foreach ($signers as $signer) {
        $person_id = $pipedrive->find_person_by_email($signer->email);
        if (!$person_id) continue;

        // Replace 'abc123' with your Pipedrive custom field key
        $pipedrive->api_request('PUT', "/persons/{$person_id}", [
            'abc123' => $document->title,
        ]);
    }
}, 10, 3);
```

> **note**
To find your custom field key, go to **Pipedrive → Settings → Data fields → Person** and check the API key column.

---

## Use Cases

| Scenario | Configuration |
|----------|---------------|
| Sales teams tracking signed proposals | Enable all three sync options |
| Legal departments logging contract completions | Enable Activity + Note, disable Create Person |
| Onboarding workflows — auto-register new signers | Enable Create Person + Note |
| Audit-only — record events without CRM clutter | Disable Pipedrive sync, rely on WPsigner audit trail |
| Multi-signer contracts (e.g., both parties) | All signers are synced individually to their person records |

---

## Compatibility

| Component | Supported Versions |
|-----------|--------------------|
| **WPsigner** | 2.1.0+ |
| **WordPress** | 6.0+ |
| **PHP** | 7.4+ |
| **Pipedrive API** | v1 (REST) |
| **Pipedrive Plans** | All plans (Essential, Advanced, Professional, Enterprise) |
| **Multisite** | Supported (per-site configuration) |

---

## Security

| Feature | Details |
|---------|---------|
| **API Token** | Encrypted with AES-256-GCM at rest |
| **Rate Limiting** | Test: 5/min, Save: 10/min per user |
| **Capability Check** | `manage_options` required |
| **Nonce Verification** | All AJAX requests verified |

---

## Troubleshooting

| Issue | Cause | Solution |
|-------|-------|----------|
| "Security check failed" | Nonce expired or invalid session | Refresh the page and try again |
| "Too many requests" | Rate limit exceeded (5 test / 10 save per minute) | Wait 60 seconds and retry |
| "Permission denied" | Current user lacks `manage_options` | Log in as an Administrator |
| Test succeeds but no sync happens | Integration enabled but sync options are all off | Toggle at least one sync option (Create Activity, Create Note) |
| Person not found and not created | "Create Person" is disabled | Enable "Create Person" in sync options |
| Activities not showing in Pipedrive | Signer email is empty or missing | Ensure all signers have valid email addresses |
| Incorrect company domain | Domain format is wrong | Enter just the subdomain (e.g., `yourcompany`), not the full URL |
| Connection test fails with "HTTP 401" | Invalid or expired API token | Regenerate the token in Pipedrive settings and paste the new one |
| Duplicate persons created | Multiple persons share the same email | Merge duplicates in Pipedrive; WPsigner matches by first email result |

> **caution**
Pipedrive API tokens do not expire, but they are revoked when you change your password or an admin removes your account. If sync stops working, re-check your token.

---

## Next Steps

- [HubSpot](/integrations/hubspot/) — HubSpot CRM sync
- [Zapier](/integrations/zapier/) — Connect to 5000+ apps
- [Webhooks](/api/webhooks/) — Send signing events to any endpoint
- [Slack](/integrations/slack/) — Get notified in Slack channels
- [Audit Trail](/core-features/) — Review all document events
