diff --git a/README.md b/README.md index 7174aedba687..309f2506597f 100644 --- a/README.md +++ b/README.md @@ -31,6 +31,7 @@ This client supports the following Google Cloud Platform services at a [Beta](#v This client supports the following Google Cloud Platform services at an [Alpha](#versioning) quality level: * [Google Cloud Speech](#google-cloud-speech-alpha) (Alpha) * [Google Stackdriver Trace](#google-stackdriver-trace-alpha) (Alpha) +* [Google Cloud BigQuery Data Transfer](#google-cloud-bigquerydatatransfer-alpha) (Alpha) If you need support for other Google APIs, please check out the [Google APIs Client Library for PHP](https://github.com/google/google-api-php-client). @@ -899,6 +900,36 @@ Stackdriver Trace can be installed separately by requiring the `google/cloud-tra $ composer require google/cloud-trace ``` +## Google Cloud BigQuery Data Transfer (Alpha) + +- [Source Code](https://github.com/GoogleCloudPlatform/google-cloud-php-bigquerydatatransfer) + +**NOTE:** The BigQuery Data Transfer client library is not included in +google/cloud, and must be installed separately. See below for installation +instructions. + +#### Preview + +```php +require 'vendor/autoload.php'; + +use Google\Cloud\BigQuery\DataTransfer\V1\DataTransferServiceClient; + +$dataTransferServiceClient = new DataTransferServiceClient(); +$projectId = '[MY_PROJECT_ID]'; +$location = 'us-central1'; +$formattedLocation = $dataTransferServiceClient->locationName($projectId, $location); +$dataSources = $dataTransferServiceClient->listDataSources($formattedLocation); +``` + +#### google/cloud-bigquerydatatransfer + +Google Cloud BigQuery Data Transfer **must** be installed separately by requiring the `google/cloud-bigquerydatatransfer` composer package: + +``` +$ composer require google/cloud-bigquerydatatransfer +``` + ## Caching Access Tokens By default the library will use a simple in-memory caching implementation, however it is possible to override this behavior by passing a [PSR-6](http://www.php-fig.org/psr/psr-6/) caching implementation in to the desired client. diff --git a/composer.json b/composer.json index 92fe07487267..5ddd1ade88db 100644 --- a/composer.json +++ b/composer.json @@ -49,8 +49,8 @@ "monolog/monolog": "~1", "psr/http-message": "1.0.*", "ramsey/uuid": "~3", - "google/proto-client": "0.29.0", - "google/gax": "0.28.0" + "google/proto-client": "^0.29.0", + "google/gax": "^0.28.0" }, "require-dev": { "phpunit/phpunit": "^4.8|^5.0", @@ -87,7 +87,8 @@ "google/cloud-vision": "0.8.0" }, "suggest": { - "phpseclib/phpseclib": "May be used in place of OpenSSL for creating signed Cloud Storage URLs. Please require version ^2." + "phpseclib/phpseclib": "May be used in place of OpenSSL for creating signed Cloud Storage URLs. Please require version ^2.", + "google/cloud-bigquerydatatransfer": "Client library for the BigQuery Data Transfer API." }, "autoload": { "psr-4": {