---
title: "presentFriendRequestCreator(from:)"
framework: gamekit
role: symbol
role_heading: Instance Method
path: "gamekit/gklocalplayer/presentfriendrequestcreator(from:)-7clh6"
---

# presentFriendRequestCreator(from:)

Opens the Messages app with a sheet for the player to request friends.

## Declaration

```swift
func presentFriendRequestCreator(from window: NSWindow?) throws
```

## Parameters

- `window`: The window that’s the anchor for opening the Messages app.

## Discussion

Discussion If this method throws an exception, it doesn’t open the Messages app.

## See Also

### Adding Friends

- [isPresentingFriendRequestViewController](gamekit/gklocalplayer/ispresentingfriendrequestviewcontroller.md)
- [presentFriendRequestCreator(from:)](gamekit/gklocalplayer/presentfriendrequestcreator(from:)-7j1kn.md)
