php - Can Google drive file.insert check before insert, to prevent creating a duplicate folder? -
is there way stop creating duplicate folders in google drive rest api without looping items , compare title folder name.
also how can list folders of root folder.
i have tried pass folder id "root" argument in list files , list children method not getting expected response.
thanks in advance.
files: insert's job create new file. check if file or directory exists before trying create new one.
you might want check out files: list using q option can have api search you. if returns directory exists shouldn't insert it. thing return file id allowing use in later requests.
mimetype = 'application/vnd.google-apps.folder'
title contains 'hello' , title contains 'goodbye'
Comments
Post a Comment