Is there a way , we can generate multiple access tokens (lets say 50) in a single API call ??

Not applicable

Use Case :

We need to create a test endpoint which can create multiple access tokens(50) .

We can implement this in a javascript policy and invoke the OAuth proxy via HTTPclient in a loop.

But this will involve a 'network hop' (i.e. a round trip to Apigee Load balancer) .

Also we cannot use proxy-chaining concept in a Javascript poilcy .

Is there an efficient way we can implement this use-case or we have to implement this with the way described above.

0 2 634
2 REPLIES 2

Not applicable

@Anil Sagar Can you please addresss the above use-case??

if this is for testing purpose, I would suggest that the test client should call the token endpoint 50 separate times. Creating an API to do this feels dangerous as it may be exposed to the outside world.

Using OAuth2 a client should not need to manage many tokens, but should instead request a single access token (and refresh token) with the correct scopes for the actions they want to perform. I can't see a good reason for creating an API which generates many tokens. You can read more here.

Hope this helps!