Connecting to Salesforce
Integrating Salesforce into ReportMagic means you can:
- Create internal sales reports
- Use the customer contact's contact information in your customer-facing reports
- List current opportunities, projects etc. in your customer-facing reports
Creating an External Client App in Salesforce
To set up a Salesforce connection, as a Salesforce administrator, create a new External Client App:
- Under Platform Tools, expand Apps and click App Manager.
- Click the New External Client App button and provide the following:
- External Client App Name = ReportMagic
- API Name = ReportMagic
- Contact Email = your email address
- Select the Enable OAuth checkbox and provide a Callback URL. This is not actually used by the connection, so any valid URL works, for example https://login.salesforce.com/services/oauth2/success
- Include at least the following selected OAuth Scopes:
- Access and manage your data (api)
- Access the identity URL service (id, profile, email, address, phone)
- Under Flow Enablement, select the Enable Client Credentials Flow checkbox and confirm the dialog that appears.
- Click Create.
Once the app has been created, configure it to run as a specific Salesforce user:
- On the app's Policies tab, click Edit.
- Set Permitted Users to "Admin approved users are pre-authorized" and confirm the dialog that appears.
- Under Select Profiles, add the profile of the Salesforce user you want the connection to act as. This user's data access and permissions become the connection's data access and permissions, so a dedicated user with Read Only Salesforce permissions is recommended.
- Under OAuth Policies, in the OAuth Flows and External Client App Enhancements section, select the Enable Client Credentials Flow checkbox and set Run As to that user's username.
- Click Save.
Finally, obtain the Consumer Key and Consumer Secret:
- On the app's Settings tab, under OAuth Settings, click Consumer Key and Secret.
- Copy the Consumer Key value (will be required later).
- Copy the Consumer Secret value (will be required later).
Note: if clicking Consumer Key and Secret does not do anything, reload the page and try again. This is a known Salesforce issue, not a Magic Suite issue.
Adding the Salesforce Connection in Magic Suite
In Magic Suite, add a new Salesforce Connection as follows:
- From the Admin menu, click Connections.
- Click the Create button.
- Enter a name and description and a Connection type of Salesforce.
- In the URL field, enter your Salesforce org's own My Domain token endpoint, for example https://your-domain.my.salesforce.com/services/oauth2/token. Your domain name is shown under Setup, My Domain.
- In the User Name field, enter the Consumer Key obtained above.
- In the Password field, enter the Consumer Secret obtained above.
- Click Save and ensure that the new connection has a valid green checkmark next to it in the Status column.
Note: the User Name and Password fields are labelled this way for historical reasons, but for a new Salesforce connection they hold the Consumer Key and Consumer Secret, not a Salesforce user's own login details. The Password field is stored encrypted.