quickCreateProxies(...args)

Quickly forwards multiple proxies to a set of ports.

  • If a port has a configuration, the proxy will be forwarded using that configuration.

  • If not, a random proxy will be assigned.

  • Optionally, you can limit forwarding only to unused ports.

async quickCreateProxies(requestId, plan, ports, n, onlyFree)

Parameters

  • requestId (string) – ID used to track request status in event callbacks.

  • plan (string) – ID of the plan to use (default: "1").

  • ports (Uint32Array) – List of ports to forward.

  • n (number) – Number of elements in the ports array.

  • onlyFree (number, 0 or 1) – 1 = only forward to ports that are not in use; 0 = attempt on all ports.

Return Value

number or array (binding dependent).

Example

// example

const cand = new Uint32Array([60000, 60001]);
const ret = sdk.quickCreateProxies("request_id", "1", cand, cand.length, 1);

Last updated

Was this helpful?