Class: Google::Cloud::Channel::V1::CloudChannelService::Rest::Client
- Inherits:
-
Object
- Object
- Google::Cloud::Channel::V1::CloudChannelService::Rest::Client
- Includes:
- Paths
- Defined in:
- lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb
Overview
REST client for the CloudChannelService service.
CloudChannelService lets Google cloud resellers and distributors manage their customers, channel partners, entitlements, and reports.
Using this service:
- Resellers and distributors can manage a customer entity.
- Distributors can register an authorized reseller in their channel and provide them with delegated admin access.
- Resellers and distributors can manage customer entitlements.
CloudChannelService exposes the following resources:
Customers: An entity-usually an enterprise-managed by a reseller or distributor.
Entitlements: An entity that provides a customer with the means to use a service. Entitlements are created or updated as a result of a successful fulfillment.
ChannelPartnerLinks: An entity that identifies links between distributors and their indirect resellers in a channel.
Defined Under Namespace
Classes: Configuration
Instance Attribute Summary collapse
-
#operations_client ⇒ ::Google::Cloud::Channel::V1::CloudChannelService::Rest::Operations
readonly
Get the associated client for long-running operations.
Class Method Summary collapse
-
.configure {|config| ... } ⇒ Client::Configuration
Configure the CloudChannelService Client class.
Instance Method Summary collapse
-
#activate_entitlement(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Activates a previously suspended entitlement.
-
#cancel_entitlement(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Cancels a previously fulfilled entitlement.
-
#change_offer(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Updates the Offer for an existing customer entitlement.
-
#change_parameters(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Change parameters of the entitlement.
-
#change_renewal_settings(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Updates the renewal settings for an existing customer entitlement.
-
#check_cloud_identity_accounts_exist(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::CheckCloudIdentityAccountsExistResponse
Confirms the existence of Cloud Identity accounts based on the domain and if the Cloud Identity accounts are owned by the reseller.
-
#configure {|config| ... } ⇒ Client::Configuration
Configure the CloudChannelService Client instance.
-
#create_channel_partner_link(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Initiates a channel partner link between a distributor and a reseller, or between resellers in an n-tier reseller channel.
-
#create_channel_partner_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Creates a ChannelPartnerRepricingConfig.
-
#create_customer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Customer
Creates a new Customer resource under the reseller or distributor account.
-
#create_customer_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Creates a CustomerRepricingConfig.
-
#create_entitlement(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Creates an entitlement for a customer.
-
#delete_channel_partner_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Deletes the given ChannelPartnerRepricingConfig permanently.
-
#delete_customer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Deletes the given Customer permanently.
-
#delete_customer_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Protobuf::Empty
Deletes the given CustomerRepricingConfig permanently.
-
#get_channel_partner_link(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Returns the requested ChannelPartnerLink resource.
-
#get_channel_partner_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Gets information about how a Distributor modifies their bill before sending it to a ChannelPartner.
-
#get_customer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Customer
Returns the requested Customer resource.
-
#get_customer_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Gets information about how a Reseller modifies their bill before sending it to a Customer.
-
#get_entitlement(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Entitlement
Returns the requested Entitlement resource.
-
#import_customer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Customer
Imports a Customer from the Cloud Identity associated with the provided Cloud Identity ID or domain before a TransferEntitlements call.
-
#initialize {|config| ... } ⇒ Client
constructor
Create a new CloudChannelService REST client object.
-
#list_channel_partner_links(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerLink>
List ChannelPartnerLinks belonging to a distributor.
-
#list_channel_partner_repricing_configs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig>
Lists information about how a Reseller modifies their bill before sending it to a ChannelPartner.
-
#list_customer_repricing_configs(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::CustomerRepricingConfig>
Lists information about how a Reseller modifies their bill before sending it to a Customer.
-
#list_customers(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Customer>
List Customers.
-
#list_entitlement_changes(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::EntitlementChange>
List entitlement history.
-
#list_entitlements(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Entitlement>
Lists Entitlements belonging to a customer.
-
#list_offers(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Offer>
Lists the Offers the reseller can sell.
-
#list_products(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Product>
Lists the Products the reseller is authorized to sell.
-
#list_purchasable_offers(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableOffer>
Lists the following:.
-
#list_purchasable_skus(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableSku>
Lists the following:.
-
#list_sku_group_billable_skus(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::BillableSku>
Lists the Billable SKUs in a given SKU group.
-
#list_sku_groups(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::SkuGroup>
Lists the Rebilling supported SKU groups the account is authorized to sell.
-
#list_skus(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Sku>
Lists the SKUs for a product the reseller is authorized to sell.
-
#list_subscribers(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::String>
Lists service accounts with subscriber privileges on the Cloud Pub/Sub topic created for this Channel Services account.
-
#list_transferable_offers(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableOffer>
List TransferableOffers of a customer based on Cloud Identity ID or Customer Name in the request.
-
#list_transferable_skus(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableSku>
List TransferableSkus of a customer based on the Cloud Identity ID or Customer Name in the request.
-
#lookup_offer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Offer
Returns the requested Offer resource.
-
#provision_cloud_identity(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Creates a Cloud Identity for the given customer using the customer's information, or the information provided here.
-
#register_subscriber(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::RegisterSubscriberResponse
Registers a service account with subscriber privileges on the Cloud Pub/Sub topic for this Channel Services account.
-
#start_paid_service(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Starts paid service for a trial entitlement.
-
#suspend_entitlement(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Suspends a previously fulfilled entitlement.
-
#transfer_entitlements(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Transfers customer entitlements to new reseller.
-
#transfer_entitlements_to_google(request, options = nil) {|result, operation| ... } ⇒ ::Gapic::Operation
Transfers customer entitlements from their current reseller to Google.
-
#unregister_subscriber(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::UnregisterSubscriberResponse
Unregisters a service account with subscriber privileges on the Cloud Pub/Sub topic created for this Channel Services account.
-
#update_channel_partner_link(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Updates a channel partner link.
-
#update_channel_partner_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Updates a ChannelPartnerRepricingConfig.
-
#update_customer(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::Customer
Updates an existing Customer resource for the reseller or distributor.
-
#update_customer_repricing_config(request, options = nil) {|result, operation| ... } ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Updates a CustomerRepricingConfig.
Methods included from Paths
#channel_partner_link_path, #channel_partner_repricing_config_path, #customer_path, #customer_repricing_config_path, #entitlement_path, #offer_path, #product_path, #sku_group_path
Constructor Details
#initialize {|config| ... } ⇒ Client
Create a new CloudChannelService REST client object.
157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 157 def initialize # Create the configuration object @config = Configuration.new Client.configure # Yield the configuration if needed yield @config if block_given? # Create credentials credentials = @config.credentials # Use self-signed JWT if the endpoint is unchanged from default, # but only if the default endpoint does not have a region prefix. enable_self_signed_jwt = @config.endpoint == Configuration::DEFAULT_ENDPOINT && !@config.endpoint.split(".").first.include?("-") credentials ||= Credentials.default scope: @config.scope, enable_self_signed_jwt: enable_self_signed_jwt if credentials.is_a?(::String) || credentials.is_a?(::Hash) credentials = Credentials.new credentials, scope: @config.scope end @quota_project_id = @config.quota_project @quota_project_id ||= credentials.quota_project_id if credentials.respond_to? :quota_project_id @operations_client = ::Google::Cloud::Channel::V1::CloudChannelService::Rest::Operations.new do |config| config.credentials = credentials config.quota_project = @quota_project_id config.endpoint = @config.endpoint end @cloud_channel_service_stub = ::Google::Cloud::Channel::V1::CloudChannelService::Rest::ServiceStub.new endpoint: @config.endpoint, credentials: credentials end |
Instance Attribute Details
#operations_client ⇒ ::Google::Cloud::Channel::V1::CloudChannelService::Rest::Operations (readonly)
Get the associated client for long-running operations.
193 194 195 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 193 def operations_client @operations_client end |
Class Method Details
.configure {|config| ... } ⇒ Client::Configuration
Configure the CloudChannelService Client class.
See Configuration for a description of the configuration fields.
77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 77 def self.configure @configure ||= begin namespace = ["Google", "Cloud", "Channel", "V1"] parent_config = while namespace.any? parent_name = namespace.join "::" parent_const = const_get parent_name break parent_const.configure if parent_const.respond_to? :configure namespace.pop end default_config = Client::Configuration.new parent_config default_config.timeout = 60.0 default_config.retry_policy = { initial_delay: 1.0, max_delay: 10.0, multiplier: 1.3, retry_codes: [14] } default_config.rpcs.provision_cloud_identity.timeout = 60.0 default_config.rpcs.create_entitlement.timeout = 60.0 default_config.rpcs.change_parameters.timeout = 60.0 default_config.rpcs.change_renewal_settings.timeout = 60.0 default_config.rpcs.change_offer.timeout = 60.0 default_config.rpcs.start_paid_service.timeout = 60.0 default_config.rpcs.suspend_entitlement.timeout = 60.0 default_config.rpcs.cancel_entitlement.timeout = 60.0 default_config.rpcs.activate_entitlement.timeout = 60.0 default_config.rpcs.transfer_entitlements.timeout = 60.0 default_config.rpcs.transfer_entitlements_to_google.timeout = 60.0 default_config end yield @configure if block_given? @configure end |
Instance Method Details
#activate_entitlement(request, options = nil) ⇒ ::Gapic::Operation #activate_entitlement(name: nil, request_id: nil) ⇒ ::Gapic::Operation
Activates a previously suspended entitlement. Entitlements suspended for pending ToS acceptance can't be activated using this method.
An entitlement activation is a long-running operation and it updates the state of the customer entitlement.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Entitlement resource not found.
- SUSPENSION_NOT_RESELLER_INITIATED: Can only activate reseller-initiated suspensions and entitlements that have accepted the TOS.
- NOT_SUSPENDED: Can only activate suspended entitlements not in an ACTIVE state.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2041 def activate_entitlement request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ActivateEntitlementRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.activate_entitlement..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.activate_entitlement.timeout, metadata: , retry_policy: @config.rpcs.activate_entitlement.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.activate_entitlement request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#cancel_entitlement(request, options = nil) ⇒ ::Gapic::Operation #cancel_entitlement(name: nil, request_id: nil) ⇒ ::Gapic::Operation
Cancels a previously fulfilled entitlement.
An entitlement cancellation is a long-running operation.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- FAILED_PRECONDITION: There are Google Cloud projects linked to the Google Cloud entitlement's Cloud Billing subaccount.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Entitlement resource not found.
- DELETION_TYPE_NOT_ALLOWED: Cancel is only allowed for Google Workspace add-ons, or entitlements for Google Cloud's development platform.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The response will contain google.protobuf.Empty on success. The Operation metadata will contain an instance of OperationMetadata.
1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1937 def cancel_entitlement request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CancelEntitlementRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.cancel_entitlement..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.cancel_entitlement.timeout, metadata: , retry_policy: @config.rpcs.cancel_entitlement.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.cancel_entitlement request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#change_offer(request, options = nil) ⇒ ::Gapic::Operation #change_offer(name: nil, offer: nil, parameters: nil, purchase_order_id: nil, request_id: nil) ⇒ ::Gapic::Operation
Updates the Offer for an existing customer entitlement.
An entitlement update is a long-running operation and it updates the entitlement as a result of fulfillment.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Offer or Entitlement resource not found.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1635 def change_offer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ChangeOfferRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.change_offer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.change_offer.timeout, metadata: , retry_policy: @config.rpcs.change_offer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.change_offer request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#change_parameters(request, options = nil) ⇒ ::Gapic::Operation #change_parameters(name: nil, parameters: nil, request_id: nil, purchase_order_id: nil) ⇒ ::Gapic::Operation
Change parameters of the entitlement.
An entitlement update is a long-running operation and it updates the entitlement as a result of fulfillment.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid. For example, the number of seats being changed is greater than the allowed number of max seats, or decreasing seats for a commitment based plan.
- NOT_FOUND: Entitlement resource not found.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1425 def change_parameters request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ChangeParametersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.change_parameters..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.change_parameters.timeout, metadata: , retry_policy: @config.rpcs.change_parameters.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.change_parameters request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#change_renewal_settings(request, options = nil) ⇒ ::Gapic::Operation #change_renewal_settings(name: nil, renewal_settings: nil, request_id: nil) ⇒ ::Gapic::Operation
Updates the renewal settings for an existing customer entitlement.
An entitlement update is a long-running operation and it updates the entitlement as a result of fulfillment.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Entitlement resource not found.
- NOT_COMMITMENT_PLAN: Renewal Settings are only applicable for a commitment plan. Can't enable or disable renewals for non-commitment plans.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1527 def change_renewal_settings request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ChangeRenewalSettingsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.change_renewal_settings..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.change_renewal_settings.timeout, metadata: , retry_policy: @config.rpcs.change_renewal_settings.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.change_renewal_settings request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#check_cloud_identity_accounts_exist(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::CheckCloudIdentityAccountsExistResponse #check_cloud_identity_accounts_exist(parent: nil, domain: nil) ⇒ ::Google::Cloud::Channel::V1::CheckCloudIdentityAccountsExistResponse
Confirms the existence of Cloud Identity accounts based on the domain and if the Cloud Identity accounts are owned by the reseller.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- INVALID_VALUE: Invalid domain value in the request.
Return value: A list of CloudIdentityCustomerAccount resources for the domain (may be empty)
Note: in the v1alpha1 version of the API, a NOT_FOUND error returns if no CloudIdentityCustomerAccount resources match the domain.
410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 410 def check_cloud_identity_accounts_exist request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CheckCloudIdentityAccountsExistRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.check_cloud_identity_accounts_exist..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.check_cloud_identity_accounts_exist.timeout, metadata: , retry_policy: @config.rpcs.check_cloud_identity_accounts_exist.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.check_cloud_identity_accounts_exist request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#configure {|config| ... } ⇒ Client::Configuration
Configure the CloudChannelService Client instance.
The configuration is set to the derived mode, meaning that values can be changed, but structural changes (adding new fields, etc.) are not allowed. Structural changes should be made on configure.
See Configuration for a description of the configuration fields.
136 137 138 139 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 136 def configure yield @config if block_given? @config end |
#create_channel_partner_link(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink #create_channel_partner_link(parent: nil, channel_partner_link: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Initiates a channel partner link between a distributor and a reseller, or between resellers in an n-tier reseller channel. Invited partners need to follow the invite_link_uri provided in the response to accept. After accepting the invitation, a link is set up between the two parties. You must be a distributor to call this method.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- ALREADY_EXISTS: The ChannelPartnerLink sent in the request already exists.
- NOT_FOUND: No Cloud Identity customer exists for provided domain.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The new ChannelPartnerLink resource.
2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2521 def create_channel_partner_link request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CreateChannelPartnerLinkRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_channel_partner_link..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_channel_partner_link.timeout, metadata: , retry_policy: @config.rpcs.create_channel_partner_link.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.create_channel_partner_link request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_channel_partner_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig #create_channel_partner_repricing_config(parent: nil, channel_partner_repricing_config: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Creates a ChannelPartnerRepricingConfig. Call this method to set modifications for a specific ChannelPartner's bill. You can only create configs if the RepricingConfig.effective_invoice_month is a future month. If needed, you can create a config for the current month, with some restrictions.
When creating a config for a future month, make sure there are no existing configs for that RepricingConfig.effective_invoice_month.
The following restrictions are for creating configs in the current month.
- This functionality is reserved for recovering from an erroneous config, and should not be used for regular business cases.
- The new config will not modify exports used with other configs. Changes to the config may be immediate, but may take up to 24 hours.
- There is a limit of ten configs for any ChannelPartner or RepricingConfig.effective_invoice_month.
- The contained ChannelPartnerRepricingConfig.repricing_config vaule must be different from the value used in the current config for a ChannelPartner.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- INVALID_ARGUMENT: Missing or invalid required parameters in the request. Also displays if the updated config is for the current month or past months.
- NOT_FOUND: The ChannelPartnerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the updated ChannelPartnerRepricingConfig resource, otherwise returns an error.
3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3380 def create_channel_partner_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CreateChannelPartnerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_channel_partner_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_channel_partner_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.create_channel_partner_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.create_channel_partner_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_customer(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Customer #create_customer(parent: nil, customer: nil) ⇒ ::Google::Cloud::Channel::V1::Customer
Creates a new Customer resource under the reseller or distributor account.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT:
- Required request parameters are missing or invalid.
- Domain field value doesn't match the primary email domain.
Return value: The newly created Customer resource.
487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 487 def create_customer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CreateCustomerRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_customer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_customer.timeout, metadata: , retry_policy: @config.rpcs.create_customer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.create_customer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_customer_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig #create_customer_repricing_config(parent: nil, customer_repricing_config: nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Creates a CustomerRepricingConfig. Call this method to set modifications for a specific customer's bill. You can only create configs if the RepricingConfig.effective_invoice_month is a future month. If needed, you can create a config for the current month, with some restrictions.
When creating a config for a future month, make sure there are no existing configs for that RepricingConfig.effective_invoice_month.
The following restrictions are for creating configs in the current month.
- This functionality is reserved for recovering from an erroneous config, and should not be used for regular business cases.
- The new config will not modify exports used with other configs. Changes to the config may be immediate, but may take up to 24 hours.
- There is a limit of ten configs for any RepricingConfig.EntitlementGranularity.entitlement or RepricingConfig.effective_invoice_month.
- The contained CustomerRepricingConfig.repricing_config vaule must be different from the value used in the current config for a RepricingConfig.EntitlementGranularity.entitlement.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- INVALID_ARGUMENT: Missing or invalid required parameters in the request. Also displays if the updated config is for the current month or past months.
- NOT_FOUND: The CustomerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the updated CustomerRepricingConfig resource, otherwise returns an error.
2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2909 def create_customer_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CreateCustomerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_customer_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_customer_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.create_customer_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.create_customer_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#create_entitlement(request, options = nil) ⇒ ::Gapic::Operation #create_entitlement(parent: nil, entitlement: nil, request_id: nil) ⇒ ::Gapic::Operation
Creates an entitlement for a customer.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT:
- Required request parameters are missing or invalid.
- There is already a customer entitlement for a SKU from the same product family.
- INVALID_VALUE: Make sure the OfferId is valid. If it is, contact Google Channel support for further troubleshooting.
- NOT_FOUND: The customer or offer resource was not found.
- ALREADY_EXISTS:
- The SKU was already purchased for the customer.
- The customer's primary email already exists. Retry after changing the customer's primary contact email.
- CONDITION_NOT_MET or FAILED_PRECONDITION:
- The domain required for purchasing a SKU has not been verified.
- A pre-requisite SKU required to purchase an Add-On SKU is missing. For example, Google Workspace Business Starter is required to purchase Vault or Drive.
- (Developer accounts only) Reseller and resold domain must meet the
following naming requirements:
- Domain names must start with goog-test.
- Domain names must include the reseller domain.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1316 def create_entitlement request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::CreateEntitlementRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.create_entitlement..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.create_entitlement.timeout, metadata: , retry_policy: @config.rpcs.create_entitlement.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.create_entitlement request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_channel_partner_repricing_config(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_channel_partner_repricing_config(name: nil) ⇒ ::Google::Protobuf::Empty
Deletes the given ChannelPartnerRepricingConfig permanently. You can only delete configs if their RepricingConfig.effective_invoice_month is set to a date after the current month.
Possible error codes:
- PERMISSION_DENIED: The account making the request does not own this customer.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- FAILED_PRECONDITION: The ChannelPartnerRepricingConfig is active or in the past.
- NOT_FOUND: No ChannelPartnerRepricingConfig found for the name in the request.
3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3552 def delete_channel_partner_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::DeleteChannelPartnerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_channel_partner_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_channel_partner_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.delete_channel_partner_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.delete_channel_partner_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_customer(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_customer(name: nil) ⇒ ::Google::Protobuf::Empty
Deletes the given Customer permanently.
Possible error codes:
- PERMISSION_DENIED: The account making the request does not own this customer.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- FAILED_PRECONDITION: The customer has existing entitlements.
- NOT_FOUND: No Customer resource found for the name in the request.
635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 635 def delete_customer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::DeleteCustomerRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_customer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_customer.timeout, metadata: , retry_policy: @config.rpcs.delete_customer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.delete_customer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#delete_customer_repricing_config(request, options = nil) ⇒ ::Google::Protobuf::Empty #delete_customer_repricing_config(name: nil) ⇒ ::Google::Protobuf::Empty
Deletes the given CustomerRepricingConfig permanently. You can only delete configs if their RepricingConfig.effective_invoice_month is set to a date after the current month.
Possible error codes:
- PERMISSION_DENIED: The account making the request does not own this customer.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- FAILED_PRECONDITION: The CustomerRepricingConfig is active or in the past.
- NOT_FOUND: No CustomerRepricingConfig found for the name in the request.
3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3082 def delete_customer_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::DeleteCustomerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.delete_customer_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.delete_customer_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.delete_customer_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.delete_customer_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_channel_partner_link(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink #get_channel_partner_link(name: nil, view: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Returns the requested ChannelPartnerLink resource. You must be a distributor to call this method.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: ChannelPartnerLink resource not found because of an invalid channel partner link name.
Return value: The ChannelPartnerLink resource.
2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2431 def get_channel_partner_link request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::GetChannelPartnerLinkRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_channel_partner_link..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_channel_partner_link.timeout, metadata: , retry_policy: @config.rpcs.get_channel_partner_link.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.get_channel_partner_link request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_channel_partner_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig #get_channel_partner_repricing_config(name: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Gets information about how a Distributor modifies their bill before sending it to a ChannelPartner.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- NOT_FOUND: The ChannelPartnerRepricingConfig was not found.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the ChannelPartnerRepricingConfig resource, otherwise returns an error.
3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3162 def get_channel_partner_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::GetChannelPartnerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_channel_partner_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_channel_partner_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.get_channel_partner_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.get_channel_partner_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_customer(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Customer #get_customer(name: nil) ⇒ ::Google::Cloud::Channel::V1::Customer
Returns the requested Customer resource.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer resource doesn't exist. Usually the result of an invalid name parameter.
Return value: The Customer resource.
327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 327 def get_customer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::GetCustomerRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_customer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_customer.timeout, metadata: , retry_policy: @config.rpcs.get_customer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.get_customer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_customer_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig #get_customer_repricing_config(name: nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Gets information about how a Reseller modifies their bill before sending it to a Customer.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- NOT_FOUND: The CustomerRepricingConfig was not found.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the CustomerRepricingConfig resource, otherwise returns an error.
2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2693 def get_customer_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::GetCustomerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_customer_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_customer_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.get_customer_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.get_customer_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#get_entitlement(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Entitlement #get_entitlement(name: nil) ⇒ ::Google::Cloud::Channel::V1::Entitlement
Returns the requested Entitlement resource.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer entitlement was not found.
Return value: The requested Entitlement resource.
1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1202 def get_entitlement request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::GetEntitlementRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.get_entitlement..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.get_entitlement.timeout, metadata: , retry_policy: @config.rpcs.get_entitlement.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.get_entitlement request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#import_customer(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Customer #import_customer(domain: nil, cloud_identity_id: nil, parent: nil, auth_token: nil, overwrite_if_exists: nil, channel_partner_id: nil, customer: nil) ⇒ ::Google::Cloud::Channel::V1::Customer
Imports a Customer from the Cloud Identity associated with the provided Cloud Identity ID or domain before a TransferEntitlements call. If a linked Customer already exists and overwrite_if_exists is true, it will update that Customer's data.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- NOT_FOUND: Cloud Identity doesn't exist or was deleted.
- INVALID_ARGUMENT: Required parameters are missing, or the auth_token is expired or invalid.
- ALREADY_EXISTS: A customer already exists and has conflicting critical fields. Requires an overwrite.
Return value: The Customer.
737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 737 def import_customer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ImportCustomerRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.import_customer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.import_customer.timeout, metadata: , retry_policy: @config.rpcs.import_customer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.import_customer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_channel_partner_links(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerLink> #list_channel_partner_links(parent: nil, page_size: nil, page_token: nil, view: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerLink>
List ChannelPartnerLinks belonging to a distributor. You must be a distributor to call this method.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
Return value: The list of the distributor account's ChannelPartnerLink resources.
2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2350 def list_channel_partner_links request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListChannelPartnerLinksRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_channel_partner_links..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_channel_partner_links.timeout, metadata: , retry_policy: @config.rpcs.list_channel_partner_links.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_channel_partner_links request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_channel_partner_links, "channel_partner_links", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_channel_partner_repricing_configs(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig> #list_channel_partner_repricing_configs(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig>
Lists information about how a Reseller modifies their bill before sending it to a ChannelPartner.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- NOT_FOUND: The ChannelPartnerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the ChannelPartnerRepricingConfig resources. The data for each resource is displayed in the ascending order of:
- Channel Partner ID
- RepricingConfig.effective_invoice_month
- ChannelPartnerRepricingConfig.update_time
If unsuccessful, returns an error.
3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3273 def list_channel_partner_repricing_configs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListChannelPartnerRepricingConfigsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_channel_partner_repricing_configs..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_channel_partner_repricing_configs.timeout, metadata: , retry_policy: @config.rpcs.list_channel_partner_repricing_configs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_channel_partner_repricing_configs request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_channel_partner_repricing_configs, "channel_partner_repricing_configs", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_customer_repricing_configs(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::CustomerRepricingConfig> #list_customer_repricing_configs(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::CustomerRepricingConfig>
Lists information about how a Reseller modifies their bill before sending it to a Customer.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- NOT_FOUND: The CustomerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the CustomerRepricingConfig resources. The data for each resource is displayed in the ascending order of:
- Customer ID
- RepricingConfig.EntitlementGranularity.entitlement
- RepricingConfig.effective_invoice_month
- CustomerRepricingConfig.update_time
If unsuccessful, returns an error.
2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2801 def list_customer_repricing_configs request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListCustomerRepricingConfigsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_customer_repricing_configs..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_customer_repricing_configs.timeout, metadata: , retry_policy: @config.rpcs.list_customer_repricing_configs.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_customer_repricing_configs request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_customer_repricing_configs, "customer_repricing_configs", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_customers(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Customer> #list_customers(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Customer>
List Customers.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
Return value: List of Customers, or an empty list if there are no customers.
251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 251 def list_customers request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListCustomersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_customers..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_customers.timeout, metadata: , retry_policy: @config.rpcs.list_customers.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_customers request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_customers, "customers", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_entitlement_changes(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::EntitlementChange> #list_entitlement_changes(parent: nil, page_size: nil, page_token: nil, filter: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::EntitlementChange>
List entitlement history.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request and the provided reseller account are different.
- INVALID_ARGUMENT: Missing or invalid required fields in the request.
- NOT_FOUND: The parent resource doesn't exist. Usually the result of an invalid name parameter.
- INTERNAL: Any non-user error related to a technical issue in the backend. In this case, contact CloudChannel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. In this case, contact Cloud Channel support.
Return value: List of EntitlementChanges.
4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4586 def list_entitlement_changes request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListEntitlementChangesRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_entitlement_changes..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_entitlement_changes.timeout, metadata: , retry_policy: @config.rpcs.list_entitlement_changes.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_entitlement_changes request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_entitlement_changes, "entitlement_changes", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_entitlements(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Entitlement> #list_entitlements(parent: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Entitlement>
Lists Entitlements belonging to a customer.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
Return value: A list of the customer's Entitlements.
912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 912 def list_entitlements request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListEntitlementsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_entitlements..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_entitlements.timeout, metadata: , retry_policy: @config.rpcs.list_entitlements.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_entitlements request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_entitlements, "entitlements", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_offers(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Offer> #list_offers(parent: nil, page_size: nil, page_token: nil, filter: nil, language_code: nil, show_future_offers: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Offer>
Lists the Offers the reseller can sell.
Possible error codes:
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4059 def list_offers request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListOffersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_offers..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_offers.timeout, metadata: , retry_policy: @config.rpcs.list_offers.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_offers request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_offers, "offers", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_products(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Product> #list_products(account: nil, page_size: nil, page_token: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Product>
Lists the Products the reseller is authorized to sell.
Possible error codes:
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3887 def list_products request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListProductsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_products..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_products.timeout, metadata: , retry_policy: @config.rpcs.list_products.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_products request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_products, "products", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_purchasable_offers(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableOffer> #list_purchasable_offers(create_entitlement_purchase: nil, change_offer_purchase: nil, customer: nil, page_size: nil, page_token: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableOffer>
Lists the following:
- Offers that you can purchase for a customer.
- Offers that you can change for an entitlement.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4231 def list_purchasable_offers request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListPurchasableOffersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_purchasable_offers..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_purchasable_offers.timeout, metadata: , retry_policy: @config.rpcs.list_purchasable_offers.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_purchasable_offers request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_purchasable_offers, "purchasable_offers", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_purchasable_skus(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableSku> #list_purchasable_skus(create_entitlement_purchase: nil, change_offer_purchase: nil, customer: nil, page_size: nil, page_token: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::PurchasableSku>
Lists the following:
- SKUs that you can purchase for a customer
- SKUs that you can upgrade or downgrade for an entitlement.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4145 def list_purchasable_skus request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListPurchasableSkusRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_purchasable_skus..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_purchasable_skus.timeout, metadata: , retry_policy: @config.rpcs.list_purchasable_skus.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_purchasable_skus request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_purchasable_skus, "purchasable_skus", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_sku_group_billable_skus(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::BillableSku> #list_sku_group_billable_skus(parent: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::BillableSku>
Lists the Billable SKUs in a given SKU group.
Possible error codes: PERMISSION_DENIED: If the account making the request and the account being queried for are different, or the account doesn't exist. INVALID_ARGUMENT: Missing or invalid required parameters in the request. INTERNAL: Any non-user error related to technical issue in the backend. In this case, contact cloud channel support.
Return Value: If successful, the BillableSku resources. The data for each resource is displayed in the ascending order of:
If unsuccessful, returns an error.
3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3736 def list_sku_group_billable_skus request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSkuGroupBillableSkusRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_sku_group_billable_skus..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_sku_group_billable_skus.timeout, metadata: , retry_policy: @config.rpcs.list_sku_group_billable_skus.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_sku_group_billable_skus request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_sku_group_billable_skus, "billable_skus", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_sku_groups(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::SkuGroup> #list_sku_groups(parent: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::SkuGroup>
Lists the Rebilling supported SKU groups the account is authorized to sell. Reference: https://cloud.google.com/skus/sku-groups
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different, or the account doesn't exist.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the SkuGroup resources. The data for each resource is displayed in the alphabetical order of SKU group display name. The data for each resource is displayed in the ascending order of SkuGroup.display_name
If unsuccessful, returns an error.
3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3644 def list_sku_groups request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSkuGroupsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_sku_groups..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_sku_groups.timeout, metadata: , retry_policy: @config.rpcs.list_sku_groups.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_sku_groups request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_sku_groups, "sku_groups", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_skus(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Sku> #list_skus(parent: nil, account: nil, page_size: nil, page_token: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::Sku>
Lists the SKUs for a product the reseller is authorized to sell.
Possible error codes:
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3970 def list_skus request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSkusRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_skus..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_skus.timeout, metadata: , retry_policy: @config.rpcs.list_skus.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_skus request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_skus, "skus", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_subscribers(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::String> #list_subscribers(account: nil, page_size: nil, page_token: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::String>
Lists service accounts with subscriber privileges on the Cloud Pub/Sub topic created for this Channel Services account.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request and the provided reseller account are different, or the impersonated user is not a super admin.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The topic resource doesn't exist.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: A list of service email addresses.
4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4488 def list_subscribers request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListSubscribersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_subscribers..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_subscribers.timeout, metadata: , retry_policy: @config.rpcs.list_subscribers.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_subscribers request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_subscribers, "service_accounts", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_transferable_offers(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableOffer> #list_transferable_offers(cloud_identity_id: nil, customer_name: nil, parent: nil, page_size: nil, page_token: nil, sku: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableOffer>
List TransferableOffers of a customer based on Cloud Identity ID or Customer Name in the request.
Use this method when a reseller gets the entitlement information of an unowned customer. The reseller should provide the customer's Cloud Identity ID or Customer Name.
Possible error codes:
- PERMISSION_DENIED:
- The customer doesn't belong to the reseller and has no auth token.
- The customer provided incorrect reseller information when generating auth token.
- The reseller account making the request is different from the reseller account in the query.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
Return value: List of TransferableOffer for the given customer and SKU.
1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1127 def list_transferable_offers request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListTransferableOffersRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_transferable_offers..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_transferable_offers.timeout, metadata: , retry_policy: @config.rpcs.list_transferable_offers.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_transferable_offers request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_transferable_offers, "transferable_offers", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#list_transferable_skus(request, options = nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableSku> #list_transferable_skus(cloud_identity_id: nil, customer_name: nil, parent: nil, page_size: nil, page_token: nil, auth_token: nil, language_code: nil) ⇒ ::Gapic::Rest::PagedEnumerable<::Google::Cloud::Channel::V1::TransferableSku>
List TransferableSkus of a customer based on the Cloud Identity ID or Customer Name in the request.
Use this method to list the entitlements information of an unowned customer. You should provide the customer's Cloud Identity ID or Customer Name.
Possible error codes:
- PERMISSION_DENIED:
- The customer doesn't belong to the reseller and has no auth token.
- The supplied auth token is invalid.
- The reseller account making the request is different from the reseller account in the query.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
Return value: A list of the customer's TransferableSku.
1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1023 def list_transferable_skus request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ListTransferableSkusRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.list_transferable_skus..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.list_transferable_skus.timeout, metadata: , retry_policy: @config.rpcs.list_transferable_skus.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.list_transferable_skus request, do |result, operation| result = ::Gapic::Rest::PagedEnumerable.new @cloud_channel_service_stub, :list_transferable_skus, "transferable_skus", request, result, yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#lookup_offer(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Offer #lookup_offer(entitlement: nil) ⇒ ::Google::Cloud::Channel::V1::Offer
3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3810 def lookup_offer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::LookupOfferRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.lookup_offer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.lookup_offer.timeout, metadata: , retry_policy: @config.rpcs.lookup_offer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.lookup_offer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#provision_cloud_identity(request, options = nil) ⇒ ::Gapic::Operation #provision_cloud_identity(customer: nil, cloud_identity_info: nil, user: nil, validate_only: nil) ⇒ ::Gapic::Operation
Creates a Cloud Identity for the given customer using the customer's information, or the information provided here.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer was not found.
- ALREADY_EXISTS: The customer's primary email already exists. Retry after changing the customer's primary contact email.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata contains an instance of OperationMetadata.
826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 826 def provision_cloud_identity request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::ProvisionCloudIdentityRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.provision_cloud_identity..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.provision_cloud_identity.timeout, metadata: , retry_policy: @config.rpcs.provision_cloud_identity.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.provision_cloud_identity request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#register_subscriber(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::RegisterSubscriberResponse #register_subscriber(account: nil, service_account: nil) ⇒ ::Google::Cloud::Channel::V1::RegisterSubscriberResponse
Registers a service account with subscriber privileges on the Cloud Pub/Sub topic for this Channel Services account. After you create a subscriber, you get the events through SubscriberEvent
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request and the provided reseller account are different, or the impersonated user is not a super admin.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The topic name with the registered service email address.
4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4314 def register_subscriber request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::RegisterSubscriberRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.register_subscriber..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.register_subscriber.timeout, metadata: , retry_policy: @config.rpcs.register_subscriber.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.register_subscriber request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#start_paid_service(request, options = nil) ⇒ ::Gapic::Operation #start_paid_service(name: nil, request_id: nil) ⇒ ::Gapic::Operation
Starts paid service for a trial entitlement.
Starts paid service for a trial entitlement immediately. This method is only applicable if a plan is set up for a trial entitlement but has some trial days remaining.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Entitlement resource not found.
- FAILED_PRECONDITION/NOT_IN_TRIAL: This method only works for entitlement on trial plans.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1736 def start_paid_service request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::StartPaidServiceRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.start_paid_service..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.start_paid_service.timeout, metadata: , retry_policy: @config.rpcs.start_paid_service.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.start_paid_service request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#suspend_entitlement(request, options = nil) ⇒ ::Gapic::Operation #suspend_entitlement(name: nil, request_id: nil) ⇒ ::Gapic::Operation
Suspends a previously fulfilled entitlement.
An entitlement suspension is a long-running operation.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: Entitlement resource not found.
- NOT_ACTIVE: Entitlement is not active.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 1834 def suspend_entitlement request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::SuspendEntitlementRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.suspend_entitlement..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.suspend_entitlement.timeout, metadata: , retry_policy: @config.rpcs.suspend_entitlement.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.suspend_entitlement request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#transfer_entitlements(request, options = nil) ⇒ ::Gapic::Operation #transfer_entitlements(parent: nil, entitlements: nil, auth_token: nil, request_id: nil) ⇒ ::Gapic::Operation
Transfers customer entitlements to new reseller.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer or offer resource was not found.
- ALREADY_EXISTS: The SKU was already transferred for the customer.
- CONDITION_NOT_MET or FAILED_PRECONDITION:
- The SKU requires domain verification to transfer, but the domain is not verified.
- An Add-On SKU (example, Vault or Drive) is missing the pre-requisite SKU (example, G Suite Basic).
- (Developer accounts only) Reseller and resold domain must meet the
following naming requirements:
- Domain names must start with goog-test.
- Domain names must include the reseller domain.
- Specify all transferring entitlements.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The Operation metadata will contain an instance of OperationMetadata.
2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2154 def transfer_entitlements request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::TransferEntitlementsRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.transfer_entitlements..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.transfer_entitlements.timeout, metadata: , retry_policy: @config.rpcs.transfer_entitlements.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.transfer_entitlements request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#transfer_entitlements_to_google(request, options = nil) ⇒ ::Gapic::Operation #transfer_entitlements_to_google(parent: nil, entitlements: nil, request_id: nil) ⇒ ::Gapic::Operation
Transfers customer entitlements from their current reseller to Google.
Possible error codes:
- PERMISSION_DENIED: The customer doesn't belong to the reseller.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer or offer resource was not found.
- ALREADY_EXISTS: The SKU was already transferred for the customer.
- CONDITION_NOT_MET or FAILED_PRECONDITION:
- The SKU requires domain verification to transfer, but the domain is not verified.
- An Add-On SKU (example, Vault or Drive) is missing the pre-requisite SKU (example, G Suite Basic).
- (Developer accounts only) Reseller and resold domain must meet the
following naming requirements:
- Domain names must start with goog-test.
- Domain names must include the reseller domain.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The ID of a long-running operation.
To get the results of the operation, call the GetOperation method of CloudChannelOperationsService. The response will contain google.protobuf.Empty on success. The Operation metadata will contain an instance of OperationMetadata.
2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2262 def transfer_entitlements_to_google request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::TransferEntitlementsToGoogleRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.transfer_entitlements_to_google..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.transfer_entitlements_to_google.timeout, metadata: , retry_policy: @config.rpcs.transfer_entitlements_to_google.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.transfer_entitlements_to_google request, do |result, operation| result = ::Gapic::Operation.new result, @operations_client, options: yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#unregister_subscriber(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::UnregisterSubscriberResponse #unregister_subscriber(account: nil, service_account: nil) ⇒ ::Google::Cloud::Channel::V1::UnregisterSubscriberResponse
Unregisters a service account with subscriber privileges on the Cloud Pub/Sub topic created for this Channel Services account. If there are no service accounts left with subscriber privileges, this deletes the topic. You can call ListSubscribers to check for these accounts.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request and the provided reseller account are different, or the impersonated user is not a super admin.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The topic resource doesn't exist.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The topic name that unregistered the service email address. Returns a success response if the service email address wasn't registered with the topic.
4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 4399 def unregister_subscriber request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::UnregisterSubscriberRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.unregister_subscriber..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.unregister_subscriber.timeout, metadata: , retry_policy: @config.rpcs.unregister_subscriber.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.unregister_subscriber request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_channel_partner_link(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink #update_channel_partner_link(name: nil, channel_partner_link: nil, update_mask: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerLink
Updates a channel partner link. Distributors call this method to change a link's status. For example, to suspend a partner link. You must be a distributor to call this method.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT:
- Required request parameters are missing or invalid.
- Link state cannot change from invited to active or suspended.
- Cannot send reseller_cloud_identity_id, invite_url, or name in update mask.
- NOT_FOUND: ChannelPartnerLink resource not found.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
Return value: The updated ChannelPartnerLink resource.
2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 2613 def update_channel_partner_link request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::UpdateChannelPartnerLinkRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_channel_partner_link..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_channel_partner_link.timeout, metadata: , retry_policy: @config.rpcs.update_channel_partner_link.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.update_channel_partner_link request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_channel_partner_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig #update_channel_partner_repricing_config(channel_partner_repricing_config: nil) ⇒ ::Google::Cloud::Channel::V1::ChannelPartnerRepricingConfig
Updates a ChannelPartnerRepricingConfig. Call this method to set modifications for a specific ChannelPartner's bill. This method overwrites the existing CustomerRepricingConfig.
You can only update configs if the RepricingConfig.effective_invoice_month is a future month. To make changes to configs for the current month, use CreateChannelPartnerRepricingConfig, taking note of its restrictions. You cannot update the RepricingConfig.effective_invoice_month.
When updating a config in the future:
- This config must already exist.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- INVALID_ARGUMENT: Missing or invalid required parameters in the request. Also displays if the updated config is for the current month or past months.
- NOT_FOUND: The ChannelPartnerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the updated ChannelPartnerRepricingConfig resource, otherwise returns an error.
3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3473 def update_channel_partner_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::UpdateChannelPartnerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_channel_partner_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_channel_partner_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.update_channel_partner_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.update_channel_partner_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_customer(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::Customer #update_customer(customer: nil, update_mask: nil) ⇒ ::Google::Cloud::Channel::V1::Customer
Updates an existing Customer resource for the reseller or distributor.
Possible error codes:
- PERMISSION_DENIED: The reseller account making the request is different from the reseller account in the API request.
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: No Customer resource found for the name in the request.
Return value: The updated Customer resource.
564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 564 def update_customer request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::UpdateCustomerRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_customer..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_customer.timeout, metadata: , retry_policy: @config.rpcs.update_customer.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.update_customer request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |
#update_customer_repricing_config(request, options = nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig #update_customer_repricing_config(customer_repricing_config: nil) ⇒ ::Google::Cloud::Channel::V1::CustomerRepricingConfig
Updates a CustomerRepricingConfig. Call this method to set modifications for a specific customer's bill. This method overwrites the existing CustomerRepricingConfig.
You can only update configs if the RepricingConfig.effective_invoice_month is a future month. To make changes to configs for the current month, use CreateCustomerRepricingConfig, taking note of its restrictions. You cannot update the RepricingConfig.effective_invoice_month.
When updating a config in the future:
- This config must already exist.
Possible Error Codes:
- PERMISSION_DENIED: If the account making the request and the account being queried are different.
- INVALID_ARGUMENT: Missing or invalid required parameters in the request. Also displays if the updated config is for the current month or past months.
- NOT_FOUND: The CustomerRepricingConfig specified does not exist or is not associated with the given account.
- INTERNAL: Any non-user error related to technical issues in the backend. In this case, contact Cloud Channel support.
Return Value: If successful, the updated CustomerRepricingConfig resource, otherwise returns an error.
3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 |
# File 'lib/google/cloud/channel/v1/cloud_channel_service/rest/client.rb', line 3002 def update_customer_repricing_config request, = nil raise ::ArgumentError, "request must be provided" if request.nil? request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::Channel::V1::UpdateCustomerRepricingConfigRequest # Converts hash and nil to an options object = ::Gapic::CallOptions.new(**.to_h) if .respond_to? :to_h # Customize the options with defaults = @config.rpcs.update_customer_repricing_config..to_h # Set x-goog-api-client and x-goog-user-project headers [:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \ lib_name: @config.lib_name, lib_version: @config.lib_version, gapic_version: ::Google::Cloud::Channel::V1::VERSION, transports_version_send: [:rest] [:"x-goog-user-project"] = @quota_project_id if @quota_project_id .apply_defaults timeout: @config.rpcs.update_customer_repricing_config.timeout, metadata: , retry_policy: @config.rpcs.update_customer_repricing_config.retry_policy .apply_defaults timeout: @config.timeout, metadata: @config., retry_policy: @config.retry_policy @cloud_channel_service_stub.update_customer_repricing_config request, do |result, operation| yield result, operation if block_given? return result end rescue ::Gapic::Rest::Error => e raise ::Google::Cloud::Error.from_error(e) end |