# Service Usage V1 API - Class Google::Api::Usage (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::Api::Usage.

Configuration controlling usage of a service.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #producer_notification_channel

    def producer_notification_channel() -> ::String

**Returns**

- (::String) --- The full resource name of a channel used for sending notifications to the service producer.

  Google Service Management currently only supports
  [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
  channel. To use Google Cloud Pub/Sub as the channel, this must be the name
  of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
  documented in https://cloud.google.com/pubsub/docs/overview.

### #producer_notification_channel=

    def producer_notification_channel=(value) -> ::String

**Parameter**

- **value** (::String) --- The full resource name of a channel used for sending notifications to the service producer.


  Google Service Management currently only supports
  [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
  channel. To use Google Cloud Pub/Sub as the channel, this must be the name
  of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
  documented in https://cloud.google.com/pubsub/docs/overview.
**Returns**

- (::String) --- The full resource name of a channel used for sending notifications to the service producer.

  Google Service Management currently only supports
  [Google Cloud Pub/Sub](https://cloud.google.com/pubsub) as a notification
  channel. To use Google Cloud Pub/Sub as the channel, this must be the name
  of a Cloud Pub/Sub topic that uses the Cloud Pub/Sub topic name format
  documented in https://cloud.google.com/pubsub/docs/overview.

### #requirements

    def requirements() -> ::Array<::String>

**Returns**

- (::Array\<::String\>) --- Requirements that must be satisfied before a consumer project can use the service. Each requirement is of the form

### #requirements=

    def requirements=(value) -> ::Array<::String>

**Parameter**

- **value** (::Array\<::String\>) --- Requirements that must be satisfied before a consumer project can use the service. Each requirement is of the form
**Returns**

- (::Array\<::String\>) --- Requirements that must be satisfied before a consumer project can use the service. Each requirement is of the form

### #rules

    def rules() -> ::Array<::Google::Api::UsageRule>

**Returns**

- (::Array\<[::Google::Api::UsageRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Api-UsageRule)\>) --- A list of usage rules that apply to individual API methods.


  **NOTE:** All service configuration rules follow "last one wins" order.

### #rules=

    def rules=(value) -> ::Array<::Google::Api::UsageRule>

**Parameter**

- **value** (::Array\<[::Google::Api::UsageRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Api-UsageRule)\>) --- A list of usage rules that apply to individual API methods.


  **NOTE:** All service configuration rules follow "last one wins" order.
**Returns**

- (::Array\<[::Google::Api::UsageRule](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-service_usage-v1/latest/Google-Api-UsageRule)\>) --- A list of usage rules that apply to individual API methods.


  **NOTE:** All service configuration rules follow "last one wins" order.