# Service Usage V1 API - Class Google::Cloud::ServiceUsage::V1::ServiceUsage::Rest::ServiceStub (v1.8.0)

1.8.0 (latest) 1.7.1 1.6.0 1.5.1 1.4.0 1.3.0 1.2.1 1.1.0 1.0.1 0.7.0 0.6.2 0.5.0 0.4.0 0.3.1 0.2.1 0.1.4 Reference documentation and code samples for the Service Usage V1 API class Google::Cloud::ServiceUsage::V1::ServiceUsage::Rest::ServiceStub.

REST service stub for the ServiceUsage service.
Service stub contains baseline method implementations
including transcoding, making the REST call, and deserialing the response.

## Inherits

- Object

## Methods

### #batch_enable_services

    def batch_enable_services(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the batch_enable_services REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::BatchEnableServicesRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-BatchEnableServicesRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #batch_get_services

    def batch_get_services(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::ServiceUsage::V1::BatchGetServicesResponse

Baseline implementation for the batch_get_services REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::BatchGetServicesRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-BatchGetServicesRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::ServiceUsage::V1::BatchGetServicesResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-BatchGetServicesResponse))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::ServiceUsage::V1::BatchGetServicesResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-BatchGetServicesResponse)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #disable_service

    def disable_service(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the disable_service REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::DisableServiceRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-DisableServiceRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #enable_service

    def enable_service(request_pb, options = nil) { |result, operation| ... } -> ::Google::Longrunning::Operation

Baseline implementation for the enable_service REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::EnableServiceRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-EnableServiceRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Longrunning::Operation](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Longrunning-Operation)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #endpoint

    def endpoint() -> String

The effective endpoint
**Returns**

- (String)

### #get_service

    def get_service(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::ServiceUsage::V1::Service

Baseline implementation for the get_service REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::GetServiceRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-GetServiceRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::ServiceUsage::V1::Service](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-Service))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::ServiceUsage::V1::Service](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-Service)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #list_services

    def list_services(request_pb, options = nil) { |result, operation| ... } -> ::Google::Cloud::ServiceUsage::V1::ListServicesResponse

Baseline implementation for the list_services REST call
**Parameters**

- **request_pb** ([::Google::Cloud::ServiceUsage::V1::ListServicesRequest](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-ListServicesRequest)) --- A request object representing the call parameters. Required.
- **options** (::Gapic::CallOptions) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
**Yields**

- (result, operation) --- Access the result along with the TransportOperation object
**Yield Parameters**

- **result** ([::Google::Cloud::ServiceUsage::V1::ListServicesResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-ListServicesResponse))
- **operation** (::Gapic::Rest::TransportOperation)
**Returns**

- ([::Google::Cloud::ServiceUsage::V1::ListServicesResponse](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Cloud-ServiceUsage-V1-ListServicesResponse)) --- A result object deserialized from the server's reply
**Raises**

- (::ArgumentError)

### #logger

    def logger(stub: false) -> Logger

The logger used for request/response debug logging.
**Returns**

- (Logger)

### #universe_domain

    def universe_domain() -> String

The effective universe domain
**Returns**

- (String)