Skip to content

Commit b4ade31

Browse files
committed
Merge branch 'authenticate_with_token' into 'main'
Authenticate with token See merge request softwares-pkp/thoth-client-php!19
2 parents 6cffdc3 + 15e6267 commit b4ade31

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/GraphQL/Client.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@ public function __construct(array $httpConfig = [])
3737
$this->request = new Request($httpConfig);
3838
}
3939

40+
public function setToken(string $token): self
41+
{
42+
$this->token = $token;
43+
return $this;
44+
}
45+
4046
public function login(string $email, string $password): self
4147
{
4248
$this->token = (new Account($this->request))->login($email, $password);

0 commit comments

Comments
 (0)