# withTunnelReference

- Module: [Aspire.Hosting.DevTunnels](/reference/api/typescript/aspire.hosting.devtunnels.md)
- Version: `13.4.0`
- Kind: `method`
- Source: [GitHub](https://github.com/microsoft/aspire)

Exposes the specified endpoint via the dev tunnel.

## Definition

```typescript
interface DevTunnelResource {
  // ... omitted for brevity
  withTunnelReference(targetEndpoint: EndpointReference): DevTunnelResource
}
```

## Parameters

- `targetEndpoint` (`EndpointReference`)

## Returns

[DevTunnelResource](/reference/api/typescript/aspire.hosting.devtunnels/devtunnelresource.md) `builder`

## Applies to

- [DevTunnelResource](/reference/api/typescript/aspire.hosting.devtunnels/devtunnelresource.md)
