mirror of
https://github.com/elyby/accounts.git
synced 2024-12-28 16:10:40 +05:30
df1859f0c1
Исправлена ошибка доступа к authserver из-за перехода на использование хостов, а не доменов
28 lines
733 B
PHP
28 lines
733 B
PHP
<?php
|
|
namespace tests\codeception\api\_pages;
|
|
|
|
use yii\codeception\BasePage;
|
|
|
|
/**
|
|
* @property \tests\codeception\api\FunctionalTester $actor
|
|
*/
|
|
class MojangApiRoute extends BasePage {
|
|
|
|
public function usernameToUuid($username, $at = null) {
|
|
$this->route = '/mojang/profiles/' . $username;
|
|
$params = $at === null ? [] : ['at' => $at];
|
|
$this->actor->sendGET($this->getUrl(), $params);
|
|
}
|
|
|
|
public function usernamesByUuid($uuid) {
|
|
$this->route = "/mojang/profiles/{$uuid}/names";
|
|
$this->actor->sendGET($this->getUrl());
|
|
}
|
|
|
|
public function uuidsByUsernames($uuids) {
|
|
$this->route = '/mojang/profiles';
|
|
$this->actor->sendPOST($this->getUrl(), $uuids);
|
|
}
|
|
|
|
}
|