Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / OAuth2

How to Configure Postman to Call Infor ION API

5.00/5 (1 vote)
17 Dec 2022CPOL2 min read 9.4K  
Step-by-step approach to configure popular development tool Postman to test/execute Infor ION API
In this post, you will see an explanation of the step-by-step approach to configure the popular development tool Postman to test/execute Infor ION API.

In this post, I'm going to explain the step-by-step approach to configuring the popular development tool Postman to test/execute Infor ION API. Even though this is straightforward, better to have a document to do quickly whenever you need it, to save time.

As you know, Infor ION APIs use OAuth2.0 (The OAuth 2.0 Authorization Framework) for authorization and Bearer Tokens which are the predominant type of access token.

Configuration from the Infor ION API

Create Postman as Authorized Apps in Infor ION.

Note: To complete the below steps, you must be in the IONAPI-Administrator security role.

  1. Go to Infor ION API -> Authorized Apps
  2. Click on + icon on the left top (Add New App)

    Image 1

  3. Give it a name, description select type as "Backend Service", then Save.

    Image 2

  4. After Save, we can see additional information like Client ID, Secret, Associated Events, etc.
  5. Click on the Download Credentials button (next to the Secret text box).
  6. In the Download Credentials Dialog, toggle on the Create Service Account.
  7. Select a user from the Full Name text box. This is required because we configure this as Backend service and need impersonation. Or you will get Illegal impersonation attempt (error: 163) error.

    Image 3

  8. A file will be created (e.g., PostmanClient.ionapi) and downloaded to your local Download folder. After you download, store these credentials securely.

If you open the file, you can see it is a JSON file and contains several properties. Infor API Admin guide defines those properties as follows:

Property Description
ti Tenant identifier
cn Application name
ci ClientID that must be passed to the Authorization
cs ServerClient Secret to pass to the Authorization Server
iu Base URL for calling the ION API Gateway for this tenant/environment
pu Base URL for calling the authorization server for this tenant/environment
oa Path to append to "pu" to create the Authorization URL
ot Path to append to "pu" to create the Access Token URL
or Path to append to "pu" to revoke a previously obtained token
SAAK Service Account Access Key
SASK Service Account Secret Key

Configuration in Postman

  1. On the Authorization tab in the Postman, select Type as OAuth 2.0

    Image 4

  2. On the right-hand side, under the Configure New Token-> Configuration Options, enter parameter values as below:
    Token Name Name it as you want
    Grand Type Password Credentials
    Access Token URL value of "pu"+"ot" from the .ionapi file
    Client ID value of "ci" from the .ionapi file
    Client Secret value of "cs" from the .ionapi file
    Username value of "saak" from the .ionapi file
    Password value of "sask" from the .ionapi file
    Scope [blank]
    Client Authentication Send as Basic Auth header
  3. Click on the Get New Access Token button.
  4. You will see the success message like this:

    Image 5

  5. In the next window, click on the Use Token.
  6. Now Postman client is ready to call Infor ION API.

    Image 6

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)