from google.oauth2.service_account import Credentials
from googleapiclient.discovery import build
import random
import msvcrt 
import json

credentials_doc = 'service_account.json'

service_account_info = json.load(open(credentials_doc))
credentials = Credentials.from_service_account_info(service_account_info)
service = build('drive', 'v3', credentials=credentials)


document = service.documents().get(documentId=document_id).execute()

document = service.documents().get(documentId=document_id).execute()
AttributeError: ‘Resource’ object has no attribute ‘documents’. Did you mean: ‘comments’?

how can i get my document

I want to get my drive doc infos and processing incomings

New contributor

isil is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.