Hi,
I have a basic Node app and having issues authenticating. I have set my server, clientId, secretId and jwt. However, I keep getting this error
The [Audience] claim value must contain a token endpoint URL
My code looks like:
const RC_SDK = require('@ringcentral/sdk').SDK
const path = require('path')
require('dotenv').config({ path: path.resolve(__dirname, './.env') })
var rcsdk = new RC_SDK({
'server': process.env.RC_SERVER_URL,
'clientId': process.env.RC_CLIENT_ID,
'clientSecret': process.env.RC_CLIENT_SECRET
});
var platform = rcsdk.platform();
platform.login({ 'jwt': process.env.RC_JWT })
platform.on(platform.events.loginSuccess, function(e){
console.log('LOGGED IN')
});
platform.on(platform.events.loginError, function(e){
console.log("Unable to authenticate to platform. Check credentials.", e.message)
process.exit(1)
});