This document explains how to use Postman to run Advanced Server Access API collections.
- Advanced Server Access (ASA)
- API
Follow these steps to set up ASA API with Postman:
-
From the Okta dashboard, log in to the Advanced Server Access App.
-
Create a Group with an Admin role if it does not exist already.
-
In IU, under the Directory section, go to Groups > Create New Group > choose Group Name (for example, ServiceAdmins) > Create Group.
-
Click on Groups again > Details > Team Roles > select Admin > click Update Roles.
-
-
Create a new service user account and add it to the Admins' Group:
-
Click on Users > Service Accounts tab > Create Service User > select new Username > Create Service User.
-
Go to Groups > select the newly created Group with the Admin role > click on the Users tab > Add User to Group > Add User.
NOTE: Only Administrators can list their teams' settings or update these usingGET/PUTon/v1/teams/{{asa-team}}/settings.
-
-
Generate a new API key and secret using the newly created service user:
-
Click on Users > Service Users and click on the newly created Service User.
-
Under the API Keys section > click Create API Key.
NOTE: Keep both safe and secure.
-
-
-
Next, generate
bearer_tokenusing curl on the local machine, for example, on macOS, open a terminal:curl -v -X POST \ -H "Content-Type: application/json" \ --data '{ "key_id": "api-key-id-here", "key_secret": "api/secret/here" }' \ https://app.scaleft.com/v1/teams/"team_name"/service_token-
Once the
bearer_tokenis generated, keep it secure with a note of that to be used later.
-
-
Fork this Postman API collection (Advance Server Access > Attributes) to the environment.
-
Once imported in Postman, go to Advanced Server Access API > article:users > select Get List the ASA Users for a team.
-
In the RHS Window, click Authorization tab > change type to Bearer Token.
-
In the Token field on the right, paste the bearer token copied in Step 2.a.
-
-
Run the GET commands to test, for example:
-
GET team users list:
{{baseUrl}}/v1/teams/"team_name"/users - GET projects list:
{{baseUrl}}/v1/teams/"team_name"/projects
-
If able to GET the users and projects list, the ASA API was set up successfully using Postman.
