|
|
@@ -35,7 +35,14 @@ class MobytService extends ApiRequestService
|
|
|
*/
|
|
|
protected function connect(string $login, string $password): void
|
|
|
{
|
|
|
- $responseContent = $this->getContent('login', ['username' => $login, 'password' => $password]);
|
|
|
+ $responseContent = $this->getContent('login',[],
|
|
|
+ [
|
|
|
+ 'headers' => [
|
|
|
+ 'Content-Type: application/json',
|
|
|
+ 'Authorization: Basic '. base64_encode($login.':'.$password),
|
|
|
+ ]
|
|
|
+ ]
|
|
|
+ );
|
|
|
[$this->userId, $this->sessionKey] = explode(';', $responseContent);
|
|
|
}
|
|
|
|