Postman Collection

12min

Postman is a tool to help test and build APIs. We've developed a Postman Collection that contains the complete set of API calls to make it all convenient for developers integrating with the Platform APIs.

What you need before getting started

Before you start with the Postman Collection, please make sure you have a developer account created on OS1 Developer Portal, have registered an app, and have a set of authentication keys (Client ID and Client Secret).

With that, create an account on Postman Platform if you haven’t already. Refer to the Postman Collections below to start testing. We will always have the latest versions of our Postman collections post here:

OS1 Postman Collection

v3.9.1

OS1 Environment File

App and Solution Postman Collection

We will always have the latest version of our Postman collection post here:

v2.3.2

Environment File

Troubleshooting

If you run into any issues with the collection, see our Postman Troubleshooting Guide.

📘 NOTE

The OS1 Postman Collection includes App & Solutions, Platform, DispatchOne APIs.



Get Started with the Postman Collection

Step 1: Downloading & importing OS1 Postman Collection to Postman Account

Open Postman application > Go to Collections > Click on the Import button > In the dialog box, go to Raw Text and copy-paste the code from Git > Click on Import.

Document image


Step 2: Import the Environment File to Postman Account

Now, visit the Postman account > Go to Environments > Click on the Import button > In the dialog box, click on Raw text > Paste the file that you copied above > Click on Continue.

Document image


Next, add the values of the different variables to the environment file table. Before that, make sure the OSI Environment File is selected.

Open Postman account > Environments > OSI Environment File > Add variables.

To start with, you’ll need to add Client ID, Secret, baseURL (Tenant URL), Request ID (a random identifier; for example, request123), and Tenant ID to the environment file.

🔐

You will get the Client ID, Secret, Tenant URL, and Tenant ID after registering an app on OS1 Platform Developer Portal. For more information about registering an App, see Getting started with Apps and Solutions.

Note that the variable values used in the above screenshot are made up and will not work if used to make a request.

Step 3: Generate Access Token

In the Postman app, go to Collections > CoreOS Services > Token > Click on Send to make your request > You'll receive the token in the body as shown below.

Document image


Add this access token to the environment file.

🚧 ️ Access Token Expiry

The access token has an expiry date. If after running an API, it says the token is expired, you can simply generate a new one by following the same steps mentioned in step 3.

Step 4: Exploring APIs

The next step is to choose an endpoint from the right-hand side navigation of the collection and start to build your request. Here, we will try out the Entity Service API.

To create a new Entity, visit Entity Service > Entity Type APIs > Entity Type Post > In the request body, enter the details of the Entity you want to create, for example, the name & category of the Entity > Hit Send > In response, a new Entity will be created & you'll get the Entity ID.

Document image


🎉 You are now ready to explore other endpoints.

📘 API Reference 'Try It' Feature

Use the API Reference ‘Try It’ Feature to explore all the APIs directly using the Documentation Portal.



Updated 15 Nov 2024
Did this page help you?