<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: 26.0.0 -",
    "macOS: 26.0.0 -",
    "tvOS: 26.0.0 -",
    "visionOS: 26.0.0 -",
    "watchOS: 26.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Network",
  "identifier" : "/documentation/Network/BrowserProvider/bonjour(_:domain:includeTxtRecord:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Network"
    ],
    "preciseIdentifier" : "s:7Network15BrowserProviderPA2A7BonjourVRszrlE7bonjour_6domain16includeTxtRecordAESS_SSSgSbtFZ"
  },
  "title" : "bonjour(_:domain:includeTxtRecord:)"
}
-->

# bonjour(_:domain:includeTxtRecord:)

Create a Bonjour browser provider used to browse for Bonjour services.

```
static func bonjour(_ type: String, domain: String? = nil, includeTxtRecord: Bool = false) -> Bonjour
```

## Parameters

`type`

The Bonjour type to browse for.

`domain`

Optional Bonjour domain to browse in.
If not specified, uses the Bonjour default browse domain, `nil`,
which is recommended in most cases.

`includeTxtRecord`

Boolean specifying whether to query for TXT records.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)