The MDAPI is used in Questionnaires and lookup fields across Litify. Follow this guide to set up or reset MDAPI in both sandbox and production environments. 

To reset or troubleshoot the MDAPI in a sandbox environment, follow all steps in this article. To Reset MDAPI in a production environment, Pre-Setup Steps and Production MDAPI Setup Steps. If you're setting up the MDAPI for the first time, click here to skip ahead to Production Setup

Table of Contents

Important Pre-Setup/Reset Steps:

If you are resetting the MDAPI, or configuring the MDAPI in a sandbox, you must first complete these steps to reconfigure it.

  1. Navigate to Setup > App Manager and delete the MDAPI app.


  2. Then navigate to Named Credentials and delete the MDAPI named credentials.


  3. Finally, navigate to Auth Providers and delete the MDAPI auth provider.


NOTE: If you are troubleshooting or resetting the MDAPI, click here to skip to Production Setup Steps


Sandbox MDAPI Setup Steps

  1. Log in to your sandbox.
  2. In Setup, navigate to App Manager > LitifyMDAPI > View
  3. Copy the Consumer Key and Consumer Secret


    4. In Setup, navigate to Auth. Providers > LitifyMDAPI and paste the Consumer Key and Consumer Secret.  


    5. In Setup, navigate to My Domain and copy the domain name in “Your domain name is” section.


    6. Navigate to Named Credentials > LitifyMDAPI > Edit, then change the URL to the mydomain URL you copied in the previous step. Make sure to include “https://” at the beginning. Click Save


    7. Navigate back to App Manager > LitifyMDAPI > View. Click Edit and change the Callback URL to match the mydomain from the previous step. 

Important note: make sure this begins with “https://” and ends with “/services/authcallback/LitifyMDAPI” -- you are only editing the URL between these two. 


8. You're ready to begin using MDAPI in your new sandbox.

Production MDAPI Setup Steps

  1. Click Configure MDAPI from the App Launcher. You will be directed to this page:


  2. You may find that the first step of this process is already completed. If so, you can skip this part of the setup guide. Otherwise, hit the Configure button all the way to the right of the first step. This automatically completes the first step:


  3. For step 2, you are prompted to refer to this setup instruction.
  4. Go to Setup > App Manager and scroll to the App named LitifyMDAPI. On the right-hand side is a dropdown button. Click it and then click the View link.


  5. In the area labeled API (Enable OAuth Settings) on the top line will be a Consumer Key and Consumer Secret (you need to click the link by Consumer Secret to see the actual value). Copy both values to use in the next step.


  6. Go to Setup > Auth. Providers and scroll to the Auth. Provider named LitifyMDAPI.
  7. Click Edit.


  8. Enter the Consumer Key and Consumer Secret in the corresponding fields.


  9. Return to the 'Configure MDAPI' page and it will complete the rest of the automated setup. At that point there's one more manual step and again it says to refer to these instructions.


  10. Go to Setup > Named Credentials and locate LitifyMDAPI and click the Edit link.
  11. 10. Ensure that the Start Authentication Flow on Save checkbox is checked, which it should be by default.


  12. Click Save.
    • Important Note: If you get an error stating this or something similar (error=invalid_client_id&error_description=client%20identifier%20invalid) after clicking save, you simply have to wait a few minutes for the Auth Provider to complete setup. Wait a few minutes then refresh the page, then click Save again to continue.
  13. You will be redirected to the Salesforce login page. Log in using your Litify credentials.
  14. Upon logging in, you will be asked if you want to Allow Access.
  15. Click the blue Allow button.


  16. Finally, visit 'Configure MDAPI' once more and you will see the setup is complete.

Was this article helpful?
34 out of 36 found this helpful