Google Drive Connector
Documentation
Version: 8
Documentation

Google Drive Connector - Source Code


<?xml version="1.0" encoding="utf-8"?>
<ApiConfig Name="Google Drive"
           Desc="Read / write Google Drive data inside your app; perform many Google Drive operations without coding, just using easy to use high performance API Connector for Google Drive"
           Slug="google-drive-connector"
           Id="172fd7a0-c14a-4e6b-9309-b9d69ec5bb07"
           Logo="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAIAAAAByCAYAAACbZNnZAAAAAXNSR0IArs4c6QAAB59JREFUeF7tnU1sVUUYht+5LRiDFgmBJoKNEm1MDBE1Iia6MNJ7dacESFxqiGGhMdGluMKtutDEne6hgsu2CP6RGFMVI/gHJEYImLDwBzAGuO2YQ3vb28s598z/fN85c5ftnJk58z7vO9+ce3srwPm1d6MkMf03jgsS8zCYBL+JUxG9aLGZwcALgPGWxM/nDTgPd4l85DhEE2zWlcdEx1vvAnhpQUaiEGTid73eE028HA49s5HoA3Cg9Txm8cGS2+MBACDwghjDh2bShLmKPgBZ7Oe9iEHQ4/6FGVPfDmgDUCR+Z3mJQFAkfmealCGgC8B4awJAq28QMgEAwKRo4qkwoa43CmUA1M74kSEocz/1FKAJQFn0d0POBIBsyhS3Av4AZCsbCQJV91NOAXoA6Li/s7KnL1zEtfaQ3u5n13rryssXD937m/aY1FKgGgBESAFd91NNAVoAmLg/Qj1gKj5FCOgAYCt+wBSwBYBSQVgtAAJA4EL8BEBv/eXC/YGeDroCgAoENBLAJQAeU8Cl+AmAjmNdi5/1225fwqkLt9od9JZefXXziUvLhHTaJwUI4ibAx8070BZnXAq10Jfjh0Ou3b8wT4kR0cJZL2ug0GlcAHy438Ox0Jv483ON+XAoHgC+xXdYC/gGIOZWUG0AHEAQQvz6ARDC/Z2t4Jc/ZiDlgMJ2eEOT5Q3MXHn4uNG1JuPF2AriJEBIACxSIJT7Yz4iDg9AaPENHxCFFj8WBGEB2N88BiE2mcSj9TWax8JYAAD4XjTxgPX9KnYQFoBY7tdMgYjiX59pyFogHACxxdeoBWIDEBKCegGgAAEF8asHAAX3d7aB83+dwT//jeRtke/fde7M7rV/5v5OcUt12izEVhAmASgB0CcFqLg/5InAPwDUxC8oCKmJHwoCvwBQFT8nBagC4LseqC8AXRBQFp8vAJTd37MNUAfAJwT+EoADAADk0KTTyt1XZ75OBH4AYCI+ZocGJfYDt6HtSziX/fqAwD0AH7UehMS3Lm/cW1/bJ6/fv5yC2l8ie5uIYscDeEg8ie8UWys1cw8AF/fPi99ZJS4QuE4BtwBwET9TnSkArgvCegLQI36dU8AdAHzcfxXbJ2/K2yDlFK4AWK60eUZu5GorqB8ABe6vawq4AYCL+0vEryME9gCMt34HQOYt1L7JXDEAIDAhxvC0zW7kAgAeZ2hF8euWAnYAcIn+nGNfmWu4PBewPRbWAwBN99cpBcwBYON+8Ta2T7xW5viCY+FbAF41uTb0NabHwuoDYOj+uqSAGQBc3G8pfh0g0AeAi/gGhV9RbDMqCNuiiWU62091AXDk/qqngB4ANXQ/NwB0j4XVBMCx+7lBoHMiUAeAi/tnhwaxc/+Mzj6o2lbuw0DVPj6mBsC+sU1oNI6pLlTUdp7czy0F8DcGxU6UGkENAC7u9yw+NwhUtoJyALiI7/DYV5ZgjI6Fpd81UB0AArm/ainQH4Dk/sIwqEoKVAOAwO6vUgoUA8DF/ZHErwoE+QCMt04AuK+sGCLx+wSAmgwSG0ULma5LXkUAVPJjXmorpd+KSz2Qdyy8EQAu0R/w2FeGBBcA8t4n4AtA5OjvhYILBL0psBQALu6X8iB2TG0rc2bI38spHADwbMgxTcfqhoAnAMTcz/lEsAgAF/cTFZ8rBHMAcBGfUOFXFL9cagE0sFlsxTQvAIi7n2MKJABMK6k+13FJgawYFGzin4n72aUACwCuza7Dc4fOezCrty7lFG4HcM7bAI465pEAzNzPKQUEdv9E+rn/6PpRR6zH6eboF1viDKw4qsCLJ2kDMLJB8VZoNjv66aM0JzY/K9IAjDIXv6M8ZQgSAAH8SRuAbAEIbgNVcT/lFFh7eFrMPQgiBkDVxKcKQRcAvx4ExDMB0lBpiASA0jJZNZISB4ePTG9bfDeQSApUVXxqKZC5P5vT0s8DEIAgAWBlbKWLO+KTA6Dq4lNJgWIAIhaEq1euOrV65ap7lBBm3uiV0+9gx9l9Ue6iW/wbEyAiAHVxf+wUKAcgAgR1Ez8WBL3i5ydA9tNdp7agIb8KlVEJgAArLRqPr/3k66O9IxX/bWCgE0FdxQ+dAnnuL06AzuwCQJAA8P9uYZH40QGou/ihUsAcAI8F4ejIhuyfNQ4G2P3IDzEgZ/D5Z495mWc/8csTwC8AXm6Ya6e+3jK2B8ADBCn68zF1DUGZ+GoJMDfX7IMjs67clQDwD8Caw9MNgfJ/iVv+LWGOTwRJ/P42cpUCKu7XSYC5WVseCxuNxpW719+Z+08bXaUL934mvhzDLe3LVrehKn5wAJL71XS1TQF/AFikQBJfTXzbZwM64usnwHUAzD4+lgDwD4CE/GH48Df364ykXgR296pZCyTxdSRZbKu7Fei63ywBDE4FCQD/AJiIHwSAJL6Z+Lq1QHgAFArCdWuG/11x84oVdktQ76ufuHAEe398ve8imIpvlwAKACT3u4G3rBaIB0AfCJL4bsQv2wpsxLdPgD4FYQLAPwC24rsDoCcJkvhuxc9LARfiuwWgC4IEgF8AXInvHoD5+x59s036W0f8yOO/15N7Bs0e3PWZmvMOu8dKIDiBQp7cM9hw0lNOJ/8D2+XdP1Q0hRoAAAAASUVORK5CYII="
           Version="8"
           EngineVersion="4"
           >
	<VersionHistory>
          <Change Ver="8" Type="New" Date="2025-01-28">Added images in User Account and Service Account authentication instructions.</Change>               		
	     <Change Ver="8" Type="New" Date="2025-01-24">Added ImpersonateAs property for Service Account authentication (Requires Domain-wide delegation ON and needs Google Workspace account)</Change>
          <Change Ver="8" Type="New" Date="2024-06-05">Added Redirect URL property to support Web Application credentials (visible when show advanced option checked).</Change>
		<Change Type="Fix" Date="2023-09-21">EndPoint list_files should not include folders.</Change>
		<Change Type="Fix" Date="2023-09-21">EndPoints like list_files, list_folders, list_items and tables like Files, Folders should not include deleted items.</Change>
	     <Change Type="New" Date="2023-09-21">Add ContineOn404Error support in Files / Folders endpoints which takes File Id as input.</Change>
		<Change Type="New" Date="2023-09-21">Add lookup support in Files / Folders table.</Change>
		<Change Type="Fix" Date="2023-09-21">create_folder endpoint creating file rather than folder.</Change>
		<Change Type="New" Date="2023-09-21">Add support for Shared Drive for all operations (i.e. Download / Upload / Delete / List).</Change>
		<Change Type="Modified" Date="2023-04-13">Added HelpLinks all the endpoints.</Change>
		<Change Type="Modified" Date="2022-09-15">Added new endpoint export_file. Using this endpoint, you can export/convert various Google editor document types (e.g. Documents, Spreadsheets, Drawings, Presentations, Apps Scripts ) to known file formats (e.g. HTML, PDF, Excel, Text, PowerPoint).</Change>
		<Change Type="Modified" Date="2022-09-06">Updated endpoint to display the search criteria by default, added the pagination for files,folder list endpoints.</Change>
		<Change Type="Modified" Date="2022-01-11">Changed Update endpoint to update files by using chunk method.</Change>
		<Change Type="Modified" Date="2022-01-11">Changed File select operation to list files rather than download operation (BREAKING CHANGE!).</Change>
		<Change Type="New" Date="2022-01-11">Added select operation for Trash table.</Change>
		<Change Date="2022-01-10">Added support for uploading large files using chunked upload (handle more than 200MB).</Change>
		<Change Date="2022-01-10">Change Minimum EngineVersion to 4 (from 3).</Change>
		<Change Date="2021-10-06">Added parameters to Upload File endpoint.</Change>
		<Change Date="2021-09-18">Change Minimum EngineVersion to 3 (from 2).</Change>
		<Change Date="2021-09-15">Updated how params are used with UseCustomApp. Added new Authentication type - ServiceAccount. Added "delete_all_items" endpoint.</Change>
		<Change Date="2021-08-23">Initial version</Change>
	</VersionHistory>

	<ServiceUrls>
		<ServiceUrl Name="https://www.googleapis.com/" Url="https://www.googleapis.com/" />
	</ServiceUrls>
	<Auths>
		<Auth Name="OAuth"
                Label="User Account" 
                Desc="User accounts represent a developer, administrator, or any other person who interacts with Google APIs and services. User accounts are managed as Google Accounts, either with Google Workspace or Cloud Identity. They can also be user accounts that are managed by a third-party identity provider and federated with Workforce Identity Federation."          
                HelpLink="https://cloud.google.com/docs/authentication#user-accounts"
			 Type="OAuth" 
                ConnStr="Provider=GoogleSheets;ScopeSeparator={space};RetryMode=[$RetryMode$];RetryStatusCodeList=[$RetryStatusCodeList$]"
			 TestEndPoint="get_about">
		<Notes>
        <![CDATA[
<p>
    Follow these steps on how to create Client Credentials (User Account principle) to authenticate and access Google Drive API in SSIS package or ODBC data source:    
</p>
<div class="alert alert-warning">
    <strong>WARNING</strong>: 
        
    If you are planning to automate processes, we recommend that you use a <em>Service Account</em> authentication method.    
    In case, you still need to use <em>User Account</em>, then make sure you use a system/generic account (e.g. <code>automation@my-company.com</code>).
    When you use a personal account which is tied to a specific employee profile and that employee leaves the company, 
    the token may become invalid and any automated processes using that token will start to fail.
</div>    

<h3>Step-1: Create project</h3>
<p>
    This step is optional, if you already have a project in Google Cloud and can use it.
    However, if you don't, proceed with these simple steps to create one:
</p>
<ol>
     <li>
          <p>
             First of all, go to <a target="_blank" href="https://console.developers.google.com/">Google API Console</a>.
          </p>
     </li>
	<li>
          <p>
             Then click <strong>Select a project</strong> button and then click <strong>NEW PROJECT</strong> button:
          </p>
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/start-creating-new-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Start creating a new project in Google Cloud"
		     title="Starting creating a new project in Google Cloud"
		     width="1000"
		     height="340" />
	</li>
	<li>
          <p>
             Name your project and click <strong>CREATE</strong> button:
          </p>
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/create-new-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Create a new project in Google Cloud"
		     title="Creating a new project in Google Cloud"
		     width="680"
		     height="360" />
	</li>
	<li>
          <p>
             Wait until the project is created:
          </p>          
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/wait-until-project-is-created-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Wait until project is created in Google Cloud"
		     title="Waiting until project is created in Google Cloud"
		     width="640"
		     height="390" />
	</li>
     <li>
        Done! Let's proceed to the next step.
     </li>
</ol>



<h3>Step-2: Enable Google Drive API</h3>
<p>
    In this step we will enable Google Drive API:
</p>
<ol>
	<li>
          <p>
             Select your project on the top bar:
          </p>          
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/select-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Select project in Google Cloud"
		     title="Selecting project in Google Cloud"
		     width="1000"
		     height="400" />
	</li>
     <li>
          <p>
              Then click the <strong>"hamburger"</strong> icon on the top left and access 
              <a target="_blank" href="https://console.cloud.google.com/apis/dashboard">APIs & Services</a>:
          </p>
          <img src="https://cdn.zappysys.com/api/Images/authentication/google/access-apis-and-services-in-google-cloud.png"
               loading="lazy"
               decoding="async"
               class="img-thumbnail block"
               alt="Access APIs and services in Google Cloud"
               title="Accessing APIs and services in Google Cloud"
               width="990"
               height="440" />
    </li>
    <li>
        <p>
            Now let's enable several APIs by clicking <strong>ENABLE APIS AND SERVICES</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/enable-api-for-project-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Enable API for project in Google Cloud"
             title="Enabling API for project in Google Cloud"
             width="800"
             height="300" />
    </li>
    <li>
        <p>
            In the search bar search for <code>drive</code> and then locate and select <strong>Google Drive API</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/search-for-api-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Search for API in Google Cloud"
             title="Searching for API in Google Cloud"
             width="1000"
             height="390" />
    </li>
    <li>
        <p>
            Enable <strong>Google Drive API</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/enable-google-drive-api.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Enable Google Drive API"
             title="Enabling Google Drive API"
             width="620"
             height="350" />
    </li>
    <li>
        Done! Let's proceed to the next step.
    </li>    
</ol>



<h3>Step-3: Create OAuth application</h3>
<ol>
    <li>
        <p>
            First of all, click the <strong>"hamburger"</strong> icon on the top left and then hit <strong>VIEW ALL PRODUCTS</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/view-all-products-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="View all products in Google Cloud"
             title="Viewing all products in Google Cloud"
             width="990"
             height="700" />
    </li>
    <li>
        <p>
            Then access 
            <a target="_blank" href="https://console.cloud.google.com/auth">Google Auth Platform</a>
            to start creating an OAuth application:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/open-google-auth-platform-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Open Google Auth Platform in Google Cloud"
             title="Opening Google Auth Platform in Google Cloud"
             width="1000"
             height="430" />
    </li>
    <li>
        <p>
            Start by pressing <strong>GET STARTED</strong> button:
        </p>        
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/start-creating-app-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Start creating an app in Google Cloud"
             title="Starting creating an app in Google Cloud"
             width="1000"
             height="340" />
    </li>    
    <li>
        <p>
            Next, continue by filling in <strong>App name</strong> and <strong>User support email</strong> fields:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/fill-app-info-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Fill app info in Google Cloud"
             title="Filling app info in Google Cloud"
             width="850"
             height="440" />
    </li>
    <li>
        <p>
            Choose <strong>Internal</strong> option, if it's enabled, otherwise select <strong>External</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/choose-app-audience-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Choose app audience in Google Cloud"
             title="Choosing app audience in Google Cloud"
             width="850"
             height="590" />
    </li>
    <li>
        <p>
            <em>Optional step if you used <code>Internal</code> option in the previous step</em>. 
            Nevertheless, if you had to use <code>External</code> option, then click <strong>ADD USERS</strong> to add a user:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/add-test-user-in-google-cloud-app.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Add test user in Google Cloud app"
             title="Adding test user in Google Cloud app"
             width="1000"
             height="990" />
    </li>
    <li>
        <p>
            Then add your contact <strong>Email address</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/enter-app-contact-info-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Enter app contact info in Google Cloud"
             title="Entering app contact info in Google Cloud"
             width="850"
             height="510" />
    </li>
    <li>
        <p>
            Finally, check the checkbox and click <strong>CREATE</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/create-app-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Create app in Google Cloud"
             title="Creating app in Google Cloud"
             width="850"
             height="580" />
    </li>
    <li>
        Done! Let's create Client Credentials in the next step.
    </li>
</ol>



<h3>Step-4: Create Client Credentials</h3>
<ol>
    <li>        
        <p>
            In 
            <a target="_blank" href="https://console.cloud.google.com/auth">Google Auth Platform</a>, 
            select <strong>Clients</strong> menu item and click <strong>CREATE CLIENT</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/start-creating-app-client-in-google-cloud.png"
	       loading="lazy"
	       decoding="async"
	       class="img-thumbnail block"
	       alt="Start creating app client in Google Cloud"
	       title="Starting creating app client in Google Cloud"
	       width="1000"
	       height="340" />
    </li>
    <li>
        <p>
            Choose <code>Desktop app</code> as <strong>Application type</strong> and name your credentials:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/create-oauth-app-client-in-google-cloud.png"
	       loading="lazy"
	       decoding="async"
	       class="img-thumbnail block"
	       alt="Create OAuth app client in Google Cloud"
	       title="Creating OAuth app client in Google Cloud"
	       width="1000"
	       height="500" />
    </li>
    <li>
        <p>
            Continue by opening the created credentials:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/view-app-client-credentials-in-google-cloud.png"
	       loading="lazy"
	       decoding="async"
	       class="img-thumbnail block"
	       alt="View app client credentials in Google Cloud"
	       title="Viewing app client credentials in Google Cloud"
	       width="1000"
	       height="370" />
    </li>
    <li>
        <p>
            Finally, copy <strong>Client ID</strong> and <strong>Client secret</strong> for the later step:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/user-account/use-client-id-and-secret-to-read-google-rest-api-data.png"
	       loading="lazy"
	       decoding="async"
	       class="img-thumbnail block"
	       alt="Use client ID and secret to read Google REST API data"
	       title="Using client ID and secret to read Google REST API data"
	       width="770"
	       height="360" />
    </li>
    <li>  
        Done! We have all the data needed for authentication, let's proceed to the last step!
    </li>    
</ol>




<h3>Step-5: Configure connection</h3>
<ol>
    <li>
        <p>
            Now go to SSIS package or ODBC data source and use previously copied values in <strong>User Account</strong> authentication configuration:
        </p>
	   <ul>
            <li>In the <strong>ClientId</strong> field paste the <strong>Client ID</strong> value.</li>
            <li>In the <strong>ClientSecret</strong> field paste the <strong>Client secret</strong> value.</li>            
        </ul>
    </li>
    <li>
        <p>
            Press <strong>Generate Token</strong> button to generate Access and Refresh Tokens.
        </p>
    </li>
    <li>
        <p>
            Finally, click <strong>Test Connection</strong> to confirm the connection is working.
        </p>
    </li>
    <li>
        Done! Now you are ready to use Google Drive Connector!
    </li>        
</ol>
        ]]>
			</Notes>
			<Params>
				<Param Name="UseCustomApp" Value="True" Required="True" Hidden="False" Desc="Use your own app credentials or inbuilt app provided by ZappySys for ease of use. If you choose UseCustomApp=true then make sure to obtain your own ClientId and Secret using steps provided (Click [Steps to Configure] link found next to Authentication Type dropdown)" />
				<Param Name="ClientId" VisibleIf="UseCustomApp" RequiredIf="UseCustomApp"/>
				<Param Name="ClientSecret" Secret="True" VisibleIf="UseCustomApp" RequiredIf="UseCustomApp" />
				<Param Name="Scope" Value="https://www.googleapis.com/auth/drive" />
				<Param Name="RetryMode" Value="RetryWhenStatusCodeMatch" Options="None;RetryAny;RetryWhenStatusCodeMatch;" Hidden="True" />
				<Param Name="RetryStatusCodeList" Value="403|429" Hidden="True" />
				<Param Name="RetryCountMax" Value="5" Hidden="True" />
				<Param Name="RetryMultiplyWaitTime" Value="True" Hidden="True" />   
				<Param Name="ReturnUrl" Label="Redirect URL (Only for Web App)" Options=";https://zappysys.com/oauth/" VisibleIf="UseCustomApp" Desc="Only specifiy this if you have created Credential as Web Application rather than Desktop. In Desktop App you dont have to supply Return URL (its always localhost). When you keep this blank it uses default value http://localhost:[some_random_port_each_time] for redirect_url)"  />
			</Params>
		</Auth>

		<Auth Name="ServiceAccount" 
                Label="Service Account" 
                Desc="Service accounts are accounts that do not represent a human user. They provide a way to manage authentication and authorization when a human is not directly involved, such as when an application needs to access Google Cloud resources. Service accounts are managed by IAM."
                HelpLink="https://cloud.google.com/docs/authentication#service-accounts"
			 Type="OAuth" 
                ConnStr="Provider=GoogleSheets;UseCustomApp=True;UseClientCertificate=True;CertificateStorageType=PfxFile;CertificatePath=[$PrivateKeyPath$];GrantType=ClientCredentials;RetryMode=RetryWhenStatusCodeMatch;RetryStatusCodeList=403"
			 TestEndPoint="get_about">
			<Params>
				<Param Name="ClientId" Label="Service Account Email" Desc="This is service account email ID (e.g. some_name@my_project.iam.gserviceaccount.com)" Required="True" />
				<Param Name="PrivateKeyPath" Label="Service Account Private Key Path (i.e. *.p12)" Desc="File path for p12 file (i.e. Private Key file for service account). Keep this key file secure" Required="True" />
				<Param Name="Scope" Value="https://www.googleapis.com/auth/drive" />

				<Param Name="RetryMode" Value="RetryWhenStatusCodeMatch" Options="None;RetryAny;RetryWhenStatusCodeMatch;" Hidden="True" />
				<Param Name="RetryStatusCodeList" Value="403|429" Hidden="True" />
				<Param Name="RetryCountMax" Value="5" Hidden="True" />
				<Param Name="RetryMultiplyWaitTime" Value="True" Hidden="True" />   
				<Param Name="ImpersonateAs" Type="Property" Key="ExtraAttributesForTokenRequest" Hidden="False" ValueTemplate="user={$value$}" Label="Impersonate As (Google account email address)" />
			</Params>

			<Notes>				                    
				<![CDATA[
<p>
    Follow these steps on how to create Service Account to authenticate and access Google Drive API in SSIS package or ODBC data source:
</p>

<h3>Step-1: Create project</h3>
<p>
    This step is optional, if you already have a project in Google Cloud and can use it.
    However, if you don't, proceed with these simple steps to create one:
</p>
<ol>
     <li>
          <p>
             First of all, go to <a target="_blank" href="https://console.developers.google.com/">Google API Console</a>.
          </p>
     </li>
	<li>
          <p>
             Then click <strong>Select a project</strong> button and then click <strong>NEW PROJECT</strong> button:
          </p>
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/start-creating-new-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Start creating a new project in Google Cloud"
		     title="Starting creating a new project in Google Cloud"
		     width="1000"
		     height="340" />
	</li>
	<li>
          <p>
             Name your project and click <strong>CREATE</strong> button:
          </p>
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/create-new-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Create a new project in Google Cloud"
		     title="Creating a new project in Google Cloud"
		     width="680"
		     height="360" />
	</li>
	<li>
          <p>
             Wait until the project is created:
          </p>          
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/wait-until-project-is-created-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Wait until project is created in Google Cloud"
		     title="Waiting until project is created in Google Cloud"
		     width="640"
		     height="390" />
	</li>
     <li>
        Done! Let's proceed to the next step.
     </li>
</ol>



<h3>Step-2: Enable Google Drive API</h3>
<p>
    In this step we will enable Google Drive API:
</p>
<ol>
	<li>
          <p>
             Select your project on the top bar:
          </p>          
		<img src="https://cdn.zappysys.com/api/Images/authentication/google/select-project-in-google-cloud.png"
		     loading="lazy"
		     decoding="async"
		     class="img-thumbnail block"
		     alt="Select project in Google Cloud"
		     title="Selecting project in Google Cloud"
		     width="1000"
		     height="400" />
	</li>
     <li>
          <p>
              Then click the <strong>"hamburger"</strong> icon on the top left and access 
              <a target="_blank" href="https://console.cloud.google.com/apis/dashboard">APIs & Services</a>:
          </p>
          <img src="https://cdn.zappysys.com/api/Images/authentication/google/access-apis-and-services-in-google-cloud.png"
               loading="lazy"
               decoding="async"
               class="img-thumbnail block"
               alt="Access APIs and services in Google Cloud"
               title="Accessing APIs and services in Google Cloud"
               width="990"
               height="440" />
    </li>
    <li>
        <p>
            Now let's enable several APIs by clicking <strong>ENABLE APIS AND SERVICES</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/enable-api-for-project-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Enable API for project in Google Cloud"
             title="Enabling API for project in Google Cloud"
             width="800"
             height="300" />
    </li>
    <li>
        <p>
            In the search bar search for <code>drive</code> and then locate and select <strong>Google Drive API</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/search-for-api-in-google-cloud.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Search for API in Google Cloud"
             title="Searching for API in Google Cloud"
             width="1000"
             height="390" />
    </li>
    <li>
        <p>
            Enable <strong>Google Drive API</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/enable-google-drive-api.png"
             loading="lazy"
             decoding="async"
             class="img-thumbnail block"
             alt="Enable Google Drive API"
             title="Enabling Google Drive API"
             width="620"
             height="350" />
    </li>
    <li>
        Done! Let's proceed to the next step.
    </li>    
</ol>



<h3>Step-3: Create Service Account</h3>
<p>
    Use the steps below to create a Service Account in Google Cloud:
</p>
<ol>    
    <li>
        <p>
            First of all, go to 
            <a target="_blank" href="https://console.cloud.google.com/iam-admin/iam">IAM & Admin</a> 
            in Google Cloud console:
        </p>
        
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/access-iam-and-admin-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Access IAM & Admin in Google Cloud" 
             title="Accessing IAM & Admin in Google Cloud" 
             width="690" 
             height="510" /> 
    </li>
    <li>        
        <p>
            Once you do that, click <strong>Service Accounts</strong> on the left side 
            and click <strong>CREATE SERVICE ACCOUNT</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/start-creating-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Start creating service account in Google Cloud" 
             title="Starting creating service account in Google Cloud" 
             width="1000" 
             height="500" /> 
    </li>
    <li>
        <p>
            Then name your service account and click <strong>CREATE AND CONTINUE</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/create-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Create service account in Google Cloud" 
             title="Creating service account in Google Cloud" 
             width="750" 
             height="450" /> 
    </li>
    <li>
        <p>
            Continue by clicking <strong>Select a role</strong> dropdown 
            and start granting service account Project Viewer roles:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/start-granting-service-account-project-roles-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Start granting service account project roles in Google Cloud" 
             title="Starting granting service account project roles in Google Cloud" 
             width="750" 
             height="250" /> 
    </li>     
    <li>
        <p>
            Find <strong>Project</strong> group 
            and select <strong>Viewer</strong> role:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/grant-service-account-project-viewer-role.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Grant service account project viewer role" 
             title="Granting service account project viewer role" 
             width="540" 
             height="410" />                  
    </li>
    <li>
        <p>
            Finish adding roles by clicking <strong>CONTINUE</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/finish-granting-service-account-project-roles-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Finish granting service account project roles in Google Cloud" 
             title="Finishing granting service account project roles in Google Cloud" 
             width="750" 
             height="370" /> 
            
        <div class="alert alert-info alert-title">
            You can always add or modify permissions later in 
            <a target="_blank" href="https://console.cloud.google.com/iam-admin/iam">IAM & Admin</a>.
        </div>
    </li>
    <li>
        <p>
            Finally, in the last step, just click button <strong>DONE</strong>:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/finish-configuring-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Finish configuring service account in Google Cloud" 
             title="Finishing configuring service account in Google Cloud" 
             width="750" 
             height="350" /> 
    </li>
    <li>
        <p>
            Done! We are ready to add a Key to this service account in the next step.
        </p>
    </li>        
</ol>



<h3>Step-4: Add Key to Service Account</h3>
<p>
    We are ready to add a Key (P12 certificate) to the created Service Account:
</p>
<ol>    
    <li>
        <p>
            In <a target="_blank" href="https://console.cloud.google.com/iam-admin/serviceaccounts">Service Accounts</a>
            open newly created service account:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/open-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Open service account in Google Cloud" 
             title="Opening service account in Google Cloud" 
             width="750" 
             height="350" /> 
    </li>    
    <li>
        <p>
            Next, copy email address of your service account for the later step:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/copy-service-account-email-address-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Copy service account email address in Google Cloud" 
             title="Copying service account email address in Google Cloud" 
             width="600" 
             height="370" /> 
    </li>
    <li>
        <p>
            Continue by selecting <strong>KEYS</strong> tab, 
            then press <strong>ADD KEY</strong> dropdown, 
            and click <strong>Create new key menu</strong> item:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/start-creating-key-for-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Start creating key for service account in Google Cloud" 
             title="Starting creating key for service account in Google Cloud" 
             width="750" 
             height="530" /> 
    </li>
    <li>
        <p>
            Finally, select <strong>P12</strong> option and hit <strong>CREATE</strong> button:
        </p>
        <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/create-p12-key-for-service-account-in-google-cloud.png" 
             loading="lazy" 
             decoding="async" 
             class="img-thumbnail block" 
             alt="Create P12 key for service account in Google Cloud" 
             title="Creating P12 key for service account in Google Cloud" 
             width="600" 
             height="400" /> 
    </li>    
    <li>
        P12 certificate downloads into your machine. We have all the data needed for authentication, let's proceed to the last step!
    </li>
</ol>



<h3>Step-5: Share Google Drive files and folders with Service Account</h3>
<p>
    Now it's time to grant Google Drive read/write permissions to the created service account:
</p>
<ol>
    <li>Login to https://drive.google.com with Google account credentials whose files/folders you want to share with the service account.</li>      
    <li>
	   <p>
		  Select the file or folder, right-click on it, click <strong>Share</strong> menu item, and then hit <strong>Share</strong> subitem:
	   </p>
	   <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/start-sharing-google-drive-file-or-folder-with-service-account.png" 
		   loading="lazy" 
		   decoding="async" 
		   class="img-thumbnail block" 
		   alt="Share Google Drive file or folder with service account" 
		   title="Sharing Google Drive file or folder with service account" 
		   width="950" 
		   height="440" />
    </li>      
    <li>
	   <p>
		  Share it with your service account:
        </p>
	   <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/share-google-drive-folder-with-service-account.png" 
		   loading="lazy" 
		   decoding="async" 
		   class="img-thumbnail block" 
		   alt="Share Google Drive folder with service account" 
		   title="Sharing Google Drive folder with service account" 
		   width="500" 
		   height="410" />         
    </li>
    <li>
	   <p>
		  Grant it appropriate permissions, e.g. <code>Viewer</code> or <code>Editor</code> (for reading or writing):
        </p>
	   <img src="https://cdn.zappysys.com/api/Images/authentication/google/Service-Account/grant-service-account-google-drive-file-permissions.png" 
		   loading="lazy" 
		   decoding="async" 
		   class="img-thumbnail block" 
		   alt="Grant service account Google Drive file permissions" 
		   title="Granting service account Google Drive file permissions" 
		   width="500" 
		   height="290" />         	   
    </li>    
    <li>
	   That's it! Let's proceed to the configuration!
    </li>
</ol>



<h3>Step-6: Configure connection</h3>
<ol>
    <li>
        <p>
            Now go to SSIS package or ODBC data source and configure these fields in <strong>Service Account</strong> authentication configuration:
        </p>
	   <ul>
            <li>In the <strong>Service Account Email</strong> field paste the service account <strong>Email address</strong> value you copied in the previous step.</li>        
            <li>In the <strong>Service Account Private Key Path (i.e. *.p12)</strong> field use downloaded certificate's file path.</li>
       </ul>
    </li>       
    <li>
        Done! Now you are ready to use Google Drive Connector!
    </li>
</ol>

]]>
			</Notes>
		</Auth>


	</Auths>


	<Template>
		<EndPoint Name="DriveSupportTemplate">
			<Params>
				<Param Name="DriveId" Label=" Shared DriveId" RequiredIf="DriveType==drive" VisibleIf="DriveType==drive" Key="driveId" Type="Query" 
				OptionsEndPoint="list_shared_drives"  Desc="By default file lists from MyDrive but if you like to search other Shared drive (formally known as Team drive) then set this parameter." 
					OptionsEndPointValueColumn="Id" OptionsEndPointLabelColumn="Name" />

				<Param Name="DriveType" Label=" Drive Type" Key="corpora" Required="True" Value="user" Options=";My Drive=user;Shared Drive=drive;" Type="Query" 
					Desc="Default search context is User's drive. Bodies of items (files/documents) to which the query applies. Supported bodies are 'user', 'domain', 'drive', and 'allDrives'. Prefer 'user' or 'drive' to 'allDrives' for efficiency. By default, corpora is set to 'user'. However, this can change depending on the filter set through the 'Query' parameter."/>
				
				<Param Name="SupportsAllDrives" Key="supportsAllDrives" Value="true" Label=" Supports all drives (e.g. My and Shared)" Desc="Whether the requesting application supports both My Drives and shared drives." Type="Query" Options=";true;false" Hidden="True" />				
			    <Param Name="ContineOn404Error" Label=" Continue processing on 404 error" Type="Property" Value="False" Options="False;True" Hidden="False" />
			</Params>	 			
		</EndPoint>
		
		<EndPoint Name="ListSharedDrivesTemplate">
			<Params>
				<Param Name="NextUrlAttributeOrExpr"
						Value="$.nextPageToken"
						Type="Property"/>
				<Param Name="NextUrlSuffix"
						Value="pageToken=&lt;%nextlink%&gt;"
						Type="Property"/>
				<Param Name="pageSize" Label="PageSize" Type="Query" Value="100" Hidden="True" />
				
				<Param Name="Query" Key="q" Label=" Search Criteria (Keep blank to get all)" 
					Type="Query" Options="None=;By name (exact name match)=name='abc';By name (contains sub string)=name contains 'abc';By name (does not contain)=not name contains 'abc';By text (search inside file)=fullText contains 'abc';By created time=createdTime > '2012-06-04T12:00:00'" Desc="File list filter" HelpLink="https://developers.google.com/drive/api/v3/search-files#query_string_examples"/>
				
				<Param Name="useDomainAdminAccess" Label="UseDomainAdminAccess" 
					Type="Query" Options=";true;false" Desc="Some operations such as searching for shared drives with specific attributes might need Admin access (set this to true)"/>
			</Params>
			<OutputColumns>
				<Column Name="id" DataType="DT_WSTR" Label="Id" Length="500" />
				<Column Name="name" DataType="DT_WSTR" Label="Name" Length="50" />
				<Column Name="colorRgb" DataType="DT_WSTR" Label="ColorRgb" Length="100" />
				<Column Name="kind" DataType="DT_WSTR" Label="Kind" Length="500" />
				<Column Name="backgroundImageLink" DataType="DT_WSTR" Label="BackgroundImageLink" Length="1000" />
				<Column Name="capabilities.canAddChildren" DataType="DT_BOOL" Label="CanAddChildren" />
				<Column Name="capabilities.canComment" DataType="DT_BOOL" Label="CanComment" />
				<Column Name="capabilities.canCopy" DataType="DT_BOOL" Label="CanCopy" />
				<Column Name="capabilities.canDeleteDrive" DataType="DT_BOOL" Label="CanDeleteDrive" />
				<Column Name="capabilities.canDownload" DataType="DT_BOOL" Label="CanDownload" />
				<Column Name="capabilities.canEdit" DataType="DT_BOOL" Label="CanEdit" />
				<Column Name="capabilities.canListChildren" DataType="DT_BOOL" Label="CanListChildren" />
				<Column Name="capabilities.canManageMembers" DataType="DT_BOOL" Label="CanManageMembers" />
				<Column Name="capabilities.canReadRevisions" DataType="DT_BOOL" Label="CanReadRevisions" />
				<Column Name="capabilities.canRename" DataType="DT_BOOL" Label="CanRename" />
				<Column Name="capabilities.canRenameDrive" DataType="DT_BOOL" Label="CanRenameDrive" />
				<Column Name="capabilities.canChangeDriveBackground" DataType="DT_BOOL" Label="CanChangeDriveBackground" />
				<Column Name="capabilities.canShare" DataType="DT_BOOL" Label="CanShare" />
				<Column Name="capabilities.canChangeCopyRequiresWriterPermissionRestriction" DataType="DT_BOOL" Label="CanChangeCopyRequiresWriterPermissionRestriction" />
				<Column Name="capabilities.canChangeDomainUsersOnlyRestriction" DataType="DT_BOOL" Label="CanChangeDomainUsersOnlyRestriction" />
				<Column Name="capabilities.canChangeDriveMembersOnlyRestriction" DataType="DT_BOOL" Label="CanChangeDriveMembersOnlyRestriction" />
				<Column Name="capabilities.canChangeSharingFoldersRequiresOrganizerPermissionRestriction" DataType="DT_BOOL" Label="CanChangeSharingFoldersRequiresOrganizerPermissionRestriction" />
				<Column Name="capabilities.canResetDriveRestrictions" DataType="DT_BOOL" Label="CanResetDriveRestrictions" />
				<Column Name="capabilities.canDeleteChildren" DataType="DT_BOOL" Label="CanDeleteChildren" />
				<Column Name="capabilities.canTrashChildren" DataType="DT_BOOL" Label="CanTrashChildren" />
				<Column Name="createdTime" DataType="DT_DBTIMESTAMP" Label="CreatedTime" />
				<Column Name="hidden" DataType="DT_BOOL" Label="Hidden" />
				<Column Name="restrictions.copyRequiresWriterPermission" DataType="DT_BOOL" Label="CopyRequiresWriterPermission" />
				<Column Name="restrictions.domainUsersOnly" DataType="DT_BOOL" Label="DomainUsersOnly" />
				<Column Name="restrictions.driveMembersOnly" DataType="DT_BOOL" Label="DriveMembersOnly" />
				<Column Name="restrictions.adminManagedRestrictions" DataType="DT_BOOL" Label="AdminManagedRestrictions" />
				<Column Name="restrictions.sharingFoldersRequiresOrganizerPermission" DataType="DT_BOOL" Label="SharingFoldersRequiresOrganizerPermission" />
			</OutputColumns>
		</EndPoint>
		
		<EndPoint Name="ListItemsTemplate"  
					Url="/drive/v3/files?fields=nextPageToken,files(*)" Method="GET" Filter="$.files[*]" 
					HelpLink="https://developers.google.com/drive/api/v3/reference/files/list"
              >
			<Params>
				<Param Name="DriveId" Label=" Shared DriveId" RequiredIf="DriveType==drive" VisibleIf="DriveType==drive" Key="driveId" Type="Query" OptionsEndPoint="list_shared_drives"  Desc="By default file lists from MyDrive but if you like to search other Shared drive (formally known as Team drive) then set this parameter." 
					OptionsEndPointValueColumn="Id" OptionsEndPointLabelColumn="Name" />

				<Param Name="DriveType" Label=" Drive Type" Key="corpora" Type="Query" Required="True" Value="user" Options=";My Drive=user;Shared Drive=drive;All Drives=allDrives;" 
					Desc="Default search context is User's drive. Bodies of items (files/documents) to which the query applies. Supported bodies are 'user', 'domain', 'drive', and 'allDrives'. Prefer 'user' or 'drive' to 'allDrives' for efficiency. By default, corpora is set to 'user'. However, this can change depending on the filter set through the 'Query' parameter."/>

			
				<Param Name="NextUrlAttributeOrExpr" Value="$.nextPageToken" Type="Property"/>
				<Param Name="NextUrlSuffix" Value="pageToken=&lt;%nextlink%&gt;" Type="Property"/>
				<Param Name="pageSize" Label="PageSize" Type="Query" Value="1000" Hidden="True" />
				
					
				<Param Name="SupportsAllDrives" Key="supportsAllDrives" Value="true" Label=" Supports all drives (e.g. My and Shared)" Desc="Whether the requesting application supports both My Drives and shared drives." Type="Query" Options=";true;false" Hidden="True" />				

				<Param Name="IncludeItemsFromAllDrives" Value="true" VisibleIf="DriveType==allDrives | DriveId " Key="includeItemsFromAllDrives" Options=";true;false" Type="Query" Label=" Include items from all drives (e.g. My and Shared)" />
				<Param Name="Spaces" Key="spaces" Label=" Spaces to include in corpora (comma separed)" Type="Query"/>				
				
				<Param Name="IncludePermissionsForView" Key="includePermissionsForView" Label=" Include Permissions For View" Options=";true;false" Type="Query"/>
				<Param Name="IncludeLabels" Key="includeLabels" Label=" Include Labels" Options=";true;false" Type="Query"/>
				
				<Param Name="Query" Key="q" Label=" Search Criteria" Type="Query" Value="trashed!=true"
					   Options="None=;
					   By name (exact name match)=name='abc';
					   By name (contains sub string)=name contains 'abc';
					   By name (does not contain)=not name contains 'abc';
					   By text (search inside file)=fullText contains 'abc';
					   By created time=createdTime > '2012-06-04T12:00:00';
					   By modified time=modifiedTime > '2012-06-04T12:00:00';
					   Allow only shared files and folders=sharedWithMe=true; 
					   Exclude trashed files or folders=trashed=false;
					   Exclude Folders=mimeType!='application/vnd.google-apps.folder';
					   Include files from trash=mimeType!='application/vnd.google-apps.folder';					   
					   Exclude files from trash=mimeType!='application/vnd.google-apps.folder' and trashed!=true;						   
					   Exclude App Script=mimeType!='application/vnd.google-apps.script';
					   Search for spreadsheet=mimeType = 'application/vnd.google-apps.spreadsheet';
					   Search for multiple files type=mimeType contains 'application/vnd.google-apps.spreadsheet' OR mimeType contains 'application/vnd.google-apps.document' OR mimeType contains 'application/vnd.google-apps.presentation' OR mimeType contains 'application/vnd.google-apps.drawing' "
					   Desc="Data filter (e.g. somecolumn -eq 'somevalue' ) , User can select multiple filter criteria using 'AND','OR' operator , Note*:- please refer the link for more filter criteria : https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files  "  
					   HelpLink="https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files" Hidden="False" 
					   />				
			</Params>
				

			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="createdTime" Label="CreatedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="modifiedTime" Label="ModifiedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="size" Label="Size" DataType="DT_WSTR" Length="200"/>
				<Column Name="version" Label="Version" DataType="DT_WSTR" Length="200"/>
				<Column Name="shared" Label="Shared" DataType="DT_BOOL"/>
				<Column Name="starred" Label="Starred" DataType="DT_BOOL"/>
				<Column Name="trashed" Label="Trashed" DataType="DT_BOOL"/>
				<Column Name="fileExtension" Label="FileExtension" DataType="DT_WSTR" Length="200"/>
				
				<Column Name="driveId" DataType="DT_WSTR" Label="DriveId" Length="500" />
				
				<Column Name="copyRequiresWriterPermission" DataType="DT_BOOL" Label="CopyRequiresWriterPermission" />
				<Column Name="md5Checksum" DataType="DT_WSTR" Label="Md5Checksum" Length="500" />
				<Column Name="writersCanShare" DataType="DT_BOOL" Label="WritersCanShare" />
				<Column Name="viewedByMe" DataType="DT_BOOL" Label="ViewedByMe" />
				<Column Name="parents" DataType="DT_WSTR" Label="Parents" Length="500" />
				<Column Name="thumbnailLink" DataType="DT_WSTR" Label="ThumbnailLink" Length="4000" />
				<Column Name="iconLink" DataType="DT_WSTR" Label="IconLink" Length="1000" />

				<Column Name="lastModifyingUser.displayName" DataType="DT_WSTR" Label="LastModifyingUserDisplayName" Length="500" />
				<Column Name="lastModifyingUser.kind" DataType="DT_WSTR" Label="LastModifyingUserKind" Length="100" />
				<Column Name="lastModifyingUser.me" DataType="DT_BOOL" Label="LastModifyingUserMe" />
				<Column Name="lastModifyingUser.permissionId" DataType="DT_WSTR" Label="LastModifyingUserPermissionId" Length="500" />
				<Column Name="lastModifyingUser.emailAddress" DataType="DT_WSTR" Label="LastModifyingUserEmailAddress" Length="500" />
				<Column Name="lastModifyingUser.photoLink" DataType="DT_WSTR" Label="LastModifyingUserPhotoLink" Length="1000" />
				<Column Name="owners" DataType="DT_WSTR" Label="Owners" Length="4000" />
				<Column Name="headRevisionId" DataType="DT_WSTR" Label="HeadRevisionId" Length="1000" />
				<Column Name="webViewLink" DataType="DT_WSTR" Label="WebViewLink" Length="1000" />
				<Column Name="webContentLink" DataType="DT_WSTR" Label="WebContentLink" Length="1000" />

				<Column Name="viewersCanCopyContent" DataType="DT_BOOL" Label="ViewersCanCopyContent" />
				<Column Name="permissions" DataType="DT_WSTR" Label="Permissions" Length="4000" />
				<Column Name="hasThumbnail" DataType="DT_BOOL" Label="HasThumbnail" />
				<Column Name="spaces" DataType="DT_WSTR" Label="Spaces" Length="500" />

				<Column Name="explicitlyTrashed" DataType="DT_BOOL" Label="ExplicitlyTrashed" />

				<Column Name="modifiedByMeTime" DataType="DT_DBTIMESTAMP" Label="ModifiedByMeTime" />
				<Column Name="viewedByMeTime" DataType="DT_DBTIMESTAMP" Label="ViewedByMeTime" />
				<Column Name="quotaBytesUsed" DataType="DT_WSTR" Label="QuotaBytesUsed" Length="50" />

				<Column Name="originalFilename" DataType="DT_WSTR" Label="OriginalFilename" Length="500" />
				<Column Name="ownedByMe" DataType="DT_BOOL" Label="OwnedByMe" />
				<Column Name="fullFileExtension" DataType="DT_WSTR" Label="FullFileExtension" Length="50" />
				<Column Name="isAppAuthorized" DataType="DT_BOOL" Label="IsAppAuthorized" />
				<Column Name="capabilities.canChangeViewersCanCopyContent" DataType="DT_BOOL" Label="CanChangeViewersCanCopyContent" />
				<Column Name="capabilities.canEdit" DataType="DT_BOOL" Label="CanEdit" />
				<Column Name="capabilities.canCopy" DataType="DT_BOOL" Label="CanCopy" />
				<Column Name="capabilities.canComment" DataType="DT_BOOL" Label="CanComment" />
				<Column Name="capabilities.canAddChildren" DataType="DT_BOOL" Label="CanAddChildren" />
				<Column Name="capabilities.canDelete" DataType="DT_BOOL" Label="CanDelete" />
				<Column Name="capabilities.canDownload" DataType="DT_BOOL" Label="CanDownload" />
				<Column Name="capabilities.canListChildren" DataType="DT_BOOL" Label="CanListChildren" />
				<Column Name="capabilities.canRemoveChildren" DataType="DT_BOOL" Label="CanRemoveChildren" />
				<Column Name="capabilities.canRename" DataType="DT_BOOL" Label="CanRename" />
				<Column Name="capabilities.canTrash" DataType="DT_BOOL" Label="CanTrash" />
				<Column Name="capabilities.canReadRevisions" DataType="DT_BOOL" Label="CanReadRevisions" />
				<Column Name="capabilities.canChangeCopyRequiresWriterPermission" DataType="DT_BOOL" Label="CanChangeCopyRequiresWriterPermission" />
				<Column Name="capabilities.canMoveItemIntoTeamDrive" DataType="DT_BOOL" Label="CanMoveItemIntoTeamDrive" />
				<Column Name="capabilities.canUntrash" DataType="DT_BOOL" Label="CanUntrash" />
				<Column Name="capabilities.canModifyContent" DataType="DT_BOOL" Label="CanModifyContent" />
				<Column Name="capabilities.canMoveItemOutOfDrive" DataType="DT_BOOL" Label="CanMoveItemOutOfDrive" />
				<Column Name="capabilities.canAddMyDriveParent" DataType="DT_BOOL" Label="CanAddMyDriveParent" />
				<Column Name="capabilities.canRemoveMyDriveParent" DataType="DT_BOOL" Label="CanRemoveMyDriveParent" />
				<Column Name="capabilities.canMoveItemWithinDrive" DataType="DT_BOOL" Label="CanMoveItemWithinDrive" />
				<Column Name="capabilities.canShare" DataType="DT_BOOL" Label="CanShare" />
				<Column Name="capabilities.canMoveChildrenWithinDrive" DataType="DT_BOOL" Label="CanMoveChildrenWithinDrive" />
				<Column Name="capabilities.canModifyContentRestriction" DataType="DT_BOOL" Label="CanModifyContentRestriction" />
				<Column Name="capabilities.canChangeSecurityUpdateEnabled" DataType="DT_BOOL" Label="CanChangeSecurityUpdateEnabled" />
				<Column Name="capabilities.canAcceptOwnership" DataType="DT_BOOL" Label="CanAcceptOwnership" />
				<Column Name="capabilities.canReadLabels" DataType="DT_BOOL" Label="CanReadLabels" />
				<Column Name="capabilities.canModifyLabels" DataType="DT_BOOL" Label="CanModifyLabels" />
				<Column Name="capabilities.canModifyEditorContentRestriction" DataType="DT_BOOL" Label="CanModifyEditorContentRestriction" />
				<Column Name="capabilities.canModifyOwnerContentRestriction" DataType="DT_BOOL" Label="CanModifyOwnerContentRestriction" />
				<Column Name="capabilities.canRemoveContentRestriction" DataType="DT_BOOL" Label="CanRemoveContentRestriction" />
				<Column Name="capabilities.canMoveChildrenOutOfDrive" DataType="DT_BOOL" Label="CanMoveChildrenOutOfDrive" />
				<Column Name="capabilities.canReadDrive" DataType="DT_BOOL" Label="CanReadDrive" />
				<Column Name="capabilities.canReadTeamDrive" DataType="DT_BOOL" Label="CanReadTeamDrive" />
				<Column Name="capabilities.canMoveTeamDriveItem" DataType="DT_BOOL" Label="CanMoveTeamDriveItem" />
				<Column Name="capabilities.canMoveItemWithinTeamDrive" DataType="DT_BOOL" Label="CanMoveItemWithinTeamDrive" />
				<Column Name="capabilities.canMoveItemOutOfTeamDrive" DataType="DT_BOOL" Label="CanMoveItemOutOfTeamDrive" />
				<Column Name="capabilities.canDeleteChildren" DataType="DT_BOOL" Label="CanDeleteChildren" />
				<Column Name="capabilities.canMoveChildrenOutOfTeamDrive" DataType="DT_BOOL" Label="CanMoveChildrenOutOfTeamDrive" />
				<Column Name="capabilities.canMoveChildrenWithinTeamDrive" DataType="DT_BOOL" Label="CanMoveChildrenWithinTeamDrive" />
				<Column Name="capabilities.canTrashChildren" DataType="DT_BOOL" Label="CanTrashChildren" />
				<Column Name="capabilities.canAddFolderFromAnotherDrive" DataType="DT_BOOL" Label="CanAddFolderFromAnotherDrive" />

				
				<Column Name="thumbnailVersion" DataType="DT_WSTR" Label="ThumbnailVersion" Length="50" />
				<Column Name="modifiedByMe" DataType="DT_BOOL" Label="ModifiedByMe" />
				<Column Name="permissionIds" DataType="DT_WSTR" Label="PermissionIds" Length="500" />
				<Column Name="imageMediaMetadata.width" DataType="DT_I4" Label="ImageMediaMetadataWidth" />
				<Column Name="imageMediaMetadata.height" DataType="DT_I4" Label="ImageMediaMetadataHeight" />
				<Column Name="imageMediaMetadata.rotation" DataType="DT_I4" Label="ImageMediaMetadataRotation" />
				<Column Name="linkShareMetadata.securityUpdateEligible" DataType="DT_BOOL" Label="LinkShareMetadataSecurityUpdateEligible" />
				<Column Name="linkShareMetadata.securityUpdateEnabled" DataType="DT_BOOL" Label="LinkShareMetadataSecurityUpdateEnabled" />
				<Column Name="sha1Checksum" DataType="DT_WSTR" Label="Sha1Checksum" Length="500" />
				<Column Name="sha256Checksum" DataType="DT_WSTR" Label="Sha256Checksum" Length="1000" />
				<Column Name="hasAugmentedPermissions" DataType="DT_BOOL" Label="HasAugmentedPermissions" />
			</OutputColumns>			

		</EndPoint>

		<EndPoint Name="DeleteItemTemplate"  Template="DriveSupportTemplate" Label="Delete an item" Desc="Deletes an item"
					Url="/drive/v3/files/[$Id$]" Method="DELETE" DotAsPath="True" HelpLink="https://developers.google.com/drive/api/v3/reference/files/delete">
			<Params>				
				<Param Name="Id"
				       Label=" File Id"
					   OptionsEndPoint="list_items"
					   OptionsEndPointValueColumn="Id"
					   IsKey="True"
					   Required="True"
					   OptionsEndPointLabelColumn="Name"
					   OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true"
					   Desc="Id of an item you want to delete"
				/>
				<Param Name="RawOutputDataRowTemplate" Type="Property" Value="{Status:'Deleted'}" />
				<Param Name="EnableRawOutputModeSingleRow" Type="Property" Value="True" />
			</Params>
			<OutputColumns>
				<Column Name="Status" DataType="DT_WSTR" />
			</OutputColumns>
			<InputColumns>
				<Column Name="Id" DataType="DT_WSTR" MapToParam="True" Key="True" />
			</InputColumns>			
		</EndPoint>
	</Template>

	<EndPoints>
		<!--=====================================
        ========= GET ABOUT INFO ============
        =====================================-->
		<EndPoint Name="get_about" Label="Get my drive info" Desc="Gets my drive information"
					Url="/drive/v3/about?fields=*" Method="GET" HelpLink="https://developers.google.com/drive/api/v3/reference/about/get"
              >
			<OutputColumns>
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="210" />
				<Column Name="user.kind" Label="UserKind" DataType="DT_WSTR" Length="200" />
				<Column Name="user.displayName" Label="UserDisplayName" DataType="DT_WSTR" Length="180" />
				<Column Name="user.me" Label="UserMe" DataType="DT_WSTR" Length="40" />
				<Column Name="user.permissionId" Label="UserPermissionId" DataType="DT_WSTR" />
				<Column Name="user.emailAddress" Label="UserEmailAddress" DataType="DT_WSTR" Length="290" />
				<Column Name="storageQuota.limit" Label="StorageQuotaLimit" DataType="DT_I8" />
				<Column Name="storageQuota.usage" Label="StorageQuotaUsage" DataType="DT_I8" />
				<Column Name="storageQuota.usageInDrive" Label="StorageQuotaUsageInDrive" DataType="DT_I8" />
				<Column Name="storageQuota.usageInDriveTrash" Label="StorageQuotaUsageInDriveTrash" DataType="DT_I4" />
				<Column Name="maxUploadSize" Label="MaxUploadSize" DataType="DT_I8" />
				<Column Name="appInstalled" Label="AppInstalled" DataType="DT_WSTR" Length="40" />
				<Column Name="folderColorPalette" Label="FolderColorPalette" DataType="DT_WSTR" Length="3390" />
				<Column Name="teamDriveThemes" Label="TeamDriveThemes" DataType="DT_NTEXT" />
				<Column Name="driveThemes" Label="DriveThemes" DataType="DT_NTEXT" />
				<Column Name="canCreateTeamDrives" Label="CanCreateTeamDrives" DataType="DT_WSTR" Length="150" />
				<Column Name="canCreateDrives" Label="CanCreateDrives" DataType="DT_WSTR" Length="150" />
			</OutputColumns>
		</EndPoint>

		<!--=======================================
        ============ LIST DRIVES ===============
        =======================================-->
		<EndPoint Name="list_shared_drives" Template="ListSharedDrivesTemplate" Label="Lists shared drives" Desc="Lists the user's shared drives (i.e. formally known as team drive) with optional search criteria"
					Url="/drive/v3/drives?fields=nextPageToken,drives(*)" Method="GET" Filter="$.drives[*]" HelpLink="https://developers.google.com/drive/api/v3/reference/drives/list">
		</EndPoint>


		<!--=====================================
        ============ LIST ITEMS =============
        =====================================-->
		
		<EndPoint Name="list_files" Template="ListItemsTemplate" Label="List files" Desc="List files / folders with search criteria"
					Url="/drive/v3/files?fields=nextPageToken,files(*)" >
			<Params>
				<Param Name="Query" Key="q" Label=" Search Criteria" Type="Query" Hidden="False" Value="mimeType!='application/vnd.google-apps.folder' AND trashed!=true" 
					   Options="None=;
					   By name (exact name match)=name='abc';
					   By name (contains sub string)=name contains 'abc';
					   By name (does not contain)=not name contains 'abc';
					   By text (search inside file)=fullText contains 'abc';
					   By Parent Folder Id='your-folder-id' in parents;
					   By created time=createdTime > '2012-06-04T12:00:00';
					   By modified time=modifiedTime > '2012-06-04T12:00:00';
					   Allow only shared files and folders=sharedWithMe=true; 
					   Exclude trashed files=trashed=false;
					   Include files from trash=mimeType!='application/vnd.google-apps.folder';					   
					   Exclude files from trash=mimeType!='application/vnd.google-apps.folder' and trashed!=true;					   
					   Exclude Folders=mimeType!='application/vnd.google-apps.folder';
					   Exclude App Script=mimeType!='application/vnd.google-apps.script';
					   Search for spreadsheet=mimeType = 'application/vnd.google-apps.spreadsheet';
					   Search for multiple files type=mimeType contains 'application/vnd.google-apps.spreadsheet' OR mimeType contains 'application/vnd.google-apps.document' OR mimeType contains 'application/vnd.google-apps.presentation' OR mimeType contains 'application/vnd.google-apps.drawing' "
					   Desc="Data filter (e.g. somecolumn -eq 'somevalue' ) , User can select multiple filter criteria using 'AND','OR' operator , Note*:- please refer the link for more filter criteria : https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files  "  
					   HelpLink="https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files"   
					   />					
			</Params>
		</EndPoint>

		<!--=====================================
        ============ LIST ITEMS =============
        =====================================-->
		<EndPoint Name="list_items" Template="ListItemsTemplate" Label="Search items (i.e. files / folders)" Desc="Lists items (i.e. files / folders) with search criteria"
					Url="/drive/v3/files?fields=nextPageToken,files(*)" >
		</EndPoint>
		
		<!--=======================================
        ============ LIST FOLDERS =============
        =======================================-->
		<EndPoint Name="list_folders" Template="ListItemsTemplate" Label="List folders" Desc="Lists folders" >
			<Params>
				<Param Name="Query" Key="q" Label=" Search Criteria" Type="Query" Hidden="False" Value="mimeType='application/vnd.google-apps.folder' and trashed!=true" 
					   Options="None=;
					   By name (exact name match)=name='abc';
					   By name (contains sub string)=name contains 'abc';
					   By name (does not contain)=not name contains 'abc';
					   By text (search inside file)=fullText contains 'abc';
					   By created time=createdTime > '2012-06-04T12:00:00';
					   Include folders from trash=mimeType='application/vnd.google-apps.folder';
					   Exclude folders from trash=mimeType='application/vnd.google-apps.folder' and trashed!=true;
					   By modified time=modifiedTime > '2012-06-04T12:00:00';
					   Allow only shared files and folders=sharedWithMe=true; 
					   Exclude trashed files=trashed=false;
					   Exclude Folders=mimeType!='application/vnd.google-apps.folder';
					   Exclude App Script=mimeType!='application/vnd.google-apps.script';
					   Search for spreadsheet=mimeType = 'application/vnd.google-apps.spreadsheet';
					   Search for multiple files type=mimeType contains 'application/vnd.google-apps.spreadsheet' OR mimeType contains 'application/vnd.google-apps.document' OR mimeType contains 'application/vnd.google-apps.presentation' OR mimeType contains 'application/vnd.google-apps.drawing' "
					   Desc="Data filter (e.g. somecolumn -eq 'somevalue' ) , User can select multiple filter criteria using 'AND','OR' operator , Note*:- please refer the link for more filter criteria : https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files  "  
					   HelpLink="https://zappysys.com/links?url=https://developers.google.com/drive/api/guides/search-files"   
					   />				
			</Params>
		</EndPoint>

		<!--=======================================
        ======== LIST DELETED FILES ===========
        =======================================-->
		<EndPoint Name="list_deleted_files" Template="ListItemsTemplate" Label="List deleted files / folders" Desc="Lists only deleted files / folders from trash">
			<Params>
				<Param Name="Query" Key="q" Label="Search Criteria" Type="Query" Value="trashed=true" Hidden="False"/>
			</Params>
		</EndPoint>

		<!--=====================================
        ========== GET FILE INFO ============
        =====================================-->
		<EndPoint Name="get_file_info" Template="DriveSupportTemplate" Label="Get file info" Desc="Gets information of a file"
					Url="/drive/v3/files/[$Id$]?fields=*" Method="GET" DotAsPath="True" HelpLink="https://developers.google.com/drive/api/v3/reference/files/get"
              >
			<Params>
				
				<Param Name="Id"
					   Type="Placeholder"
					   OptionsEndPoint="list_items"
					   OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true;"
					   OptionsEndPointValueColumn="Id"
					   OptionsEndPointLabelColumn="Name"
					   Desc="Id of a file you want to see information for"
					   Required="True"
					   IsKey="True"
                />
			
			</Params>
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="createdTime" Label="CreatedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="modifiedTime" Label="ModifiedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="size" Label="Size" DataType="DT_WSTR" Length="200"/>
				<Column Name="version" Label="Version" DataType="DT_WSTR" Length="200"/>
				<Column Name="shared" Label="Shared" DataType="DT_BOOL"/>
				<Column Name="starred" Label="Starred" DataType="DT_BOOL"/>
				<Column Name="trashed" Label="Trashed" DataType="DT_BOOL"/>
				<Column Name="fileExtension" Label="FileExtension" DataType="DT_WSTR" Length="200"/>
				
				<Column Name="driveId" DataType="DT_WSTR" Label="DriveId" Length="500" />
				
				<Column Name="copyRequiresWriterPermission" DataType="DT_BOOL" Label="CopyRequiresWriterPermission" />
				<Column Name="md5Checksum" DataType="DT_WSTR" Label="Md5Checksum" Length="500" />
				<Column Name="writersCanShare" DataType="DT_BOOL" Label="WritersCanShare" />
				<Column Name="viewedByMe" DataType="DT_BOOL" Label="ViewedByMe" />
				<Column Name="parents" DataType="DT_WSTR" Label="Parents" Length="500" />
				<Column Name="thumbnailLink" DataType="DT_WSTR" Label="ThumbnailLink" Length="4000" />
				<Column Name="iconLink" DataType="DT_WSTR" Label="IconLink" Length="1000" />

				<Column Name="lastModifyingUser.displayName" DataType="DT_WSTR" Label="LastModifyingUserDisplayName" Length="500" />
				<Column Name="lastModifyingUser.kind" DataType="DT_WSTR" Label="LastModifyingUserKind" Length="100" />
				<Column Name="lastModifyingUser.me" DataType="DT_BOOL" Label="LastModifyingUserMe" />
				<Column Name="lastModifyingUser.permissionId" DataType="DT_WSTR" Label="LastModifyingUserPermissionId" Length="500" />
				<Column Name="lastModifyingUser.emailAddress" DataType="DT_WSTR" Label="LastModifyingUserEmailAddress" Length="500" />
				<Column Name="lastModifyingUser.photoLink" DataType="DT_WSTR" Label="LastModifyingUserPhotoLink" Length="1000" />
				<Column Name="owners" DataType="DT_WSTR" Label="Owners" Length="4000" />
				<Column Name="headRevisionId" DataType="DT_WSTR" Label="HeadRevisionId" Length="1000" />
				<Column Name="webViewLink" DataType="DT_WSTR" Label="WebViewLink" Length="1000" />
				<Column Name="webContentLink" DataType="DT_WSTR" Label="WebContentLink" Length="1000" />

				<Column Name="viewersCanCopyContent" DataType="DT_BOOL" Label="ViewersCanCopyContent" />
				<Column Name="permissions" DataType="DT_WSTR" Label="Permissions" Length="4000" />
				<Column Name="hasThumbnail" DataType="DT_BOOL" Label="HasThumbnail" />
				<Column Name="spaces" DataType="DT_WSTR" Label="Spaces" Length="500" />

				<Column Name="explicitlyTrashed" DataType="DT_BOOL" Label="ExplicitlyTrashed" />

				<Column Name="modifiedByMeTime" DataType="DT_DBTIMESTAMP" Label="ModifiedByMeTime" />
				<Column Name="viewedByMeTime" DataType="DT_DBTIMESTAMP" Label="ViewedByMeTime" />
				<Column Name="quotaBytesUsed" DataType="DT_WSTR" Label="QuotaBytesUsed" Length="50" />

				<Column Name="originalFilename" DataType="DT_WSTR" Label="OriginalFilename" Length="500" />
				<Column Name="ownedByMe" DataType="DT_BOOL" Label="OwnedByMe" />
				<Column Name="fullFileExtension" DataType="DT_WSTR" Label="FullFileExtension" Length="50" />
				<Column Name="isAppAuthorized" DataType="DT_BOOL" Label="IsAppAuthorized" />
				<Column Name="capabilities.canChangeViewersCanCopyContent" DataType="DT_BOOL" Label="CanChangeViewersCanCopyContent" />
				<Column Name="capabilities.canEdit" DataType="DT_BOOL" Label="CanEdit" />
				<Column Name="capabilities.canCopy" DataType="DT_BOOL" Label="CanCopy" />
				<Column Name="capabilities.canComment" DataType="DT_BOOL" Label="CanComment" />
				<Column Name="capabilities.canAddChildren" DataType="DT_BOOL" Label="CanAddChildren" />
				<Column Name="capabilities.canDelete" DataType="DT_BOOL" Label="CanDelete" />
				<Column Name="capabilities.canDownload" DataType="DT_BOOL" Label="CanDownload" />
				<Column Name="capabilities.canListChildren" DataType="DT_BOOL" Label="CanListChildren" />
				<Column Name="capabilities.canRemoveChildren" DataType="DT_BOOL" Label="CanRemoveChildren" />
				<Column Name="capabilities.canRename" DataType="DT_BOOL" Label="CanRename" />
				<Column Name="capabilities.canTrash" DataType="DT_BOOL" Label="CanTrash" />
				<Column Name="capabilities.canReadRevisions" DataType="DT_BOOL" Label="CanReadRevisions" />
				<Column Name="capabilities.canChangeCopyRequiresWriterPermission" DataType="DT_BOOL" Label="CanChangeCopyRequiresWriterPermission" />
				<Column Name="capabilities.canMoveItemIntoTeamDrive" DataType="DT_BOOL" Label="CanMoveItemIntoTeamDrive" />
				<Column Name="capabilities.canUntrash" DataType="DT_BOOL" Label="CanUntrash" />
				<Column Name="capabilities.canModifyContent" DataType="DT_BOOL" Label="CanModifyContent" />
				<Column Name="capabilities.canMoveItemOutOfDrive" DataType="DT_BOOL" Label="CanMoveItemOutOfDrive" />
				<Column Name="capabilities.canAddMyDriveParent" DataType="DT_BOOL" Label="CanAddMyDriveParent" />
				<Column Name="capabilities.canRemoveMyDriveParent" DataType="DT_BOOL" Label="CanRemoveMyDriveParent" />
				<Column Name="capabilities.canMoveItemWithinDrive" DataType="DT_BOOL" Label="CanMoveItemWithinDrive" />
				<Column Name="capabilities.canShare" DataType="DT_BOOL" Label="CanShare" />
				<Column Name="capabilities.canMoveChildrenWithinDrive" DataType="DT_BOOL" Label="CanMoveChildrenWithinDrive" />
				<Column Name="capabilities.canModifyContentRestriction" DataType="DT_BOOL" Label="CanModifyContentRestriction" />
				<Column Name="capabilities.canChangeSecurityUpdateEnabled" DataType="DT_BOOL" Label="CanChangeSecurityUpdateEnabled" />
				<Column Name="capabilities.canAcceptOwnership" DataType="DT_BOOL" Label="CanAcceptOwnership" />
				<Column Name="capabilities.canReadLabels" DataType="DT_BOOL" Label="CanReadLabels" />
				<Column Name="capabilities.canModifyLabels" DataType="DT_BOOL" Label="CanModifyLabels" />
				<Column Name="capabilities.canModifyEditorContentRestriction" DataType="DT_BOOL" Label="CanModifyEditorContentRestriction" />
				<Column Name="capabilities.canModifyOwnerContentRestriction" DataType="DT_BOOL" Label="CanModifyOwnerContentRestriction" />
				<Column Name="capabilities.canRemoveContentRestriction" DataType="DT_BOOL" Label="CanRemoveContentRestriction" />
				<Column Name="capabilities.canMoveChildrenOutOfDrive" DataType="DT_BOOL" Label="CanMoveChildrenOutOfDrive" />
				<Column Name="capabilities.canReadDrive" DataType="DT_BOOL" Label="CanReadDrive" />
				<Column Name="capabilities.canReadTeamDrive" DataType="DT_BOOL" Label="CanReadTeamDrive" />
				<Column Name="capabilities.canMoveTeamDriveItem" DataType="DT_BOOL" Label="CanMoveTeamDriveItem" />
				<Column Name="capabilities.canMoveItemWithinTeamDrive" DataType="DT_BOOL" Label="CanMoveItemWithinTeamDrive" />
				<Column Name="capabilities.canMoveItemOutOfTeamDrive" DataType="DT_BOOL" Label="CanMoveItemOutOfTeamDrive" />
				<Column Name="capabilities.canDeleteChildren" DataType="DT_BOOL" Label="CanDeleteChildren" />
				<Column Name="capabilities.canMoveChildrenOutOfTeamDrive" DataType="DT_BOOL" Label="CanMoveChildrenOutOfTeamDrive" />
				<Column Name="capabilities.canMoveChildrenWithinTeamDrive" DataType="DT_BOOL" Label="CanMoveChildrenWithinTeamDrive" />
				<Column Name="capabilities.canTrashChildren" DataType="DT_BOOL" Label="CanTrashChildren" />
				<Column Name="capabilities.canAddFolderFromAnotherDrive" DataType="DT_BOOL" Label="CanAddFolderFromAnotherDrive" />

				
				<Column Name="thumbnailVersion" DataType="DT_WSTR" Label="ThumbnailVersion" Length="50" />
				<Column Name="modifiedByMe" DataType="DT_BOOL" Label="ModifiedByMe" />
				<Column Name="permissionIds" DataType="DT_WSTR" Label="PermissionIds" Length="500" />
				<Column Name="imageMediaMetadata.width" DataType="DT_I4" Label="ImageMediaMetadataWidth" />
				<Column Name="imageMediaMetadata.height" DataType="DT_I4" Label="ImageMediaMetadataHeight" />
				<Column Name="imageMediaMetadata.rotation" DataType="DT_I4" Label="ImageMediaMetadataRotation" />
				<Column Name="linkShareMetadata.securityUpdateEligible" DataType="DT_BOOL" Label="LinkShareMetadataSecurityUpdateEligible" />
				<Column Name="linkShareMetadata.securityUpdateEnabled" DataType="DT_BOOL" Label="LinkShareMetadataSecurityUpdateEnabled" />
				<Column Name="sha1Checksum" DataType="DT_WSTR" Label="Sha1Checksum" Length="500" />
				<Column Name="sha256Checksum" DataType="DT_WSTR" Label="Sha256Checksum" Length="1000" />
				<Column Name="hasAugmentedPermissions" DataType="DT_BOOL" Label="HasAugmentedPermissions" />
			</OutputColumns>			
		</EndPoint>


		<!--=====================================
        ========= DOWNLOAD A FILE ===========
        =====================================-->
		<EndPoint Name="download_file" Template="DriveSupportTemplate" Label="Download a file" Desc="Downloads a file"
					Url="/drive/v3/files/[$Id$]?alt=media" Method="GET"
				  OutputHeaders="Content-Length" HelpLink="https://developers.google.com/drive/api/v3/reference/files/get"
              >
			<Params>
				<Param Name="Id"
					  Label=" File Id"
					  Required="True"
					  Type="Placeholder"
					  OptionsEndPoint="list_items"
					  OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true;"
					  OptionsEndPointValueColumn="Id"
					  OptionsEndPointLabelColumn="Name"
					  Desc="Id of a file you want to download"
              />
				<Param Name="RequestTimeoutMs"
					   Type="Property"
					   Desc="Timeout in milliseconds after which download stops"
					   Value="7200000"
              />
				<Param Name="SaveContentAsBinary"
					  Type="Property"
					  Hidden="True"
					  Value="True"
                />
				
				<Param Name="FileOverwriteMode" Label=" Overwrite Mode" Type="Property" Value="AlwaysOverwrite" Required="True"/>
				<Param Name="ResponseDataFile" Label=" Local File Path" Required="True" Type="Property" Value="c:\somefolder\myfile.ext" Editor="FileSave" />
				
				<Param Name="RawOutputDataRowTemplate" Type="Property" Value="{Status:'Downloaded'}" />
				<Param Name="EnableRawOutputModeSingleRow" Type="Property" Value="True" />
			</Params>
			<OutputColumns>
				<Column Name="Status" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>
		<!--=====================================
        ========= EXPORT A FILE ===========
        =====================================-->
		<EndPoint Name="export_file" Label="Export a file" Template="DriveSupportTemplate" Desc="Export a document editor files such document, Spreadsheets, Drawings, Presentations, Apps Scripts to common file formats as defined in this link https://developers.google.com/drive/api/guides/ref-export-formats"
					Url="/drive/v3/files/[$Id$]/export?mimeType=[$ExportAs$]" Method="GET"
				  OutputHeaders="Content-Length" HelpLink="https://developers.google.com/drive/api/v3/reference/files/export"
              >
			<Params>
							
				<Param Name="Id"
					  Label=" File Id"
					  Required="True"
					  Type="Placeholder"
					  OptionsEndPoint="list_items"
					  
					  OptionsEndPointValueColumn="Id"
					  OptionsEndPointLabelColumn="Name"
					  OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true;Query=mimeType contains 'application/vnd.google-apps.spreadsheet' OR mimeType contains 'application/vnd.google-apps.document' OR mimeType contains 'application/vnd.google-apps.presentation' OR mimeType contains 'application/vnd.google-apps.drawing'"
					  Desc="Id of a file you want to export and file must be editor type (e.g. document, Spreadsheets, Drawings, Presentations, Apps Scripts)"
                />
				<Param Name="ExportAs"
					   Label=" Export As (Mime Type)"
					   Required="True"
					   Type="Placeholder"
					   Desc="The MIME type of the format requested for this export."
					   Options="None=;Export to PDF=application/pdf;
					   Export to HTML=text/html;
					   Export to HTML (zipped)=application/zip;
					   Export to Plain text=text/plain;
					   Export to Rich text=application/rtf;
					   Export to Open Office doc=application/vnd.oasis.opendocument.text;
					   Export to MS Word document=application/vnd.openxmlformats-officedocument.wordprocessingml.document;
					   Export to EPUB=application/epub+zip;
					   Export to MS Excel=application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;
					   Export to Open Office sheet=application/x-vnd.oasis.opendocument.spreadsheet;
					   Export to (sheet only)=text/tab-separated-values;
					   Export to JPEG=image/jpeg;
					   Export to PNG=image/png;
					   Export to SVG=image/svg+xml;
					   Export to MS PowerPoint=application/vnd.openxmlformats-officedocument.presentationml.presentation;
					   Export to Open Office presentation=application/vnd.oasis.opendocument.presentation;
					   Export to JSON=application/vnd.google-apps.script+json;"
					   HelpLink="https://developers.google.com/drive/api/guides/mime-types"
              />
				<Param Name="fields"
					   Type="Placeholder"
					   Desc="fields"
					   Value="True"
					   Hidden="True"
                />
				<Param Name="RequestTimeoutMs"
					   Type="Property"
					   Desc="Timeout in milliseconds after which download stops"
					   Value="7200000"
              />
				<Param Name="SaveContentAsBinary"
					  Type="Property"
					  Hidden="True"
					  Value="True"
                />
				
				<Param Name="FileOverwriteMode" Label=" Overwrite Mode" Type="Property" Value="AlwaysOverwrite" Required="True"/>
				<Param Name="ResponseDataFile"  Label=" Local File Path" Required="True" Type="Property" Value="c:\somefolder\myfile.ext" Editor="FileSave" />
				
				<Param Name="RawOutputDataRowTemplate" Type="Property" Value="{Status:'Downloaded'}" />
				<Param Name="EnableRawOutputModeSingleRow" Type="Property" Value="True" />
			</Params>
			<OutputColumns>
				<Column Name="Status" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>

		<!--=====================================
        ========== UPLOAD A FILE ============
        =====================================-->
		<EndPoint Name="upload_file" Label="Upload a file" TemplateXX="DriveSupportTemplate" Desc="Uploads a file"
				  Url="/upload/drive/v3/files?uploadType=resumable" Method="POST" 
				  OutputHeaders="Location"
				  ContentType="application/json"
			  HelpLink="https://developers.google.com/drive/api/reference/rest/v3/files/create"
              >
			<Params>
				<Param Name="KeepRevisionForever"
					   Key="keepRevisionForever"
					   Label=" Keep Revision Forever"
					   Required="False"
					   Type="Query"
					   Hidden="False"
					   Options=";true;false"
					   Desc="Defines whether uploaded file has revisions"
					   Value=""
              />
			  
			 <Param Name="ParentFolderId"
						Label=" Parent FolderId"
						Type="Placeholder"
						OptionsEndPoint="list_folders"
						OptionsEndPointValueColumn="Id"
						OptionsEndPointLabelColumn="Name"
						OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true"
						Desc="Id of a parent folder you want to upload the file in. Use value 'root' to place the file in the topmost level."
						Value="root"
                />
				
				<Param Name="DriveId" Label=" Shared DriveId" VisibleIf="DriveType==drive" Key="driveId" OptionsEndPoint="list_shared_drives"  Desc="By default file lists from MyDrive but if you like to search other Shared drive then set this parameter." 
					OptionsEndPointValueColumn="Id" OptionsEndPointLabelColumn="Name" />

				<Param Name="DriveType" Label=" Drive Type" Key="corpora" Value="user" Options=";My Drive=user;Shared Drive=drive;" 
					Desc="Default search context is User's drive. Bodies of items (files/documents) to which the query applies. Supported bodies are 'user', 'domain', 'drive', and 'allDrives'. Prefer 'user' or 'drive' to 'allDrives' for efficiency. By default, corpora is set to 'user'. However, this can change depending on the filter set through the 'Query' parameter."/>

				<Param Name="SupportsAllDrives" Key="supportsAllDrives" Value="true" Label=" Supports all drives (e.g. My and Shared)" Desc="Whether the requesting application supports both My Drives and shared drives." Type="Query" Options=";true;false" Hidden="True" />				
			
				<Param Name="FileName"
					   Label=" Target FileName"	
					   Required="True"
					   Type="Placeholder"
					   Desc="A filename the file will have in Google Drive"
					   Example="myfile.ext"
					   Value="myfile.ext"
              />
				<Param Name="DiskFilePath"
				        Label=" Local FilePath"
						Required="True"
						Type="Placeholder"
						Desc="Specify a disk file path"
						Example="C:\somefolder\file.ext"
						Editor="FileOpen"
						Value=""
              />
		
		       
				<Param Name="RawOutputDataRowTemplate" Type="Property" Value="{Status:'Uploaded'}" Target="upload_file" />
				<Param Name="EnableRawOutputModeSingleRow" Type="Property" Value="True" Target="upload_file" />

				<Param 
					   Name="AddParents"
					   Key="addParents"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A comma-separated list of parent IDs to add"
					   Value=""
              />
				<Param Name="ocrLanguage"
					   Label="OcrLanguage"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A language hint for OCR processing during image import (ISO 639-1 code)."
					   Value=""
              />
				<Param Name="useContentAsIndexableText"
					   Label="UseContentAsIndexableText"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="	Whether to use the uploaded content as indexable text."
					   Value="False"
              />
			</Params>
			<Body>
				<![CDATA[ { "kind": "drive#file"
                    ,"name": "[$FileName$]"
					,"temDriveId": "[$DriveId$]"
                    ,"parents": [ "[$ParentFolderId$]" ] } 
        ]]>
			</Body>

			<EndPoint Name="child_upload_file"
					  Url="[$parent.ResponseHeaders_Location$]" Method="PUT" Body="[$DiskFilePath$]">

				<Params>
					<Param Name="EnableSplitStreamForUpload" Type="Property" Value="True" Target="child_upload_file" Required="True" Hidden="True" Desc="Must be set to 'True'" />
					<Param Name="BytesPerSplit" Type="Property" Value="33554432" Hidden="True"  />
					<Param Name="ContineOnErrorForStatusCode" Type="Property" Value="True" Hidden="True"  />
					<Param Name="ConsumeResponseOnError" Type="Property" Value="True" Hidden="True"  />
					<Param Name="ErrorStatusCodeToMatch" Type="Property" Value="308" Hidden="True"  />

					<Param Name="RequestTimeoutMs"
						  Type="Property"
						  Desc="Timeout in milliseconds after which upload stops"
						  Value="7200000"
                    />
				</Params>
			</EndPoint>
		
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<!-- id must be duplicated and set this way -->
				<Column Name="id" Label="FileSize" DataType="DT_I8" ValueTemplate="[$DiskFilePath,FUN_FILE_SIZE$]"  />
				<Column Name="id" Label="DriveId" DataType="DT_WSTR" ValueTemplate="[$DriveId$]"  />
			</OutputColumns>
		</EndPoint>


		<!--=====================================
        ========== CREATE FOLDER ============
        =====================================-->
		<EndPoint Name="create_folder" Template="DriveSupportTemplate" Label="Create a folder" Desc="Creates a folder"
					Url="/drive/v3/files?alt=json" Method="POST"
				  ContentType="application/json"
			  HelpLink="https://developers.google.com/drive/api/guides/folder"
              >
			<Params>
				<Param Name="Name"
					   Label=" Name"
					   Required="True"
					   Type="Placeholder"
					   Desc="A folder name the folder will have in Google Drive"
					   Example="MyFolder"
					   Value="MyFolder"
                 />
				<Param Name="ParentFolderId"
					   Label=" Parent FolderId"
					   Type="Placeholder"
					   OptionsEndPoint="list_folders"
					   OptionsEndPointValueColumn="Id"
					   OptionsEndPointLabelColumn="Name"
					   OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true"
					   Value="root"
					   Desc="Id of a parent folder you want to create the folder in. Use value 'root' to create the folder in the topmost level."
                 />
			    
			</Params>
			<Body>
				<![CDATA[ { "kind": "drive#file"
                    ,"name": "[$Name$]"
					,"mimeType" : "application/vnd.google-apps.folder"
                    ,"parents": [ "[$ParentFolderId$]" ] } 
        ]]>
			</Body>

			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="id" Label="DriveId" DataType="DT_WSTR" ValueTemplate="[$DriveId$]"  />
			</OutputColumns>
		</EndPoint>


		<!--=====================================
        ========= DELETE AN ITEM ============
        =====================================-->
		<EndPoint Name="delete_item" Template="DeleteItemTemplate" Label="Delete an item" Desc="Deletes an item"
					Url="/drive/v3/files/[$Id$]" Method="DELETE" DotAsPath="True" HelpLink="https://developers.google.com/drive/api/v3/reference/files/delete"
              >
		</EndPoint>

		<!--=====================================
        =========== COPY AN ITEM ============
        =====================================-->
		<EndPoint Name="copy_file" Template="DriveSupportTemplate" Label="Duplicate a file" Desc="Duplicates a file"
					Url="/drive/v3/files/[$Id$]/copy?fields=*" Method="POST" DotAsPath="True" HelpLink="https://developers.google.com/drive/api/v3/reference/files/copy"
              >
			<Params>
				<Param Name="Id"
				       Label=" File Id"
					   Type="Placeholder"
					   OptionsEndPoint="list_items"
					   OptionsEndPointValueColumn="Id"
					   OptionsEndPointLabelColumn="Name"
					   OptionsEndPointParameters="DriveId=[$DriveId$];DriveType=[$DriveType$];SupportsAllDrives=true"
					   Desc="Id of a file you want to duplicate"
            />
			</Params>
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="createdTime" Label="CreatedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="modifiedTime" Label="ModifiedTime" DataType="DT_DBTIMESTAMP"/>
				<Column Name="size" Label="Size" DataType="DT_WSTR" Length="100"/>
				<Column Name="version" Label="Version" DataType="DT_WSTR" Length="200"/>
				<Column Name="shared" Label="Shared" DataType="DT_BOOL"/>
				<Column Name="starred" Label="Starred" DataType="DT_BOOL"/>
				<Column Name="trashed" Label="Trashed" DataType="DT_BOOL"/>
				<Column Name="fileExtension" Label="FileExtension" DataType="DT_WSTR" Length="200"/>
				<Column Name="driveId" Label="DriveId" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>

		<!--=====================================
        ========= UPDATE A FILE =============
        =====================================-->
		<EndPoint Name="update_file" Label="Replace file data (keep same file id)" Template="DriveSupportTemplate" Desc="Update file with new content / metadata (keep same file Id)"
					Url="/upload/drive/v3/files/[$Id$]?uploadType=resumable" Method="PATCH" DotAsPath="True"
				  OutputHeaders="Location"
				  ContentType="application/json"
				  HelpLink="https://developers.google.com/drive/api/v3/reference/files/update"
              >
			<Params>
				<Param Name="Id"
					   Label=" File Id" 	
					   Type="Placeholder"
					   Required="True"
					   OptionsEndPoint="list_files"
					   OptionsEndPointValueColumn="Id"
					   OptionsEndPointLabelColumn="Name"
					   Desc="Id of a file you want to update"
              />
				<Param Name="DiskFilePath"
					   Required="True"
					   Type="Placeholder"
					   Desc="A disk file path you want to update file contents with"
					   Example="C:\MyParentFolder\Subfolder\file.txt"
					   Editor="FileOpen"
					   Value=""
              />
				<Param Name="RawOutputDataRowTemplate" Type="Property" Value="{Status:'Updated'}" Target="update_file" />
				<Param Name="EnableRawOutputModeSingleRow" Type="Property" Value="True" Target="update_file" />
				<Param Name="keepRevisionForever"
					   Label="KeepRevisionForever"
					   Required="False"
					   Type="Query"
					   Hidden="False"
					   Desc="Defines whether uploaded file has revisions"
					   Value=""
              />
				<Param Name="addParents"
					   Label="AddParents"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A comma-separated list of parent IDs to add"
					   Value=""
              />
				<Param Name="ocrLanguage"
					   Label="OcrLanguage"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A language hint for OCR processing during image import (ISO 639-1 code)."
					   Value=""
              />
				<Param Name="useContentAsIndexableText"
					   Label="UseContentAsIndexableText"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="	Whether to use the uploaded content as indexable text."
					   Value="False"
              />
			</Params>
			<Body>
				<![CDATA[ { "kind": "drive#file" } ]]>
			</Body>
			<EndPoint Name="child_upload_file"
					  Url="[$parent.ResponseHeaders_Location$]" Method="PUT" Body="[$DiskFilePath$]">

				<Params>
					<Param Name="EnableSplitStreamForUpload" Type="Property" Value="True" Target="child_upload_file" Required="True" Hidden="True" Desc="Must be set to 'True'" />
					<Param Name="BytesPerSplit" Type="Property" Value="33554432" Hidden="True"  />
					<Param Name="ContineOnErrorForStatusCode" Type="Property" Value="True" Hidden="True"  />
					<Param Name="ConsumeResponseOnError" Type="Property" Value="True" Hidden="True"  />
					<Param Name="ErrorStatusCodeToMatch" Type="Property" Value="308" Hidden="True"  />

					<Param Name="RequestTimeoutMs"
						  Type="Property"
						  Desc="Timeout in milliseconds after which upload stops"
						  Value="7200000"
                    />
				</Params>
			</EndPoint>
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<!-- id must be duplicated and set this way -->
				<Column Name="id" Label="FileSize" DataType="DT_I8" ValueTemplate="[$DiskFilePath,FUN_FILE_SIZE$]"  />
				<Column Name="driveId" Label="DriveId" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>

		<!--==============================================
       ========= UPDATE METADATA IN A FILE ==========
       ============================================== -->
		<EndPoint Name="update_metadata_file" Label="Update metadata in a file"  Template="DriveSupportTemplate"  Desc="Updates meta-data in a file"
					Url="/drive/v3/files/[$Id$]" Method="PATCH" DotAsPath="True"
				  ContentType="application/json" JsonRowFormat="Multicontent" HelpLink="https://developers.google.com/drive/api/v3/reference/files/update"
              >
			<Params>
				<Param Name="Id"
				       Label=" File Id"
					   Type="Placeholder"
					   Required="True"
					   OptionsEndPoint="list_files"
					   OptionsEndPointValueColumn="Id"
					   OptionsEndPointLabelColumn="Name"
					   Desc="Id of a file you want to update meta-data to"
              />
				<Param Name="keepRevisionForever"
					   Label=" Keep Revision Forever"
					   Required="False"
					   Type="Query"
					   Hidden="False"
					   Desc="Defines whether uploaded file has revisions"
					   Value=""
					   MultiSelect="False"
					   Options="True;False"
              />
				<Param Name="addParents"
					   Label=" AddParents"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A comma-separated list of parent IDs to add"
					   Value=""
              />
				<Param Name="ocrLanguage"
					   Label=" OcrLanguage"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="A language hint for OCR processing during image import (ISO 639-1 code)."
					   Value=""
              />
				<Param Name="useContentAsIndexableText"
					   Label=" UseContentAsIndexableText"
					   Required="False"
					   Type="Query"
					   Hidden="True"
					   Desc="Whether to use the uploaded content as indexable text."
					   Value="False"
              />
			</Params>
			<Body>
				<![CDATA[ {$rows$} ]]>
			</Body>
			<InputColumns>
				<Column Name="appProperties" Label="AppProperties" Desc="A collection of arbitrary key-value pairs which are private to the requesting app.
Entries with null values are cleared in update and copy requests. These properties can only be retrieved using an authenticated request. An authenticated request uses an access token obtained with a OAuth 2 client ID. You cannot use an API key to retrieve private properties."
					  DataType="DT_WSTR" Length="2000" Raw="True"/>
				<Column Name="contentHints.indexableText" Label="ContentHintsIndexableText" Desc="Text to be indexed for the file to improve fullText queries. This is limited to 128KB in length and may contain HTML elements."
					  DataType="DT_WSTR" Length="2000"/>
				<Column Name="contentHints.thumbnail.image" Label="ThumbnailImage" Desc="The thumbnail data encoded with URL-safe Base64 (RFC 4648 section 5)."
					  DataType="DT_WSTR" Length="4000"/>
				<Column Name="contentHints.thumbnail.mimeType" Label="ThumbnailMimeType" Desc="The MIME type of the thumbnail"
					  DataType="DT_WSTR" Length="4000"/>
				<Column Name="contentRestrictions" Label="ContentRestrictionsReadOnly" Desc="Format: 'contentRestrictions[].readOnly'. Whether the content of the file is read-only. If a file is read-only, a new revision of the file may not be added, comments may not be added or modified, and the title of the file may not be modified."
					  DataType="DT_WSTR" Length="4000" Raw="True"/>
				<Column Name="contentRestrictions" Label="ContentRestrictionsReason" Desc="Format: 'contentRestrictions[].reason'. Reason for why the content of the file is restricted. This is only mutable on requests that also set readOnly=true."
					  DataType="DT_WSTR" Length="4000" Raw="True"/>
				<Column Name="copyRequiresWriterPermission" Label="CopyRequiresWriterPermission" Desc="Whether the options to copy, print, or download this file, should be disabled for readers and commenters"
					  DataType="DT_BOOL"/>
				<Column Name="description" Label="Description" Desc="A short description of the file."
					  DataType="DT_WSTR"/>
				<Column Name="folderColorRgb" Label="FolderColorRgb" Desc="The color for a folder or shortcut to a folder as an RGB hex string. The supported colors are published in the folderColorPalette field of the About resource.
If an unsupported color is specified, the closest color in the palette will be used instead."
					  DataType="DT_WSTR" Length="2000"/>
				<Column Name="mimeType" Label="MimeType" Desc="The MIME type of the file.
Google Drive will attempt to automatically detect an appropriate value from uploaded content if no value is provided. The value cannot be changed unless a new revision is uploaded.

If a file is created with a Google Doc MIME type, the uploaded content will be imported if possible. The supported import formats are published in the About resource."
					  DataType="DT_WSTR" Length="2000"/>
				<Column Name="modifiedTime" Label="ModifiedTime" Desc="Format: 2019-10-12T07:20:50.52Z. The last time the file was modified by anyone (RFC 3339 date-time).
Note that setting modifiedTime will also update modifiedByMeTime for the user"
					  DataType="DT_DBTIMESTAMP"/>
				<Column Name="name" Label="Name" Desc="The name of the file. This is not necessarily unique within a folder. Note that for immutable items such as the top level folders of shared drives, My Drive root folder, and Application Data folder the name is constant."
					  DataType="DT_WSTR" Length="2000"/>
				<Column Name="originalFilename" Label="OriginalFilename" Desc="The original filename of the uploaded content if available, or else the original value of the name field. This is only available for files with binary content in Google Drive."
					  DataType="DT_WSTR" Length="2000"/>
				<Column Name="properties" Label="Properties" Desc="Entry as JSON object. A collection of arbitrary key-value pairs which are visible to all apps.
Entries with null values are cleared in update and copy requests."
					  DataType="DT_WSTR" Length="2000" Raw="True"/>
				<Column Name="starred" Label="Starred" Desc="Whether the user has starred the file."
					  DataType="DT_BOOL"/>
				<Column Name="trashed" Label="Trashed" Desc="Whether the file has been trashed, either explicitly or from a trashed parent folder. Only the owner may trash a file. The trashed item is excluded from all files.list responses returned for any user who does not own the file. However, all users with access to the file can see the trashed item metadata in an API response. All users with access can copy, download, export, and share the file."
					  DataType="DT_BOOL"/>
				<Column Name="viewedByMeTime" Label="ViewedByMeTime" Desc="Format: 2019-10-12T07:20:50.52Z. The last time the file was viewed by the 
          user (RFC 3339 date-time)."
					  DataType="DT_DBTIMESTAMP" Length="2000"/>
				<Column Name="writersCanShare" Label="WritersCanShare" Desc="Whether users with only writer permission can modify the file's permissions. Not populated for items in shared drives."
					  DataType="DT_BOOL"/>
			</InputColumns>
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="driveId" Label="DriveId" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>

		<!--=====================================
        =========== EMPTY TRASH =============
        =====================================-->
		<EndPoint Name="empty_trash" Label="Empty trash" Desc="Empties trash"  Template="DriveSupportTemplate"
					Url="/drive/v3/files/trash" Method="DELETE" DotAsPath="True" HelpLink="https://developers.google.com/drive/api/v3/reference/files/emptyTrash"
              >
			<OutputColumns>
				<Column Name="id" Label="Id" DataType="DT_WSTR" Length="440" />
				<Column Name="kind" Label="Kind" DataType="DT_WSTR" Length="200" />
				<Column Name="name" Label="Name" DataType="DT_WSTR" Length="780" />
				<Column Name="mimeType" Label="MimeType" DataType="DT_WSTR" Length="650" />
				<Column Name="driveId" Label="DriveId" DataType="DT_WSTR" />
			</OutputColumns>
		</EndPoint>



		<!--=======================================
        ========== DELETE ALL FILES ===========
        =======================================-->

		<EndPoint Name="delete_all_items" Label="Delete all items" Template="ListItemsTemplate" Desc="Deletes all items from the drive"
				  Url="/drive/v3/files" Method="GET" Filter="$.files[*]" HelpLink="https://developers.google.com/drive/api/v3/reference/files/delete"
              >
			<EndPoint Template="DeleteItemTemplate"
					Url="/drive/v3/files/[$parent.id$]" Method="DELETE"
                >
			</EndPoint>
		</EndPoint>

	</EndPoints>



	<!--=====================================
      ============= TABLES ================
      =====================================-->

	<Tables>
		<Table Name="Drive"
			   SelectEndPoint="get_about"
           />
		<Table Name="SharedDrives"
			   SelectEndPoint="list_shared_drives"
           />		   
		<Table Name="Files"
			   SelectEndPoint="list_files"
			   LookupEndPoint="get_file_info"
			   UpdateEndPoint="update_file"
			   DeleteEndPoint="delete_item"
			   InsertEndPoint="upload_file"
           />
		<Table Name="Folders"
			   SelectEndPoint="list_folders"
			   DeleteEndPoint="delete_item"
			   InsertEndPoint="create_folder"
			   LookupEndPoint="get_file_info"
           />
		   
		<Table Name="Trash"
			   SelectEndPoint="list_deleted_files"
			   DeleteEndPoint="empty_trash"
           />
		   
		 <!-- below depricated use Files and Folders tables-->  
		<Table Name="FileInfo"
			   SelectEndPoint="get_file_info"
           />
		<Table Name="ItemsList" 
			   SelectEndPoint="list_items"
           />
		<Table Name="FilesList"
			   SelectEndPoint="list_files" LookupEndPoint="get_file_info"
           />
		<Table Name="FoldersList"
			   SelectEndPoint="list_folders"
           />
		
	</Tables>


	<!--=====================================
      ============ EXAMPLES ===============
      =====================================-->
	<Examples>
	
		<Example Group="ODBC" Label="Get my drive information" Desc="Gets my drive information">
			<Code>
				<![CDATA[SELECT * FROM Drive]]>
			</Code>
		</Example>
		
		<Example Group="ODBC" Label="List all shared drives" Desc="List all shared drives">
			<Code>
				<![CDATA[SELECT * FROM SharedDrives --WITH(Query='name = "HR"')]]>
			</Code>
		</Example>	
		<Example Group="ODBC" Label="Get information about shared drive" Desc="Get information about shared drive">
			<Code>
				<![CDATA[SELECT * FROM SharedDrives WITH(Query='name = "HR"')]]>
			</Code>
		</Example>			
		
		<Example Group="ODBC" Label="List / search files from my drive" Desc="List or search files from my drive (use search query expression). Uncomment Query part to invoke filter">
			<Code>
				<![CDATA[SELECT * FROM Files
WITH(
	--Query='name  contains "ZappySys*.*"', --includes files where name contains "zappysys" word
)]]>
			</Code>
		</Example>	
		
		<Example Group="ODBC" Label="List / search files from a single shared drive" Desc="List or search files from a specific shared drive by driveId and search query expression. Uncomment Query part to invoke filter">
			<Code>
				<![CDATA[SELECT * FROM Files
WITH(
	--Query='name  contains "ZappySys*.*"', --includes files where name contains "zappysys" word
	DriveId='0AFWIggplk2z6Uk9PVA', 
	DriveType='drive',
	SupportsAllDrives='true',
	IncludeItemsFromAllDrives='true'
)]]>
			</Code>
		</Example>	
		<Example Group="ODBC" Label="List / search files from all shared drives" Desc="List or search files from all shared drives by driveId and search query expression. Uncomment Query part to invoke filter">
			<Code>
				<![CDATA[SELECT * FROM Files
WITH(
	--Query='name  contains "ZappySys*.*"', --includes files where name contains "zappysys" word
	DriveType='allDrives',
	SupportsAllDrives='true',
	IncludeItemsFromAllDrives='true'
)
]]>
			</Code>
		</Example>			


		<!-- Files and endpoints table -->
		<Example Group="ODBC" Label="Dowload a file (my drive)" Desc="Downloads a file (from user my drive)">
			<Code>
				<![CDATA[SELECT * FROM download_file
  WITH(Id='1PpE2eSi5faAnMwiSolwr34zA5MwOdR3D'	
      ,ResponseDataFile='C:\MyFiles\myfile.ext'
  )
  --You can get file Id by selecting from 'list_files' endpoint]]>
			</Code>
		</Example>
		
		<!-- Files and endpoints table -->
		<Example Group="ODBC" Label="Dowload a file from google shared drive" Desc="Dowload a file from google shared drive for which user has access">
			<Code>
				<![CDATA[SELECT * FROM download_file
WITH(
	  DriveType='drive' --or set 'user' for mydrive 
	, DriveId='0AFWIggplk2z6Uk9PVA'
	, Id='1hk7odj2Y2--yxN9DY0zW88hSnxqiyHq0' --file id
	, ResponseDataFile='c:\temp\dump.zip'
	--You can get file Id by selecting from 'list_files' endpoint
)				
]]>
			</Code>
		</Example>		
		
		<!-- Files and endpoints table -->
		<Example Group="ODBC" Label="Upload local file to google shared drive folder" Desc="Upload a local file to google shared drive folder for which user has access. Donot set DriveId to upload to MyDrive rather than sahred drive.">
			<Code>
				<![CDATA[SELECT *
FROM upload_file
WITH(
	  DriveId='0AC00HWQH144cUk9PVA' --team drive id (keep blank for uploading to my drive)
	, DiskFilePath='C:\temp\dump.csv' --source file path
	, FileName='dump.csv' --target file name
	, ParentFolderId='1PRySfNNjWIp9ZAnhPh-u9tKRj3QOETSq'
	, KeepRevisionForever='false'	
)				
]]>
			</Code>
		</Example>			


		<Example Group="ODBC" Label="Get file list" Desc="Downloads a file">
			<Code>
				<![CDATA[SELECT * FROM Files]]>
			</Code>
		</Example>

		<Example Group="ODBC" Label="Update a file" Desc="Updates a file">
			<Code>
				<![CDATA[UPDATE Files
  WITH (Id='1EVzXFVBQIh3LcJvfcLhI1UWhW3qUxFkM'
  ,DiskFilePath='C:\MyFiles\myfile.ext')
  --You can get file Id by selecting from 'list_files' endpoint
  ]]>
			</Code>
		</Example>

		<Example Group="ODBC" Label="Delete a file" Desc="Deletes a file">
			<Code>
				<![CDATA[DELETE FROM Files
  WITH (Id='1gcu0hV34OTfgvcu9CFhr7Go4b35j5Mop')
  --You can get file Id by selecting from 'list_files' endpoint]]>
			</Code>
		</Example>

		<Example Group="ODBC" Label="Delete a file by name from a shared drive" Desc="Delete a file by name from a shared drive">
			<Code>
				<![CDATA[DELETE FROM Files where Name='dump.csv' and Trashed=0 WITH(DriveId='0AC00HWQH144cUk9PVA', DriveType='drive')
  --You can get file Id by selecting from 'list_files' endpoint]]>
			</Code>
		</Example>



		<Example Group="ODBC" Label="Upload a file with INSERT keyword" Desc="Upload a file with INSERT keyword. Advantage of INSERT is you can use Bulk option using SOURCE clause. This way you can upload many files">
			<Code>
				<![CDATA[INSERT INTO Files
  WITH (FileName='My filename'
      ,DiskFilePath='C:\MyFolder\Mymyfile.ext'
      ,ParentFolderId='root'
	  )
  --You can get ParentFolderId by selecting from 'list_folders' endpoint or just use 'root']]>
			</Code>
		</Example>

		<!-- Folders table -->
		<Example Group="ODBC" Label="Delete a folder" Desc="Deletes a folder">
			<Code>
				<![CDATA[DELETE FROM Folders
  WITH (Id='1yDO11prsLH9DUrBTCadV6GGMJrITjF9I')
  --You can get folder Id by selecting from 'list_folders' endpoint]]>
			</Code>
		</Example>

		<Example Group="ODBC" Label="Create a folder" Desc="Creates a folder">
			<Code>
				<![CDATA[INSERT INTO Folders
  WITH (Name='My folder name'
      ,ParentFolderId='root')
  --You can get ParentFolderId by selecting from 'list_folders' endpoint or just use 'root']]>
			</Code>
		</Example>

		<!-- FileInfo table -->
		<Example Group="ODBC" Label="Get file information" Desc="Gets file information">
			<Code>
				<![CDATA[SELECT * FROM FileInfo
  WITH (Id='1EVzXFVBQIh3LcJvfcLhI1UWhW3qUxFkM')
  --You can get file Id by selecting from 'list_files' endpoint]]>
			</Code>
		</Example>

		<!-- ItemsList table -->
		<Example Group="ODBC" Label="Get items list" Desc="Gets items list">
			<Code>
				<![CDATA[SELECT * FROM ItemsList]]>
			</Code>
		</Example>

		<Example Group="ODBC" Label="Get items list using query" Desc="Gets items list using query">
			<Code>
				<![CDATA[SELECT Id, Kind, Name, MimeType
  FROM list_items
  WITH (Query = 'name contains ''.txt''')]]>
			</Code>
		</Example>

		<!-- FilesList table -->
		<Example Group="ODBC" Label="Get files list" Desc="Gets files list">
			<Code>
				<![CDATA[SELECT * FROM FilesList]]>
			</Code>
		</Example>

		<!-- FoldersList table -->
		<Example Group="ODBC" Label="Get folders list" Desc="Gets folders list">
			<Code>
				<![CDATA[SELECT * FROM FoldersList]]>
			</Code>
		</Example>

		<!-- Trash table -->
		<Example Group="ODBC" Label="Select from trash" Desc="Shows deleted items in Trash">
			<Code>
				<![CDATA[SELECT * FROM Trash]]>
			</Code>
		</Example>
		<Example Group="ODBC" Label="List files from trash for a shared drive" Desc="Shows deleted items in Trash">
			<Code>
				<![CDATA[SELECT * FROM Trash
				WITH(
				    DriveType='drive'
				   ,DriveId='1j0HFOP4gsoExxxxxx' 	--get id from select * from SharedDrives			   
				 )				
				]]>
			</Code>
		</Example>		
		<Example Group="ODBC" Label="Empty trash bin" Desc="Empties trash bin">
			<Code>
				<![CDATA[DELETE FROM Trash]]>
			</Code>
		</Example>
		<Example Group="ODBC" Label="Empty trash bin for a shared drive" Desc="Empties trash bin for a specified shared drive">
			<Code>
				<![CDATA[DELETE FROM Trash
				WITH(
				    DriveType='drive'
				   ,DriveId='1j0HFOP4gsoExxxxxx' --get id from select * from SharedDrives
				 )
				]]>
			</Code>
		</Example>		
		<!-- export_file-->
		<Example Group="ODBC" Label="Export Google Sheet to Excel (xlsx) or PDF" Desc="Export a Google files to other format (e.g. Google Sheets to MS Excel / PDF)">
			<Code>
				<![CDATA[SELECT "Status" FROM export_file
				WITH(
                      Id='1j0HFOP4gsoE-Zbf2xN3IsPSj8wgwNtIfyyvM1_BWkW4' --//google sheet id or document ID
					  
				   --,DriveId='xx your shared drive id'  --get id from select * from SharedDrives
				   --,DriveType='drive'
					   
					 , ExportAs='application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
				   --, ExportAs='application/pdf'
					 , ResponseDataFile='c:\temp\sheet1.xlsx'		
					 , FileOverwriteMode='AlwaysOverwrite' -- or try 'FailIfExists' or 'SkipIfExists'					 
				))
			 --You can export files from 'export_file' endpoint]]>
			</Code>
		</Example>
			
	</Examples>
</ApiConfig>