# EventHubProxy

- Module: [Aspire.Hosting.Azure.Provisioning.EventHubs](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs.md)
- Version: `17.0.0-preview.1.26567.5`
- Kind: `handle`
- Source: [GitHub](https://github.com/microsoft/aspire/tree/2d325b13709752ba6d9a943635c5e2940a2530c0)

Represents the EventHub Azure Provisioning model.

## Definition

```typescript
interface EventHubProxy {
  captureDescription: CaptureDescriptionProxy;
  readonly createdOn: BicepValueProxy | datetimeoffset;
  readonly id: BicepValueProxy;
  readonly location: BicepValueProxy;
  name: BicepValueProxy | string;
  parent: EventHubsNamespaceProxy;
  partitionCount: BicepValueProxy | number;
  readonly partitionIds: Aspire_Hosting_Azure_Provisioning_EventHubs_Generated_ListOfStringProxy;
  retentionDescription: RetentionDescriptionProxy;
  status: BicepValueProxy | EventHubEntityStatus;
  readonly systemData: EventHubsSystemDataProxy;
  readonly updatedOn: BicepValueProxy | datetimeoffset;
  userMetadata: BicepValueProxy | string;
  addTo(infrastructure: AzureResourceInfrastructure): void;
  clearName(): void;
  clearPartitionCount(): void;
  clearStatus(): void;
  clearUserMetadata(): void;
}
```

## Properties

- `captureDescription`: [CaptureDescriptionProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/capturedescriptionproxy.md) `get - set` -- Gets or sets the CaptureDescription provisioning property.
- `createdOn`: `BicepValueProxy | datetimeoffset` `get` -- Gets the CreatedOn provisioning property.
- `id`: `BicepValueProxy` `get` -- Gets the Id provisioning property.
- `location`: `BicepValueProxy` `get` -- Gets the Location provisioning property.
- `name`: `BicepValueProxy | string` `get - set` -- Gets or sets the Name provisioning property.
- `parent`: [EventHubsNamespaceProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubsnamespaceproxy.md) `get - set` -- Gets or sets the Parent provisioning property.
- `partitionCount`: `BicepValueProxy | number` `get - set` -- Gets or sets the PartitionCount provisioning property.
- `partitionIds`: [Aspire_Hosting_Azure_Provisioning_EventHubs_Generated_ListOfStringProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/aspire-hosting-azure-provisioning-eventhubs-generated-listofstringproxy.md) `get` -- Gets the PartitionIds provisioning property.
- `retentionDescription`: [RetentionDescriptionProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/retentiondescriptionproxy.md) `get - set` -- Gets or sets the RetentionDescription provisioning property.
- `status`: `BicepValueProxy | EventHubEntityStatus` `get - set` -- Gets or sets the Status provisioning property.
- `systemData`: [EventHubsSystemDataProxy](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubssystemdataproxy.md) `get` -- Gets the SystemData provisioning property.
- `updatedOn`: `BicepValueProxy | datetimeoffset` `get` -- Gets the UpdatedOn provisioning property.
- `userMetadata`: `BicepValueProxy | string` `get - set` -- Gets or sets the UserMetadata provisioning property.

## Methods

- [addTo](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubproxy/addto.md) -- `method` -- Adds this provisioning resource to the Azure resource infrastructure.
    ```typescript
  addTo(infrastructure: AzureResourceInfrastructure): void
  ```
- [clearName](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubproxy/clearname.md) -- `method` -- Clears the Name provisioning property.
    ```typescript
  clearName(): void
  ```
- [clearPartitionCount](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubproxy/clearpartitioncount.md) -- `method` -- Clears the PartitionCount provisioning property.
    ```typescript
  clearPartitionCount(): void
  ```
- [clearStatus](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubproxy/clearstatus.md) -- `method` -- Clears the Status provisioning property.
    ```typescript
  clearStatus(): void
  ```
- [clearUserMetadata](/reference/api/typescript/aspire.hosting.azure.provisioning.eventhubs/eventhubproxy/clearusermetadata.md) -- `method` -- Clears the UserMetadata provisioning property.
    ```typescript
  clearUserMetadata(): void
  ```
