> ## Knowledge Base Index
> Fetch the complete knowledge base index at: https://help.cxplanner.com/sitemap.xml
> Use this file to discover available pages before exploring further.
> Pure-Markdown content can be obtained by appending a '.md' suffix to the content URLs listed in the sitemap (without the trailing slash).

# Set up 2-way-sync of issues in Procore

The Procore integration connects a CxPlanner project with a Procore project and synchronizes CxPlanner tasks and task history with Procore Observations and Observation logs.

When the Procore app is installed, it is granted project-level Admin permissions for **Observations** and **Webhooks**.

---

## 1. What is the Procore CxPlanner Sync App for?

The purpose of the integration is to synchronize:

- CxPlanner tasks with Procore Observations
- CxPlanner task history and comments with Procore Observation logs
- Status changes between CxPlanner and Procore

Synchronization can be configured as either **manual synchronization** or **automatic synchronization**.

---

## 2. Connecting CxPlanner to Procore

To connect a CxPlanner project to Procore, go to:

**Project Settings → Procore**

Enter the following values:

- **Procore company ID**
- **Procore project ID**

Then click **Connect**.

![Procore 2-way-sync to commissioning](https://storage.crisp.chat/users/helpdesk/website/-/e/a/2/c/ea2cfd7bb6130800/image_1zqda4.png)

### What happens when a project is connected?

When the connection is established, CxPlanner checks the Observation Types configured in the connected Procore project.

If an Observation Type named:

`Commissioning-CxPlanner`

does not already exist, CxPlanner creates it automatically.

CxPlanner tasks synchronized to Procore are created as Observations using this type.

The authentication token required for communication between the CxPlanner and Procore projects is stored by CxPlanner for future synchronization.

---

## 3. Synchronization Modes

CxPlanner provides two synchronization options:

1. **Synchronization**
2. **Auto synchronization**

### 3.1 Synchronization

Enable **Synchronization** to allow users to manually synchronize CxPlanner tasks with Procore.

When enabled, additional synchronization actions become available in the Tasks module. Users can synchronize:

- An individual task
- Multiple tasks in bulk

When only this mode is enabled, synchronization happens **only when a user manually starts a sync**.

This means that changes to Procore Observations or Observation logs are not automatically reflected in CxPlanner. Likewise, changes made in CxPlanner are only pushed to Procore when a manual synchronization is performed.

> **Note:** While a manual synchronization is running, changes from Procore are not applied until the synchronization has completed.

---

### 3.2 Auto Synchronization

Enable **Auto synchronization** to keep CxPlanner and Procore synchronized automatically.

With Auto synchronization enabled:

- New and updated CxPlanner tasks are sent to Procore automatically.
- Task status changes are synchronized automatically.
- Observation changes in Procore are sent back to CxPlanner.
- Observation log updates are synchronized with CxPlanner task history.
- Deletions and supported updates are reflected between the two systems.

Auto synchronization uses Procore webhooks to notify CxPlanner when supported events occur.

---

## 4. Observation Status Mapping

When synchronization is enabled, the task status and the **Can be closed** state are kept aligned between CxPlanner tasks and Procore Observations.

The following mappings are used:

| Procore Observation status | CxPlanner behavior |
| ---- | ---- |
| **Initiated** | Open task where **Can be closed** is not set, or a task in **Waiting** or **Reset** |
| **Ready for review** | **Can be closed** is enabled, meaning the task is marked ready to close |
| **Not accepted** | **Rejected** in CxPlanner |
| **Closed** | Task is in a closed-status column and **Can be closed** is cleared |

---

## 5. Webhooks

### What are webhooks used for?

Webhooks provide near-real-time synchronization from Procore back to CxPlanner.

They allow CxPlanner to react when Observations or their logs are created, updated, or deleted in Procore.

### How do webhooks work?

When **Auto synchronization** is enabled, CxPlanner creates the required webhook through the Procore API.

The webhook uses the namespace:

```text
cxplanner-observation-sync
```