# BigQuery Reservation V1 API - Class Google::Cloud::Bigquery::Reservation::V1::CreateCapacityCommitmentRequest (v1.12.0)

1.12.0 (latest) 1.11.0 1.10.0 1.9.2 1.8.0 1.7.0 1.6.0 1.5.0 1.4.1 1.3.0 1.2.0 1.1.0 1.0.1 0.12.0 0.11.2 0.10.0 0.9.0 0.8.1 0.7.0 0.6.0 0.5.0 0.4.2 Reference documentation and code samples for the BigQuery Reservation V1 API class Google::Cloud::Bigquery::Reservation::V1::CreateCapacityCommitmentRequest.

The request for
[ReservationService.CreateCapacityCommitment](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-bigquery-reservation-v1/latest/Google-Cloud-Bigquery-Reservation-V1-ReservationService-Client#Google__Cloud__Bigquery__Reservation__V1__ReservationService__Client_create_capacity_commitment_instance_ "Google::Cloud::Bigquery::Reservation::V1::ReservationService::Client#create_capacity_commitment (method)").

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #capacity_commitment

    def capacity_commitment() -> ::Google::Cloud::Bigquery::Reservation::V1::CapacityCommitment

**Returns**

- ([::Google::Cloud::Bigquery::Reservation::V1::CapacityCommitment](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-bigquery-reservation-v1/latest/Google-Cloud-Bigquery-Reservation-V1-CapacityCommitment)) --- Content of the capacity commitment to create.

### #capacity_commitment=

    def capacity_commitment=(value) -> ::Google::Cloud::Bigquery::Reservation::V1::CapacityCommitment

**Parameter**

- **value** ([::Google::Cloud::Bigquery::Reservation::V1::CapacityCommitment](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-bigquery-reservation-v1/latest/Google-Cloud-Bigquery-Reservation-V1-CapacityCommitment)) --- Content of the capacity commitment to create.
**Returns**

- ([::Google::Cloud::Bigquery::Reservation::V1::CapacityCommitment](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-bigquery-reservation-v1/latest/Google-Cloud-Bigquery-Reservation-V1-CapacityCommitment)) --- Content of the capacity commitment to create.

### #capacity_commitment_id

    def capacity_commitment_id() -> ::String

**Returns**

- (::String) --- The optional capacity commitment ID. Capacity commitment name will be generated automatically if this field is empty. This field must only contain lower case alphanumeric characters or dashes. The first and last character cannot be a dash. Max length is 64 characters. NOTE: this ID won't be kept if the capacity commitment is split or merged.

### #capacity_commitment_id=

    def capacity_commitment_id=(value) -> ::String

**Parameter**

- **value** (::String) --- The optional capacity commitment ID. Capacity commitment name will be generated automatically if this field is empty. This field must only contain lower case alphanumeric characters or dashes. The first and last character cannot be a dash. Max length is 64 characters. NOTE: this ID won't be kept if the capacity commitment is split or merged.
**Returns**

- (::String) --- The optional capacity commitment ID. Capacity commitment name will be generated automatically if this field is empty. This field must only contain lower case alphanumeric characters or dashes. The first and last character cannot be a dash. Max length is 64 characters. NOTE: this ID won't be kept if the capacity commitment is split or merged.

### #enforce_single_admin_project_per_org

    def enforce_single_admin_project_per_org() -> ::Boolean

**Returns**

- (::Boolean) --- If true, fail the request if another project in the organization has a capacity commitment.

### #enforce_single_admin_project_per_org=

    def enforce_single_admin_project_per_org=(value) -> ::Boolean

**Parameter**

- **value** (::Boolean) --- If true, fail the request if another project in the organization has a capacity commitment.
**Returns**

- (::Boolean) --- If true, fail the request if another project in the organization has a capacity commitment.

### #parent

    def parent() -> ::String

**Returns**

- (::String) --- Required. Resource name of the parent reservation. E.g., `projects/myproject/locations/US`

### #parent=

    def parent=(value) -> ::String

**Parameter**

- **value** (::String) --- Required. Resource name of the parent reservation. E.g., `projects/myproject/locations/US`
**Returns**

- (::String) --- Required. Resource name of the parent reservation. E.g., `projects/myproject/locations/US`