credentials.json
to index. I already have the users access_token
, is there a way to pass this directly without the need to create the credentials file every time? I figure if two people make a request at the same time this file is just going to be overwritten?ERROR:root:error: 'tuple' object has no attribute 'get_doc_id'
c = download_loader('ConfluenceReader') reader = c(base_url=r["base_url"]) documents = reader.load_data(space_key=r["space_key"], include_attachments=False, page_status="current") logging.info("downloading documents") for documents in documents: # TODO: fix this with actual values logging.info("adding confluence link to document") logging.info("storing in pinecone") logging.info("pinecone index name: " + os.environ['PINECONE_INDEX_NAME']) logging.info("pinecone environment: " + os.environ['PINECONE_ENVIRONMENT']) pinecone.init(api_key=os.environ['PINECONE_API_KEY'], environment=os.environ['PINECONE_ENVIRONMENT']) pinecone.Index("astoria").delete(delete_all=True, namespace=workspace_id + "-confluence") vector_store = PineconeVectorStore( index_name=os.environ['PINECONE_INDEX_NAME'], environment=os.environ['PINECONE_ENVIRONMENT'], namespace=workspace_id + "-confluence", )
{"message":"Current user not permitted to use Confluence","statusCode":403}
token = { "access_token": result["access_token"], "token_type": "Bearer", } oauth2_dict = { "client_id": os.environ['CONFLUENCE_CLIENT_ID'], "token": token, } logging.info("oauth2 dict: " + str(oauth2_dict)) c = download_loader('ConfluenceReader') reader = c(base_url=r["base_url"], oauth2=oauth2_dict)