Below is my code for the IBM Watson document conversion. I keep on getting the error message below when I try to run script in Python. I have my username and password XXXX'd out in the code below, but I have copied and pasted my active username and password so I do not know what would be causing the credential issue. Any help would be appreciated.
watson_developer_cloud.watson_developer_cloud_service.WatsonException: Unauthorized: Access is denied due to invalid credentials
import json
from os.path import join, dirname
from watson_developer_cloud import DocumentConversionV1
document_conversion = DocumentConversionV1(
username="XXXXXXXXXXX",
password="XXXXXXXXXXXXXXXXX",
version='2015-12-15')
with open(join(dirname(__file__), 'a16-23019_2nq.htm'),
'r') as document:
config = {'conversion_target':DocumentConversionV1.NORMALIZED_HTML}
print(document_conversion.convert_document(
document=document, config=config, media_type='text/html').content)