第 120 章 Google Drive Component

作为 Camel 版本 2.14 可用

Google Drive 组件通过 Google Drive Web API 提供对 Google Drive 文件存储服务的访问

Google Drive 使用 OAuth 2.0 协议 对 Google 帐户进行身份验证,并授权访问用户数据。在使用此组件前,您需要 创建帐户并生成 OAuth 凭证。凭证包括 clientId、clientSecret 和 refreshToken。生成长期刷新Token 的方便资源是 OAuth playground

Maven 用户需要在这些组件的 pom.xml 中添加以下依赖项:

    <dependency>
            <groupId>org.apache.camel</groupId>
            <artifactId>camel-google-drive</artifactId>
            <version>2.14-SNAPSHOT</version>
    </dependency>

120.1. URI 格式

GoogleDrive 组件使用以下 URI 格式:

        google-drive://endpoint-prefix/endpoint?[options]

端点前缀可以是以下之一:

  • drive-about
  • drive-apps
  • drive-changes
  • drive-channels
  • drive-children
  • drive-comments
  • drive-files
  • drive-parents
  • drive-permissions
  • drive-properties
  • drive-realtime
  • drive-replies
  • 驱动修订