Hello,
I am trying to create an app that downloads our call logs and stores them in an interna database. Right now, I have a sandbox app that calls the Call Log API that has 3 dummy calls that I made myself. I can call them from the API , but when I try to visit the recording content URI of any of the calls, I met with this error:
{
"errorCode": "AGW-401",
"message": "Authorization header is not specified",
"errors": [
{
"errorCode": "AGW-401",
"message": "Authorization header is not specified"
}
]
}
Any idea how I can solve this? I think it may be related to getting an access token? I have read that I need one, but have just been using the SDK to login. See below
from ringcentral import SDK
RINGCENTRAL_CLIENTID = 'my id'
RINGCENTRAL_CLIENTSECRET = 'my secret'
RINGCENTRAL_SERVER = 'https://platform.devtest.ringcentral.com'
rcsdk = SDK( RINGCENTRAL_CLIENTID, RINGCENTRAL_CLIENTSECRET, RINGCENTRAL_SERVER)
platform = rcsdk.platform()
JWT_TOKEN = 'my jwt'
try:
platform.login( jwt=JWT_TOKEN )
resp = platform.get('/restapi/v1.0/account/~/extension/~/call-log')
print(resp.text())
except Exception as e:
print ("Unable to authenticate to platform. Check credentials." + str(e))