Using Postman to Test RingCX Digital APIs
For easy testing using Postman, RingCentral provides a Postman 2.0 Collection for RingCX Digital. It is based on the RingCentral RingCX Digital OpenAPI 3.0 Specificaion. While Postman can import an OpenAPI 3.0 Specification directly, RingCentral recommends using the Collection as it provides better authorization handling using Postman variables and environments as recommended by Postman.
The files are available here:
This document describes how to install and use the Postman 2.0 Collection.
Pre-Requisites
Before you can use Postman, it is important to note the URL for your account and generate an access token. You will configure both of these in Postman.
Your API URL
RingCX Digital accounts use a customer subdomain that is important to note when accessing both the web application and API. In the following URL, replace the {mycompany}
variable in the web URL with your own subdomain when accessing your account.
https://{mycompany}.digital.ringcentral.com
Use your customer subdomain to create the following API base URL for your company:
https://{mycompany}.api.digital.ringcentral.com
Creating an Access Token
See the following instructions for how to create an access token in the RingCX Digital administration web console.
Using Postman
Using Postman once you have your pre-requisites consists of a few steps:
- Creating your Postman environment
- Importing the Postman collection
- Making an API call
Configuring Your Postman Environment
Use the following steps to configure your Postman environment:
- In Postman, create an environment by clicking the Gear icon for "Management Environments" in the upper right corner. This will bring up a list of existing environments.
- Click "Add" to create a new environment.
- Choose a name of your choice.
- Enter your server URL with "Variable":
RINGCX_DIGITAL_SERVER_URL
and "Initial Value" set to your API URL. This would be:https://{mycompany}.api.digital.ringcentral.com
uising your company's subdomain replacing{mycompany}
. - Enter your static access token with "Variable" set to
RINGCX_DIGITAL_ACCESS_TOKEN
and "Initial Value" set to your access token. This will set the proper request header. - Click the "Add" button to finish adding this environment.
Importing the Postman collection
Use the following steps to import the RingCX Digital Postman collection.
- In the upper left corner of the Postman application click the "Import" button.
- Click the "Import from Link" tab.
- Paste in the following URL where it says "Enter a URL and press import":
https://raw.githubusercontent.com/ringcentral/engage-digital-api-docs/master/specs/engage-digital_postman2.json
- Click the "Import" button
Making an API call
To test the Postman collection, let's call the "Get All Users" API.
- In the Environments pick list in the upper right corner, select the environment you just created.
- In the left hand navigation menu, select "Users" > "Getting all users"
- Ensure all the optional query string parameters are unselected
- Click the "Send" button
Feedback
If you have any feedback on using the Postman collection, please post to our GitHub repo here.