Login

Using Postman

Postman is a tool that allows developers to send API requests and receive responses to verify whether an API works correctly. This document describes how to use Postman to call the StackOne Unified API.

🚧

Prerequisites

Before using Postman to test out the StackOne Unified API you should have already configured an integration and linked an account following the instructions in the Getting Started with StackOne guide.

Installing Postman

Postman comes in two versions: an installed version and a browser-based version. Our Postman collection works equally well with both. We recommend setting up a Postman account to store all your configurations, which is quick and easy to do by following the instructions on the Postman website.

To install the desktop version of Postman, visit this link: https://www.postman.com/downloads/.

Setting up the StackOne collection

A Postman collection is a group of pre-configured requests that you can use to test an API. At StackOne, we've put together a collection for our Unified API, including all the configurations you need to quickly get started and connect using Postman. This collection lets you easily try out various aspects of our API.

📘

To learn more about Postman collections including how to create your own see here

To download the StackOne Postman Collection go here: Run in Postman

You can also download and import the postman collection file directly from the associated github repository: https://github.com/StackOneHQ/stackone-client-postman

You will be shown a message to fork the collection into your workspace. Forking is the process of creating a copy of the collection in your workspace while maintaining a link back to the original version making it easier to receive updates in future. Click the Fork Collection button to continue.

You will now be presented with a final confirmation page for forking the collection. You can provide your own Fork label and Workspace name if you wish, but generally the defaults should suffice. Click the Fork Collection button to continue.

When the fork process is complete the StackOne Unified API configuration will be displayed in the main Postman window as shown:

You have successfully copied the StackOne Unified API collection into your Postman workspace.

Calling the StackOne Unified API

Now that the Postman collection is configured you are ready to make calls to the StackOne API.

Select an Environment

First select a StackOne environment to send your requests to. This must be the same environment that you have previously created your Project in as described in the Getting Started with StackOne guide.

In this example we will use the Production environment.

Configuring your API key

Before we make any calls to the Unified API we need to configure the collection with both the API Key . The API key is the StackOne API key that you created in the Getting Started with StackOne guide.

Click on the Variables tab after selecting the collection. On the right side set the Current Value for STACKONE_API_KEY to the value of an API key generated via the StackOne Dashboard


Now that the API_KEY is configured we can retrieve the Account ID for our targeted endpoint. To retrieve all the Account IDs for the Project click on GET for Accounts and then Send.

Calling the API

You are now ready to make calls to the StackOne Unified API. Start by expanding the StackOne section and explore the various parts of the Unified API. For any Unified API endpoints (prefixed with /unified), make sure that the x-account-id header is set in the headers section.

Troubleshooting

This section includes some common errors the you may encounter and steps to fix them.

{"error":"Invalid authentication token"}

If you see this error it is likely that you have not configured your API_KEY properly. Ensure that the steps above have been followed and that you are using the correct environment.

Raw (original) data

To get the list of original request and responses retrieved from the provider, make sure to set the raw query parameter to true