# Connect ConnectMachine to Zapier

Send every new and updated contact from ConnectMachine straight into the apps you already use, and write contacts back from those apps. This guide walks through connecting your account, the triggers and actions you get, the fields you can map, and how to fix the problems people run into most.

## Before you start

The ConnectMachine app on Zapier gives you three triggers and two actions for your contacts. Triggers are instant, so a Zap runs within seconds of a contact changing instead of waiting for a polling interval.

### You will need

- A ConnectMachine account with onboarding finished.
- Zapier access on your ConnectMachine plan: a paid subscription, a seat on an organization license, or an active Premium trial.
- A Zapier account. Zapier’s free tier includes 100 tasks per month, which is enough for most single-step Zaps.

## Connect your account

You connect ConnectMachine to Zapier once. After that, every Zap you build can reuse the same connection.

1. In Zapier, create a Zap and search for **ConnectMachine**.
2. Pick a ConnectMachine trigger or action, then click **Sign in**.
3. ConnectMachine opens a consent page. Sign in with Google or with a code sent to your email. You are never asked for a password.
4. Review the permissions you are granting, then click **Approve and continue**.
5. Zapier returns to the Zap editor with your ConnectMachine account connected and ready to use.

### What you are approving

- Read your account details
- Read contacts and networks
- Create and update contacts
- Manage its own trigger subscriptions

**Disconnecting**

To revoke access, open _My Apps_ in Zapier, find ConnectMachine, and remove the connection. Zaps that use it stop running until you connect again.

## Triggers and actions

Triggers start a Zap when something happens in ConnectMachine. Actions let another app write into ConnectMachine.

### Triggers

- **New Contact:** A contact is added to your ConnectMachine account.
- **Updated Contact:** Any detail on an existing contact changes.
- **Deleted Contact:** A contact is removed.

### Actions

- **Create Contact:** Adds a person or business contact to ConnectMachine from another app.
- **Update Contact:** Changes fields on a contact that already exists.

## Build your first Zap

### Choose your trigger

Add ConnectMachine as the first step and pick a trigger event. This example uses Updated Contact.

### Pull a sample record

Click Test to load a sample contact. Samples let you map fields before a real event arrives.

### Check what the trigger gives you

Expand the sample to see every field you can map into later steps: names, company, job title, primary email and phone, labeled values, locations, tags, and timestamps.

### Map fields into the next app

Add your second app and drag ConnectMachine fields into it.

### Handle deletions

Use the Deleted Contact trigger to keep other systems tidy.

## Fields you can map

### What a trigger gives you

Every trigger hands Zapier the full contact record.

| Field                  | What it holds                                                                 |
|------------------------|-------------------------------------------------------------------------------|
| Item ID                | A stable ID for the event, so your Zap never runs twice for the same change.  |
| Contact ID             | The ConnectMachine contact ID.                                                |
| Event Type             | Whether the contact was created, updated, or deleted.                        |
| Source                 | Where the change came from.                                                  |
| First Name, Last Name, Company, Job Title | The core identity fields.                                              |
| Primary Email, Primary Phone, Website | The main contact values, ready to map straight into most apps.         |

## ConnectMachine API reference for Zapier

### Authentication and scopes

The integration uses OAuth 2.0 authorization code flow with PKCE. Protected endpoints require `Authorization: Bearer <access_token>`. Zapier requests the scopes `user:read`, `contacts:read`, `contacts:write`, and `webhooks:write`.

### Endpoints

#### OAuth 2.0 with PKCE

- **GET** `/api/v1/oauth/authorize`
  - Starts authorization and redirects the browser to the ConnectMachine consent screen.

- **POST** `/api/v1/oauth/token`
  - Exchanges an authorization code or refresh token for an access token.

#### Contact actions

- **POST** `/api/v1/zapier/contacts`
  - Creates a person or business contact in the connected account.

- **PATCH** `/api/v1/zapier/contacts/{id}`
  - Updates only the supplied fields on an existing contact.

### Errors

Errors use a consistent JSON body. A `429` response also includes a `Retry-After` header.

### Status Codes

| Code | Meaning                                             |
|------|----------------------------------------------------|
| 400  | malformed request or validation failure             |
| 401  | OAuth client, grant, or bearer token missing or invalid |
| 403  | insufficient scope or forbidden                    |
| 404  | requested resource does not exist                   |

## Still stuck?

Send us the name of your Zap and the error Zapier showed you, and we will take a look.
