> For the complete documentation index, see [llms.txt](https://docs.9proxy.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.9proxy.com/developers/sdk/sdk-nodejs/functions/createwithid-...args.md).

# createWithId(...args)

Creates and forwards a proxy on the specified port, identified by proxyId and configured with the given plan and action type.

```javascript
async createWithId(port, proxyId, plan, actionType)
```

***

## Parameters

* **port** (<mark style="color:green;">number</mark>) – The local port to forward.
* **proxyId** (<mark style="color:green;">string</mark>) – ID of the proxy to forward. This also acts as the requestId for receiving success/failure status in event callbacks.
* **plan** (<mark style="color:green;">string</mark>) – ID of the plan to use (default: "1").
* **actionType** (<mark style="color:green;">string</mark>) – User action type (default: "manual").

## Return Value

<mark style="color:green;">number</mark> – Returns 0 on success.

## Example

```javascript
// example

sdk.createWithId(60000, "677e2c4517f247bc89dd66a4", "1", "manual");

```
