Cloudflare\User\LoadBalancers\Pools::create PHP Method

create() public method

Create a pool Create a new pool
public create ( string $name, array $origins, string | null $description = null, boolean | null $enabled = null, string | null $monitor = null, string | null $notifier = null )
$name string Object name
$origins array A list of origins contained in the pool. Traffic destined to the pool is balanced across all available origins contained in the pool (as long as the pool is considered available).
$description string | null Object description
$enabled boolean | null Whether this pool is enabled or not.
$monitor string | null ID of the monitor object to use for monitoring the health status of origins inside this pool.
$notifier string | null ID of the notifier object to use for notifications relating to the health status of origins inside this pool.
    public function create($name, $origins, $description = null, $enabled = null, $monitor = null, $notifier = null)
    {
        $data = ['name' => $name, 'origins' => $origins, 'description' => $description, 'enabled' => $enabled, 'monitor' => $monitor, 'notifier' => $notifier];
        return $this->post('/user/load_balancers/pools', $data);
    }