public function addGuest($id,$guest) {
        if(is_string($guest)) {
            $params = array('email'=>$guest);
        } elseif(is_numeric($guest)) {
            $params = array('user_id'=>$guest);
        }else  {
            throw new \Exception('Invalid parameter');
        }
         
        return $this->post('/projects/'.$id.'/add_guest.json', $params);
        
    }
public function addGuest($id,$guest) {
        if(is_string($guest)) {
            $params = array('email'=>$guest);
        } elseif(is_numeric($guest)) {
            $params = array('user_id'=>$guest);
        }else  {
            throw new \Exception('Invalid parameter');
        }
         
        return $this->post('/projects/'.$id.'/add_guest.json', $params);
        
    }
public function addGuest ( $ id , $ guest ) { if ( is_string ( $ guest ) ) { $ params = array ( 'email' => $ guest ) ; } elseif ( is_numeric ( $ guest ) ) { $ params = array ( 'user_id' => $ guest ) ; } else { throw new \ Exception ( 'Invalid parameter' ) ; } return $ this -> post ( '/projects/' . $ id . '/add_guest.json' , $ params ) ; }
Add a member to a project

@link https://www.bugherd.com/api_v2#api_proj_add_guest
@param int $id
@param mixed $guest
@return boolean
Add a member to a project