google-cloud-essential_contacts-v1 0.2.0 → 0.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/AUTHENTICATION.md +1 -1
- data/README.md +2 -2
- data/lib/google/cloud/essential_contacts/v1/essential_contacts_service/client.rb +14 -16
- data/lib/google/cloud/essential_contacts/v1/essential_contacts_service/rest/client.rb +842 -0
- data/lib/google/cloud/essential_contacts/v1/essential_contacts_service/rest/service_stub.rb +568 -0
- data/lib/google/cloud/essential_contacts/v1/essential_contacts_service/rest.rb +52 -0
- data/lib/google/cloud/essential_contacts/v1/essential_contacts_service.rb +7 -1
- data/lib/google/cloud/essential_contacts/v1/rest.rb +37 -0
- data/lib/google/cloud/essential_contacts/v1/version.rb +1 -1
- data/lib/google/cloud/essential_contacts/v1.rb +7 -2
- data/lib/google/cloud/essentialcontacts/v1/enums_pb.rb +24 -17
- data/lib/google/cloud/essentialcontacts/v1/service_pb.rb +26 -47
- data/proto_docs/google/api/client.rb +381 -0
- data/proto_docs/google/api/launch_stage.rb +71 -0
- data/proto_docs/google/protobuf/duration.rb +98 -0
- data/proto_docs/google/protobuf/empty.rb +0 -2
- data/proto_docs/google/protobuf/timestamp.rb +1 -3
- metadata +14 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 731dcda8218add231df4bd6cba3900500e528429a14ac206c220b682777188ea
|
4
|
+
data.tar.gz: 35ab8548f8f332699f1a2a405f836ed5f106876c042e55b46c809907fbc98701
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c47ea560ca299f4303f72b903deb39828665434200f9a43bd151fc770cb774002de9a400a979bd1352e77eb9000aba29c94c47c875bc2d1f36715123e13762eb
|
7
|
+
data.tar.gz: a5ce37b8989f9572aa8fa79326bdfa4fd0f963c4473fa19653924bfa1d2066dbbe5beb13161150b2a6208dd012d693e9cd75b4c0d4d960891986da8c2ec25fe7
|
data/AUTHENTICATION.md
CHANGED
@@ -114,7 +114,7 @@ credentials are discovered.
|
|
114
114
|
To configure your system for this, simply:
|
115
115
|
|
116
116
|
1. [Download and install the Cloud SDK](https://cloud.google.com/sdk)
|
117
|
-
2. Authenticate using OAuth 2.0 `$ gcloud auth login`
|
117
|
+
2. Authenticate using OAuth 2.0 `$ gcloud auth application-default login`
|
118
118
|
3. Write code as if already authenticated.
|
119
119
|
|
120
120
|
**NOTE:** This is _not_ recommended for running in production. The Cloud SDK
|
data/README.md
CHANGED
@@ -46,8 +46,8 @@ for general usage information.
|
|
46
46
|
## Enabling Logging
|
47
47
|
|
48
48
|
To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
|
49
|
-
The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/
|
50
|
-
or a [`Google::Cloud::Logging::Logger`](https://
|
49
|
+
The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/current/stdlibs/logger/Logger.html) as shown below,
|
50
|
+
or a [`Google::Cloud::Logging::Logger`](https://cloud.google.com/ruby/docs/reference/google-cloud-logging/latest)
|
51
51
|
that will write logs to [Cloud Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
|
52
52
|
and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
|
53
53
|
|
@@ -143,7 +143,7 @@ module Google
|
|
143
143
|
credentials = @config.credentials
|
144
144
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
145
145
|
# but only if the default endpoint does not have a region prefix.
|
146
|
-
enable_self_signed_jwt = @config.endpoint ==
|
146
|
+
enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
147
147
|
!@config.endpoint.split(".").first.include?("-")
|
148
148
|
credentials ||= Credentials.default scope: @config.scope,
|
149
149
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -398,13 +398,11 @@ module Google
|
|
398
398
|
# # Call the list_contacts method.
|
399
399
|
# result = client.list_contacts request
|
400
400
|
#
|
401
|
-
# # The returned object is of type Gapic::PagedEnumerable. You can
|
402
|
-
# #
|
403
|
-
#
|
404
|
-
# # methods are also available for managing paging directly.
|
405
|
-
# result.each do |response|
|
401
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
402
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
403
|
+
# result.each do |item|
|
406
404
|
# # Each element is of type ::Google::Cloud::EssentialContacts::V1::Contact.
|
407
|
-
# p
|
405
|
+
# p item
|
408
406
|
# end
|
409
407
|
#
|
410
408
|
def list_contacts request, options = nil
|
@@ -684,13 +682,11 @@ module Google
|
|
684
682
|
# # Call the compute_contacts method.
|
685
683
|
# result = client.compute_contacts request
|
686
684
|
#
|
687
|
-
# # The returned object is of type Gapic::PagedEnumerable. You can
|
688
|
-
# #
|
689
|
-
#
|
690
|
-
# # methods are also available for managing paging directly.
|
691
|
-
# result.each do |response|
|
685
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
686
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
687
|
+
# result.each do |item|
|
692
688
|
# # Each element is of type ::Google::Cloud::EssentialContacts::V1::Contact.
|
693
|
-
# p
|
689
|
+
# p item
|
694
690
|
# end
|
695
691
|
#
|
696
692
|
def compute_contacts request, options = nil
|
@@ -871,9 +867,9 @@ module Google
|
|
871
867
|
# * (`String`) The path to a service account key file in JSON format
|
872
868
|
# * (`Hash`) A service account key as a Hash
|
873
869
|
# * (`Google::Auth::Credentials`) A googleauth credentials object
|
874
|
-
# (see the [googleauth docs](https://
|
870
|
+
# (see the [googleauth docs](https://rubydoc.info/gems/googleauth/Google/Auth/Credentials))
|
875
871
|
# * (`Signet::OAuth2::Client`) A signet oauth2 client object
|
876
|
-
# (see the [signet docs](https://
|
872
|
+
# (see the [signet docs](https://rubydoc.info/gems/signet/Signet/OAuth2/Client))
|
877
873
|
# * (`GRPC::Core::Channel`) a gRPC channel with included credentials
|
878
874
|
# * (`GRPC::Core::ChannelCredentials`) a gRPC credentails object
|
879
875
|
# * (`nil`) indicating no credentials
|
@@ -915,7 +911,9 @@ module Google
|
|
915
911
|
class Configuration
|
916
912
|
extend ::Gapic::Config
|
917
913
|
|
918
|
-
|
914
|
+
DEFAULT_ENDPOINT = "essentialcontacts.googleapis.com"
|
915
|
+
|
916
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
919
917
|
config_attr :credentials, nil do |value|
|
920
918
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
921
919
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|