diff options
author | kinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-05 02:12:46 +0000 |
---|---|---|
committer | kinaba@chromium.org <kinaba@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-02-05 02:12:46 +0000 |
commit | 63049bbbeeebdeaf7eced730f8b247d5c8e6928e (patch) | |
tree | 585b477fd56779dce255d103cadf4bf335396581 /google_apis/drive/drive_api_url_generator.cc | |
parent | f6d2cba2529f2e4d828bd0e516eec7ab8169fdd6 (diff) | |
download | chromium_src-63049bbbeeebdeaf7eced730f8b247d5c8e6928e.zip chromium_src-63049bbbeeebdeaf7eced730f8b247d5c8e6928e.tar.gz chromium_src-63049bbbeeebdeaf7eced730f8b247d5c8e6928e.tar.bz2 |
Parse "removable" and "productId" fields from apps.list response.
BUG=334966
R=hashimoto@chromium.org
Review URL: https://codereview.chromium.org/132333006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@248831 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'google_apis/drive/drive_api_url_generator.cc')
-rw-r--r-- | google_apis/drive/drive_api_url_generator.cc | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/google_apis/drive/drive_api_url_generator.cc b/google_apis/drive/drive_api_url_generator.cc index e8660cc..a68938c 100644 --- a/google_apis/drive/drive_api_url_generator.cc +++ b/google_apis/drive/drive_api_url_generator.cc @@ -7,6 +7,7 @@ #include "base/logging.h" #include "base/strings/string_number_conversions.h" #include "base/strings/stringprintf.h" +#include "google_apis/google_api_keys.h" #include "net/base/escape.h" #include "net/base/url_util.h" @@ -32,6 +33,7 @@ const char kDriveV2InitiateUploadExistingFileUrlPrefix[] = // apps.delete and file.authorize API is exposed through a special endpoint // v2internal that is accessible only by the official API key for Chrome. +const char kDriveV2InternalAppsUrl[] = "/drive/v2internal/apps"; const char kDriveV2AppsDeleteUrlFormat[] = "/drive/v2internal/apps/%s"; const char kDriveV2FilesAuthorizeUrlFormat[] = "/drive/v2internal/files/%s/authorize?appId=%s"; @@ -62,8 +64,9 @@ GURL DriveApiUrlGenerator::GetAboutGetUrl() const { return base_url_.Resolve(kDriveV2AboutUrl); } -GURL DriveApiUrlGenerator::GetAppsListUrl() const { - return base_url_.Resolve(kDriveV2AppsUrl); +GURL DriveApiUrlGenerator::GetAppsListUrl(bool use_internal_endpoint) const { + return base_url_.Resolve(use_internal_endpoint ? + kDriveV2InternalAppsUrl : kDriveV2AppsUrl); } GURL DriveApiUrlGenerator::GetAppsDeleteUrl(const std::string& app_id) const { |