# Import contact data from Salesforce to Qwary

With Qwary's integration, you can effortlessly bring in your new contacts or update existing contacts from Salesforce into the Qwary platform. This streamlined import functionality eliminates the need for manual data entry or complex data migration processes. It enables you to access and utilize your Salesforce contacts within Qwary's survey and feedback management system, providing you with a unified and comprehensive view of your customer base.

**Create an app in Salesforce.**

Skip *this step if you already have an app created for Qwary.*

* Log into the Salesforce account.&#x20;
* Open to Settings --> Setup.
* Go to platform tools --> App Manager & click 'New Connected App.'
* Enter the below information and click on 'Save.'
* After saving your record, Click on consumer details and save the consumer key and secret.&#x20;

<figure><img src="/files/j7PJRQtI2gGeEpWOKCpm" alt=""><figcaption><p>Create Salesforce App</p></figcaption></figure>

**Connect Qwary to Salesforce with scheduler workflow.**

1. Go to Workflows --> Create new workflow --> Select Schedule-based workflow, enter workflow name, and click 'Create.'
2. Click on 'Add Task.' and add 'Extract contact and/or account data from Salesforce Account.'
3. Select opportunity or case email campaign and click 'connect.'
4. Click on 'Connect' again from the Salesforce integration overview page.&#x20;
5. Enter the Salesforce account username, password, consumer key, and consumer secret (from step 2e)
6. You have successfully connected Qwary to your Salesforce account and will land on the task configuration page.

**Create an email campaign for Salesforce Case/Opportunity.**

1. Click 'Add Survey' on the task configuration page to Extract contact and/or account data from the Salesforce account.
2. Mapping account and contact fields with a Salesforce object are incredibly easy. Select the contact list name from the dropdown menu to import contacts into a contact list in Qwary.

<figure><img src="/files/x99aZbvocOuqOiKLJJV4" alt=""><figcaption></figcaption></figure>

2. Click on 'Save' for the task to save the task.

**Define Schedule**

Define a schedule for the task to run. Qwary runs SOQL query periodically to check if a new case/opportunity matching the defined criteria is found.

1. Schedule by minutes - runs the workflow every defined minute.
2. Schedule by hours - runs the workflow every defined hour.
3. Schedule daily - runs the workflow daily.
4. Schedule weekly - runs the workflow weekly.
5. Schedule monthly - runs workflow monthly.
6. Schedule yearly - runs workflow yearly.

**Active the workflow**

Click on the workflow menu to activate the workflow.

Qwary will run the workflow on a defined schedule, import new contacts and update an existing contact.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.qwary.com/product-guide/workflows/salesforce-workflow/import-contact-data-from-salesforce-to-qwary.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
