public function startBuild($env = null, $options = array())
    {
        $env = $this->getEnvUuid(null === $env ? $this->config->getEnv() : $env);
        $content = json_encode($options);
        $data = json_decode($this->sendHttpRequest($this->config->getEndpoint().'/api/v2/builds/env/'.$env, 'POST', array('content' => $content), array('Content-Type: application/json')), true);

        return new Build\Build($env, $data);
    }
public function startBuild($env = null, $options = array())
    {
        $env = $this->getEnvUuid(null === $env ? $this->config->getEnv() : $env);
        $content = json_encode($options);
        $data = json_decode($this->sendHttpRequest($this->config->getEndpoint().'/api/v2/builds/env/'.$env, 'POST', array('content' => $content), array('Content-Type: application/json')), true);

        return new Build\Build($env, $data);
    }
public function startBuild ( $ env = null , $ options = array ( ) ) { $ env = $ this -> getEnvUuid ( null === $ env ? $ this -> config -> getEnv ( ) : $ env ) ; $ content = json_encode ( $ options ) ; $ data = json_decode ( $ this -> sendHttpRequest ( $ this -> config -> getEndpoint ( ) . '/api/v2/builds/env/' . $ env , 'POST' , array ( 'content' => $ content ) , array ( 'Content-Type: application/json' ) ) , true ) ; return new Build \ Build ( $ env , $ data ) ; }
Creates a Blackfire Build.

@param string|null $env     The environment name (or null to use the one configured on the client)
@param array       $options An array of Build options
(title, metadata, trigger_name, external_id, external_parent_id)

@return Build\Build
Creates a Blackfire Build .