<!--
{
  "availability" : [
    "iOS: 11.0.0 -",
    "iPadOS: 11.0.0 -",
    "macCatalyst: 13.1.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/UIDocumentBrowserAction/init(identifier:localizedTitle:availability:handler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)UIDocumentBrowserAction(im)initWithIdentifier:localizedTitle:availability:handler:"
  },
  "title" : "init(identifier:localizedTitle:availability:handler:)"
}
-->

# init(identifier:localizedTitle:availability:handler:)

Instantiates and returns a new browser action item.

```
init(identifier: String, localizedTitle: String, availability: UIDocumentBrowserAction.Availability, handler: @escaping ([URL]) -> Void)
```

## Parameters

`identifier`

A unique identifier for the activity.

`localizedTitle`

The title that appears in the Edit Menu or navigation bar. This title should be a <doc://com.apple.documentation/documentation/Swift/String> returned by  <doc://com.apple.documentation/documentation/Foundation/NSLocalizedString>.

`availability`

A value that defines where the action can appear (in the menu, navigation bar, or both).

    For a list of valid values, see [`UIDocumentBrowserAction.Availability`](/documentation/UIKit/UIDocumentBrowserAction/Availability-swift.struct)    .

`handler`

A block that is called when the user triggers the action. The block takes the following parameter:

- urls: An array of URLs for the documents that the user has selected. If the action’s [`supportsMultipleItems`](/documentation/UIKit/UIDocumentBrowserAction/supportsMultipleItems)  property is <doc://com.apple.documentation/documentation/Swift/false>, this array contains one URL. Otherwise, it can contain one or more URLs.

---

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)