| Total Complexity | 3 |
| Total Lines | 45 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 16 | class Api |
||
| 17 | { |
||
| 18 | /** |
||
| 19 | * @var Client |
||
| 20 | */ |
||
| 21 | protected Client $client; |
||
| 22 | /** |
||
| 23 | * @var ResponseTransformer |
||
| 24 | */ |
||
| 25 | protected ResponseTransformer $transformer; |
||
| 26 | /** |
||
| 27 | * @var string |
||
| 28 | */ |
||
| 29 | private string $version = 'v3'; |
||
| 30 | /** |
||
| 31 | * @var string |
||
| 32 | */ |
||
| 33 | private string $endpoint = '/'; |
||
| 34 | |||
| 35 | /** |
||
| 36 | * Api constructor. |
||
| 37 | * @param Client $client |
||
| 38 | */ |
||
| 39 | 30 | public function __construct(Client $client) |
|
| 43 | 30 | } |
|
| 44 | |||
| 45 | /** |
||
| 46 | * @param string $method |
||
| 47 | * @param string $uri |
||
| 48 | * @param array $options |
||
| 49 | * @param bool|null $needSequence |
||
| 50 | * @return array |
||
| 51 | * @throws GuzzleException |
||
| 52 | * @throws TransformResponseException |
||
| 53 | */ |
||
| 54 | 27 | public function rest(string $method, string $uri, array $options = [], ?bool $needSequence = null): array |
|
| 61 | } |
||
| 62 | } |