# Track survey answers in Heap

Send **Survey Completed** to Heap when someone finishes a survey. Use the survey title to compare counts, or filter by an answer to compare groups of people.

## Connect the receiving environment

1. In Heap, open **Account → Manage → Projects**. Find the environment that should receive your events. Copy its numeric environment ID, also called the app ID.
2. In Shopoll, open **Integrations → Product analytics** as a workspace owner or admin. Choose **Heap**.
3. Match the region to the Heap environment, enter its ID and choose **Connect project**.
4. Finish a published survey. Check the event in the receiving environment and choose **Refresh status** in Shopoll to see whether Heap accepted the delivery.

## Inspect a completion

| Heap field | Value from Shopoll |
| --- | --- |
| `survey_id` and `survey_title` | The published survey that received the response. |
| `answer_<question ID>` | The submitted answer, including write-in text when supplied. Long answers continue in properties ending in `.part2`, `.part3` and so on. |
| `phone` | The first valid phone answer in international format on an identified survey. |
| `timestamp` | When the participant completed the survey. |

When Shopoll has an external participant ID or a verified customer ID, it uses that identity for Heap. An anonymous survey uses a new ID for each event and leaves out the separate phone field. Text entered in answers still appears in the answer properties.

## Manage the connection

Partial submissions and imported responses do not trigger events. Temporary delivery failures are retried with the same event ID. **Change project** replaces the receiving environment and cancels outstanding deliveries to the old one. **Disconnect** stops future forwarding. [Heap Track API](https://developers.heap.io/reference/track-1)
