The implementation currently is flawed as we're using the user credentials for sign in again and again when executing the script, this enforces rate limiting.
Ideally, the script should:
Login once with the user credentials
Store the JWT returned from the server into the config.json file
When the script is executed again, it should:
Use the old JWT for the requests from config.json
If that JWT has expired, try and request a new JWT from /uaa/auth/refresh-token endpoint
If that fails, then and only then, login with the user credentials
This should help with the rate limiting currently imposed on sign in attempts.
The implementation currently is flawed as we're using the user credentials for sign in again and again when executing the script, this enforces rate limiting.
Ideally, the script should:
config.json
fileWhen the script is executed again, it should:
config.json
/uaa/auth/refresh-token
endpointThis should help with the rate limiting currently imposed on sign in attempts.