# Managed Service for Apache Kafka V1 API - Class Google::Cloud::ManagedKafka::V1::CreateTopicRequest (v1.9.0)

1.9.0 (latest) 1.8.0 1.7.0 1.6.1 1.5.0 1.4.0 1.3.0 1.2.0 1.1.2 1.0.1 0.5.0 0.4.0 0.3.0 0.2.0 0.1.3 Reference documentation and code samples for the Managed Service for Apache Kafka V1 API class Google::Cloud::ManagedKafka::V1::CreateTopicRequest.

Request for CreateTopic.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #parent

    def parent() -> ::String

**Returns**

- (::String) --- Required. The parent cluster in which to create the topic. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.

### #parent=

    def parent=(value) -> ::String

**Parameter**

- **value** (::String) --- Required. The parent cluster in which to create the topic. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.
**Returns**

- (::String) --- Required. The parent cluster in which to create the topic. Structured like `projects/{project}/locations/{location}/clusters/{cluster}`.

### #topic

    def topic() -> ::Google::Cloud::ManagedKafka::V1::Topic

**Returns**

- ([::Google::Cloud::ManagedKafka::V1::Topic](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-managed_kafka-v1/latest/Google-Cloud-ManagedKafka-V1-Topic)) --- Required. Configuration of the topic to create. Its `name` field is ignored.

### #topic=

    def topic=(value) -> ::Google::Cloud::ManagedKafka::V1::Topic

**Parameter**

- **value** ([::Google::Cloud::ManagedKafka::V1::Topic](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-managed_kafka-v1/latest/Google-Cloud-ManagedKafka-V1-Topic)) --- Required. Configuration of the topic to create. Its `name` field is ignored.
**Returns**

- ([::Google::Cloud::ManagedKafka::V1::Topic](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-managed_kafka-v1/latest/Google-Cloud-ManagedKafka-V1-Topic)) --- Required. Configuration of the topic to create. Its `name` field is ignored.

### #topic_id

    def topic_id() -> ::String

**Returns**

- (::String) --- Required. The ID to use for the topic, which will become the final component of the topic's name.

  This value is structured like: `my-topic-name`.

### #topic_id=

    def topic_id=(value) -> ::String

**Parameter**

- **value** (::String) --- Required. The ID to use for the topic, which will become the final component of the topic's name.


  This value is structured like: `my-topic-name`.
**Returns**

- (::String) --- Required. The ID to use for the topic, which will become the final component of the topic's name.

  This value is structured like: `my-topic-name`.