Squarespace is one of the most popular website builders in the world.
Apipheny is an API connector for Google Sheets. You can use Apipheny to connect your Google Sheets to unlimited API data sources, make unlimited API requests, and more. There is a 30 day free trial included.
1.) Install Apipheny by opening the following link on desktop and then clicking the Install button in the Google Marketplace: https://apipheny.io/install
2.) After you’ve installed Apipheny, open a Google Sheet and then click on the Extensions dropdown in the menu at the top.
In the dropdown list you should see Apipheny. Click Apipheny then click Import API to open the Apipheny sidebar in your Google Sheet.
Tip: you can open a new Google Sheet by entering this URL in your browser:
Next, log in to your Squarespace account and in the left navigation menu, click Settings:
Then scroll down and click Advanced:
Then click Developer API Keys:
Click the GENERATE KEY button:
In the popup window, fill in the “KEY NAME” field and select one or more Commerce APIs under “PERMISSIONS”, along with their permission level, then click GENERATE KEY:
After your key is generated, click the Copy Key button and then paste your key to a safe location, because you will need it in the next steps:
In this section, I’ll show you how to browse the Squarespace API documentation to find an API endpoint URL that retrieves the specific information you need from your Squarespace account.
If you already know your API URL endpoint, or you want to use the same example URL as us, just skip to Step 4.
First, open the Squarespace API documentation page: https://developers.squarespace.com/commerce-apis/overview
The menu on the left contains a guide on how to use the Squarespace API and a list of all the available APIs (Inventory API, Orders API, Products API and Transactions API):
Each API has a list of specific endpoints. Clicking one of the available Squarespace API’s endpoints.
An example endpoint is the Retrieve all inventory endpoint from the Inventory API. Clicking on this endpoint will open its documentation page, which contains the endpoint’s HTTP method and URL, a short description of its purpose, a list of the accepted parameters, as well as a sample request and its associated sample response.
Here’s the API URL for this example endpoint:
All API calls to the Squarespace API should be made to the base/root URL:
Okay, now we’re in the home stretch. Now go back to your Google Sheet and make sure that the Apipheny add-on is open on the Import tab. With the Import Tab open, enter these details into the add-on:
API URL: In Step 3, I explained how you can find the Squarespace API endpoint that you need. Now copy the complete API URL into the Apipheny add-on, where it says API URL Path (JSON / CSV), followed by any GET parameters required for your query.
For this example, we are using the Retrieve all orders endpoint, that retrieves all order information; orders can be filtered within a date range. The response contains order information in an Order, up to 50 Orders ordered by their modification date (modifiedOn). The corresponding URL for this endpoint is:
Headers: In the Headers section of the Apipheny add-on, add one row, with the following key and value:
Header Key: Authorization Value: Bearer your_key
Replace your_key with the value of the API key you obtained previously, in Step 2. There should be a literal space between Bearer and your_key.
Here’s what your Squarespace API request should look like when entered into the Apipheny add-on:
Once you have your Squarespace API details entered into Apipheny, the last step is to click the Run button at the bottom of the Apipheny add-on, and then your Squarespace API data will be imported into your Google Sheet.
That’s it! That’s how you can connect the Squarespace API to Google Sheets and pull your Squarespace account data into Google Sheets using Apipheny.
After making a successful request to the Squarespace API, try querying a different Squarespace API endpoint, or try using one of the more advanced features in the Apipheny add-on.
Crypto API Tutorials: