Exporting mapped values from sheets setup guide
Table of Contents
- Open the Google Sheet you want to export mapped values from.
- Go to Extensions > Apps Scripts.

- Change the title of your project to the preferred name (Ex. “Export Mapped Values”).
- Make a new script or rename the default script to exportJson.

- Delete all contents of exportJson and copy all of the text in this file into it.

- Click the + in the Files tab and select HTML to create a new html document.

- Name it downloadTemplate.
- Delete all contents of downloadTemplate and copy all text in this document into it.
- Open the exportJson script in the left panel.
- Click Run in the top bar.
-
Note: If it gives you an error about myFunction being deleted, just hit Run again, and it will work.

-
Note: If it gives you an error about myFunction being deleted, just hit Run again, and it will work.
- Google will ask to give the project permission to access your data. Click Review permissions and log into your account.

- Scroll down and select Allow.
- Select Run again just to make sure it ran.

- Navigate back to your Google Sheet.
- You should see a menu in your top ribbon labeled Mapped Values. In order to export mapped values, select the values by clicking and dragging. You can only select 2 columns (it will stop you if you don’t have 2 selected).
-
Note: If you don’t see the menu click Extensions > Apps Scripts and it should pop up.

-
Note: If you don’t see the menu click Extensions > Apps Scripts and it should pop up.
- Once you have selected your values, navigate to Mapped Values > Export JSON.

- Your browser may block pop-ups on google drive. Ensure to allow the pop-up to appear. The only way to download automatically from your drive is to create a download link and then open it, which is why the script opens a new window temporarily.
- Note: If you see a 403 error, it is because you are signed into multiple Google accounts. Even if the correct account is the default, it still won't work. Ensure to sign out of all other accounts temporarily and then run the script again to fix this.
- Click the Download JSON button.
- You can drag and drop this into the Mapped Values Import Area section of Integration Center.
- The Mapped Value Form will be named Imported Mapped Values. Change the name and description accordingly.
Extra functionality
The Invert Keys and Values checkbox will switch columns as they correspond to the mapped input and output. By default, the left column is input and the right column is output.

In the Mapped Values menu, there is an extra option called Export JSON | Add Zeros. This works the same as the normal Export JSON, but every value that is both an integer and less than 5 digits will be formatted to have leading zeros until it is 5 digits long. Ex: 205 -> 00205.
- Note: The script makes a temporary output file in your Google Drive root folder then moves it to trash. This is necessary to download said file.