/** * Create a Join.Me download/start URL * * Method calls API to get a start meeting code and ticket. You only need * to call this method and then access the hostUrl and joinUrl properties * to get the links for the host to download the software and start the meeting * and the link for an attendee to join the share. * * @param array $options Unused with this adapter. * @return \Smx\SimpleMeetings\JoinMe\Meeting A copy of $this */ public function createMeeting($options = false) { if ($options && is_array($options)) { foreach ($options as $name => $value) { $this->{$name} = $value; } } if ($this->isAuthenticated()) { $url = 'https://secure.join.me/API/requestCode?authcode=' . $this->getAuthCode(); $results = Utilities::callApi($url); $success = preg_match('/CODE: (\\d+)[\\n]TICKET: (\\d+)/', $results, $details); if ($success) { $this->meetingKey = $details[1]; $this->meetingPassword = $details[2]; $this->hostPassword = $details[2]; $this->startMeeting(); $this->joinMeeting(); return $this; } else { throw new \ErrorException('Unable to create meeting, error: ' . $results, 301); } } else { throw new \ErrorException('User must be logged in with a valid auth code before creating a meeting.', 302); } }
/** * JoinMe requires exchanging an email address and password for an authCode */ public function requestAuthCode() { $url = 'https://secure.join.me/API/requestAuthCode' . '?email=' . $this->email . '&password='******'/^AUTHCODE: (.*)$/', $response, $matches); if ($validate) { $this->authCode = $matches[1]; } }