google-cloud-channel-v1 0.19.0 → 0.21.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/lib/google/cloud/channel/v1/channel_partner_links_pb.rb +26 -23
- data/lib/google/cloud/channel/v1/cloud_channel_reports_service/client.rb +4 -2
- data/lib/google/cloud/channel/v1/cloud_channel_reports_service/operations.rb +3 -1
- data/lib/google/cloud/channel/v1/cloud_channel_reports_service/rest/client.rb +4 -2
- data/lib/google/cloud/channel/v1/cloud_channel_reports_service/rest/operations.rb +7 -5
- data/lib/google/cloud/channel/v1/cloud_channel_reports_service/rest/service_stub.rb +3 -3
- data/lib/google/cloud/channel/v1/cloud_channel_service/client.rb +257 -2
- data/lib/google/cloud/channel/v1/cloud_channel_service/operations.rb +3 -1
- data/lib/google/cloud/channel/v1/cloud_channel_service/paths.rb +17 -0
- data/lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb +203 -2
- data/lib/google/cloud/channel/v1/cloud_channel_service/rest/operations.rb +7 -5
- data/lib/google/cloud/channel/v1/cloud_channel_service/rest/service_stub.rb +164 -46
- data/lib/google/cloud/channel/v1/common_pb.rb +25 -50
- data/lib/google/cloud/channel/v1/customers_pb.rb +27 -24
- data/lib/google/cloud/channel/v1/entitlement_changes_pb.rb +26 -54
- data/lib/google/cloud/channel/v1/entitlements_pb.rb +28 -73
- data/lib/google/cloud/channel/v1/offers_pb.rb +28 -104
- data/lib/google/cloud/channel/v1/operations_pb.rb +24 -18
- data/lib/google/cloud/channel/v1/products_pb.rb +24 -24
- data/lib/google/cloud/channel/v1/reports_service_pb.rb +29 -94
- data/lib/google/cloud/channel/v1/repricing_pb.rb +27 -52
- data/lib/google/cloud/channel/v1/service_pb.rb +39 -345
- data/lib/google/cloud/channel/v1/service_services_pb.rb +40 -0
- data/lib/google/cloud/channel/v1/subscriber_event_pb.rb +24 -35
- data/lib/google/cloud/channel/v1/version.rb +1 -1
- data/proto_docs/google/cloud/channel/v1/service.rb +112 -0
- data/proto_docs/google/protobuf/any.rb +7 -4
- data/proto_docs/google/protobuf/timestamp.rb +1 -3
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3aa8fc5349ce7d0cfccf288e1191130183a587f46a17fb2a3b5ae9529d4f2ed0
|
4
|
+
data.tar.gz: 76292b004a004dec6d17510c206830e5bd4e2e1b70798bf9c27c511618361454
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5c806102daf252edd3dc447a4fac8a969a4a6903f7292abd13794c23dd1cbff5ab6df2ee4f51e9c77e579f518b36734d129fa1f4f47d49363c85618b6375f634
|
7
|
+
data.tar.gz: 0cca47f4f897f9cd3b4b4e4fb1c9dee96bc5c617524449c4a0d0b7136659d3a2dd9d418c7d5d6a2fd6403062e8d91abd4a505d90dd7c0cdc78344340c565accf
|
@@ -1,3 +1,4 @@
|
|
1
|
+
# frozen_string_literal: true
|
1
2
|
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
3
|
# source: google/cloud/channel/v1/channel_partner_links.proto
|
3
4
|
|
@@ -8,31 +9,33 @@ require 'google/api/resource_pb'
|
|
8
9
|
require 'google/cloud/channel/v1/common_pb'
|
9
10
|
require 'google/protobuf/timestamp_pb'
|
10
11
|
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
12
|
+
|
13
|
+
descriptor_data = "\n3google/cloud/channel/v1/channel_partner_links.proto\x12\x17google.cloud.channel.v1\x1a\x1fgoogle/api/field_behavior.proto\x1a\x19google/api/resource.proto\x1a$google/cloud/channel/v1/common.proto\x1a\x1fgoogle/protobuf/timestamp.proto\"\x8f\x04\n\x12\x43hannelPartnerLink\x12\x11\n\x04name\x18\x01 \x01(\tB\x03\xe0\x41\x03\x12\'\n\x1areseller_cloud_identity_id\x18\x02 \x01(\tB\x03\xe0\x41\x02\x12I\n\nlink_state\x18\x03 \x01(\x0e\x32\x30.google.cloud.channel.v1.ChannelPartnerLinkStateB\x03\xe0\x41\x02\x12\x1c\n\x0finvite_link_uri\x18\x04 \x01(\tB\x03\xe0\x41\x03\x12\x34\n\x0b\x63reate_time\x18\x05 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x34\n\x0bupdate_time\x18\x06 \x01(\x0b\x32\x1a.google.protobuf.TimestampB\x03\xe0\x41\x03\x12\x16\n\tpublic_id\x18\x07 \x01(\tB\x03\xe0\x41\x03\x12\\\n#channel_partner_cloud_identity_info\x18\x08 \x01(\x0b\x32*.google.cloud.channel.v1.CloudIdentityInfoB\x03\xe0\x41\x03:r\xea\x41o\n.cloudchannel.googleapis.com/ChannelPartnerLink\x12=accounts/{account}/channelPartnerLinks/{channel_partner_link}*>\n\x16\x43hannelPartnerLinkView\x12\x0f\n\x0bUNSPECIFIED\x10\x00\x12\t\n\x05\x42\x41SIC\x10\x01\x12\x08\n\x04\x46ULL\x10\x02*z\n\x17\x43hannelPartnerLinkState\x12*\n&CHANNEL_PARTNER_LINK_STATE_UNSPECIFIED\x10\x00\x12\x0b\n\x07INVITED\x10\x01\x12\n\n\x06\x41\x43TIVE\x10\x02\x12\x0b\n\x07REVOKED\x10\x03\x12\r\n\tSUSPENDED\x10\x04\x42p\n\x1b\x63om.google.cloud.channel.v1B\x18\x43hannelPartnerLinksProtoP\x01Z5cloud.google.com/go/channel/apiv1/channelpb;channelpbb\x06proto3"
|
14
|
+
|
15
|
+
pool = Google::Protobuf::DescriptorPool.generated_pool
|
16
|
+
|
17
|
+
begin
|
18
|
+
pool.add_serialized_file(descriptor_data)
|
19
|
+
rescue TypeError => e
|
20
|
+
# Compatibility code: will be removed in the next major version.
|
21
|
+
require 'google/protobuf/descriptor_pb'
|
22
|
+
parsed = Google::Protobuf::FileDescriptorProto.decode(descriptor_data)
|
23
|
+
parsed.clear_dependency
|
24
|
+
serialized = parsed.class.encode(parsed)
|
25
|
+
file = pool.add_serialized_file(serialized)
|
26
|
+
warn "Warning: Protobuf detected an import path issue while loading generated file #{__FILE__}"
|
27
|
+
imports = [
|
28
|
+
["google.protobuf.Timestamp", "google/protobuf/timestamp.proto"],
|
29
|
+
["google.cloud.channel.v1.CloudIdentityInfo", "google/cloud/channel/v1/common.proto"],
|
30
|
+
]
|
31
|
+
imports.each do |type_name, expected_filename|
|
32
|
+
import_file = pool.lookup(type_name).file_descriptor
|
33
|
+
if import_file.name != expected_filename
|
34
|
+
warn "- #{file.name} imports #{expected_filename}, but that import was loaded as #{import_file.name}"
|
34
35
|
end
|
35
36
|
end
|
37
|
+
warn "Each proto file must use a consistent fully-qualified name."
|
38
|
+
warn "This will become an error in the next major version."
|
36
39
|
end
|
37
40
|
|
38
41
|
module Google
|
@@ -125,7 +125,7 @@ module Google
|
|
125
125
|
credentials = @config.credentials
|
126
126
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
127
127
|
# but only if the default endpoint does not have a region prefix.
|
128
|
-
enable_self_signed_jwt = @config.endpoint ==
|
128
|
+
enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
129
129
|
!@config.endpoint.split(".").first.include?("-")
|
130
130
|
credentials ||= Credentials.default scope: @config.scope,
|
131
131
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -599,7 +599,9 @@ module Google
|
|
599
599
|
class Configuration
|
600
600
|
extend ::Gapic::Config
|
601
601
|
|
602
|
-
|
602
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
603
|
+
|
604
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
603
605
|
config_attr :credentials, nil do |value|
|
604
606
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
605
607
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -664,7 +664,9 @@ module Google
|
|
664
664
|
class Configuration
|
665
665
|
extend ::Gapic::Config
|
666
666
|
|
667
|
-
|
667
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
668
|
+
|
669
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
668
670
|
config_attr :credentials, nil do |value|
|
669
671
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
670
672
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -121,7 +121,7 @@ module Google
|
|
121
121
|
credentials = @config.credentials
|
122
122
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
123
123
|
# but only if the default endpoint does not have a region prefix.
|
124
|
-
enable_self_signed_jwt = @config.endpoint ==
|
124
|
+
enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
125
125
|
!@config.endpoint.split(".").first.include?("-")
|
126
126
|
credentials ||= Credentials.default scope: @config.scope,
|
127
127
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -497,7 +497,9 @@ module Google
|
|
497
497
|
class Configuration
|
498
498
|
extend ::Gapic::Config
|
499
499
|
|
500
|
-
|
500
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
501
|
+
|
502
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
501
503
|
config_attr :credentials, nil do |value|
|
502
504
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
503
505
|
allowed.any? { |klass| klass === value }
|
@@ -446,7 +446,9 @@ module Google
|
|
446
446
|
class Configuration
|
447
447
|
extend ::Gapic::Config
|
448
448
|
|
449
|
-
|
449
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
450
|
+
|
451
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
450
452
|
config_attr :credentials, nil do |value|
|
451
453
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
452
454
|
allowed.any? { |klass| klass === value }
|
@@ -567,7 +569,7 @@ module Google
|
|
567
569
|
|
568
570
|
verb, uri, query_string_params, body = OperationsServiceStub.transcode_list_operations_request request_pb
|
569
571
|
query_string_params = if query_string_params.any?
|
570
|
-
query_string_params.to_h { |p| p.split
|
572
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
571
573
|
else
|
572
574
|
{}
|
573
575
|
end
|
@@ -605,7 +607,7 @@ module Google
|
|
605
607
|
|
606
608
|
verb, uri, query_string_params, body = OperationsServiceStub.transcode_get_operation_request request_pb
|
607
609
|
query_string_params = if query_string_params.any?
|
608
|
-
query_string_params.to_h { |p| p.split
|
610
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
609
611
|
else
|
610
612
|
{}
|
611
613
|
end
|
@@ -643,7 +645,7 @@ module Google
|
|
643
645
|
|
644
646
|
verb, uri, query_string_params, body = OperationsServiceStub.transcode_delete_operation_request request_pb
|
645
647
|
query_string_params = if query_string_params.any?
|
646
|
-
query_string_params.to_h { |p| p.split
|
648
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
647
649
|
else
|
648
650
|
{}
|
649
651
|
end
|
@@ -681,7 +683,7 @@ module Google
|
|
681
683
|
|
682
684
|
verb, uri, query_string_params, body = OperationsServiceStub.transcode_cancel_operation_request request_pb
|
683
685
|
query_string_params = if query_string_params.any?
|
684
|
-
query_string_params.to_h { |p| p.split
|
686
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
685
687
|
else
|
686
688
|
{}
|
687
689
|
end
|
@@ -59,7 +59,7 @@ module Google
|
|
59
59
|
|
60
60
|
verb, uri, query_string_params, body = ServiceStub.transcode_run_report_job_request request_pb
|
61
61
|
query_string_params = if query_string_params.any?
|
62
|
-
query_string_params.to_h { |p| p.split
|
62
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
63
63
|
else
|
64
64
|
{}
|
65
65
|
end
|
@@ -97,7 +97,7 @@ module Google
|
|
97
97
|
|
98
98
|
verb, uri, query_string_params, body = ServiceStub.transcode_fetch_report_results_request request_pb
|
99
99
|
query_string_params = if query_string_params.any?
|
100
|
-
query_string_params.to_h { |p| p.split
|
100
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
101
101
|
else
|
102
102
|
{}
|
103
103
|
end
|
@@ -135,7 +135,7 @@ module Google
|
|
135
135
|
|
136
136
|
verb, uri, query_string_params, body = ServiceStub.transcode_list_reports_request request_pb
|
137
137
|
query_string_params = if query_string_params.any?
|
138
|
-
query_string_params.to_h { |p| p.split
|
138
|
+
query_string_params.to_h { |p| p.split "=", 2 }
|
139
139
|
else
|
140
140
|
{}
|
141
141
|
end
|
@@ -169,7 +169,7 @@ module Google
|
|
169
169
|
credentials = @config.credentials
|
170
170
|
# Use self-signed JWT if the endpoint is unchanged from default,
|
171
171
|
# but only if the default endpoint does not have a region prefix.
|
172
|
-
enable_self_signed_jwt = @config.endpoint ==
|
172
|
+
enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT &&
|
173
173
|
!@config.endpoint.split(".").first.include?("-")
|
174
174
|
credentials ||= Credentials.default scope: @config.scope,
|
175
175
|
enable_self_signed_jwt: enable_self_signed_jwt
|
@@ -4526,6 +4526,245 @@ module Google
|
|
4526
4526
|
raise ::Google::Cloud::Error.from_error(e)
|
4527
4527
|
end
|
4528
4528
|
|
4529
|
+
##
|
4530
|
+
# Lists the Rebilling supported SKU groups the account is authorized to
|
4531
|
+
# sell.
|
4532
|
+
# Reference: https://cloud.google.com/skus/sku-groups
|
4533
|
+
#
|
4534
|
+
# Possible Error Codes:
|
4535
|
+
#
|
4536
|
+
# * PERMISSION_DENIED: If the account making the request and the account
|
4537
|
+
# being queried are different, or the account doesn't exist.
|
4538
|
+
# * INTERNAL: Any non-user error related to technical issues in the
|
4539
|
+
# backend. In this case, contact Cloud Channel support.
|
4540
|
+
#
|
4541
|
+
# Return Value:
|
4542
|
+
# If successful, the {::Google::Cloud::Channel::V1::SkuGroup SkuGroup} resources.
|
4543
|
+
# The data for each resource is displayed in the alphabetical order of SKU
|
4544
|
+
# group display name.
|
4545
|
+
# The data for each resource is displayed in the ascending order of
|
4546
|
+
# {::Google::Cloud::Channel::V1::SkuGroup#display_name SkuGroup.display_name}
|
4547
|
+
#
|
4548
|
+
# If unsuccessful, returns an error.
|
4549
|
+
#
|
4550
|
+
# @overload list_sku_groups(request, options = nil)
|
4551
|
+
# Pass arguments to `list_sku_groups` via a request object, either of type
|
4552
|
+
# {::Google::Cloud::Channel::V1::ListSkuGroupsRequest} or an equivalent Hash.
|
4553
|
+
#
|
4554
|
+
# @param request [::Google::Cloud::Channel::V1::ListSkuGroupsRequest, ::Hash]
|
4555
|
+
# A request object representing the call parameters. Required. To specify no
|
4556
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
4557
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
4558
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
4559
|
+
#
|
4560
|
+
# @overload list_sku_groups(parent: nil, page_size: nil, page_token: nil)
|
4561
|
+
# Pass arguments to `list_sku_groups` via keyword arguments. Note that at
|
4562
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
4563
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
4564
|
+
#
|
4565
|
+
# @param parent [::String]
|
4566
|
+
# Required. The resource name of the account from which to list SKU groups.
|
4567
|
+
# Parent uses the format: accounts/\\{account}.
|
4568
|
+
# @param page_size [::Integer]
|
4569
|
+
# Optional. The maximum number of SKU groups to return. The service may
|
4570
|
+
# return fewer than this value. If unspecified, returns a maximum of 1000 SKU
|
4571
|
+
# groups. The maximum value is 1000; values above 1000 will be coerced to
|
4572
|
+
# 1000.
|
4573
|
+
# @param page_token [::String]
|
4574
|
+
# Optional. A token identifying a page of results beyond the first page.
|
4575
|
+
# Obtained through
|
4576
|
+
# [ListSkuGroups.next_page_token][] of the previous
|
4577
|
+
# {::Google::Cloud::Channel::V1::CloudChannelService::Client#list_sku_groups CloudChannelService.ListSkuGroups}
|
4578
|
+
# call.
|
4579
|
+
#
|
4580
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
4581
|
+
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::Channel::V1::SkuGroup>]
|
4582
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
4583
|
+
#
|
4584
|
+
# @return [::Gapic::PagedEnumerable<::Google::Cloud::Channel::V1::SkuGroup>]
|
4585
|
+
#
|
4586
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
4587
|
+
#
|
4588
|
+
# @example Basic example
|
4589
|
+
# require "google/cloud/channel/v1"
|
4590
|
+
#
|
4591
|
+
# # Create a client object. The client can be reused for multiple calls.
|
4592
|
+
# client = Google::Cloud::Channel::V1::CloudChannelService::Client.new
|
4593
|
+
#
|
4594
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
4595
|
+
# request = Google::Cloud::Channel::V1::ListSkuGroupsRequest.new
|
4596
|
+
#
|
4597
|
+
# # Call the list_sku_groups method.
|
4598
|
+
# result = client.list_sku_groups request
|
4599
|
+
#
|
4600
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
4601
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
4602
|
+
# result.each do |item|
|
4603
|
+
# # Each element is of type ::Google::Cloud::Channel::V1::SkuGroup.
|
4604
|
+
# p item
|
4605
|
+
# end
|
4606
|
+
#
|
4607
|
+
def list_sku_groups request, options = nil
|
4608
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
4609
|
+
|
4610
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSkuGroupsRequest
|
4611
|
+
|
4612
|
+
# Converts hash and nil to an options object
|
4613
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
4614
|
+
|
4615
|
+
# Customize the options with defaults
|
4616
|
+
metadata = @config.rpcs.list_sku_groups.metadata.to_h
|
4617
|
+
|
4618
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
4619
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
4620
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
4621
|
+
gapic_version: ::Google::Cloud::Channel::V1::VERSION
|
4622
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
4623
|
+
|
4624
|
+
header_params = {}
|
4625
|
+
if request.parent
|
4626
|
+
header_params["parent"] = request.parent
|
4627
|
+
end
|
4628
|
+
|
4629
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
4630
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
4631
|
+
|
4632
|
+
options.apply_defaults timeout: @config.rpcs.list_sku_groups.timeout,
|
4633
|
+
metadata: metadata,
|
4634
|
+
retry_policy: @config.rpcs.list_sku_groups.retry_policy
|
4635
|
+
|
4636
|
+
options.apply_defaults timeout: @config.timeout,
|
4637
|
+
metadata: @config.metadata,
|
4638
|
+
retry_policy: @config.retry_policy
|
4639
|
+
|
4640
|
+
@cloud_channel_service_stub.call_rpc :list_sku_groups, request, options: options do |response, operation|
|
4641
|
+
response = ::Gapic::PagedEnumerable.new @cloud_channel_service_stub, :list_sku_groups, request, response, operation, options
|
4642
|
+
yield response, operation if block_given?
|
4643
|
+
return response
|
4644
|
+
end
|
4645
|
+
rescue ::GRPC::BadStatus => e
|
4646
|
+
raise ::Google::Cloud::Error.from_error(e)
|
4647
|
+
end
|
4648
|
+
|
4649
|
+
##
|
4650
|
+
# Lists the Billable SKUs in a given SKU group.
|
4651
|
+
#
|
4652
|
+
# Possible error codes:
|
4653
|
+
# PERMISSION_DENIED: If the account making the request and the account
|
4654
|
+
# being queried for are different, or the account doesn't exist.
|
4655
|
+
# INVALID_ARGUMENT: Missing or invalid required parameters in the
|
4656
|
+
# request.
|
4657
|
+
# INTERNAL: Any non-user error related to technical issue in the
|
4658
|
+
# backend. In this case, contact cloud channel support.
|
4659
|
+
#
|
4660
|
+
# Return Value:
|
4661
|
+
# If successful, the {::Google::Cloud::Channel::V1::BillableSku BillableSku}
|
4662
|
+
# resources. The data for each resource is displayed in the ascending order
|
4663
|
+
# of:
|
4664
|
+
#
|
4665
|
+
# * {::Google::Cloud::Channel::V1::BillableSku#service_display_name BillableSku.service_display_name}
|
4666
|
+
# * {::Google::Cloud::Channel::V1::BillableSku#sku_display_name BillableSku.sku_display_name}
|
4667
|
+
#
|
4668
|
+
# If unsuccessful, returns an error.
|
4669
|
+
#
|
4670
|
+
# @overload list_sku_group_billable_skus(request, options = nil)
|
4671
|
+
# Pass arguments to `list_sku_group_billable_skus` via a request object, either of type
|
4672
|
+
# {::Google::Cloud::Channel::V1::ListSkuGroupBillableSkusRequest} or an equivalent Hash.
|
4673
|
+
#
|
4674
|
+
# @param request [::Google::Cloud::Channel::V1::ListSkuGroupBillableSkusRequest, ::Hash]
|
4675
|
+
# A request object representing the call parameters. Required. To specify no
|
4676
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
4677
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
4678
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
4679
|
+
#
|
4680
|
+
# @overload list_sku_group_billable_skus(parent: nil, page_size: nil, page_token: nil)
|
4681
|
+
# Pass arguments to `list_sku_group_billable_skus` via keyword arguments. Note that at
|
4682
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
4683
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
4684
|
+
#
|
4685
|
+
# @param parent [::String]
|
4686
|
+
# Required. Resource name of the SKU group.
|
4687
|
+
# Format: accounts/\\{account}/skuGroups/\\{sku_group}.
|
4688
|
+
# @param page_size [::Integer]
|
4689
|
+
# Optional. The maximum number of SKUs to return. The service may return
|
4690
|
+
# fewer than this value. If unspecified, returns a maximum of 100000 SKUs.
|
4691
|
+
# The maximum value is 100000; values above 100000 will be coerced to 100000.
|
4692
|
+
# @param page_token [::String]
|
4693
|
+
# Optional. A token identifying a page of results beyond the first page.
|
4694
|
+
# Obtained through
|
4695
|
+
# [ListSkuGroupBillableSkus.next_page_token][] of the previous
|
4696
|
+
# {::Google::Cloud::Channel::V1::CloudChannelService::Client#list_sku_group_billable_skus CloudChannelService.ListSkuGroupBillableSkus}
|
4697
|
+
# call.
|
4698
|
+
#
|
4699
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
4700
|
+
# @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::Channel::V1::BillableSku>]
|
4701
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
4702
|
+
#
|
4703
|
+
# @return [::Gapic::PagedEnumerable<::Google::Cloud::Channel::V1::BillableSku>]
|
4704
|
+
#
|
4705
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
4706
|
+
#
|
4707
|
+
# @example Basic example
|
4708
|
+
# require "google/cloud/channel/v1"
|
4709
|
+
#
|
4710
|
+
# # Create a client object. The client can be reused for multiple calls.
|
4711
|
+
# client = Google::Cloud::Channel::V1::CloudChannelService::Client.new
|
4712
|
+
#
|
4713
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
4714
|
+
# request = Google::Cloud::Channel::V1::ListSkuGroupBillableSkusRequest.new
|
4715
|
+
#
|
4716
|
+
# # Call the list_sku_group_billable_skus method.
|
4717
|
+
# result = client.list_sku_group_billable_skus request
|
4718
|
+
#
|
4719
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
4720
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
4721
|
+
# result.each do |item|
|
4722
|
+
# # Each element is of type ::Google::Cloud::Channel::V1::BillableSku.
|
4723
|
+
# p item
|
4724
|
+
# end
|
4725
|
+
#
|
4726
|
+
def list_sku_group_billable_skus request, options = nil
|
4727
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
4728
|
+
|
4729
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSkuGroupBillableSkusRequest
|
4730
|
+
|
4731
|
+
# Converts hash and nil to an options object
|
4732
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
4733
|
+
|
4734
|
+
# Customize the options with defaults
|
4735
|
+
metadata = @config.rpcs.list_sku_group_billable_skus.metadata.to_h
|
4736
|
+
|
4737
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
4738
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
4739
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
4740
|
+
gapic_version: ::Google::Cloud::Channel::V1::VERSION
|
4741
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
4742
|
+
|
4743
|
+
header_params = {}
|
4744
|
+
if request.parent
|
4745
|
+
header_params["parent"] = request.parent
|
4746
|
+
end
|
4747
|
+
|
4748
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
4749
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
4750
|
+
|
4751
|
+
options.apply_defaults timeout: @config.rpcs.list_sku_group_billable_skus.timeout,
|
4752
|
+
metadata: metadata,
|
4753
|
+
retry_policy: @config.rpcs.list_sku_group_billable_skus.retry_policy
|
4754
|
+
|
4755
|
+
options.apply_defaults timeout: @config.timeout,
|
4756
|
+
metadata: @config.metadata,
|
4757
|
+
retry_policy: @config.retry_policy
|
4758
|
+
|
4759
|
+
@cloud_channel_service_stub.call_rpc :list_sku_group_billable_skus, request, options: options do |response, operation|
|
4760
|
+
response = ::Gapic::PagedEnumerable.new @cloud_channel_service_stub, :list_sku_group_billable_skus, request, response, operation, options
|
4761
|
+
yield response, operation if block_given?
|
4762
|
+
return response
|
4763
|
+
end
|
4764
|
+
rescue ::GRPC::BadStatus => e
|
4765
|
+
raise ::Google::Cloud::Error.from_error(e)
|
4766
|
+
end
|
4767
|
+
|
4529
4768
|
##
|
4530
4769
|
# Returns the requested {::Google::Cloud::Channel::V1::Offer Offer} resource.
|
4531
4770
|
#
|
@@ -5703,7 +5942,9 @@ module Google
|
|
5703
5942
|
class Configuration
|
5704
5943
|
extend ::Gapic::Config
|
5705
5944
|
|
5706
|
-
|
5945
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
5946
|
+
|
5947
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
5707
5948
|
config_attr :credentials, nil do |value|
|
5708
5949
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
5709
5950
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -5937,6 +6178,16 @@ module Google
|
|
5937
6178
|
#
|
5938
6179
|
attr_reader :delete_channel_partner_repricing_config
|
5939
6180
|
##
|
6181
|
+
# RPC-specific configuration for `list_sku_groups`
|
6182
|
+
# @return [::Gapic::Config::Method]
|
6183
|
+
#
|
6184
|
+
attr_reader :list_sku_groups
|
6185
|
+
##
|
6186
|
+
# RPC-specific configuration for `list_sku_group_billable_skus`
|
6187
|
+
# @return [::Gapic::Config::Method]
|
6188
|
+
#
|
6189
|
+
attr_reader :list_sku_group_billable_skus
|
6190
|
+
##
|
5940
6191
|
# RPC-specific configuration for `lookup_offer`
|
5941
6192
|
# @return [::Gapic::Config::Method]
|
5942
6193
|
#
|
@@ -6061,6 +6312,10 @@ module Google
|
|
6061
6312
|
@update_channel_partner_repricing_config = ::Gapic::Config::Method.new update_channel_partner_repricing_config_config
|
6062
6313
|
delete_channel_partner_repricing_config_config = parent_rpcs.delete_channel_partner_repricing_config if parent_rpcs.respond_to? :delete_channel_partner_repricing_config
|
6063
6314
|
@delete_channel_partner_repricing_config = ::Gapic::Config::Method.new delete_channel_partner_repricing_config_config
|
6315
|
+
list_sku_groups_config = parent_rpcs.list_sku_groups if parent_rpcs.respond_to? :list_sku_groups
|
6316
|
+
@list_sku_groups = ::Gapic::Config::Method.new list_sku_groups_config
|
6317
|
+
list_sku_group_billable_skus_config = parent_rpcs.list_sku_group_billable_skus if parent_rpcs.respond_to? :list_sku_group_billable_skus
|
6318
|
+
@list_sku_group_billable_skus = ::Gapic::Config::Method.new list_sku_group_billable_skus_config
|
6064
6319
|
lookup_offer_config = parent_rpcs.lookup_offer if parent_rpcs.respond_to? :lookup_offer
|
6065
6320
|
@lookup_offer = ::Gapic::Config::Method.new lookup_offer_config
|
6066
6321
|
list_products_config = parent_rpcs.list_products if parent_rpcs.respond_to? :list_products
|
@@ -664,7 +664,9 @@ module Google
|
|
664
664
|
class Configuration
|
665
665
|
extend ::Gapic::Config
|
666
666
|
|
667
|
-
|
667
|
+
DEFAULT_ENDPOINT = "cloudchannel.googleapis.com"
|
668
|
+
|
669
|
+
config_attr :endpoint, DEFAULT_ENDPOINT, ::String
|
668
670
|
config_attr :credentials, nil do |value|
|
669
671
|
allowed = [::String, ::Hash, ::Proc, ::Symbol, ::Google::Auth::Credentials, ::Signet::OAuth2::Client, nil]
|
670
672
|
allowed += [::GRPC::Core::Channel, ::GRPC::Core::ChannelCredentials] if defined? ::GRPC
|
@@ -146,6 +146,23 @@ module Google
|
|
146
146
|
"products/#{product}"
|
147
147
|
end
|
148
148
|
|
149
|
+
##
|
150
|
+
# Create a fully-qualified SkuGroup resource string.
|
151
|
+
#
|
152
|
+
# The resource will be in the following format:
|
153
|
+
#
|
154
|
+
# `accounts/{account}/skuGroups/{sku_group}`
|
155
|
+
#
|
156
|
+
# @param account [String]
|
157
|
+
# @param sku_group [String]
|
158
|
+
#
|
159
|
+
# @return [::String]
|
160
|
+
def sku_group_path account:, sku_group:
|
161
|
+
raise ::ArgumentError, "account cannot contain /" if account.to_s.include? "/"
|
162
|
+
|
163
|
+
"accounts/#{account}/skuGroups/#{sku_group}"
|
164
|
+
end
|
165
|
+
|
149
166
|
extend self
|
150
167
|
end
|
151
168
|
end
|