Generate IBM API Connect OAuth2 token programatically in Postaman

Hello arlemi,

Sure thing, thank you for the warming welcome and quick reply!

Here’s the gist to the code:

I have a few remarks:

  1. The query is formulated to be accepted by IBM’s Oauth2 token generator API. You might want to change it to the one you’d be using;
  2. You need to come up with some scope;

After you get any kind of reply from an Oauth2 generating API, save it as a variable, then try to access that variable from a couple more scripts in the collection and send it somewhere. It won’t be available always. But this is specific to the Oauth2 generator I’m using…

Thanks in advance!