# GetOrCreateClient(string)

> Creates a new ChannelClient on a specific channel. If a client already exists, this method gets the client.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor.MPE](/engine/6000.7/script-reference/unityeditor/mpe.md)
* **Assembly:** UnityEditor.CoreModule

```csharp
public static ChannelClient GetOrCreateClient(string channelName)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): The name of the channel to open. This matches the last part of a WebSocket URL. For example, "127.0.0.1:9090/\\\<channelName\\>".

### Returns

| Type                                                                              | Description                                              |
| --------------------------------------------------------------------------------- | -------------------------------------------------------- |
| [ChannelClient](/engine/6000.7/script-reference/unityeditor/mpe/channelclient.md) | Instance of the newly-created or existing ChannelClient. |

### Remarks

This method does not automatically start clients that it creates. For information about starting a client, see [ChannelClient.Start](/engine/6000.7/script-reference/unityeditor/mpe/channelclient/start.md).
