The Automated Token Script editor allows you to specify scripts that will be used to automate retrieval of OAuth 2.0 tokens. You specify Groovy automation scripts in the editor fields.
Add Fields
Click . ReadyAPI will add a new empty field.
Delete Fields
-
Select the field you want to delete.
-
Click
.
-
Confirm that you want to delete the selected field.
Check Syntax
The editor warns you when checking your scripts if the code syntax is incorrect:

Possible Errors
Browser Error
The browser will display all the errors returned by the authorization server.
Validation Error
Successful Validation
If the script validation has completed without errors, an information dialog will appear.
Note: | This does not mean the script has actually retrieved something successfully (the credentials may still be wrong, for example). This means the script can run and is not malformed. Always check for any errors in the browser, even if the validation is successful. |

See Also
About Automating Token Retrieval
OAuth Automation Example
Automating Token Retrieval