# GetInputPortByName(string)

> Retrieves an input port using its name.

## Definition

* **Type:** Method
* **Namespace:** [Unity.GraphToolkit.Editor](/engine/6000.6/script-reference/unity/graphtoolkit/editor.md)
* **Assembly:** UnityEditor

```csharp
public IPort GetInputPortByName(string name)
```

### Parameters

**** (\[string]\(https\://learn.microsoft.com/dotnet/api/system.string)): The unique name of the input port within this node.

### Returns

| Type                                                                        | Description                                                           |
| --------------------------------------------------------------------------- | --------------------------------------------------------------------- |
| [IPort](/engine/6000.6/script-reference/unity/graphtoolkit/editor/iport.md) | The input port with the specified name, or null if no match is found. |

### Remarks

The input port's name is unique within the node's input ports and node options.
