Need some advise on how to get JWT Token from Oracle Applications Cloud programmatically.
I referred to the following document: https://docs.oracle.com/en/cloud/saas/applications-common/20a/farca/Use_JWT_Token_for_Authorization.html
1) One of the method was to go to https://<fusion app url>/fscmRestApi/tokenrelay from any browser and sign in with valid credentials. The Token Relay Service returns a JSON response with the access token. However, this method requires me to manually perform the token retrieval everytime which is not ideal.
2) The other method was to use the following Groovy code in your code to get the token from Oracle Applications Cloud:
def jwt = new oracle.apps.fnd.applcore.common.SecuredTokenBean().getTrustToken(); Can anyone advise how do I set this up to test if it works? Any pre-requisites?
My organization is using the Oracle Fusion ERP Cloud - Procurement